Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
C
confucius
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
罗超
confucius
Commits
7d525ae8
Commit
7d525ae8
authored
Jul 28, 2021
by
黄奎
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
页面修改
parent
9f6265b4
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
56 additions
and
16 deletions
+56
-16
index.js
src/api/school/index.js
+11
-0
class-form.vue
src/components/course/class-form.vue
+45
-16
No files found.
src/api/school/index.js
View file @
7d525ae8
...
...
@@ -232,6 +232,17 @@ export function saveClass(data) {
})
}
/**
* 批量添加上课计划
* @param {JSON数据} data
*/
export
function
batchSaveClassPlan
(
data
)
{
return
request
({
url
:
'/Class/BatchSetClassPlan'
,
method
:
'post'
,
data
})
}
/**
...
...
src/components/course/class-form.vue
View file @
7d525ae8
...
...
@@ -66,11 +66,12 @@
font-size
:
12px
;
margin-bottom
:
20px
;
}
.planTimeLi2
tbody
::before
{
.planTimeLi2
tbody
::before
{
content
:
''
;
display
:
table-row
;
height
:
20px
;
}
}
</
style
>
<
template
>
...
...
@@ -350,15 +351,15 @@
</div>
<div
class=
"row wrap"
>
<div
class=
"col-12"
>
<q-input
filled
type=
"textarea"
:rows=
"3"
stack-label
maxlength=
"2000"
v-model=
"objOption.InnerRemark"
:dense=
"false"
class=
"col-12 q-pr-lg q-pb-lg"
label=
"对内备注"
/>
<q-input
filled
type=
"textarea"
:rows=
"3"
stack-label
maxlength=
"2000"
v-model=
"objOption.InnerRemark"
:dense=
"false"
class=
"col-12 q-pr-lg q-pb-lg"
label=
"对内备注"
/>
</div>
</div>
</q-card-section>
<q-separator
/>
<q-card-actions
align=
"right"
class=
"bg-white"
>
<q-btn
label=
"取消"
flat
color=
"grey-10"
style=
"font-weight:400 !important"
@
click=
"closeCourseForm"
/>
<q-btn
label=
"立即提交
"
color=
"accent q-px-md"
style=
"font-weight:400 !important"
:loading=
"saveCourseLoading"
<q-btn
:label=
"BtnStr
"
color=
"accent q-px-md"
style=
"font-weight:400 !important"
:loading=
"saveCourseLoading"
@
click=
"saveCourse"
/>
</q-card-actions>
</q-card>
...
...
@@ -376,6 +377,7 @@
getTeacherDropDownList
,
getSchoolDropdown
,
saveClass
,
batchSaveClassPlan
,
getClassInfo
,
queryClassRoomList
}
from
'../../api/school/index'
...
...
@@ -489,6 +491,7 @@
checkedDays
:
[],
//默认上课时间数组
DefaultPlanTimeList
:
[],
BtnStr
:
"立即提交"
,
}
},
created
()
{
...
...
@@ -598,7 +601,7 @@
saveCourse
()
{
this
.
$refs
.
ClassName
.
validate
();
this
.
$refs
.
ClassPersion
.
validate
();
if
(
!
this
.
$refs
.
ClassName
.
hasError
&&
!
this
.
$refs
.
ClassPersion
.
hasError
)
{
if
(
this
.
objOption
.
IsOpenCommission
==
1
)
{
if
(
this
.
objOption
.
CommissionValue
==
''
)
{
...
...
@@ -610,6 +613,7 @@
return
;
}
}
this
.
BtnStr
=
"正在保存班级信息"
;
this
.
objOption
.
ClassStepPriceList
=
this
.
ladderPriceList
;
//选中的日期或星期
this
.
objOption
.
WeekDayList
=
this
.
checkedDays
;
...
...
@@ -617,16 +621,41 @@
this
.
objOption
.
DefaultPlanTimeList
=
this
.
DefaultPlanTimeList
;
this
.
saveCourseLoading
=
true
;
saveClass
(
this
.
objOption
).
then
(
res
=>
{
this
.
saveCourseLoading
=
false
this
.
$q
.
notify
({
icon
:
'iconfont icon-chenggong'
,
color
:
'accent'
,
timeout
:
2000
,
message
:
'数据保存成功!'
,
position
:
'top'
})
this
.
$emit
(
"success"
)
this
.
closeSaveForm
()
if
(
res
.
Code
==
1
)
{
//有上课计划
if
(
res
.
Data
&&
res
.
Data
.
ClassPlanList
&&
res
.
Data
.
ClassPlanList
.
length
>
0
)
{
this
.
BtnStr
=
"正在检查排班是否存在冲突"
;
var
newMsg
=
{
ClassId
:
res
.
Data
.
ClassId
,
PlanList
:
res
.
Data
.
ClassPlanList
,
}
batchSaveClassPlan
(
newMsg
).
then
(
res
=>
{
this
.
saveCourseLoading
=
false
if
(
res
.
Code
==
1
)
{
this
.
$q
.
notify
({
icon
:
'iconfont icon-chenggong'
,
color
:
'accent'
,
timeout
:
2000
,
message
:
'数据保存成功!'
,
position
:
'top'
})
this
.
$emit
(
"success"
)
this
.
closeCourseForm
()
}
})
}
else
{
this
.
saveCourseLoading
=
false
this
.
$q
.
notify
({
icon
:
'iconfont icon-chenggong'
,
color
:
'accent'
,
timeout
:
2000
,
message
:
'数据保存成功!'
,
position
:
'top'
})
this
.
$emit
(
"success"
)
this
.
closeCourseForm
()
}
}
}).
catch
(()
=>
{
this
.
saveCourseLoading
=
false
})
...
...
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