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
9d4249e8
Commit
9d4249e8
authored
Jul 02, 2024
by
吴春
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
学生问卷调查
parent
20acf0c7
Hide whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
1154 additions
and
1 deletion
+1154
-1
common.js
src/api/common/common.js
+96
-0
index.js
src/api/school/index.js
+24
-0
permission.js
src/boot/permission.js
+1
-1
stufollowlistNew.vue
src/components/school/student/stufollowlistNew.vue
+81
-0
survey-form.vue
src/components/system/survey-form.vue
+170
-0
surveyStudentList-form.vue
src/components/system/surveyStudentList-form.vue
+128
-0
survey.vue
src/pages/system/survey.vue
+199
-0
surveyStudent.vue
src/pages/system/surveyStudent.vue
+289
-0
surveyStudentList.vue
src/pages/system/surveyStudentList.vue
+150
-0
routes.js
src/router/routes.js
+16
-0
No files found.
src/api/common/common.js
View file @
9d4249e8
...
...
@@ -434,6 +434,102 @@ export function saveArea(data) {
})
}
/**
* 获取学生问卷调查信息分页列表
*/
export
function
querySurveyPage
(
data
)
{
return
request
({
url
:
'/Survey/GetPageList'
,
method
:
'post'
,
data
})
}
/**
* 根据编号获取学生问卷调查信息详情
*/
export
function
querySurveyInfo
(
data
)
{
return
request
({
url
:
'/Survey/GetSurvey'
,
method
:
'post'
,
data
})
}
/**
* 根据编号获取学生问卷调查信息详情
*/
export
function
queryGuestSurvey
(
data
)
{
return
request
({
url
:
'/Survey/GetGuestSurvey'
,
method
:
'post'
,
data
})
}
/**
* 根据编号删除学生问卷调查信息
*/
export
function
deleteSurvey
(
data
)
{
return
request
({
url
:
'/Survey/DelSurvey'
,
method
:
'post'
,
data
})
}
/**
* 新增修改学生问卷调查信息
*/
export
function
saveSurvey
(
data
)
{
return
request
({
url
:
'/Survey/SetSurvey'
,
method
:
'post'
,
data
})
}
/**
* 获取意见调查表表格内容
*/
export
function
querySurveyShowList
(
data
)
{
return
request
({
url
:
'/Survey/GetSurveyShowList'
,
method
:
'post'
,
data
})
}
/**
* 获取学生问卷调查信息分页列表
*/
export
function
queryStudentSurveyPage
(
data
)
{
return
request
({
url
:
'/Survey/GetStudentSurveyPage'
,
method
:
'post'
,
data
})
}
/**
* 填写意见调查表信息
*/
export
function
setEducationSurvey
(
data
)
{
return
request
({
url
:
'/Survey/SetEducationSurvey'
,
method
:
'post'
,
data
})
}
/**
* 问卷调查类型枚举信息
*/
export
function
querySurveyTypeEnumList
(
data
)
{
return
request
({
url
:
'/Survey/GetSurveyTypeEnumList'
,
method
:
'post'
,
data
})
}
/**
* 获取文件扩展名
*/
...
...
src/api/school/index.js
View file @
9d4249e8
...
...
@@ -82,6 +82,17 @@ export function getTeacherDropDownList(data) {
})
}
/**
* 获取讲师列表
*/
export
function
getTeacherListByGroupId
(
data
)
{
return
request
({
url
:
'/user/GetTeacherListByGroupId'
,
method
:
'post'
,
data
})
}
/**
* 保存教师信息
*/
...
...
@@ -338,6 +349,19 @@ export function saveStudentBaseInfo(data) {
})
}
/**
* 问卷调查二维码
*/
export
function
queryQrCodeImage
(
data
)
{
return
request
({
url
:
'/Survey/GetQrCodeImage'
,
method
:
'post'
,
data
})
}
/**
* 获取客户阶段列表
*/
...
...
src/boot/permission.js
View file @
9d4249e8
...
...
@@ -8,7 +8,7 @@ LoadingBar.setDefaults({
position
:
"bottom"
});
let
loadAsyncRouter
=
false
;
const
whiteList
=
[
"/login"
,
"uploadFiles"
,
"/"
,
"/contractConfirm"
,
"/contractPay"
,
"/contractView"
,
"/contractSign"
,
"/noticeView"
,
"/autologin"
,
"/courseRefundH5"
,
"/koreaUpload"
,
"/uploadFiles"
];
// 不重定向白名单
const
whiteList
=
[
"/login"
,
"uploadFiles"
,
"/"
,
"/contractConfirm"
,
"/contractPay"
,
"/contractView"
,
"/contractSign"
,
"/noticeView"
,
"/autologin"
,
"/courseRefundH5"
,
"/koreaUpload"
,
"/uploadFiles"
,
"/system/surveyStudent"
];
// 不重定向白名单
router
.
beforeEach
((
to
,
from
,
next
)
=>
{
localStorage
.
setItem
(
"routerBefore"
,
from
.
path
);
LoadingBar
.
start
();
...
...
src/components/school/student/stufollowlistNew.vue
View file @
9d4249e8
...
...
@@ -175,6 +175,27 @@
<div
class=
"text-blue cursor-pointer"
@
click=
"getStudentStudy(item)"
>
学习情况
</div>
<!-- <div class="text-blue cursor-pointer" @click="getStudentSurvey(item)">
问卷调查
</div> -->
<div
class=
"text-blue cursor-pointer"
>
<div
push
flat
color=
"text-blue cursor-pointer"
@
click=
"getStudentSurveyImg(item,index)"
>
问卷调查
<q-popup-proxy>
<div
style=
"width:185px;padding:10px;border-radius:8px"
>
<q-img
:src=
"item.QrCodeUrl"
>
<
template
v-slot:loading
>
<div
class=
"text-subtitle1 text-white"
>
Loading...
</div>
</
template
>
</q-img>
</div>
</q-popup-proxy>
</div>
</div>
</td>
</tr>
</template>
...
...
@@ -186,6 +207,12 @@
style=
"width: 100%;border:1px solid #E6E6E6;display: flex;align-items: center;justify-content: center;height: 60px;"
>
暂无数据
</div>
<studentRight-form
v-if=
"isShowStuRight"
:BelongType=
"BelongType"
:save-obj=
"stuOption"
@
close=
"closeStuForm"
@
success=
"refreshTable"
>
</studentRight-form>
...
...
@@ -229,6 +256,23 @@
</q-card-actions>
</q-card>
</q-dialog>
<q-dialog
v-if=
"isShowQrCode"
>
<
template
>
<div
class=
"q-pa-md"
>
<q-img
:src=
"QrCodeUrl"
style=
"height: 140px; max-width: 150px"
>
<template
v-slot:loading
>
<div
class=
"text-subtitle1 text-white"
>
Loading...
</div>
</
template
>
</q-img>
</div>
</template>
</q-dialog>
</div>
</template>
<
script
>
...
...
@@ -239,6 +283,7 @@
}
from
"../../../api/sale/sale"
;
import
{
saveStudentBaseInfo
,
//保存学员信息
queryQrCodeImage
,
//问卷调查二维码生成
}
from
"../../../api/school/index"
;
import
UeEditor
from
"../../editor/UeEditor"
;
export
default
{
...
...
@@ -277,6 +322,8 @@
isShowStuFU
:
false
,
isShowStuRight
:
false
,
isShowStuBaseInfo
:
false
,
isShowQrCode
:
false
,
QrCodeUrl
:
""
,
stuloading
:
false
,
//学习目的列表
goalsList
:
[],
...
...
@@ -347,6 +394,40 @@
};
this
.
OpenNewUrl
(
'/teacher/studentStudy'
,
qObj
)
},
//点击生成二维码
getStudentSurveyImg
(
obj
,
index
)
{
// console.log(this.$refs.qDateProxy[index],'--');
// this.$refs.qDateProxy[index].show()
if
(
this
.
dataObj
.
RList
[
index
].
QrCodeUrl
===
""
)
{
let
codeMsg
=
{
pUrl
:
"system/surveyStudent"
,
StudentId
:
obj
.
StuId
,
StuName
:
obj
.
StuName
}
queryQrCodeImage
(
codeMsg
).
then
(
res
=>
{
if
(
res
.
Code
==
1
)
{
this
.
isShowQrCode
=
true
;
this
.
dataObj
.
RList
[
index
].
QrCodeUrl
=
"data:image/png;base64,"
+
res
.
Data
console
.
log
(
"res"
,
res
);
// this.stuloading = false;
// this.isShowStuBaseInfo = false;
codeMsg
=
{};
}
});
}
},
//点击生成二维码,先跳转到页面吧
getStudentSurvey
(
obj
)
{
let
nowUserInfo
=
JSON
.
parse
(
localStorage
.
getItem
(
"loginUserInfo"
)).
data
var
qObj
=
{
StuId
:
obj
.
StuId
,
StuName
:
obj
.
StuName
,
GuestId
:
obj
.
GuestId
,
CourseRateName
:
obj
.
CourseRateName
,
Group_Id
:
nowUserInfo
.
Group_Id
};
this
.
OpenNewUrl
(
'/system/surveyStudent'
,
qObj
)
},
//清除
clearMsg
()
{
this
.
customObj
.
Remark
=
""
;
...
...
src/components/system/survey-form.vue
0 → 100644
View file @
9d4249e8
<
template
>
<q-dialog
v-model=
"persistent"
content-class=
"bg-grey-1"
persistent
transition-show=
"scale"
transition-hide=
"scale"
>
<q-card
style=
"width: 800px;max-width:900px;"
>
<q-card-section>
<div
class=
"text-h6"
>
{{
objOption
.
MenuId
==
0
?
'新增学生问卷调查信息'
:
'修改学生问卷调查信息'
}}
</div>
</q-card-section>
<q-card-section
class=
"q-pt-none scroll"
style=
"max-height: 70vh"
>
<div
class=
"text-caption q-mb-lg q-px-md text-grey-6"
>
学生问卷调查信息
</div>
<div
class=
"row wrap"
>
<q-input
filled
stack-label
maxlength=
"20"
:dense=
"false"
v-model=
"objOption.Title"
ref=
"Title"
class=
"col-6 q-pr-lg q-pb-lg"
label=
"问题名称"
:rules=
"[val => !!val || '请填问题名称']"
/>
<q-select
filled
stack-label
class=
"col-6 q-pr-lg"
option-value=
"Id"
option-label=
"Name"
v-model=
"objOption.SurveyType"
:options=
"SurveyTypeEnumList"
emit-value
map-options
label=
"问题类型"
@
input=
"changeType()"
/>
</div>
<div
class=
"row wrap"
>
<q-field
label=
"是否显示"
stack-label
filled
class=
"col-6 q-pr-lg q-pb-lg"
>
<template
v-slot:control
>
<div
class=
"row col-12"
>
<q-radio
v-model=
"objOption.IsShow"
:val=
"1"
label=
"显示"
size=
"xs"
/>
<q-radio
v-model=
"objOption.IsShow"
:val=
"0"
label=
"不显示"
size=
"xs"
/>
</div>
</
template
>
</q-field>
<q-input
filled
stack-label
maxlength=
"20"
:dense=
"false"
v-model=
"objOption.Sort"
class=
"col-6 q-pr-lg q-pb-lg"
label=
"排序"
:rules=
"[val => !!val || '请输入排序']"
/>
</div>
<
template
v-if=
"objOption.SurveyType==2||objOption.SurveyType==3"
>
增加选项
<q-btn
round
dense
flat
icon=
"add"
@
click=
"addSurveyOptions"
/>
<div
v-for=
"(sItem,sIndex) in objOption.SurveyOptionsList"
:key=
"sIndex"
>
<div
class=
"row wrap"
>
<q-input
filled
class=
"col-6 q-pr-lg q-pb-lg"
v-model=
"sItem.OptionsName"
:label=
"`选项$
{sIndex+1}`" :dense="false">
</q-input>
<q-input
filled
stack-label
:dense=
"false"
v-model=
"sItem.Sort"
class=
"col-4 q-pr-lg q-pb-lg"
label=
"排序"
:rules=
"[val => !!val || '请输入排序']"
>
<template
v-slot:append
>
<q-btn
round
dense
flat
icon=
"delete"
@
click=
"delSurveyOptions(sIndex)"
/>
</
template
>
</q-input>
</div>
</div>
</template>
</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=
"closeSaveForm"
/>
<q-btn
label=
"立即提交"
color=
"accent q-px-md"
style=
"font-weight:400 !important"
:loading=
"saveLoading"
@
click=
"setSurvey"
/>
</q-card-actions>
</q-card>
</q-dialog>
</template>
<
script
>
import
{
querySurveyTypeEnumList
,
saveSurvey
,
querySurveyInfo
}
from
'../../api/common/common'
export
default
{
props
:
{
saveObj
:
{
type
:
Object
,
default
:
null
}
},
data
()
{
return
{
persistent
:
true
,
objOption
:
{
ID
:
0
,
//编号
Title
:
""
,
//问题名称
SurveyType
:
1
,
//问题类型见枚举参数
Sort
:
0
,
//排序
IsShow
:
1
,
//0-不显示,1-显示
SurveyOptionsList
:[],
},
optionTitle
:
""
,
SurveyTypeEnumList
:
[],
//问题类型
saveLoading
:
false
,
SurveyOptionsItem
:{
ID
:
0
,
OptionsName
:
""
,
Sort
:
0
,
}
}
},
created
()
{
this
.
getSurveyTypeEnumList
();
},
mounted
()
{
this
.
initObj
()
},
methods
:
{
delSurveyOptions
(
index
){
this
.
objOption
.
SurveyOptionsList
.
splice
(
index
,
1
);
},
addSurveyOptions
(){
this
.
objOption
.
SurveyOptionsList
.
push
(
JSON
.
parse
(
JSON
.
stringify
(
this
.
SurveyOptionsItem
)));
},
//获取类型列表
getSurveyTypeEnumList
()
{
querySurveyTypeEnumList
({}).
then
(
res
=>
{
this
.
SurveyTypeEnumList
=
res
.
Data
;
})
},
//类型切换
changeType
()
{
this
.
objOption
.
CountryId
=
""
;
this
.
objOption
.
ProviceId
=
""
;
this
.
objOption
.
CityId
=
""
;
},
//初始化表单
initObj
()
{
if
(
this
.
saveObj
&&
this
.
saveObj
.
ID
>
0
)
{
querySurveyInfo
({
SurveyID
:
this
.
saveObj
.
ID
}).
then
(
res
=>
{
var
tempData
=
res
.
Data
;
this
.
objOption
.
ID
=
tempData
.
ID
;
this
.
objOption
.
Title
=
tempData
.
Title
;
this
.
objOption
.
SurveyType
=
tempData
.
SurveyType
;
this
.
objOption
.
Sort
=
tempData
.
Sort
;
this
.
objOption
.
IsShow
=
tempData
.
IsShow
;
this
.
objOption
.
SurveyOptionsList
=
tempData
.
SurveyOptionsList
;
})
this
.
optionTitle
=
"修改学生意见调查"
}
else
{
this
.
optionTitle
=
"新增学生意见调查"
this
.
objOption
.
ID
=
0
;
this
.
objOption
.
Title
=
''
;
this
.
objOption
.
SurveyType
=
1
;
this
.
objOption
.
Sort
=
0
;
this
.
objOption
.
IsShow
=
1
;
this
.
objOption
.
SurveyOptionsList
=
[];
}
},
//关闭弹窗
closeSaveForm
()
{
this
.
$emit
(
'close'
)
this
.
persistent
=
false
},
//保存菜单
setSurvey
()
{
this
.
saveLoading
=
true
;
saveSurvey
(
this
.
objOption
).
then
(
res
=>
{
this
.
saveLoading
=
false
this
.
$q
.
notify
({
icon
:
'iconfont icon-chenggong'
,
color
:
'accent'
,
timeout
:
2000
,
message
:
'数据保存成功!'
,
position
:
'top'
})
this
.
$emit
(
"success"
)
this
.
closeSaveForm
()
}).
catch
(()
=>
{
this
.
saveLoading
=
false
})
}
},
}
</
script
>
\ No newline at end of file
src/components/system/surveyStudentList-form.vue
0 → 100644
View file @
9d4249e8
<
template
>
<q-dialog
v-model=
"persistent"
content-class=
"bg-grey-1"
persistent
transition-show=
"scale"
transition-hide=
"scale"
>
<q-card
style=
"width: 800px;max-width:900px;"
>
<q-card-section>
<div
class=
"text-h6"
>
老师上课质量调查问卷
</div>
</q-card-section>
<q-card-section
class=
"q-pt-none scroll"
style=
"max-height: 70vh"
>
<div
class=
"text-caption q-mb-lg q-px-md text-grey-6"
>
老师上课质量调查问卷
</div>
<div
class=
"row wrap"
style=
"margin-bottom:10px;"
>
<div
class=
"col-12"
>
<div
style=
"float:left;"
>
【
{{
saveObj
.
StudentName
}}
】选择评价的老师:
</div>
<div
style=
"text-decoration:underline;"
>
{{
saveObj
.
TeacherName
}}
</div>
</div>
</div>
<template
v-if=
"data&&data.length>0"
>
<div
v-for=
"(item,index) in data"
>
<div>
{{
index
+
1
}}
、
{{
item
.
Title
}}
</div>
<div
class=
"row wrap"
>
<div
class=
"col-12"
>
<template
v-if=
"item.SurveyType === 1"
>
<q-rating
v-model=
"item.ScoreNum"
size=
"1.5em"
icon=
"thumb_up"
min=
"1"
readonly
/>
<span
class=
"ratestyle"
v-if=
"item.ScoreNum==5"
>
非常满意
</span>
<span
class=
"ratestyle"
v-if=
"item.ScoreNum==4"
>
满意
</span>
<span
class=
"ratestyle"
v-if=
"item.ScoreNum==3"
>
感觉一般
</span>
<span
class=
"ratestyle"
v-if=
"item.ScoreNum==2"
>
不满意
</span>
<span
class=
"ratestyle"
v-if=
"item.ScoreNum==1"
>
非常不满意
</span>
</
template
>
<
template
v-if=
"item.SurveyType === 2"
>
<div
class=
"q-gutter-sm"
>
<q-list>
<q-radio
v-for=
"(radio, rIndex) in item.SurveyOptionsList"
:key=
"rIndex"
disable
v-model=
"item.ScoreNum"
:label=
"radio.OptionsName"
:val=
"radio.ID"
/>
</q-list>
</div>
</
template
>
<
template
v-if=
"item.SurveyType === 3"
>
<div
class=
"q-gutter-sm"
>
<q-list>
<q-checkbox
v-for=
"(radio, rIndex) in item.SurveyOptionsList"
disable
:key=
"rIndex"
v-model=
"item.CheckInfo"
:val=
"radio.ID"
:label=
"radio.OptionsName"
/>
</q-list>
</div>
</
template
>
<
template
v-if=
"item.SurveyType === 4"
>
<q-input
type=
"textarea"
:rows=
"2"
:placeholder=
"$t('fnc.qsrneirong')"
v-model=
"item.TextContent"
disable
>
</q-input>
</
template
>
</div>
</div>
</div>
</template>
</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=
"closeSaveForm"
/>
</q-card-actions>
</q-card>
</q-dialog>
</template>
<
script
>
import
{
querySurveyTypeEnumList
,
saveSurvey
,
queryGuestSurvey
}
from
'../../api/common/common'
export
default
{
props
:
{
saveObj
:
{
type
:
Object
,
default
:
null
}
},
data
()
{
return
{
persistent
:
true
,
data
:[],
optionTitle
:
""
,
SurveyTypeEnumList
:
[],
//问题类型
saveLoading
:
false
,
}
},
created
()
{
this
.
getSurveyTypeEnumList
();
},
mounted
()
{
this
.
initObj
()
},
methods
:
{
//获取类型列表
getSurveyTypeEnumList
()
{
querySurveyTypeEnumList
({}).
then
(
res
=>
{
this
.
SurveyTypeEnumList
=
res
.
Data
;
})
},
//初始化表单
initObj
()
{
if
(
this
.
saveObj
&&
this
.
saveObj
.
ID
>
0
)
{
queryGuestSurvey
({
SurveyID
:
this
.
saveObj
.
ID
}).
then
(
res
=>
{
this
.
data
=
res
.
Data
;
})
}
},
//关闭弹窗
closeSaveForm
()
{
this
.
$emit
(
'close'
)
this
.
persistent
=
false
},
},
}
</
script
>
\ No newline at end of file
src/pages/system/survey.vue
0 → 100644
View file @
9d4249e8
<
template
>
<div
class=
"page-body"
>
<div
class=
"page-search row items-center"
>
<div
class=
"col row wrap q-mr-lg q-col-gutter-md"
>
<div
class=
"col-3"
>
<q-input
@
input=
"resetSearch"
clearable
standout=
"bg-primary text-white"
class=
"col-6 q-pr-lg q-pr-lg"
v-model=
"msg.Title"
label=
"问题名称"
maxlength=
"20"
@
clear=
"resetSearch"
/>
</div>
<div
class=
"col-3"
>
<q-select
filled
stack-label
class=
"col-6 q-pr-lg"
option-value=
"Id"
option-label=
"Name"
v-model=
"msg.SurveyType"
:options=
"SurveyTypeEnumList"
emit-value
map-options
label=
"问题类型"
@
input=
"refreshPage()"
/>
</div>
<div
class=
"col-3"
>
<q-select
filled
stack-label
class=
"col-6 q-pr-lg"
option-value=
"Id"
option-label=
"Name"
v-model=
"msg.IsShow"
:options=
"ShowList"
emit-value
map-options
label=
"是否显示"
@
input=
"refreshPage()"
/>
</div>
</div>
</div>
<div
class=
"page-content"
>
<q-table
:pagination=
"msg"
:loading=
"loading"
no-data-label=
"暂无相关数据"
flat
class=
"sticky-tow-column-table"
separator=
"none"
:data=
"data"
:columns=
"columns"
row-key=
"name"
>
<template
v-slot:top=
"props"
>
<div
class=
"col-2 q-table__title"
>
问卷调查信息
</div>
<q-space
/>
<div
class=
"page-option"
>
<q-btn
color=
"accent"
class=
"q-mr-md"
size=
"sm"
icon=
"add"
label=
"新增"
@
click=
"editSurvey(null)"
/>
</div>
</
template
>
<
template
v-slot:bottom
>
<q-pagination
class=
"full-width justify-end"
v-model=
"msg.pageIndex"
color=
"primary"
:max=
"pageCount"
:input=
"true"
@
input=
"changePage"
/>
</
template
>
<
template
v-slot:body-cell-optioned=
"props"
>
<q-td
:props=
"props"
>
<q-btn
flat
size=
"xs"
icon=
"edit"
color=
"accent"
style=
"font-weight:400"
label=
"编辑"
@
click=
"editSurvey(props.row)"
/>
<q-btn
flat
size=
"xs"
icon=
"delete"
color=
"negative"
style=
"font-weight:400"
label=
"删除"
@
click=
"delSurvey(props.row)"
/>
</q-td>
</
template
>
</q-table>
<area-form
v-if=
"isShowAreaForm"
:save-obj=
"areaObjOption"
@
close=
"refreshPage"
@
success=
"refreshPage"
>
</area-form>
</div>
</div>
</template>
<
script
>
import
{
querySurveyPage
,
deleteSurvey
,
querySurveyTypeEnumList
}
from
'../../api/common/common'
import
areaForm
from
'../../components/system/survey-form'
export
default
{
meta
:
{
title
:
"学生问卷调查管理"
},
components
:
{
areaForm
,
},
data
()
{
return
{
currentUrl
:
""
,
columns
:
[
{
name
:
'Title'
,
label
:
'问题名称'
,
field
:
'Title'
,
align
:
'left'
},
{
name
:
'SurveyTypeStr'
,
label
:
'类型'
,
field
:
'SurveyTypeStr'
,
align
:
'left'
},
{
name
:
'Sort'
,
label
:
'排序'
,
field
:
'Sort'
,
align
:
'left'
},
{
name
:
'IsShow'
,
required
:
true
,
label
:
'是否显示'
,
align
:
'left'
,
field
:
row
=>
row
.
IsShow
==
1
?
'显示'
:
"不显示"
},
{
name
:
'optioned'
,
label
:
'操作'
,
field
:
'MenuId'
}
],
data
:
[],
loading
:
true
,
msg
:
{
pageIndex
:
1
,
pageSize
:
12
,
rowsPerPage
:
12
,
Title
:
""
,
SurveyType
:
-
1
,
IsShow
:
-
1
,
},
pageCount
:
0
,
isShowAreaForm
:
false
,
//是否显示新增修改地区表单
areaObjOption
:
null
,
SurveyTypeEnumList
:
[],
//问题类型
ShowList
:
[{
Id
:
-
1
,
Name
:
'不限'
},{
Id
:
1
,
Name
:
'显示'
},{
Id
:
0
,
Name
:
'不显示'
}],
//问题类型
}
},
mounted
()
{
this
.
currentUrl
=
this
.
$route
.
path
this
.
getSurveypage
();
this
.
getSurveyTypeEnumList
();
},
methods
:
{
//获取类型列表
getSurveyTypeEnumList
()
{
querySurveyTypeEnumList
({}).
then
(
res
=>
{
res
.
Data
.
unshift
({
Id
:
-
1
,
Name
:
"不限"
});
this
.
SurveyTypeEnumList
=
res
.
Data
;
})
},
//删除问卷调查信息
delSurvey
(
item
)
{
var
that
=
this
;
this
.
$q
.
dialog
({
title
:
'提示信息'
,
message
:
'是否确定删除?'
,
cancel
:
true
,
persistent
:
true
,
ok
:
"确定"
,
cancel
:
"取消"
,
}).
onOk
(()
=>
{
let
delMsg
=
{
SurveyID
:
item
.
ID
,
}
deleteSurvey
(
delMsg
).
then
(
res
=>
{
if
(
res
.
Code
==
1
)
{
that
.
$q
.
notify
({
icon
:
'iconfont icon-chenggong'
,
color
:
'accent'
,
timeout
:
2000
,
message
:
'操作成功'
,
position
:
'top'
})
that
.
refreshPage
();
}
})
})
},
//刷新页面
refreshPage
()
{
this
.
isShowAreaForm
=
false
;
this
.
areaObjOption
=
null
;
this
.
getSurveypage
();
},
//新增修改学生调查
editSurvey
(
obj
)
{
if
(
obj
!=
null
)
{
this
.
areaObjOption
=
obj
;
}
this
.
isShowAreaForm
=
true
;
},
//重新查询
resetSearch
()
{
this
.
msg
.
pageIndex
=
1
;
this
.
getSurveypage
();
},
//翻页
changePage
(
val
)
{
this
.
msg
.
pageIndex
=
val
;
this
.
getSurveypage
()
},
//获取地区分页列表
getSurveypage
()
{
this
.
loading
=
true
;
querySurveyPage
(
this
.
msg
).
then
(
res
=>
{
this
.
loading
=
false
this
.
data
=
res
.
Data
.
PageData
this
.
pageCount
=
res
.
Data
.
PageCount
}).
catch
(()
=>
{
this
.
loading
=
false
})
},
}
}
</
script
>
<
style
lang=
"sass"
>
@import
url('~assets/css/table.sass')
</
style
>
\ No newline at end of file
src/pages/system/surveyStudent.vue
0 → 100644
View file @
9d4249e8
<
template
>
<div
class=
"page-body"
style=
"width: auto;height:150%;"
>
<div
class=
"page-content"
>
<div
class=
"col-2 q-table__title"
style=
"text-align:center;"
>
老师上课质量调查问卷
</div>
<div
v-if=
"loadingCG"
>
<div
class=
"row wrap"
style=
"margin:10px 0px;"
>
<div
class=
"col-12"
>
亲爱的
{{
addMsg
.
StuName
}}
同学,为了提高老师上课的教学质量,请您完成对任课老师的评价。
</div>
</div>
<div
class=
"row wrap"
>
<div
class=
"col-12"
>
<q-select
filled
v-model=
"addMsg.TeacherId"
use-input
:dense=
"false"
ref=
"Teacher_Id"
label=
"您选择评价的老师:"
option-value=
"TId"
option-label=
"TeacherName"
:options=
"TeacherList"
@
filter=
"filterFnTeacher"
class=
"col-6 q-pb-lg"
emit-value
map-options
>
<template
v-slot:no-option
>
<q-item>
<q-item-section
class=
"text-grey"
>
No results
</q-item-section>
</q-item>
</
template
>
</q-select>
</div>
</div>
<
template
v-if=
"data&&data.length>0"
>
<div
v-for=
"(item,index) in data"
>
<div>
{{
index
+
1
}}
、
{{
item
.
Title
}}
</div>
<div
class=
"row wrap"
>
<div
class=
"col-12"
>
<template
v-if=
"item.SurveyType === 1"
>
<q-rating
v-model=
"item.ScoreNum"
size=
"1.5em"
icon=
"thumb_up"
min=
"1"
style=
"margin-bottom:15px;margin-top:10px;"
/>
<span
class=
"ratestyle"
v-if=
"item.ScoreNum==5"
>
非常满意
</span>
<span
class=
"ratestyle"
v-if=
"item.ScoreNum==4"
>
满意
</span>
<span
class=
"ratestyle"
v-if=
"item.ScoreNum==3"
>
感觉一般
</span>
<span
class=
"ratestyle"
v-if=
"item.ScoreNum==2"
>
不满意
</span>
<span
class=
"ratestyle"
v-if=
"item.ScoreNum==1"
>
非常不满意
</span>
</
template
>
<
template
v-if=
"item.SurveyType === 2"
>
<div
class=
"q-gutter-sm"
>
<q-list>
<q-radio
v-for=
"(radio, rIndex) in item.SurveyOptionsList"
:key=
"rIndex"
v-model=
"item.ScoreNum"
:label=
"radio.OptionsName"
:val=
"radio.ID"
/>
</q-list>
</div>
</
template
>
<
template
v-if=
"item.SurveyType === 3"
>
<div
class=
"q-gutter-sm"
>
<q-list>
<q-checkbox
v-for=
"(radio, rIndex) in item.SurveyOptionsList"
:key=
"rIndex"
v-model=
"item.CheckInfo"
:val=
"radio.ID"
:label=
"radio.OptionsName"
/>
</q-list>
</div>
</
template
>
<
template
v-if=
"item.SurveyType === 4"
>
<q-input
type=
"textarea"
:rows=
"2"
:placeholder=
"$t('fnc.qsrneirong')"
v-model=
"item.TextContent"
style=
"margin-bottom:15px;"
>
</q-input>
</
template
>
</div>
</div>
</div>
</template>
<q-card-actions
align=
"right"
class=
"bg-white"
>
<q-btn
label=
"取消"
flat
color=
"grey-10"
style=
"font-weight:400 !important"
/>
<q-btn
label=
"立即提交"
color=
"accent q-px-md"
style=
"font-weight:400 !important"
@
click=
"setSurveyStudent"
/>
</q-card-actions>
</div>
<div
v-else
>
<div
class=
"row wrap"
style=
"margin:10px 0px;text-align:center; "
>
<div
class=
"col-12"
>
亲爱的{{addMsg.StuName}}同学,感谢您对任课老师{{addMsg.TeacherName}}的评价。
</div>
</div>
</div>
</div>
</div>
</template>
<
script
>
import
{
querySurveyShowList
,
setEducationSurvey
}
from
'../../api/common/common'
import
{
getTeacherListByGroupId
}
from
'../../api/school/index'
export
default
{
meta
:
{
title
:
"老师上课质量调查问卷"
},
components
:
{
},
data
()
{
return
{
currentUrl
:
""
,
data
:
[],
loading
:
true
,
loadingCG
:
true
,
msg
:
{
RB_Group_Id
:
0
,
},
TeacherList
:
[],
//关联教师下拉数据
AllTeacherList
:
[],
//关联教师下拉数据
addMsg
:
{
TeacherId
:
0
,
StuName
:
""
,
TeacherName
:
""
,
StudentId
:
0
,
SurveyList
:[],
}
}
},
mounted
()
{
this
.
currentUrl
=
this
.
$route
.
path
if
(
this
.
$route
.
query
&&
this
.
$route
.
query
.
StuId
)
{
this
.
addMsg
.
StudentId
=
this
.
$route
.
query
.
StuId
}
if
(
this
.
$route
.
query
&&
this
.
$route
.
query
.
Group_Id
){
this
.
msg
.
RB_Group_Id
=
this
.
$route
.
query
.
Group_Id
}
if
(
this
.
$route
.
query
&&
this
.
$route
.
query
.
StuName
){
this
.
addMsg
.
StuName
=
decodeURIComponent
(
this
.
$route
.
query
.
StuName
)
}
this
.
GetTeacherList
();
this
.
getSurveyShowList
();
},
methods
:
{
filterFnTeacher
(
val
,
update
)
{
update
(()
=>
{
if
(
val
===
""
)
{
this
.
TeacherList
=
JSON
.
parse
(
JSON
.
stringify
(
this
.
AllTeacherList
));
}
else
{
const
needle
=
val
.
toLowerCase
();
this
.
TeacherList
=
this
.
AllTeacherList
.
filter
(
(
v
)
=>
v
.
TeacherName
.
toLowerCase
().
indexOf
(
needle
)
>
-
1
);
}
});
},
//保存菜单
setSurveyStudent
()
{
this
.
saveLoading
=
true
;
this
.
addMsg
.
SurveyList
=
[];
if
(
this
.
addMsg
.
TeacherId
===
""
||
this
.
addMsg
.
TeacherId
==
0
)
{
this
.
$q
.
notify
({
type
:
"negative"
,
position
:
"top"
,
message
:
`请选择您评价的老师!`
});
return
;
}
let
teacherObj
=
this
.
AllTeacherList
.
find
(
item
=>
item
.
TId
===
this
.
addMsg
.
TeacherId
);
if
(
teacherObj
!=
undefined
){
this
.
addMsg
.
TeacherName
=
teacherObj
.
TeacherName
;
}
let
showTips
=
0
;
this
.
data
.
forEach
((
item
,
index
)
=>
{
let
nowInfo
=
{
ID
:
item
.
ID
,
SurveyType
:
item
.
SurveyType
,
CheckInfo
:
item
.
CheckInfo
,
Title
:
item
.
Title
,
Sort
:
item
.
Sort
,
ScoreNum
:
item
.
ScoreNum
,
TextContent
:
item
.
TextContent
};
// if(item.SurveyType==1){//打分
// if(item.ScoreNum==0){
// this.$q.notify({
// type: "negative",
// position: "top",
// message: item.Title+'您还未打分'
// });
// showTips+=1;
// }
// } else if(item.SurveyType==2){//单选
// if(item.ScoreNum==0){
// this.$q.notify({
// type: "negative",
// position: "top",
// message: item.Title+'您还未选择'
// });
// showTips+=1;
// }
// }
// else if(item.SurveyType==3){//多选
// if(item.CheckInfo.length==0){
// this.$q.notify({
// type: "negative",
// position: "top",
// message: item.Title+'您还未选择'
// });
// showTips+=1;
// }
// }
this
.
addMsg
.
SurveyList
.
push
(
nowInfo
);
});
if
(
showTips
>
0
)
{
return
;
}
setEducationSurvey
(
this
.
addMsg
).
then
(
res
=>
{
this
.
saveLoading
=
false
this
.
$q
.
notify
({
icon
:
'iconfont icon-chenggong'
,
color
:
'accent'
,
timeout
:
2000
,
message
:
'数据保存成功!'
,
position
:
'top'
})
this
.
loadingCG
=
false
;
this
.
$emit
(
"success"
)
}).
catch
(()
=>
{
this
.
saveLoading
=
false
this
.
loadingCG
=
true
;
})
},
//获取教师下拉
GetTeacherList
()
{
getTeacherListByGroupId
(
this
.
msg
).
then
(
res
=>
{
if
(
res
.
Code
==
1
)
{
this
.
TeacherList
=
res
.
Data
;
var
obj
=
{
TeacherName
:
'请选择'
,
TId
:
0
}
this
.
TeacherList
.
unshift
(
obj
);
this
.
AllTeacherList
=
this
.
TeacherList
;
}
})
},
//获取问卷调查内容
getSurveyShowList
()
{
this
.
loading
=
true
;
querySurveyShowList
(
this
.
msg
).
then
(
res
=>
{
this
.
loading
=
false
this
.
data
=
res
.
Data
}).
catch
(()
=>
{
this
.
loading
=
false
})
},
}
}
</
script
>
<
style
>
html
{
font-size
:
625%
;
/*100 ÷ 16 × 100% = 625%*/
}
@media
screen
and
(
min-width
:
360px
)
and
(
max-width
:
374px
)
and
(
orientation
:
portrait
)
{
html
{
font-size
:
703%
;
}
}
@media
screen
and
(
min-width
:
375px
)
and
(
max-width
:
383px
)
and
(
orientation
:
portrait
)
{
html
{
font-size
:
732.4%
;
}
}
@media
screen
and
(
min-width
:
384px
)
and
(
max-width
:
399px
)
and
(
orientation
:
portrait
)
{
html
{
font-size
:
750%
;
}
}
@media
screen
and
(
min-width
:
400px
)
and
(
max-width
:
413px
)
and
(
orientation
:
portrait
)
{
html
{
font-size
:
781.25%
;
}
}
@media
screen
and
(
min-width
:
414px
)
and
(
max-width
:
431px
)
and
(
orientation
:
portrait
){
html
{
font-size
:
808.6%
;
}
}
@media
screen
and
(
min-width
:
432px
)
and
(
max-width
:
479px
)
and
(
orientation
:
portrait
){
html
{
font-size
:
843.75%
;
}
}
</
style
>
<
style
lang=
"sass"
>
@import
url('~assets/css/table.sass')
</
style
>
\ No newline at end of file
src/pages/system/surveyStudentList.vue
0 → 100644
View file @
9d4249e8
<
template
>
<div
class=
"page-body"
>
<div
class=
"page-search row items-center"
>
<div
class=
"col row wrap q-mr-lg q-col-gutter-md"
>
<div
class=
"col-3"
>
<q-input
@
input=
"resetSearch"
clearable
standout=
"bg-primary text-white"
class=
"col-6 q-pr-lg q-pr-lg"
v-model=
"msg.Title"
label=
"问题名称"
maxlength=
"20"
@
clear=
"resetSearch"
/>
</div>
<div
class=
"col-3"
>
<q-select
filled
stack-label
class=
"col-6 q-pr-lg"
option-value=
"Id"
option-label=
"Name"
v-model=
"msg.TeacherId"
:options=
"SurveyTypeEnumList"
emit-value
map-options
label=
"问题类型"
@
input=
"refreshPage()"
/>
</div>
<div
class=
"col-3"
>
<q-select
filled
stack-label
class=
"col-6 q-pr-lg"
option-value=
"Id"
option-label=
"Name"
v-model=
"msg.StudentId"
:options=
"ShowList"
emit-value
map-options
label=
"是否显示"
@
input=
"refreshPage()"
/>
</div>
</div>
</div>
<div
class=
"page-content"
>
<q-table
:pagination=
"msg"
:loading=
"loading"
no-data-label=
"暂无相关数据"
flat
class=
"sticky-tow-column-table"
separator=
"none"
:data=
"data"
:columns=
"columns"
row-key=
"name"
>
<template
v-slot:top=
"props"
>
<div
class=
"col-2 q-table__title"
>
问卷调查信息
</div>
<q-space
/>
</
template
>
<
template
v-slot:bottom
>
<q-pagination
class=
"full-width justify-end"
v-model=
"msg.pageIndex"
color=
"primary"
:max=
"pageCount"
:input=
"true"
@
input=
"changePage"
/>
</
template
>
<
template
v-slot:body-cell-optioned=
"props"
>
<q-td
:props=
"props"
>
<q-btn
flat
size=
"xs"
icon=
"edit"
color=
"accent"
style=
"font-weight:400"
label=
"详情"
@
click=
"editSurvey(props.row)"
/>
</q-td>
</
template
>
</q-table>
<area-form
v-if=
"isShowAreaForm"
:save-obj=
"areaObjOption"
@
close=
"refreshPage"
@
success=
"refreshPage"
>
</area-form>
</div>
</div>
</template>
<
script
>
import
{
queryStudentSurveyPage
,
deleteSurvey
,
querySurveyTypeEnumList
}
from
'../../api/common/common'
import
areaForm
from
'../../components/system/surveyStudentList-form'
export
default
{
meta
:
{
title
:
"老师上课质量调查问卷"
},
components
:
{
areaForm
,
},
data
()
{
return
{
currentUrl
:
""
,
columns
:
[
{
name
:
'TeacherName'
,
label
:
'老师'
,
field
:
'TeacherName'
,
align
:
'left'
},
{
name
:
'StudentName'
,
label
:
'学生'
,
field
:
'StudentName'
,
align
:
'left'
},
{
name
:
'CreateDate'
,
label
:
'时间'
,
field
:
'CreateDate'
,
align
:
'left'
},
{
name
:
'optioned'
,
label
:
'操作'
,
field
:
'MenuId'
}
],
data
:
[],
loading
:
true
,
msg
:
{
pageIndex
:
1
,
pageSize
:
12
,
rowsPerPage
:
12
,
TeacherId
:
-
1
,
StudentId
:
-
1
,
},
pageCount
:
0
,
isShowAreaForm
:
false
,
//是否显示新增修改地区表单
areaObjOption
:
null
,
SurveyTypeEnumList
:
[],
//问题类型
ShowList
:
[{
Id
:
-
1
,
Name
:
'不限'
},{
Id
:
1
,
Name
:
'显示'
},{
Id
:
0
,
Name
:
'不显示'
}],
//问题类型
}
},
mounted
()
{
this
.
currentUrl
=
this
.
$route
.
path
this
.
getSurveypage
();
},
methods
:
{
//刷新页面
refreshPage
()
{
this
.
isShowAreaForm
=
false
;
this
.
areaObjOption
=
null
;
this
.
getSurveypage
();
},
//新增修改学生调查
editSurvey
(
obj
)
{
if
(
obj
!=
null
)
{
this
.
areaObjOption
=
obj
;
}
this
.
isShowAreaForm
=
true
;
},
//重新查询
resetSearch
()
{
this
.
msg
.
pageIndex
=
1
;
this
.
getSurveypage
();
},
//翻页
changePage
(
val
)
{
this
.
msg
.
pageIndex
=
val
;
this
.
getSurveypage
()
},
//获取地区分页列表
getSurveypage
()
{
this
.
loading
=
true
;
queryStudentSurveyPage
(
this
.
msg
).
then
(
res
=>
{
this
.
loading
=
false
this
.
data
=
res
.
Data
.
PageData
this
.
pageCount
=
res
.
Data
.
PageCount
}).
catch
(()
=>
{
this
.
loading
=
false
})
},
}
}
</
script
>
<
style
lang=
"sass"
>
@import
url('~assets/css/table.sass')
</
style
>
\ No newline at end of file
src/router/routes.js
View file @
9d4249e8
...
...
@@ -18,6 +18,11 @@ const routes = [{
component
:
()
=>
import
(
"pages/wxhtml/uploadFiles.vue"
)
},
{
path
:
"/system/surveyStudent"
,
//学生意见调查填写2024-07-01 add by:W
component
:
()
=>
import
(
"pages/system/surveyStudent.vue"
)
},
{
path
:
"/home"
,
component
:
()
=>
...
...
@@ -108,6 +113,17 @@ const routes = [{
component
:
()
=>
import
(
"pages/system/area.vue"
)
},
{
path
:
"/system/survey"
,
//问卷调查管理2024-06-28 add by:W
component
:
()
=>
import
(
"pages/system/survey.vue"
)
},
{
path
:
"/system/surveyStudentList"
,
//老师问卷调查管理2024-06-28 add by:W
component
:
()
=>
import
(
"pages/system/surveyStudentList.vue"
)
},
{
path
:
"/system/deptrelation"
,
//部门关系图
component
:
()
=>
...
...
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