Merge branch 'master' of ssh://gitlab.dongwu-inc.com:10022/BOE/fe-manage

This commit is contained in:
Ggysh-7
2022-11-18 07:17:04 +08:00
22 changed files with 2829 additions and 1361 deletions

View File

@@ -2,7 +2,7 @@
* @Author: lixg lixg@dongwu-inc.com
* @Date: 2022-11-04 22:45:31
* @LastEditors: lixg lixg@dongwu-inc.com
* @LastEditTime: 2022-11-10 11:41:52
* @LastEditTime: 2022-11-17 15:41:45
* @FilePath: /fe-manage/src/api/index1.js
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
*/

View File

@@ -1,4 +1,14 @@
/*
* @Author: lixg lixg@dongwu-inc.com
* @Date: 2022-11-09 09:26:26
* @LastEditors: lixg lixg@dongwu-inc.com
* @LastEditTime: 2022-11-17 21:20:05
* @FilePath: /fe-manage/src/api/indexStage.js
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
*/
import http from "./config";
//添加阶段
export const editStage = (obj) => http.post('/admin/project/editStage', obj);
// 删除阶段
export const deleteStage = (obj) => http.delete('/admin/project/deleteStage',{params:obj});

View File

@@ -63,7 +63,9 @@ export const deleteVoteStemOption = (obj) => http.post('/vote/deleteVoteStemOpti
export const editVote = (obj) => http.post('/vote/editVote', obj)
//根据题干ID获取题干信息
export const queryStemByStemId = (obj) => http.post('/vote/queryStemByStemId', { params: obj })
export const queryStemByStemId = (obj) => http.post('/vote/queryStemByStemId', obj,{
headers: {'Content-Type': 'application/x-www-form-urlencoded;charset=UTF-8'}
})
//修改题干信息接口
export const updateStemMessage = (obj) => http.post('/vote/updateStemMessage', obj);

Binary file not shown.

After

Width:  |  Height:  |  Size: 410 B

View File

@@ -437,6 +437,17 @@ textarea {
}
}
.ant-modal{
.modalHeader{
background: linear-gradient(180deg, rgba(103,64,255,0.2) 0%, rgba(166,168,255,0) 100%) !important;
}
.top{
background: linear-gradient(180deg, rgba(103,64,255,0.2) 0%, rgba(166,168,255,0) 100%) !important;
}
.del_header{
background: linear-gradient(180deg, rgba(103,64,255,0.2) 0%, rgba(166,168,255,0) 100%) !important;
}
}
//弹窗--------------------------------------------------------
//loading--------------------------------------------------------

View File

@@ -273,6 +273,58 @@ export default {
},
];
}
if (
n.indexOf("/coursereviewed") !== -1 ||
n.indexOf("/CourseReiewed") !== -1
) {
state.list = [
{
name: "审核管理",
},
{
name: "已审核课程",
},
];
}
if (
n.indexOf("/coursereviewedn") !== -1 ||
n.indexOf("/CourseReiewedN") !== -1
) {
state.list = [
{
name: "审核管理",
},
{
name: "待审核课程",
},
];
}
if (
n.indexOf("/projectreviewed") !== -1 ||
n.indexOf("/ProjectReviewed") !== -1
) {
state.list = [
{
name: "审核管理",
},
{
name: "已审核项目",
},
];
}
if (
n.indexOf("/projectreviewedn") !== -1 ||
n.indexOf("/ProjectReviewedN") !== -1
) {
state.list = [
{
name: "审核管理",
},
{
name: "待审核项目",
},
];
}
}
);

View File

@@ -180,7 +180,7 @@
alt=""
/>
</div>
<span style="margin-right: 3px">培训体系</span>
<span style="margin-right: 3px">培训分类</span>
</div>
<div class="btnbox">
<a-input

View File

