mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/fe-manage.git
synced 2025-12-12 20:36:45 +08:00
feat:合并
This commit is contained in:
6
package-lock.json
generated
6
package-lock.json
generated
@@ -19867,7 +19867,7 @@
|
|||||||
},
|
},
|
||||||
"sortablejs": {
|
"sortablejs": {
|
||||||
"version": "1.15.0",
|
"version": "1.15.0",
|
||||||
"resolved": "https://registry.npmjs.org/sortablejs/-/sortablejs-1.15.0.tgz",
|
"resolved": "https://registry.npmmirror.com/sortablejs/-/sortablejs-1.15.0.tgz",
|
||||||
"integrity": "sha512-bv9qgVMjUMf89wAvM6AxVvS/4MX3sPeN0+agqShejLU5z5GX4C75ow1O2e5k4L6XItUyAK3gH6AxSbXrOM5e8w=="
|
"integrity": "sha512-bv9qgVMjUMf89wAvM6AxVvS/4MX3sPeN0+agqShejLU5z5GX4C75ow1O2e5k4L6XItUyAK3gH6AxSbXrOM5e8w=="
|
||||||
},
|
},
|
||||||
"source-map": {
|
"source-map": {
|
||||||
@@ -20676,7 +20676,7 @@
|
|||||||
},
|
},
|
||||||
"vuedraggable": {
|
"vuedraggable": {
|
||||||
"version": "4.1.0",
|
"version": "4.1.0",
|
||||||
"resolved": "https://registry.npmjs.org/vuedraggable/-/vuedraggable-4.1.0.tgz",
|
"resolved": "https://registry.npmmirror.com/vuedraggable/-/vuedraggable-4.1.0.tgz",
|
||||||
"integrity": "sha512-FU5HCWBmsf20GpP3eudURW3WdWTKIbEIQxh9/8GE806hydR9qZqRRxRE3RjqX7PkuLuMQG/A7n3cfj9rCEchww==",
|
"integrity": "sha512-FU5HCWBmsf20GpP3eudURW3WdWTKIbEIQxh9/8GE806hydR9qZqRRxRE3RjqX7PkuLuMQG/A7n3cfj9rCEchww==",
|
||||||
"requires": {
|
"requires": {
|
||||||
"sortablejs": "1.14.0"
|
"sortablejs": "1.14.0"
|
||||||
@@ -20684,7 +20684,7 @@
|
|||||||
"dependencies": {
|
"dependencies": {
|
||||||
"sortablejs": {
|
"sortablejs": {
|
||||||
"version": "1.14.0",
|
"version": "1.14.0",
|
||||||
"resolved": "https://registry.npmjs.org/sortablejs/-/sortablejs-1.14.0.tgz",
|
"resolved": "https://registry.npmmirror.com/sortablejs/-/sortablejs-1.14.0.tgz",
|
||||||
"integrity": "sha512-pBXvQCs5/33fdN1/39pPL0NZF20LeRbLQ5jtnheIPN9JQAaufGjKdWduZn4U7wCtVuzKhmRkI0DFYHYRbB2H1w=="
|
"integrity": "sha512-pBXvQCs5/33fdN1/39pPL0NZF20LeRbLQ5jtnheIPN9JQAaufGjKdWduZn4U7wCtVuzKhmRkI0DFYHYRbB2H1w=="
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -27,4 +27,4 @@ export const planList = (obj) => http.post('/admin/offcourse/planList', obj)
|
|||||||
//获取面授课列表
|
//获取面授课列表
|
||||||
export const list = (obj) => http.post('/admin/offcourse/list', obj)
|
export const list = (obj) => http.post('/admin/offcourse/list', obj)
|
||||||
|
|
||||||
export const addTempTask = (obj) => http.post('/admin/project//template/editTask', obj)
|
export const addTempTask = (obj) => http.post('/admin/project/template/editTask', obj)
|
||||||
@@ -42,10 +42,16 @@ import qs from 'qs';
|
|||||||
// 接口-请求
|
// 接口-请求
|
||||||
|
|
||||||
//基础票数上传接口
|
//基础票数上传接口
|
||||||
export const baseVoteupload = (obj) => http.post('/vote/baseVoteupload', obj)
|
export const baseVoteupload = (obj) => http.post('/vote/baseVoteupload', obj,{
|
||||||
|
headers: {
|
||||||
|
'token': '123',
|
||||||
|
'Content-Type' : 'multipart/form-data',
|
||||||
|
|
||||||
|
}
|
||||||
|
})
|
||||||
//创建题干信息接口
|
//创建题干信息接口
|
||||||
export const createOptionMessage = (obj) => http.post('/vote/createOptionMessage', obj)
|
export const createStemMessage = (obj) => http.post('/vote/createOptionMessage', obj)
|
||||||
|
|
||||||
|
|
||||||
//投票信息创建接口
|
//投票信息创建接口
|
||||||
export const createVote = (obj) => http.post('/vote/createVote', obj)
|
export const createVote = (obj) => http.post('/vote/createVote', obj)
|
||||||
@@ -54,7 +60,12 @@ export const createVote = (obj) => http.post('/vote/createVote', obj)
|
|||||||
export const deleteVoteMessage = (obj) => http.post('/vote/deleteVoteMessage', { params: obj })
|
export const deleteVoteMessage = (obj) => http.post('/vote/deleteVoteMessage', { params: obj })
|
||||||
|
|
||||||
//删除题干信息接口
|
//删除题干信息接口
|
||||||
export const deleteVoteStem = (obj) => http.post('/vote/deleteVoteStem', { params: obj })
|
export const deleteVoteStem = (obj) => http.post('/vote/deleteVoteStem', obj,{
|
||||||
|
headers: {
|
||||||
|
'token': '123',
|
||||||
|
'Content-Type': 'application/x-www-form-urlencoded;charset=UTF-8',
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
//删除题选项息接口
|
//删除题选项息接口
|
||||||
export const deleteVoteStemOption = (obj) => http.post('/vote/deleteVoteStemOption', { params: obj })
|
export const deleteVoteStemOption = (obj) => http.post('/vote/deleteVoteStemOption', { params: obj })
|
||||||
@@ -64,15 +75,24 @@ export const editVote = (obj) => http.post('/vote/editVote', obj)
|
|||||||
|
|
||||||
//根据题干ID获取题干信息
|
//根据题干ID获取题干信息
|
||||||
export const queryStemByStemId = (obj) => http.post('/vote/queryStemByStemId', obj,{
|
export const queryStemByStemId = (obj) => http.post('/vote/queryStemByStemId', obj,{
|
||||||
headers: {'Content-Type': 'application/x-www-form-urlencoded;charset=UTF-8'}
|
headers: {
|
||||||
})
|
'token': '123',
|
||||||
|
'Content-Type': 'application/x-www-form-urlencoded;charset=UTF-8',
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
//修改题干信息接口
|
//修改题干信息接口
|
||||||
export const updateStemMessage = (obj) => http.post('/vote/updateStemMessage', obj);
|
export const updateStemMessage = (obj) => http.post('/vote/updateStemMessage', obj);
|
||||||
|
|
||||||
//上传组件
|
//上传组件
|
||||||
export const fileUp = (obj) => http.post('/file/upload', obj, qs.stringify({ obj }));
|
export const fileUp = (obj) => http.post('/file/upload', obj, qs.stringify({ obj }));
|
||||||
|
//根据题干ID获取投票任务
|
||||||
|
export const queryVoteDetailById = (obj) => http.post('/vote/queryVoteDetailById', obj,{
|
||||||
|
headers: {
|
||||||
|
'token': '123',
|
||||||
|
'Content-Type': 'application/x-www-form-urlencoded;charset=UTF-8',
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
// 测试方法
|
// 测试方法
|
||||||
// import * as api from '../../api/index'
|
// import * as api from '../../api/index'
|
||||||
|
|||||||
@@ -82,7 +82,7 @@ export default {
|
|||||||
type: Boolean,
|
type: Boolean,
|
||||||
default: false,
|
default: false,
|
||||||
},
|
},
|
||||||
isface: {
|
assessmentId: {
|
||||||
type: Number,
|
type: Number,
|
||||||
default: null,
|
default: null,
|
||||||
},
|
},
|
||||||
@@ -101,10 +101,12 @@ export default {
|
|||||||
tableDataTotal: 0,
|
tableDataTotal: 0,
|
||||||
tableData: [],
|
tableData: [],
|
||||||
selectedRowKeys: [],
|
selectedRowKeys: [],
|
||||||
|
assessmentId:null,
|
||||||
});
|
});
|
||||||
const closeDrawer = () => {
|
const closeDrawer = () => {
|
||||||
ctx.emit("update:assessmentVisible", false);
|
ctx.emit("update:assessmentVisible", false);
|
||||||
ctx.emit("update:titleTag", true);
|
ctx.emit("update:titleTag", true);
|
||||||
|
|
||||||
};
|
};
|
||||||
const afterVisibleChange = (bool) => {
|
const afterVisibleChange = (bool) => {
|
||||||
console.log("state getAllInvistText", bool,"======",props.titleTag);
|
console.log("state getAllInvistText", bool,"======",props.titleTag);
|
||||||
@@ -150,14 +152,10 @@ export default {
|
|||||||
const rowSelection = {
|
const rowSelection = {
|
||||||
type: "radio",
|
type: "radio",
|
||||||
onSelect: (selectedRows) => {
|
onSelect: (selectedRows) => {
|
||||||
state.assessment = selectedRows;
|
state.assessment =selectedRows;
|
||||||
console.log("selectedRows=======", state.assessment);
|
state.assessmentId = selectedRows.assessmentId;
|
||||||
if (props.isface == 1) {
|
|
||||||
ctx.emit("faceAssess", state.assessment);
|
|
||||||
} else {
|
|
||||||
ctx.emit("checkedAss", state.assessment);
|
ctx.emit("checkedAss", state.assessment);
|
||||||
}
|
ctx.emit("update:assessmentId", state.assessmentId);
|
||||||
|
|
||||||
state.selectedRowKeys = [];
|
state.selectedRowKeys = [];
|
||||||
closeDrawer();
|
closeDrawer();
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -282,6 +282,10 @@ export default {
|
|||||||
type: Number,
|
type: Number,
|
||||||
default: null,
|
default: null,
|
||||||
},
|
},
|
||||||
|
projectTemplateId:{
|
||||||
|
type: Number,
|
||||||
|
default: null,
|
||||||
|
},
|
||||||
},
|
},
|
||||||
setup(props, ctx) {
|
setup(props, ctx) {
|
||||||
const state = reactive({
|
const state = reactive({
|
||||||
@@ -370,7 +374,7 @@ export default {
|
|||||||
name: res.data.data.activityName,
|
name: res.data.data.activityName,
|
||||||
projectId: props.projectId,
|
projectId: props.projectId,
|
||||||
projectTaskId: props.projectTaskId || 0,
|
projectTaskId: props.projectTaskId || 0,
|
||||||
stageId: props.chooseStageId,
|
stageId: props.chooseStageId || 0,
|
||||||
type: 9,
|
type: 9,
|
||||||
})
|
})
|
||||||
.then(() => {
|
.then(() => {
|
||||||
@@ -385,9 +389,9 @@ export default {
|
|||||||
courseId: res.data.data.activityId,
|
courseId: res.data.data.activityId,
|
||||||
duration: res.data.data.activityDuration,
|
duration: res.data.data.activityDuration,
|
||||||
name: res.data.data.activityName,
|
name: res.data.data.activityName,
|
||||||
projectTemplateId:props.projectTemplateId,
|
projectTemplateId: props.projectTemplateId,
|
||||||
projectTaskId: props.projectTaskId || 0,
|
projectTaskId: props.projectTaskId || 0,
|
||||||
stageId: props.chooseStageId,
|
stageId: props.chooseStageId || 0,
|
||||||
type: 9,
|
type: 9,
|
||||||
})
|
})
|
||||||
.then(() => {
|
.then(() => {
|
||||||
@@ -397,7 +401,7 @@ export default {
|
|||||||
message.error(`${props.edit ? "编辑" : "新增"}阶段任务失败`);
|
message.error(`${props.edit ? "编辑" : "新增"}阶段任务失败`);
|
||||||
});
|
});
|
||||||
|
|
||||||
console.log("");
|
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
//创建活动
|
//创建活动
|
||||||
|
|||||||
@@ -299,10 +299,8 @@ export default {
|
|||||||
apiTask
|
apiTask
|
||||||
.addTask({
|
.addTask({
|
||||||
courseId: state.apiTaskList[i].casesId,
|
courseId: state.apiTaskList[i].casesId,
|
||||||
duration: 0,
|
|
||||||
flag: true,
|
|
||||||
name: state.apiTaskList[i].title,
|
name: state.apiTaskList[i].title,
|
||||||
projectId: props.projectId,
|
projectTemplateId: props.projectTemplateId,
|
||||||
projectTaskId: props.projectTaskId,
|
projectTaskId: props.projectTaskId,
|
||||||
stageId: Number(props.chooseStageId),
|
stageId: Number(props.chooseStageId),
|
||||||
type: 3,
|
type: 3,
|
||||||
@@ -332,7 +330,7 @@ export default {
|
|||||||
name: state.apiTaskList[i].caseName,
|
name: state.apiTaskList[i].caseName,
|
||||||
projectId: props.projectId,
|
projectId: props.projectId,
|
||||||
projectTemplateId: props.projectTemplateId,
|
projectTemplateId: props.projectTemplateId,
|
||||||
stageId: props.chooseStageId,
|
stageId: props.chooseStageId || 0,
|
||||||
type: 3,
|
type: 3,
|
||||||
})
|
})
|
||||||
.then(() => {
|
.then(() => {
|
||||||
|
|||||||
@@ -128,6 +128,10 @@ export default {
|
|||||||
type: Number,
|
type: Number,
|
||||||
default: null,
|
default: null,
|
||||||
},
|
},
|
||||||
|
projectTemplateId:{
|
||||||
|
type: Number,
|
||||||
|
default: null,
|
||||||
|
},
|
||||||
},
|
},
|
||||||
setup(props, ctx) {
|
setup(props, ctx) {
|
||||||
const state = reactive({
|
const state = reactive({
|
||||||
@@ -194,11 +198,10 @@ export default {
|
|||||||
apiTask
|
apiTask
|
||||||
.addTask({
|
.addTask({
|
||||||
courseId: res.data.data.discussId,
|
courseId: res.data.data.discussId,
|
||||||
duration: res.data.data.discussExplain,
|
|
||||||
name: res.data.data.discussName,
|
name: res.data.data.discussName,
|
||||||
projectId: props.projectId,
|
projectId: props.projectId,
|
||||||
projectTaskId: props.projectTaskId || 0,
|
projectTaskId: props.projectTaskId || 0,
|
||||||
stageId: props.chooseStageId,
|
stageId: props.chooseStageId || 0,
|
||||||
type: 8,
|
type: 8,
|
||||||
})
|
})
|
||||||
.then(() => {
|
.then(() => {
|
||||||
@@ -211,11 +214,10 @@ export default {
|
|||||||
console.log("");
|
console.log("");
|
||||||
addTempTask({
|
addTempTask({
|
||||||
courseId: res.data.data.discussId,
|
courseId: res.data.data.discussId,
|
||||||
duration: res.data.data.discussExplain,
|
|
||||||
name: res.data.data.discussName,
|
name: res.data.data.discussName,
|
||||||
projectId: props.projectId,
|
projectTemplateId: props.projectTemplateId,
|
||||||
projectTaskId: props.projectTaskId || 0,
|
projectTaskId: props.projectTaskId || 0,
|
||||||
stageId: props.chooseStageId,
|
stageId: props.chooseStageId || 0,
|
||||||
type: 8,
|
type: 8,
|
||||||
})
|
})
|
||||||
.then(() => {
|
.then(() => {
|
||||||
|
|||||||
@@ -228,7 +228,7 @@ export default {
|
|||||||
name: value.evaluationName,
|
name: value.evaluationName,
|
||||||
projectId: props.projectId,
|
projectId: props.projectId,
|
||||||
projectTaskId: props.projectTaskId || 0,
|
projectTaskId: props.projectTaskId || 0,
|
||||||
stageId: props.chooseStageId,
|
stageId: props.chooseStageId || 0,
|
||||||
type: 10,
|
type: 10,
|
||||||
})
|
})
|
||||||
.then(() => {
|
.then(() => {
|
||||||
@@ -240,15 +240,12 @@ export default {
|
|||||||
message.error(`${props.edit ? "编辑" : "新增"}阶段任务失败`);
|
message.error(`${props.edit ? "编辑" : "新增"}阶段任务失败`);
|
||||||
});
|
});
|
||||||
} else if (props.isLevel == 3) {
|
} else if (props.isLevel == 3) {
|
||||||
console.log("");
|
|
||||||
addTempTask({
|
addTempTask({
|
||||||
duration: 0,
|
|
||||||
flag: true,
|
|
||||||
courseId: Number(value.evaluationId),
|
courseId: Number(value.evaluationId),
|
||||||
name: value.evaluationName,
|
name: value.evaluationName,
|
||||||
projectId: props.projectId,
|
projectTemplateId: props.projectTemplateId,
|
||||||
projectTaskId: props.projectTaskId || 0,
|
projectTaskId: props.projectTaskId || 0,
|
||||||
stageId: props.chooseStageId,
|
stageId: props.chooseStageId || 0,
|
||||||
type: 10,
|
type: 10,
|
||||||
})
|
})
|
||||||
.then(() => {
|
.then(() => {
|
||||||
|
|||||||
@@ -30,9 +30,9 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="btnbox">
|
<div class="btnbox">
|
||||||
<a-input
|
<a-input
|
||||||
v-model:value="inputV1"
|
v-model:value="courseName"
|
||||||
style="width: 384px; height: 32px"
|
style="width: 384px; height: 32px"
|
||||||
placeholder="请输入小组名称"
|
placeholder="请输入名称"
|
||||||
maxlength="20"
|
maxlength="20"
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
@@ -49,29 +49,20 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="btnbox" @click="showDrawerSelFacet">
|
<div class="btnbox" @click="showDrawerSelFacet">
|
||||||
<button class="xkbtn">
|
<button class="xkbtn">
|
||||||
{{ chooseCourse == null ? "授课" : "修改" }}课程
|
{{ chooseCourse == null ? "选择" : "修改" }}面授课
|
||||||
</button>
|
</button>
|
||||||
<a-tag
|
<div v-if = "chooseCourse > 0">
|
||||||
style="
|
<a-tag closable color="processing" @close="logC">
|
||||||
width: 104px;
|
<span style="font-size:14px;line-height: 33px;" >删除课程</span>
|
||||||
height: 32px;
|
</a-tag></div>
|
||||||
border-radius: 4px;
|
|
||||||
color: #388be1;
|
|
||||||
display: flex;
|
|
||||||
align-items: center;
|
|
||||||
"
|
|
||||||
color="#ECF3FC"
|
|
||||||
v-if="chooseCourse !== null"
|
|
||||||
closable
|
|
||||||
@close="closeTag"
|
|
||||||
>{{ chooseCourseName }}</a-tag
|
|
||||||
>
|
|
||||||
</div>
|
</div>
|
||||||
<!-- 选择面授侧弹窗 -->
|
<!-- 选择面授侧弹窗 -->
|
||||||
<div>
|
<div>
|
||||||
<sel-facet
|
<sel-facet
|
||||||
v-model:selfacetVisible="selfacetvisible"
|
v-model:selfacetVisible="selfacetvisible"
|
||||||
@getData="upDateTable"
|
v-model:chooseCourse="chooseCourse"
|
||||||
|
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
<!-- 选择面授侧弹窗 -->
|
<!-- 选择面授侧弹窗 -->
|
||||||
@@ -82,7 +73,7 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="textarea">
|
<div class="textarea">
|
||||||
<a-textarea
|
<a-textarea
|
||||||
v-model:value="textV1"
|
v-model:value="description"
|
||||||
placeholder="请输入说明"
|
placeholder="请输入说明"
|
||||||
allow-clear
|
allow-clear
|
||||||
maxlength="100"
|
maxlength="100"
|
||||||
@@ -144,7 +135,7 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="btnbox">
|
<div class="btnbox">
|
||||||
<a-input
|
<a-input
|
||||||
v-model:value="inputV3"
|
v-model:value="duration"
|
||||||
style="width: 384px; height: 32px"
|
style="width: 384px; height: 32px"
|
||||||
/>
|
/>
|
||||||
<span style="margin-left: 5px; width: 30px">分钟</span>
|
<span style="margin-left: 5px; width: 30px">分钟</span>
|
||||||
@@ -162,7 +153,7 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="btnbox">
|
<div class="btnbox">
|
||||||
<a-input
|
<a-input
|
||||||
v-model:value="inputV4"
|
v-model:value="address"
|
||||||
style="width: 384px; height: 32px"
|
style="width: 384px; height: 32px"
|
||||||
placeholder="请输入上课地址"
|
placeholder="请输入上课地址"
|
||||||
maxlength="100"
|
maxlength="100"
|
||||||
@@ -190,7 +181,7 @@
|
|||||||
border-radius: 8px;
|
border-radius: 8px;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
"
|
"
|
||||||
:v-model:value="inputV5"
|
:v-model:value="beforeStart"
|
||||||
></a-input-number>
|
></a-input-number>
|
||||||
<span style="color: #999999; margin-left: 8px">分钟</span>
|
<span style="color: #999999; margin-left: 8px">分钟</span>
|
||||||
</div>
|
</div>
|
||||||
@@ -206,34 +197,13 @@
|
|||||||
border-radius: 8px;
|
border-radius: 8px;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
"
|
"
|
||||||
:v-model:value="inputV6"
|
:v-model:value="afterStart"
|
||||||
></a-input-number>
|
></a-input-number>
|
||||||
<span style="color: #999999; margin-left: 8px">分钟</span>
|
<span style="color: #999999; margin-left: 8px">分钟</span>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="qdqtbox">
|
|
||||||
<div class="qtbtn"><div class="btntext">签退</div></div>
|
|
||||||
</div>
|
|
||||||
<div class="setbox">
|
|
||||||
<div class="timerbox">
|
|
||||||
<span>结束前:</span>
|
|
||||||
<a-input-number
|
|
||||||
:min="0"
|
|
||||||
:max="30"
|
|
||||||
:precision="0"
|
|
||||||
style="
|
|
||||||
width: 88px;
|
|
||||||
height: 32px;
|
|
||||||
border-radius: 8px;
|
|
||||||
overflow: hidden;
|
|
||||||
"
|
|
||||||
:v-model:value="inputV7"
|
|
||||||
></a-input-number>
|
|
||||||
<span style="color: #999999; margin-left: 8px"
|
|
||||||
>分钟(提前签退则记为早退)</span
|
|
||||||
>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="main_item">
|
<div class="main_item">
|
||||||
@@ -241,14 +211,11 @@
|
|||||||
<span style="margin-right: 3px">完成标准设置:</span>
|
<span style="margin-right: 3px">完成标准设置:</span>
|
||||||
</div>
|
</div>
|
||||||
<div class="btnbox">
|
<div class="btnbox">
|
||||||
<a-radio-group v-model:value="radioV1">
|
|
||||||
<a-radio v-model:checked="checked" :value="1" @click="cloradio1"
|
|
||||||
>仅签到</a-radio
|
<a-checkbox v-model:checked="onlySign" @click="onlySign=!onlySign">仅签到</a-checkbox>
|
||||||
>
|
|
||||||
<a-radio v-model:checked="checked" :value="2" @click="cloradio1"
|
|
||||||
>签到、签退全部完成</a-radio
|
|
||||||
>
|
|
||||||
</a-radio-group>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="main_item">
|
<div class="main_item">
|
||||||
@@ -256,24 +223,18 @@
|
|||||||
<span style="margin-right: 3px">其他设置:</span>
|
<span style="margin-right: 3px">其他设置:</span>
|
||||||
</div>
|
</div>
|
||||||
<div class="btnbox">
|
<div class="btnbox">
|
||||||
<a-checkbox v-model:checked="checkedHolidy"
|
<a-checkbox v-model:checked="complete_leave" @click="complete_leave=!complete_leave"
|
||||||
>学员请假后记为任务完成</a-checkbox
|
>学员请假后记为任务完成</a-checkbox
|
||||||
>
|
>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="main_item2">
|
<div class="main_item">
|
||||||
<div class="signbox">
|
<div class="signbox">
|
||||||
<span style="margin-right: 3px">现场参与:</span>
|
<span style="margin-right: 3px">现场参与:</span>
|
||||||
</div>
|
</div>
|
||||||
<div class="btnbox2">
|
<div class="btnbox">
|
||||||
<a-radio-group v-model:value="radioV2">
|
<a-checkbox v-model:checked="innerPersion" @click="innerPersion=!innerPersion">允许项目内人员临时到场参加</a-checkbox>
|
||||||
<a-radio v-model:checked="checked" :value="1" @click="cloradio2"
|
<a-checkbox v-model:checked="outPerson" @click="outPerson=!outPerson">允许项目外人员临时到场参加</a-checkbox>
|
||||||
>允许项目内人员临时到场参加</a-radio
|
|
||||||
>
|
|
||||||
<a-radio v-model:checked="checked" :value="2" @click="cloradio2"
|
|
||||||
>允许项目外人员临时到场参加</a-radio
|
|
||||||
>
|
|
||||||
</a-radio-group>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="main_item2">
|
<div class="main_item2">
|
||||||
@@ -281,27 +242,29 @@
|
|||||||
<span style="margin-right: 3px">评估:</span>
|
<span style="margin-right: 3px">评估:</span>
|
||||||
</div>
|
</div>
|
||||||
<div class="btnbox2">
|
<div class="btnbox2">
|
||||||
<a-checkbox v-model:checked="checkedAssessment"
|
<a-checkbox v-model:checked="needEval"
|
||||||
>需要评估</a-checkbox
|
>需要评估</a-checkbox >
|
||||||
>
|
</div>
|
||||||
|
</div>
|
||||||
|
<div v-if="needEval" class="main_item">
|
||||||
|
<div class="signbox">
|
||||||
|
</div>
|
||||||
|
<div class="btnbox">
|
||||||
<button class="xkbtn" @click="showAssessment">选择评估</button>
|
<button class="xkbtn" @click="showAssessment">选择评估</button>
|
||||||
<a-tag
|
<div v-if = "assessmentId >0 ">
|
||||||
style="
|
<a-tag closable color="processing" @close="logA">
|
||||||
width: 104px;
|
<span style="font-size:14px;line-height: 33px;" >删除评估</span>
|
||||||
height: 32px;
|
</a-tag></div>
|
||||||
border-radius: 4px;
|
<AssessmentList
|
||||||
color: #388be1;
|
v-model:assessmentVisible="assessmentVisible"
|
||||||
display: flex;
|
v-model:titleTag="titleTag"
|
||||||
align-items: center;
|
v-model:assessmentId="assessmentId"
|
||||||
"
|
/>
|
||||||
color="#ECF3FC"
|
|
||||||
v-if="chooseMent !== null"
|
|
||||||
closable
|
|
||||||
@close="closeTag"
|
|
||||||
>{{ chooseMentName }}</a-tag
|
|
||||||
>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
<div class="main_right">
|
<div class="main_right">
|
||||||
<div class="main_item">
|
<div class="main_item">
|
||||||
@@ -310,6 +273,11 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="btnbox" @click="showDrawerAddHomework">
|
<div class="btnbox" @click="showDrawerAddHomework">
|
||||||
<button class="xkbtn">配置</button>
|
<button class="xkbtn">配置</button>
|
||||||
|
<div v-if = "EditWorkId >0">
|
||||||
|
<a-tag closable color="processing" @close="logW">
|
||||||
|
<span style="font-size:14px;line-height: 33px;" >删除作业</span>
|
||||||
|
</a-tag></div>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<!-- 添加作业侧弹窗 -->
|
<!-- 添加作业侧弹窗 -->
|
||||||
@@ -317,39 +285,33 @@
|
|||||||
<add-homework
|
<add-homework
|
||||||
v-model:addhomeworkVisible="addhomeworkvisible"
|
v-model:addhomeworkVisible="addhomeworkvisible"
|
||||||
@getWork="getWork"
|
@getWork="getWork"
|
||||||
v-model:face="face"
|
:faceLevel="true"
|
||||||
|
v-model:EditWorkId="EditWorkId"
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
<!-- 添加作业侧弹窗 -->
|
<!-- 添加作业侧弹窗 -->
|
||||||
</div>
|
</div>
|
||||||
<div>
|
<div>
|
||||||
<a-tag
|
|
||||||
style="
|
|
||||||
width: 104px;
|
|
||||||
height: 32px;
|
|
||||||
border-radius: 4px;
|
|
||||||
color: #388be1;
|
|
||||||
display: flex;
|
|
||||||
align-items: center;
|
|
||||||
margin-left: 120px;
|
|
||||||
"
|
|
||||||
color="#ECF3FC"
|
|
||||||
v-if="chooseWork !== null"
|
|
||||||
closable
|
|
||||||
@close="closeTagWork"
|
|
||||||
>{{ chooseWorkName }}</a-tag
|
|
||||||
>
|
|
||||||
</div>
|
</div>
|
||||||
<div class="main_item">
|
<div class="main_item">
|
||||||
<div class="signbox">
|
<div class="signbox">
|
||||||
<span style="margin-right: 3px">配置考试:</span>
|
<span style="margin-right: 3px">配置考试:</span>
|
||||||
</div>
|
</div>
|
||||||
<div class="btnbox" @click="showDrawerAddTest">
|
<div class="btnbox" @click="showDrawerAddTest">
|
||||||
<button class="xkbtn">配置</button>
|
<button class="xkbtn">配置</button>
|
||||||
|
<div v-if = "EditTestId >0">
|
||||||
|
<a-tag closable color="processing" @close="logT">
|
||||||
|
<span style="font-size:14px;line-height: 33px;" >删除考试</span>
|
||||||
|
</a-tag></div>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
<!-- 添加考试侧弹窗 -->
|
<!-- 添加考试侧弹窗 -->
|
||||||
<div>
|
<div>
|
||||||
<add-test v-model:addtestVisible="addtestvisible" />
|
<add-test v-model:addtestVisible="addtestvisible"
|
||||||
|
v-model:EditTestId ="EditTestId"
|
||||||
|
:faceLevel="true"
|
||||||
|
/>
|
||||||
</div>
|
</div>
|
||||||
<!-- 添加考试侧弹窗 -->
|
<!-- 添加考试侧弹窗 -->
|
||||||
</div>
|
</div>
|
||||||
@@ -373,11 +335,7 @@
|
|||||||
<button class="btn1">取消</button>
|
<button class="btn1">取消</button>
|
||||||
<button class="btn2" @click="updateFaceTeach">确定</button>
|
<button class="btn2" @click="updateFaceTeach">确定</button>
|
||||||
</div>
|
</div>
|
||||||
<assessment-list
|
|
||||||
v-model:assessmentVisible="assessmentVisible"
|
|
||||||
v-model:isface="isface"
|
|
||||||
@faceAssess="faceAssess"
|
|
||||||
/>
|
|
||||||
</div>
|
</div>
|
||||||
</a-drawer>
|
</a-drawer>
|
||||||
</template>
|
</template>
|
||||||
@@ -394,8 +352,7 @@ import { debounce } from "lodash-es";
|
|||||||
import { queryFaceDetailById, editPlan } from "../../api/indexFace";
|
import { queryFaceDetailById, editPlan } from "../../api/indexFace";
|
||||||
import dayjs from "dayjs";
|
import dayjs from "dayjs";
|
||||||
import AssessmentList from "../drawers/ AssessmentList.vue";
|
import AssessmentList from "../drawers/ AssessmentList.vue";
|
||||||
// import { toDate } from "../../api/method";
|
// import { toDate } from "../../api/method";、
|
||||||
import { queryWorkDetailById } from "../../api/indexWork";
|
|
||||||
import { addTempTask } from "../../api/indexTaskadd";
|
import { addTempTask } from "../../api/indexTaskadd";
|
||||||
export default {
|
export default {
|
||||||
name: "AddFaceteach",
|
name: "AddFaceteach",
|
||||||
@@ -458,64 +415,53 @@ export default {
|
|||||||
selfacetvisible: false,
|
selfacetvisible: false,
|
||||||
addhomeworkvisible: false,
|
addhomeworkvisible: false,
|
||||||
addtestvisible: false,
|
addtestvisible: false,
|
||||||
memberValue: null,
|
memberValue: {
|
||||||
|
value:"",
|
||||||
|
label:""
|
||||||
|
},
|
||||||
fetching: false,
|
fetching: false,
|
||||||
totalPages: 0,
|
totalPages: 0,
|
||||||
currentPage: 1,
|
currentPage: 1,
|
||||||
tableDataTotal: 100,
|
tableDataTotal: 100,
|
||||||
memberId: 0,
|
memberId: 0,
|
||||||
pageSize: 10,
|
pageSize: 10,
|
||||||
inputV1: "",
|
courseName: "",
|
||||||
inputV2: "",
|
duration: "",
|
||||||
inputV3: "",
|
address: null,
|
||||||
inputV4: null,
|
beforeStart: null,
|
||||||
inputV5: null,
|
afterStart: null,
|
||||||
inputV6: null,
|
description: "",
|
||||||
inputV7: null,
|
|
||||||
testV1: "",
|
|
||||||
radioV1: "",
|
|
||||||
radioV2: "",
|
|
||||||
textV1: "",
|
|
||||||
checkedHolidy: false,
|
|
||||||
checkedAssessment: false,
|
|
||||||
chooseTime: [],
|
chooseTime: [],
|
||||||
fileList: [],
|
fileList: [],
|
||||||
chooseCourse: null, //选择的在线课程
|
chooseCourse: null, //选择的在线课程
|
||||||
chooseCourseName: null, //选择的课程的名字
|
assessmentId:null,
|
||||||
face: true, //面授传给配置作业的标识
|
EditTestId:null,
|
||||||
chooseWork: null, //配置的work
|
EditWorkId:null,
|
||||||
chooseWorkName: null, //配置的work名字
|
|
||||||
chooseWorkId: null, //配置的work ID
|
|
||||||
chooseMent: null,
|
|
||||||
chooseMentName: null,
|
|
||||||
assessmentVisible: false,
|
assessmentVisible: false,
|
||||||
isface: 1,
|
|
||||||
|
|
||||||
});
|
});
|
||||||
const clear = () => {
|
const clear = () => {
|
||||||
state.inputV1 = null;
|
state.courseName = null;
|
||||||
state.inputV2 = null;
|
state.memberValue = null;
|
||||||
state.inputV3 = null;
|
state.duration = null;
|
||||||
state.inputV4 = null;
|
state.address = null;
|
||||||
state.inputV5 = null;
|
state.beforeStart = null;
|
||||||
state.inputV6 = null;
|
state.afterStart = null;
|
||||||
state.inputV7 = null;
|
|
||||||
state.chooseTime = [];
|
state.chooseTime = [];
|
||||||
state.textV1 = null;
|
state.description = null;
|
||||||
state.radioV1 = "";
|
state.onlySign =false;
|
||||||
state.radioV2 = "";
|
state.completeLeave =false;
|
||||||
state.checkedHolidy = false;
|
state.projectMember =false;
|
||||||
state.checkedAssessment = false;
|
state.noProjectMember =false;
|
||||||
state.chooseMent = null;
|
|
||||||
state.chooseWork = null;
|
|
||||||
state.chooseWorkId = null;
|
|
||||||
state.chooseWorkName = null;
|
|
||||||
state.chooseCourse = null;
|
state.chooseCourse = null;
|
||||||
state.chooseCourseName = null;
|
state.EditTestId =null;
|
||||||
|
state.assessmentId=null;
|
||||||
|
state.EditWorkId=null;
|
||||||
|
|
||||||
};
|
};
|
||||||
const closeDrawer = () => {
|
const closeDrawer = () => {
|
||||||
ctx.emit("update:addfaceteachVisible", false);
|
ctx.emit("update:addfaceteachVisible", false);
|
||||||
state.radioV1 = "";
|
|
||||||
state.radioV2 = "";
|
|
||||||
localStorage.setItem("stageId", props.chooseStageId);
|
localStorage.setItem("stageId", props.chooseStageId);
|
||||||
localStorage.setItem("chapterId", props.isactive);
|
localStorage.setItem("chapterId", props.isactive);
|
||||||
clear();
|
clear();
|
||||||
@@ -524,38 +470,48 @@ export default {
|
|||||||
if (bool && props.edit) {
|
if (bool && props.edit) {
|
||||||
// 该页面显示同时 edit为true 时,发送查询请求,
|
// 该页面显示同时 edit为true 时,发送查询请求,
|
||||||
queryFaceTeach();
|
queryFaceTeach();
|
||||||
|
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
const logC= e => {
|
||||||
|
state.chooseCourse=null;
|
||||||
|
console.log(e);
|
||||||
|
};
|
||||||
|
const logW = e => {
|
||||||
|
state.EditWorkId=null;
|
||||||
|
console.log(e);
|
||||||
|
};
|
||||||
|
const logT= e => {
|
||||||
|
state.EditTestId=null;
|
||||||
|
console.log(e);
|
||||||
|
};
|
||||||
|
const logA= e => {
|
||||||
|
state.EditEvalId=null;
|
||||||
|
console.log(e);
|
||||||
|
};
|
||||||
|
|
||||||
const showDrawerSelFacet = () => {
|
const showDrawerSelFacet = () => {
|
||||||
state.selfacetvisible = true;
|
state.selfacetvisible = true;
|
||||||
};
|
};
|
||||||
const showDrawerAddHomework = () => {
|
const showDrawerAddHomework = () => {
|
||||||
state.addhomeworkvisible = true;
|
state.addhomeworkvisible = true;
|
||||||
|
|
||||||
};
|
};
|
||||||
const showDrawerAddTest = () => {
|
const showDrawerAddTest = () => {
|
||||||
state.addtestvisible = true;
|
state.addtestvisible = true;
|
||||||
};
|
};
|
||||||
const cloradio1 = (value) => {
|
|
||||||
if (value != "") {
|
|
||||||
state.radioV1 = "";
|
|
||||||
}
|
|
||||||
};
|
|
||||||
const cloradio2 = (value) => {
|
|
||||||
if (value != "") {
|
|
||||||
state.radioV2 = "";
|
|
||||||
}
|
|
||||||
};
|
|
||||||
//查询面授
|
//查询面授
|
||||||
const queryFaceTeach = () => {
|
const queryFaceTeach = () => {
|
||||||
//暂时写一个假的offcoursePlanId
|
|
||||||
queryFaceDetailById(props.EditFaceId).then((res) => {
|
queryFaceDetailById(props.EditFaceId).then((res) => {
|
||||||
// state.inputV1 = res.data.data.name;
|
|
||||||
// state.inputV2 = res.data.data.teacherId;
|
|
||||||
console.log("获取到了面授课开课详情", res.data.data);
|
console.log("获取到了面授课开课详情", res.data.data);
|
||||||
let result = res.data.data;
|
let result = res.data.data;
|
||||||
state.inputV1 = result.name;
|
state.courseName = result.name;
|
||||||
state.textV1 = result.description;
|
state.description = result.description;
|
||||||
state.inputV2 = result.teacher;
|
state.memberValue= {value:result.teacherId,label:result.teacher}
|
||||||
|
state.duration =result.duration;
|
||||||
if (result.beginTime && result.endTime) {
|
if (result.beginTime && result.endTime) {
|
||||||
state.chooseTime = [
|
state.chooseTime = [
|
||||||
dayjs(result.beginTime, "YYYY-MM-DD"),
|
dayjs(result.beginTime, "YYYY-MM-DD"),
|
||||||
@@ -564,40 +520,19 @@ export default {
|
|||||||
} else {
|
} else {
|
||||||
state.chooseTime = [];
|
state.chooseTime = [];
|
||||||
}
|
}
|
||||||
state.inputV4 = result.address;
|
state.address = result.address;
|
||||||
state.inputV5 = result.beforeStart;
|
state.beforeStart = result.beforeStart;
|
||||||
state.inputV6 = result.afterStart;
|
state.afterStart = result.afterStart;
|
||||||
state.inputV7 = result.beforeEnd;
|
|
||||||
state.fileList = JSON.parse(result.attach);
|
state.fileList = JSON.parse(result.attach);
|
||||||
state.chooseWorkId = result.homeWorkId;
|
state.EditWorkId = result.homeWorkId;
|
||||||
// state.radioV1 = result.
|
state.onlySign = result.completeType.split(",")[0]==1?true:false;
|
||||||
state.checkedHolidy =
|
state.completeLeave =result.completeType.split(",")[1]==1?true:false;
|
||||||
result.completeType == 1
|
state.chooseCourse =result.offcourseId;
|
||||||
? false
|
state.projectMember = result.projectMember.split(",")[0]==1?true:false;
|
||||||
: result.completeType == 2
|
state.noProjectMember = result.projectMember.split(",")[1]==1?true:false;
|
||||||
? false
|
state.EditTestId = result.testId;
|
||||||
: result.completeType == 3
|
state.EditWorkId=result.homeWorkId;
|
||||||
? true
|
state.assessmentId =result.evaluateId;
|
||||||
: false;
|
|
||||||
if (result.projectMember) {
|
|
||||||
state.radioV2 = "1";
|
|
||||||
} else if (result.noProjectMember) {
|
|
||||||
state.radioV2 = "2";
|
|
||||||
} else {
|
|
||||||
state.radioV2 = "";
|
|
||||||
}
|
|
||||||
if (result.completeSet == 1) {
|
|
||||||
state.radioV1 = "1";
|
|
||||||
} else {
|
|
||||||
state.radioV1 = "2";
|
|
||||||
}
|
|
||||||
state.checkedAssessment = result.evalFlag == 1 ? true : false;
|
|
||||||
if (state.chooseWorkId) {
|
|
||||||
queryWorkDetailById({ workId: state.chooseWorkId }).then((res) => {
|
|
||||||
state.chooseWork = res.data.data;
|
|
||||||
state.chooseWorkName = res.data.data.workName;
|
|
||||||
});
|
|
||||||
}
|
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
@@ -605,76 +540,50 @@ export default {
|
|||||||
// 新增任务
|
// 新增任务
|
||||||
const updateFaceTeach = () => {
|
const updateFaceTeach = () => {
|
||||||
if (
|
if (
|
||||||
state.inputV1 == "" ||
|
state.courseName == "" ||
|
||||||
state.chooseCourse == null ||
|
state.chooseCourse == null ||
|
||||||
state.inputV2 == "" ||
|
state.memberValue == "" ||
|
||||||
state.chooseTime == [] ||
|
state.chooseTime == [] ||
|
||||||
state.inputV3 == "" ||
|
state.duration == "" ||
|
||||||
state.inputV4 == ""
|
state.address == ""
|
||||||
) {
|
) {
|
||||||
message.destroy();
|
message.destroy();
|
||||||
return message.warning("请输入必填字段");
|
return message.warning("请输入必填字段");
|
||||||
} else {
|
} else {
|
||||||
let obj = {
|
let obj = {
|
||||||
address: state.inputV4,
|
teacherId:state.memberValue.value,
|
||||||
|
teacher:state.memberValue.label,
|
||||||
|
address:state.address,
|
||||||
applyFlag: 1,
|
applyFlag: 1,
|
||||||
attach: JSON.stringify(state.fileList),
|
attach: JSON.stringify(state.fileList),
|
||||||
afterStart: state.inputV6 || 0,
|
afterStart: state.afterStart || 0,
|
||||||
beforeEnd: state.inputV7 || 0,
|
beforeStart: state.beforeStart || 0,
|
||||||
beforeStart: state.inputV5 || 0,
|
beginTime: parseInt( new Date(state.chooseTime[0].$d).getTime() / 1000),
|
||||||
// beginTime: dayjs(state.chooseTime[0]).format("YYYY-MM-DD hh-mm-ss"),
|
completeType: state.onlySign? "1,":"0," + state.completeLeave?"1":"0",
|
||||||
beginTime: parseInt(
|
description: state.description,
|
||||||
new Date(state.chooseTime[0].$d).getTime() / 1000
|
|
||||||
),
|
|
||||||
// beginTime: "",
|
|
||||||
completeType: state.radioV1 == "1" ? 2 : 1,
|
|
||||||
description: state.textV1,
|
|
||||||
// endTime: dayjs(state.chooseTime[1]).format("YYYY-MM-DD hh-mm-ss"),
|
|
||||||
endTime: parseInt(new Date(state.chooseTime[1].$d).getTime() / 1000),
|
endTime: parseInt(new Date(state.chooseTime[1].$d).getTime() / 1000),
|
||||||
// endTime: "",
|
evalFlag: state.needEval?1:0,
|
||||||
evalFlag: state.checkedAssessment == true ? 1 : 0,
|
evaluateId:state.assessmentId,
|
||||||
evaluateId:
|
homeWorkId: state.EditWorkId,
|
||||||
state.chooseMent == null ? 0 : state.chooseMent.assessmentId,
|
name: state.courseName,
|
||||||
homeWorkId: state.chooseWorkId || 0,
|
projectMember:state.innerPersion?"1":"0" + state.outPerson?"1":"0",
|
||||||
name: state.inputV1,
|
offcourseId:state.chooseCourse,
|
||||||
noProjectMember: state.radioV2 == "1" ? 0 : 1,
|
offcoursePlanId:props.EditFaceId >0 ? props.EditFaceId : 0,
|
||||||
offcourseId: 0,
|
|
||||||
offcoursePlanId: props.edit ? props.EditFaceId : 0,
|
|
||||||
projectMember: state.radioV2 == "1" ? 1 : 0,
|
|
||||||
signFlag: 0,
|
signFlag: 0,
|
||||||
signWordFlag: 0,
|
testId: state.EditTestId
|
||||||
teacherId: state.memberId,
|
|
||||||
testId: 0,
|
|
||||||
// teacher: state.inputV2,
|
|
||||||
};
|
};
|
||||||
|
|
||||||
if (props.edit) {
|
|
||||||
editPlan(obj)
|
editPlan(obj)
|
||||||
.then((res) => {
|
.then((res) => {
|
||||||
updateTask(res);
|
updateTask(res);
|
||||||
closeDrawer();
|
closeDrawer();
|
||||||
})
|
}).catch((err) => {
|
||||||
.catch((err) => {
|
|
||||||
message.error(`添加失败${err}`);
|
message.error(`添加失败${err}`);
|
||||||
});
|
});
|
||||||
} else {
|
|
||||||
editPlan(obj)
|
|
||||||
.then((res) => {
|
|
||||||
updateTask(res);
|
|
||||||
closeDrawer();
|
|
||||||
})
|
|
||||||
.catch((err) => {
|
|
||||||
message.error(`添加失败${err}`);
|
|
||||||
});
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
const upDateTable = (value) => {
|
|
||||||
console.log("gg", value);
|
|
||||||
console.log("gg", value[0].name);
|
|
||||||
state.chooseCourse = value[0];
|
|
||||||
state.chooseCourseName = value[0].name;
|
|
||||||
};
|
|
||||||
|
|
||||||
//更新任务列表
|
//更新任务列表
|
||||||
// 新增编辑或新增项目任务
|
// 新增编辑或新增项目任务
|
||||||
@@ -705,7 +614,7 @@ export default {
|
|||||||
name: res.data.data.name,
|
name: res.data.data.name,
|
||||||
projectId: props.projectId,
|
projectId: props.projectId,
|
||||||
projectTaskId: props.projectTaskId || 0,
|
projectTaskId: props.projectTaskId || 0,
|
||||||
stageId: props.chooseStageId,
|
stageId: props.chooseStageId || 0,
|
||||||
type: 2,
|
type: 2,
|
||||||
};
|
};
|
||||||
// 新增编辑或新增项目
|
// 新增编辑或新增项目
|
||||||
@@ -722,11 +631,11 @@ export default {
|
|||||||
} else if (props.isLevel == 3) {
|
} else if (props.isLevel == 3) {
|
||||||
addTempTask({
|
addTempTask({
|
||||||
courseId: res.data.data.offcoursePlanId,
|
courseId: res.data.data.offcoursePlanId,
|
||||||
duration: 0,
|
|
||||||
name: res.data.data.name,
|
name: res.data.data.name,
|
||||||
projectId: props.projectId,
|
duration: res.data.data.duration,
|
||||||
|
projectTemplateId: props.projectTemplateId,
|
||||||
projectTaskId: props.projectTaskId || 0,
|
projectTaskId: props.projectTaskId || 0,
|
||||||
stageId: props.chooseStageId,
|
stageId: props.chooseStageId || 0,
|
||||||
type: 2,
|
type: 2,
|
||||||
})
|
})
|
||||||
.then(() => {
|
.then(() => {
|
||||||
@@ -740,23 +649,7 @@ export default {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
const closeTag = () => {
|
|
||||||
state.chooseCourse = null;
|
|
||||||
state.chooseCourseName = null;
|
|
||||||
};
|
|
||||||
const closeTagWork = () => {
|
|
||||||
state.chooseWork = null;
|
|
||||||
state.chooseWorkName = null;
|
|
||||||
state.chooseWorkId = null;
|
|
||||||
};
|
|
||||||
const getWork = (value) => {
|
|
||||||
console.log("getWork", value);
|
|
||||||
state.chooseWork = value;
|
|
||||||
state.chooseWorkName = value.workName;
|
|
||||||
state.chooseWorkId = value.workId;
|
|
||||||
|
|
||||||
// console.log("getWorkName", value.workName);
|
|
||||||
};
|
|
||||||
const handleChange = ({ file, fileList }) => {
|
const handleChange = ({ file, fileList }) => {
|
||||||
if (file.status !== "uploading") {
|
if (file.status !== "uploading") {
|
||||||
console.log(file, fileList);
|
console.log(file, fileList);
|
||||||
@@ -764,6 +657,7 @@ export default {
|
|||||||
};
|
};
|
||||||
const showAssessment = () => {
|
const showAssessment = () => {
|
||||||
state.assessmentVisible = true;
|
state.assessmentVisible = true;
|
||||||
|
|
||||||
};
|
};
|
||||||
const faceAssess = (value) => {
|
const faceAssess = (value) => {
|
||||||
console.log(value);
|
console.log(value);
|
||||||
@@ -825,7 +719,7 @@ export default {
|
|||||||
const handleChange2 = (value, label) => {
|
const handleChange2 = (value, label) => {
|
||||||
console.log(`selected ${value}`);
|
console.log(`selected ${value}`);
|
||||||
state.memberId = value;
|
state.memberId = value;
|
||||||
state.inputV2 = label;
|
state.memberValue = label;
|
||||||
};
|
};
|
||||||
const handleFocus = () => {
|
const handleFocus = () => {
|
||||||
queryMember();
|
queryMember();
|
||||||
@@ -837,14 +731,8 @@ export default {
|
|||||||
showDrawerAddTest,
|
showDrawerAddTest,
|
||||||
afterVisibleChange,
|
afterVisibleChange,
|
||||||
closeDrawer,
|
closeDrawer,
|
||||||
cloradio1,
|
|
||||||
cloradio2,
|
|
||||||
updateFaceTeach,
|
updateFaceTeach,
|
||||||
updateTask,
|
updateTask,
|
||||||
upDateTable,
|
|
||||||
closeTag,
|
|
||||||
getWork,
|
|
||||||
closeTagWork,
|
|
||||||
clear,
|
clear,
|
||||||
handleChange,
|
handleChange,
|
||||||
showAssessment,
|
showAssessment,
|
||||||
@@ -855,6 +743,11 @@ export default {
|
|||||||
handleSearch,
|
handleSearch,
|
||||||
handleChange2,
|
handleChange2,
|
||||||
templateScroll,
|
templateScroll,
|
||||||
|
logC,
|
||||||
|
logT,
|
||||||
|
logW,
|
||||||
|
logA,
|
||||||
|
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
@@ -926,7 +819,7 @@ export default {
|
|||||||
.main_item2 {
|
.main_item2 {
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: flex-start;
|
align-items: flex-start;
|
||||||
// margin-bottom: 32px;
|
margin-bottom: 32px;
|
||||||
|
|
||||||
.signbox {
|
.signbox {
|
||||||
width: 120px;
|
width: 120px;
|
||||||
@@ -987,8 +880,7 @@ export default {
|
|||||||
border: 0;
|
border: 0;
|
||||||
margin-right: 16px 8px 32px 0;
|
margin-right: 16px 8px 32px 0;
|
||||||
color: #fff;
|
color: #fff;
|
||||||
margin-top: 16px;
|
|
||||||
margin-bottom: 60px;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -165,10 +165,14 @@ export default {
|
|||||||
type: Number,
|
type: Number,
|
||||||
default: null,
|
default: null,
|
||||||
},
|
},
|
||||||
face: {
|
faceLevel: {
|
||||||
type: Boolean,
|
type: Boolean,
|
||||||
default: false,
|
default: false,
|
||||||
},
|
},
|
||||||
|
projectTemplateId:{
|
||||||
|
type: Number,
|
||||||
|
default: null,
|
||||||
|
},
|
||||||
},
|
},
|
||||||
setup(props, ctx) {
|
setup(props, ctx) {
|
||||||
const formState = reactive({
|
const formState = reactive({
|
||||||
@@ -259,18 +263,21 @@ export default {
|
|||||||
|
|
||||||
const fileList = ref([]);
|
const fileList = ref([]);
|
||||||
const closeDrawer = () => {
|
const closeDrawer = () => {
|
||||||
resetForm();
|
|
||||||
fileList.value = [];
|
|
||||||
formState.choosedTime = "";
|
formState.choosedTime = "";
|
||||||
ctx.emit("update:addhomeworkVisible", false);
|
ctx.emit("update:addhomeworkVisible", false);
|
||||||
ctx.emit("update:edit", false);
|
ctx.emit("update:edit", false);
|
||||||
ctx.emit("changeData", false);
|
ctx.emit("update:EditWorkId", state.EditWorkId);
|
||||||
|
console.log("state.EditWorkId==============",state.EditWorkId);
|
||||||
localStorage.setItem("stageId", props.chooseStageId);
|
localStorage.setItem("stageId", props.chooseStageId);
|
||||||
localStorage.setItem("chapterId", props.isactive);
|
localStorage.setItem("chapterId", props.isactive);
|
||||||
|
fileList.value = [];
|
||||||
|
resetForm();
|
||||||
};
|
};
|
||||||
const afterVisibleChange = () => {
|
const afterVisibleChange = () => {
|
||||||
if (props.addhomeworkVisible && props.edit) {
|
if (props.EditWorkId >0) {
|
||||||
// 该页面显示同时 edit为true 时,发送查询请求,
|
state.EditWorkId = props.EditWorkId;
|
||||||
queryWork();
|
queryWork();
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
@@ -285,7 +292,7 @@ export default {
|
|||||||
workName: formState.workName,
|
workName: formState.workName,
|
||||||
workRequirement: formState.workRequirement,
|
workRequirement: formState.workRequirement,
|
||||||
};
|
};
|
||||||
if (props.edit) {
|
if (props.EditWorkId >0) {
|
||||||
updateWorkTaskUsing(obj)
|
updateWorkTaskUsing(obj)
|
||||||
.then((res) => {
|
.then((res) => {
|
||||||
updateTask(res);
|
updateTask(res);
|
||||||
@@ -325,6 +332,11 @@ export default {
|
|||||||
};
|
};
|
||||||
// 新增编辑或新增项目任务
|
// 新增编辑或新增项目任务
|
||||||
const updateTask = (res) => {
|
const updateTask = (res) => {
|
||||||
|
|
||||||
|
if(props.faceLevel){
|
||||||
|
state.EditWorkId = res.data.data.workId
|
||||||
|
|
||||||
|
}else{
|
||||||
if (props.isLevel == 1) {
|
if (props.isLevel == 1) {
|
||||||
let editObj1 = {
|
let editObj1 = {
|
||||||
chapterId: props.isactive,
|
chapterId: props.isactive,
|
||||||
@@ -337,50 +349,52 @@ export default {
|
|||||||
|
|
||||||
RouterEditTask(editObj1)
|
RouterEditTask(editObj1)
|
||||||
.then(() => {
|
.then(() => {
|
||||||
message.success(`${props.edit ? "编辑" : "新增"}关卡任务成功`);
|
message.success(`${props.EditWorkId > 0 ? "编辑" : "新增"}关卡任务成功`);
|
||||||
ctx.emit("changeData", false);
|
ctx.emit("changeData", false);
|
||||||
state.addLoading = false;
|
state.addLoading = false;
|
||||||
})
|
})
|
||||||
.catch(() => {
|
.catch(() => {
|
||||||
message.error(`${props.edit ? "编辑" : "新增"}关卡任务失败`);
|
message.error(`${props.EditWorkId > 0 ? "编辑" : "新增"}关卡任务失败`);
|
||||||
});
|
});
|
||||||
} else if (props.isLevel == 2) {
|
} else if (props.isLevel == 2) {
|
||||||
let editObj = {
|
let editObj = {
|
||||||
courseId: res.data.data.workId,
|
courseId: res.data.data.workId,
|
||||||
name: res.data.data.workName,
|
name: res.data.data.workName,
|
||||||
projectId: props.edit ? props.projectId : 0,
|
projectId: props.EditWorkId > 0 ? props.projectId : 0,
|
||||||
projectTaskId: props.projectTaskId || 0,
|
projectTaskId: props.projectTaskId || 0,
|
||||||
stageId: props.chooseStageId,
|
stageId: props.chooseStageId || 0 ,
|
||||||
type: 4,
|
type: 4,
|
||||||
};
|
};
|
||||||
ProjectEditTask(editObj)
|
ProjectEditTask(editObj)
|
||||||
.then(() => {
|
.then(() => {
|
||||||
message.success(`${props.edit ? "编辑" : "新增"}阶段任务成功`);
|
message.success(`${props.EditWorkId > 0 ? "编辑" : "新增"}阶段任务成功`);
|
||||||
ctx.emit("changeData", false);
|
ctx.emit("changeData", false);
|
||||||
state.addLoading = false;
|
state.addLoading = false;
|
||||||
})
|
})
|
||||||
.catch(() => {
|
.catch(() => {
|
||||||
message.error(`${props.edit ? "编辑" : "新增"}阶段任务失败`);
|
message.error(`${props.EditWorkId > 0 ? "编辑" : "新增"}阶段任务失败`);
|
||||||
});
|
});
|
||||||
} else if (props.isLevel == 3) {
|
} else if (props.isLevel == 3) {
|
||||||
console.log("");
|
console.log("projectTemplateId,===",props.projectTemplateId);
|
||||||
addTempTask({
|
addTempTask({
|
||||||
courseId: res.data.data.workId,
|
courseId: res.data.data.workId,
|
||||||
name: res.data.data.workName,
|
name: res.data.data.workName,
|
||||||
projectId: props.edit ? props.projectId : 0,
|
projectTemplateId:props.projectTemplateId,
|
||||||
projectTaskId: props.projectTaskId || 0,
|
projectTaskId: props.projectTaskId || 0,
|
||||||
stageId: props.chooseStageId,
|
stageId: props.chooseStageId || 0,
|
||||||
type: 4,
|
type: 4,
|
||||||
})
|
})
|
||||||
.then(() => {
|
.then(() => {
|
||||||
message.success(`${props.edit ? "编辑" : "新增"}阶段任务成功`);
|
message.success(`${props.EditWorkId > 0 ? "编辑" : "新增"}阶段任务成功`);
|
||||||
ctx.emit("changeData", false);
|
ctx.emit("changeData", false);
|
||||||
state.addLoading = false;
|
state.addLoading = false;
|
||||||
})
|
})
|
||||||
.catch(() => {
|
.catch(() => {
|
||||||
message.error(`${props.edit ? "编辑" : "新增"}阶段任务失败`);
|
message.error(`${props.EditWorkId > 0 ? "编辑" : "新增"}阶段任务失败`);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
const cle = () => {
|
const cle = () => {
|
||||||
@@ -389,7 +403,7 @@ export default {
|
|||||||
submitEndTime: dayjs(formState.choosedTime[1]).format("YYYY-MM-DD"),
|
submitEndTime: dayjs(formState.choosedTime[1]).format("YYYY-MM-DD"),
|
||||||
submitStartTime: dayjs(formState.choosedTime[0]).format("YYYY-MM-DD"),
|
submitStartTime: dayjs(formState.choosedTime[0]).format("YYYY-MM-DD"),
|
||||||
workEnclosureAddress: "",
|
workEnclosureAddress: "",
|
||||||
workId: props.edit ? props.EditWorkId : 0,
|
workId: props.EditWorkId > 0 ? props.EditWorkId : 0,
|
||||||
workName: formState.workName,
|
workName: formState.workName,
|
||||||
workRequirement: formState.workRequirement,
|
workRequirement: formState.workRequirement,
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -157,6 +157,10 @@ export default {
|
|||||||
type: Number,
|
type: Number,
|
||||||
default: null,
|
default: null,
|
||||||
},
|
},
|
||||||
|
projectTemplateId:{
|
||||||
|
type: Number,
|
||||||
|
default: null,
|
||||||
|
}
|
||||||
},
|
},
|
||||||
setup(props, ctx) {
|
setup(props, ctx) {
|
||||||
const state = reactive({
|
const state = reactive({
|
||||||
@@ -236,7 +240,7 @@ export default {
|
|||||||
name: state.assessment.name,
|
name: state.assessment.name,
|
||||||
projectId: props.projectId,
|
projectId: props.projectId,
|
||||||
projectTaskId: props.projectTaskId || 0,
|
projectTaskId: props.projectTaskId || 0,
|
||||||
stageId: props.chooseStageId,
|
stageId: props.chooseStageId || 0,
|
||||||
type: 11,
|
type: 11,
|
||||||
})
|
})
|
||||||
.then(() => {
|
.then(() => {
|
||||||
@@ -248,13 +252,12 @@ export default {
|
|||||||
message.error(`${props.edit ? "编辑" : "新增"}阶段任务失败`);
|
message.error(`${props.edit ? "编辑" : "新增"}阶段任务失败`);
|
||||||
});
|
});
|
||||||
} else if (props.isLevel == 3) {
|
} else if (props.isLevel == 3) {
|
||||||
console.log("");
|
|
||||||
addTempTask({
|
addTempTask({
|
||||||
courseId: state.assessment.assessmentId,
|
courseId: state.assessment.assessmentId,
|
||||||
name: state.assessment.name,
|
name: state.assessment.name,
|
||||||
projectId: props.projectId,
|
projectTemplateId: props.projectTemplateId,
|
||||||
projectTaskId: props.projectTaskId || 0,
|
projectTaskId: props.projectTaskId || 0,
|
||||||
stageId: props.chooseStageId,
|
stageId: props.chooseStageId || 0,
|
||||||
type: 11,
|
type: 11,
|
||||||
})
|
})
|
||||||
.then(() => {
|
.then(() => {
|
||||||
|
|||||||
@@ -382,6 +382,10 @@ export default {
|
|||||||
type: Number,
|
type: Number,
|
||||||
default: null,
|
default: null,
|
||||||
},
|
},
|
||||||
|
projectTemplateId:{
|
||||||
|
type: Number,
|
||||||
|
default: null,
|
||||||
|
},
|
||||||
},
|
},
|
||||||
setup(props, ctx) {
|
setup(props, ctx) {
|
||||||
// const router = useRouter();
|
// const router = useRouter();
|
||||||
@@ -559,7 +563,7 @@ export default {
|
|||||||
name: res.data.data.liveName,
|
name: res.data.data.liveName,
|
||||||
projectId: props.projectId,
|
projectId: props.projectId,
|
||||||
projectTaskId: props.projectTaskId || 0,
|
projectTaskId: props.projectTaskId || 0,
|
||||||
stageId: props.chooseStageId,
|
stageId: props.chooseStageId || 0,
|
||||||
type: 6,
|
type: 6,
|
||||||
})
|
})
|
||||||
.then(() => {
|
.then(() => {
|
||||||
@@ -570,14 +574,14 @@ export default {
|
|||||||
message.error(`${props.edit ? "编辑" : "新增"}阶段任务失败`);
|
message.error(`${props.edit ? "编辑" : "新增"}阶段任务失败`);
|
||||||
});
|
});
|
||||||
} else if (props.isLevel == 3) {
|
} else if (props.isLevel == 3) {
|
||||||
console.log("");
|
console.log("props.projectTemplateId",props.projectTemplateId);
|
||||||
addTempTask({
|
addTempTask({
|
||||||
courseId: res.data.data.liveId,
|
courseId: res.data.data.liveId,
|
||||||
duration: res.data.data.duration,
|
duration: res.data.data.duration,
|
||||||
name: res.data.data.liveName,
|
name: res.data.data.liveName,
|
||||||
projectId: props.projectId,
|
projectTemplateId:props.projectTemplateId,
|
||||||
projectTaskId: props.projectTaskId || 0,
|
projectTaskId: props.projectTaskId || 0,
|
||||||
stageId: props.chooseStageId,
|
stageId: props.chooseStageId || 0,
|
||||||
type: 6,
|
type: 6,
|
||||||
})
|
})
|
||||||
.then(() => {
|
.then(() => {
|
||||||
|
|||||||
@@ -371,7 +371,7 @@ export default {
|
|||||||
name: value.name,
|
name: value.name,
|
||||||
projectId: props.projectId,
|
projectId: props.projectId,
|
||||||
projectTaskId: props.projectTaskId || 0,
|
projectTaskId: props.projectTaskId || 0,
|
||||||
stageId: props.chooseStageId,
|
stageId: props.chooseStageId || 0,
|
||||||
type: 1,
|
type: 1,
|
||||||
})
|
})
|
||||||
.then(() => {
|
.then(() => {
|
||||||
@@ -389,9 +389,9 @@ export default {
|
|||||||
addTempTask({
|
addTempTask({
|
||||||
courseId: state.onlineClassesId,
|
courseId: state.onlineClassesId,
|
||||||
name: state.onlineName,
|
name: state.onlineName,
|
||||||
projectId: props.projectId,
|
projectTemplateId: props.projectTemplateId,
|
||||||
projectTaskId: props.projectTaskId || 0,
|
projectTaskId: props.projectTaskId || 0,
|
||||||
stageId: props.chooseStageId,
|
stageId: props.chooseStageId || 0,
|
||||||
type: 1,
|
type: 1,
|
||||||
})
|
})
|
||||||
.then(() => {
|
.then(() => {
|
||||||
|
|||||||
@@ -140,6 +140,10 @@ export default {
|
|||||||
type: Number,
|
type: Number,
|
||||||
default: null,
|
default: null,
|
||||||
},
|
},
|
||||||
|
projectTemplateId:{
|
||||||
|
type: Number,
|
||||||
|
default: null,
|
||||||
|
},
|
||||||
},
|
},
|
||||||
setup(props, ctx) {
|
setup(props, ctx) {
|
||||||
const state = reactive({
|
const state = reactive({
|
||||||
@@ -198,7 +202,7 @@ export default {
|
|||||||
name: res.data.data.linkName,
|
name: res.data.data.linkName,
|
||||||
projectId: props.projectId,
|
projectId: props.projectId,
|
||||||
projectTaskId: props.projectTaskId || 0,
|
projectTaskId: props.projectTaskId || 0,
|
||||||
stageId: props.chooseStageId,
|
stageId: props.chooseStageId || 0,
|
||||||
type: 7,
|
type: 7,
|
||||||
})
|
})
|
||||||
.then(() => {
|
.then(() => {
|
||||||
@@ -212,13 +216,13 @@ export default {
|
|||||||
message.error(`${props.EditTestId ? "编辑" : "新增"}阶段任务失败`);
|
message.error(`${props.EditTestId ? "编辑" : "新增"}阶段任务失败`);
|
||||||
});
|
});
|
||||||
} else if (props.isLevel == 3) {
|
} else if (props.isLevel == 3) {
|
||||||
console.log("");
|
|
||||||
addTempTask({
|
addTempTask({
|
||||||
courseId: res.data.data.linkId,
|
courseId: res.data.data.linkId,
|
||||||
name: res.data.data.linkName,
|
name: res.data.data.linkName,
|
||||||
projectId: props.projectId,
|
projectTemplateId:props.projectTemplateId,
|
||||||
projectTaskId: props.projectTaskId || 0,
|
projectTaskId: props.projectTaskId || 0,
|
||||||
stageId: props.chooseStageId,
|
stageId: props.chooseStageId || 0,
|
||||||
type: 7,
|
type: 7,
|
||||||
})
|
})
|
||||||
.then(() => {
|
.then(() => {
|
||||||
|
|||||||
@@ -15,6 +15,7 @@
|
|||||||
@click="closeDrawer"
|
@click="closeDrawer"
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div style="display: flex; flex-direction: row">
|
<div style="display: flex; flex-direction: row">
|
||||||
<button
|
<button
|
||||||
style="width: 100px"
|
style="width: 100px"
|
||||||
@@ -77,7 +78,7 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="main_item">
|
<div class="main_item">
|
||||||
<div class="btnbox">
|
<div class="btnbox">
|
||||||
<a-form-item has-feedback label="选择试卷" name="choosedTest">
|
<a-form-item has-feedback label="选择考试" name="choosedTest">
|
||||||
<a-button
|
<a-button
|
||||||
type="primary"
|
type="primary"
|
||||||
style="width: 100px; margin-left: 35px"
|
style="width: 100px; margin-left: 35px"
|
||||||
@@ -85,7 +86,7 @@
|
|||||||
@click.prevent
|
@click.prevent
|
||||||
@click="selectTest()"
|
@click="selectTest()"
|
||||||
>
|
>
|
||||||
选择试卷
|
选择考试
|
||||||
</a-button>
|
</a-button>
|
||||||
<!-- <a-dropdown>
|
<!-- <a-dropdown>
|
||||||
<a-button
|
<a-button
|
||||||
@@ -342,7 +343,7 @@ export default {
|
|||||||
EditTestId: {
|
EditTestId: {
|
||||||
// 要编辑的考试id
|
// 要编辑的考试id
|
||||||
type: Number,
|
type: Number,
|
||||||
default: -1,
|
default: null,
|
||||||
},
|
},
|
||||||
isactive: {
|
isactive: {
|
||||||
type: Number,
|
type: Number,
|
||||||
@@ -379,13 +380,21 @@ export default {
|
|||||||
type: Boolean,
|
type: Boolean,
|
||||||
default: null,
|
default: null,
|
||||||
},
|
},
|
||||||
|
faceLevel: {
|
||||||
|
type: Boolean,
|
||||||
|
default: false,
|
||||||
|
},
|
||||||
|
projectTemplateId:{
|
||||||
|
type: Number,
|
||||||
|
default: null,
|
||||||
|
},
|
||||||
},
|
},
|
||||||
setup(props, ctx) {
|
setup(props, ctx) {
|
||||||
const formState = reactive({
|
const formState = reactive({
|
||||||
examinationName: "",
|
examinationName: "",
|
||||||
examinationDuration: "",
|
examinationDuration: "",
|
||||||
examinationLimit: "",
|
examinationLimit: "",
|
||||||
passLine: 60,
|
passLine:null,
|
||||||
examinationEndTime: "",
|
examinationEndTime: "",
|
||||||
examinationExplain: "",
|
examinationExplain: "",
|
||||||
questionArrangement: 1,
|
questionArrangement: 1,
|
||||||
@@ -432,11 +441,12 @@ export default {
|
|||||||
return Promise.reject("请输入考试说明");
|
return Promise.reject("请输入考试说明");
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
/*
|
||||||
let checkChoosedTest = async (_rule, value) => {
|
let checkChoosedTest = async (_rule, value) => {
|
||||||
if (!value) {
|
if (!value) {
|
||||||
return Promise.reject("请选择考试");
|
return Promise.reject("请选择考试");
|
||||||
}
|
}
|
||||||
};
|
};*/
|
||||||
let checkChoosedTime = async (_rule, value) => {
|
let checkChoosedTime = async (_rule, value) => {
|
||||||
if (!value.length) {
|
if (!value.length) {
|
||||||
return Promise.reject("请选择时间");
|
return Promise.reject("请选择时间");
|
||||||
@@ -467,11 +477,7 @@ export default {
|
|||||||
return Promise.reject("请输入作业名称");
|
return Promise.reject("请输入作业名称");
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
let checkPassLine = async (_rule, value) => {
|
|
||||||
if (!value) {
|
|
||||||
return Promise.reject("请输入及格线");
|
|
||||||
}
|
|
||||||
};
|
|
||||||
let checkQuestionArrangement = async (_rule, value) => {
|
let checkQuestionArrangement = async (_rule, value) => {
|
||||||
if (!value) {
|
if (!value) {
|
||||||
return Promise.reject("请输入作业名称");
|
return Promise.reject("请输入作业名称");
|
||||||
@@ -491,13 +497,14 @@ export default {
|
|||||||
trigger: "change",
|
trigger: "change",
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
|
/*
|
||||||
choosedTest: [
|
choosedTest: [
|
||||||
{
|
{
|
||||||
required: true,
|
required: true,
|
||||||
validator: checkChoosedTest,
|
validator: checkChoosedTest,
|
||||||
trigger: "change",
|
trigger: "change",
|
||||||
},
|
},
|
||||||
],
|
],*/
|
||||||
choosedTime: [
|
choosedTime: [
|
||||||
{
|
{
|
||||||
required: true,
|
required: true,
|
||||||
@@ -537,13 +544,7 @@ export default {
|
|||||||
trigger: "change",
|
trigger: "change",
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
passLine: [
|
|
||||||
{
|
|
||||||
required: true,
|
|
||||||
validator: checkPassLine,
|
|
||||||
trigger: "change",
|
|
||||||
},
|
|
||||||
],
|
|
||||||
questionArrangement: [
|
questionArrangement: [
|
||||||
{
|
{
|
||||||
validator: checkQuestionArrangement,
|
validator: checkQuestionArrangement,
|
||||||
@@ -578,13 +579,14 @@ export default {
|
|||||||
console.log(args);
|
console.log(args);
|
||||||
};
|
};
|
||||||
const closeDrawer = () => {
|
const closeDrawer = () => {
|
||||||
resetForm();
|
|
||||||
formState.choosedTime = "";
|
formState.choosedTime = "";
|
||||||
ctx.emit("update:addtestVisible", false);
|
ctx.emit("update:addtestVisible", false);
|
||||||
ctx.emit("update:edit", false);
|
ctx.emit("update:edit", false);
|
||||||
// ctx.emit("changeData", false);
|
ctx.emit("update:EditTestId", state.EditTestId);
|
||||||
localStorage.setItem("stageId", props.chooseStageId);
|
localStorage.setItem("stageId", props.chooseStageId);
|
||||||
localStorage.setItem("chapterId", props.isactive);
|
localStorage.setItem("chapterId", props.isactive);
|
||||||
|
resetForm();
|
||||||
};
|
};
|
||||||
const afterVisibleChange = () => {
|
const afterVisibleChange = () => {
|
||||||
if (props.addtestVisible && props.edit) {
|
if (props.addtestVisible && props.edit) {
|
||||||
@@ -598,7 +600,7 @@ export default {
|
|||||||
};
|
};
|
||||||
|
|
||||||
const queryTest = () => {
|
const queryTest = () => {
|
||||||
state.addLoading = true;
|
// state.addLoading = true;
|
||||||
queryExaminationDetailById({ examinationId: props.EditTestId })
|
queryExaminationDetailById({ examinationId: props.EditTestId })
|
||||||
.then((res) => {
|
.then((res) => {
|
||||||
formState.examinationName = res.data.data.examinationName;
|
formState.examinationName = res.data.data.examinationName;
|
||||||
@@ -631,7 +633,7 @@ export default {
|
|||||||
});
|
});
|
||||||
};
|
};
|
||||||
const updateTest = () => {
|
const updateTest = () => {
|
||||||
state.addLoading = true;
|
//state.addLoading = true;
|
||||||
let obj = {
|
let obj = {
|
||||||
examinationDuration: formState.examinationDuration,
|
examinationDuration: formState.examinationDuration,
|
||||||
examinationEndTime: dayjs(formState.choosedTime[1]).format(
|
examinationEndTime: dayjs(formState.choosedTime[1]).format(
|
||||||
@@ -642,7 +644,7 @@ export default {
|
|||||||
examinationLimit: formState.examinationLimit,
|
examinationLimit: formState.examinationLimit,
|
||||||
examinationName: formState.examinationName,
|
examinationName: formState.examinationName,
|
||||||
examinationPaperId: 0,
|
examinationPaperId: 0,
|
||||||
examinationPaperName: formState.choosedTest,
|
// examinationPaperName: formState.choosedTest,
|
||||||
examinationStartTime: dayjs(formState.choosedTime[0]).format(
|
examinationStartTime: dayjs(formState.choosedTime[0]).format(
|
||||||
"YYYY-MM-DD"
|
"YYYY-MM-DD"
|
||||||
),
|
),
|
||||||
@@ -676,6 +678,12 @@ export default {
|
|||||||
};
|
};
|
||||||
|
|
||||||
const updateTask = (res) => {
|
const updateTask = (res) => {
|
||||||
|
state.EditTestId = res.data.data.examinationId;
|
||||||
|
console.log("state.EditTestId=====0",state.EditTestId,props.faceLevel);
|
||||||
|
if(props.faceLevel){
|
||||||
|
state.EditTestId = res.data.data.examinationId;
|
||||||
|
console.log("state.EditTestId=====",state.EditTestId);
|
||||||
|
}else{
|
||||||
if (props.isLevel == 1) {
|
if (props.isLevel == 1) {
|
||||||
let editObj1 = {
|
let editObj1 = {
|
||||||
chapterId: props.isactive,
|
chapterId: props.isactive,
|
||||||
@@ -702,7 +710,7 @@ export default {
|
|||||||
name: res.data.data.examinationName,
|
name: res.data.data.examinationName,
|
||||||
projectId: props.projectId,
|
projectId: props.projectId,
|
||||||
projectTaskId: props.projectTaskId || 0,
|
projectTaskId: props.projectTaskId || 0,
|
||||||
stageId: props.chooseStageId,
|
stageId: props.chooseStageId || 0,
|
||||||
type: 5,
|
type: 5,
|
||||||
};
|
};
|
||||||
// 新增编辑或新增项目
|
// 新增编辑或新增项目
|
||||||
@@ -720,11 +728,11 @@ export default {
|
|||||||
console.log("");
|
console.log("");
|
||||||
addTempTask({
|
addTempTask({
|
||||||
courseId: res.data.data.examinationId,
|
courseId: res.data.data.examinationId,
|
||||||
duration: 0,
|
duration: res.data.data.examinationDuration,
|
||||||
name: res.data.data.examinationName,
|
name: res.data.data.examinationName,
|
||||||
projectId: props.projectId,
|
projectTemplateId: props.projectTemplateId,
|
||||||
projectTaskId: props.projectTaskId || 0,
|
projectTaskId: props.projectTaskId || 0,
|
||||||
stageId: props.chooseStageId,
|
stageId: props.chooseStageId || 0,
|
||||||
type: 5,
|
type: 5,
|
||||||
})
|
})
|
||||||
.then(() => {
|
.then(() => {
|
||||||
@@ -737,6 +745,8 @@ export default {
|
|||||||
message.error(`${props.EditTestId ? "编辑" : "新增"}阶段任务失败`);
|
message.error(`${props.EditTestId ? "编辑" : "新增"}阶段任务失败`);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
const cloradio1 = (value) => {
|
const cloradio1 = (value) => {
|
||||||
@@ -877,7 +887,7 @@ export default {
|
|||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
width: 130px;
|
width: 130px;
|
||||||
height: 40px;
|
height: 40px;
|
||||||
background: #388be1;
|
background: #4ea6ff;
|
||||||
border-radius: 8px;
|
border-radius: 8px;
|
||||||
border: 0;
|
border: 0;
|
||||||
margin-right: 8px;
|
margin-right: 8px;
|
||||||
@@ -924,7 +934,7 @@ export default {
|
|||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
width: 130px;
|
width: 130px;
|
||||||
height: 40px;
|
height: 40px;
|
||||||
background: #388be1;
|
background: #4ea6ff;
|
||||||
border-radius: 8px;
|
border-radius: 8px;
|
||||||
border: 0;
|
border: 0;
|
||||||
margin-right: 16px 8px 32px 0;
|
margin-right: 16px 8px 32px 0;
|
||||||
|
|||||||
@@ -20,28 +20,28 @@
|
|||||||
<div class="main_items">
|
<div class="main_items">
|
||||||
<div class="mi_ipts">
|
<div class="mi_ipts">
|
||||||
<div class="mii_ipt">
|
<div class="mii_ipt">
|
||||||
<div class="ipt_name">课程编号:</div>
|
<div class="ipt_name">课程信息:</div>
|
||||||
<div class="fi_input">
|
<div class="fi_input">
|
||||||
<a-input
|
<a-input
|
||||||
v-model:value="valueClass"
|
v-model:value="name"
|
||||||
style="width: 240px; height: 40px; border-radius: 8px"
|
style="width: 240px; height: 40px; border-radius: 8px"
|
||||||
placeholder="请输入项目名称"
|
placeholder="请输入项目名称"
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="mii_ipt">
|
<div class="mii_ipt">
|
||||||
<div class="ipt_name">内容分类:</div>
|
<div class="ipt_name">课程状态:</div>
|
||||||
<div class="select">
|
<div class="select fitems">
|
||||||
<a-select
|
<a-select
|
||||||
|
v-model:value="auditStatus"
|
||||||
dropdownClassName="dropdown-style"
|
dropdownClassName="dropdown-style"
|
||||||
style="width: 240px"
|
style="width: 200px"
|
||||||
placeholder="请选择"
|
placeholder="请选择状态"
|
||||||
:options="options1"
|
:options="options1"
|
||||||
@change="handleChange"
|
|
||||||
v-model:value="valueContent"
|
|
||||||
allowClear
|
allowClear
|
||||||
showSearch
|
showSearch
|
||||||
/>
|
>
|
||||||
|
</a-select>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@@ -56,18 +56,58 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
<div class="main_notice">
|
||||||
|
<div class="mntc_left">
|
||||||
|
<div class="notice_icon"></div>
|
||||||
|
<div v-if="offcourse == null">
|
||||||
|
<span class="title"
|
||||||
|
>已选择 <span class="data">0</span> 条</span
|
||||||
|
>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div v-else>
|
||||||
|
<span class="title"
|
||||||
|
>已选择 <span class="data">1</span> 条;</span
|
||||||
|
>
|
||||||
|
<span class="title"
|
||||||
|
>课程编号:
|
||||||
|
<span class="data">{{ offcourse.offcourseId }}</span>
|
||||||
|
</span>
|
||||||
|
<span class="title"
|
||||||
|
>名称:
|
||||||
|
<span class="data">{{
|
||||||
|
offcourse.name
|
||||||
|
}}</span>
|
||||||
|
</span>
|
||||||
|
<span class="title"
|
||||||
|
>分类:
|
||||||
|
<span class="data">{{
|
||||||
|
offcourse.categoryId
|
||||||
|
}}</span>
|
||||||
|
</span>
|
||||||
|
<span class="title"
|
||||||
|
>授课老师:
|
||||||
|
<span class="data">{{
|
||||||
|
offcourse.teacherId
|
||||||
|
}}</span>
|
||||||
|
</span>
|
||||||
|
<span class="title"
|
||||||
|
>创建人:
|
||||||
|
<span class="data">{{ offcourse.createUser }}</span>
|
||||||
|
</span>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
<div class="main_table">
|
<div class="main_table">
|
||||||
|
|
||||||
<a-table
|
<a-table
|
||||||
class="ant-table-striped"
|
class="ant-table-striped"
|
||||||
:row-class-name="
|
:row-class-name="
|
||||||
(_record, index) => (index % 2 === 1 ? 'table-striped' : null)
|
(_record, index) => (index % 2 === 1 ? 'table-striped' : null)
|
||||||
"
|
"
|
||||||
:row-selection="{
|
:row-selection="rowSelection"
|
||||||
selectedRowKeys: selectedRowKeys,
|
|
||||||
onChange: onSelectChange,
|
|
||||||
type: 'radio',
|
|
||||||
}"
|
|
||||||
:columns="columns1"
|
:columns="columns1"
|
||||||
:data-source="classTableData"
|
:data-source="classTableData"
|
||||||
:loading="tableDataTotal === -1 ? true : false"
|
:loading="tableDataTotal === -1 ? true : false"
|
||||||
@@ -88,28 +128,18 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="main_btns">
|
|
||||||
<button class="btn1">取消</button>
|
|
||||||
<button class="btn2" @click="closeDrawer">确定</button>
|
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
</a-drawer>
|
</a-drawer>
|
||||||
</template>
|
</template>
|
||||||
<script>
|
<script>
|
||||||
|
//import { ApiFilled } from "@ant-design/icons-vue";
|
||||||
import { reactive, toRefs, ref } from "vue";
|
import { reactive, toRefs, ref } from "vue";
|
||||||
// import { planList } from "../../api/indexTaskadd";
|
// import { planList } from "../../api/indexTaskadd";
|
||||||
|
import {detail} from "../../api/indexCourse";
|
||||||
import { list } from "../../api/indexTaskadd";
|
import { list } from "../../api/indexTaskadd";
|
||||||
import { toDate } from "../../api/method";
|
import { toDate } from "../../api/method";
|
||||||
const options1 = ref([
|
|
||||||
{
|
|
||||||
value: "value1",
|
|
||||||
label: "通用",
|
|
||||||
},
|
|
||||||
{
|
|
||||||
value: "value2",
|
|
||||||
label: "领导",
|
|
||||||
},
|
|
||||||
]);
|
|
||||||
const columns1 = [
|
const columns1 = [
|
||||||
{
|
{
|
||||||
title: "课程编号",
|
title: "课程编号",
|
||||||
@@ -162,6 +192,14 @@ export default {
|
|||||||
type: Boolean,
|
type: Boolean,
|
||||||
default: false,
|
default: false,
|
||||||
},
|
},
|
||||||
|
chooseCourse: {
|
||||||
|
type: Number,
|
||||||
|
default: null,
|
||||||
|
},
|
||||||
|
titleTag: {
|
||||||
|
type: Boolean,
|
||||||
|
default: false,
|
||||||
|
},
|
||||||
},
|
},
|
||||||
setup(props, ctx) {
|
setup(props, ctx) {
|
||||||
const state = reactive({
|
const state = reactive({
|
||||||
@@ -183,46 +221,55 @@ export default {
|
|||||||
valueContent: null, //内容分类
|
valueContent: null, //内容分类
|
||||||
selectedRows: [], //选择的数据
|
selectedRows: [], //选择的数据
|
||||||
selectedRowKeys: [],
|
selectedRowKeys: [],
|
||||||
});
|
titleTag:false,
|
||||||
const onSelectChange = (selectedRowKeys, selectedRows) => {
|
offcourse:null,
|
||||||
console.log("selectedRowKeys changed: ", selectedRowKeys);
|
auditStatus:null,
|
||||||
|
name:null,
|
||||||
|
|
||||||
state.selectedRowKeys = selectedRowKeys;
|
});
|
||||||
state.selectedRows = selectedRows;
|
const rowSelection = {
|
||||||
console.log("选择了", state.selectedRows[0].name);
|
type: "radio",
|
||||||
|
onSelect: (selectedRows) => {
|
||||||
|
state.chooseCourse=selectedRows.num;
|
||||||
|
console.log(selectedRows,"==========",state.chooseCourse);
|
||||||
|
closeDrawer();
|
||||||
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
const closeDrawer = () => {
|
const closeDrawer = () => {
|
||||||
ctx.emit("update:selfacetVisible", false);
|
ctx.emit("update:selfacetVisible", false);
|
||||||
ctx.emit("getData", state.selectedRows);
|
ctx.emit("update:chooseCourse", state.chooseCourse);
|
||||||
};
|
};
|
||||||
const afterVisibleChange = (bool) => {
|
const afterVisibleChange = (bool) => {
|
||||||
console.log("state", bool);
|
if(bool){
|
||||||
|
state.chooseCourse=props.chooseCourse;
|
||||||
getClassList();
|
getClassList();
|
||||||
|
getFaceInfo();
|
||||||
|
}
|
||||||
|
|
||||||
};
|
};
|
||||||
// const showDrawerSelFacet = () => {
|
// const showDrawerSelFacet = () => {
|
||||||
// state.selfacetvisible = true;
|
// state.selfacetvisible = true;
|
||||||
// };
|
// };
|
||||||
|
const getFaceInfo =()=>{
|
||||||
|
detail({offcourseId:36}).then((res) => {
|
||||||
|
state.chooseCourse = res.data.data;
|
||||||
|
}).catch();
|
||||||
|
}
|
||||||
//获取面授课列表
|
//获取面授课列表
|
||||||
const getClassList = (obj) => {
|
const getClassList = (obj) => {
|
||||||
let objn = obj || {
|
let objn = obj || {
|
||||||
auditStatus: 0,
|
auditStatus:state.auditStatus,
|
||||||
// beginTime: 0,
|
name:state.name,
|
||||||
categoryId: 0,
|
pageNo:state.currentPage,
|
||||||
createName: "",
|
pageSize:state.pageSize
|
||||||
// endTime: 0,
|
|
||||||
name: "",
|
|
||||||
pageNo: state.currentPage,
|
|
||||||
pageSize: 10,
|
|
||||||
projectName: "",
|
|
||||||
};
|
};
|
||||||
list(objn)
|
list(objn)
|
||||||
.then((res) => {
|
.then((res) => {
|
||||||
console.log(res.data.data.rows);
|
console.log(res.data.data.rows);
|
||||||
let result = res.data.data;
|
let result = res.data.data;
|
||||||
state.tableDataTotal = result.total;
|
state.tableDataTotal = result.total;
|
||||||
if (result.total > 0) {
|
|
||||||
getClassData(result.rows);
|
getClassData(result.rows);
|
||||||
}
|
|
||||||
})
|
})
|
||||||
.catch((err) => {
|
.catch((err) => {
|
||||||
console.log("获取列表失败", err.data);
|
console.log("获取列表失败", err.data);
|
||||||
@@ -248,32 +295,41 @@ export default {
|
|||||||
state.classTableData = array;
|
state.classTableData = array;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
const options1 = ref([
|
||||||
|
{
|
||||||
|
value: 0,
|
||||||
|
label: "未提交",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
value: 1,
|
||||||
|
label: "待审核",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
value: 2,
|
||||||
|
label: "已审核",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
value: -1,
|
||||||
|
label: "审核未通过",
|
||||||
|
},
|
||||||
|
]);
|
||||||
const handleChange = (value, option) => {
|
const handleChange = (value, option) => {
|
||||||
console.log("改变了", value, option);
|
console.log("改变了", value, option);
|
||||||
console.log(state.valueContent);
|
console.log(state.valueContent);
|
||||||
};
|
};
|
||||||
//重置
|
//搜索
|
||||||
const reset = () => {
|
const search = () => {
|
||||||
state.valueClass = null;
|
|
||||||
state.valueContent = null;
|
|
||||||
//重新获取列表
|
//重新获取列表
|
||||||
getClassList();
|
getClassList();
|
||||||
};
|
};
|
||||||
//搜索
|
//重置
|
||||||
const search = () => {
|
const reset = () => {
|
||||||
let obj = {
|
state.name = null;
|
||||||
auditStatus: 0,
|
state.auditStatus = null;
|
||||||
// beginTime: 0,
|
//重新获取列表
|
||||||
categoryId: 0, //分类
|
getClassList();
|
||||||
createName: "",
|
|
||||||
// endTime: 0,
|
|
||||||
name: state.valueClass,
|
|
||||||
pageNo: state.currentPage,
|
|
||||||
pageSize: 10,
|
|
||||||
projectName: "",
|
|
||||||
};
|
|
||||||
getClassList(obj);
|
|
||||||
};
|
};
|
||||||
|
|
||||||
const changePaginationStu = (page) => {
|
const changePaginationStu = (page) => {
|
||||||
state.currentPage = page;
|
state.currentPage = page;
|
||||||
getClassList();
|
getClassList();
|
||||||
@@ -289,9 +345,9 @@ export default {
|
|||||||
handleChange,
|
handleChange,
|
||||||
reset,
|
reset,
|
||||||
getClassList,
|
getClassList,
|
||||||
search,
|
|
||||||
changePaginationStu,
|
changePaginationStu,
|
||||||
onSelectChange,
|
rowSelection,
|
||||||
|
search,
|
||||||
// change,
|
// change,
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
@@ -323,6 +379,7 @@ export default {
|
|||||||
display: flex;
|
display: flex;
|
||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
margin-bottom: 12px;
|
margin-bottom: 12px;
|
||||||
|
margin-top: 32px;
|
||||||
flex-wrap: wrap;
|
flex-wrap: wrap;
|
||||||
.mi_ipts {
|
.mi_ipts {
|
||||||
display: flex;
|
display: flex;
|
||||||
@@ -403,6 +460,36 @@ export default {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
.main_notice {
|
||||||
|
display: flex;
|
||||||
|
justify-content: space-between;
|
||||||
|
align-items: center;
|
||||||
|
margin-bottom: 32px;
|
||||||
|
height: 40px;
|
||||||
|
background-color: #e9f6fe;
|
||||||
|
.mntc_left {
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
.title {
|
||||||
|
color: rgba(0, 0, 0, 0.65);
|
||||||
|
margin-right: 17px;
|
||||||
|
}
|
||||||
|
.data {
|
||||||
|
color: #388be1;
|
||||||
|
}
|
||||||
|
.notice_icon {
|
||||||
|
width: 14px;
|
||||||
|
height: 14px;
|
||||||
|
margin-right: 9px;
|
||||||
|
margin-left: 9px;
|
||||||
|
background-image: url(@/assets/images/coursewareManage/gan.png);
|
||||||
|
background-size: 100% 100%;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
.mntc_right {
|
||||||
|
cursor: pointer;
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.main_btns {
|
.main_btns {
|
||||||
|
|||||||
@@ -51,12 +51,16 @@
|
|||||||
<div class="btnbox">
|
<div class="btnbox">
|
||||||
<button
|
<button
|
||||||
class="xkbtn"
|
class="xkbtn"
|
||||||
:style="{ display: creVote ? 'none' : 'block' }"
|
|
||||||
@click="showDrawerCreVote"
|
@click="showDrawerCreVote"
|
||||||
>
|
>
|
||||||
创建投票
|
{{ ballotId ? "编辑" : "添加" }}投票
|
||||||
|
|
||||||
</button>
|
</button>
|
||||||
<a @click="queryStem">查看投票</a>
|
<div v-if = "ballotId>0">
|
||||||
|
<a-tag closable color="processing" @close="log">
|
||||||
|
<span style="font-size:14px;line-height: 33px;" >删除投票</span>
|
||||||
|
</a-tag></div>
|
||||||
<div>
|
<div>
|
||||||
<CreateVote
|
<CreateVote
|
||||||
v-model:createVoteVisible="createVoteVisible"
|
v-model:createVoteVisible="createVoteVisible"
|
||||||
@@ -79,9 +83,6 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<!-- 创建投票侧弹窗 -->
|
<!-- 创建投票侧弹窗 -->
|
||||||
<div>
|
<div>
|
||||||
<create-vote
|
<create-vote
|
||||||
@@ -111,10 +112,13 @@
|
|||||||
<div class="btnbox">
|
<div class="btnbox">
|
||||||
<a-upload
|
<a-upload
|
||||||
@change="handleChange"
|
@change="handleChange"
|
||||||
action="/vote/baseVoteupload"
|
:multiple="true"
|
||||||
|
:max-count="1"
|
||||||
|
action="/manageApi/vote/baseVoteupload"
|
||||||
v-model:file-list="fileList"
|
v-model:file-list="fileList"
|
||||||
>
|
>
|
||||||
<button class="xkbtn">点击上传</button></a-upload>
|
<button class="xkbtn">点击上传</button></a-upload>
|
||||||
|
<div v-if="voteCount > 0"><a-tag color="processing"> <span style="font-size:14px;line-height: 33px;" >{{voteCount}}票</span></a-tag></div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="main_item" style="margin-top: -25px">
|
<div class="main_item" style="margin-top: -25px">
|
||||||
@@ -201,6 +205,10 @@ export default {
|
|||||||
isactive: {
|
isactive: {
|
||||||
type: Number,
|
type: Number,
|
||||||
default: null,
|
default: null,
|
||||||
|
},
|
||||||
|
projectTemplateId:{
|
||||||
|
type: Number,
|
||||||
|
default: null,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -225,6 +233,9 @@ export default {
|
|||||||
addStemVisible:false, //
|
addStemVisible:false, //
|
||||||
editChild:false,
|
editChild:false,
|
||||||
fileList: [],
|
fileList: [],
|
||||||
|
voteCount:null,
|
||||||
|
projectTemplateId:null,
|
||||||
|
|
||||||
});
|
});
|
||||||
const closeDrawer = () => {
|
const closeDrawer = () => {
|
||||||
state.inputV1 = "",
|
state.inputV1 = "",
|
||||||
@@ -234,12 +245,16 @@ export default {
|
|||||||
ctx.emit("update:addvoteVisible", false);
|
ctx.emit("update:addvoteVisible", false);
|
||||||
ctx.emit("update:edit", false);
|
ctx.emit("update:edit", false);
|
||||||
};
|
};
|
||||||
const afterVisibleChange = () => {
|
const afterVisibleChange = (bool) => {
|
||||||
if(props.edit){
|
if(props.edit&&bool){
|
||||||
queryVoteInfo();
|
queryVoteInfo();
|
||||||
}
|
}
|
||||||
|
state.projectTemplateId = props.projectTemplateId;
|
||||||
|
console.log("projectTemplateId visible====",state.projectTemplateId);
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
const showDrawerCreVote = () => {
|
const showDrawerCreVote = () => {
|
||||||
state.createVoteVisible = true;
|
state.createVoteVisible = true;
|
||||||
state.editChild = props.edit;
|
state.editChild = props.edit;
|
||||||
@@ -248,10 +263,20 @@ export default {
|
|||||||
};
|
};
|
||||||
|
|
||||||
const handleChange = info => {
|
const handleChange = info => {
|
||||||
if (info.file.status !== "uploading") {
|
let resFileList = [...info.fileList];
|
||||||
|
|
||||||
console.log("基础票数rinfo======",info);
|
|
||||||
|
resFileList.map(file => {
|
||||||
|
if (file.response) {
|
||||||
|
// Component will show file.url as link
|
||||||
|
file.url = file.response.url;
|
||||||
|
console.log("file========",file);
|
||||||
|
console.log("file========",file.response);
|
||||||
|
state.voteCount = file.response.data;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
});
|
||||||
|
//fileList.value = resFileList;
|
||||||
};
|
};
|
||||||
|
|
||||||
//删除题干信息接口
|
//删除题干信息接口
|
||||||
@@ -286,6 +311,7 @@ export default {
|
|||||||
|
|
||||||
}
|
}
|
||||||
const updateToTask =(res)=>{
|
const updateToTask =(res)=>{
|
||||||
|
console.log("props.isLevel=====",props.isLevel);
|
||||||
if(props.isLevel ==1){
|
if(props.isLevel ==1){
|
||||||
RouterEditTask({
|
RouterEditTask({
|
||||||
chapterId: props.isactive,
|
chapterId: props.isactive,
|
||||||
@@ -310,7 +336,7 @@ export default {
|
|||||||
name: res.data.data.voteName,
|
name: res.data.data.voteName,
|
||||||
projectId: props.projectId,
|
projectId: props.projectId,
|
||||||
projectTaskId: props.projectTaskId || 0,
|
projectTaskId: props.projectTaskId || 0,
|
||||||
stageId: props.chooseStageId,
|
stageId: props.chooseStageId || 0,
|
||||||
type: 12,
|
type: 12,
|
||||||
})
|
})
|
||||||
.then(() => {
|
.then(() => {
|
||||||
@@ -321,16 +347,14 @@ export default {
|
|||||||
message.error(`${props.edit ? '编辑' : '新增'}阶段任务失败`)
|
message.error(`${props.edit ? '编辑' : '新增'}阶段任务失败`)
|
||||||
});
|
});
|
||||||
}else if (props.isLevel == 3) {
|
}else if (props.isLevel == 3) {
|
||||||
console.log("");
|
|
||||||
addTempTask({
|
addTempTask({
|
||||||
duration: 0,
|
courseId: res.data.data.voteId,
|
||||||
flag: true,
|
name: res.data.data.voteName,
|
||||||
courseId: Number(res.data.data.EditVoteId),
|
projectTemplateId: props.projectTemplateId,
|
||||||
name: res.data.data.data.voteName,
|
|
||||||
projectId: props.projectId,
|
|
||||||
projectTaskId: props.projectTaskId || 0,
|
projectTaskId: props.projectTaskId || 0,
|
||||||
stageId: props.chooseStageId,
|
stageId: props.chooseStageId || 0,
|
||||||
type: 10,
|
type: 12,
|
||||||
})
|
})
|
||||||
.then(() => {
|
.then(() => {
|
||||||
message.success(`${props.edit ? "编辑" : "新增"}阶段任务成功`);
|
message.success(`${props.edit ? "编辑" : "新增"}阶段任务成功`);
|
||||||
@@ -373,6 +397,7 @@ export default {
|
|||||||
api
|
api
|
||||||
.editVote(obj)
|
.editVote(obj)
|
||||||
.then((res) => {
|
.then((res) => {
|
||||||
|
console.log("updte======");
|
||||||
updateToTask(res);
|
updateToTask(res);
|
||||||
closeDrawer();
|
closeDrawer();
|
||||||
message.success("修改投票信息成功")
|
message.success("修改投票信息成功")
|
||||||
@@ -400,6 +425,10 @@ export default {
|
|||||||
const closeStem = () => {
|
const closeStem = () => {
|
||||||
state.addStemVisible = false;
|
state.addStemVisible = false;
|
||||||
};
|
};
|
||||||
|
const log = e => {
|
||||||
|
state.ballotId=null;
|
||||||
|
console.log(e);
|
||||||
|
};
|
||||||
return {
|
return {
|
||||||
...toRefs(state),
|
...toRefs(state),
|
||||||
showDrawerCreVote,
|
showDrawerCreVote,
|
||||||
@@ -411,11 +440,117 @@ export default {
|
|||||||
queryStem,
|
queryStem,
|
||||||
closeStem,
|
closeStem,
|
||||||
handleChange,
|
handleChange,
|
||||||
|
log,
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
<style lang="scss">
|
<style lang="scss">
|
||||||
|
.ConfirmModal {
|
||||||
|
.ant-modal {
|
||||||
|
width: 424px !important;
|
||||||
|
height: 258px !important;
|
||||||
|
.ant-modal-content {
|
||||||
|
width: 424px !important;
|
||||||
|
height: 258px !important;
|
||||||
|
.ant-modal-body {
|
||||||
|
width: 424px !important;
|
||||||
|
height: 258px !important;
|
||||||
|
padding: 0 !important;
|
||||||
|
.delete {
|
||||||
|
z-index: 999;
|
||||||
|
width: 424px;
|
||||||
|
height: 258px;
|
||||||
|
background: #ffffff;
|
||||||
|
box-shadow: 0px 1px 35px 0px rgba(118, 136, 166, 0.21);
|
||||||
|
border-radius: 4px;
|
||||||
|
.del_header {
|
||||||
|
position: absolute;
|
||||||
|
width: calc(100%);
|
||||||
|
height: 40px;
|
||||||
|
background: linear-gradient(
|
||||||
|
rgba(78, 166, 255, 0.2) 0%,
|
||||||
|
rgba(78, 166, 255, 0) 100%
|
||||||
|
);
|
||||||
|
}
|
||||||
|
.del_main {
|
||||||
|
width: 100%;
|
||||||
|
position: relative;
|
||||||
|
.header {
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
padding-top: 20px;
|
||||||
|
padding-left: 26px;
|
||||||
|
font-size: 16px;
|
||||||
|
.icon {
|
||||||
|
width: 16px;
|
||||||
|
height: 16px;
|
||||||
|
margin-right: 10px;
|
||||||
|
background-image: url(@/assets/images/coursewareManage/QR.png);
|
||||||
|
background-size: 100% 100%;
|
||||||
|
}
|
||||||
|
.close_exit {
|
||||||
|
position: absolute;
|
||||||
|
right: 42px;
|
||||||
|
cursor: pointer;
|
||||||
|
width: 20px;
|
||||||
|
height: 20px;
|
||||||
|
background-image: url(@/assets/images/coursewareManage/close.png);
|
||||||
|
background-size: 100% 100%;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
.body {
|
||||||
|
width: 100%;
|
||||||
|
margin: 34px auto 56px auto;
|
||||||
|
display: flex;
|
||||||
|
justify-content: center;
|
||||||
|
align-items: center;
|
||||||
|
flex-direction: column;
|
||||||
|
position: relative;
|
||||||
|
.back {
|
||||||
|
position: absolute;
|
||||||
|
top: 30px;
|
||||||
|
font-size: 12px;
|
||||||
|
font-weight: 400;
|
||||||
|
color: #666666;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
.del_btnbox {
|
||||||
|
display: flex;
|
||||||
|
margin: 30px auto;
|
||||||
|
justify-content: center;
|
||||||
|
.del_btn {
|
||||||
|
width: 100px;
|
||||||
|
height: 40px;
|
||||||
|
background: rgba(64, 158, 255, 0);
|
||||||
|
border-radius: 8px;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: center;
|
||||||
|
flex-shrink: 0;
|
||||||
|
cursor: pointer;
|
||||||
|
.btnText {
|
||||||
|
font-size: 14px;
|
||||||
|
font-weight: 400;
|
||||||
|
line-height: 40px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
.btn1 {
|
||||||
|
border: 1px solid rgba(64, 158, 255, 1);
|
||||||
|
color: #4ea6ff;
|
||||||
|
margin-right: 14px;
|
||||||
|
}
|
||||||
|
.btn2 {
|
||||||
|
background-color: #4ea6ff;
|
||||||
|
color: #ffffff;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
.ant-table-striped :deep(.table-striped) td {
|
.ant-table-striped :deep(.table-striped) td {
|
||||||
background-color: #fafafa !important;
|
background-color: #fafafa !important;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -130,15 +130,13 @@ export default {
|
|||||||
});
|
});
|
||||||
// const router = useRouter();
|
// const router = useRouter();
|
||||||
const afterVisibleChange = () => {
|
const afterVisibleChange = () => {
|
||||||
|
if(state.ballotId>0){
|
||||||
getInfoDate();
|
getInfoDate();
|
||||||
|
|
||||||
/*
|
|
||||||
if(){
|
|
||||||
|
|
||||||
}else{
|
}else{
|
||||||
handleTypes();
|
handleTypes();
|
||||||
|
|
||||||
}
|
}
|
||||||
*/
|
|
||||||
};
|
};
|
||||||
const closeDrawer = () => {
|
const closeDrawer = () => {
|
||||||
ctx.emit("update:createVoteVisible", false);
|
ctx.emit("update:createVoteVisible", false);
|
||||||
@@ -286,6 +284,11 @@ export default {
|
|||||||
inputVal: "",
|
inputVal: "",
|
||||||
imgVal: "",
|
imgVal: "",
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
id: 2,
|
||||||
|
inputVal: "",
|
||||||
|
imgVal: "",
|
||||||
|
},
|
||||||
],
|
],
|
||||||
};
|
};
|
||||||
state.allFormsData.push(obj);
|
state.allFormsData.push(obj);
|
||||||
|
|||||||
@@ -51,6 +51,7 @@
|
|||||||
<script>
|
<script>
|
||||||
import VoteQuestionItem from "./VoteQuestionItem.vue";
|
import VoteQuestionItem from "./VoteQuestionItem.vue";
|
||||||
import { ref } from "vue";
|
import { ref } from "vue";
|
||||||
|
import * as api from "../../api/indexVote";
|
||||||
export default {
|
export default {
|
||||||
name: "CreateVote",
|
name: "CreateVote",
|
||||||
components: {
|
components: {
|
||||||
@@ -76,6 +77,12 @@ export default {
|
|||||||
const curItem = ref(props.item);
|
const curItem = ref(props.item);
|
||||||
const handleTypesDel = () => {
|
const handleTypesDel = () => {
|
||||||
emit("del", { id: curItem.value.id, curItem: curItem.value });
|
emit("del", { id: curItem.value.id, curItem: curItem.value });
|
||||||
|
console.log("删除题干======",{ id: curItem.value.id, curItem: curItem.value });
|
||||||
|
api.deleteVoteStem({voteStemId:3})
|
||||||
|
.then(() => {
|
||||||
|
// message.success('删除题干信息成功')
|
||||||
|
|
||||||
|
})
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
@@ -3922,10 +3922,6 @@ export default defineComponent({
|
|||||||
};
|
};
|
||||||
|
|
||||||
const options1 = ref([
|
const options1 = ref([
|
||||||
// {
|
|
||||||
// value: "value1",
|
|
||||||
// label: "请选择状态",
|
|
||||||
// },
|
|
||||||
{
|
{
|
||||||
value: 0,
|
value: 0,
|
||||||
label: "未提交",
|
label: "未提交",
|
||||||
|
|||||||
@@ -427,7 +427,7 @@
|
|||||||
v-model:chooseStageId="chooseStageId"
|
v-model:chooseStageId="chooseStageId"
|
||||||
v-model:projectTaskId="projectTaskId"
|
v-model:projectTaskId="projectTaskId"
|
||||||
v-model:EditVoteId="EditVoteId"
|
v-model:EditVoteId="EditVoteId"
|
||||||
v-model:voteId="voteId"
|
|
||||||
v-model:ballotId="ballotId"
|
v-model:ballotId="ballotId"
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
@@ -1106,8 +1106,8 @@ export default {
|
|||||||
},
|
},
|
||||||
setup() {
|
setup() {
|
||||||
const state = reactive({
|
const state = reactive({
|
||||||
projectId: storage.get("projectId")
|
projectTemplateId: storage.get("projectTemplateId")
|
||||||
? JSON.parse(storage.get("projectId"))
|
? JSON.parse(storage.get("projectTemplateId"))
|
||||||
: null,
|
: null,
|
||||||
chooseStageId: null,
|
chooseStageId: null,
|
||||||
removeStageId: null,
|
removeStageId: null,
|
||||||
@@ -1297,7 +1297,7 @@ export default {
|
|||||||
|
|
||||||
unlockModeVisible: false, //切换模式抽屉
|
unlockModeVisible: false, //切换模式抽屉
|
||||||
});
|
});
|
||||||
console.log("projectId", state.projectId);
|
console.log("projectTemplateId", state.projectTemplateId);
|
||||||
const selectProjectName = (value, index) => {
|
const selectProjectName = (value, index) => {
|
||||||
console.log("value", value, index);
|
console.log("value", value, index);
|
||||||
};
|
};
|
||||||
@@ -1344,12 +1344,12 @@ export default {
|
|||||||
? "投票"
|
? "投票"
|
||||||
: "-",
|
: "-",
|
||||||
creater: value.name,
|
creater: value.name,
|
||||||
cretime: value.duration ? value.duration : "-",
|
cretime: Number(value.duration)>0 ? value.duration : "-",
|
||||||
checked1: value.flag ? true : false,
|
checked1: value.flag ? true : false,
|
||||||
checked: false, //是否选中类型
|
checked: false, //是否选中类型
|
||||||
courseId: value.courseId,
|
courseId: value.courseId,
|
||||||
projectId: value.projectId,
|
projectTemplateId: value.projectTemplateId,
|
||||||
templateStageId: value.templateStageId,
|
stageId: value.templateStageId,
|
||||||
type: value.type,
|
type: value.type,
|
||||||
};
|
};
|
||||||
array.push(obj);
|
array.push(obj);
|
||||||
@@ -1618,8 +1618,8 @@ export default {
|
|||||||
} else {
|
} else {
|
||||||
{
|
{
|
||||||
let obj = {
|
let obj = {
|
||||||
templateStageId: state.removeStageId,
|
stageId: state.removeStageId,
|
||||||
projectTemplateTaskId: state.selectRow,
|
projectTaskId: state.selectRow,
|
||||||
};
|
};
|
||||||
api
|
api
|
||||||
.moveTask(obj)
|
.moveTask(obj)
|
||||||
@@ -1629,7 +1629,7 @@ export default {
|
|||||||
message.success("移动成功");
|
message.success("移动成功");
|
||||||
console.log(state.removeStageId);
|
console.log(state.removeStageId);
|
||||||
getTask();
|
getTask();
|
||||||
localStorage.setItem("templateStageId", state.chooseStageId);
|
localStorage.setItem("stageId", state.chooseStageId);
|
||||||
})
|
})
|
||||||
.catch((err) => {
|
.catch((err) => {
|
||||||
console.log("移动失败", err);
|
console.log("移动失败", err);
|
||||||
@@ -1704,12 +1704,11 @@ export default {
|
|||||||
message.destroy();
|
message.destroy();
|
||||||
return message.warning("请输入阶段名称");
|
return message.warning("请输入阶段名称");
|
||||||
}
|
}
|
||||||
if (state.updateStageID) {
|
|
||||||
let obj = {
|
let obj = {
|
||||||
name: state.valuesname,
|
name: state.valuesname,
|
||||||
projectTemplateId: localStorage.getItem("templateStageId"),
|
projectTemplateId: localStorage.getItem("projectTemplateId"),
|
||||||
remark: state.valuesnotice,
|
remark: state.valuesnotice,
|
||||||
stageId: state.updateStageID,
|
stageId: state.updateStageID || 0,
|
||||||
};
|
};
|
||||||
api
|
api
|
||||||
.editStage(obj)
|
.editStage(obj)
|
||||||
@@ -1726,28 +1725,7 @@ export default {
|
|||||||
.catch((err) => {
|
.catch((err) => {
|
||||||
console.log("添加阶段失败", err);
|
console.log("添加阶段失败", err);
|
||||||
});
|
});
|
||||||
} else {
|
|
||||||
let obj = {
|
|
||||||
name: state.valuesname,
|
|
||||||
projectTemplateId: localStorage.getItem("templateStageId"),
|
|
||||||
remark: state.valuesnotice,
|
|
||||||
stageId: 0,
|
|
||||||
};
|
|
||||||
api
|
|
||||||
.editStage(obj)
|
|
||||||
.then((res) => {
|
|
||||||
console.log("添加阶段成功", res);
|
|
||||||
state.valuesname = "";
|
|
||||||
state.valuesnotice = "";
|
|
||||||
closeModal();
|
|
||||||
message.destroy();
|
|
||||||
message.success("添加阶段成功");
|
|
||||||
getTask();
|
|
||||||
})
|
|
||||||
.catch((err) => {
|
|
||||||
console.log("添加阶段失败", err);
|
|
||||||
});
|
|
||||||
}
|
|
||||||
};
|
};
|
||||||
|
|
||||||
//打开删除阶段弹窗
|
//打开删除阶段弹窗
|
||||||
@@ -1821,6 +1799,7 @@ export default {
|
|||||||
state.addrefvisible = true;
|
state.addrefvisible = true;
|
||||||
};
|
};
|
||||||
const showDrawerAddDiscuss = (id, eleId) => {
|
const showDrawerAddDiscuss = (id, eleId) => {
|
||||||
|
console.log("projectTemplateId========",state.projectTemplateId);
|
||||||
state.EditDiscussId = id;
|
state.EditDiscussId = id;
|
||||||
state.projectTaskId = eleId;
|
state.projectTaskId = eleId;
|
||||||
state.adddiscussvisible = true;
|
state.adddiscussvisible = true;
|
||||||
@@ -1942,9 +1921,9 @@ export default {
|
|||||||
duration: ele.cretime == "-" ? 0 : ele.cretime,
|
duration: ele.cretime == "-" ? 0 : ele.cretime,
|
||||||
flag: ele.checked1,
|
flag: ele.checked1,
|
||||||
name: ele.creater,
|
name: ele.creater,
|
||||||
projectId: ele.projectId,
|
projectTemplateId: ele.projectTemplateId,
|
||||||
projectTaskId: ele.id,
|
projectTaskId: ele.id,
|
||||||
templateStageId: ele.templateStageId,
|
stageId: ele.templateStageId,
|
||||||
type: ele.type,
|
type: ele.type,
|
||||||
};
|
};
|
||||||
api
|
api
|
||||||
|
|||||||
Reference in New Issue
Block a user