Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
VueElementTemplate
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
JIRA
JIRA
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
黄瑜
VueElementTemplate
Commits
82cd051d
Commit
82cd051d
authored
May 15, 2018
by
王康
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master' of 115.28.80.125:softwarefactory/vueelementtemplate
parents
5fd03995
b5ba89d0
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
20 additions
and
30 deletions
+20
-30
HmFullCalendar.vue
src/views/haomo/components/calendar/HmFullCalendar.vue
+10
-20
index.vue
src/views/haomo/components/calendar/index.vue
+10
-10
No files found.
src/views/haomo/components/calendar/HmFullCalendar.vue
View file @
82cd051d
<
template
>
<
template
>
<div
class=
"calendarlist"
>
<div
class=
"calendarlist"
>
<i
class=
"el-icon-date"
@
click=
"dialogTableVisible = true"
></i>
<i
class=
"el-icon-date"
@
click=
"dialogTableVisible = true"
:style=
"demoEvent.iconStyle"
></i>
<el-dialog
:visible
.
sync=
"dialogTableVisible"
>
<el-dialog
:visible
.
sync=
"dialogTableVisible"
>
<div
class=
"datebook-root"
:style=
'componentW?"width:"+componentW+";":""'
>
<div
class=
"datebook-root"
:style=
'componentW?"width:"+componentW+";":""'
>
<div
class=
'top-panel'
>
<div
class=
'top-panel'
>
...
@@ -269,23 +269,12 @@
...
@@ -269,23 +269,12 @@
type
:
Object
,
type
:
Object
,
required
:
true
required
:
true
},
},
width
:
{
type
:
String
,
required
:
false
},
initTime
:
{
initTime
:
{
required
:
false
required
:
false
},
},
title
:
{
demoEvent
:
{
required
:
false
type
:
Object
,
},
events
:
{
required
:
false
},
timeOrder
:
{
required
:
false
},
date
:
{
required
:
false
required
:
false
}
}
},
},
...
@@ -493,15 +482,16 @@
...
@@ -493,15 +482,16 @@
getDailyEvent
()
{
getDailyEvent
()
{
const
self
=
this
const
self
=
this
var
saveTime
=
''
var
saveTime
=
''
var
filterparams
=
self
.
demoEvent
.
filterparams
request
(
self
.
schema
.
modelUnderscorePlural
,
{
request
(
self
.
schema
.
modelUnderscorePlural
,
{
params
:
{
'sortItem'
:
self
.
timeOrder
,
'pageSize'
:
10000
}
params
:
{
'sortItem'
:
self
.
demoEvent
.
timeOrder
,
'pageSize'
:
10000
,
filters
:
filterparams
}
}).
then
(
resp
=>
{
}).
then
(
resp
=>
{
console
.
log
(
resp
.
data
,
'========='
)
console
.
log
(
resp
.
data
,
'========='
)
_
.
each
(
resp
.
data
,
function
(
item
)
{
_
.
each
(
resp
.
data
,
function
(
item
)
{
item
.
time
=
moment
(
item
[
self
.
date
]).
format
(
'YYYY-MM-DD'
)
item
.
time
=
moment
(
item
[
self
.
d
emoEvent
.
d
ate
]).
format
(
'YYYY-MM-DD'
)
item
.
date
=
moment
(
item
[
self
.
date
]).
format
(
'X'
)
*
1000
item
.
date
=
moment
(
item
[
self
.
d
emoEvent
.
d
ate
]).
format
(
'X'
)
*
1000
item
.
title
=
item
[
self
.
title
]
item
.
title
=
item
[
self
.
demoEvent
.
title
]
item
.
allEvents
=
item
[
self
.
events
]
item
.
allEvents
=
item
[
self
.
demoEvent
.
events
]
if
(
saveTime
===
item
.
time
)
{
if
(
saveTime
===
item
.
time
)
{
self
.
schedules
[
self
.
schedules
.
length
-
1
].
allEvents
.
push
(
item
.
allEvents
)
self
.
schedules
[
self
.
schedules
.
length
-
1
].
allEvents
.
push
(
item
.
allEvents
)
}
else
{
}
else
{
...
...
src/views/haomo/components/calendar/index.vue
View file @
82cd051d
<
template
>
<
template
>
<div
class=
"app-container calendar-list-container"
>
<div
class=
"app-container calendar-list-container"
>
<hm-full-calendar
<hm-full-calendar
:width=
"width"
:schema=
"schema['HmUser']"
:schema=
"schema['HmUser']"
:title=
"title"
:demoEvent=
"demoEvent"
:events=
"events"
:date=
"date"
:timeOrder=
"timeOrder"
@
dateChange=
"datechange"
@
dateChange=
"datechange"
@
monthChange=
"monthchange"
@
monthChange=
"monthchange"
></hm-full-calendar>
></hm-full-calendar>
...
@@ -27,13 +23,17 @@
...
@@ -27,13 +23,17 @@
data
()
{
data
()
{
return
{
return
{
show
:
false
,
show
:
false
,
width
:
'300px'
,
demoEvent
:
{
width
:
'300px'
,
title
:
'loginid'
,
date
:
'createTime'
,
events
:
'email'
,
timeOrder
:
'create_time'
,
filterparams
:
''
,
iconStyle
:
'color: #00BF8B'
}
// title为需要传入的事件名所对应的的字段名,date为时间所对应的字段,events为事件所对应的字段,都不是必传
// title为需要传入的事件名所对应的的字段名,date为时间所对应的字段,events为事件所对应的字段,都不是必传
title
:
'loginid'
,
date
:
'createTime'
,
events
:
'email'
,
// timeOrder为所有所有事件按照数据库的哪个字段排序,为下划线格式
// timeOrder为所有所有事件按照数据库的哪个字段排序,为下划线格式
timeOrder
:
'create_time'
}
}
},
},
filters
:
{
filters
:
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment