This commit is contained in:
Pengxiansen
2025-02-18 18:00:01 +08:00
parent b58772e88d
commit 0d76654361
8 changed files with 447 additions and 305 deletions

View File

@@ -85,3 +85,10 @@ export const getStudyStatisticsList = (data) => http.post('/professional/statics
// 专业力列表 // 专业力列表
export const boeuGrowthPlatePageList = (obj) => http.post('/boeu/growth/pageList', obj) export const boeuGrowthPlatePageList = (obj) => http.post('/boeu/growth/pageList', obj)
// 是否按顺序学习
export const openOrCloseSortSwitch = (growthId) => http.get('/professional/task/openOrCloseSortSwitch/' + growthId,)
// 新建专业力必修
export const saveGrowth = (data) => http.post('/professional/compulsory/saveGrowth', data)

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 MiB

View File

@@ -1,10 +1,5 @@
<template> <template>
<a-select <a-select
:getPopupContainer="
(triggerNode) => {
return triggerNode.parentNode || document.body;
}
"
:mode="multiple" :mode="multiple"
v-model:value="selectedValue" v-model:value="selectedValue"
:style="{ width: width || '' }" :style="{ width: width || '' }"
@@ -15,6 +10,7 @@
@focus="focus" @focus="focus"
allowClear allowClear
showArrow showArrow
:filter-option="filterOption"
showSearch showSearch
:disabled="disabled" :disabled="disabled"
></a-select> ></a-select>
@@ -84,7 +80,10 @@ export default {
emit("update:value", newVal); emit("update:value", newVal);
emit("change"); emit("change");
} }
async function handleSearch(val) { const filterOption = (input, option) => {
return option.label.toLowerCase().indexOf(input.toLowerCase()) >= 0;
};
function handleSearch(val) {
console.log(val, "val"); console.log(val, "val");
} }
function focus() { function focus() {
@@ -94,6 +93,7 @@ export default {
selectedValue, selectedValue,
options, options,
onSelectChange, onSelectChange,
filterOption,
handleSearch, handleSearch,
focus, focus,
}; };

View File

@@ -1,10 +1,5 @@
<template> <template>
<a-select <a-select
:getPopupContainer="
(triggerNode) => {
return triggerNode.parentNode || document.body;
}
"
:mode="multiple" :mode="multiple"
v-model:value="selectedValue" v-model:value="selectedValue"
:style="{ width: width || '' }" :style="{ width: width || '' }"
@@ -13,6 +8,7 @@
@change="onSelectChange" @change="onSelectChange"
allowClear allowClear
showArrow showArrow
:filter-option="filterOption"
showSearch showSearch
></a-select> ></a-select>
</template> </template>
@@ -67,9 +63,14 @@ export default {
emit("update:value", newVal); emit("update:value", newVal);
emit("update:postList", postList); emit("update:postList", postList);
} }
const filterOption = (input, option) => {
return option.label.toLowerCase().indexOf(input.toLowerCase()) >= 0;
};
return { return {
selectedValue, selectedValue,
options, options,
filterOption,
onSelectChange, onSelectChange,
}; };
}, },

View File

