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
b47abbe6
Commit
b47abbe6
authored
Mar 10, 2021
by
罗超
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改部分BUG
parent
32e61fc0
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
451 additions
and
272 deletions
+451
-272
quasar.conf.js
quasar.conf.js
+1
-1
course-form.vue
src/components/course/course-form.vue
+8
-3
catagory.vue
src/pages/course/catagory.vue
+57
-6
course.vue
src/pages/course/course.vue
+383
-261
user.js
src/store/modules/user.js
+2
-1
No files found.
quasar.conf.js
View file @
b47abbe6
...
@@ -48,7 +48,7 @@ module.exports = function (ctx) {
...
@@ -48,7 +48,7 @@ module.exports = function (ctx) {
build
:
{
build
:
{
vueRouterMode
:
'hash'
,
// available values: 'hash', 'history'
vueRouterMode
:
'hash'
,
// available values: 'hash', 'history'
env
:
ctx
.
dev
?
{
env
:
ctx
.
dev
?
{
API
:
'http://
192.168.1.27:8300
/api'
API
:
'http://
eduapi.oytour.com
/api'
}
:
{
}
:
{
API
:
'http://eduapi.oytour.com/api'
API
:
'http://eduapi.oytour.com/api'
},
},
...
...
src/components/course/course-form.vue
View file @
b47abbe6
...
@@ -351,8 +351,9 @@ export default {
...
@@ -351,8 +351,9 @@ export default {
this
.
getSaleplat
();
this
.
getSaleplat
();
},
},
mounted
()
{
mounted
()
{
this
.
getCategorytree
();
this
.
initObj
();
this
.
initObj
();
},
},
methods
:
{
methods
:
{
//获取教师下拉
//获取教师下拉
...
@@ -392,13 +393,14 @@ export default {
...
@@ -392,13 +393,14 @@ export default {
var
qMsg
=
{};
var
qMsg
=
{};
queryCourseCategoryTree
(
qMsg
).
then
(
res
=>
{
queryCourseCategoryTree
(
qMsg
).
then
(
res
=>
{
this
.
TreeCategoryList
=
res
.
Data
;
this
.
TreeCategoryList
=
res
.
Data
;
if
(
this
.
objOption
.
CateId
!=
0
){
console
.
log
(
this
.
objOption
.
CateId
,
this
.
TreeCategoryList
)
//if(this.objOption.CateId!=0){
this
.
TreeCategoryList
.
forEach
(
x
=>
{
this
.
TreeCategoryList
.
forEach
(
x
=>
{
if
(
x
.
CateId
==
this
.
objOption
.
CateId
){
if
(
x
.
CateId
==
this
.
objOption
.
CateId
){
this
.
chosenCateId
=
x
this
.
chosenCateId
=
x
}
}
})
})
}
//
}
});
});
},
},
//新增阶梯定价
//新增阶梯定价
...
@@ -452,6 +454,7 @@ export default {
...
@@ -452,6 +454,7 @@ export default {
this
.
choosePlat
=
res
.
Data
.
SalePlatList
;
this
.
choosePlat
=
res
.
Data
.
SalePlatList
;
}
}
this
.
defaultArray
.
push
(
res
.
Data
.
CateId
);
this
.
defaultArray
.
push
(
res
.
Data
.
CateId
);
this
.
getCategorytree
();
});
});
this
.
optionTitle
=
"修改课程信息"
;
this
.
optionTitle
=
"修改课程信息"
;
}
else
{
}
else
{
...
@@ -473,7 +476,9 @@ export default {
...
@@ -473,7 +476,9 @@ export default {
this
.
objOption
.
RenewSlPrice
=
0
;
this
.
objOption
.
RenewSlPrice
=
0
;
this
.
objOption
.
Saleplat
=
""
;
this
.
objOption
.
Saleplat
=
""
;
this
.
objOption
.
IsKCourse
=
0
;
this
.
objOption
.
IsKCourse
=
0
;
this
.
getCategorytree
();
}
}
},
},
//关闭弹窗
//关闭弹窗
closeCourseForm
()
{
closeCourseForm
()
{
...
...
src/pages/course/catagory.vue
View file @
b47abbe6
...
@@ -43,14 +43,18 @@
...
@@ -43,14 +43,18 @@
<q-badge
:color=
"props.value==1?'negative':'primary'"
:label=
"props.value==0?'正常':'禁用'"
/>
<q-badge
:color=
"props.value==1?'negative':'primary'"
:label=
"props.value==0?'正常':'禁用'"
/>
</q-td>
</q-td>
</
template
>
</
template
>
<
template
v-slot:body-cell-
optione
d=
"props"
>
<
template
v-slot:body-cell-
CateI
d=
"props"
>
<q-td
:props=
"props"
>
<q-td
:props=
"props"
>
<q-btn
flat
size=
"xs"
icon=
"edit"
color=
"accent"
style=
"font-weight:400"
label=
"编辑"
<q-btn
flat
size=
"xs"
icon=
"edit"
color=
"accent"
style=
"font-weight:400"
label=
"编辑"
@
click=
"EditCategory(props.row)"
/>
@
click=
"EditCategory(props.row)"
/>
<q-btn
flat
size=
"xs"
icon=
"
edit"
color=
"accent"
style=
"font-weight:400;display:none;"
label=
"详情
"
<q-btn
flat
size=
"xs"
icon=
"
delete"
color=
"negative"
style=
"font-weight:400;"
label=
"删除
"
@
click=
"deleteCategory(props.row
.CateId
)"
/>
@
click=
"deleteCategory(props.row)"
/>
</q-td>
</q-td>
</
template
>
</
template
>
<
template
v-slot:bottom
>
<q-pagination
class=
"full-width justify-end"
v-model=
"msg.PageIndex"
color=
"primary"
:max=
"msg.PageCount"
:input=
"true"
@
input=
"changePage"
/>
</
template
>
</q-table>
</q-table>
<category-form
v-if=
"isShowCategory"
:save-obj=
"categoryObj"
@
close=
"closeCagegoryForm"
@
success=
"refreshPage"
>
<category-form
v-if=
"isShowCategory"
:save-obj=
"categoryObj"
@
close=
"closeCagegoryForm"
@
success=
"refreshPage"
>
</category-form>
</category-form>
...
@@ -63,6 +67,7 @@
...
@@ -63,6 +67,7 @@
queryCourseCategoryPage
queryCourseCategoryPage
}
from
'../../api/course/index'
}
from
'../../api/course/index'
import
categoryForm
from
'../../components/course/category-form'
import
categoryForm
from
'../../components/course/category-form'
export
default
{
export
default
{
meta
:
{
meta
:
{
title
:
"课程系类"
title
:
"课程系类"
...
@@ -72,6 +77,11 @@
...
@@ -72,6 +77,11 @@
},
},
data
()
{
data
()
{
return
{
return
{
msg
:{
PageIndex
:
1
,
PageSize
:
20
,
PageCount
:
1
},
currentUrl
:
""
,
currentUrl
:
""
,
data
:
[],
data
:
[],
keyWords
:
''
,
keyWords
:
''
,
...
@@ -90,7 +100,8 @@
...
@@ -90,7 +100,8 @@
name
:
'CourseCount'
,
name
:
'CourseCount'
,
label
:
'关联课程'
,
label
:
'关联课程'
,
align
:
'left'
,
align
:
'left'
,
field
:
row
=>
row
.
CourseCount
field
:
row
=>
row
.
CourseCount
,
format
:
(
val
,
row
)
=>
`
${
val
}
个课程`
},
},
{
{
name
:
'Status'
,
name
:
'Status'
,
...
@@ -109,15 +120,54 @@
...
@@ -109,15 +120,54 @@
label
:
'修改时间'
,
label
:
'修改时间'
,
align
:
'left'
,
align
:
'left'
,
field
:
row
=>
row
.
UpdateTimeStr
field
:
row
=>
row
.
UpdateTimeStr
},
{
name
:
'CateId'
,
label
:
'操作'
,
field
:
'CateId'
}
}
],
],
}
}
},
},
mounted
()
{
mounted
()
{
this
.
currentUrl
=
this
.
$route
.
path
this
.
currentUrl
=
this
.
$route
.
path
this
.
getcoursecategorytree
()
this
.
getcoursecategorytree
()
},
},
methods
:
{
methods
:
{
changePage
(
val
)
{
this
.
msg
.
PageIndex
=
val
;
this
.
getcoursecategorytree
()
},
//删除系列
deleteCategory
(
item
)
{
let
delMsg
=
{
CateId
:
item
.
CateId
,
};
this
.
$q
.
dialog
({
title
:
'提示信息'
,
message
:
'是否确定删除该系列?'
,
cancel
:
true
,
persistent
:
true
,
ok
:
"确定"
,
cancel
:
"取消"
,
}).
onOk
(()
=>
{
deleteCourseCategory
(
delMsg
).
then
(
res
=>
{
if
(
res
.
Code
==
1
)
{
this
.
$q
.
notify
({
icon
:
'iconfont icon-chenggong'
,
color
:
'accent'
,
timeout
:
2000
,
message
:
'删除成功!'
,
position
:
'top'
})
this
.
refreshPage
();
}
})
}).
onCancel
(()
=>
{
});
},
//搜索分类
//搜索分类
myFilterMethod
(
node
,
filter
)
{
myFilterMethod
(
node
,
filter
)
{
return
node
.
CateName
&&
node
.
CateName
.
indexOf
(
filter
)
>
-
1
;
return
node
.
CateName
&&
node
.
CateName
.
indexOf
(
filter
)
>
-
1
;
...
@@ -135,12 +185,13 @@
...
@@ -135,12 +185,13 @@
getcoursecategorytree
()
{
getcoursecategorytree
()
{
this
.
isShow
=
false
;
this
.
isShow
=
false
;
queryCourseCategoryPage
({
queryCourseCategoryPage
({
PageSize
:
50
,
PageSize
:
this
.
msg
.
PageSize
,
pageIndex
:
1
PageIndex
:
this
.
msg
.
PageIndex
}).
then
(
res
=>
{
}).
then
(
res
=>
{
this
.
isShow
=
true
;
this
.
isShow
=
true
;
this
.
loading
=
false
;
this
.
loading
=
false
;
this
.
data
=
res
.
Data
.
PageData
;
this
.
data
=
res
.
Data
.
PageData
;
this
.
msg
.
PageCount
=
res
.
Data
.
PageCount
})
})
},
},
//新增修改角色
//新增修改角色
...
...
src/pages/course/course.vue
View file @
b47abbe6
This diff is collapsed.
Click to expand it.
src/store/modules/user.js
View file @
b47abbe6
...
@@ -8,6 +8,7 @@ const user = {
...
@@ -8,6 +8,7 @@ const user = {
userInfo
:
null
,
// 用户信息
userInfo
:
null
,
// 用户信息
//TODO 用户权限
//TODO 用户权限
allAuth
:
[
'/home'
,
'/school/manager'
],
allAuth
:
[
'/home'
,
'/school/manager'
],
actionList
:[]
},
},
mutations
:
{
mutations
:
{
...
@@ -16,7 +17,7 @@ const user = {
...
@@ -16,7 +17,7 @@ const user = {
},
},
SET_ALLAUTH
:
(
state
,
allAuth
)
=>
{
SET_ALLAUTH
:
(
state
,
allAuth
)
=>
{
state
.
allAuth
=
allAuth
state
.
allAuth
=
allAuth
}
,
}
//TODO 用户权限
//TODO 用户权限
},
},
...
...
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