Merge remote-tracking branch 'origin/develop' into develop

This commit is contained in:
yuping
2022-12-20 13:28:55 +08:00
8 changed files with 3090 additions and 2908 deletions

View File

@@ -1,472 +1,479 @@
<template> <template>
<a-drawer <a-drawer :visible="addinvistVisible" class="drawerStyle addinvistDrawer" width="70%" title="添加评估" placement="right"
:visible="addinvistVisible" @after-visible-change="afterVisibleChange">
class="drawerStyle addinvistDrawer" <div class="drawerMain">
width="70%" <div class="header">
title="添加评估" <div v-if="edit" class="headerTitle">编辑评估</div>
placement="right" <div v-else class="headerTitle">添加评估</div>
@after-visible-change="afterVisibleChange" <img style="width: 29px; height: 29px; cursor: pointer" src="../../assets/images/basicinfo/close.png"
> @click="closeDrawer" />
<div class="drawerMain"> </div>
<div class="header"> <div class="contentMain">
<div v-if="edit" class="headerTitle">编辑评估</div> <div class="main">
<div v-else class="headerTitle">添加评估</div> <div class="main_left">
<img <AssessmentAll v-model:assessmentVisible="assessmentVisible" v-model:assessmentId="assessmentId"
style="width: 29px; height: 29px; cursor: pointer" v-model:assessmentName="assessmentName" />
src="../../assets/images/basicinfo/close.png" </div>
@click="closeDrawer" </div>
/> </div>
</div> <div class="main_btns">
<div class="contentMain"> <button class="btn1" @click="closeDrawer">取消</button>
<div class="main"> <button class="btn2" @click="updateTask">确定</button>
<div class="main_left"> </div>
<AssessmentAll </div>
v-model:assessmentVisible="assessmentVisible" </a-drawer>
v-model:assessmentId="assessmentId"
v-model:assessmentName="assessmentName"
/>
</div>
</div>
</div>
<div class="main_btns">
<button class="btn1" @click="closeDrawer">取消</button>
<button class="btn2" @click="updateTask">确定</button>
</div>
</div>
</a-drawer>
</template> </template>
<script> <script>
import { reactive, toRefs } from "vue"; import { reactive, toRefs } from "vue";
import * as apiTask from "../../api/indexTaskadd"; import * as apiTask from "../../api/indexTaskadd";
import { message } from "ant-design-vue"; import { message } from "ant-design-vue";
import { import {
RouterEditTask, RouterEditTask,
IsExistence, IsExistence,
IsExistenceProject, IsExistenceProject,
IsExistenceProjectTemplate, IsExistenceProjectTemplate,
} from "@/api/indexTask"; } from "@/api/indexTask";
import { addTempTask } from "../../api/indexTaskadd"; import { addTempTask } from "../../api/indexTaskadd";
import AssessmentAll from "@/components/drawers/AssessmentAll.vue"; import AssessmentAll from "@/components/drawers/AssessmentAll.vue";
export default { export default {
name: "AddInvist", name: "AddInvist",
components: { components: {
AssessmentAll, AssessmentAll,
}, },
props: { props: {
addinvistVisible: { addinvistVisible: {
type: Boolean, type: Boolean,
default: false, default: false,
}, },
EditInvistId: { EditInvistId: {
type: Number, type: Number,
default: null, default: null,
}, },
edit: { edit: {
// 是否为编辑 // 是否为编辑
type: Boolean, type: Boolean,
default: null, default: null,
}, },
projectId: { projectId: {
type: Number, type: Number,
default: null, default: null,
}, },
chooseStageId: { chooseStageId: {
type: Number, type: Number,
default: null, default: null,
}, },
routerTaskId: { routerTaskId: {
type: Number, type: Number,
default: 0, default: 0,
}, },
isLevel: { isLevel: {
// 是否是关卡页面触发 // 是否是关卡页面触发
type: Number, type: Number,
default: null, default: null,
}, },
projectTaskId: { projectTaskId: {
// 要编辑的projectId // 要编辑的projectId
type: Number, type: Number,
default: null, default: null,
}, },
routerId: { routerId: {
type: Number, type: Number,
default: null, default: null,
}, },
isactive: { isactive: {
type: Number, type: Number,
default: null, default: null,
}, },
projectTemplateId: { projectTemplateId: {
type: Number, type: Number,
default: null, default: null,
}, },
}, },
setup(props, ctx) { setup(props, ctx) {
const state = reactive({ const state = reactive({
inputV1: "", inputV1: "",
time: undefined, time: undefined,
currentPage: 1, currentPage: 1,
pageSize: 10, pageSize: 10,
tableDataTotal: 0, tableDataTotal: 0,
tableData: [], tableData: [],
assessmentId: null, assessmentId: null,
assessmentName: "", assessmentName: "",
assessment: null, assessment: null,
assessment1: null, assessment1: null,
assessmentVisible: false, assessmentVisible: false,
titleTag: false, titleTag: false,
}); });
// const getCheckedAss = (ass) => { // const getCheckedAss = (ass) => {
// state.assessmentId = ass.assessmentId; // state.assessmentId = ass.assessmentId;
// state.assessment = ass; // state.assessment = ass;
// console.log("state.assessment1",state.assessment); // console.log("state.assessment1",state.assessment);
// //
// }; // };
const closeDrawer = () => { const closeDrawer = () => {
ctx.emit("update:addinvistVisible", false); ctx.emit("update:addinvistVisible", false);
ctx.emit("update:edit", false); ctx.emit("update:edit", false);
state.assessmentId = null; state.assessmentId = null;
state.assessmentName = null; state.assessmentName = null;
state.inputV1 = ""; state.inputV1 = "";
// ctx.emit("changeData", false); // ctx.emit("changeData", false);
localStorage.setItem("stageId", props.chooseStageId); localStorage.setItem("stageId", props.chooseStageId);
localStorage.setItem("chapterId", props.isactive); localStorage.setItem("chapterId", props.isactive);
}; };
const checkAssDrawer = () => { const checkAssDrawer = () => {
state.assessmentVisible = true; state.assessmentVisible = true;
}; };
const afterVisibleChange = (bool) => { const afterVisibleChange = (bool) => {
if (bool && props.EditInvistId > 0) { if (bool && props.EditInvistId > 0) {
state.assessmentVisible = true; state.assessmentVisible = true;
state.assessmentId = props.EditInvistId; state.assessmentId = props.EditInvistId;
} else { } else {
state.assessmentId = null; state.assessmentId = null;
state.assessmentName = null; state.assessmentName = null;
} }
}; };
const updateTask = () => { const updateTask = () => {
console.log( console.log(
"state.assessmentId ", "state.assessmentId ",
state.assessmentId, state.assessmentId,
state.assessmentName state.assessmentName
); );
if (!state.assessmentId) { if (!state.assessmentId) {
return message.warning("请选择评估"); return message.warning("请选择评估");
} }
let l_data_id = []; let l_data_id = [];
l_data_id.push(Number(state.assessmentId)); l_data_id.push(Number(state.assessmentId));
console.log("state.assessment", state.assessment, state.assessmentId); console.log("state.assessment", state.assessment, state.assessmentId);
if (props.isLevel == 1) { if (props.isLevel == 1) {
if (!props.isactive) { if (!props.isactive) {
message.destroy(); message.destroy();
return message.warning("请先选中关卡"); return message.warning("请先选中关卡");
} }
IsExistence({ IsExistence({
chapterId: Number(props.isactive), chapterId: Number(props.isactive),
courseTaskId: l_data_id, courseTaskId: l_data_id,
routerId: props.routerId, routerId: props.routerId,
type: 11, type: 11,
}) })
.then((res) => { .then((res) => {
console.log("shifouchongfu", res); console.log("shifouchongfu", res);
console.log("路径图中是否包含此评估了", res); console.log("路径图中是否包含此评估了", res);
if (res.data.data.length) { if (res.data.data.length) {
let strdata = res.data.data; let strdata = res.data.data;
let tipStr = ""; let tipStr = "";
for (let i = 0; i < strdata.length; i++) { for (let i = 0; i < strdata.length; i++) {
if (i == strdata.length - 1) { if (i == strdata.length - 1) {
tipStr += strdata[i].courseName; tipStr += strdata[i].courseName;
} else { } else {
tipStr += strdata[i].courseName + "/"; tipStr += strdata[i].courseName + "/";
} }
} }
message.destroy(); message.destroy();
message.warning("评估(" + tipStr + ")重复添加"); message.warning("评估(" + tipStr + ")重复添加");
return; return;
} else { } else {
RouterEditTask({ RouterEditTask({
chapterId: props.isactive, chapterId: props.isactive,
courseId: state.assessmentId, courseId: state.assessmentId,
name: state.assessmentName, name: state.assessmentName,
routerId: props.routerId, routerId: props.routerId,
routerTaskId: props.routerTaskId || 0, routerTaskId: props.routerTaskId || 0,
type: 11, type: 11,
}) })
.then(() => { .then(() => {
message.destroy(); message.destroy();
message.success( message.success(
`${props.edit ? "编辑" : "新增"}关卡任务成功` `${props.edit ? "编辑" : "新增"}关卡任务成功`
); );
ctx.emit("changeData", false); ctx.emit("changeData", false);
closeDrawer(); closeDrawer();
state.addLoading = false; state.addLoading = false;
}) })
.catch(() => { .catch(() => {
message.destroy(); message.destroy();
message.error(`${props.edit ? "编辑" : "新增"}关卡任务失败`); message.error(`${props.edit ? "编辑" : "新增"}关卡任务失败`);
}); });
} }
}) })
.catch((err) => { .catch((err) => {
console.log(err); console.log(err);
}); });
} else if (props.isLevel == 2) { } else if (props.isLevel == 2) {
IsExistenceProject({ IsExistenceProject({
courseTaskId: l_data_id, courseTaskId: l_data_id,
projectId: props.projectId, projectId: props.projectId,
stageId: props.chooseStageId || 0, stageId: props.chooseStageId || 0,
type: 11, type: 11,
}) })
.then((res) => { .then((res) => {
console.log(res); console.log(res);
console.log("项目中是否包含此评估了", res); console.log("项目中是否包含此评估了", res);
if (res.data.data.length) { if (res.data.data.length) {
let strdata = res.data.data; let strdata = res.data.data;
let tipStr = ""; let tipStr = "";
for (let i = 0; i < strdata.length; i++) { for (let i = 0; i < strdata.length; i++) {
if (i == strdata.length - 1) { if (i == strdata.length - 1) {
tipStr += strdata[i].courseName; tipStr += strdata[i].courseName;
} else { } else {
tipStr += strdata[i].courseName + "/"; tipStr += strdata[i].courseName + "/";
} }
} }
message.destroy(); message.destroy();
message.warning("评估(" + tipStr + ")重复添加"); message.warning("评估(" + tipStr + ")重复添加");
return; return;
} else { } else {
apiTask apiTask
.addTask({ .addTask({
courseId: state.assessmentId, courseId: state.assessmentId,
name: state.assessmentName, name: state.assessmentName,
projectId: props.projectId, projectId: props.projectId,
projectTaskId: props.projectTaskId || 0, projectTaskId: props.projectTaskId || 0,
stageId: props.chooseStageId || 0, stageId: props.chooseStageId || 0,
type: 11, type: 11,
}) })
.then(() => { .then(() => {
message.success(`${props.edit ? "编辑" : "新增"}任务成功`); message.success(`${props.edit ? "编辑" : "新增"}任务成功`);
ctx.emit("changeData", false); ctx.emit("changeData", false);
closeDrawer(); closeDrawer();
}) })
.catch(() => { .catch(() => {
message.error(`${props.edit ? "编辑" : "新增"}任务失败`); message.error(`${props.edit ? "编辑" : "新增"}任务失败`);
}); });
} }
}) })
.catch((err) => { .catch((err) => {
console.log(err); console.log(err);
}); });
} else if (props.isLevel == 3) { } else if (props.isLevel == 3) {
IsExistenceProjectTemplate({ IsExistenceProjectTemplate({
courseTaskId: l_data_id, courseTaskId: l_data_id,
projectTemplateId: props.projectTemplateId, projectTemplateId: props.projectTemplateId,
stageId: props.chooseStageId || 0, templateStageId: props.chooseStageId || 0,
type: 11, type: 11,
}).then((res) => { }).then((res) => {
console.log(res); console.log(res);
console.log("项目中是否包含此评估了", res); console.log("项目中是否包含此评估了", res);
if (res.data.data.length) { if (res.data.data.length) {
let strdata = res.data.data; let strdata = res.data.data;
let tipStr = ""; let tipStr = "";
for (let i = 0; i < strdata.length; i++) { for (let i = 0; i < strdata.length; i++) {
if (i == strdata.length - 1) { if (i == strdata.length - 1) {
tipStr += strdata[i].courseName; tipStr += strdata[i].courseName;
} else { } else {
tipStr += strdata[i].courseName + "/"; tipStr += strdata[i].courseName + "/";
} }
} }
message.destroy(); message.destroy();
message.warning("评估(" + tipStr + ")重复添加"); message.warning("评估(" + tipStr + ")重复添加");
return; return;
} else { } else {
addTempTask({ addTempTask({
courseId: state.assessmentId, courseId: state.assessmentId,
name: state.assessmentName, name: state.assessmentName,
projectTemplateId: props.projectTemplateId, projectTemplateId: props.projectTemplateId,
projectTaskId: props.projectTaskId || 0, projectTaskId: props.projectTaskId || 0,
stageId: props.chooseStageId || 0, stageId: props.chooseStageId || 0,
type: 11, type: 11,
}) })
.then(() => { .then(() => {
message.destroy(); message.destroy();
message.success(`${props.edit ? "编辑" : "新增"}任务成功`); message.success(`${props.edit ? "编辑" : "新增"}任务成功`);
ctx.emit("changeData", false); ctx.emit("changeData", false);
closeDrawer(); closeDrawer();
}) })
.catch(() => { .catch(() => {
message.destroy(); message.destroy();
message.error(`${props.edit ? "编辑" : "新增"}任务失败`); message.error(`${props.edit ? "编辑" : "新增"}任务失败`);
}); });
} }
}); });
} }
}; };
return { return {
...toRefs(state), ...toRefs(state),
afterVisibleChange, afterVisibleChange,
closeDrawer, closeDrawer,
updateTask, updateTask,
checkAssDrawer, checkAssDrawer,
}; };
}, },
}; };
</script> </script>
<style lang="scss"> <style lang="scss">
.ant-table-striped :deep(.table-striped) td { .ant-table-striped :deep(.table-striped) td {
background-color: #fafafa !important; background-color: #fafafa !important;
} }
.addinvistDrawer { .addinvistDrawer {
.drawerMain { .drawerMain {
.header { .header {
height: 73px; height: 73px;
border-bottom: 1px solid #e8e8e8; border-bottom: 1px solid #e8e8e8;
display: flex; display: flex;
justify-content: space-between; justify-content: space-between;
align-items: center; align-items: center;
.headerTitle {
font-size: 18px;
font-weight: 600;
color: #333333;
line-height: 25px;
margin-left: 24px;
}
}
.contentMain {
.main {
width: 100%;
.main_left {
padding-right: 30px;
margin-top: 32px;
.main_item {
display: flex;
align-items: center;
.fi_input { .headerTitle {
margin-right: 20px; font-size: 18px;
} font-weight: 600;
.btns { color: #333333;
margin-right: 20px; line-height: 25px;
padding: 0px 26px 0px 26px; margin-left: 24px;
height: 38px; }
background: #4ea6ff; }
border-radius: 8px;
//border: 1px solid rgba(64, 158, 255, 1);
display: flex;
align-items: center;
justify-content: center;
margin-right: 14px;
flex-shrink: 0;
cursor: pointer;
.search {
width: 15px;
height: 17px;
background-image: url("../../assets/images/courseManage/search0.png");
background-size: 100% 100%;
}
.btnText {
font-size: 14px;
font-weight: 400;
color: #ffffff;
line-height: 36px;
margin-left: 5px;
}
}
.btnsn {
padding: 0px 26px 0px 26px;
height: 38px;
background: #ffffff;
border-radius: 8px;
border: 1px solid rgba(64, 158, 255, 1);
display: flex;
align-items: center;
justify-content: center;
margin-right: 14px;
flex-shrink: 0;
cursor: pointer;
.search {
width: 16px;
height: 18px;
background-image: url("../../assets/images/courseManage/reset1.png");
background-size: 100% 100%;
}
.btnText {
font-size: 14px;
font-weight: 400;
color: #4ea6ff;
line-height: 36px;
margin-left: 5px;
}
}
}
.main_notice {
display: flex;
justify-content: space-between;
align-items: center;
margin-bottom: 3px;
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: #4ea6ff;
}
.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 { .contentMain {
height: 72px; .main {
width: 100%; width: 100%;
bottom: 0; .main_left {
left: 0; padding-right: 30px;
display: flex; margin-top: 32px;
align-items: center;
justify-content: center; .main_item {
box-shadow: 0px 1px 35px 0px rgba(118, 136, 166, 0.16); display: flex;
.btn1 { align-items: center;
width: 100px;
height: 40px; .fi_input {
border: 1px solid #4ea6ff; margin-right: 20px;
border-radius: 8px; }
color: #4ea6ff;
background-color: #fff; .btns {
cursor: pointer; margin-right: 20px;
} padding: 0px 26px 0px 26px;
.btn2 { height: 38px;
cursor: pointer; background: #4ea6ff;
width: 100px; border-radius: 8px;
height: 40px; //border: 1px solid rgba(64, 158, 255, 1);
background: #4ea6ff; display: flex;
border-radius: 8px; align-items: center;
border: 0; justify-content: center;
margin-left: 15px; margin-right: 14px;
color: #fff; flex-shrink: 0;
} cursor: pointer;
}
} .search {
width: 15px;
height: 17px;
background-image: url("../../assets/images/courseManage/search0.png");
background-size: 100% 100%;
}
.btnText {
font-size: 14px;
font-weight: 400;
color: #ffffff;
line-height: 36px;
margin-left: 5px;
}
}
.btnsn {
padding: 0px 26px 0px 26px;
height: 38px;
background: #ffffff;
border-radius: 8px;
border: 1px solid rgba(64, 158, 255, 1);
display: flex;
align-items: center;
justify-content: center;
margin-right: 14px;
flex-shrink: 0;
cursor: pointer;
.search {
width: 16px;
height: 18px;
background-image: url("../../assets/images/courseManage/reset1.png");
background-size: 100% 100%;
}
.btnText {
font-size: 14px;
font-weight: 400;
color: #4ea6ff;
line-height: 36px;
margin-left: 5px;
}
}
}
.main_notice {
display: flex;
justify-content: space-between;
align-items: center;
margin-bottom: 3px;
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: #4ea6ff;
}
.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 {
height: 72px;
width: 100%;
bottom: 0;
left: 0;
display: flex;
align-items: center;
justify-content: center;
box-shadow: 0px 1px 35px 0px rgba(118, 136, 166, 0.16);
.btn1 {
width: 100px;
height: 40px;
border: 1px solid #4ea6ff;
border-radius: 8px;
color: #4ea6ff;
background-color: #fff;
cursor: pointer;
}
.btn2 {
cursor: pointer;
width: 100px;
height: 40px;
background: #4ea6ff;
border-radius: 8px;
border: 0;
margin-left: 15px;
color: #fff;
}
}
}
} }
</style> </style>

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@@ -1,10 +1,12 @@
<!-- eslint-disable vue/no-parsing-error -->
<!-- eslint-disable vue/require-v-for-key -->
<template> <template>
<div> <div>
<a-drawer <a-drawer
:visible="visiable" :visible="visiable"
class="drawerStyle ProjCheckship" class="drawerStyle ProjCheckship"
placement="right" placement="right"
width="55%" width="60%"
> >
<div class="drawerMain" id="ProjCheckship"> <div class="drawerMain" id="ProjCheckship">
<div class="header"> <div class="header">
@@ -18,7 +20,7 @@
/> />
</div> </div>
<div style="width:100%;display: grid;grid-template-columns: 750px auto;"> <div style="width:100%;display: grid;grid-template-columns: 750px auto;">
<div class="tabs"> <div class="tabs" style="min-height:800px;" >
<a-tabs v-model:activeKey="activeKey"> <a-tabs v-model:activeKey="activeKey">
<a-tab-pane :key="1" tab="快速选人"> <a-tab-pane :key="1" tab="快速选人">
<div :style="{ height: screenHeight - 235 + 'px' }"> <div :style="{ height: screenHeight - 235 + 'px' }">
@@ -39,7 +41,8 @@
</a-form-item> </a-form-item>
</div> </div>
<div class="chooseLeft" style="display: grid;grid-template-columns: 250px auto"> <div class="chooseLeft" style="display: grid;grid-template-columns: 250px auto">
<div :style="{ height: screenHeight - 235 + 'px' ,overflowY:'auto'}"> <div :style="{ height: screenHeight - 180 + 'px' ,overflowY:'auto'}" style="border: 1px solid #f0f0f0; ;">
<div class="tree" style="margin: 10px 4px 220px 10px;">
<a-tree <a-tree
allow-clear allow-clear
tree-default-expand-all tree-default-expand-all
@@ -53,8 +56,9 @@
@select="stuStuOrgSelect" @select="stuStuOrgSelect"
> >
</a-tree> </a-tree>
</div>
</div> </div>
<div class="tableBox tabb"> <div class="tableBox tabb" style="margin: 0px 4px 120px 10px; border: 1px solid #f0f0f0;">
<a-table <a-table
:columns="stuColumns" :columns="stuColumns"
:data-source="stuData" :data-source="stuData"
@@ -140,13 +144,108 @@
</a-tab-pane> </a-tab-pane>
</a-tabs> </a-tabs>
</div> </div>
<div style="padding:100px 0 0 20px;display: grid;grid-template-rows: auto auto auto;"> <div class="right1">
<div class="onerow">
<div class="onleft">
<div class="already">已选</div>
</div>
</div>
<div
class="selecteds"
:style="{ 'max-height': screenHeight - 235 + 'px' }"
style="overflow-y: auto"
>
<div class="person">快速选人</div>
<div v-for="(item,i) in selectsData.studentList" >
<div v-if="i<11">
<div class="chose">
{{ item.realName }}
<div class="ch" @click="stuDel(i)"></div>
</div>
</div>
<div v-else>
<div v-if ="person">
<div class="chose">
{{ item.realName }}
<div class="ch" @click="stuDel(i)"></div>
</div>
</div>
</div>
</div>
<div v-if="!person && selectsData.studentList.length >10" class="ifsw"><div @click="person = !person" class=sw>查看更多></div></div>
<div v-if="person && selectsData.studentList.length >10" class="ifsw" ><div @click="person = !person" class="sw"> 收起&lt; </div></div>
<!--组织-->
<div class="dept">添加组织</div>
<div v-for="(item,i) in selectsData.deptList" >
<div v-if="i<11">
<div class="chose1">
<div class="span"> {{ item.name }}</div>
<div class="ch1" @click="orgDel(i)"></div>
</div>
</div>
<div v-else>
<div v-if ="dept">
<div class="chose1">
<div class="span"> {{ item.name }}</div>
<div class="ch1" @click="orgDel(i)"></div>
</div>
</div>
</div>
</div>
<div v-if="!dept && selectsData.deptList.length >10" class="ifsw"><div @click="dept = !dept" class=sw>查看更多></div></div>
<div v-if="dept && selectsData.deptList.length >10" class="ifsw" ><div @click="dept = !dept" class="sw"> 收起&lt; </div></div>
<!--受众-->
<div class="group">受众关联</div>
<div v-for="(item,i) in selectsData.groupList" >
<div v-if="i<11">
<div class="chose2">
<div class="span"> {{ item.audienceName }}</div>
<div class="ch2" @click="AuditDel(i)"></div>
</div>
</div>
<div v-else>
<div v-if ="group">
<div class="chose2">
<div class="span"> {{ item.audienceName }}</div>
<div class="ch2" @click="AuditDel(i)"></div>
</div>
</div>
</div>
</div>
<div v-if="!group && selectsData.groupList.length >10" class="ifsw"><div @click="group = !group" class=sw>查看更多></div></div>
<div v-if="group && selectsData.groupList >10" class="ifsw" ><div @click="group = !group" class="sw"> 收起&lt; </div></div>
</div>
</div>
<!-- <div style="padding:100px 0 0 20px;display: grid;grid-template-rows: auto auto auto;">
<div> <div>
<div style="margin-top: 20px">快速选人</div> <div style="margin-top: 20px">快速选人</div>
<a-tag :closable="true" color="#4ea6ff" @close="stuDel(i)" v-for="(item,i) in selectsData.studentList" // eslint-disable-next-line vue/require-v-for-key
<div v-for="(item,i) in selectsData.studentList" >
<a-tag v-if="i < 10" :closable="true" color="#4ea6ff" @close="stuDel(i)"
:key="i" style="margin-top:20px"> :key="i" style="margin-top:20px">
{{ item.realName }} {{ item.realName }}
</a-tag> </a-tag>
<a-tag v-else :closable="true" color="#4ea6ff" @close="stuDel(i)"
style="margin-top:20px">
{{ item.realName }}
</a-tag>
<div></div>
</div>
</div> </div>
<div> <div>
<div style="margin-top: 20px">组织添加</div> <div style="margin-top: 20px">组织添加</div>
@@ -163,7 +262,7 @@
{{ item.audienceName }} {{ item.audienceName }}
</a-tag> </a-tag>
</div> </div>
</div> </div>-->
</div> </div>
<div class="btnn"> <div class="btnn">
<button class="btn1" @click="closeDrawer">取消</button> <button class="btn1" @click="closeDrawer">取消</button>
@@ -205,6 +304,9 @@ const props = defineProps({
default: () => [] default: () => []
} }
}) })
const person =ref(false)
const dept =ref(false)
const group =ref(false)
const visiable = ref(false) const visiable = ref(false)
const activeKey = ref(1) const activeKey = ref(1)
const stageVisible = ref(false) const stageVisible = ref(false)
@@ -404,18 +506,23 @@ function stuDel(i) {
selectsData.value.studentList.splice(i, 1) selectsData.value.studentList.splice(i, 1)
} }
function orgDel(i) {
orgSelectKeys.value = orgSelectKeys.value.filter(e => e !== selectsData.value.deptList[i].id)
selectsData.value.deptList.splice(i, 1)
}
function AuditDel(i) { function AuditDel(i) {
auditSelectKeys.value = auditSelectKeys.value.filter(e => e !== selectsData.value.groupList[i].id) auditSelectKeys.value = auditSelectKeys.value.filter(e => e !== selectsData.value.groupList[i].id)
selectsData.value.groupList.splice(i, 1) selectsData.value.groupList.splice(i, 1)
} }
//
// function orgSelect(key, obj) { // function orgSelect(key, obj) {
// console.log(obj) // console.log(obj)
// request(ORG_CHILD_LIST, {orgId: null}).then(res => { //request(ORG_CHILD_LIST, {orgId: null}).then(res => {
// console.log(res.result) //console.log(res.result)
// }) //})
// } //}
function onStuSelectChange(e, l) { function onStuSelectChange(e, l) {
stuSelectKeys.value = e stuSelectKeys.value = e
@@ -516,7 +623,7 @@ watch(visiable, () => {
}) })
</script> </script>
<style> <style lang="scss">
.ant-btn-primary { .ant-btn-primary {
background-color: #4ea6ff !important; background-color: #4ea6ff !important;
} }
@@ -525,4 +632,196 @@ watch(visiable, () => {
height: 40px; height: 40px;
border-radius: 8px; border-radius: 8px;
} }
.tableBox .ant-table-row .ant-table-cell {
height: 48px;
font-size: 12px;
font-weight: 400;
color: #4F5156;
line-height: 29px;
padding: 0px;
}
.tableBox .ant-table-thead tr th {
font-size: 12px;
}
.ant-tabs-tabpane{
height: 100%;
}
.ant-tabs{
overflow:visible;
}
.right1 {
border-left: 1px solid #f2f6fe;
width: 100%;
margin-left: 20px;
.onerow {
display: flex;
justify-content: space-between;
align-items: center;
margin-right: 40px;
flex-wrap: wrap;
width: 100%;
.onleft {
display: flex;
text-align: center;
.already {
color: rgba(51, 51, 51, 1);
font-size: 16px;
font-weight: 500;
margin-left: 32px;
white-space: nowrap;
// margin-bottom: 20px;
}
.count {
color: #4ea6ff;
font-size: 16px;
margin: 0 6px;
}
.peo {
color: rgba(51, 51, 51, 1);
font-size: 16px;
font-weight: 500;
}
}
.clbox {
margin-right: 50px;
display: flex;
justify-content: center;
align-items: center;
cursor: pointer;
width: 104px;
height: 32px;
border-radius: 4px;
background: #4ea6ff;
.colose {
width: 16px;
height: 16px;
// border-radius: 8px;
// background: #ffffff;
// position: relative;
background-image: url(../../assets/images/basicinfo/ch.png);
background-size: 100%;
margin-right: 4px;
}
.allclear {
color: rgba(255, 255, 255, 1);
font-size: 14px;
}
}
}
.selecteds {
display: flex;
flex-wrap: wrap;
margin-left: 32px;
.person{
width:100%;
margin-top: 20px;
border-top: 1px solid #f2f6fe;
}
.chose {
width: 64px;
height: 24px;
margin-top: 25px;
margin-right: 25px;
display: flex;
align-items: center;
justify-content: center;
border-radius: 2px;
border: 1px solid rgba(56, 139, 225, 1);
color: rgba(56, 139, 225, 1);
font-size: 12px;
position: relative;
.ch {
position: absolute;
width: 18px;
height: 18px;
background-image: url(../../assets/images/basicinfo/ch.png);
right: -8px;
top: -8px;
}
}
.ifsw{
display:flex;
align-items:end;
justify-content: center;
color:#4ea6ff;
}
.sw{
display:flex;
align-items:center;
justify-content: center;
text-align: justify;
color:#4ea6ff;
margin-top: 23px;
margin-left:10px;
}
.dept{
width:100%;
margin-top: 30px;
border-top: 1px solid #f2f6fe;
}
.chose1 {
//width: 90px;
height: 24px;
margin-top: 25px;
margin-right: 25px;
display: flex;
align-items: center;
justify-content: center;
border-radius: 2px;
border: 1px solid rgba(56, 139, 225, 1);
color: rgba(56, 139, 225, 1);
font-size: 12px;
position: relative;
.span{
white-space:nowrap;
overflow:hidden;
text-overflow:ellipsis;
}
.ch1 {
position: absolute;
width: 18px;
height: 18px;
background-image: url(../../assets/images/basicinfo/ch.png);
right: -8px;
top: -8px;
}
}
.group{
width:100%;
margin-top: 30px;
border-top: 1px solid #f2f6fe;
}
.chose2 {
//width: 120px;
height: 24px;
margin-top: 25px;
margin-right: 25px;
display: flex;
align-items: center;
justify-content: center;
border-radius: 2px;
border: 1px solid rgba(56, 139, 225, 1);
color: rgba(56, 139, 225, 1);
font-size: 12px;
position: relative;
.span{
white-space:nowrap;
overflow:hidden;
text-overflow:ellipsis;
}
.ch2 {
position: absolute;
width: 18px;
height: 18px;
background-image: url(../../assets/images/basicinfo/ch.png);
right: -8px;
top: -8px;
}
}
}
}
</style> </style>

View File

@@ -118,7 +118,7 @@ const tablecolumns = ref([
title: "姓名", title: "姓名",
dataIndex: "studentName", dataIndex: "studentName",
key: "studentName", key: "studentName",
width: "20%", width: "10%",
align: "left", align: "left",
className: "h", className: "h",
}, },
@@ -126,7 +126,7 @@ const tablecolumns = ref([
title: "工号", title: "工号",
dataIndex: "studentUserNo", dataIndex: "studentUserNo",
key: "studentUserNo", key: "studentUserNo",
width: "10%", width: "20%",
align: "center", align: "center",
className: "h", className: "h",
ellipsis: true, ellipsis: true,
@@ -135,7 +135,7 @@ const tablecolumns = ref([
title: "部门", title: "部门",
dataIndex: "studentDepartName", dataIndex: "studentDepartName",
key: "studentDepartName", key: "studentDepartName",
width: "10%", width: "20%",
align: "center", align: "center",
className: "h", className: "h",
ellipsis: true, ellipsis: true,
@@ -144,7 +144,7 @@ const tablecolumns = ref([
title: "加入方式", title: "加入方式",
dataIndex: "source", dataIndex: "source",
key: "source", key: "source",
width: "10%", width: "20%",
align: "center", align: "center",
customRender: ({record: {source}}) => customRender: ({record: {source}}) =>
({1: "快速添加", 2: "组织", 3: "受众"}[source]), ({1: "快速添加", 2: "组织", 3: "受众"}[source]),
@@ -174,7 +174,7 @@ const tableData = ref({
}); });
const stuRowSelection = computed(() => ({ const stuRowSelection = computed(() => ({
columnWidth: 20, columnWidth: 10,
selectedRowKeys: stuSelectKeys.value, selectedRowKeys: stuSelectKeys.value,
onChange: onStuSelectChange, onChange: onStuSelectChange,
preserveSelectedRowKeys: true, preserveSelectedRowKeys: true,

View File

@@ -143,7 +143,7 @@
placeholder="请输入课程名称" placeholder="请输入课程名称"
v-model:value="xzinputV1" v-model:value="xzinputV1"
v-model:validate="validate" v-model:validate="validate"
v-model:finished="finished"
:maxlength="20" :maxlength="20"
show-count show-count
:type="2" :type="2"
@@ -364,7 +364,7 @@
placeholder="请输入课程名称" placeholder="请输入课程名称"
v-model:value="qdms_inputV1" v-model:value="qdms_inputV1"
v-model:validate="validate" v-model:validate="validate"
v-model:finished="finished"
:maxlength="20" :maxlength="20"
show-count show-count
:type="2" :type="2"
@@ -3732,7 +3732,7 @@ export default defineComponent({
codevisible: false, //二维码弹窗 codevisible: false, //二维码弹窗
codeInfo: null, //二维码内容 codeInfo: null, //二维码内容
codeUrl: codeUrl, codeUrl: codeUrl,
finished: false,
// 课程三级分类 // 课程三级分类
options2222: [ options2222: [
{ {
@@ -4658,11 +4658,9 @@ export default defineComponent({
} }
console.log("state.validate", state.validate); console.log("state.validate", state.validate);
if (!state.finished) {
return;
}
if (!state.validate && state.finished) { if (!state.validate) {
message.destroy(); message.destroy();
return message.warning("该课程名称已存在"); return message.warning("该课程名称已存在");
} }

File diff suppressed because it is too large Load Diff

View File

@@ -110,7 +110,7 @@
placeholder="请输入评估名称" placeholder="请输入评估名称"
v-model:value="assessmentName" v-model:value="assessmentName"
v-model:validate="validate" v-model:validate="validate"
v-model:finished="finished"
:maxlength="15" :maxlength="15"
show-count show-count
:type="4" :type="4"
@@ -199,6 +199,7 @@ import { toDate } from "../../api/method.js";
import store from "@/store"; import store from "@/store";
import { message } from "ant-design-vue"; import { message } from "ant-design-vue";
import NameInput from "@/components/project/NameInput"; import NameInput from "@/components/project/NameInput";
import {validateName} from "@/api/index1";
export default { export default {
name: "learningPath", name: "learningPath",
components: { components: {
@@ -312,7 +313,7 @@ export default {
copy_hs: false, copy_hs: false,
back_hs: false, back_hs: false,
pub_hs: false, pub_hs: false,
finished:false,
validate: true, validate: true,
}); });
const tableDataFunc = () => { const tableDataFunc = () => {
@@ -590,20 +591,26 @@ export default {
state.assessmentName = item.assessmentName; state.assessmentName = item.assessmentName;
state.newNext = true; state.newNext = true;
}; };
const handleNext = () => { const handleNext = async() => {
if (!state.assessmentId) { if (!state.assessmentId) {
if (!state.assessmentName) { if (!state.assessmentName) {
message.error("请输入评估名称"); message.error("请输入评估名称");
return false; return false;
} }
if (!state.finished) { if (!state.validate ) {
return;
}
if (!state.validate && state.finished) {
message.destroy(); message.destroy();
return message.warning("该评估名称已存在"); return message.warning("该评估名称已存在");
} }
const offName = await validateName({name: state.assessmentName, type:4, id:state.assessmentId}).then(res => {
return res.data.data == 1;
});
if(offName){
message.destroy();
return message.warning("课程名称重复,请重新填写");
}
store.commit("SET_assessmentName", state.assessmentName); store.commit("SET_assessmentName", state.assessmentName);
router.push("/researchadd"); router.push("/researchadd");
handleCancel(); handleCancel();