Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
M
mt-education-mobile
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
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
王旭
mt-education-mobile
Commits
52d99a99
Commit
52d99a99
authored
Apr 04, 2020
by
yun
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
暂时性修改1
parent
bba29a17
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
29 additions
and
23 deletions
+29
-23
index.vue
src/views/addTrain/index.vue
+29
-23
No files found.
src/views/addTrain/index.vue
View file @
52d99a99
...
...
@@ -1312,58 +1312,64 @@ export default {
const
applyOverDate
=
new
Date
(
this
.
formData
.
applyOverDate
),
applyStartDate
=
new
Date
(
this
.
formData
.
applyStartDate
),
trainOverDate
=
new
Date
(
this
.
formData
.
trainOverDate
),
trainStartDate
=
new
Date
(
this
.
formData
.
trainStartDate
)
trainStartDate
=
new
Date
(
this
.
formData
.
trainStartDate
),
that
=
this
switch
(
this
.
type
)
{
// 判断报名开始时间不得晚于报名结束时间
case
'applyStartDate'
:
if
(
th
is
.
formData
.
applyOverDate
!==
''
)
{
th
is
.
maxDate
=
new
Date
(
applyOverDate
.
getTime
()
-
(
1000
*
60
))
if
(
th
at
.
formData
.
applyOverDate
!==
''
)
{
th
at
.
maxDate
=
new
Date
(
applyOverDate
.
getTime
()
-
(
1000
*
60
))
// this.currentDate = new Date(this.formData.applyStartDate)
}
// 判断报名开始时间不得晚于培训结束时间
if
(
th
is
.
formData
.
trainOverDate
!==
''
)
{
th
is
.
maxDate
=
new
Date
(
trainOverDate
.
getTime
()
-
(
1000
*
60
))
if
(
th
at
.
formData
.
trainOverDate
!==
''
)
{
th
at
.
maxDate
=
new
Date
(
trainOverDate
.
getTime
()
-
(
1000
*
60
))
// this.currentDate = new Date(this.formData.applyStartDate)
}
if
(
th
is
.
formData
.
trainOverDate
!==
''
&&
this
.
formData
.
applyOverDate
!==
''
)
{
th
is
.
maxDate
=
trainOverDate
.
getTime
()
>
applyOverDate
.
getTime
()
?
new
Date
(
applyOverDate
.
getTime
()
-
(
1000
*
60
))
:
new
Date
(
trainOverDate
.
getTime
()
-
(
1000
*
60
))
if
(
th
at
.
formData
.
trainOverDate
!==
''
&&
that
.
formData
.
applyOverDate
!==
''
)
{
th
at
.
maxDate
=
trainOverDate
.
getTime
()
>
applyOverDate
.
getTime
()
?
new
Date
(
applyOverDate
.
getTime
()
-
(
1000
*
60
))
:
new
Date
(
trainOverDate
.
getTime
()
-
(
1000
*
60
))
// this.currentDate = new Date(this.formData.applyStartDate)
}
break
// 判断报名结束时间不得早于报名开始时间
case
'applyOverDate'
:
if
(
this
.
formData
.
applyStartDate
!==
''
)
{
this
.
minDate
=
new
Date
(
applyStartDate
.
getTime
()
+
(
1000
*
60
))
if
(
that
.
formData
.
applyStartDate
!==
''
)
{
that
.
minDate
=
new
Date
(
applyStartDate
.
getTime
()
+
(
1000
*
60
))
that
.
currentDate
=
this
.
minDate
}
// 判断报名结束时间不得大于培训结束时间
if
(
th
is
.
formData
.
trainOverDate
!==
''
)
{
th
is
.
maxDate
=
new
Date
(
trainOverDate
.
getTime
()
-
(
1000
*
60
))
if
(
th
at
.
formData
.
trainOverDate
!==
''
)
{
th
at
.
maxDate
=
new
Date
(
trainOverDate
.
getTime
()
-
(
1000
*
60
))
}
break
// 判断培训开始时间不得晚于培训结束时间
case
'trainStartDate'
:
if
(
th
is
.
formData
.
trainOverDate
!==
''
)
{
th
is
.
maxDate
=
new
Date
(
trainOverDate
.
getTime
()
-
(
1000
*
60
))
if
(
th
at
.
formData
.
trainOverDate
!==
''
)
{
th
at
.
maxDate
=
new
Date
(
trainOverDate
.
getTime
()
-
(
1000
*
60
))
}
// 培训的开始字段要大于报名的开始字段
if
(
this
.
formData
.
applyStartDate
!==
''
)
{
this
.
minDate
=
new
Date
(
applyStartDate
.
getTime
()
+
(
1000
*
60
))
if
(
that
.
formData
.
applyStartDate
!==
''
)
{
that
.
minDate
=
new
Date
(
applyStartDate
.
getTime
()
+
(
1000
*
60
))
that
.
currentDate
=
this
.
minDate
}
if
(
th
is
.
formData
.
trainOverDate
!==
''
&&
this
.
formData
.
applyStartDate
!==
''
)
{
th
is
.
minDate
=
trainOverDate
.
getTime
()
>
applyStartDate
.
getTime
()
?
new
Date
(
applyStartDate
.
getTime
()
+
(
1000
*
60
))
:
new
Date
(
trainOverDate
.
getTime
()
+
(
1000
*
60
))
if
(
th
at
.
formData
.
trainOverDate
!==
''
&&
that
.
formData
.
applyStartDate
!==
''
)
{
th
at
.
minDate
=
trainOverDate
.
getTime
()
>
applyStartDate
.
getTime
()
?
new
Date
(
applyStartDate
.
getTime
()
+
(
1000
*
60
))
:
new
Date
(
trainOverDate
.
getTime
()
+
(
1000
*
60
))
}
break
// 判断培训结束时间不得早于培训开始时间
case
'trainOverDate'
:
if
(
this
.
formData
.
trainStartDate
!==
''
)
{
this
.
minDate
=
new
Date
(
trainStartDate
.
getTime
()
+
(
1000
*
60
))
if
(
that
.
formData
.
trainStartDate
!==
''
)
{
that
.
minDate
=
new
Date
(
trainStartDate
.
getTime
()
+
(
1000
*
60
))
that
.
currentDate
=
this
.
minDate
}
// 培训的结束字段要大于报名的结束字段
if
(
this
.
formData
.
applyOverDate
!==
''
)
{
this
.
minDate
=
new
Date
(
applyOverDate
.
getTime
()
+
(
1000
*
60
))
if
(
that
.
formData
.
applyOverDate
!==
''
)
{
that
.
minDate
=
new
Date
(
applyOverDate
.
getTime
()
+
(
1000
*
60
))
that
.
currentDate
=
this
.
minDate
}
if
(
this
.
formData
.
trainStartDate
!==
''
&&
this
.
formData
.
applyOverDate
!==
''
)
{
this
.
minDate
=
trainStartDate
.
getTime
()
>
applyOverDate
.
getTime
()
?
new
Date
(
trainStartDate
.
getTime
()
+
(
1000
*
60
))
:
new
Date
(
applyOverDate
.
getTime
()
+
(
1000
*
60
))
if
(
that
.
formData
.
trainStartDate
!==
''
&&
that
.
formData
.
applyOverDate
!==
''
)
{
that
.
minDate
=
trainStartDate
.
getTime
()
>
applyOverDate
.
getTime
()
?
new
Date
(
trainStartDate
.
getTime
()
+
(
1000
*
60
))
:
new
Date
(
applyOverDate
.
getTime
()
+
(
1000
*
60
))
that
.
currentDate
=
this
.
minDate
}
break
}
...
...
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