@@ -16,6 +16,18 @@
allowClear allowClear
></a-select> ></a-select>
</div> </div>
<div class="select">
<a-select
v-model:value="dataSourceValue"
style="width: 181px; height: 40px"
placeholder="请选择数据来源"
:options="[
{ value: '1', label: 'AMED' },
{ value: '2', label: '手动添加' },
]"
allowClear
></a-select>
</div>
<div class="grow_btn_left"> <div class="grow_btn_left">
<div class="btn1" @click="searchList"> <div class="btn1" @click="searchList">
<div class="search"></div> <div class="search"></div>
@@ -26,9 +38,18 @@
<div class="btnText">重置</div> <div class="btnText">重置</div>
</div> </div>
</div> </div>
<!-- <div class="growth_switch"> </div>
<img src="../../assets/images/growthpath/switch.png" alt=""> <div class="btns">
</div> --> <!-- <router-link to="/projectadd">
<div class="btn btn3">
<div class="search"></div>
<div class="btnText">创建路径</div>
</div>
</router-link> -->
<div class="btn btn3" @click="handleOut">
<div class="search"></div>
<div class="btnText">创建必修</div>
</div>
</div> </div>
<div class="grow_con"> <div class="grow_con">
<div class="grow_list"> <div class="grow_list">
@@ -49,7 +70,7 @@
>发布</a-button >发布</a-button
> >
<a-button <a-button
v-if="checkGrowthPer(record.permissions) && !record.isPublished" v-if="checkGrowthPer(record.permissions)"
type="link" type="link"
class="table_btn" class="table_btn"
@click="editPath(record)" @click="editPath(record)"
@@ -58,7 +79,7 @@
<a-button type="link" class="table_btn" @click="manage(record)" <a-button type="link" class="table_btn" @click="manage(record)"
>管理</a-button >管理</a-button
> >
<DropDown v-if="record?.permissions?.includes('17')" value="授权"> <!-- <DropDown v-if="record?.permissions?.includes('17')" value="授权">
<TableModelStudent :id="record.id" title="转移归属权" :type="17" <TableModelStudent :id="record.id" title="转移归属权" :type="17"
>归属权</TableModelStudent >归属权</TableModelStudent
> >
@@ -68,7 +89,7 @@
<TableModelStudent :id="record.id" title="添加管理权" :type="16" <TableModelStudent :id="record.id" title="添加管理权" :type="16"
>管理权</TableModelStudent >管理权</TableModelStudent
> >
</DropDown> </DropDown> -->
<a-dropdown <a-dropdown
:getPopupContainer="(triggerNode) => triggerNode.parentNode" :getPopupContainer="(triggerNode) => triggerNode.parentNode"
:trigger="['click']" :trigger="['click']"
@@ -150,8 +171,13 @@
<span>标准岗位</span> <span>标准岗位</span>
</div> </div>
<div class="bg_body_input"> <div class="bg_body_input">
<PostSelectNew v-model:value="statusPosts" width="384px" disabled> <a-input
</PostSelectNew> v-model:value="statusPosts"
:disabled="editId"
style="width: 384px; height: 40px"
allowClear
placeholder="填写标准岗位"
/>
</div> </div>
</div> </div>
<div class="bg_body_bt" style="align-items: flex-start"> <div class="bg_body_bt" style="align-items: flex-start">
@@ -167,9 +193,10 @@
<div class="bg_body_input"> <div class="bg_body_input">
<a-input <a-input
v-model:value="statusOffices" v-model:value="statusOffices"
disabled :disabled="editId"
style="width: 384px; height: 40px" style="width: 384px; height: 40px"
allowClear allowClear
placeholder="填写任职资格等级"
/> />
</div> </div>
</div> </div>
@@ -186,7 +213,7 @@
<div class="bg_body_input"> <div class="bg_body_input">
<a-input <a-input
v-model:value="band" v-model:value="band"
disabled :disabled="editId"
style="width: 384px; height: 40px" style="width: 384px; height: 40px"
placeholder="填写Band职级" placeholder="填写Band职级"
allowClear allowClear
@@ -209,6 +236,52 @@
</div> </div>
</div> </div>
<div class="bg_body_bt" style="align-items: flex-start"> <div class="bg_body_bt" style="align-items: flex-start">
<div class="bg_body_bttext" style="margin-top: 11px">
<div class="bg_body_btimg">
<img
src="@/assets/images/coursewareManage/asterisk.png"
alt=""
/>
</div>
<span>路径图背景</span>
</div>
<div class="bg_body_input">
<div style="display: flex">
<div
@click="template = 1"
class="learnBgItem"
:style="{
border:
template === 1
? '2px solid rgba(78, 166, 255, 1)'
: '1px solid #ccc',
}"
>
<img
class="im"
src="../../assets/images/growthpath/path1.png"
/>
</div>
<div
@click="template = 2"
class="learnBgItem"
:style="{
border:
template === 2
? '2px solid rgba(78, 166, 255, 1)'
: '1px solid #ccc',
}"
>
<img
class="im"
src="../../assets/images/growthpath/path2.png"
/>
</div>
</div>
</div>
</div>
<!-- <div class="bg_body_bt" style="align-items: flex-start">
<div class="bg_body_bttext"> <div class="bg_body_bttext">
<div class="bg_body_btimg"> <div class="bg_body_btimg">
<img <img
@@ -231,7 +304,7 @@
</div> </div>
</a-radio-group> </a-radio-group>
</div> </div>
</div> </div> -->
<div class="bg_body_bt" style="align-items: flex-start"> <div class="bg_body_bt" style="align-items: flex-start">
<div class="bg_body_bttext"> <div class="bg_body_bttext">
<span>说明</span> <span>说明</span>
@@ -321,6 +394,7 @@ import {
published, published,
withdrawal, withdrawal,
updatePostInfomation, updatePostInfomation,
saveGrowth,
} from "@/api/growthpath"; } from "@/api/growthpath";
export default { export default {
name: "growthpath", name: "growthpath",
@@ -340,7 +414,24 @@ export default {
// 掉接口 // 掉接口
listDatas(); listDatas();
}); });
// 动态引入图片
const getAssetsFile = (url) => {
return new URL(
`../../assets/image/growthpath/${url}.png`,
import.meta.url
).href;
};
// 路径图背景选项
const imgData = [
{
url: getAssetsFile("path1"),
code: 1,
},
{
url: "../../assets/image/growthpath/addrenwu.png",
code: 2,
},
];
const store = useStore(); const store = useStore();
const router = useRouter(); const router = useRouter();
const state = reactive({ const state = reactive({
@@ -355,6 +446,7 @@ export default {
pathWays: "", pathWays: "",
statusPost: null, statusPost: null,
matchRules: "1", matchRules: "1",
template: 1,
matchRulesVisible: false, matchRulesVisible: false,
statusPostMaps: [], statusPostMaps: [],
statusPosts: null, statusPosts: null,
@@ -364,8 +456,9 @@ export default {
statusOffice: null, statusOffice: null,
statusRanks: [], statusRanks: [],
rankList: [], rankList: [],
bandLists: [], band: "",
statusValue: null, statusValue: null,
dataSourceValue: null,
loadingList: false, loadingList: false,
total: 10, total: 10,
pageNum: 1, pageNum: 1,
@@ -373,6 +466,9 @@ export default {
dataList: [], dataList: [],
keepLearner: false, keepLearner: false,
}); });
const handleOut = () => {
state.bg_check = true;
};
const releaseLearnPath = (item) => { const releaseLearnPath = (item) => {
dialog({ dialog({
content: "是否发布该条数据?", content: "是否发布该条数据?",
@@ -427,13 +523,24 @@ export default {
return record.isPublished ? "已发布" : "未发布"; return record.isPublished ? "已发布" : "未发布";
}, },
}, },
// {
// title: "归属人",
// dataIndex: "createName",
// key: "createName",
// width: 60,
// align: "center",
// ellipsis: true,
// },
{ {
title: "归属人", title: "数据来源",
dataIndex: "createName", dataIndex: "dataSource",
key: "createName", key: "dataSource",
width: 60, width: 100,
align: "center", align: "center",
ellipsis: true, ellipsis: true,
customRender: ({ record }) => {
return record.dataSource == 1 ? "AMED" : "手动添加";
},
}, },
{ {
title: "操作", title: "操作",
@@ -455,6 +562,7 @@ export default {
isPublished: state.statusValue, isPublished: state.statusValue,
bandIdList: state.statusRank, //职级 bandIdList: state.statusRank, //职级
qualsLevelCode: state.statusOffice, qualsLevelCode: state.statusOffice,
dataSource: state.dataSourceValue,
}; };
console.log(store); console.log(store);
// 判断当前用户是否是专业力必修角色管理员,如果不是查询列表时需传入员工工号 // 判断当前用户是否是专业力必修角色管理员,如果不是查询列表时需传入员工工号
@@ -482,6 +590,7 @@ export default {
state.statusPost = null; state.statusPost = null;
state.statusRank = []; state.statusRank = [];
state.statusOffice = null; state.statusOffice = null;
state.dataSourceValue = null;
state.pageNum = 1; state.pageNum = 1;
listDatas(); listDatas();
}; };
@@ -500,6 +609,7 @@ export default {
state.elePublishedNum = record.elePublishedNum; state.elePublishedNum = record.elePublishedNum;
state.pathWays = record.description; state.pathWays = record.description;
state.band = record.band; state.band = record.band;
state.template = record.template;
state.matchRules = record.matchRules || "1"; state.matchRules = record.matchRules || "1";
state.bg_check = true; state.bg_check = true;
}; };
@@ -510,6 +620,16 @@ export default {
}; };
// 确定 // 确定
const confirm = () => { const confirm = () => {
if (!state.statusPosts) {
return message.error("请输入标准岗位");
}
if ( !state.band) {
return message.error("请输入Band职级");
}
if ( !state.statusOffices) {
return message.error("请输入任职资格等级");
}
if (state.courseNum !== 0 && !state.courseNum) { if (state.courseNum !== 0 && !state.courseNum) {
return message.error("请输入完成选修数量"); return message.error("请输入完成选修数量");
} }
@@ -519,29 +639,42 @@ export default {
return; return;
} }
const params = { const params = {
stdPosition: state.statusPosts, stdPositionDesr: state.statusPosts,
qualsLevelDesr: state.statusOffices, qualsLevelDesr: state.statusOffices,
electivesCompletedNum: state.courseNum, electivesCompletedNum: state.courseNum,
template: state.template,
description: state.pathWays, description: state.pathWays,
matchRules: state.matchRules, matchRules: state.matchRules,
id: state.editId ? state.editId : null, id: state.editId ? state.editId : null,
keepLearner: state.keepLearner, keepLearner: state.keepLearner,
template: state.template,
band: state.band,
}; };
if (state.editId) {
updatePostInfomation(params) updatePostInfomation(params)
.then((res) => { .then((res) => {
if (res.data.code == 200) { if (res.data.code == 200) {
if (state.matchRules == 1) {
message.warning("自动匹配学员为异步添加,请稍后手动刷新学员");
}
message.success("保存成功"); message.success("保存成功");
state.bg_check = false; of_exit();
listDatas(); listDatas();
} }
}) })
.catch((err) => { .catch((err) => {
message.error(err.data.msg); message.error(err.data.msg);
}); });
// of_exit() } else {
saveGrowth(params)
.then((res) => {
if (res.data.code == 200) {
message.success("保存成功");
of_exit();
listDatas();
}
})
.catch((err) => {
message.error(err.data.msg);
});
}
}; };
const of_exit = () => { const of_exit = () => {
state.statusPosts = null; state.statusPosts = null;
@@ -603,8 +736,10 @@ export default {
confirm, confirm,
editPath, editPath,
manage, manage,
imgData,
updateList, updateList,
withdraw, withdraw,
handleOut,
releaseLearnPath, releaseLearnPath,
UpdateRecordRef, UpdateRecordRef,
matchRulesChange, matchRulesChange,
@@ -628,6 +763,7 @@ export default {
.growthpath { .growthpath {
width: 100%; width: 100%;
.filterItems { .filterItems {
display: flex; display: flex;
flex-wrap: wrap; flex-wrap: wrap;
@@ -693,6 +829,51 @@ export default {
margin-bottom: 20px; margin-bottom: 20px;
} }
} }
.btns {
display: flex;
padding-left: 24px;
padding-bottom: 10px;
// flex-wrap: wrap;
.btn {
padding: 0px 26px 0px 26px;
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 {
background-size: 100%;
}
.btnText {
font-size: 14px;
font-weight: 400;
color: #ffffff;
line-height: 36px;
margin-left: 5px;
}
}
.btn3 {
margin-right: 0px;
.search {
width: 17px;
height: 18px;
background-image: url("../../assets/images/courseManage/add0.png");
}
}
.btn3:active {
background: #0982ff;
}
}
.grow_list { .grow_list {
margin-left: 24px; margin-left: 24px;
.grow_btn { .grow_btn {
@@ -726,48 +907,6 @@ export default {
line-height: 31px; line-height: 31px;
} }
} }
.grow_btn_right {
display: flex;
margin-right: 61px;
.btn1 {
padding: 0px 26px 0px 26px;
height: 38px;
background: #4ea6ff;
border-radius: 8px;
display: flex;
align-items: center;
justify-content: center;
margin-right: 14px;
flex-shrink: 0;
cursor: pointer;
.search {
width: 17px;
height: 18px;
margin-right: 6px;
background-image: url("../../assets/images/courseManage/add0.png");
}
.btnText {
font-size: 14px;
font-weight: 400;
color: #ffffff;
line-height: 36px;
margin-left: 5px;
}
}
.btnns2 {
width: 130px;
height: 40px;
background: #ffffff;
border-radius: 8px;
border: 1px solid #65a4f8;
margin-left: 25px;
box-sizing: border-box;
color: #65a4f8;
text-align: center;
cursor: pointer;
line-height: 40px;
}
}
} }
.grow_table { .grow_table {
margin: 0 24px 16px 0; margin: 0 24px 16px 0;
@@ -852,13 +991,10 @@ export default {
background-size: 100% 100%; background-size: 100% 100%;
} }
} }
.text_color {
color: #d9d9d9;
}
.bg_body { .bg_body {
width: 80%; width: 80%;
margin: 3px auto; margin: 3px auto;
.bg_body_bt { .bg_body_bt {
display: flex; display: flex;
align-items: center; align-items: center;
@@ -878,118 +1014,23 @@ export default {
background-size: 100% 100%; background-size: 100% 100%;
} }
} }
.mbl_items12 {
width: 333px;
margin-left: 128px;
.item_text {
width: 300px;
white-space: nowrap; /* 不换行 */
overflow: hidden; /* 超出部分隐藏 */
text-overflow: ellipsis; /* 使用省略号表示被隐藏的部分 */
}
.i12_box1 {
display: flex;
align-items: center;
padding: 10px 0px 17px 21px;
border: 1px solid #eff4fc;
border-radius: 8px;
margin-bottom: 10px;
.file_img {
width: 27px;
height: 32px;
background-image: url(@/assets/images/coursewareManage/imgs.png);
margin-right: 22px;
img {
width: 100%;
height: 100%;
}
}
.file_detail {
width: 250px;
margin-right: 21px;
.file_updata {
display: flex;
align-items: center;
.updatabox {
position: relative;
width: 230px;
height: 5px;
background-color: rgba(192, 192, 192, 0.25);
border-radius: 3px;
.updatacolor {
position: absolute;
left: 0;
width: 100%;
height: 5px;
background-color: #57c887;
border-radius: 3px;
}
.updatacolor2 {
position: absolute;
left: 0;
width: 80%;
height: 5px;
background-color: #ff7474;
border-radius: 3px;
}
.updatacolor3 {
position: absolute;
left: 0;
width: 60%;
height: 5px;
background-color: #4ea6ff;
border-radius: 3px;
}
.updataxq1 {
margin-top: 7px;
}
.updataxq {
position: absolute;
right: 2px;
top: -37px;
color: #57c887;
}
.updataxq2 {
position: absolute;
right: 2px;
top: -35px;
color: #ff7474;
}
.updataxq3 {
position: absolute;
right: 2px;
top: -30px;
color: #4ea6ff;
}
}
}
}
.file_operation {
display: flex;
.fobox {
margin-right: 5px;
cursor: pointer;
}
}
}
}
} }
.bg_body_input { .bg_body_input {
flex: 1; flex: 1;
position: relative; position: relative;
.learnBgItem {
border-radius: 8px;
width: 136px;
height: 106px;
background-size: 100%;
background-repeat: no-repeat;
margin-bottom: 20px;
margin-right: 6px;
.im {
width: 100%;
height: 100%;
}
}
.ant-upload-picture-card-wrapper { .ant-upload-picture-card-wrapper {
width: 200px; width: 200px;
margin-right: 18px; margin-right: 18px;
@@ -1069,11 +1110,6 @@ export default {
} }
} }
.btn5 {
border: 1px solid rgba(64, 158, 255, 1);
color: #4ea6ff;
}
.btn6 { .btn6 {
background-color: #4ea6ff; background-color: #4ea6ff;
color: #ffffff; color: #ffffff;
@@ -1085,83 +1121,6 @@ export default {
border: 1px solid #387df7; border: 1px solid #387df7;
color: #387df7; color: #387df7;
} }
.btndesign {
background-color: #eff4fc;
color: #ffffff;
}
}
}
.headers {
margin-left: 38px;
margin-right: 38px;
margin-top: 30px;
display: flex;
justify-content: space-between;
flex-wrap: wrap;
.button_btn {
display: flex;
}
.headers_item {
margin-right: 20px;
margin-bottom: 20px;
.headers_item_text {
margin-right: 15px;
}
.headers_item_btn {
padding: 0px 26px 0px 26px;
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 {
background-size: 100%;
}
.btnText {
font-size: 14px;
font-weight: 400;
color: #ffffff;
line-height: 36px;
margin-left: 5px;
}
}
.btn1 {
.search {
width: 15px;
height: 17px;
background-image: url("../../assets/images/courseManage/search0.png");
}
}
.btnns2 {
.search {
width: 16px;
height: 18px;
background-image: url("../../assets/images/courseManage/reset0.png");
}
}
::v-deep .ant-select {
border-radius: 5px;
width: 100%;
min-height: 40px;
.ant-select-selector {
border-radius: 8px;
width: 100%;
min-height: 40px;
}
.ant-select-selection-placeholder {
line-height: 40px;
}
.ant-select-selection-item {
line-height: 40px;
}
}
} }
} }
} }

View File

@@ -194,7 +194,10 @@
<!-- 路径管理 --> <!-- 路径管理 -->
<div style="flex: 1"> <div style="flex: 1">
<div class="onerow" style="margin: 0 0 0 26px"> <div class="onerow" style="margin: 0 0 0 26px">
<div style="display: flex; justify-content: center">
<div class="taskmain">任务大纲</div> <div class="taskmain">任务大纲</div>
</div>
<router-link <router-link
:to="{ :to="{
path: '/editingtasks', path: '/editingtasks',
@@ -210,7 +213,23 @@
<span class="editextb">编辑任务</span> <span class="editextb">编辑任务</span>
</router-link> </router-link>
</div> </div>
<div class="tabs" style="margin-left: 26px"> <div class="tabs">
<a-radio-group
button-style="solid"
v-model:value="courseType"
@change="getListTask"
>
<a-radio-button value="1">必修</a-radio-button>
<a-radio-button value="2">选修</a-radio-button>
</a-radio-group>
<div class="switch">
<a-switch
@change="sortSwitchChange"
v-model:checked="basicData.sortSwitch"
/>
<div style="margin-left: 5px">是否按顺序学习</div>
</div>
<!-- <div>
<a-tabs <a-tabs
v-model:activeKey="courseType" v-model:activeKey="courseType"
size="large" size="large"
@@ -219,6 +238,7 @@
<a-tab-pane key="1" tab="必修"></a-tab-pane> <a-tab-pane key="1" tab="必修"></a-tab-pane>
<a-tab-pane key="2" tab="选修"></a-tab-pane> <a-tab-pane key="2" tab="选修"></a-tab-pane>
</a-tabs> </a-tabs>
</div> -->
</div> </div>
<!-- 无数据显示快速创建 --> <!-- 无数据显示快速创建 -->
<div v-if="!listTaskData.length" style="margin-top: 20px"> <div v-if="!listTaskData.length" style="margin-top: 20px">
@@ -329,18 +349,12 @@
</a-tooltip> </a-tooltip>
</template> </template>
<template v-else> <template v-else>
<a-dropdown :trigger="['click']"> <div @click="handlerSuperiors(element)">
<div>
<a-button type="link"> <a-button type="link">
选择需解锁的上级任务 选择需解锁的上级任务
</a-button> </a-button>
<DownOutlined
:style="{
color: '#1890ff',
}"
/>
</div> </div>
<!-- <a-dropdown :trigger="['click']">
<template #overlay> <template #overlay>
<a-menu> <a-menu>
<a-menu-item <a-menu-item
@@ -352,7 +366,7 @@
</a-menu-item> </a-menu-item>
</a-menu> </a-menu>
</template> </template>
</a-dropdown> </a-dropdown> -->
</template> </template>
</div> </div>
<div class="operations" v-if="checkGrowthPer(preId)"> <div class="operations" v-if="checkGrowthPer(preId)">
@@ -489,7 +503,6 @@
</div> </div>
</template> </template>
</Draggable> </Draggable>
</div> </div>
<!-- 有数据--> <!-- 有数据-->
<div style="display: flex; height: 20px"></div> <div style="display: flex; height: 20px"></div>
@@ -580,6 +593,79 @@
<!-- 二维码弹窗 --> <!-- 二维码弹窗 -->
<!-- 面授课开课弹框 --> <!-- 面授课开课弹框 -->
<GrowthOpenCourse ref="coursePlanRef" :type="4" /> <GrowthOpenCourse ref="coursePlanRef" :type="4" />
<a-modal
v-model:visible="setSuperiorsVisible"
:footer="null"
closable="false"
style="margin-top: 350px"
@cancel="setSuperiorsVisible = false"
>
<div
class="selectonlineface"
:style="{ display: setSuperiorsVisible ? 'block' : 'none' }"
>
<div class="bg_headers"></div>
<div class="bg_main">
<div class="bg_main_header">
<div class="bg_main_header_icon"></div>
<div>绑定上级任务</div>
<div
class="bg_main_header_close"
@click="setSuperiorsVisible = false"
></div>
</div>
<div class="bg_body">
<div
v-for="(item, key) in listTaskData"
style="
width: 100%;
display: flex;
justify-content: space-between;
align-items: center;
margin-bottom: 12px;
background: rgb(247, 251, 253);
height: 40px;
padding: 5px 10px 5px 5px;
border-radius: 5px;
"
>
<div
style="
overflow: hidden;
white-space: nowrap;
text-overflow: ellipsis;
width: 220px;
"
>
{{ item.taskName }}
</div>
<div
@click="selectSuperiorTask(setSuperiorsActive, item)"
style="
width: 60px;
height: 30px;
text-align: center;
line-height: 30px;
background: #0078fc;
border-radius: 5px;
color: #fff;
cursor: pointer;
"
:style="{
filter:
setSuperiorsActive.id == item.id
? 'grayscale(1)'
: 'grayscale(0)',
}"
>
绑定
</div>
</div>
</div>
</div>
</div>
</a-modal>
</template> </template>
<script lang="jsx"> <script lang="jsx">
import { ref, reactive, toRefs, onMounted, createVNode, watch } from "vue"; import { ref, reactive, toRefs, onMounted, createVNode, watch } from "vue";
@@ -616,6 +702,7 @@ import {
toSortTask, toSortTask,
saveSuperiorTask, saveSuperiorTask,
delSuperiorTask, delSuperiorTask,
openOrCloseSortSwitch,
taskInformation, taskInformation,
taskCompletionRate, taskCompletionRate,
} from "@/api/growthpath"; } from "@/api/growthpath";
@@ -650,6 +737,7 @@ export default {
commonData: null, commonData: null,
showTimeText: null, showTimeText: null,
onlineVisible: false, onlineVisible: false,
setSuperiorsVisible: false,
total: 0, total: 0,
pageSize: 99999, pageSize: 99999,
pageNum: 1, pageNum: 1,
@@ -721,6 +809,13 @@ export default {
}); });
}; };
// 开启绑定上级任务的弹窗
const setSuperiorsActive = ref(null);
const handlerSuperiors = (element) => {
// 保存需要操作的数据
setSuperiorsActive.value = element;
state.setSuperiorsVisible = true;
};
const qrCodeItems = ref([]); const qrCodeItems = ref([]);
const visibleEwm = ref({}); const visibleEwm = ref({});
const qrcodeVisible = async (item) => { const qrcodeVisible = async (item) => {
@@ -830,7 +925,12 @@ export default {
// 保存/删除上级任务 // 保存/删除上级任务
const selectSuperiorTask = (element, row) => { const selectSuperiorTask = (element, row) => {
console.log(element, row); console.log(element, row);
if (row) { if (row) {
if (element.id === row.id) {
message.warning("不可绑定");
return;
}
// 保存需解锁的上级任务 // 保存需解锁的上级任务
saveSuperiorTask({ saveSuperiorTask({
id: element.id, id: element.id,
@@ -838,6 +938,7 @@ export default {
}).then((res) => { }).then((res) => {
message.success("操作成功"); message.success("操作成功");
element.superiorTaskName = row.taskName; element.superiorTaskName = row.taskName;
state.setSuperiorsVisible = false;
}); });
} else { } else {
// 删除需解锁的上级任务 // 删除需解锁的上级任务
@@ -1187,7 +1288,13 @@ export default {
const openCourse = (ele) => { const openCourse = (ele) => {
coursePlanRef.value.openDrawer(ele); coursePlanRef.value.openDrawer(ele);
}; };
// 是否自动学习开关
const sortSwitchChange = () => {
openOrCloseSortSwitch(state.routerId).then((res) => {
message.success("操作成功");
getListTask()
});
};
return { return {
...toRefs(state), ...toRefs(state),
stuRef, stuRef,
@@ -1196,6 +1303,7 @@ export default {
changeTabs, changeTabs,
resize, resize,
releaseLearnPath, releaseLearnPath,
sortSwitchChange,
showStudent, showStudent,
showTest, showTest,
showOnline, showOnline,
@@ -1214,11 +1322,13 @@ export default {
handleMenuClickpg, handleMenuClickpg,
handleMenuClick, handleMenuClick,
qrcodeVisible, qrcodeVisible,
handlerSuperiors,
showFS, showFS,
qrCodeItems, qrCodeItems,
visibleEwm, visibleEwm,
qrCodeItemspg, qrCodeItemspg,
visibleEwmpg, visibleEwmpg,
setSuperiorsActive,
}; };
}, },
}; };
@@ -1230,7 +1340,70 @@ export default {
display: block; display: block;
clear: both; clear: both;
} }
.tabs {
margin: 10px 63px 10px 26px;
display: flex;
align-items: center;
}
.switch {
display: flex;
align-items: center;
margin-left: 20px;
}
.selectonlineface {
z-index: 999;
width: 679px;
background: #ffffff;
box-shadow: 0px 1px 35px 0px rgba(118, 136, 166, 0.21);
position: absolute;
left: 50%;
top: -100%;
transform: translate(-50%, -50%);
.bg_headers {
position: absolute;
width: 100%;
height: 40px;
background: linear-gradient(
180deg,
rgba(103, 64, 255, 0.2) 0%,
rgba(166, 168, 255, 0) 100%
);
}
.bg_main {
width: 100%;
position: relative;
.bg_main_header {
display: flex;
align-items: center;
padding-top: 20px;
padding-left: 26px;
font-size: 16px;
.bg_main_header_icon {
width: 16px;
height: 16px;
margin-right: 10px;
background-image: url(@/assets/images/evaluation/uploads.png);
background-size: 100% 100%;
}
.bg_main_header_close {
position: absolute;
right: 42px;
cursor: pointer;
width: 20px;
height: 20px;
background-image: url(@/assets/images/coursewareManage/close.png);
background-size: 100% 100%;
}
}
.bg_body {
width: 80%;
margin: 20px auto;
height: 600px;
overflow-y: auto;
}
}
}
.path-manage { .path-manage {
width: 100%; width: 100%;
height: 100%; height: 100%;
@@ -1295,6 +1468,7 @@ export default {
display: flex; display: flex;
align-items: center; align-items: center;
margin-right: 12px; margin-right: 12px;
cursor: pointer;
.img2 { .img2 {
width: 42px; width: 42px;
@@ -1927,6 +2101,7 @@ export default {
padding: 10px; padding: 10px;
width: 63px; width: 63px;
text-align: center; text-align: center;
cursor: pointer;
} }
.operations_dropdown { .operations_dropdown {
padding: 10px; padding: 10px;

View File

@@ -19,8 +19,8 @@ module.exports = defineConfig({
}, },
proxy: { proxy: {
// "/professional": { // "/professional": {
// target: 'http://192.168.150.97:32002', // target: 'http://192.168.143.97:32002',
// // target: 'http://192.168.237.141:32002', // // target: 'http://192.168.50.195:32002',
// changeOrigin: true, // changeOrigin: true,
// }, // },
"/growth": { "/growth": {