mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/fe-manage.git
synced 2025-12-21 00:36:46 +08:00
暂时搁置
This commit is contained in:
@@ -55,3 +55,5 @@ export const getUserList = (keyword) => http.get(`/admin/thirdApi/user/list?page
|
||||
export const getSelectOrg = (id) => http.get(`/admin/affiliation/getSelectOrg?id=${id}`)
|
||||
//查询弹框不可选择组织(审核中的组织)
|
||||
export const getUnSelectOrg = () => http.get(`/admin/affiliation/getUnSelectOrg`)
|
||||
//获取培训发生组织编号
|
||||
export const getAffiliationCode = () => http.get('/admin/affiliation/getAffiliationCode')
|
||||
|
||||
@@ -86,15 +86,15 @@
|
||||
</a-row>
|
||||
<a-row :gutter="16">
|
||||
<a-col :span="12">
|
||||
<a-form-item label="培训发生组织编号:" name="trainorgId">
|
||||
<a-input disabled v-model:value="formParam.trainorgId" class="draitem"
|
||||
<a-form-item label="培训发生组织编号:" name="trainOrgId">
|
||||
<a-input disabled v-model:value="formParam.trainOrgId" class="draitem"
|
||||
placeholder="请输入讲师体系编号" allowClear showSearch>
|
||||
</a-input>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
<a-form-item label="培训发生组织名称:" name="trainorgName">
|
||||
<a-input v-model:value="formParam.trainorgName" class="draitem"
|
||||
<a-form-item label="培训发生组织名称:" name="trainOrgName">
|
||||
<a-input v-model:value="formParam.trainOrgName" class="draitem"
|
||||
placeholder="请输入讲师体系名称" allowClear showSearch>
|
||||
</a-input>
|
||||
</a-form-item>
|
||||
@@ -102,14 +102,14 @@
|
||||
</a-row>
|
||||
<a-row :gutter="16">
|
||||
<a-col :span="12">
|
||||
<a-form-item label="是否为根节点:" name="zzfzr">
|
||||
<a-form-item label="是否为根节点:" name="parentId">
|
||||
<div style="display: flex;align-items: center;">
|
||||
<a-radio-group style="min-width:126px;" @change="selectRadio" v-model:value="formParam.status" name="radioGroup">
|
||||
<a-radio :value="0">否</a-radio>
|
||||
<a-radio :value="1">是</a-radio>
|
||||
</a-radio-group>
|
||||
<a-select v-model:value="formParam.zzfzr" placeholder="请选择组织负责人"
|
||||
:options="PlaceOfPayList" allowClear showSearch/>
|
||||
<a-select v-model:value="formParam.parentId" placeholder="请选择根节点"
|
||||
:options="formParam.status?PlaceOfPayList:PlaceOfPayListTwo" allowClear showSearch/>
|
||||
</div>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
@@ -207,6 +207,7 @@ import dialog from "@/utils/dialog";
|
||||
import ProjectManager from "@/components/project/ProjectManagerLecturer";
|
||||
import { queryTrainOrg,deleteTrainOrg,addReviewer,updateTrainOrg} from "../../api/organization";
|
||||
import AddOrgContent from "../../components/project/AddOrgContent.vue"
|
||||
import lecturer from "../../api/Lecturer";
|
||||
export default{
|
||||
name:"organization",
|
||||
components: {
|
||||
@@ -231,8 +232,8 @@ export default{
|
||||
pageSize: "10"
|
||||
},
|
||||
formParam:{
|
||||
trainorgId:null,
|
||||
trainorgName:null,
|
||||
trainOrgId:null,
|
||||
trainOrgName:null,
|
||||
status: 0,
|
||||
remark:null,
|
||||
orgName: null,
|
||||
@@ -243,12 +244,23 @@ export default{
|
||||
leveOneArray: [],
|
||||
leveTwoArray: [],
|
||||
leveThreeArray: [],
|
||||
parentId: null,
|
||||
affiliationOrgList: [],
|
||||
},
|
||||
orgList: [],
|
||||
})
|
||||
const PlaceOfPayList = ref([
|
||||
{ value: 1, label: "一级审批人" },
|
||||
{ value: 2, label: "二级审批人" },
|
||||
{ value: 3, label: "三级审批人" },
|
||||
])
|
||||
const PlaceOfPayListTwo = ref([
|
||||
{ value: 1, label: "一级审批人" },
|
||||
])
|
||||
const AddContentList = (val) => {
|
||||
console.log(val,'val')
|
||||
state.orgList = val
|
||||
state.formParam.affiliationOrgList = val
|
||||
}
|
||||
const selectRadio = (val)=>{
|
||||
if(val.target.value == 1){
|
||||
@@ -256,20 +268,21 @@ export default{
|
||||
state.formParam.leveTwoArray = []
|
||||
state.formParam.leveThreeArray = []
|
||||
}
|
||||
state.formParam.parentId = null
|
||||
}
|
||||
const columns = ref([
|
||||
{
|
||||
title: '培训发生组织编号 ',
|
||||
dataIndex: 'trainorgId',
|
||||
key: 'trainorgId',
|
||||
dataIndex: 'trainOrgId',
|
||||
key: 'trainOrgId',
|
||||
elipsis: true,
|
||||
align: "center",
|
||||
width: 200,
|
||||
},
|
||||
{
|
||||
title: '培训发生组织名称 ',
|
||||
dataIndex: 'trainorgName',
|
||||
key: 'trainorgName',
|
||||
dataIndex: 'trainOrgName',
|
||||
key: 'trainOrgName',
|
||||
elipsis: true, align: "center",
|
||||
width: 600,
|
||||
},
|
||||
@@ -325,13 +338,27 @@ const orgColumns = ref([
|
||||
},
|
||||
{
|
||||
title: '是否被培训发生组织选择',
|
||||
dataIndex: 'name',
|
||||
key: 'name',
|
||||
dataIndex: 'isSelect',
|
||||
key: 'isSelect',
|
||||
customRender: (text) => {
|
||||
return (
|
||||
<div>
|
||||
{isSelect == 1 ? `${text.record.isSelect} (${text.record.orgName})` : "否 (-)"}
|
||||
</div>
|
||||
)
|
||||
}
|
||||
},
|
||||
{
|
||||
title: '担当',
|
||||
dataIndex: 'name',
|
||||
key: 'name',
|
||||
dataIndex: 'leaders',
|
||||
key: 'leaders',
|
||||
customRender: (text) => {
|
||||
return (
|
||||
<div>
|
||||
{text.record.leaders || '-'}
|
||||
</div>
|
||||
)
|
||||
}
|
||||
},
|
||||
])
|
||||
//列表数据
|
||||
@@ -398,6 +425,11 @@ const getTableDate = (obj) => {
|
||||
state.teacherdialog=true ,
|
||||
state.teacherdialogtitle="新增归属组织"
|
||||
state.vf = true
|
||||
lecturer.getAffiliationCode().then(res=>{
|
||||
state.formParam.trainOrgId = res.data
|
||||
}).catch(()=>{
|
||||
message.error('获取归属组织编号失败')
|
||||
})
|
||||
}
|
||||
const addContentData = () => {
|
||||
state.showContent = true
|
||||
@@ -411,14 +443,14 @@ const getTableDate = (obj) => {
|
||||
TeacherSystem(record)
|
||||
}
|
||||
const TeacherSystem =(record)=>{
|
||||
state.formParam.trainorgId=record.trainorgId
|
||||
state.formParam.trainorgName=record.trainorgName
|
||||
state.formParam.trainOrgId=record.trainOrgId
|
||||
state.formParam.trainOrgName=record.trainOrgName
|
||||
state.formParam.remark=record.remark
|
||||
}
|
||||
const cancel=()=>{
|
||||
state.formParam={
|
||||
trainorgId:null,
|
||||
trainorgName:null,
|
||||
trainOrgId:null,
|
||||
trainOrgName:null,
|
||||
status: 0,
|
||||
remark:null,
|
||||
orgName: null,
|
||||
@@ -429,6 +461,8 @@ const getTableDate = (obj) => {
|
||||
leveOneArray: [],
|
||||
leveTwoArray: [],
|
||||
leveThreeArray: [],
|
||||
parentId: null,
|
||||
affiliationOrgList: []
|
||||
}
|
||||
}
|
||||
async function validateField(name) {
|
||||
@@ -444,6 +478,9 @@ const getTableDate = (obj) => {
|
||||
}
|
||||
//保存
|
||||
const createTeacherDialog = async () => {
|
||||
if(state.formParam.status){
|
||||
state.formParam.status = state.formParam.parentId
|
||||
}
|
||||
state.formParam.affiliationUserList = [...state.formParam?.actArray,...state.formParam?.leveOneArray,...state.formParam?.leveTwoArray,...state.formParam?.leveThreeArray]
|
||||
state.formParam.orgId = state.orgList?.map(item=>item.id).join(',')
|
||||
state.formParam.orgName = state.orgList?.map(item=>item.name).join(',')
|
||||
@@ -476,12 +513,11 @@ const getTableDate = (obj) => {
|
||||
})
|
||||
};
|
||||
const rules = {
|
||||
// trainorgId: [{ required: true, message: '',log:'培训发生组织编号不能为空' }],
|
||||
// trainorgName: [{ required: true, message: '',log:'培训发生组织名称不能为空' }],
|
||||
trainOrgId: [{ required: true, message: '',log:'培训发生组织编号不能为空' }],
|
||||
trainOrgName: [{ required: true, message: '',log:'培训发生组织名称不能为空' }],
|
||||
parentId: [{ required: true, message: '',log:'根节点不能为空' }],
|
||||
actValue: [{ required: true, message: '',log:'组织担当不能为空' }],
|
||||
leveOneValue: [{ required: true, message: '"',log:'一级审批人不能为空' }],
|
||||
// zzfzr: [{ required: true, message: '',log:'二级审批人不能为空' }],
|
||||
// sjspr: [{ required: true, message: '',log:'三级审批人不能为空' }],
|
||||
|
||||
|
||||
}
|
||||
@@ -496,6 +532,8 @@ const getTableDate = (obj) => {
|
||||
searchSubmit,
|
||||
selectRadio,
|
||||
AddContentList,
|
||||
PlaceOfPayList,
|
||||
PlaceOfPayListTwo,
|
||||
searchReset,
|
||||
deleteModal,
|
||||
cancelTeacherDialog,
|
||||
|
||||
Reference in New Issue
Block a user