mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/fe-manage.git
synced 2025-12-18 23:36:46 +08:00
讲师管理bug
This commit is contained in:
@@ -2,7 +2,7 @@
|
|||||||
<template>
|
<template>
|
||||||
<div>
|
<div>
|
||||||
<!-- 搜索框及按钮 -->
|
<!-- 搜索框及按钮 -->
|
||||||
<div class="filter" style="min-width: 1380px;">
|
<div class="filter" >
|
||||||
<a-form layout="inline">
|
<a-form layout="inline">
|
||||||
<a-form-item class="select">
|
<a-form-item class="select">
|
||||||
<!-- v-model:value="searchParam.name" -->
|
<!-- v-model:value="searchParam.name" -->
|
||||||
@@ -40,10 +40,10 @@
|
|||||||
<template #action="{ record, column }">
|
<template #action="{ record, column }">
|
||||||
<a-space >
|
<a-space >
|
||||||
<a-button type="link" @click="() => handleLook(record, String(record.courseform))">查看</a-button>
|
<a-button type="link" @click="() => handleLook(record, String(record.courseform))">查看</a-button>
|
||||||
<a-button type="link" v-if="record.isPermission==='true'||record.isSuperPermission==='true'" @click="() => handleModify(record, String(record.courseform))">编辑</a-button>
|
<a-button type="link" @click="() => handleModify(record, String(record.courseform))">编辑</a-button>
|
||||||
<a-button v-if="record.status == '1'&&(record.isPermission==='true'||record.isSuperPermission==='true')" type="link"
|
<a-button v-if="record.status == '1'" type="link"
|
||||||
@click="() => handleOperate(record, String(record.courseform))">停用</a-button>
|
@click="() => handleOperate(record, String(record.courseform))">停用</a-button>
|
||||||
<a-button v-if="record.status == '2'&&(record.isPermission==='true'||record.isSuperPermission==='true')" type="link"
|
<a-button v-if="record.status == '2'" type="link"
|
||||||
@click="() => handleOperate(record, String(record.courseform))">启用</a-button>
|
@click="() => handleOperate(record, String(record.courseform))">启用</a-button>
|
||||||
<a-button type="link" v-if="record.isSuperPermission==='true'" @click="() => deleteModal(record, String(record.courseform))"
|
<a-button type="link" v-if="record.isSuperPermission==='true'" @click="() => deleteModal(record, String(record.courseform))"
|
||||||
>删除</a-button>
|
>删除</a-button>
|
||||||
@@ -79,12 +79,13 @@
|
|||||||
<a-upload name="avatar" list-type="picture-card" class="avatar-uploader" :show-upload-list="false"
|
<a-upload name="avatar" list-type="picture-card" class="avatar-uploader" :show-upload-list="false"
|
||||||
:headers="headers" :before-upload="beforeUpload">
|
:headers="headers" :before-upload="beforeUpload">
|
||||||
<img class="i_upload_img" v-if="formParam.photo" :src="formParam.photo" alt="avatar" title="更换头像" />
|
<img class="i_upload_img" v-if="formParam.photo" :src="formParam.photo" alt="avatar" title="更换头像" />
|
||||||
<div class="i_upload" v-else>
|
<img class="i_upload_img" v-else src="../../assets/avatar.png" alt="avatar" title="更换头像" />
|
||||||
|
<!-- <div class="i_upload" v-else>
|
||||||
<div class="addimg">
|
<div class="addimg">
|
||||||
<div class="heng"></div>
|
<div class="heng"></div>
|
||||||
<div class="shu"></div>
|
<div class="shu"></div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div> -->
|
||||||
</a-upload>
|
</a-upload>
|
||||||
<div class="i_bottom">
|
<div class="i_bottom">
|
||||||
<div class="tip" style="margin-bottom: 10px;">
|
<div class="tip" style="margin-bottom: 10px;">
|
||||||
@@ -315,7 +316,7 @@ export default {
|
|||||||
formParam: {
|
formParam: {
|
||||||
description:"",
|
description:"",
|
||||||
teacherType:'2',
|
teacherType:'2',
|
||||||
photo:avatar,
|
photo:null,
|
||||||
status:1,
|
status:1,
|
||||||
teaching:'',
|
teaching:'',
|
||||||
},
|
},
|
||||||
@@ -492,7 +493,7 @@ export default {
|
|||||||
state.teacherdialog = true;
|
state.teacherdialog = true;
|
||||||
state.teacherdialogtitle = '新增讲师'
|
state.teacherdialogtitle = '新增讲师'
|
||||||
// state.formParam.photo =userInfo.value?.avatar
|
// state.formParam.photo =userInfo.value?.avatar
|
||||||
state.formParam.photo = avatar
|
state.formParam.photo = null
|
||||||
state.vf = true
|
state.vf = true
|
||||||
state.formParam.status = '1'
|
state.formParam.status = '1'
|
||||||
// state.formParam.photo = state.formParam.photo === null ?boe : state.formParam.photo
|
// state.formParam.photo = state.formParam.photo === null ?boe : state.formParam.photo
|
||||||
@@ -679,7 +680,7 @@ export default {
|
|||||||
console.log("外部讲师详情", res.data);
|
console.log("外部讲师详情", res.data);
|
||||||
state.formParam = res.data.data
|
state.formParam = res.data.data
|
||||||
state.formParam.description = state.formParam.description === null ? '' : state.formParam.description
|
state.formParam.description = state.formParam.description === null ? '' : state.formParam.description
|
||||||
state.formParam.photo = state.formParam.photo === null ? userInfo.value?.avatar : state.formParam.photo
|
// state.formParam.photo = state.formParam.photo === null ? userInfo.value?.avatar : state.formParam.photo
|
||||||
})
|
})
|
||||||
.catch((err) => {
|
.catch((err) => {
|
||||||
console.log("外部讲师详情", err);
|
console.log("外部讲师详情", err);
|
||||||
@@ -715,7 +716,7 @@ export default {
|
|||||||
}
|
}
|
||||||
const clearNonNumber = () => {
|
const clearNonNumber = () => {
|
||||||
state.formParam.teaching = state.formParam.teaching.replace(/\D/g, '');
|
state.formParam.teaching = state.formParam.teaching.replace(/\D/g, '');
|
||||||
// state.formParam.teaching
|
state.formParam.teaching = state.formParam.teaching.slice(0,8)
|
||||||
}
|
}
|
||||||
const sendRemark=()=>{
|
const sendRemark=()=>{
|
||||||
state.formParam.remark = state.formParam.remark.replace(/\s/g, '');
|
state.formParam.remark = state.formParam.remark.replace(/\s/g, '');
|
||||||
|
|||||||
@@ -170,8 +170,8 @@ export default{
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '内容分类',
|
title: '内容分类',
|
||||||
dataIndex: 'nrfl',
|
dataIndex: 'courseTypeName',
|
||||||
key: 'nrfl',
|
key: 'courseTypeName',
|
||||||
ellipsis: true, align: "center",
|
ellipsis: true, align: "center",
|
||||||
width: 120,
|
width: 120,
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -235,7 +235,7 @@ export default{
|
|||||||
{
|
{
|
||||||
title: "内容分类",
|
title: "内容分类",
|
||||||
width: 100,
|
width: 100,
|
||||||
dataIndex: "sysType1",
|
dataIndex: "courseTypeName",
|
||||||
ellipsis: true,
|
ellipsis: true,
|
||||||
key: "keywords",
|
key: "keywords",
|
||||||
align: "center",
|
align: "center",
|
||||||
@@ -352,22 +352,29 @@ export default{
|
|||||||
const promotionrecordsColumns = ref([
|
const promotionrecordsColumns = ref([
|
||||||
{
|
{
|
||||||
title: '变更时间',
|
title: '变更时间',
|
||||||
dataIndex: 'updateTime',
|
dataIndex: 'createTime',
|
||||||
key: 'updateTime',
|
key: 'createTime',
|
||||||
ellipsis: true, align: "center",
|
ellipsis: true, align: "center",
|
||||||
width: 120,
|
width: 120,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '变更方式',
|
title: '变更方式',
|
||||||
dataIndex: 'operatorType',
|
dataIndex: 'type',
|
||||||
key: 'operatorType',
|
key: 'type',
|
||||||
ellipsis: true, align: "center",
|
ellipsis: true, align: "center",
|
||||||
width: 120,
|
width: 120,
|
||||||
|
customRender: (value) => {
|
||||||
|
return (
|
||||||
|
<div>
|
||||||
|
{value.record.type == 1 ? "自动" : value.record.type == 0 ? '手动':"-"}
|
||||||
|
</div>
|
||||||
|
)
|
||||||
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '变更结果',
|
title: '变更结果',
|
||||||
dataIndex: 'levelName',
|
dataIndex: 'result',
|
||||||
key: 'levelName',
|
key: 'result',
|
||||||
ellipsis: true, align: "center",
|
ellipsis: true, align: "center",
|
||||||
width: 120,
|
width: 120,
|
||||||
},
|
},
|
||||||
|
|||||||
Reference in New Issue
Block a user