Merge remote-tracking branch 'origin/zcwy-0511-out' into zcwy-0511-out

# Conflicts:
#	src/views/gratefulteacher/InstructorCertification.vue
#	src/views/gratefulteacher/LecturerManagement.vue
#	src/views/gratefulteacher/tablemodel.vue
This commit is contained in:
zhangsir
2024-05-15 09:47:32 +08:00
20 changed files with 624 additions and 168 deletions

View File

@@ -129,3 +129,30 @@ export const getDataById = (data) => http.post('/activityApi/teacher/getDataById
export const getCertificationProcess = (data) => http.post('/activityApi/teacher/getCertificationProcess',data) export const getCertificationProcess = (data) => http.post('/activityApi/teacher/getCertificationProcess',data)
//编辑认证 //编辑认证
export const updateExamine = (data) => http.post('/activityApi/examine/updateExamine',data) export const updateExamine = (data) => http.post('/activityApi/examine/updateExamine',data)
//添加权限 0: 查看 2: 管理
export const addPermission = (data) => http.post('/activityApi/examinePermission/addPermission',data)
//权限列表
export const removePermission = (data)=>{
return http({
url:'/activityApi/examinePermission/list',
method: "post",
data:data
})
}
//转移归属权
export const transferPermission =(data)=>{
return http({
url:'/activityApi/examinePermission/transferPermission',
method: "post",
data:data
})
}
//添加权限
// export const addPermission = (data)=>{
// return http({
// url:'/activityApi/permission/addPermission',
// method: "post",
// data:data
// })
// }

View File

@@ -80,3 +80,5 @@ export const getProjectCount = (projectId) => http.get('/admin/project/projectCo
export const login = (obj) => http.post('/admin/CheckUser/userLogin', obj) export const login = (obj) => http.post('/admin/CheckUser/userLogin', obj)
export const userInfo = () => http.get('/admin/CheckUser/userInfo') export const userInfo = () => http.get('/admin/CheckUser/userInfo')
//修改备注
export const editStudent = (obj) => http.post('/admin/student/editStudent', obj)

View File

@@ -20,3 +20,5 @@ export const dataStatisticsSelectV1= (obj) => http.post('/data/statistics/select
export const dataStatisticsSelectV2= (obj) => http.post('/data/statistics/select/v2', obj ) export const dataStatisticsSelectV2= (obj) => http.post('/data/statistics/select/v2', obj )
// 图表2 学习情况数据接口 // 图表2 学习情况数据接口
export const boeuStudyDataGetStudyStaisticsList= (obj) => http.post('/boeu/studyData/getStudyStatisticsList', obj ) export const boeuStudyDataGetStudyStaisticsList= (obj) => http.post('/boeu/studyData/getStudyStatisticsList', obj )
//查看用户有无权限
export const reportOrgs = (obj) => https.get('/orgHrbp/reportOrgs', {params:obj} )

View File

@@ -606,6 +606,16 @@
} }
]; ];
} }
if (n.indexOf("/trainingnewmanager") !== -1 || n.indexOf("/TrainingNewManager") !== -1) {
state.list = [
{
name: "报表中心",
},
{
name:'新任管理者培训数据'
},
];
}
if (n.indexOf("/learningpathmap") !== -1 || n.indexOf("/LearningPathMap") !== -1) { if (n.indexOf("/learningpathmap") !== -1 || n.indexOf("/LearningPathMap") !== -1) {
state.list = [ state.list = [
{ {

View File

@@ -584,6 +584,15 @@
<router-link to="/employeelearning">员工学习数据</router-link> <router-link to="/employeelearning">员工学习数据</router-link>
</a-menu-item> </a-menu-item>
</a-sub-menu> </a-sub-menu>
<a-menu-item key="sub17-4" v-if="checkMenu('trainingnewmanager')">
<span
:class="{
circleActive: selectedKeys[0] === 'sub17-4' ? true : false,
circle: selectedKeys[0] === 'sub17-4' ? false : true,
}"
></span>
<router-link to="/trainingnewmanager">新任管理者培训数据</router-link>
</a-menu-item>
</a-sub-menu> </a-sub-menu>
<a-menu-item key="sub16" v-if="checkMenu('OldSystemManage')"> <a-menu-item key="sub16" v-if="checkMenu('OldSystemManage')">
<div class="imgBox"> <div class="imgBox">
@@ -1039,6 +1048,12 @@ export default {
selectedKeys: "sub17-3-2", selectedKeys: "sub17-3-2",
pagename: "员工学习数据", pagename: "员工学习数据",
}, },
{
href: "/trainingnewmanager",
openKeys: "sub17",
selectedKeys: "sub17-4",
pagename: "新任管理者培训数据",
},
{ {
href: "/oldsystemmanage", href: "/oldsystemmanage",
openKeys: "sub18", openKeys: "sub18",
@@ -1177,7 +1192,6 @@ export default {
const getClientHeight = () => { const getClientHeight = () => {
state.screenHeight = document.body.clientHeight; state.screenHeight = document.body.clientHeight;
}; };
onMounted(() => { onMounted(() => {
// console.log("11111", 1); // console.log("11111", 1);
window.addEventListener("resize", getClientHeight, false); window.addEventListener("resize", getClientHeight, false);

View File

@@ -430,10 +430,7 @@ export default {
// 导出数据 // 导出数据
function exportTaskStu() { function exportTaskStu() {
if(!props.datasource.projectTaskId){ window.open(`${process.env.VUE_APP_BASE_API}/admin/student/exportTaskStudent?currentStageId=${props.datasource.stageId}&type=${1}&pid=${props.datasource.projectId}&taskType=${props.datasource.type}`)
props.datasource.projectTaskId = ''
}
window.open(`${process.env.VUE_APP_BASE_API}/admin/student/exportTaskStudent?currentStageId=${props.datasource.stageId}&type=${1}&pid=${props.datasource.projectId}&taskId=${props.datasource.projectTaskId}&taskType=${props.datasource.type}`)
// window.open(`${process.env.VUE_APP_BASE_API}/admin/student/exportTaskStudent?pageNo=${state.currentPage}&pageSize=${state.pageSize}&currentStageId=${props.datasource.stageId}&type=${1}&pid=${props.datasource.projectId}&taskId=${props.datasource.projectTaskId}&status=${state.name}&studentName=${state.projectName}`) // window.open(`${process.env.VUE_APP_BASE_API}/admin/student/exportTaskStudent?pageNo=${state.currentPage}&pageSize=${state.pageSize}&currentStageId=${props.datasource.stageId}&type=${1}&pid=${props.datasource.projectId}&taskId=${props.datasource.projectTaskId}&status=${state.name}&studentName=${state.projectName}`)
} }

View File

@@ -314,7 +314,7 @@ export default {
align: "center", align: "center",
ellipsis: true, ellipsis: true,
className: "h", className: "h",
customRender: ({record:{status}}) => ({1:'已完成',0:'未开始',9:'已完成'}[status] || '未开始'), customRender: ({record:{status}}) => ({2:'进行中',1:'未开始',9:'已完成'}[status] || '未开始'),
}, },
{ {
title: "操作", title: "操作",

View File

@@ -428,11 +428,8 @@ export default {
// 导出数据 // 导出数据
function exportTaskStu() { function exportTaskStu() {
console.log(`${process.env.VUE_APP_BASE_API}/admin/student/exportTaskStudent?currentStageId=${props.datasource.chapterId}&type=${2}&pid=${props.datasource.routerId}&taskId=${props.datasource.routerTaskId}&taskType=${props.datasource.type}`) console.log(`${process.env.VUE_APP_BASE_API}/admin/student/exportTaskStudent?currentStageId=${props.datasource.chapterId}&type=${2}&pid=${props.datasource.routerId}&taskId=${props.datasource.id}&taskType=${props.datasource.type}`)
if(!props.datasource.routerTaskId){ window.open(`${process.env.VUE_APP_BASE_API}/admin/student/exportTaskStudent?currentStageId=${props.datasource.chapterId}&type=${2}&pid=${props.datasource.routerId}&taskId=${props.datasource.id}&taskType=${props.datasource.type}`)
props.datasource.routerTaskId = ''
}
window.open(`${process.env.VUE_APP_BASE_API}/admin/student/exportTaskStudent?currentStageId=${props.datasource.chapterId}&type=${2}&pid=${props.datasource.routerId}&taskId=${props.datasource.routerTaskId}&taskType=${props.datasource.type}`)
// window.open(`${process.env.VUE_APP_BASE_API}/admin/student/exportTaskStudent?pageNo=${state.currentPage}&pageSize=${state.pageSize}&currentStageId=${props.datasource.chapterId}&type=${2}&pid=${props.datasource.routerId}&taskId=${props.datasource.routerTaskId}&status=${state.name}&studentName=${state.projectName}`) // window.open(`${process.env.VUE_APP_BASE_API}/admin/student/exportTaskStudent?pageNo=${state.currentPage}&pageSize=${state.pageSize}&currentStageId=${props.datasource.chapterId}&type=${2}&pid=${props.datasource.routerId}&taskId=${props.datasource.routerTaskId}&status=${state.name}&studentName=${state.projectName}`)
} }

View File

@@ -243,7 +243,7 @@ const columns = ref([
width: 80, width: 80,
align: "center", align: "center",
ellipsis: true, ellipsis: true,
customRender: ({ record: { finishStatus } }) => finishStatus ? "已完成" : "未开始", customRender: ({ record: { finishStatus } }) => finishStatus==9 ? "已完成" : finishStatus==2 ? "进行中": '未开始',
}, },
{ {
title: "操作", title: "操作",

View File

@@ -441,6 +441,10 @@ const props = defineProps({
type: Object, type: Object,
default: () => ({}), default: () => ({}),
}, },
remarksTrue: {
type: Boolean,
default: false,
}
}); });
const { loading: stuAsyncLoading, start } = useAsyncStu(props.id, props.type, getStuList); const { loading: stuAsyncLoading, start } = useAsyncStu(props.id, props.type, getStuList);
@@ -540,7 +544,7 @@ const tablecolumns = ref([
title: "操作", title: "操作",
dataIndex: "operation", dataIndex: "operation",
key: "operation", key: "operation",
width: 210, width: 260,
align: "center", align: "center",
slots: { customRender: "action" }, slots: { customRender: "action" },
}, },

View File

@@ -18,6 +18,18 @@ export function downLoadZip(str, filename) {
resolveBlob(res, mimeMap.zip,filename) resolveBlob(res, mimeMap.zip,filename)
}) })
} }
const baseUrlManage = process.env.VUE_APP_BASE_API
export function downLoadZipManage(str, filename) {
var url = baseUrlManage + str
axios({
method: 'get',
url: url,
responseType: 'blob',
headers: { 'Authorization': 'Bearer ' + getCookieForName("token") }
}).then(res => {
resolveBlob(res, mimeMap.xlsx,filename)
})
}
/** /**
* 解析blob响应内容并下载 * 解析blob响应内容并下载
* @param {*} res blob响应内容 * @param {*} res blob响应内容

View File

@@ -878,6 +878,7 @@ import {downLoadZip} from "@/utils/zipdownload";
bg_remarks: false, bg_remarks: false,
checkclick: [], checkclick: [],
permissionId:'', permissionId:'',
perWorkNum: '',
filesList:[], filesList:[],
tableData:[], tableData:[],
tableData1:[], tableData1:[],
@@ -1285,6 +1286,7 @@ import {downLoadZip} from "@/utils/zipdownload";
await updateStatus({status:1,id:record.id}).then((res)=>{ await updateStatus({status:1,id:record.id}).then((res)=>{
if(res.code === 200){ if(res.code === 200){
message.success('禁用成功') message.success('禁用成功')
getByUserIds(record.workNum)
saveListItem() saveListItem()
listData() listData()
} }
@@ -1297,6 +1299,7 @@ import {downLoadZip} from "@/utils/zipdownload";
deleteId({id:record.id}).then((res)=>{ deleteId({id:record.id}).then((res)=>{
if(res.code === 200){ if(res.code === 200){
message.success('删除成功') message.success('删除成功')
getByUserIds(record.workNum)
saveListItem() saveListItem()
listData() listData()
} }
@@ -1307,6 +1310,7 @@ import {downLoadZip} from "@/utils/zipdownload";
const updateAuthority = (record) => { const updateAuthority = (record) => {
state.bg_power = true state.bg_power = true
state.permissionId = record.id state.permissionId = record.id
state.perWorkNum = record.workNum
if(record.permission){ if(record.permission){
state.checkclick = record.permission.split(',') state.checkclick = record.permission.split(',')
} }
@@ -1439,7 +1443,9 @@ import {downLoadZip} from "@/utils/zipdownload";
successIds:state.saveNotUpload?state.sussessIds.length!=0?state.sussessIds.split(','):null:null successIds:state.saveNotUpload?state.sussessIds.length!=0?state.sussessIds.split(','):null:null
}).then((res)=>{ }).then((res)=>{
if(res.status == 500){ if(res.status == 500){
message.error('测评标题和报告名称不一致') if(res.message){
message.error(res.message)
}
state.uploadDownLoad = false state.uploadDownLoad = false
state.uploadStatusType = false state.uploadStatusType = false
} }
@@ -1447,6 +1453,9 @@ import {downLoadZip} from "@/utils/zipdownload";
state.uploadDownLoad = false state.uploadDownLoad = false
state.bg_check = false state.bg_check = false
} }
}).catch(err=>{
state.uploadDownLoad = false
state.uploadStatusType = false
}) })
} }
if(state.uploadStatusType){ if(state.uploadStatusType){
@@ -1711,7 +1720,9 @@ import {downLoadZip} from "@/utils/zipdownload";
} }
//添加权限确定 //添加权限确定
const addSettingUp = async () => { const addSettingUp = async () => {
await savePermission({userList:[state.saveList],pid:state.saveListPid}) if(JSON.stringify(state.saveList) !== '{}'){
await savePermission({userList:[state.saveList],pid:state.saveListPid})
}
saveListItem() saveListItem()
of_addsetting() of_addsetting()
listData() listData()
@@ -1725,21 +1736,22 @@ import {downLoadZip} from "@/utils/zipdownload";
state.bg_power2 = false state.bg_power2 = false
state.powerStatus = {} state.powerStatus = {}
state.permissionId = '' state.permissionId = ''
state.perWorkNum = ''
state.checkclick = [] state.checkclick = []
} }
const getByUserIds = async () => { const getByUserIds = async (workNum) => {
// const roleCode = userInfo.value await getByUserId({workNum,}).then(res=>{
// const roleId = roleCode.roleList.find(item=>item.roleCode=='quiz-admin') || null // if(res.code == 200){
// const isQuizAdmin = roleId ? 1 : 0 // console.log(res.data,'workUnum')
// await getByUserId({loginId:roleCode.userId,roleId,isQuizAdmin}).then(res=>{ // }
})
// })
} }
const powerTrue = async () => { const powerTrue = async () => {
state.powerStatus.permission = state.checkclick.join(",") state.powerStatus.permission = state.checkclick.join(",")
if(state.permissionId){ if(state.permissionId){
await updateStatus({id:state.permissionId,permission:state.checkclick.join(",")}).then((res)=>{ await updateStatus({id:state.permissionId,permission:state.checkclick.join(",")}).then((res)=>{
saveListItem() saveListItem()
getByUserIds(state.perWorkNum)
}) })
} }
listData() listData()
@@ -1749,9 +1761,9 @@ import {downLoadZip} from "@/utils/zipdownload";
await updateStatus({status:0,id:record.id}).then((res)=>{ await updateStatus({status:0,id:record.id}).then((res)=>{
if(res.code === 200){ if(res.code === 200){
message.success('启用成功') message.success('启用成功')
getByUserIds(record.workNum)
listData() listData()
saveListItem() saveListItem()
getByUserIds()
} }
}) })
} }

View File

@@ -360,6 +360,14 @@
type: String, type: String,
default: null, default: null,
}, },
permissionType:{
type: Number,
default: null,
},
examineId:{
type: String,
default: null
}
}); });
const projectSelectKeys = ref([]); const projectSelectKeys = ref([]);
const projectSelectRows = ref([]); const projectSelectRows = ref([]);
@@ -590,6 +598,7 @@
//清空选择部门信息 //清空选择部门信息
const deleteDepSelect = () => { const deleteDepSelect = () => {
stuSelectRows.value = []; stuSelectRows.value = [];
dataLists.value = []
selectedOrgKeys.value = []; selectedOrgKeys.value = [];
projectSelectKeys.value = []; projectSelectKeys.value = [];
}; };
@@ -620,7 +629,21 @@
} }
handleStageOk(); handleStageOk();
} }
const dataLists = ref([])
watch(()=>stuSelectRows.value,(val)=>{
if(val.length!=0){
console.log(val,'val')
dataLists.value = val.map(item=>{
console.log(item,'item')
return{
examineId:props.examineId,
name:item.realName,
userNo:item.userNo,
departName:item.departName,
permissionType:props.permissionType}
})
}
})
function handleStageOk() { function handleStageOk() {
if (props.type === 1 && props.groupId && (props.groupMemberCount < (props.groupMemberNumber * 1 + projectSelectRows.value.length + stuSelectRows.value.length))) { if (props.type === 1 && props.groupId && (props.groupMemberCount < (props.groupMemberNumber * 1 + projectSelectRows.value.length + stuSelectRows.value.length))) {
return message.warning("添加小组学员超过最大值"); return message.warning("添加小组学员超过最大值");
@@ -629,18 +652,7 @@
visiable.value = false; visiable.value = false;
emit("finash", false); emit("finash", false);
nameSearch.value.keyword = ""; nameSearch.value.keyword = "";
saveStu({ addPermission(dataLists.value).then(() => {
targetId: props.id,
type: props.type,
clear: props.clear,
deptIds: deptList.value?.map((e) => e.id),
stageId: stageId.value,
groupIds: auditSelectRows.value?.map((e) => e.id),
studentList: stuSelectRows.value,
projectList: projectSelectRows.value,
groupName: props.groupName,
groupId: props.groupId,
}).then(() => {
deleteDepSelect(); deleteDepSelect();
emit("finash", true); emit("finash", true);
}); });

View File

@@ -1,5 +1,5 @@
<script setup > <script setup >
import { ref,onMounted } from 'vue'; import { ref,onMounted,computed } from 'vue';
import { useRoute, useRouter } from 'vue-router' import { useRoute, useRouter } from 'vue-router'
import {getexamineList,CreateAuthentication,delExamine,getOnlineLearningList,deleteCourse,addCourse,updateExamine,removePermission} from '@/api/examineApi.js' import {getexamineList,CreateAuthentication,delExamine,getOnlineLearningList,deleteCourse,addCourse,updateExamine,removePermission} from '@/api/examineApi.js'
import dialog from "@/utils/dialog"; import dialog from "@/utils/dialog";
@@ -8,11 +8,20 @@ import OwnerTableModelStudent from "./tablemodel";
import CommonStudent from "./CommonTeacher"; import CommonStudent from "./CommonTeacher";
import CreateOnline from "@/components/drawers/CreateOnline.vue"; import CreateOnline from "@/components/drawers/CreateOnline.vue";
import { message } from "ant-design-vue"; import { message } from "ant-design-vue";
import { useStore } from "vuex";
const route = useRoute() const route = useRoute()
const router = useRouter() const router = useRouter()
const visible = ref(false); const visible = ref(false);
const loading = ref(false); const loading = ref(false);
const store = useStore();
const userInfo = computed(() => store.state.userInfo);
const uploadAdmin = (admin)=>{
const roleCode = userInfo.value.roleList.map((item)=>item.roleCode)
if (admin){
return roleCode.some(t => t == admin)
}
}
const onlineRef = ref(false);
const columns = [ const columns = [
{ {
name: 'serial', name: 'serial',
@@ -101,7 +110,7 @@ const createParam = ref({
index:'' index:''
}) })
const imgClick = (item) => { const imgClick = (item) => {
console.log(url,'url') console.log(item,'url')
createParam.value.cover = item.url createParam.value.cover = item.url
createParam.value.index = item.id createParam.value.index = item.id
} }
@@ -136,7 +145,25 @@ const editFee = (record) => {
} }
//线上学习课列表显示 //线上学习课列表显示
const ViewReviewdata = ref([]) const ViewReviewdata = ref([])
const OnlineLearning = async () => { const ViewReviewDataShow = ref([])
function selectCourse(row) {
console.log(row);
row.courseName = row.name
row.courseContent = '在线课'
row.createName = row.sysCreateBy
row.createTime = row.publishTime
row.newId = 2
console.log(row,'row')
if (!ViewReviewDataShow.value.some(item => item.id === row.id)) {
console.log('添加')
ViewReviewdata.value.push(row);
ViewReviewDataShow.value.push(row);
}
onlineRef.value.closeModal();
}
const OnlineLearning = async (i, row) => {
window.selectCourse = selectCourse;
// row && (ViewReviewdata.value = [row.info]);
ViewReviewShow.value = true ViewReviewShow.value = true
await getOnlineLearningList().then(res=>{ await getOnlineLearningList().then(res=>{
if(res.code == 200){ if(res.code == 200){
@@ -155,10 +182,17 @@ const createData = () => {
visible.value = true visible.value = true
} }
//删除数据 //删除数据
const deleteReview = (record) =>{ const deleteReview = (record,index) =>{
console.log(ViewReviewdata,'ViewReviewdata')
console.log(record,index,'record')
dialog({ dialog({
content: '是否删除?', content: '是否删除?',
ok: () => { ok: () => {
if(record.newId==2){
ViewReviewdata.value = ViewReviewdata.value.filter(item => item.id !== record.id);
message.success('删除成功')
return
}
deleteCourse({id:record.id}).then(res=>{ deleteCourse({id:record.id}).then(res=>{
console.log(res,'res') console.log(res,'res')
if(res.code == 200){ if(res.code == 200){
@@ -169,35 +203,41 @@ const deleteReview = (record) =>{
} }
}) })
} }
const falseData = () => {
ViewReviewdata.value = []
ViewReviewDataShow.value = []
ViewReviewShow.value = false
}
const AddList = () => {
console.log(ViewReviewdata.value,'数据')
if(ViewReviewDataShow.value.length==0){
message.error('请选择课程')
return
}
// const data = ViewReviewDataShow.value.map(item=>{
// return {
// courseName: item.name,
// courseContent: '',
// courseId: item.orgId
// }
// })
const filteredData = ViewReviewdata.value.filter(item => item.newId === 2);
if(filteredData.length==0){
message.error('请选择课程')
return
}
const transformedData = filteredData.map(item => ({
courseName: item.name,
courseContent: '',
courseId: item.orgId
}));
addCourse({transformedData}).then(res=>{
console.log(res,'res')
})
falseData()
}
//认证审批项目列表数据 //认证审批项目列表数据
const data = ref([{ const data = ref([])
"id": 1,
"deleted": false,
"createTime": "2024-05-10 13:38:37",
"createId": null,
"createName": null,
"updateTime": "2024-05-10 13:49:16",
"updateId": 965342027497607168,
"updateName": "李玉冰",
"number": 1,
"name": "测试1",
"description": "认证项目详情",
"cover": "/www/elearning/upload/activityfile/blue.png"
},
{
"id": 6,
"deleted": false,
"createTime": "2024-05-10 13:24:50",
"createId": null,
"createName": null,
"updateTime": null,
"updateId": null,
"updateName": null,
"number": 2,
"name": "认证项目003修改",
"description": "认证项目详情",
"cover": "/www/elearning/upload/activityfile/blue.png"
},])
const delVisible = ref(false) const delVisible = ref(false)
//页数 //页数
const current1 = ref(1); const current1 = ref(1);
@@ -333,13 +373,13 @@ function handleOper(record, type, status = "") {
<img <img
style="width: 29px; height: 29px; cursor: pointer" style="width: 29px; height: 29px; cursor: pointer"
src="../../assets/images/basicinfo/close.png" src="../../assets/images/basicinfo/close.png"
@click="closeDrawer" @click="falseData"
/> />
</div> </div>
<div style="display: flex;flex-direction: column;"> <div style="display: flex;flex-direction: column;">
<!-- <div @click="ViewReviewShow=true" style="margin-bottom: 15px; height: 38px; width: 150px;background: #4ea6ff;line-height: 40px;text-align: center;border-radius: 8px;color: #ffffff;">选择/新建课程</div> --> <!-- <div @click="ViewReviewShow=true" style="margin-bottom: 15px; height: 38px; width: 150px;background: #4ea6ff;line-height: 40px;text-align: center;border-radius: 8px;color: #ffffff;">选择/新建课程</div> -->
<CreateOnline ref="onlineRef" :id="1" :type="1"> <CreateOnline ref="onlineRef" :id="''" :type="''">
<a-button type="primary" style="border-radius: 4px;margin-bottom: 15px;">{{ <a-button type="primary" style="border-radius: 4px;margin-bottom:15px;">{{
"选择/新建课程" "选择/新建课程"
}} }}
</a-button> </a-button>
@@ -358,7 +398,7 @@ function handleOper(record, type, status = "") {
> >
<template #action="{ record, column }"> <template #action="{ record, column }">
<a-space> <a-space>
<a-button type="link" @click="deleteReview(record)"> <a-button type="link" @click="deleteReview(record,index)">
<span>删除</span> <span>删除</span>
</a-button> </a-button>
</a-space> </a-space>
@@ -367,9 +407,8 @@ function handleOper(record, type, status = "") {
</a-table> </a-table>
</div> </div>
<div style=" display: flex;justify-content: center;"> <div style=" display: flex;justify-content: center;">
<div style="margin-right: 30px; border-radius: 8px; color: #fff;font-size: 16px; display: flex; justify-content: center;align-items: center; width: 100px; height: 38px; margin-top: 36px;background: #3da8f0;">取消</div> <div @click="falseData" style="margin-right: 30px; border-radius: 8px; color: #fff;font-size: 16px; display: flex; justify-content: center;align-items: center; width: 100px; height: 38px; margin-top: 36px;background: #3da8f0;">取消</div>
<div style="border-radius: 8px; color: #fff;font-size: 16px; display: flex; justify-content: center;align-items: center; width: 100px; height: 38px; <div @click="AddList" style="border-radius: 8px; color: #fff;font-size: 16px; display: flex; justify-content: center;align-items: center; width: 100px; height: 38px; margin-top: 36px;background: #3da8f0;">确定</div>
margin-top: 36px;background: #3da8f0;">确定</div>
</div> </div>
</div> </div>
@@ -394,9 +433,9 @@ function handleOper(record, type, status = "") {
<div style="display: flex;justify-content: space-between;align-self: end;"> <div style="display: flex;justify-content: space-between;align-self: end;">
<div v-if="Administrator===0" @click="OnlineLearning" style=" cursor: pointer;margin-right: 15px;height: 38px; width: 150px;background: #4ea6ff; line-height: 40px;text-align: center;border-radius: 8px;color: #ffffff;">线上学习课程设置</div> <div v-if="Administrator===0" @click="OnlineLearning" style=" cursor: pointer;margin-right: 15px;height: 38px; width: 150px;background: #4ea6ff; line-height: 40px;text-align: center;border-radius: 8px;color: #ffffff;">线上学习课程设置</div>
<div class="btns" @click="centerDialogVisible=true"> <div class="btns" @click="centerDialogVisible=true">
<div style="margin-right: 0;" class="btn btn3"> <div style="margin-right: 0;" class="btn btn3" @click="createData">
<div class="search"></div> <div class="search"></div>
<div class="btnText" @click="createData">创建认证</div> <div class="btnText">创建认证</div>
</div> </div>
</div> </div>
</div> </div>
@@ -446,12 +485,13 @@ function handleOper(record, type, status = "") {
:types="[7, 8, 9]" :types="[7, 8, 9]"
:id="record.id" :id="record.id"
:type="9" :type="9"
:searchTrue="true"
>权限名单</OwnerTableModelStudent >权限名单</OwnerTableModelStudent
> >
<CommonStudent :pid="0" :type="7" :id="record.id" title="查看权" <CommonStudent :type="7" :permissionType="0" :examineId="record.id" :id="record.id" title="查看权"
>查看权</CommonStudent >查看权</CommonStudent
> >
<CommonStudent :pid="1" :type="8" :id="record.id" title="管理权" <CommonStudent :type="8" :permissionType="2" :examineId="record.id" :id="record.id" title="管理权"
>管理权</CommonStudent >管理权</CommonStudent
> >
</DropDown> </DropDown>
@@ -482,8 +522,8 @@ function handleOper(record, type, status = "") {
<img style="width: 127px; height: 70px;margin-bottom: 13px;" src="../../assets/33.png" alt=""> <img style="width: 127px; height: 70px;margin-bottom: 13px;" src="../../assets/33.png" alt="">
<img style="width: 127px; height: 70px;margin-bottom: 13px;margin-left: 15px" src="../../assets/47.png" alt=""> <img style="width: 127px; height: 70px;margin-bottom: 13px;margin-left: 15px" src="../../assets/47.png" alt="">
<img style="width: 127px; height: 70px;margin-bottom: 13px;margin-left: 15px" src="../../assets/49.png" alt=""> --> <img style="width: 127px; height: 70px;margin-bottom: 13px;margin-left: 15px" src="../../assets/49.png" alt=""> -->
<div class="img_box_item" :style="createParam?.index==item.id?{border:'1px solid #4ea6ff'}:{}" @click="imgClick(item)" v-for="(item,index) in imgData" :key="index"> <div class="img_box_item" @click="imgClick(item)" v-for="(item,index) in imgData" :key="index">
<img style="width: 127px; height: 70px;" :src="require(`../../assets/${item.img}`)" alt=""> <img :style="createParam?.index==item.id?{border:'3px solid rgba(78, 166, 255, 1)'}:{border:'1px solid #ccc'}" style="width: 127px; height: 70px;" :src="require(`../../assets/${item.img}`)" alt="">
</div> </div>
</a-form-item> </a-form-item>
<a-form-item style="margin-left: 32px;margin-top: 24px" label="具体说明"> <a-form-item style="margin-left: 32px;margin-top: 24px" label="具体说明">

View File

@@ -18,6 +18,12 @@ const route = useRoute()
const router = useRouter() const router = useRouter()
const store = useStore(); const store = useStore();
const userInfo = computed(() => store.state.userInfo) const userInfo = computed(() => store.state.userInfo)
const uploadAdmin = (admin)=>{
const roleCode = userInfo.value.roleList.map((item)=>item.roleCode)
if (admin){
return roleCode.some(t => t == admin)
}
}
console.log(route.query.id, 'idssss'); console.log(route.query.id, 'idssss');
const formState = reactive({ const formState = reactive({
reviewname: '', reviewname: '',
@@ -147,7 +153,7 @@ const editReviewSave = async (name, time, id) => {
editTime.value = time editTime.value = time
addTeacherList() addTeacherList()
} }
const ViewReviewcolumns = [ const ViewReviewcolumns = reactive([
{ {
title: '序号', title: '序号',
key: 'name', key: 'name',
@@ -168,17 +174,13 @@ const ViewReviewcolumns = [
key: '认证结果', key: '认证结果',
dataIndex: '认证结果', dataIndex: '认证结果',
}, },
{
title: '评委-黄盛发10867418',
key: '评委-黄盛发10867418',
dataIndex: '评委-黄盛发10867418',
},
{ {
title: '平均分', title: '平均分',
key: '平均分', key: '平均分',
dataIndex: '平均分', dataIndex: '平均分',
}, },
]; ]);
const ViewReviewdata = ref([]) const ViewReviewdata = ref([])
const reviewcolumn = [ const reviewcolumn = [
{ {
@@ -233,7 +235,7 @@ const columnsTeacher = [
const downLoadCoures = (id) => { const downLoadCoures = (id) => {
console.log(id,'id') console.log(id,'id')
if(id){ if(id){
window.open(`/activityApi/teacher/download?id=${id}`) window.open(`/activityApi/teacher/download?coursewareId=${id}`)
} }
} }
//老师重置 //老师重置
@@ -313,24 +315,27 @@ const getReviewList = async () => {
const ViewReList = ref() const ViewReList = ref()
const arrayLists = ref([]) const arrayLists = ref([])
const remould = () => { const remould = () => {
console.log(2222);
console.log(ViewReList.value)
let keys = Object.keys(ViewReList.value); let keys = Object.keys(ViewReList.value);
arrayLists.value = keys.filter(key => Array.isArray(ViewReList.value[key])); arrayLists.value = keys.filter(key => Array.isArray(ViewReList.value[key]));
arrayLists.value.forEach(arrayKey => { if(arrayLists.value.length!=0){
if (!ViewReviewcolumns.some(column => column.key === arrayKey)) { arrayLists.value.forEach(arrayKey => {
ViewReviewcolumns.push({ if (!ViewReviewcolumns.some(column => column.key === arrayKey)) {
title: arrayKey, ViewReviewcolumns.push({
key: arrayKey, title: arrayKey,
dataIndex: arrayKey, key: arrayKey,
}); dataIndex: arrayKey,
});
}
});
for (let i = 0; i < ViewReList.value[arrayLists.value[0]].length; i++) {
const obj = {};
for (const key of arrayLists.value) {
obj[key] = ViewReList.value[key][i];
}
ViewReviewdata.value.push(obj);
} }
}); }
ViewReviewdata.value = arrayLists.value.map((key, index) => {
return Object.fromEntries([key, ViewReList.value[key][index]]);
});
console.log(ViewReviewdata.value, '基础上九四');
} }
const getreviewdetail = async (object) => { const getreviewdetail = async (object) => {
ViewReviewShow.value = true ViewReviewShow.value = true
@@ -518,6 +523,13 @@ onMounted(() => {
}) })
const activeName = ref('first') const activeName = ref('first')
const ViewReviewShow = ref(null) const ViewReviewShow = ref(null)
watch(ViewReviewShow,(val)=>{
console.log(val,'val')
if(!val){
ViewReviewdata.value = []
}
})
const columns = [ const columns = [
{ {
title: '姓名', title: '姓名',
@@ -700,11 +712,9 @@ const attestation = ref([])
const scoreTwo = ref() const scoreTwo = ref()
const scoreOne = ref() const scoreOne = ref()
const show= async (record)=>{ const show= async (record)=>{
showViewInstructor.value=true
await getDataById({teacherId:record.teacherId}).then(res=>{ await getDataById({teacherId:record.teacherId}).then(res=>{
console.log(res,'res')
if(res.code == 200){ if(res.code == 200){
console.log(res.data,'data') showViewInstructor.value=true
techerDetail.value = res.data techerDetail.value = res.data
if(techerDetail.value.firstList){ if(techerDetail.value.firstList){
const totalScore = techerDetail.value.firstList.reduce((acc, item) => acc + item.score, 0); const totalScore = techerDetail.value.firstList.reduce((acc, item) => acc + item.score, 0);
@@ -718,6 +728,8 @@ const show= async (record)=>{
const averageScore = totalScore / techerDetail.value.secondList.length; const averageScore = totalScore / techerDetail.value.secondList.length;
scoreTwo.value = averageScore.toFixed(2) scoreTwo.value = averageScore.toFixed(2)
} }
}else{
message.error('暂无数据')
} }
}) })
await getCertificationProcess({teacherId:record.teacherId}).then(res=>{ await getCertificationProcess({teacherId:record.teacherId}).then(res=>{
@@ -817,9 +829,9 @@ const vwtext = ref(null)
<p>具体说明{{ route.query.description }}</p> <p>具体说明{{ route.query.description }}</p>
</div> </div>
<div> <div @click="$router.push({ path: '/InstructorCertification' })" style="cursor: pointer;">
<img src="../../assets/images/projectadd/return.png" alt=""> <img src="../../assets/images/projectadd/return.png" alt="">
<el-button type="primary" text @click="$router.push({ path: '/InstructorCertification' })">返回</el-button> <el-button type="primary" text style="margin-left: 10px;">返回</el-button>
</div> </div>
</div> </div>
@@ -895,7 +907,7 @@ const vwtext = ref(null)
</template> </template>
</template> </template>
<template #bodyCell="{ column, record }"> <template #bodyCell="{ column, record,text }">
<template v-if="column.key === 'name'"> <template v-if="column.key === 'name'">
<a> <a>
{{ record.name }} {{ record.name }}
@@ -922,7 +934,7 @@ const vwtext = ref(null)
</template> </template>
<template v-else-if="column.key === 'reviewResult'"> <template v-else-if="column.key === 'reviewResult'">
<span> <span>
{{ text===1?'未开始':(text===2?'进行中':'已完成') }} {{ text===1?'未开始':(text===2?'进行中':'已报名') }}
</span> </span>
</template> </template>
<template v-else-if="column.key === 'action'"> <template v-else-if="column.key === 'action'">
@@ -1233,9 +1245,8 @@ const vwtext = ref(null)
<div class="drawerMain"> <div class="drawerMain">
<div class="header"> <div class="header">
<div class="headerTitle">查看讲师</div> <div class="headerTitle">查看讲师</div>
<img v-if="techerDetail?.avatar" style="width: 29px; height: 29px; cursor: pointer" :src="techerDetail?.avatar"/>
<img <img
v-else @click="showViewInstructor = false"
style="width: 29px; height: 29px; cursor: pointer" style="width: 29px; height: 29px; cursor: pointer"
src="../../assets/images/basicinfo/close.png" src="../../assets/images/basicinfo/close.png"
/> />
@@ -1243,10 +1254,15 @@ const vwtext = ref(null)
<div > <div >
<div style="display: flex;width: 100%; height: 88px;"> <div style="display: flex;width: 100%; height: 88px;">
<div> <div>
<img src="../../assets/2.png" alt=""> <img v-if="techerDetail?.avatar" style="width: 60px; height: 58px;margin-left: 22px;margin-right: 29px;margin-top: 13px;" :src="techerDetail?.avatar"/>
<img
v-else
style="width: 60px; height: 58px;margin-left: 22px;margin-right: 29px;margin-top: 13px;"
src="../../assets/2.png"
/>
</div> </div>
<div style="margin-left: 18px;"> <div style="margin-left: 18px;">
<div style="font-size: 18px;font-weight: 500;color: #333333;line-height: 25px;font-style: normal;">{{techerDetail?.teacherName}} {{techerDetail?.workNo}}<span style="margin-left: 8px;"> 01011098</span></div> <div style="font-size: 18px;font-weight: 500;color: #333333;line-height: 25px;font-style: normal;">{{techerDetail?.teacherName}}<span style="margin-left: 8px;"> {{techerDetail?.teacherNo}}</span></div>
<div style="font-size: 14px;color: #979797;margin-top: 12px;">{{techerDetail?.orgName}}</div> <div style="font-size: 14px;color: #979797;margin-top: 12px;">{{techerDetail?.orgName}}</div>
<div style="font-size: 14px;color: #979797;">{{techerDetail?.orgPath}} {{techerDetail?.bandCode}}</div> <div style="font-size: 14px;color: #979797;">{{techerDetail?.orgPath}} {{techerDetail?.bandCode}}</div>
</div> </div>
@@ -1270,9 +1286,9 @@ const vwtext = ref(null)
<div style="display:flex;"> <div style="display:flex;">
<div style="padding-left:16px; width: 136px;height: 56px;background: #FFFFFF;border: 1px solid #F0F6FC;line-height: 56px;">课程终稿</div> <div style="padding-left:16px; width: 136px;height: 56px;background: #FFFFFF;border: 1px solid #F0F6FC;line-height: 56px;">课程终稿</div>
<div style="width: 559px;height: 56px;line-height: 56px;border: 1px solid #F0F6FC;padding-left:16px;"> <div style="width: 559px;height: 56px;line-height: 56px;border: 1px solid #F0F6FC;padding-left:16px;">
<img src="../../assets/images/gratefulteacher/ppt.png" alt=""> <img v-if="techerDetail?.coursewareName" src="../../assets/images/gratefulteacher/ppt.png" alt="">
学习能力提升课件.pptx {{ techerDetail?.coursewareName?techerDetail?.coursewareName:''}}
<span style="color:#3da8f0" @click="downLoadCoures(techerDetail?.coursewareId)">下载</span> <span v-if="techerDetail?.coursewareName" style="color:#3da8f0" @click="downLoadCoures(techerDetail?.coursewareId)">下载</span>
</div> </div>
<div style="width: 136px;height: 56px;line-height: 56px;background: #FFFFFF;border: 1px solid #F0F6FC;padding-left:16px;">上传时间</div> <div style="width: 136px;height: 56px;line-height: 56px;background: #FFFFFF;border: 1px solid #F0F6FC;padding-left:16px;">上传时间</div>
<div style="width: 342px;height: 56px;line-height: 56px;border: 1px solid #F0F6FC;padding-left:16px;">{{techerDetail?.uploadTime}}</div> <div style="width: 342px;height: 56px;line-height: 56px;border: 1px solid #F0F6FC;padding-left:16px;">{{techerDetail?.uploadTime}}</div>
@@ -1283,12 +1299,12 @@ const vwtext = ref(null)
<div style='font-size: 18px;font-weight: 500;margin-top: 39px;'> <div style='font-size: 18px;font-weight: 500;margin-top: 39px;'>
认证流程 认证流程
</div> </div>
<div style="margin-top: 13px; height: 125px;width: 100%;display: flex;align-items: center;justify-content: center;" > <div style="margin-top: 13px; height: 125px;width: 100%;display: flex;margin-left: 44px;" >
<div class="step_box" v-for="(item,index) in attestation" :key="index"> <div class="step_box" v-for="(item,index) in attestation" :key="index">
<div v-if="index != 0" style="height: 1px;width: 81px;background-color: #DEDEDE;"></div> <div v-if="index != 0" style="height: 2px;width: 81px;background-color: #DEDEDE;margin-top: -30px;"></div>
<div style="display: flex;width: 70px;height: 78px;flex-direction: column;align-items: center"> <div style="display: flex;min-width: 70px;height: 78px;flex-direction: column;align-items: center">
<img style="width: 46px;height: 46px;" :src="require(`../../assets/images/gratefulteacher/${item.images[item.status]}`)" alt=""> <img style="width: 46px;height: 46px;margin-bottom: 12px;" :src="require(`../../assets/images/gratefulteacher/${item.images[item.status]}`)" alt="">
<div style="color: #409EFF;font-size: 14px;">{{item.name[item.status]}}</div> <div style="font-size: 14px;" :style="{color:['#3DA8F0','#DEDEDE','#FF4040','#31AF0D'][item.status]}">{{item.name[item.status]}}</div>
</div> </div>
</div> </div>
</div> </div>
@@ -1482,7 +1498,7 @@ const vwtext = ref(null)
align-items: center; align-items: center;
flex-shrink: 0; flex-shrink: 0;
// background-color: red; // background-color: red;
margin-bottom: 20px; margin-bottom: 58px;
.headerTitle { .headerTitle {
font-size: 18px; font-size: 18px;

View File

@@ -67,7 +67,7 @@
:columns="columns" :columns="columns"
:data-source="datalist" :data-source="datalist"
:pagination="stuPagination" :pagination="stuPagination"
:loading="loading" :loading="loadings"
row-key="id" row-key="id"
> >
<template #action="{ record }"> <template #action="{ record }">
@@ -89,7 +89,7 @@
</a-table> </a-table>
</div> </div>
</div> </div>
<div class="btn" style="display: flex;justify-content: center;margin-top: 200px"> <div class="btn_footer">
<button class="btn2" @click="closeDrawer" style="cursor: pointer;border: none; margin-right: 15px;height: 38px; width: 100px;background: #4ea6ff; line-height: 38px;text-align: center;border-radius: 8px;color: #ffffff;">取消</button> <button class="btn2" @click="closeDrawer" style="cursor: pointer;border: none; margin-right: 15px;height: 38px; width: 100px;background: #4ea6ff; line-height: 38px;text-align: center;border-radius: 8px;color: #ffffff;">取消</button>
<button class="btn2" @click="closeDrawer" style=" cursor: pointer;border: none;height: 38px; width: 100px;background: #4ea6ff; line-height: 38px;text-align: center;border-radius: 8px;color: #ffffff;">确定</button> <button class="btn2" @click="closeDrawer" style=" cursor: pointer;border: none;height: 38px; width: 100px;background: #4ea6ff; line-height: 38px;text-align: center;border-radius: 8px;color: #ffffff;">确定</button>
</div> </div>
@@ -156,21 +156,30 @@ import { message } from "ant-design-vue";
type: Array, type: Array,
default: () => [], default: () => [],
}, },
searchTrue:{
type: String,
default:false
}
}); });
const datalist = ref([]) const datalist = ref([])
const getData = async ()=>{ const getData = async ()=>{
const res = await removePermission({ loadings.value = true
"examineId": props.id await removePermission({
"examineId": props.id,
pageNo: searchParams.value.pageNo,
pageSize: searchParams.value.pageSize,
}).then(res=>{
console.log(res,'权限列表');
datalist.value = res.data.records
total.value = res.data.total
loadings.value = false
}) })
console.log(res,'权限列表');
datalist.value = res.data.records
} }
onMounted(()=>{ onMounted(()=>{
getData() getData()
}) })
const visiable = ref(false); const visiable = ref(false);
const total = ref(0)
const initParams = { const initParams = {
studentName: "", studentName: "",
pageNo: 1, pageNo: 1,
@@ -218,7 +227,7 @@ import { message } from "ant-design-vue";
({ ({
0: "查看权", 0: "查看权",
1: "管理权", 1: "管理权",
2: "归属权", 2: "管理权",
7: "查看权", 7: "查看权",
8: "管理权", 8: "管理权",
9: "归属权", 9: "归属权",
@@ -237,14 +246,13 @@ import { message } from "ant-design-vue";
}, },
]); ]);
const { // const {
data: studentList, // data: studentList,
fetch: searchStu, // fetch: searchStu,
total, // total,
loading, // loading,
} = usePage(STUDENT_LIST, searchParams); // } = usePage(STUDENT_LIST, searchParams);
// const { loading: stuAsyncLoading } = useAsyncStu(props.id, props.types.join(","), searchStu);
const { loading: stuAsyncLoading } = useAsyncStu(props.id, props.types.join(","), searchStu);
const stuPagination = computed(() => ({ const stuPagination = computed(() => ({
@@ -260,15 +268,24 @@ import { message } from "ant-design-vue";
}; };
const changePagination = (page) => { const changePagination = (page) => {
console.log(page,'page')
searchParams.value.pageNo = page; searchParams.value.pageNo = page;
getData()
}; };
const loadings = ref(false)
const search = async()=>{ const search = async()=>{
const res = await removePermission({ loadings.value = true
searchParams.value.pageNo = 1;
await removePermission({
"examineId": props.id, "examineId": props.id,
"name" : searchName.value "name" : searchName.value,
pageNo: 1,
pageSize: 10
}).then(res => {
loadings.value = false
datalist.value = res.data.records
total.value = res.data.total
}) })
datalist.value = res.data.records
} }
// function search() { // function search() {
// searchParams.value.studentName = searchName.value; // searchParams.value.studentName = searchName.value;
@@ -324,14 +341,15 @@ import { message } from "ant-design-vue";
// searchStu() // searchStu()
// } // }
watch(visiable, () => { watch(visiable, (val) => {
visiable.value && searchStu(); if(val){
searchParams.value = initParams; getData()
}
}); });
defineExpose({ defineExpose({
searchStu, // searchStu,
loading, // loading,
}); });
</script> </script>
<style lang="scss"> <style lang="scss">
@@ -589,6 +607,10 @@ import { message } from "ant-design-vue";
} }
} }
} }
.btn_footer{
display: flex;
justify-content: center;
}
.deleteModal1 { .deleteModal1 {
.ant-modal { .ant-modal {
width: 424px !important; width: 424px !important;
@@ -718,4 +740,5 @@ import { message } from "ant-design-vue";
} }
} }
} }
</style> </style>

View File

@@ -163,6 +163,10 @@
<span>任务列表</span> <span>任务列表</span>
</div> </div>
<div class="tit_right"> <div class="tit_right">
<div style="margin-right: 14px">
<span style="margin-right: 8px" :style="{color: switchList ? '#4ea6ff' : '#ffb64e'}">{{switchList?'自由学习模式':'顺序学习模式'}}</span>
<a-switch v-model:checked="switchList" />
</div>
<div class="btn btn1" @click="showChangeModal"> <div class="btn btn1" @click="showChangeModal">
<div class="btnText">移动任务到关卡</div> <div class="btnText">移动任务到关卡</div>
</div> </div>
@@ -547,7 +551,7 @@ function deleteTask(element, index) {
}, },
}); });
} }
const switchList = ref(false)
const showChangeModal = () => { const showChangeModal = () => {
if (routerInfo.value?.chapterList?.length <= 1) { if (routerInfo.value?.chapterList?.length <= 1) {
message.warning("请添加关卡!"); message.warning("请添加关卡!");

View File

@@ -119,6 +119,10 @@
<div class="boomcen"> <div class="boomcen">
<div class="onerow"> <div class="onerow">
<div class="taskmain">任务列表</div> <div class="taskmain">任务列表</div>
<div class="taskmain_switch">
<span class="taskmain_switch_text" :style="{color: projectInfo?.projectInfo?.unlockMode == 1 ? '#4ea6ff' : '#ffb64e'}">{{projectInfo?.projectInfo?.unlockMode == 1 ?'自由学习模式':'顺序学习模式'}}</span>
<a-switch v-model:checked="switchList" />
</div>
<button class="btn" @click="showChangeModal"> <button class="btn" @click="showChangeModal">
移动任务到阶段 移动任务到阶段
</button> </button>
@@ -418,7 +422,7 @@ import {TASK_TYPE} from "@/utils/const";
import {request} from "@/api/request"; import {request} from "@/api/request";
import {PROJECT_DETAIL_MODIFY, PROJECT_RELEASE} from "@/api/apis"; import {PROJECT_DETAIL_MODIFY, PROJECT_RELEASE} from "@/api/apis";
import dialog from "@/utils/dialog"; import dialog from "@/utils/dialog";
import { editProjectModel } from "@/api/indexLearningPath";
const route = useRoute(); const route = useRoute();
const courseRef = ref({}) const courseRef = ref({})
const visiblene = ref(false); const visiblene = ref(false);
@@ -460,6 +464,7 @@ function changeStageIndex(index) {
const getTask = async () => { const getTask = async () => {
await api.getDraftTask({projectId: route.query.projectId}).then((res) => { await api.getDraftTask({projectId: route.query.projectId}).then((res) => {
projectInfo.value = res.data.data projectInfo.value = res.data.data
projectInfo.value.projectInfo.unlockMode == 1 ? switchList.value = true : switchList.value = false
console.log("获取任务列表:" + JSON.stringify(projectInfo.value) ) console.log("获取任务列表:" + JSON.stringify(projectInfo.value) )
}); });
}; };
@@ -467,7 +472,11 @@ const getTask = async () => {
const editTaskForType = (ele, index) => { const editTaskForType = (ele, index) => {
courseRef.value['el' + ele.type].openDrawer(index, ele) courseRef.value['el' + ele.type].openDrawer(index, ele)
}; };
const switchList = ref(false)
watch(()=>switchList.value,(newVal)=>{
newVal ? projectInfo.value.projectInfo.unlockMode = 1 : projectInfo.value.projectInfo.unlockMode = 2
editProjectModel(projectInfo.value.projectInfo)
})
const showChangeModal = () => { const showChangeModal = () => {
if (projectInfo.value?.stageList?.length <= 1) { if (projectInfo.value?.stageList?.length <= 1) {
message.warning("请添加阶段!"); message.warning("请添加阶段!");
@@ -1420,6 +1429,21 @@ const openCourse = (ele) => {
color: #000000; color: #000000;
margin-top: 10px; margin-top: 10px;
} }
.taskmain_switch{
position: absolute;
top: 0;
right: 268px;
width: 150px;
height: 40px;
border-radius: 8px;
cursor: pointer;
text-align: center;
line-height: 40px;
.taskmain_switch_text{
margin-right: 10px;
}
}
.btn { .btn {
position: absolute; position: absolute;

View File

@@ -827,6 +827,7 @@
:stage="stage" :stage="stage"
:visable="tabFlag" :visable="tabFlag"
:groupList="groupList" :groupList="groupList"
:remarksTrue="remarksTrue"
> >
<template #extension="{ data: { record } }"> <template #extension="{ data: { record } }">
<a-button @click="showStudent(record)" type="link" <a-button @click="showStudent(record)" type="link"
@@ -845,6 +846,11 @@
@click="showChangeGroupModal(record)" @click="showChangeGroupModal(record)"
>换组 >换组
</a-button> </a-button>
<a-button
type="link"
@click="modifyRemarks(record)"
>修改备注
</a-button>
</template> </template>
</TableStudent> </TableStudent>
</a-tab-pane> </a-tab-pane>
@@ -2347,6 +2353,43 @@
<!-- 换组弹窗 --> <!-- 换组弹窗 -->
<!-- 面授课开课弹框 --> <!-- 面授课开课弹框 -->
<AddOpenCourse @call-parent-method="getTaskListAll" ref="coursePlanRef" :type="1"/> <AddOpenCourse @call-parent-method="getTaskListAll" ref="coursePlanRef" :type="1"/>
<!-- 修改备注弹窗 -->
<a-modal
v-model:visible="showRemarks"
:footer="null"
closable="false"
style="margin-top: 400px"
@cancel="of_remarks"
>
<div class="selectonlineface" :style="{ display: showRemarks ? 'block' : 'none' }">
<div class="bg_headers"></div>
<div class="bg_main">
<div class="bg_main_header">
<div>修改备注</div>
<div class="bg_main_header_close" @click="of_remarks"></div>
</div>
<div class="bg_body">
<div class="bg_body_bt" style="align-items: flex-start;">
<!-- <div class="bg_body_bttext" style="margin-top: 5px;">修改备注</div> -->
<div class="bg_body_input">
<a-input v-model:value="remarks" placeholder="请输入" />
</div>
</div>
<div class="bg_footer">
<div class="btn btn6" @click="of_remarks">
<div class="btnText">取消</div>
</div>
<a-button
class="btn btn6"
@click="RemarksUpdata"
>
确定
</a-button>
</div>
</div>
</div>
</div>
</a-modal>
</div> </div>
</template> </template>
<script lang="jsx"> <script lang="jsx">
@@ -2603,11 +2646,11 @@ export default {
ellipsis: true, ellipsis: true,
customRender: ({ record }) => ( customRender: ({ record }) => (
<div> <div>
{record.finishTaskNum == 0 {record.stuStatus == 2
? "未开始" ? "进行中"
: record.finishTaskNum == record.totalTaskNum : record.status == 1
? "已完成" ? "已完成"
: "进行中"} : "未开始"}
</div> </div>
), ),
}, },
@@ -2620,6 +2663,15 @@ export default {
className: "h", className: "h",
ellipsis: true, ellipsis: true,
}, },
{
title: "备注",
dataIndex: "batch",
key: "batch",
width: 120,
align: "center",
className: "h",
ellipsis: true,
},
], ],
loading: false, loading: false,
projectId: route.query.projectId, projectId: route.query.projectId,
@@ -3038,6 +3090,10 @@ export default {
facestudent: {}, facestudent: {},
modal1Visible: false, // 证书预览 modal1Visible: false, // 证书预览
changegroupV: false, //换组弹窗 changegroupV: false, //换组弹窗
remarks: '',
remarksId: '',
remarksTrue: false,
showRemarks: false, //修改备注
checkgroupStuId: null, //换组id checkgroupStuId: null, //换组id
ImpoterGroupLeaderV: false, //导入小组长抽屉 ImpoterGroupLeaderV: false, //导入小组长抽屉
certificatelist: [], certificatelist: [],
@@ -3394,6 +3450,26 @@ export default {
state.checkgroupStuId = []; state.checkgroupStuId = [];
state.checkgroupStuId.push(record.id); state.checkgroupStuId.push(record.id);
}; };
//修改备注
const modifyRemarks = (record) => {
state.remarks = record.batch
state.remarksId = record.id
state.showRemarks = true;
}
const of_remarks = () => {
state.remarksTrue = false;
state.showRemarks = false;
}
const RemarksUpdata = () => {
apitl.editStudent({
id: state.remarksId,
batch: state.remarks
}).then(res=>{
console.log(res,'res')
state.remarksTrue = true;
})
of_remarks()
}
const showModal2 = (item, isEdit) => { const showModal2 = (item, isEdit) => {
state.isEdit = isEdit; state.isEdit = isEdit;
state.stugroup = true; state.stugroup = true;
@@ -5183,6 +5259,9 @@ export default {
cancelyou, cancelyou,
cancelcanyou, cancelcanyou,
showChangeGroupModal, showChangeGroupModal,
modifyRemarks,
of_remarks,
RemarksUpdata,
changePaginationStu, changePaginationStu,
handleChange, handleChange,
toEdit, toEdit,
@@ -6083,7 +6162,113 @@ export default {
} }
} }
} }
.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(
rgba(78, 166, 255, 0.2) 0%,
rgba(78, 166, 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_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: 3px auto;
.bg_body_bt {
display: flex;
align-items: center;
justify-content: end;
margin: 14px auto;
.bg_body_bttext {
width: 110px;
display: flex;
justify-content: end;
margin-right: 20px;
}
}
.bg_body_input {
flex: 1;
position: relative;
.ant-upload-picture-card-wrapper{
width: 200px;
margin-right: 18px;
}
}
.bg_footer {
width: 100%;
margin-left: 174px;
margin-top: 25px;
margin-bottom: 20px;
display: flex;
.btn {
width: 100px;
height: 40px;
background: rgba(64, 158, 255, 0);
border-radius: 8px;
display: flex;
align-items: center;
justify-content: center;
margin-right: 14px;
flex-shrink: 0;
cursor: pointer;
.btnText {
font-size: 14px;
font-weight: 400;
line-height: 40px;
}
}
.btn6 {
background-color: #4ea6ff;
color: #ffffff;
}
}
}
.headers{
margin-left: 38px;
margin-right: 38px;
margin-top: 30px;
display: flex;
justify-content: space-between;
flex-wrap: wrap;
.btn{
display: flex;
}
}
}
}
.taskpage { .taskpage {
width: 100%; width: 100%;
display: flex; display: flex;

View File

@@ -0,0 +1,75 @@
<template>
<div class="train_newman">
<div class="title">新任管理者线下学习项目定制报表</div>
<div class="btn" @click="downReport" v-if="uploadAdmin('training-admin')||adminType?.length>0">
<div class="img"></div>
<div class="text">报表下载</div>
</div>
</div>
</template>
<script setup>
import { computed,onMounted,ref } from "vue";
import { useStore } from "vuex";
import { reportOrgs } from "@/api/indexProject";
import {downLoadZipManage} from "@/utils/zipdownload";
const downReport = () => {
console.log('下载报表')
if(uploadAdmin('training-admin')){
downLoadZipManage(`/admin/project/report/data`,'新任管理者培训数据')
return
}
if(adminType?.value.length>0){
let orgs = adminType.value.join(',')
downLoadZipManage(`/admin/project/report/data?orgs=${orgs}`,'新任管理者培训数据')
}
}
const userInfo = computed(() => store.state.userInfo);
onMounted(()=>{
getReportOrgs()
})
const store = useStore();
const adminType = ref()
const getReportOrgs = () => {
reportOrgs({workNum: userInfo.value.userNo}).then((res) => {
console.log(res,'res')
adminType.value = res.data
});
};
const uploadAdmin = (admin)=>{
const roleCode = userInfo.value.roleList.map((item)=>item.roleCode)
if (admin){
return roleCode.some(t => t == admin)
}
}
</script>
<style lang="scss" scoped>
.train_newman{
margin: 40px 0 0 50px;
.title{
color: #000000;
margin-bottom: 16px;
}
.btn {
cursor: pointer;
width: 130px;
height: 40px;
border-radius: 8px;
display: flex;
justify-content: center;
align-items: center;
background: #4ea6ff;
.img {
width: 17px;
height: 16px;
background-image: url(../../assets/images/coursewareManage/export1.png);
background-size: 100% 100%;
margin-right: 7px;
}
.text{
color: #ffffff;
}
}
}
</style>