mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/fe-manage.git
synced 2025-12-17 06:46:46 +08:00
Merge branch 'new_1205_bug' into zcwy-teacher-manage
This commit is contained in:
@@ -574,7 +574,7 @@
|
||||
{
|
||||
name: "感恩教师",
|
||||
}, {
|
||||
name:'认证讲师库(2023)'
|
||||
name:'认证讲师库'
|
||||
}
|
||||
];
|
||||
}
|
||||
|
||||
@@ -394,7 +394,7 @@
|
||||
circle: selectedKeys[0] === 'sub22-4' ? false : true,
|
||||
}"
|
||||
></span>
|
||||
<router-link to="/teachertopic">认证讲师库(2023)</router-link>
|
||||
<router-link to="/teachertopic">认证讲师库</router-link>
|
||||
</a-menu-item>
|
||||
<a-menu-item key="sub22-5" v-if="checkMenu('tooldown')">
|
||||
<span
|
||||
@@ -994,7 +994,7 @@ export default {
|
||||
href: "/teachertopic",
|
||||
openKeys: "sub22",
|
||||
selectedKeys: "sub22-4",
|
||||
pagename: "认证讲师库(2023)",
|
||||
pagename: "认证讲师库",
|
||||
},
|
||||
{
|
||||
href: "/tooldown",
|
||||
|
||||
342
src/components/TwoDimensionalCodeNew.vue
Normal file
342
src/components/TwoDimensionalCodeNew.vue
Normal file
@@ -0,0 +1,342 @@
|
||||
<template>
|
||||
<div class="twoDimensionalCode">
|
||||
<!--二维码页面 -->
|
||||
<a-modal
|
||||
:visible="codevisible"
|
||||
:footer="null"
|
||||
:closable="closableQR"
|
||||
wrapClassName="codeModal"
|
||||
style="margin-top: 400px"
|
||||
:zIndex="9999"
|
||||
@cancel="qr_exit"
|
||||
>
|
||||
<div id="qrcode" class="QR">
|
||||
<div class="qr_header"></div>
|
||||
<div class="qr_main">
|
||||
<div class="qrm_header">
|
||||
<span style="title">{{
|
||||
codeInfo.title ? codeInfo.title : ""
|
||||
}}</span>
|
||||
<div class="close_exit" @click="closeCodeModal"></div>
|
||||
</div>
|
||||
<div class="downloadCode" style="">
|
||||
<div class="qrm_body">
|
||||
<div :class="codeInfo.teacherName?'qrm_body_item':''">
|
||||
<div v-if="codeInfo.name&&!codeInfo.teacherName" class="codename">
|
||||
{{ codeInfo.name ? codeInfo.name : "" }}
|
||||
</div>
|
||||
<div v-if="codeInfo.name&&codeInfo.teacherName" class="codename" :title="codeInfo.name">
|
||||
开课:{{ codeInfo.name ? codeInfo.name : "" }}
|
||||
</div>
|
||||
<div v-if="codeInfo.teacherName" class="codename" :title="codeInfo.titleTeacherName">
|
||||
讲师:{{ codeInfo.teacherName ? codeInfo.teacherName : "" }}
|
||||
</div>
|
||||
</div>
|
||||
<qrcode-vue
|
||||
:value="codeInfo.url.startsWith('/')?(`${domain+codeInfo.url}&t=10`):`${codeInfo.url}&t=10`"
|
||||
:size="qrcodeSize"
|
||||
style="width: 200px; height: 200px"
|
||||
></qrcode-vue>
|
||||
</div>
|
||||
</div>
|
||||
<div class="codeUrl" :style="{ display: showUrl ? 'flex' : 'none' }">
|
||||
<div class="codeUrlLink">链接</div>
|
||||
<a-input
|
||||
:value="codeInfo.url.startsWith('/')?`${domain+codeInfo.url}&t=10`:`${codeInfo.url}&t=10`"
|
||||
disabled
|
||||
class="codeUrlInp"
|
||||
/>
|
||||
<a-input
|
||||
:value="codeInfo.url.startsWith('/')?`${domain+codeInfo.url}&t=10`:`${codeInfo.url}&t=10`"
|
||||
id="courseUrl"
|
||||
class="codeUrlInp"
|
||||
style="position: absolute; opacity: 0; z-index: -1"
|
||||
/>
|
||||
<div @click="copyUrl" class="codeUrlCopy">复制链接</div>
|
||||
</div>
|
||||
<div class="qrm_footer">
|
||||
<span
|
||||
style="color: #387df7; cursor: pointer"
|
||||
@click="downloadQr(200)"
|
||||
>下载二维码</span
|
||||
>
|
||||
<!-- <div class="qrmbtn" @click="downloadQr(200)">
|
||||
<div class="btntext">200*200</div>
|
||||
</div> -->
|
||||
<!-- <div class="qrmbtn" @click="downloadQr(200)">
|
||||
<div class="btntext">400*400</div>
|
||||
</div>
|
||||
<div class="qrmbtn" @click="downloadQr(200)">
|
||||
<div class="btntext">800*800</div>
|
||||
</div> -->
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</a-modal>
|
||||
<!--二维码页面 -->
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import { reactive, toRefs, watch } from "vue";
|
||||
import QrcodeVue from "qrcode.vue";
|
||||
import html2canvas from "html2canvas";
|
||||
import { message } from "ant-design-vue";
|
||||
export default {
|
||||
name: "TwoDimensionalCode",
|
||||
components: {
|
||||
QrcodeVue,
|
||||
},
|
||||
props: {
|
||||
codevisible: {
|
||||
type: Boolean,
|
||||
default: false,
|
||||
},
|
||||
codeInfo: {
|
||||
type: Object,
|
||||
default: function () {
|
||||
return {};
|
||||
},
|
||||
},
|
||||
index: {
|
||||
type: String,
|
||||
default: "",
|
||||
},
|
||||
type: {
|
||||
type: String,
|
||||
default: "",
|
||||
},
|
||||
},
|
||||
setup(props, ctx) {
|
||||
const state = reactive({
|
||||
qrcodeSize: 800,
|
||||
codeInfo: {},
|
||||
courseUrl: "https://www.baidu.com/",
|
||||
showUrl: false,
|
||||
domain: location.protocol+'//'+location.host
|
||||
});
|
||||
|
||||
//下载二维码图片
|
||||
const downloadQr = (num) => {
|
||||
state.qrcodeSize = num;
|
||||
html2canvas(
|
||||
document.querySelectorAll(".downloadCode")[Number(props.index)],
|
||||
{
|
||||
useCORS: true, //支持图片跨域
|
||||
}
|
||||
).then((canvas) => {
|
||||
// console.log("canvas", canvas, canvas.width, canvas.style.width);
|
||||
let filename = `${new Date().getTime()}.png`;
|
||||
let imageUrl = canvas.toDataURL("image/png");
|
||||
let a = document.createElement("a");
|
||||
a.style.display = "none";
|
||||
a.download = filename;
|
||||
a.href = imageUrl;
|
||||
document.body.appendChild(a);
|
||||
a.click();
|
||||
});
|
||||
// let canvas =document.getElementsByClassName('codeModal')[Number(props.index)].getElementsByTagName('canvas')[0];
|
||||
// let filename = `${new Date().getTime()}.png`;
|
||||
// let imageUrl = canvas.toDataURL("image/png");
|
||||
// let a = document.createElement("a");
|
||||
// a.style.display = "none";
|
||||
// a.download = filename;
|
||||
// a.href = imageUrl;
|
||||
// document.body.appendChild(a);
|
||||
// a.click();
|
||||
};
|
||||
//复制链接
|
||||
const copyUrl = () => {
|
||||
// const range = document.createRange(); //创建range对象
|
||||
// range.selectNode(document.getElementById('courseUrl')); //获取复制内容的 id 选择器
|
||||
// const selection = window.getSelection(); //创建 selection对象
|
||||
// if (selection.rangeCount > 0) selection.removeAllRanges(); //如果页面已经有选取了的话,会自动删除这个选区,没有选区的话,会把这个选取加入选区
|
||||
// selection.addRange(range); //将range对象添加到selection选区当中,会高亮文本块
|
||||
// document.execCommand("Copy"); //复制选中的文字到剪贴板
|
||||
// message.success('复制成功')
|
||||
// selection.removeRange(range); // 移除选中的元素
|
||||
|
||||
var input = document.createElement("input"); // 创建input对象
|
||||
input.value = state.codeInfo.url.startsWith('/')?(state.domain+state.codeInfo.url):state.codeInfo.url; // 设置复制内容
|
||||
document.body.appendChild(input); // 添加临时实例
|
||||
input.select(); // 选择实例内容
|
||||
document.execCommand("Copy"); // 执行复制
|
||||
document.body.removeChild(input); // 删除临时实例
|
||||
message.success("复制成功!");
|
||||
};
|
||||
const closeCodeModal = () => {
|
||||
ctx.emit("update:codevisible", false);
|
||||
};
|
||||
watch(() => {
|
||||
let obj = {
|
||||
title: "",
|
||||
name: "",
|
||||
url: "",
|
||||
teacherName: "",
|
||||
};
|
||||
state.codeInfo = Object.assign(obj, props.codeInfo);
|
||||
console.log("codeInfo22222", state.codeInfo, props.index, props.type);
|
||||
|
||||
if (props.type === "签到二维码"|| props.type === "评估二维码") {
|
||||
state.showUrl = false;
|
||||
console.log(" state.showUrl", state.showUrl);
|
||||
} else if (props.type === "课程二维码") {
|
||||
state.showUrl = true;
|
||||
}
|
||||
});
|
||||
return {
|
||||
...toRefs(state),
|
||||
downloadQr,
|
||||
closeCodeModal,
|
||||
copyUrl,
|
||||
};
|
||||
},
|
||||
};
|
||||
</script>
|
||||
<style scoped lang="scss">
|
||||
.twoDimensionalCode {
|
||||
}
|
||||
.codeModal {
|
||||
.ant-modal {
|
||||
.ant-modal-content {
|
||||
width: 479px !important;
|
||||
.ant-modal-body {
|
||||
.QR {
|
||||
z-index: 9999;
|
||||
width: 520px;
|
||||
background: #ffffff;
|
||||
box-shadow: 0px 1px 35px 0px rgba(118, 136, 166, 0.21);
|
||||
position: absolute;
|
||||
left: 50%;
|
||||
top: 10%;
|
||||
transform: translate(-50%, -50%);
|
||||
.qr_header {
|
||||
position: absolute;
|
||||
width: calc(100%);
|
||||
height: 40px;
|
||||
background: linear-gradient(
|
||||
rgba(78, 166, 255, 0.2) 0%,
|
||||
rgba(78, 166, 255, 0) 100%
|
||||
);
|
||||
}
|
||||
.qr_main {
|
||||
width: 100%;
|
||||
position: relative;
|
||||
.qrm_header {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
padding-top: 20px;
|
||||
padding-left: 26px;
|
||||
font-size: 16px;
|
||||
.title {
|
||||
font-size: 16px;
|
||||
font-weight: 600;
|
||||
color: #333333;
|
||||
line-height: 22px;
|
||||
}
|
||||
.close_exit {
|
||||
position: absolute;
|
||||
right: 42px;
|
||||
cursor: pointer;
|
||||
width: 20px;
|
||||
height: 20px;
|
||||
background-image: url(@/assets/images/coursewareManage/close.png);
|
||||
background-size: 100% 100%;
|
||||
}
|
||||
}
|
||||
.qrm_body {
|
||||
width: 100%;
|
||||
padding-top: 22px;
|
||||
padding-bottom: 32px;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
.qrm_body_item{
|
||||
width: 100%;
|
||||
margin-left: 270px;
|
||||
}
|
||||
.codename {
|
||||
font-size: 18px;
|
||||
font-weight: 400;
|
||||
color: #333333;
|
||||
line-height: 25px;
|
||||
margin-bottom: 20px;
|
||||
margin-left: 20px;
|
||||
margin-right: 20px;
|
||||
overflow: hidden;
|
||||
white-space: nowrap;
|
||||
text-overflow: ellipsis;
|
||||
max-width: 300px;
|
||||
}
|
||||
}
|
||||
.codeUrl {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
margin-bottom: 24px;
|
||||
.codeUrlLink {
|
||||
width: 72px;
|
||||
height: 40px;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
font-size: 14px;
|
||||
font-weight: 400;
|
||||
color: #c7cbd2;
|
||||
line-height: 20px;
|
||||
border: 1px solid #c7cbd2;
|
||||
border-right: 0px solid #c7cbd2;
|
||||
}
|
||||
.codeUrlInp {
|
||||
width: 305px;
|
||||
height: 40px;
|
||||
border: 1px solid #c7cbd2;
|
||||
}
|
||||
.ant-input-disabled {
|
||||
background-color: rgba(0, 0, 0, 0) !important;
|
||||
}
|
||||
.ant-input[disabled] {
|
||||
background-color: rgba(0, 0, 0, 0) !important;
|
||||
}
|
||||
.codeUrlCopy {
|
||||
width: 96px;
|
||||
height: 40px;
|
||||
background-color: #4ea6ff;
|
||||
border-radius: 8px;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
font-size: 14px;
|
||||
font-weight: 400;
|
||||
color: #ffffff;
|
||||
line-height: 20px;
|
||||
cursor: pointer;
|
||||
margin-left: 8px;
|
||||
}
|
||||
}
|
||||
.qrm_footer {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
margin-bottom: 44px;
|
||||
.qrmbtn {
|
||||
width: 80px;
|
||||
height: 32px;
|
||||
display: flex;
|
||||
line-height: 32px;
|
||||
justify-content: center;
|
||||
border-radius: 4px;
|
||||
border: 1px solid #387df7;
|
||||
// margin-left: 16px;
|
||||
cursor: pointer;
|
||||
.btntext {
|
||||
color: #387df7;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
||||
@@ -487,20 +487,19 @@ const columns = ref([
|
||||
key: "teacher",
|
||||
width: "20%",
|
||||
align: "center",
|
||||
ellipsis: true,
|
||||
customRender: ({ record }) => {
|
||||
// const teachers = record.offteachers;
|
||||
// return teachers.map((teacher, index) => {
|
||||
// // 如果需要显示为列表形式
|
||||
// return (
|
||||
// <div key={index}>
|
||||
// {teacher.teacherName}
|
||||
// {index !== teachers.length - 1 && ', '}
|
||||
// </div>
|
||||
// );
|
||||
// });
|
||||
return record.offteachers.map(item=>item.teacherName).join(',')
|
||||
},
|
||||
// const teachers = record.offteachers;
|
||||
// return teachers.map((teacher, index) => {
|
||||
// // 如果需要显示为列表形式
|
||||
// return (
|
||||
// <div key={index}>
|
||||
// {teacher.teacherName}
|
||||
// {index !== teachers.length - 1 && ', '}
|
||||
// </div>
|
||||
// );
|
||||
// });
|
||||
return record.offteachers.map(item=>item.teacherName).join(',')
|
||||
},
|
||||
|
||||
},
|
||||
{
|
||||
|
||||
@@ -442,10 +442,6 @@ export default {
|
||||
|
||||
{/* 导出数据 */ }
|
||||
function exportData() {
|
||||
if(state.tabledata.length==0){
|
||||
message.error("没有数据可以导出");
|
||||
return
|
||||
}
|
||||
// window.open(`${process.env.VUE_APP_BASE_API}/admin/exam/manage/exportExam?chapterId=${props.datasource.chapterId}&targetId=${props.datasource.routerId}&taskId=${props.datasource.courseId}&type=${1}`)
|
||||
window.open(`${process.env.VUE_APP_BASE_API}/admin/exam/manage/exportExam?currentStageId=${props.datasource.chapterId}&type=${1}&pid=${props.datasource.routerId}&targetId=${props.datasource.routerId}&taskId=${props.datasource.courseId}&taskType=${props.datasource.type}`)
|
||||
|
||||
|
||||
@@ -71,6 +71,7 @@ const rulesRef = ref({
|
||||
Form.useForm(modelV, rulesRef, { debounce: { wait: 800 } });
|
||||
|
||||
onMounted(() => {
|
||||
validateValue()
|
||||
if(props.onceName==modelV.value.value){
|
||||
isExistName.value = false;
|
||||
}else{
|
||||
@@ -90,10 +91,11 @@ watch(props, () => {
|
||||
watch(() => modelV.value.value, () => {
|
||||
emit("update:validated", 1);
|
||||
emit("update:value", modelV.value.value);
|
||||
});
|
||||
},{immediate: true});
|
||||
|
||||
async function validateValue() {
|
||||
if (!modelV.value.value) {
|
||||
emit("update:validated", 2);
|
||||
return Promise.reject("请输入名称");
|
||||
}
|
||||
return validateName({ name: modelV.value.value, type: props.type, id: props.id }).then(res => {
|
||||
|
||||
@@ -125,7 +125,16 @@ watch(() => modelV.value.value, () => {
|
||||
emit("update:validated", 1);
|
||||
emit("update:value", modelV.value.value);
|
||||
});
|
||||
|
||||
const timer = ref(null)
|
||||
watch(()=>props.validated, (val)=>{
|
||||
if(val===1){
|
||||
timer.value = setTimeout(() => {
|
||||
emit("update:validated", 2);
|
||||
}, 10000);
|
||||
}else{
|
||||
clearTimeout(timer.value)
|
||||
}
|
||||
})
|
||||
async function validateValue() {
|
||||
if (!modelV.value.value) {
|
||||
return Promise.reject("请输入名称");
|
||||
@@ -138,7 +147,10 @@ async function validateValue() {
|
||||
emit("update:validated", 2);
|
||||
return Promise.resolve();
|
||||
}
|
||||
);
|
||||
).catch(err => {
|
||||
emit("update:validated", 2);
|
||||
return Promise.resolve();
|
||||
})
|
||||
}
|
||||
</script>
|
||||
<style lang="scss">
|
||||
|
||||
56
src/components/project/ProjectNumber.vue
Normal file
56
src/components/project/ProjectNumber.vue
Normal file
@@ -0,0 +1,56 @@
|
||||
<template>
|
||||
<a-select
|
||||
:getPopupContainer="
|
||||
(triggerNode) => {
|
||||
return triggerNode.parentNode || document.body;
|
||||
}
|
||||
"
|
||||
v-model:value="numValue"
|
||||
style="width: 100%;"
|
||||
placeholder="请选择项目编号"
|
||||
:options="options"
|
||||
showSearch
|
||||
allowClear
|
||||
@change="handleChange"
|
||||
>
|
||||
</a-select>
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
import {computed, defineEmits, defineProps, onMounted, ref, watch} from 'vue';
|
||||
import { useStore } from "vuex";
|
||||
const props = defineProps({
|
||||
value: String,
|
||||
})
|
||||
const emit = defineEmits(['update:value'])
|
||||
const store = useStore();
|
||||
const numValue = computed(()=>store.state.project_number.find(item=>item.value == props.value)?.name || null)
|
||||
const handleChange = (value,option)=>{
|
||||
emit('update:value',option?.searchData || '')
|
||||
}
|
||||
onMounted(() => {
|
||||
// console.log(store.state.project_number,'store.state.project_number')
|
||||
});
|
||||
const options = computed(() => {
|
||||
const projectNumberList = store.state.project_number;
|
||||
const sortedList = projectNumberList.sort((a, b) => {
|
||||
if (a.sort !== b.sort) {
|
||||
return b.sort - a.sort;
|
||||
}
|
||||
const aTimestamp = Date.parse(a.createTime);
|
||||
const bTimestamp = Date.parse(b.createTime);
|
||||
return bTimestamp - aTimestamp;
|
||||
});
|
||||
return sortedList.map(e => ({
|
||||
value: e.value + e.name,
|
||||
label: ' 【 ' + e.value + ' 】 ' + e.name,
|
||||
searchData: e.value
|
||||
}));
|
||||
});
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
::v-deep .ant-select-selector{
|
||||
border-radius: 8px !important;
|
||||
}
|
||||
</style>
|
||||
@@ -500,13 +500,21 @@ const audiColums = ref([
|
||||
ellipsis: true,
|
||||
},
|
||||
{
|
||||
title: "人数",
|
||||
title: "总人数",
|
||||
dataIndex: "totalMember",
|
||||
key: "totalMember",
|
||||
width: 30,
|
||||
align: "center",
|
||||
className: "h",
|
||||
},
|
||||
{
|
||||
title: "在职人数",
|
||||
dataIndex: "workMember",
|
||||
key: "workMember",
|
||||
width: 30,
|
||||
align: "center",
|
||||
className: "h",
|
||||
},
|
||||
]);
|
||||
const orgSelectKeys = ref([]);
|
||||
const auditTableRef = ref();
|
||||
@@ -612,7 +620,7 @@ const submitAuth = () => {
|
||||
|
||||
function handleDialogOk() {
|
||||
if (auditSelectRowKeys.value.length || deptList.value.length) {
|
||||
dialog({ content: "您选择了组织或受众,此添加为异步添加,请稍后手动刷新学员!", ok: handleStageOk });
|
||||
dialog({ content: "您选择了组织或受众,此添加为异步添加,请稍后手动刷新学员!(本次添加只添加在职人员)", ok: handleStageOk });
|
||||
return;
|
||||
}
|
||||
handleStageOk();
|
||||
|
||||
@@ -91,6 +91,11 @@
|
||||
导出
|
||||
</a-button>
|
||||
</a-col>
|
||||
<a-col>
|
||||
<a-button class="cus-btn" style="background: #4ea6ff; color: #fff; width: 150px" @click="exportStudy">
|
||||
导出详细学习记录
|
||||
</a-button>
|
||||
</a-col>
|
||||
</a-row>
|
||||
<div style="margin-top: 20px">
|
||||
<a-table
|
||||
@@ -121,7 +126,8 @@ import dialog from "@/utils/dialog";
|
||||
import {ONLINE_COURSE_DEL} from "@/api/ThirdApi";
|
||||
import {useStore} from "vuex";
|
||||
import {useAsyncStu, useResetRef} from "@/utils/useCommon";
|
||||
|
||||
import {downLoadXlsx} from "@/utils/zipdownload";
|
||||
import {message} from "ant-design-vue";
|
||||
const props = defineProps({
|
||||
permissions: {
|
||||
type: String,
|
||||
@@ -323,7 +329,12 @@ function reset() {
|
||||
function exportStu() {
|
||||
window.open(`${process.env.VUE_APP_BASE_API}/admin/student/exportOnlineStudent?type=3&&thirdType=8&pid=${searchParams.value.pid}`);
|
||||
}
|
||||
|
||||
function exportStudy() {
|
||||
if(studentList.value.length == 0){
|
||||
return message.warning('暂无可导出的学习记录')
|
||||
}
|
||||
downLoadXlsx(`${process.env.VUE_APP_BASE_API}/admin/student/exportOnlineStudentDetail?type=4&&thirdType=8&pid=${searchParams.value.pid}`,'在线课学员学习记录')
|
||||
}
|
||||
defineExpose({
|
||||
searchStu,
|
||||
loading,
|
||||
|
||||
@@ -196,7 +196,7 @@
|
||||
:data-source="tableData.list"
|
||||
:pagination="stuPagination"
|
||||
:loading="tableData.loading"
|
||||
:scroll="{ x: 1500 }"
|
||||
:scroll="{ x: 1350 }"
|
||||
row-key="id"
|
||||
:row-selection="stuRowSelection"
|
||||
>
|
||||
@@ -467,7 +467,7 @@ const tablecolumns = ref([
|
||||
title: "姓名",
|
||||
dataIndex: "studentName",
|
||||
key: "studentName",
|
||||
width: "10%",
|
||||
width: "80px",
|
||||
align: "left",
|
||||
className: "h",
|
||||
ellipsis: true,
|
||||
@@ -496,7 +496,7 @@ const tablecolumns = ref([
|
||||
title: "工号",
|
||||
dataIndex: "studentUserNo",
|
||||
key: "studentUserNo",
|
||||
width: "20%",
|
||||
width: "60px",
|
||||
align: "center",
|
||||
className: "h",
|
||||
ellipsis: true,
|
||||
@@ -505,12 +505,13 @@ const tablecolumns = ref([
|
||||
title: "部门",
|
||||
dataIndex: "studentDepartName",
|
||||
key: "studentDepartName",
|
||||
width: "15%",
|
||||
width: "120px",
|
||||
align: "center",
|
||||
className: "h",
|
||||
ellipsis: true,
|
||||
customCell :() => {return {style: {maxWidth: '200px',overflow: 'hidden',whiteSpace: 'nowrap',textOverflow:'ellipsis',cursor:'pointer'}}},
|
||||
customRender: ({ record: { studentOrgName, studentDepartName } }) =>
|
||||
allDepartShow(studentOrgName),
|
||||
// <a-tooltip color="white" placement="topLeft" title={allDepartShow(studentOrgName)} >{allDepartShow(studentOrgName)}</a-tooltip>
|
||||
<a-tooltip color="white" placement="topLeft" title={studentOrgName} >{studentDepartName}</a-tooltip>
|
||||
},
|
||||
{
|
||||
title: "所属小组",
|
||||
@@ -522,10 +523,10 @@ const tablecolumns = ref([
|
||||
ellipsis: true,
|
||||
},
|
||||
{
|
||||
title: "加入方式",
|
||||
title: "报名方式",
|
||||
dataIndex: "source",
|
||||
key: "source",
|
||||
width: "10%",
|
||||
width: "60px",
|
||||
align: "center",
|
||||
customRender: ({ record: { source } }) =>
|
||||
// ({ 1: "快速添加", 2: "组织", 3: "受众", 4: "报名" }[source]),
|
||||
@@ -535,8 +536,9 @@ const tablecolumns = ref([
|
||||
2: "手动加入",
|
||||
3: "手动加入",
|
||||
4: "导入",
|
||||
5: "报名",
|
||||
5: "自主报名",
|
||||
6: "导入",
|
||||
8: "扫码报名",
|
||||
}[source]),
|
||||
},
|
||||
...props.columns,
|
||||
@@ -544,7 +546,8 @@ const tablecolumns = ref([
|
||||
title: "操作",
|
||||
dataIndex: "operation",
|
||||
key: "operation",
|
||||
width: 260,
|
||||
width: '120px',
|
||||
fixed: "right",
|
||||
align: "center",
|
||||
slots: { customRender: "action" },
|
||||
},
|
||||
@@ -559,7 +562,10 @@ function allDepartShow(a, b) {
|
||||
: a;
|
||||
let depart = b == "" || b == null || b == undefined ? (b = "") : b;
|
||||
let allname = org == "" && depart == "" ? "-" : org + depart;
|
||||
return allname;
|
||||
const parts = allname.split('/');
|
||||
const reversedParts = parts.reverse();
|
||||
const reversedStr = reversedParts.join('/');
|
||||
return reversedStr;
|
||||
}
|
||||
|
||||
const tableParam = ref({
|
||||
@@ -618,7 +624,7 @@ function exportTaskStu() {
|
||||
window.open(
|
||||
`${
|
||||
process.env.VUE_APP_BASE_API
|
||||
}/admin/student/exportTaskStudent?type=${1}&pid=${props.id}`
|
||||
}/admin/student/exportTaskStudent?type=${1}&pid=${props.id}&studentName=${tableParam.value.studentName === null ?'':tableParam.value.studentName}&studentDepartName=${tableParam.value.studentDepartName===null?'':tableParam.value.studentDepartName}&topFlag=${tableParam.value.topFlag===null?'':tableParam.value.topFlag}`
|
||||
);
|
||||
}
|
||||
|
||||
@@ -858,7 +864,9 @@ const exportHomeWorkShow = () => {
|
||||
// message.success("导出作业成功");
|
||||
exportHomeWorkV.value = true;
|
||||
downloadUrl.value = res.data.data;
|
||||
});
|
||||
}).catch(err=>{
|
||||
// message.error(err.data.msg)
|
||||
})
|
||||
};
|
||||
// //导出作业
|
||||
// const exportHomeWork = () => {
|
||||
|
||||
Reference in New Issue
Block a user