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
f7e1a9ed
Commit
f7e1a9ed
authored
Dec 25, 2020
by
黄奎
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
新增设置班级状态
parent
83ec657f
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
74 additions
and
22 deletions
+74
-22
class.js
src/api/course/class.js
+12
-0
index.js
src/api/school/index.js
+1
-11
classManage.vue
src/pages/course/classManage.vue
+61
-11
No files found.
src/api/course/class.js
View file @
f7e1a9ed
...
...
@@ -248,3 +248,15 @@ export function setTeachingPerfFinance(data) {
data
});
}
/**
* 修改班级状态
* @param {JSON数据} data
*/
export
function
saveClassStatus
(
data
)
{
return
request
({
url
:
'/Class/SetClassStatus'
,
method
:
'post'
,
data
})
}
\ No newline at end of file
src/api/school/index.js
View file @
f7e1a9ed
...
...
@@ -218,17 +218,7 @@ export function saveClass(data) {
})
}
/**
* 修改班级状态
* @param {JSON数据} data
*/
export
function
saveClassStatus
(
data
)
{
return
request
({
url
:
'/Class/SetClassStatus'
,
method
:
'post'
,
data
})
}
/**
* 新增修改班级
...
...
src/pages/course/classManage.vue
View file @
f7e1a9ed
...
...
@@ -8,7 +8,7 @@
</div>
<div
class=
"col-3"
>
<q-select
@
input=
"getClassList"
standout=
"bg-primary text-white"
option-value=
"Id"
option-label=
"Name"
v-model=
"msg.ClassStatus"
:options=
"classStatusList"
emit-value
map-options
label=
"
课程
状态"
/>
v-model=
"msg.ClassStatus"
:options=
"classStatusList"
emit-value
map-options
label=
"
班级
状态"
/>
</div>
<div
class=
"col-3"
>
<q-input
@
change=
"getClassList"
clearable
standout=
"bg-primary text-white"
v-model=
"msg.TeacherName"
...
...
@@ -65,6 +65,27 @@
style=
"background-color:#EEEEEF;color:#3FC4FF"
class=
"q-mt-sm"
/>
</q-td>
</
template
>
<!--班级状态-->
<
template
v-slot:body-cell-ClassStatusStr=
"props"
>
<span>
{{
props
.
row
.
ClassStatusStr
}}
</span>
<i
class=
"iconfont icon-edit"
@
click
.
stop=
"getClassItem(props.row)"
title=
"点击修改班级状态"
>
<q-popup-proxy>
<q-banner
v-if=
"isShowEdit"
>
<div
class=
"calenderDialog"
>
<div
style=
"margin:10px 0 15px 0;"
>
设置班级状态
</div>
<q-select
standout=
"bg-primary text-white"
option-value=
"Id"
option-label=
"Name"
v-model=
"statusMsg.ClassStatus"
:options=
"classStatusList"
emit-value
map-options
label=
"班级状态"
/>
<q-card-actions
align=
"right"
class=
"bg-white"
>
<q-btn
label=
"取消"
flat
color=
"grey-10"
@
click=
"isShowEdit=false"
style=
"font-weight:400 !important"
/>
<q-btn
label=
"确认"
color=
"accent q-px-md"
style=
"font-weight:400 !important"
@
click=
"setClassStatus()"
/>
</q-card-actions>
</div>
</q-banner>
</q-popup-proxy>
</i>
</
template
>
<
template
v-slot:bottom
>
<q-pagination
class=
"full-width justify-end"
v-model=
"msg.pageIndex"
color=
"primary"
:max=
"pageCount"
:input=
"true"
@
input=
"changePage"
/>
...
...
@@ -73,7 +94,8 @@
<q-td
:props=
"props"
>
<q-btn
flat
size=
"xs"
icon=
"edit"
color=
"accent"
style=
"font-weight:400"
label=
"订单中心"
@
click=
"gotoOrder(props.row)"
></q-btn>
<q-btn
flat
size=
"xs"
icon=
"edit"
color=
"accent"
@
click=
"goPayment(props.row)"
style=
"font-weight:400"
label=
"收支明细"
></q-btn>
<q-btn
flat
size=
"xs"
icon=
"edit"
color=
"accent"
@
click=
"goPayment(props.row)"
style=
"font-weight:400"
label=
"收支明细"
></q-btn>
<q-btn
flat
size=
"xs"
icon=
"edit"
color=
"accent"
style=
"font-weight:400"
label=
"编辑"
@
click=
"EditCourse(props.row)"
/>
</q-td>
...
...
@@ -90,8 +112,8 @@
import
{
queryClassPage
,
queryClassStatusList
,
saveClassStatus
,
//修改班级状态
}
from
'../../api/course/class'
;
//获取校区列表
import
{
getSchoolDropdown
...
...
@@ -182,11 +204,16 @@
pageCount
:
0
,
classObjOption
:
null
,
isShowClassInfo
:
false
,
//是否显示课程信息
isShowEdit
:
false
,
statusMsg
:
{
ClassId
:
0
,
ClassStatus
:
0
},
}
},
created
()
{
if
(
this
.
$route
.
query
)
{
this
.
msg
.
ClassName
=
this
.
$route
.
query
.
ClassName
if
(
this
.
$route
.
query
)
{
this
.
msg
.
ClassName
=
this
.
$route
.
query
.
ClassName
}
this
.
getClassStatus
();
this
.
getSchool
();
...
...
@@ -195,6 +222,29 @@
this
.
getClassList
();
},
methods
:
{
//当前点击的班级
getClassItem
(
item
)
{
this
.
isShowEdit
=
true
;
var
Obj
=
JSON
.
parse
(
JSON
.
stringify
(
item
));
this
.
statusMsg
.
ClassStatus
=
Obj
.
ClassStatus
;
this
.
statusMsg
.
ClassId
=
Obj
.
ClassId
;
},
//更新班级状态
setClassStatus
()
{
saveClassStatus
(
this
.
statusMsg
).
then
(
res
=>
{
this
.
isShowEdit
=
false
;
if
(
res
.
Code
==
1
)
{
this
.
$q
.
notify
({
icon
:
'iconfont icon-chenggong'
,
color
:
'accent'
,
timeout
:
2000
,
message
:
'设置成功!'
,
position
:
'top'
})
this
.
getClassList
();
}
});
},
gotoOrder
(
item
)
{
var
tempStr
=
'/course/classorder?ClassId='
+
item
.
ClassId
;
this
.
$router
.
push
({
...
...
@@ -202,13 +252,13 @@
});
},
//跳转到收支明细
goPayment
(
item
){
goPayment
(
item
)
{
this
.
$router
.
push
({
path
:
'paymentDetail'
,
query
:{
ClassId
:
item
.
ClassId
,
School_Id
:
item
.
School_Id
,
blank
:
'y'
path
:
'paymentDetail'
,
query
:
{
ClassId
:
item
.
ClassId
,
School_Id
:
item
.
School_Id
,
blank
:
'y'
}
})
},
...
...
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