@@ -62,7 +62,7 @@
circle: selectedKeys[0] === 'sub10-3' ? false : true,
}"
></span>
<router-link to="/projecreviewedn">待审核项目</router-link>
<router-link to="/projectreviewedn">待审核项目</router-link>
</a-menu-item>
<a-menu-item key="sub10-4">
<span
@@ -71,7 +71,7 @@
circle: selectedKeys[0] === 'sub10-4' ? false : true,
}"
></span>
<router-link to="/projecreviewed">已审核项目</router-link>
<router-link to="/projectreviewed">已审核项目</router-link>
</a-menu-item>
</a-sub-menu>
@@ -307,13 +307,13 @@ export default {
pagename: "已审核课程",
},
{
href: "/projectviewedn",
href: "/projectreviewedn",
openKeys: "sub10",
selectedKeys: "sub10-3",
pagename: "待审核项目",
},
{
href: "/projectviewed",
href: "/projectrrviewed",
openKeys: "sub10",
selectedKeys: "sub10-4",
pagename: "已审核项目",

View File

@@ -56,6 +56,7 @@
>
创建投票
</button>
<a @click="queryStem">查看投票</a>
<div>
<CreateVote
v-model:createVoteVisible="createVoteVisible"
@@ -77,6 +78,13 @@
</div>
</div>
</div>
<!-- 查看投票弹窗 -->
<queryStem @closeDrawer="closeStem"
v-model:addStemVisible="addStemVisible" />
<!-- 创建投票侧弹窗 -->
<div>
<create-vote
@@ -142,12 +150,13 @@ import { message } from "ant-design-vue";
import { RouterEditTask } from "@/api/indexTask";
import dayjs from "dayjs";
import * as apiTask from "../../api/indexTaskadd";
import queryStem from "./queryStem.vue"
export default {
name: "AddVote",
components: {
CreateVote,
queryStem,
},
props: {
addvoteVisible: {
@@ -210,6 +219,7 @@ export default {
editStem: false, //编辑状态
ballotId: 0, //题干id
optionId: "", //删除修改选项id
addStemVisible:false, //
editChild:false,
});
const closeDrawer = () => {
@@ -362,6 +372,12 @@ export default {
}
}
const queryStem = () => {
state.addStemVisible = true;
};
const closeStem = () => {
state.addStemVisible = false;
};
return {
...toRefs(state),
showDrawerCreVote,
@@ -372,7 +388,8 @@ export default {
dleVoteStem,
updateVoteInfo,
delBox,
queryStem,
closeStem,
};
},
};

View File

@@ -0,0 +1,86 @@
<template>
<a-drawer :visible="addStemVisible"
placement="right" class="custom-class"
@after-visible-change="afterVisibleChange"
@close="closeDrawer" width="60%">
<div>
<h2 style="text-align:center;">投票查看</h2>
<div v-for="(item,index) in form" :key="item.voteStemId">
<div class="title">{{index+1}}. {{item.voteStemName}}</div>
<a-radio-group v-model:value="item.voteStemId">
<a-radio :value="3" :style="radioStyle">
{{item.optionDetailList[0].optionName}}</a-radio>
<br />
<a-radio :value="2" :style="radioStyle">
{{item.optionDetailList[1].optionName}}</a-radio>
</a-radio-group>
</div>
</div>
</a-drawer>
</template>
<script>
import { reactive, toRefs,ref } from "vue";
import { message } from "ant-design-vue";
import * as api from "@/api/indexVote"
export default {
name: "queryStem",
props: {
addStemVisible:{
type: Boolean,
default: false,
}
},
setup(props,ctx) {
const value = ref(1);
const state = reactive({
form:[],
});
const radioStyle = reactive({
display: 'flex',
height: '30px',
lineHeight: '30px',
});
const afterVisibleChange = (bool) => {
if(bool === true) {
getStem()
}
}
const getStem = () => {
let obj = {
stemId:0,
ballotId:2,
}
api.queryStemByStemId(obj).then((res) => {
state.form = res.data.data
console.log(JSON.stringify(res.data)+'***');
message.success("投票获取成功");
console.log(res);
}).catch((err) => {
message.error("投票获取失败"+err);
console.log(err);
})
}
const closeDrawer = () => {
ctx.emit("closeDrawer")
}
return {
...toRefs(state),
afterVisibleChange,
closeDrawer,
radioStyle,
value
}
}
}
</script>
<style>
.title {
font-size: 17px;
}
</style>

View File

@@ -1,458 +1,40 @@
<!--
* @Author: lixg lixg@dongwu-inc.com
* @Date: 2022-11-09 09:26:26
* @LastEditors: lixg lixg@dongwu-inc.com
* @LastEditTime: 2022-11-17 16:27:22
* @FilePath: /fe-manage/src/views/courselibrary/CourseManage.vue
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
-->
<!-- 课件管理页面 -->
<template>
<div class="courseManage">
<!-- 搜索框及按钮 -->
<div class="filter">
<div class="filterItems">
<div class="select">
<a-select
v-model:value="projectName"
style="width: 270px"
placeholder="请输入项目名称"
:options="projectNameList"
@change="selectProjectName"
allowClear
showSearch
></a-select>
</div>
<div class="select">
<a-select
v-model:value="projectName"
style="width: 270px"
placeholder="请输入项目经理"
:options="projectNameList"
@change="selectProjectName"
allowClear
showSearch
></a-select>
</div>
<div class="select">
<a-select
v-model:value="projectName"
style="width: 270px"
placeholder="请选择状态"
:options="projectNameList"
@change="selectProjectName"
allowClear
showSearch
></a-select>
</div>
<div class="select">
<a-date-picker
v-model="selectTime"
type="date"
placeholder="创建时间"
style="width: 270px"
/>
</div>
</div>
<div class="btns">
<div class="btn btn1">
<div class="search"></div>
<div class="btnText">搜索</div>
</div>
<div class="btn btn2">
<div class="search"></div>
<div class="btnText">重置</div>
</div>
<div class="btn btn3">
<div class="search"></div>
<div class="btnText">创建项目</div>
</div>
</div>
</div>
<!-- 搜索框及按钮 -->
<!-- 表格 -->
<div class="tableBox">
<a-table
:columns="columns"
:data-source="tableData"
:loading="tableDataTotal === -1 ? true : false"
:scroll="{ x: 700, y: 800 }"
expandRowByClick="true"
@expand="expandTable"
:pagination="{
showSizeChanger: true,
showQuickJumper: true,
hideOnSinglePage: true,
pageSizeOptions: [],
pageSize: pageSize,
current: currentPage,
total: tableDataTotal,
onChange: (page, pageSize) => {
currentPage = page;
// console.log('page', page)
// 加翻页查找代码
// this.setState({
// currentPage: page,
// }, () => {
// this.getMilitaryDeployment()
// })
},
}"
/>
</div>
<!-- 表格 -->
<iframe
id="iframe"
style="width:100%l;height:100%"
src="https://u-pre.boe.com/pc/iframe/course/coursewares"
name="myframe"
></iframe>
</div>
</template>
<script>
import { reactive, toRefs, onMounted, ref } from "vue";
const columns = [
{
title: "项目名称",
dataIndex: "projectName",
key: "projectName",
width: 280,
// align: "center",
ellipsis: true,
// scopedSlots: { customRender: "action" }, //引入的插槽
// customRender: (text, record) => {
// console.log(text, record);
// return <span>{text.text}</span>;
// },
},
{
title: "项目经理",
dataIndex: "manager",
key: "manager",
width: 100,
align: "center",
},
{
title: "状态",
dataIndex: "state",
// width: "30%",
key: "state",
width: 100,
align: "center",
},
{
title: "创建人",
dataIndex: "creater",
// width: "30%",
key: "creater",
width: 100,
align: "center",
},
{
title: "创建时间",
dataIndex: "time",
key: "time",
width: 180,
align: "center",
},
{
title: "操作",
dataIndex: "opacation",
key: "opacation",
width: 300,
align: "center",
},
];
const rowSelection = ref({
checkStrictly: false,
onChange: (selectedRowKeys, selectedRows) => {
console.log(
`selectedRowKeys: ${selectedRowKeys}`,
"selectedRows: ",
selectedRows
);
},
onSelect: (record, selected, selectedRows) => {
console.log(record, selected, selectedRows);
},
onSelectAll: (selected, selectedRows, changeRows) => {
console.log(selected, selectedRows, changeRows);
},
});
import { reactive, toRefs, onMounted } from "vue";
export default {
name: "CourseManage",
setup() {
const state = reactive({
projectNameList: [
{
id: 1,
value: "项目一",
label: "项目一",
},
{
id: 2,
value: "项目二",
label: "项目二",
},
{
id: 3,
value: "项目三",
label: "项目三",
},
{
id: 4,
value: "项目四",
label: "项目四",
},
],
projectName: null,
selectTime: null,
tableData: [
{
key: 1,
projectName:
"管理者进阶1管理者进阶1管理者进阶1管理者进阶1管理者进阶1管理者进阶1管理者进阶1",
manager: "黄华 刘俊",
state: "草稿",
creater: "毛继禹",
time: "2022-07-20 14:00:03",
children: [
{
key: 5,
projectName: "管理者进阶5",
manager: "黄华 刘俊",
state: "草稿",
creater: "毛继禹",
time: "2022-07-20 14:00:03",
children: [
{
key: 7,
projectName:
"管理者进阶7管理者进阶7管理者进阶7管理者进阶7管理者进阶7管理者进阶7管理者进阶7",
manager: "黄华 刘俊",
state: "草稿",
creater: "毛继禹",
time: "2022-07-20 14:00:03",
},
{
key: 8,
projectName: "管理者进阶8",
manager: "黄华 刘俊",
state: "草稿",
creater: "毛继禹",
time: "2022-07-20 14:00:03",
},
],
},
{
key: 6,
projectName: "管理者进阶6",
manager: "黄华 刘俊",
state: "草稿",
creater: "毛继禹",
time: "2022-07-20 14:00:03",
},
],
},
{
key: 2,
projectName: "管理者进阶2",
manager: "黄华 刘俊",
state: "草稿",
creater: "毛继禹",
time: "2022-07-20 14:00:03",
},
{
key: 3,
projectName: "管理者进阶3",
manager: "黄华 刘俊",
state: "草稿",
creater: "毛继禹",
time: "2022-07-20 14:00:03",
hasChildren: true,
children: [
{
key: 35,
projectName: "管理者进阶35",
manager: "黄华 刘俊",
state: "草稿",
creater: "毛继禹",
time: "2022-07-20 14:00:03",
children: [
{
key: 37,
projectName: "管理者进阶37",
manager: "黄华 刘俊",
state: "草稿",
creater: "毛继禹",
time: "2022-07-20 14:00:03",
},
{
key: 38,
projectName: "管理者进阶38",
manager: "黄华 刘俊",
state: "草稿",
creater: "毛继禹",
time: "2022-07-20 14:00:03",
},
],
},
{
key: 36,
projectName: "管理者进阶36",
manager: "黄华 刘俊",
state: "草稿",
creater: "毛继禹",
time: "2022-07-20 14:00:03",
},
],
},
{
key: 4,
projectName: "管理者进阶4",
manager: "黄华 刘俊",
state: "草稿",
creater: "毛继禹",
time: "2022-07-20 14:00:03",
},
{
key: 4,
projectName: "管理者进阶5",
manager: "黄华 刘俊",
state: "草稿",
creater: "毛继禹",
time: "2022-07-20 14:00:03",
},
{
key: 4,
projectName: "管理者进阶",
manager: "黄华 刘俊",
state: "草稿",
creater: "毛继禹",
time: "2022-07-20 14:00:03",
},
{
key: 4,
projectName: "管理者进阶",
manager: "黄华 刘俊",
state: "草稿",
creater: "毛继禹",
time: "2022-07-20 14:00:03",
},
{
key: 4,
projectName: "管理者进阶",
manager: "黄华 刘俊",
state: "草稿",
creater: "毛继禹",
time: "2022-07-20 14:00:03",
},
{
key: 4,
projectName: "管理者进阶",
manager: "黄华 刘俊",
state: "草稿",
creater: "毛继禹",
time: "2022-07-20 14:00:03",
},
{
key: 4,
projectName: "管理者进阶",
manager: "黄华 刘俊",
state: "草稿",
creater: "毛继禹",
time: "2022-07-20 14:00:03",
},
{
key: 4,
projectName: "管理者进阶",
manager: "黄华 刘俊",
state: "草稿",
creater: "毛继禹",
time: "2022-07-20 14:00:03",
},
{
key: 4,
projectName: "管理者进阶",
manager: "黄华 刘俊",
state: "草稿",
creater: "毛继禹",
time: "2022-07-20 14:00:03",
},
{
key: 4,
projectName: "管理者进阶",
manager: "黄华 刘俊",
state: "草稿",
creater: "毛继禹",
time: "2022-07-20 14:00:03",
},
{
key: 4,
projectName: "管理者进阶",
manager: "黄华 刘俊",
state: "草稿",
creater: "毛继禹",
time: "2022-07-20 14:00:03",
},
{
key: 4,
projectName: "管理者进阶",
manager: "黄华 刘俊",
state: "草稿",
creater: "毛继禹",
time: "2022-07-20 14:00:03",
},
{
key: 4,
projectName: "管理者进阶",
manager: "黄华 刘俊",
state: "草稿",
creater: "毛继禹",
time: "2022-07-20 14:00:03",
},
{
key: 4,
projectName: "管理者进阶",
manager: "黄华 刘俊",
state: "草稿",
creater: "毛继禹",
time: "2022-07-20 14:00:03",
},
{
key: 4,
projectName: "管理者进阶",
manager: "黄华 刘俊",
state: "草稿",
creater: "毛继禹",
time: "2022-07-20 14:00:03",
},
{
key: 4,
projectName: "管理者进阶",
manager: "黄华 刘俊",
state: "草稿",
creater: "毛继禹",
time: "2022-07-20 14:00:03",
},
{
key: 4,
projectName: "管理者进阶",
manager: "黄华 刘俊",
state: "草稿",
creater: "毛继禹",
time: "2022-07-20 14:00:03",
},
],
currentPage: 1,
tableDataTotal: 20,
pageSize: 10,
});
onMounted(() => {
// console.log("执行");
});
const selectProjectName = (value, index) => {
console.log("value", value, index);
};
const expandTable = (e, a) => {
console.log("惦记了");
console.log("e", e, a);
};
return {
...toRefs(state),
columns,
rowSelection,
selectProjectName,
expandTable,
};
},
};
@@ -463,99 +45,6 @@ export default {
height: 100%;
display: flex;
flex-direction: column;
.filter {
margin-left: 38px;
margin-right: 38px;
margin-top: 30px;
display: flex;
justify-content: space-between;
flex-wrap: wrap;
.filterItems {
display: flex;
flex-wrap: wrap;
.select {
margin-right: 20px;
margin-bottom: 20px;
}
}
.btns {
display: flex;
// flex-wrap: wrap;
.btn {
padding: 0px 26px 0px 26px;
height: 38px;
background: rgba(64, 158, 255, 0);
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;
.search {
background-size: 100%;
}
.btnText {
font-size: 14px;
font-weight: 400;
color: rgba(64, 158, 255, 1);
line-height: 36px;
margin-left: 5px;
}
}
.btn1 {
.search {
width: 15px;
height: 17px;
background-image: url("../../assets/images/courseManage/search1.png");
}
}
.btn2 {
.search {
width: 16px;
height: 18px;
background-image: url("../../assets/images/courseManage/reset1.png");
}
}
.btn3 {
margin-right: 0px;
.search {
width: 17px;
height: 18px;
background-image: url("../../assets/images/courseManage/add1.png");
}
}
.btn1:hover {
background: rgba(64, 158, 255, 1);
.search {
background-image: url("../../assets/images/courseManage/search0.png");
}
.btnText {
color: #ffffff;
}
}
.btn2:hover {
background: rgba(64, 158, 255, 1);
.search {
background-image: url("../../assets/images/courseManage/reset0.png");
}
.btnText {
color: #ffffff;
}
}
.btn3:hover {
background: rgba(64, 158, 255, 1);
.search {
background-image: url("../../assets/images/courseManage/add0.png");
}
.btnText {
color: #ffffff;
}
}
}
}
.tableBox {
margin: 20px 38px 30px;
}
}
</style>

View File

@@ -458,7 +458,7 @@
alt=""
/>
</div>
<span style="margin-right: 14px">内容分类</span>
<span style="margin-right: 14px">课程分类</span>
</div>
<div class="item_inp">
<div class="select i6_input">
@@ -1738,7 +1738,7 @@ const columns1 = [
},
},
{
title: "内容分类",
title: "课程分类",
width: 130,
dataIndex: "content",
key: "1",
@@ -3438,10 +3438,6 @@ courseownervisible:false,
},
]);
const options2 = ref([
{
value: "value2",
label: "请选择内容分类",
},
{
value: "leadership",
label: "领导力",

View File

@@ -98,10 +98,12 @@
<div class="taskmain">快速创建项目详情</div>
</div>
<div class="second">
<router-link :to="{ path: '/leveladddetail' }">
<div
class="taskbox"
style="background: linear-gradient(180deg, #fef3dd, #fffaf0)"
>
<div class="leftt">
<img src="../../assets/images/taskpage/left1.png" />
</div>
@@ -116,8 +118,9 @@
</div>
<div class="centermain">快速添加任务/关卡</div>
</div>
</router-link>
<div
class="taskbox"
class="taskbox" @click="showAddStu"
style="background: linear-gradient(180deg, #ddeaff, #f0f8fe)"
>
<div class="leftt">
@@ -129,7 +132,9 @@
<div class="rightt">
<img src="../../assets/images/taskpage/right2.png" />
</div>
<div class="centerbox" style="color: rgba(78, 166, 255, 1)">
<div class="centerbox"
style="color: rgba(78, 166, 255, 1)">
添加学员
</div>
<div class="centermain">快速添加学员</div>
@@ -155,7 +160,6 @@
</div>
</div>
</div>
<!-- 概览无数据 -->
<!-- 概览有数据 -->
<div :style="{ display: nodata ? 'none' : 'block' }">
<div class="onerow"><div class="taskmain">关卡概览</div></div>
@@ -215,16 +219,16 @@
stage2: item.stageId != choosedStageId,
}"
:key="item.stageId"
@click="choosedStageId = item.stageId"
@click="stageChange(item.name,item.stageId)"
>
{{ item.stage }}
关卡{{ item.stageId }}
</div>
<!-- <div class="stage1">阶段1</div>
<div class="stage2">阶段2</div> -->
</div>
<div class="stagesecond">
<div class="staname">关卡名称</div>
<div class="stamess">管理者进阶-腾飞班1第一关卡</div>
<div class="stamess">{{stateName}}</div>
</div>
<div class="stagelast">
<div class="stagepro">
@@ -578,8 +582,8 @@
<a-select
style="width: 130px"
value="更多操作"
:options="projectNameListt"
@change="selectProjectName"
@change="handleStuChange"
:options="projectNameList"
></a-select>
</div>
</div>
@@ -588,11 +592,11 @@
<div class="xu">
<span class="yi">已选择</span>
<div style="width: 5px; display: inline-block"></div>
<span class="th">3</span>
<span class="th">{{selectedRowKeys.length}}</span>
<div style="width: 5px; display: inline-block"></div>
<span class="yi"></span>
<span class="zon">列表选项总数</span>
<span class="yi">5</span>
<span class="th">{{tableData.length}}</span>
<span class="yi"> </span>
</div>
</div>
@@ -1202,6 +1206,7 @@ export default {
CheckStuvisible: false, //学员管理的查看抽屉
addLoading: false, // 加载动画
choosedStageId: 1, // 选择的阶段id
selectedRowKeys:[],
twobtn: true,
number: true,
twobtnn: false,
@@ -1213,6 +1218,20 @@ export default {
styTitle: null,
cretime: null,
picUrl: null,
projectNameList:[
{
value: '1',
label: '导出信息',
},
{
value: '2',
label: '批量调整关卡',
},
{
value: '3',
label: '批量删除',
}
],
// 共享文档列表
docList: [
{
@@ -1261,7 +1280,7 @@ export default {
pageSize: 10,
visiblene: false,
sh: false,
nodata: false,
nodata: true,
closeDeleteAll: false,
curLevel: "",
taskSyllabusActive: 0,
@@ -1278,6 +1297,7 @@ export default {
visible: false, //时间管理
TMvisible: false, //考试管理
FaceVisivle: false, //面授管理
stateName:null, // 关卡名称
//关卡的数据
level: [
// {
@@ -1329,11 +1349,11 @@ export default {
// 阶段列表
{
stageId: 1,
stage: "关卡一",
name: "关卡一xx",
},
{
stageId: 2,
stage: "关卡二",
name: "关卡二xx",
},
],
});
@@ -1541,7 +1561,10 @@ export default {
const closehuodModal = () => {
state.huodModal = false;
};
const stageChange = (name,id) => {
state.choosedStageId = id;
state.stateName = name;
}
const changeTabs = (e) => {
console.log("切换tabs", e, state.routerId);
if (e == 2) {
@@ -1566,12 +1589,12 @@ export default {
.then((res) => {
console.log("获取学员列表", res);
let data = res.data.data.rows || null;
state.tableData = [];
// state.tableData = [];
if (data.length) {
for (let i in data) {
let _time = new Date(data[i].beginStudyTime * 1000);
state.tableData.push({
key: i + 1,
key: data[i].studentId,
com: data[i].userInfoBo.deptName,
name: data[i].userInfoBo.userName,
gang: data[i].userInfoBo.jobName,
@@ -1619,6 +1642,7 @@ export default {
onMounted(() => {
state.addLoading = true;
getOverview();
myGetRouterDetail();
reget();
});
const closePub = () => {
@@ -1806,8 +1830,10 @@ export default {
const myGetRouterDetail = () => {
GetRouterDetail(state.routerId)
.then((res) => {
if(res.data.data.routerInfo.status == 1) {
state.nodata = false;
}
let data = res.data.data.chapterList;
state.taskSyllabus = data;
// for(let i in data) {
// state.taskSyllabus[i].name = data[i].name
@@ -1818,8 +1844,13 @@ export default {
// })
// }
// }
// }
levelList.stageList = [];
for(let i in data) {
if(i==0) {state.stateName = data[0].name}
levelList.stageList.push({
stageId:Number(i)+1,
name:data[i].name
}) }
})
.catch((err) => {
console.log(err);
@@ -1868,6 +1899,27 @@ export default {
state.gatenamee = '';
getStudent();
};
const handleStuChange = (value) => {
console.log(value);
if(value == 2) {state.visiblene = true}
if(value == 3 ) { deleteStu() }
};
const deleteStu = () => {
if(state.selectedRowKeys.length == 0) {
message.warning("请选择成员");
return }
let obj = {
routerId:100,
studentIds:state.selectedRowKeys,
}
api.delStudent(obj).then((res) => {
console.log(res);
message.success("批量删除成功")
}).catch(err => {
message.error("批量删除失败"+err);
console.log(err)
})
};
return {
...toRefs(state),
...toRefs(levelList),
@@ -1897,6 +1949,7 @@ export default {
changeTabs,
checkType,
handleChange,
handleStuChange,
delConfirm,
searchLevel,
resetLevel,
@@ -1913,6 +1966,7 @@ export default {
stopLearnPath,
showStop,
reget,
stageChange,
};
},
};

View File

@@ -5,7 +5,7 @@
<div class="tit" style="margin-left: 18px">关卡</div>
<div class="btn btn3" style="margin-left: 19px">
<div class="search"></div>
<div class="btnText" @click="showModal">添加关卡</div>
<div class="btnText" @click="showModal()">添加关卡</div>
</div>
<div class="maincon" style="background-color: #fff">
<!-- <div
@@ -15,7 +15,6 @@
v-for="item in level"
:key="item.id"
> -->
<draggable
v-model="level"
chosenClass="chosen"
@@ -47,13 +46,12 @@
>
</div>
</a-popover>
<div class="imgIcon"></div>
<div class="imgIcon" @click="showModal(element)"></div>
</div>
<div class="boxs_right">
<div
class="imgIcon"
@click="deleteChapter(element.chapterId)"
@click="showDeleteChapter(element.chapterId)"
></div>
</div>
</div>
@@ -82,7 +80,6 @@
</div>
</template>
</draggable>
<!-- <div
class="items"
:class="isactive == index ? 'active' : ''"
@@ -114,10 +111,11 @@
:footer="null"
:closable="clos"
wrapClassName="AddLevell"
@cancel="closeModal"
>
<div class="header">
<div class="headmain">
<div class="add">添加关卡</div>
<div class="add">编辑/添加关卡</div>
<div class="img" style="cursor: pointer" @click="closeModal"></div>
</div>
</div>
@@ -853,7 +851,6 @@
<!-- 导入学员抽屉 -->
<imp-stu v-model:AddImpStuvisible="AddImpStuvisible" />
<!-- 添加讨论侧弹窗 -->
<!-- 添加活动侧弹窗 -->
<!-- 批量删除学员弹窗 -->
<a-modal
@@ -885,7 +882,6 @@
</div>
</div>
</a-modal>
<!-- 是否确认删除任务弹窗 -->
<!-- 确认删除阶段弹窗 -->
<a-modal
@@ -917,7 +913,6 @@
</div>
</div>
</a-modal>
<!-- 移动任务到阶段 -->
<a-modal
style="padding: 0"
@@ -968,9 +963,39 @@
</div>
</div></a-modal
>
<!-- 是否删除关卡弹窗 -->
<a-modal
v-model:visible="deleteChapterModal"
:footer="null"
:closable="cC"
wrapClassName="ConfirmModal"
centered="true"
>
<div class="delete">
<div class="del_header"></div>
<div class="del_main">
<div class="header">
<div class="icon"></div>
<span>提示</span>
<div class="close_exit" @click="closeDeleteChapter"></div>
</div>
<div class="body">
<span>您确定要删除此关卡</span>
</div>
<div class="del_btnbox">
<div class="del_btn btn1" @click="closeDeleteChapter">
<div class="btnText" >取消</div>
</div>
<div class="del_btn btn2" @click="deleteChapter">
<div class="btnText" >确定</div>
</div>
</div>
</div>
</div>
</a-modal>
</div>
</template>
<script>
import { reactive, toRefs, onMounted, onUnmounted } from "vue";
import AddStu from "../../components/drawers/AddLevelAddStu";
@@ -1027,7 +1052,6 @@ export default {
name: "默认关卡",
},
],
tableData: [
{
key: 1,
@@ -1154,7 +1178,6 @@ export default {
// key: "2-1",
// projectName: "管理者进阶-腾飞班",
// manager: "黄华 刘俊",
// creater: "毛继禹",
// time: "2022-07-20 14:00:03",
// children: [
@@ -1169,12 +1192,10 @@ export default {
// },
// ],
// },
// {
// key: 3,
// projectName: "管理者进阶-腾飞班K1",
// manager: "黄华 刘俊",
// creater: "毛继禹",
// time: "2022-07-20 14:00:03",
// },
@@ -1182,7 +1203,6 @@ export default {
// key: 4,
// projectName: "管理者进阶-腾飞班K1",
// manager: "黄华 刘俊",
// creater: "毛继禹",
// time: "2022-07-20 14:00:03",
// },
@@ -1190,7 +1210,6 @@ export default {
// key: 5,
// projectName: "管理者进阶-腾飞班K1",
// manager: "黄华 刘俊",
// creater: "毛继禹",
// time: "2022-07-20 14:00:03",
// },
@@ -1198,7 +1217,6 @@ export default {
// key: 6,
// projectName: "管理者进阶-腾飞班K1",
// manager: "黄华 刘俊",
// creater: "毛继禹",
// time: "2022-07-20 14:00:03",
// },
@@ -1206,7 +1224,6 @@ export default {
// key: 7,
// projectName: "管理者进阶-腾飞班K1",
// manager: "黄华 刘俊",
// creater: "毛继禹",
// time: "2022-07-20 14:00:03",
// },
@@ -1282,11 +1299,50 @@ export default {
projectTaskId: null,
chooseStageId: null,
chooseChapterId: null,
updateChapterID: null, //编辑关卡id
deleteChapterModal:false,//删除关卡弹窗
deleteChapterId:null,//删除关卡id
});
const showModal = (element) => {
state.modal = true;
console.log("element", element);
if (element) {
console.log("element", element);
state.value1 = element.name;
state.value2 = element.remark;
state.updateChapterID = element.chapterId;
}
};
const closeModal = () => {
state.modal = false;
state.value1 = "";
state.value2 = "";
state.updateChapterID = null;
};
//新建关卡
const editChapter = () => {
if (!state.value1) return message.warning("请输入关卡名称");
if (state.updateChapterID) {
let obj = {
name: state.value1,
remark: state.value2,
routerId: state.routerId,
chapterId:state.updateChapterID
};
api
.updateChapter(obj)
.then((res) => {
console.log("修改成功", res);
message.success("修改成功");
getDetail();
closeModal();
})
.catch((err) => {
console.log("修改失败", err);
});
} else {
let obj = {
name: state.value1,
remark: state.value2,
@@ -1295,8 +1351,11 @@ export default {
api
.editChapter(obj)
.then((res) => {
setTimeout(() => {
console.log("创建成功", res);
// setTimeout(() => {
// console.log("创建成功", res);
// }, 1000);
message.success("创建成功");
state.value1 = "";
state.value2 = "";
@@ -1304,31 +1363,43 @@ export default {
// state.createLoading = false;
//state.currentPage = 1;
// getLearnPath();
}, 1000);
getDetail();
closeModal();
})
.catch((err) => {
console.log("创建失败", err);
});
}
};
//打开删除关卡弹窗
const showDeleteChapter=(id)=>{
state.deleteChapterId=id
state.deleteChapterModal=true
}
//关闭删除关卡弹窗
const closeDeleteChapter=()=>{
state.deleteChapterId=null
state.deleteChapterModal=false
}
//删除关卡
const deleteChapter = () => {
console.log("chapterId", state.deleteChapterId);
let obj = {
chapterId: state.deleteChapterId,
};
api
.deleteChapter(obj)
.then((res) => {
console.log("删除关卡成功", res);
message.success('删除关卡成功')
closeDeleteChapter()
getDetail();
})
.catch((err) => {
console.log("删除关卡失败", err);
});
};
//编辑关卡
// const updateChapter = () => {
// let obj = {
// chapterId: state.updateChapterID,
// name: "",
// remark:"",
// routerId: 0,
// };
// api
// .updateChapter(obj)
// .then((res) => {
// console.log("修改成功",res);
// message.success("修改成功");
// })
// .catch((err) => {
// console.log("修改失败",err);
// })
// };
const showDrawer = () => {
state.visible = true;
};
@@ -1389,7 +1460,6 @@ export default {
state.EditRefId = id;
state.routerTaskId = eleId;
};
const showDrawerAddDiscuss = (id, eleId) => {
state.adddiscussvisible = true;
state.EditDiscussId = id;
@@ -1406,7 +1476,6 @@ export default {
state.EditActiveId = id;
state.routerTaskId = eleId;
};
// tableData数据赋值方法
const dataAssignment = (id) => {
console.log(state.level);
@@ -1451,7 +1520,6 @@ export default {
"Y-M-D h:m"
);
state.picUrl = res.data.data.routerInfo.picUrl;
//增加两个字段
state.level.forEach((item) => {
item["value"] = item.chapterId;
@@ -1476,14 +1544,8 @@ export default {
const closeDrawer = () => {
state.visible = false;
};
const showModal = () => {
state.modal = true;
};
const closeModal = () => {
state.modal = false;
state.value1 = "";
state.value2 = "";
};
const afterVisibleChange = (bool) => {
console.log("visible", bool);
};
@@ -1493,7 +1555,6 @@ export default {
const showImpStu = () => {
state.AddImpStuvisible = true;
};
const checkType = (index) => {
let typeRules = [
"",
@@ -1594,12 +1655,10 @@ export default {
];
return columns;
};
const onSelectChange = (selectedRowKeys) => {
console.log("selectedRowKeys changed: ", selectedRowKeys);
state.selectedRowKeys = selectedRowKeys;
};
const drawertableColumns = () => {
const drawercolumns = [
{
@@ -1645,7 +1704,6 @@ export default {
width: 100,
align: "center",
},
{
title: "创建人",
dataIndex: "creator",
@@ -1672,7 +1730,6 @@ export default {
// 40 +
// "px";
// };
onMounted(() => {
document.getElementsByTagName("main")[0].style.background =
"rgb(245, 247, 250,1)";
@@ -1725,7 +1782,6 @@ export default {
console.log(err);
});
};
const closeDeleteModel = () => {
state.deleteModal = false;
state.deleteID = "";
@@ -1735,7 +1791,6 @@ export default {
state.editID = "";
getDetail();
};
//选择单个任务
const changeRow = (e) => {
//selectRow:已经选择的任务的id数组
@@ -1837,7 +1892,6 @@ export default {
state.visiblene = false;
}
};
//编辑的按钮
const decideType = (type, id, eleId) => {
state.edit = true;
@@ -1868,21 +1922,6 @@ export default {
showDrawerAddCase(id, eleId);
}
};
//删除关卡
const deleteChapter = (chapterId) => {
console.log("chapterId", chapterId);
let obj = {
chapterId: chapterId,
};
api
.deleteChapter(obj)
.then((res) => {
console.log("删除关卡成功", res);
})
.catch((err) => {
console.log("删除关卡失败", err);
});
};
const changeCourseType = (ele) => {
console.log("任务id", ele.id);
@@ -1924,7 +1963,6 @@ export default {
console.log("阶段改变", value, option);
state.removeStageId = option.chapterId;
};
//项目抽屉用的
const rowSelection = {
onSelect: (selectedRows, selected, selectedRowKeys) => {
@@ -2051,7 +2089,6 @@ export default {
showDeleteModal,
decideType,
updateTableData,
deleteChapter,
changeCourseType,
showChangeModal,
closeChangeModal,
@@ -2060,11 +2097,15 @@ export default {
getTableDate,
getAllProjText,
updateTask,
showDeleteChapter,
closeDeleteChapter,
deleteChapter,
};
},
};
</script>
<style lang="scss">
.ConfirmModal {
.ant-modal {
@@ -2147,7 +2188,6 @@ export default {
display: flex;
align-items: center;
justify-content: center;
flex-shrink: 0;
cursor: pointer;
.btnText {
@@ -2186,14 +2226,12 @@ export default {
.con {
width: 100%;
height: 100%;
.header {
width: 100%;
display: flex;
height: 68px;
position: relative;
justify-content: center;
background: linear-gradient(
rgba(78, 166, 255, 0.2) 0%,
rgba(78, 166, 255, 0) 100%
@@ -2250,7 +2288,6 @@ export default {
width: 100px;
height: 40px;
font-size: 14px;
border-radius: 8px;
}
.btn1 {
@@ -2290,7 +2327,6 @@ export default {
width: 100% !important;
height: 100% !important;
padding: 0 !important;
.header {
width: 624px;
height: 68px;
@@ -2364,7 +2400,6 @@ export default {
position: absolute;
right: 10px;
top: 4px;
font-size: 14px;
font-weight: 400;
color: #c7cbd2;
@@ -2373,7 +2408,6 @@ export default {
position: absolute;
right: 10px;
bottom: 8px;
font-size: 14px;
font-weight: 400;
color: #c7cbd2;
@@ -2438,7 +2472,6 @@ export default {
th {
background-color: #eff4fc !important;
}
.ant-table-tbody
> tr:hover:not(.ant-table-expanded-row):not(.ant-table-row-selected)
> td {
@@ -2518,7 +2551,6 @@ export default {
margin-left: 5px;
}
}
.btn3 {
width: 171px;
margin-right: 0px;
@@ -2535,7 +2567,6 @@ export default {
display: flex;
flex-direction: column;
align-items: center;
.ghost {
// background-color: red;
opacity: 0 !important;
@@ -2574,7 +2605,7 @@ export default {
.imgIcon {
width: 16px;
height: 16px;
background-image: url(@/assets/images/leveladd/edit.png);
background-image: url(@/assets/images/leveladd/edit1.png);
background-size: 100% 100%;
}
}
@@ -2594,7 +2625,6 @@ export default {
// text-overflow: ellipsis;
// white-space: nowrap;
font-weight: bold;
overflow: hidden;
text-overflow: ellipsis;
-webkit-line-clamp: 2;
@@ -2660,7 +2690,6 @@ export default {
}
}
}
.rightt {
height: 100%;
display: flex;
@@ -2717,7 +2746,6 @@ export default {
}
}
}
.mid {
width: 100%;
// height: 130px;
@@ -2856,7 +2884,6 @@ export default {
th.h {
background-color: #eff4fc !important;
}
.ant-table-tbody
> tr:hover:not(.ant-table-expanded-row):not(.ant-table-row-selected)
> td {
@@ -2961,7 +2988,6 @@ export default {
th.h {
background-color: #eff4fc !important;
}
.ant-table-tbody
> tr:hover:not(.ant-table-expanded-row):not(.ant-table-row-selected)
> td {
@@ -3237,7 +3263,6 @@ export default {
}
}
}
.opat {
.opacationt {
display: flex;
@@ -3383,7 +3408,6 @@ export default {
display: flex;
align-items: center;
justify-content: center;
flex-shrink: 0;
cursor: pointer;
.btnText {

View File

@@ -261,7 +261,7 @@
class="nameimg"
src="../../assets/images/basicinfo/asterisk.png"
/>
<div class="inname">培训体系</div>
<div class="inname">培训分类</div>
</div>
<div class="in select">
<a-select
@@ -675,7 +675,7 @@ export default {
levels = key;
};
// 培训体系
// 培训分类
const classifyList4 = ref([
{ value: 1, label: "集团级" },
{ value: 2, label: "组织级" },
@@ -748,7 +748,7 @@ export default {
managerId: "请选择项目经理",
sourceBelongId: "请选择资源归属",
level: "请填写项目级别",
systemId: "请填写项目培训体系",
systemId: "请填写项目培训分类",
boeFlag: "请选择是否BOE实施",
};

View File

@@ -200,7 +200,7 @@
: 'none',
}"
>
考勤
<!-- 考勤 -->
</div>
<div
class="operation"
@@ -214,7 +214,7 @@
: 'none',
}"
>
二维码
<!-- 二维码 -->
</div>
<div
class="operation"
@@ -238,7 +238,7 @@
: null
"
>
管理
<!-- 管理 -->
</div>
</div>
</div>
@@ -388,7 +388,7 @@
<div class="setting">
<div class="set_tit">
<span>基本信息</span>
<span class="editBtn" @click="() => {isEdit=true}">编辑</span>
<span class="editBtn" @click="toEdit">编辑</span>
</div>
<hr color="#E8E8E8" />
<div class="set_body">
@@ -478,11 +478,11 @@
</div>
</div>
<div class="set_content">
<div class="setc_name"><span>培训体系</span></div>
<div class="setc_name"><span>培训分类</span></div>
<div class="setc_main">
<a-select
v-model:value="formData.systemId"
placeholder="请选择培训体系"
placeholder="请选择培训分类"
:size="large" :bordered="isEdit" :disabled="!isEdit"
style="width: 200px;color: #999999;" :options="systemOptions"
></a-select>
@@ -593,6 +593,7 @@
import { ref, reactive, defineComponent, toRefs, onMounted} from "vue";
import { message } from "ant-design-vue";
import * as api from "@/api/indexTemplate"
import { useRouter } from "vue-router";
export default defineComponent({
name: "LibraryAdd",
setup() {
@@ -790,6 +791,7 @@ export default defineComponent({
const value = ref("");
const value2 = ref("");
const textnum = "150";
const routered = useRouter();
const changeopclo = () => {
state.hideshow = !state.hideshow;
};
@@ -907,7 +909,15 @@ export default defineComponent({
console.log(err)
})
}
const toEdit = () => {
routered.push({
path: "/templateAdd",
query: {
projectId: state.projectId,
name: state.name,
},
});
}
// 新建或编辑阶段
const stateEdit = () => {
let obj={
@@ -959,6 +969,7 @@ export default defineComponent({
taskDel,
stateEdit,
taskEdit,
toEdit,
};
},
computed: {

View File

@@ -247,7 +247,7 @@
class="nameimg"
src="../../assets/images/basicinfo/asterisk.png"
/>
<div class="inname">培训体系</div>
<div class="inname">培训分类</div>
</div>
<div class="in select">
<a-select
@@ -359,7 +359,7 @@
</div>
</template>
<script>
import { reactive, toRefs, ref } from "vue";
import { reactive, toRefs, ref, onUnmounted } from "vue";
import { message } from "ant-design-vue";
import { useRouter, useRoute } from "vue-router";
import dayjs from "dayjs";
@@ -716,7 +716,7 @@ export default {
levels = key;
};
// 培训体系
// 培训分类
const classifyList4 = ref([
{ value: 1, label: "集团级" },
{ value: 2, label: "组织级" },
@@ -1021,6 +1021,9 @@ export default {
}
};
onUnmounted(() => {
storage.remove("projectAddId");
});
return {
...toRefs(state),
projectName,

View File

@@ -1024,6 +1024,35 @@
</div>
</div>
</a-modal>
<!-- 创建项目提示框 -->
<a-modal
v-model:visible="reminderModal"
:footer="null"
:closable="closeBack"
wrapClassName="CopyModal"
centered="true"
>
<div class="delete">
<div class="del_header"></div>
<div class="del_main">
<div class="header">
<div class="icon"></div>
<span>温馨提示</span>
<div class="close_exit" @click="closeReminderModal"></div>
</div>
<div class="body">
<div style="margin-left:60px;margin-right:60px">请您根据自身需求选择对应项目类别多层项目与单层项目操作不同层级不同</div>
</div>
<div class="del_btnbox">
<div class="del_btn btn2" @click="okReminderModal">
<div class="btnText">好的</div>
</div>
</div>
</div>
</div>
</a-modal>
<!-- 归属权抽屉 -->
<proj-owner-ship v-model:ProjOwnervisible="ProjOwnervisible" />
<!-- 授权名单抽屉 -->
@@ -1032,6 +1061,9 @@
<proj-check-ship v-model:ProjCheckvisible="ProjCheckvisible" />
<!-- 管理权抽屉 -->
<proj-manage-ship v-model:ProjManagevisible="ProjManagevisible" />
</div>
</template>
<script>
@@ -1069,6 +1101,7 @@ export default {
projectPub: false, //发布弹窗
backModal: false, //撤回弹窗
closeBack: false, //撤回弹窗关闭图标
reminderModal:false,//温馨提示弹窗
ProjOwnervisible: false,
ProjPvisible: false,
ProjCheckvisible: false,
@@ -3038,7 +3071,8 @@ export default {
};
const showModal1 = () => {
state.estabish = true;
state.reminderModal=true
};
const closeModal1 = () => {
state.estabish = false;
@@ -3067,6 +3101,14 @@ export default {
state.ProjManagevisible = true;
};
const closeReminderModal=()=>{
state.reminderModal=false
}
const okReminderModal=()=>{
state.reminderModal=false
state.estabish = true;
}
return {
...toRefs(state),
selectProjectName,
@@ -3168,6 +3210,8 @@ export default {
deleteProject,
templateProject,
copyProject,
closeReminderModal,
okReminderModal,
};
},
};

View File

@@ -154,7 +154,7 @@
<div class="name">
<div class="namebox">
<img class="nameimg" src="../../assets/images/basicinfo/asterisk.png" />
<div class="inname">培训体系</div>
<div class="inname">培训分类</div>
</div>
<div class="in select">
<a-select :getPopupContainer="
@@ -529,7 +529,7 @@ export default {
levels = key;
};
// 培训体系
// 培训分类
const classifyList4 = ref([
{ value: 1, label: "集团级" },
{ value: 2, label: "组织级" },
@@ -602,7 +602,7 @@ export default {
managerId: "请选择项目经理",
sourceBelongId: "请选择资源归属",
level: "请填写项目级别",
systemId: "请填写项目培训体系",
systemId: "请填写项目培训分类",
boeFlag: "请选择是否BOE实施"
};

View File

@@ -1,5 +1,6 @@
<template>
<div class="taskadd">
<div style="display: flex">
<div class="left clearfix">
<div class="leftmain">
<div class="tit">
@@ -10,11 +11,19 @@
/>
</div>
<!-- @click="showModal" -->
<div class="btn btn3" @click="showConfirm" style="margin-left: 19px">
<div class="btn btn3" @click="showModal()" style="margin-left: 19px">
<div class="search"></div>
<div class="btnText">添加阶段</div>
</div>
<div class="maincon" style="background-color: #fff">
<!-- <div
class="items"
:class="{ active: isActive == true }"
@click="changebgc"
v-for="item in level"
:key="item.id"
> -->
<draggable
v-model="level"
chosenClass="chosen"
@@ -22,29 +31,91 @@
forceFallback="true"
group="stage"
animation="500"
@start="onStart"
@end="onEnd"
>
<template #item="{ element }">
<div
class="item"
:class="chooseStageId == element.id ? 'bgcactive' : ''"
class="items"
:class="chooseStageId == element.id ? 'active' : ''"
@click="changebgc(element.id)"
>
<div class="itemle">
<div class="tit">{{ element.tit }}</div>
<div class="name">{{ element.name }}</div>
<div class="items1">
<div class="boxs_left">
<a-popover placement="topLeft" trigger="click">
<template #content>
<div style="width: 130px">
{{ element.name ? element.name : "暂无说明" }}
</div>
<div class="itemri">
<img src="../../assets/images/leveladd/z1.png" />
<img
style="margin-top: 40px"
src="../../assets/images/leveladd/z2.png"
/>
</template>
<template #title>
<span>阶段说明</span>
</template>
<div class="script">
<span style="font-size: 12px; color: #ffffff"
>说明</span
>
</div>
</a-popover>
<div class="imgIcon" @click="showModal(element)"></div>
</div>
<div class="boxs_right">
<div
class="imgIcon"
@click="showDeleteStage(element.id)"
></div>
</div>
</div>
<div class="items2">
<a-popover
placement="topLeft"
v-if="element.tit.length > 10"
>
<template #content>
<div style="width: 130px">
{{ element.tit }}
</div>
</template>
<!-- <template #title>
<span>关卡说明</span>
</template> -->
<div class="nname">
{{ element.tit }}
</div>
</a-popover>
<div class="nname" v-if="element.tit.length <= 10">
{{ element.tit }}
</div>
</div>
<!-- <div class="itemle">
<div class="tit">{{ item.remark }}</div>
<div class="name">{{ item.name }}</div>
</div> -->
</div>
</template>
</draggable>
<!-- <div
class="items"
:class="isactive == index ? 'active' : ''"
@click="changebgc(index)"
v-for="(item, index) in level"
:key="item.chapterId"
>
<div class="items1">
<div class="boxs_left">
<div class="script">
<span style="font-size: 12px; color: #ffffff">说明</span>
</div>
<div class="imgIcon"></div>
</div>
<div class="boxs_right">
<div class="imgIcon"></div>
</div>
</div>
<div class="items2">
<div class="nname">{{ item.name }}</div>
</div>
</div> -->
</div>
</div>
</div>
@@ -63,23 +134,24 @@
</div>
<div class="rightt">
<div class="select">
<a-select
v-model:value="projectName"
style="width: 200px"
placeholder="自由学习模式"
:options="projectNameList"
@change="selectProjectName"
allowClear
showSearch
></a-select>
<span>学习模式</span>
<div class="inputbox">
<input type="text" placeholder="按学习时间解锁" />
<div class="bottonbox">
<div class="btnText">切换模式</div>
</div>
</div>
</div>
<div class="line"></div>
<img class="img2" src="../../assets/images/projectadd/keep.png" />
<!-- <img class="img2" src="../../assets/images/projectadd/keep.png" />
<div class="pub">保存</div>
<div class="line"></div>
<div class="line"></div> -->
<router-link to="/taskpage">
<div style="display: flex">
<img class="img2" src="../../assets/images/leveladd/back.png" />
<img
class="img2"
src="../../assets/images/leveladd/back.png"
/>
<div class="return">返回</div>
</div>
</router-link>
@@ -364,7 +436,9 @@
<div class="boomcen">
<div class="onerow">
<div class="taskmain">任务列表</div>
<button class="btn" @click="showChangeModal">移动任务到阶段</button>
<button class="btn" @click="showChangeModal">
移动任务到阶段
</button>
<div class="edit" @click="showdeAll">
<img
class="editimg"
@@ -617,6 +691,23 @@
</div>
</div>
</div>
</div>
<div class="footbtn">
<div class="btnbox">
<div class="btn btn2">
<div class="btnText">暂存</div>
</div>
<div class="btn btn2">
<div class="btnText">确定</div>
</div>
<div class="btn btn1">
<div class="btnText">取消</div>
</div>
</div>
</div>
<!-- 添加阶段弹窗 -->
<div>
<a-modal
v-model:visible="stage"
@@ -628,6 +719,7 @@
width="624px"
height="388px"
centered="true"
@cancel="closeModal"
>
<div
class="modalHeader"
@@ -640,7 +732,9 @@
"
>
<div class="headerLeft" style="margin-left: 32px">
<span class="headerLeftText" style="font-size: 16px">添加阶段</span>
<span class="headerLeftText" style="font-size: 16px"
>编辑/添加阶段</span
>
</div>
<div style="cursor: pointer; margin-right: 32px" @click="closeModal">
<img
@@ -745,11 +839,11 @@
<span>您确定要添加阶段吗</span>
</div>
<div class="del_btnbox">
<div class="del_btn btn1">
<div class="btnText" @click="delete_exit">取消</div>
<div class="del_btn btn1" @click="closeConfirm">
<div class="btnText">取消</div>
</div>
<div class="del_btn btn2">
<div class="btnText" @click="showModal">确定</div>
<div class="del_btn btn2" @click="showModal">
<div class="btnText">确定</div>
</div>
</div>
</div>
@@ -894,6 +988,38 @@
</div>
</div></a-modal
>
<!-- 是否删除阶段弹窗 -->
<a-modal
v-model:visible="deleteStageModal"
:footer="null"
:closable="cC"
wrapClassName="ConfirmModal"
centered="true"
>
<div class="delete">
<div class="del_header"></div>
<div class="del_main">
<div class="header">
<div class="icon"></div>
<span>提示</span>
<div class="close_exit" @click="closeDeleteStage"></div>
</div>
<div class="body">
<span>您确定要删除此阶段</span>
</div>
<div class="del_btnbox">
<div class="del_btn btn1" @click="closeDeleteStage">
<div class="btnText" >取消</div>
</div>
<div class="del_btn btn2" @click="deleteStage">
<div class="btnText" >确定</div>
</div>
</div>
</div>
</div>
</a-modal>
</div>
</template>
@@ -1161,6 +1287,10 @@ export default {
selectRow: [], //选择行
curLevel: [], //阶段名称
selectAll: 0, //0未选择1全选2部分选择
updateStageID: null, //编辑阶段id
deleteStageId:null,//删除阶段的id
deleteStageModal:false,//删除阶段弹窗
});
console.log("projectId", state.projectId);
const selectProjectName = (value, index) => {
@@ -1172,31 +1302,7 @@ export default {
const afterVisibleChange = (bool) => {
console.log("visible", bool);
};
//添加阶段
const editStage = () => {
if (!state.valuesname) {
message.destroy();
return message.warning("请输入阶段名称");
}
let obj = {
name: state.valuesname,
projectId: state.projectId,
remark: state.valuesnotice,
};
apistage
.editStage(obj)
.then((res) => {
console.log("添加阶段成功", res);
(state.valuesname = ""),
(state.valuesnotice = ""),
(state.stage = false);
message.default();
message.success("添加阶段成功");
})
.catch((err) => {
console.log("添加阶段失败", err);
});
};
// 把数据放到state里
const getTableData = (tableData) => {
let data = tableData;
@@ -1450,11 +1556,10 @@ export default {
let stage = localStorage.getItem("stageId")
? localStorage.getItem("stageId")
: null;
if (stage !== null) {
if (stage !== "null") {
state.chooseStageId = stage;
} else {
state.chooseStageId = leng > 0 ? stagearr[0].stageId : null;
console.log(state.chooseStageId, 1111);
}
}
})
@@ -1568,12 +1673,7 @@ export default {
// 40 +
// "px";
// };
//添加阶段详情
const showModal = () => {
state.stage = true;
//关闭确认框
closeConfirm();
};
const showModal1 = () => {
//关闭确认框
state.deleteModal = false;
@@ -1581,8 +1681,105 @@ export default {
message.success("删除成功");
getTask();
};
//关闭添加阶段弹窗
const closeModal = () => {
state.stage = false;
state.valuesname = "";
state.valuesnotice = "";
state.updateStageID = null;
};
//显示添加阶段弹窗
const showModal = (element) => {
state.stage = true;
//关闭确认框
closeConfirm();
if (element) {
state.valuesname = element.tit;
state.valuesnotice = element.name;
state.updateStageID = element.id;
}
};
//添加阶段
const editStage = () => {
if (!state.valuesname) {
message.destroy();
return message.warning("请输入阶段名称");
}
if (state.updateStageID) {
let obj = {
name: state.valuesname,
projectId: state.projectId,
remark: state.valuesnotice,
stageId: state.updateStageID,
};
apistage
.editStage(obj)
.then((res) => {
console.log("修改阶段成功", res);
state.valuesname = "";
state.valuesnotice = "";
closeModal()
state.updateStageID = null;
message.destroy();
message.success("修改阶段成功");
getTask();
})
.catch((err) => {
console.log("添加阶段失败", err);
});
} else {
let obj = {
name: state.valuesname,
projectId: state.projectId,
remark: state.valuesnotice,
};
apistage
.editStage(obj)
.then((res) => {
console.log("添加阶段成功", res);
state.valuesname = ""
state.valuesnotice = ""
closeModal()
message.destroy();
message.success("添加阶段成功");
getTask();
})
.catch((err) => {
console.log("添加阶段失败", err);
});
}
};
//打开删除阶段弹窗
const showDeleteStage=(id)=>{
state.deleteStageId=id
state.deleteStageModal=true
}
//关闭删除阶段弹窗
const closeDeleteStage=()=>{
state.deleteStageId=null
state.deleteStageModal=false
}
//删除阶段
const deleteStage = () => {
console.log("chapterId", state.deleteStageId);
let obj = {
stageId: state.deleteStageId,
};
apistage
.deleteStage(obj)
.then((res) => {
console.log("删除阶段成功", res);
message.success('删除阶段成功')
closeDeleteStage()
getTask();
})
.catch((err) => {
console.log("删除阶段失败", err);
});
};
onMounted(() => {
document.getElementsByTagName("main")[0].style.background =
@@ -1874,6 +2071,10 @@ export default {
showdeAll,
closeDeAll,
handleChangeStage,
showDeleteStage,
closeDeleteStage,
deleteStage,
};
},
};
@@ -2300,6 +2501,7 @@ export default {
.taskadd {
width: 100%;
display: flex;
flex-direction: column;
min-width: 933px;
// min-width: 1200px;
// overflow-x: hidden;
@@ -2366,53 +2568,76 @@ export default {
width: 208px;
display: flex;
flex-direction: column;
align-items: center; // background-color: #bfa;
align-items: center;
.ghost {
// background-color: red;
opacity: 0 !important;
}
.item {
.items {
width: 171px;
height: 83px;
display: flex;
// height: 83px;
background: rgba(255, 182, 78, 0.1);
border: 1px solid #ffb64e;
opacity: 0.45;
border-radius: 8px;
margin-bottom: 17px;
margin-bottom: 16px;
align-items: center;
position: relative;
.itemle {
margin-left: 17px;
.tit {
color: black;
// color: red;
font-size: 14px;
margin-bottom: 8px;
font-weight: bold;
white-space: nowrap;
text-overflow: ellipsis;
overflow: hidden;
width: 100px;
}
.name {
font-size: 14px;
color: #878b92;
white-space: nowrap;
text-overflow: ellipsis;
overflow: hidden;
width: 100px;
}
}
.itemri {
padding: 16px;
opacity: 0.5;
cursor: pointer;
.items1 {
margin-bottom: 12px;
display: flex;
flex-direction: column;
position: absolute;
right: 16px;
justify-content: space-between;
align-items: center;
.boxs_left {
display: flex;
align-items: center;
.script {
display: flex;
justify-content: center;
align-items: center;
width: 56px;
height: 24px;
background: #ffb64e;
border-radius: 6px;
margin-right: 12px;
white-space: nowrap;
}
.imgIcon {
width: 16px;
height: 16px;
background-image: url(@/assets/images/leveladd/edit1.png);
background-size: 100% 100%;
}
}
.bgcactive {
.boxs_right {
.imgIcon {
width: 16px;
height: 16px;
background-image: url(@/assets/images/leveladd/delete.png);
background-size: 100% 100%;
}
}
}
.items2 {
.nname {
width: 140px;
// overflow: hidden;
// text-overflow: ellipsis;
// white-space: nowrap;
font-weight: bold;
overflow: hidden;
text-overflow: ellipsis;
-webkit-line-clamp: 2;
display: -webkit-box;
-webkit-box-orient: vertical;
}
}
}
.active {
opacity: 1;
// transition: all 0.5s;
}
@@ -2479,8 +2704,40 @@ export default {
display: flex;
align-items: center;
.select {
margin-right: 50px;
// margin-bottom: 20px;
display: flex;
align-items: center;
white-space: nowrap;
margin-right: 56px;
.inputbox {
display: flex;
align-items: center;
border: 1px solid #c7cbd2;
width: 238px;
height: 40px;
border-radius: 8px;
input {
border: none;
outline: none;
}
.bottonbox {
width: 100px;
height: 40px;
background: #409eff;
border-radius: 8px;
display: flex;
justify-content: center;
align-items: center;
cursor: pointer;
flex-shrink: 0;
.btnText {
font-size: 14px;
font-weight: 400;
color: #ffffff;
line-height: 36px;
margin-left: 5px;
}
}
}
}
.line {
height: 60px;
@@ -2880,5 +3137,51 @@ export default {
margin-left: 10px;
}
}
.footbtn {
width: 100%;
height: 80px;
margin-top: 16px;
// flex: 1;
background-color: #fff;
box-shadow: 0px 1px 35px 0px rgba(118, 136, 166, 0.07);
display: flex;
justify-content: end;
.btnbox {
display: flex;
margin-right: 36px;
height: 80px;
.btn {
padding: 0px 26px 0px 26px;
height: 38px;
border-radius: 8px;
border: 1px solid rgba(64, 158, 255, 1);
display: flex;
align-items: center;
justify-content: center;
flex-shrink: 0;
margin: 21px 0px 19px 14px;
cursor: pointer;
white-space: nowrap;
.btnText {
font-size: 14px;
font-weight: 400;
line-height: 36px;
margin-left: 5px;
}
}
.btn1 {
background-color: #409eff;
.btnText {
color: #ffffff;
}
}
.btn2 {
background-color: #ffffff;
.btnText {
color: #409eff;
}
}
}
}
}
</style>

View File

@@ -2284,7 +2284,7 @@ export default {
sourceBelong: null, //资源归属
remark: null, //项目说明
level: null, //项目级别
systemId: null, //培训体系
systemId: null, //培训分类
picUrl: null,
parentId: null,
});
@@ -2665,79 +2665,17 @@ export default {
};
//学员管理列表操作
const studentData = () => {
let arr = state.tabledata;
console.log(arr, "学员管理");
arr.map((value) => {
value.operation = (
<div
style={{
display: "flex",
alignItems: "center",
justifyContent: "center",
}}
>
<div
class="studentopea1"
onClick={() => {
if (value.excellent === false) {
state.canclestu = true;
console.log("youxiu", value.studentId);
state.changeGoods.push(value.studentId);
} else if (value.excellent === true) {
state.canclestu1 = true;
console.log("youxiu", value.studentId);
state.changeGoods.push(value.studentId);
}
}}
>
{value.excellent ? "取消优秀" : "优秀学员"}
</div>
// const studentData = () => {
// let arr = state.tabledata;
// console.log(arr, "学员管理");
// arr.map((value) => {
// value.operation = (
<div
class="studentopea2"
onClick={() => {
state.Seevisible = true;
console.log(value.studentId, "点击了查看");
state.checkStuId = value.studentId;
}}
>
查看
</div>
<div class="studentSelect">
<a-select
style="width: 50px"
value="更多"
// options={state.projectNameList}
dropdownClassName="tabledropdown"
>
<a-select-option value="换组" label="换组">
<div
onClick={() => {
state.Changevisible = true;
}}
>
换组
</div>
</a-select-option>
<a-select-option value="删除" label="删除">
<div
onClick={() => {
console.log("点击了111", value.studentId);
showDeleteOne(value.studentId);
}}
>
删除
</div>
</a-select-option>
</a-select>
</div>
</div>
);
});
state.tabledata = arr;
};
studentData();
// );
// });
// state.tabledata = arr;
// };
// studentData();
const studentColumns = () => {
const tablecolumns = [
{
@@ -2844,6 +2782,75 @@ export default {
// width: 60,
align: "center",
className: "h",
scopedSlots: { customRender: "action" }, //引入的插槽
customRender: (text) => {
// console.log(text);
return (
<div
style={{
display: "flex",
alignItems: "center",
justifyContent: "center",
}}
>
<div
class="studentopea1"
onClick={() => {
if (text.record.excellent === false) {
state.canclestu = true;
console.log("youxiu", text.record.studentId);
state.changeGoods.push(text.record.studentId);
} else if (text.record.excellent === true) {
state.canclestu1 = true;
console.log("youxiu", text.record.studentId);
state.changeGoods.push(text.record.studentId);
}
}}
>
{text.record.excellent ? "取消优秀" : "优秀学员"}
</div>
<div
class="studentopea2"
onClick={() => {
state.Seevisible = true;
console.log(text.record.studentId, "点击了查看");
state.checkStuId = text.record.studentId;
}}
>
查看
</div>
<div class="studentSelect">
<a-select
style="width: 50px"
value="更多"
// options={state.projectNameList}
dropdownClassName="tabledropdown"
>
<a-select-option value="换组" label="换组">
<div
onClick={() => {
state.Changevisible = true;
}}
>
换组
</div>
</a-select-option>
<a-select-option value="删除" label="删除">
<div
onClick={() => {
// console.log("点击了111", text);
showDeleteOne(text.record.studentId);
}}
>
删除
</div>
</a-select-option>
</a-select>
</div>
</div>
)}
},
];
return tablecolumns;
@@ -3112,7 +3119,7 @@ export default {
if (leng > 0) {
let arr = res.data.data.rows;
getTableDataList(arr);
studentData();
// studentData();
}
});
};
@@ -3536,7 +3543,7 @@ export default {
createG,
resetGroupName,
searchGroup,
studentData,
// studentData,
cancelyou,
cancelcanyou,
changePaginationStu,

File diff suppressed because it is too large Load Diff