|
|
|
@ -3,217 +3,225 @@ |
|
|
|
@ 时间: 2023-10-11 08:39:10 |
|
|
|
@ 备注: 发起人节点操作 |
|
|
|
--> |
|
|
|
<script lang='ts' setup> |
|
|
|
import employeesDialog from '@/components/workflow/dialog/employeesDialog.vue' |
|
|
|
import { AnalysisForm } from '@/components/workflow/drwer/analysisForm' |
|
|
|
import $func from '@/utils/workflow/index' |
|
|
|
import { useStore } from '@/store/workflow/index' |
|
|
|
|
|
|
|
import { analysisForm,setFlowFormKeyPower } from '@/api/workflowapi/index' |
|
|
|
import AssociatedFormsTinyace from '@/widget/associatedforms/associatedFormsTinyace.vue' |
|
|
|
<script lang="ts" setup> |
|
|
|
import employeesDialog from "@/components/workflow/dialog/employeesDialog.vue"; |
|
|
|
import { AnalysisForm } from "@/components/workflow/drwer/analysisForm"; |
|
|
|
import $func from "@/utils/workflow/index"; |
|
|
|
import { useStore } from "@/store/workflow/index"; |
|
|
|
|
|
|
|
import { analysisForm, setFlowFormKeyPower } from "@/api/workflowapi/index"; |
|
|
|
import AssociatedFormsTinyace from "@/widget/associatedforms/associatedFormsTinyace.vue"; |
|
|
|
|
|
|
|
const props = defineProps({ |
|
|
|
formData:{ |
|
|
|
type:Object, |
|
|
|
default(){ |
|
|
|
return {} |
|
|
|
} |
|
|
|
}, |
|
|
|
formKey:{ |
|
|
|
type:String, |
|
|
|
default:"" |
|
|
|
}, |
|
|
|
formVersion:{ |
|
|
|
type:String, |
|
|
|
default:"" |
|
|
|
}, |
|
|
|
nodeConfig:{ |
|
|
|
type: Object, |
|
|
|
default: () => ({}), |
|
|
|
}, |
|
|
|
formData: { |
|
|
|
type: Object, |
|
|
|
default() { |
|
|
|
return {}; |
|
|
|
}, |
|
|
|
}, |
|
|
|
formKey: { |
|
|
|
type: String, |
|
|
|
default: "", |
|
|
|
}, |
|
|
|
formVersion: { |
|
|
|
type: String, |
|
|
|
default: "", |
|
|
|
}, |
|
|
|
nodeConfig: { |
|
|
|
type: Object, |
|
|
|
default: () => ({}), |
|
|
|
}, |
|
|
|
}); |
|
|
|
const emits = defineEmits<{ |
|
|
|
(e: 'update:formData', val: any): void |
|
|
|
}>() |
|
|
|
(e: "update:formData", val: any): void; |
|
|
|
}>(); |
|
|
|
|
|
|
|
const formData = computed({ |
|
|
|
get() { |
|
|
|
return props.formData |
|
|
|
}, |
|
|
|
set(val: formStruct) { |
|
|
|
emits('update:formData', val) |
|
|
|
} |
|
|
|
const formData = computed({ |
|
|
|
get() { |
|
|
|
return props.formData; |
|
|
|
}, |
|
|
|
set(val: formStruct) { |
|
|
|
emits("update:formData", val); |
|
|
|
}, |
|
|
|
}); |
|
|
|
const isLookAll = ref(false) |
|
|
|
const isEditAll = ref(false) |
|
|
|
|
|
|
|
const isLookAll = ref(false); |
|
|
|
const isEditAll = ref(false); |
|
|
|
|
|
|
|
//当前节点操作权限 |
|
|
|
// const |
|
|
|
// const |
|
|
|
|
|
|
|
let flowPermission = ref([]) |
|
|
|
let promoterVisible = ref(false) |
|
|
|
let checkedList = ref([]) |
|
|
|
let flowPermission = ref([]); |
|
|
|
let promoterVisible = ref(false); |
|
|
|
let checkedList = ref([]); |
|
|
|
|
|
|
|
let store = useStore() |
|
|
|
let { setPromoter, setFlowPermission } = store |
|
|
|
let approverConfig1 = computed(():any=> store.approverConfig1) |
|
|
|
let promoterDrawer = computed(()=> store.promoterDrawer) |
|
|
|
let flowPermission1 = computed(()=> store.flowPermission1) |
|
|
|
let store = useStore(); |
|
|
|
let { setPromoter, setFlowPermission } = store; |
|
|
|
let approverConfig1 = computed((): any => store.approverConfig1); |
|
|
|
let promoterDrawer = computed(() => store.promoterDrawer); |
|
|
|
let flowPermission1 = computed(() => store.flowPermission1); |
|
|
|
let visible = computed({ |
|
|
|
get() { |
|
|
|
return promoterDrawer.value |
|
|
|
}, |
|
|
|
set() { |
|
|
|
closeDrawer() |
|
|
|
} |
|
|
|
}) |
|
|
|
get() { |
|
|
|
return promoterDrawer.value; |
|
|
|
}, |
|
|
|
set() { |
|
|
|
closeDrawer(); |
|
|
|
}, |
|
|
|
}); |
|
|
|
watch(flowPermission1, (val) => { |
|
|
|
flowPermission.value = val.value |
|
|
|
}) |
|
|
|
flowPermission.value = val.value; |
|
|
|
}); |
|
|
|
|
|
|
|
const addPromoter = () => { |
|
|
|
checkedList.value = flowPermission.value |
|
|
|
promoterVisible.value = true; |
|
|
|
} |
|
|
|
const surePromoter = (data:any) => { |
|
|
|
flowPermission.value = data; |
|
|
|
promoterVisible.value = false; |
|
|
|
} |
|
|
|
checkedList.value = flowPermission.value; |
|
|
|
promoterVisible.value = true; |
|
|
|
}; |
|
|
|
const surePromoter = (data: any) => { |
|
|
|
flowPermission.value = data; |
|
|
|
promoterVisible.value = false; |
|
|
|
}; |
|
|
|
const savePromoter = () => { |
|
|
|
setFlowPermission({ |
|
|
|
value: flowPermission.value, |
|
|
|
flag: true, |
|
|
|
id: flowPermission1.value.id |
|
|
|
}) |
|
|
|
// console.log(1); |
|
|
|
let powerAry = []; |
|
|
|
if(powerUnitAry.value.recUnitAry.masterUnitList && powerUnitAry.value.recUnitAry.masterUnitList.length > 0){ |
|
|
|
setFlowPermission({ |
|
|
|
value: flowPermission.value, |
|
|
|
flag: true, |
|
|
|
id: flowPermission1.value.id, |
|
|
|
}); |
|
|
|
// console.log(1); |
|
|
|
let powerAry = []; |
|
|
|
if ( |
|
|
|
powerUnitAry.value.recUnitAry.masterUnitList && |
|
|
|
powerUnitAry.value.recUnitAry.masterUnitList.length > 0 |
|
|
|
) { |
|
|
|
powerUnitAry.value.recUnitAry.masterUnitList.forEach((item: any) => { |
|
|
|
powerAry.push(item); |
|
|
|
}); |
|
|
|
} |
|
|
|
// console.log(2); |
|
|
|
if ( |
|
|
|
powerUnitAry.value.recUnitAry.sunUnitList && |
|
|
|
powerUnitAry.value.recUnitAry.sunUnitList.length > 0 |
|
|
|
) { |
|
|
|
powerUnitAry.value.recUnitAry.sunUnitList.forEach((item: any) => { |
|
|
|
if (item.masterUnitList && item.masterUnitList.length > 0) { |
|
|
|
item.masterUnitList.forEach((itemSun: any) => { |
|
|
|
// powerAry.push(item) |
|
|
|
if (!powerAry.includes(itemSun)) { |
|
|
|
powerAry.push(itemSun); |
|
|
|
} |
|
|
|
}); |
|
|
|
} |
|
|
|
}); |
|
|
|
} |
|
|
|
// console.log("正确",formData.value) |
|
|
|
if (formData.value.purview) { |
|
|
|
// console.log("正确") |
|
|
|
let isNew = true; |
|
|
|
formData.value.purview.forEach((item: any) => { |
|
|
|
// console.log("正确---->",item.nodeKey) |
|
|
|
if (item.nodeKey == props.nodeConfig.nodeNumber) { |
|
|
|
item.powerAry = powerAry; |
|
|
|
isNew = false; |
|
|
|
} |
|
|
|
}); |
|
|
|
if (isNew) { |
|
|
|
formData.value.purview.push({ |
|
|
|
nodeKey: props.nodeConfig.nodeNumber, |
|
|
|
powerAry: powerAry, |
|
|
|
}); |
|
|
|
} |
|
|
|
} else { |
|
|
|
formData.value.purview = [ |
|
|
|
{ |
|
|
|
nodeKey: props.nodeConfig.nodeNumber, |
|
|
|
powerAry: powerAry, |
|
|
|
}, |
|
|
|
]; |
|
|
|
} |
|
|
|
|
|
|
|
powerUnitAry.value.recUnitAry.masterUnitList.forEach((item:any)=>{ |
|
|
|
|
|
|
|
powerAry.push(item) |
|
|
|
}) |
|
|
|
|
|
|
|
} |
|
|
|
// console.log(2); |
|
|
|
if(powerUnitAry.value.recUnitAry.sunUnitList && powerUnitAry.value.recUnitAry.sunUnitList.length > 0){ |
|
|
|
powerUnitAry.value.recUnitAry.sunUnitList.forEach((item:any)=>{ |
|
|
|
if(item.masterUnitList && item.masterUnitList.length > 0){ |
|
|
|
item.masterUnitList.forEach((itemSun:any) => { |
|
|
|
// powerAry.push(item) |
|
|
|
if(!powerAry.includes(itemSun)){ |
|
|
|
powerAry.push(itemSun) |
|
|
|
} |
|
|
|
}) |
|
|
|
} |
|
|
|
}); |
|
|
|
} |
|
|
|
// console.log("正确",formData.value) |
|
|
|
if(formData.value.purview){ |
|
|
|
// console.log("正确") |
|
|
|
let isNew = true |
|
|
|
formData.value.purview.forEach((item:any)=>{ |
|
|
|
// console.log("正确---->",item.nodeKey) |
|
|
|
if(item.nodeKey == props.nodeConfig.nodeNumber){ |
|
|
|
item.powerAry=powerAry |
|
|
|
isNew = false |
|
|
|
} |
|
|
|
}); |
|
|
|
if(isNew){ |
|
|
|
formData.value.purview.push({ |
|
|
|
nodeKey: props.nodeConfig.nodeNumber, |
|
|
|
powerAry:powerAry |
|
|
|
}) |
|
|
|
} |
|
|
|
}else{ |
|
|
|
formData.value.purview = [{ |
|
|
|
nodeKey: props.nodeConfig.nodeNumber, |
|
|
|
powerAry:powerAry |
|
|
|
}] |
|
|
|
} |
|
|
|
|
|
|
|
// formData.value.purview.push({ |
|
|
|
// nodeKey: "begin", |
|
|
|
// powerAry:powerAry |
|
|
|
// }) {{props.formKey}}=>{{props.formVersion}} |
|
|
|
// console.log(4); |
|
|
|
// console.log("formKey--->",props.formKey.toString()); |
|
|
|
// console.log("formVersion--->",props.formVersion.toString()); |
|
|
|
// console.log("value--->",formData.value); |
|
|
|
console.log("purview--->",formData.value.purview); |
|
|
|
// formData.value.purview.push({ |
|
|
|
// nodeKey: "begin", |
|
|
|
// powerAry:powerAry |
|
|
|
// }) {{props.formKey}}=>{{props.formVersion}} |
|
|
|
// console.log(4); |
|
|
|
// console.log("formKey--->",props.formKey.toString()); |
|
|
|
// console.log("formVersion--->",props.formVersion.toString()); |
|
|
|
// console.log("value--->",formData.value); |
|
|
|
console.log("purview--->", formData.value.purview); |
|
|
|
|
|
|
|
let sendInfo: any = { |
|
|
|
formKey:props.formKey.toString(), |
|
|
|
formVersion:props.formVersion.toString(), |
|
|
|
formData:JSON.stringify(formData.value), |
|
|
|
formPower:JSON.stringify(formData.value.purview) |
|
|
|
} |
|
|
|
console.log("sendInfo",sendInfo) |
|
|
|
setFlowFormKeyPower(sendInfo) |
|
|
|
// console.log("formDataAll",formData) |
|
|
|
// console.log("formData",formData.value.purview) |
|
|
|
closeDrawer() |
|
|
|
} |
|
|
|
let sendInfo: any = { |
|
|
|
formKey: props.formKey.toString(), |
|
|
|
formVersion: props.formVersion.toString(), |
|
|
|
formData: JSON.stringify(formData.value), |
|
|
|
formPower: JSON.stringify(formData.value.purview), |
|
|
|
}; |
|
|
|
console.log("sendInfo", sendInfo); |
|
|
|
setFlowFormKeyPower(sendInfo); |
|
|
|
// console.log("formDataAll",formData) |
|
|
|
// console.log("formData",formData.value.purview) |
|
|
|
closeDrawer(); |
|
|
|
}; |
|
|
|
const closeDrawer = () => { |
|
|
|
setPromoter(false) |
|
|
|
} |
|
|
|
setPromoter(false); |
|
|
|
}; |
|
|
|
|
|
|
|
const powerUnitAry = ref<any>({ |
|
|
|
nodeKey:"", |
|
|
|
recUnitAry:{ |
|
|
|
masterUnitList:[], |
|
|
|
sunUnitList:[], |
|
|
|
unitAllKey:[], |
|
|
|
unitAllState:[] |
|
|
|
} |
|
|
|
}) |
|
|
|
nodeKey: "", |
|
|
|
recUnitAry: { |
|
|
|
masterUnitList: [], |
|
|
|
sunUnitList: [], |
|
|
|
unitAllKey: [], |
|
|
|
unitAllState: [], |
|
|
|
}, |
|
|
|
}); |
|
|
|
/** |
|
|
|
@ 作者: 秦东 |
|
|
|
@ 时间: 2024-03-13 08:24:54 |
|
|
|
@ 功能: 解析表单 |
|
|
|
*/ |
|
|
|
const jieForm = () => { |
|
|
|
// console.log("nodeConfig",props.nodeConfig) |
|
|
|
analysisForm({nodeKey:props.nodeConfig.nodeNumber,nodeJson:JSON.stringify(formData.value)}) |
|
|
|
.then((data)=>{ |
|
|
|
if(data.code == 0){ |
|
|
|
powerUnitAry.value = data.data |
|
|
|
// console.log("nodeConfig",props.nodeConfig) |
|
|
|
analysisForm({ |
|
|
|
nodeKey: props.nodeConfig.nodeNumber, |
|
|
|
nodeJson: JSON.stringify(formData.value), |
|
|
|
}).then((data) => { |
|
|
|
if (data.code == 0) { |
|
|
|
powerUnitAry.value = data.data; |
|
|
|
|
|
|
|
if(powerUnitAry.value.recUnitAry.masterUnitList && powerUnitAry.value.recUnitAry.masterUnitList.length > 0){ |
|
|
|
let allToal = powerUnitAry.value.recUnitAry.masterUnitList.length |
|
|
|
let isAll = 0 |
|
|
|
let editAll = 0 |
|
|
|
powerUnitAry.value.recUnitAry.masterUnitList.forEach((item:any)=>{ |
|
|
|
if(item.isLook){ |
|
|
|
isAll++ |
|
|
|
} |
|
|
|
if(item.isEdit){ |
|
|
|
editAll++ |
|
|
|
} |
|
|
|
}) |
|
|
|
if(isAll == allToal){ |
|
|
|
isLookAll.value = true |
|
|
|
} |
|
|
|
if(editAll == allToal){ |
|
|
|
isEditAll.value = true |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
} |
|
|
|
}) |
|
|
|
} |
|
|
|
if ( |
|
|
|
powerUnitAry.value.recUnitAry.masterUnitList && |
|
|
|
powerUnitAry.value.recUnitAry.masterUnitList.length > 0 |
|
|
|
) { |
|
|
|
let allToal = powerUnitAry.value.recUnitAry.masterUnitList.length; |
|
|
|
let isAll = 0; |
|
|
|
let editAll = 0; |
|
|
|
powerUnitAry.value.recUnitAry.masterUnitList.forEach((item: any) => { |
|
|
|
if (item.isLook) { |
|
|
|
isAll++; |
|
|
|
} |
|
|
|
if (item.isEdit) { |
|
|
|
editAll++; |
|
|
|
} |
|
|
|
}); |
|
|
|
if (isAll == allToal) { |
|
|
|
isLookAll.value = true; |
|
|
|
} |
|
|
|
if (editAll == allToal) { |
|
|
|
isEditAll.value = true; |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
}); |
|
|
|
}; |
|
|
|
|
|
|
|
watch(()=>visible.value,(val:boolean)=>{ |
|
|
|
if(val){ |
|
|
|
jieForm(); |
|
|
|
} |
|
|
|
}) |
|
|
|
const nodeSetUp = ref("first") |
|
|
|
const contentpage = ref("") |
|
|
|
watch( |
|
|
|
() => visible.value, |
|
|
|
(val: boolean) => { |
|
|
|
if (val) { |
|
|
|
jieForm(); |
|
|
|
} |
|
|
|
} |
|
|
|
); |
|
|
|
const nodeSetUp = ref("first"); |
|
|
|
const contentpage = ref(""); |
|
|
|
|
|
|
|
/** |
|
|
|
@ 作者: 秦东 |
|
|
|
@ -221,179 +229,220 @@ const contentpage = ref("") |
|
|
|
@ 功能: 选择情况 |
|
|
|
*/ |
|
|
|
const editOpenOrClose = (val: any) => { |
|
|
|
if(powerUnitAry.value.recUnitAry.masterUnitList){ |
|
|
|
powerUnitAry.value.recUnitAry.masterUnitList.forEach((item:any)=>{ |
|
|
|
item.isEdit = val |
|
|
|
}) |
|
|
|
} |
|
|
|
} |
|
|
|
if (powerUnitAry.value.recUnitAry.masterUnitList) { |
|
|
|
powerUnitAry.value.recUnitAry.masterUnitList.forEach((item: any) => { |
|
|
|
item.isEdit = val; |
|
|
|
}); |
|
|
|
} |
|
|
|
}; |
|
|
|
const lookOpenOrClose = (val: boolean) => { |
|
|
|
if(powerUnitAry.value.recUnitAry.masterUnitList){ |
|
|
|
powerUnitAry.value.recUnitAry.masterUnitList.forEach((item:any)=>{ |
|
|
|
item.isLook = val |
|
|
|
if(!val){ |
|
|
|
item.isEdit = val |
|
|
|
isEditAll.value = val |
|
|
|
} |
|
|
|
}) |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
} |
|
|
|
if (powerUnitAry.value.recUnitAry.masterUnitList) { |
|
|
|
powerUnitAry.value.recUnitAry.masterUnitList.forEach((item: any) => { |
|
|
|
item.isLook = val; |
|
|
|
if (!val) { |
|
|
|
item.isEdit = val; |
|
|
|
isEditAll.value = val; |
|
|
|
} |
|
|
|
}); |
|
|
|
} |
|
|
|
}; |
|
|
|
/** |
|
|
|
@ 作者: 秦东 |
|
|
|
@ 时间: 2024-07-25 16:09:18 |
|
|
|
@ 功能: 操作单一可见 |
|
|
|
*/ |
|
|
|
const oneLookSet = (val: any) => { |
|
|
|
if(!val.isLook){ |
|
|
|
val.isEdit = val.isLook |
|
|
|
isEditAll.value = val.isLook |
|
|
|
} |
|
|
|
if(powerUnitAry.value.recUnitAry.masterUnitList){ |
|
|
|
let lookAll = 0 |
|
|
|
powerUnitAry.value.recUnitAry.masterUnitList.forEach((item:any)=>{ |
|
|
|
if(item.isLook){ |
|
|
|
lookAll++ |
|
|
|
} |
|
|
|
}) |
|
|
|
if(lookAll != powerUnitAry.value.recUnitAry.masterUnitList.length){ |
|
|
|
isLookAll.value = false |
|
|
|
}else{ |
|
|
|
isLookAll.value = true |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
if (!val.isLook) { |
|
|
|
val.isEdit = val.isLook; |
|
|
|
isEditAll.value = val.isLook; |
|
|
|
} |
|
|
|
if (powerUnitAry.value.recUnitAry.masterUnitList) { |
|
|
|
let lookAll = 0; |
|
|
|
powerUnitAry.value.recUnitAry.masterUnitList.forEach((item: any) => { |
|
|
|
if (item.isLook) { |
|
|
|
lookAll++; |
|
|
|
} |
|
|
|
}); |
|
|
|
if (lookAll != powerUnitAry.value.recUnitAry.masterUnitList.length) { |
|
|
|
isLookAll.value = false; |
|
|
|
} else { |
|
|
|
isLookAll.value = true; |
|
|
|
} |
|
|
|
} |
|
|
|
}; |
|
|
|
/** |
|
|
|
@ 作者: 秦东 |
|
|
|
@ 时间: 2024-07-25 16:17:32 |
|
|
|
@ 功能: 操作单一可编辑 |
|
|
|
*/ |
|
|
|
const oneEditSet = (val: any) => { |
|
|
|
if(powerUnitAry.value.recUnitAry.masterUnitList){ |
|
|
|
let lookAll = 0 |
|
|
|
powerUnitAry.value.recUnitAry.masterUnitList.forEach((item:any)=>{ |
|
|
|
if(item.isEdit){ |
|
|
|
lookAll++ |
|
|
|
} |
|
|
|
}) |
|
|
|
if(lookAll != powerUnitAry.value.recUnitAry.masterUnitList.length){ |
|
|
|
isEditAll.value = false |
|
|
|
}else{ |
|
|
|
isEditAll.value = true |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
if (powerUnitAry.value.recUnitAry.masterUnitList) { |
|
|
|
let lookAll = 0; |
|
|
|
powerUnitAry.value.recUnitAry.masterUnitList.forEach((item: any) => { |
|
|
|
if (item.isEdit) { |
|
|
|
lookAll++; |
|
|
|
} |
|
|
|
}); |
|
|
|
if (lookAll != powerUnitAry.value.recUnitAry.masterUnitList.length) { |
|
|
|
isEditAll.value = false; |
|
|
|
} else { |
|
|
|
isEditAll.value = true; |
|
|
|
} |
|
|
|
} |
|
|
|
}; |
|
|
|
</script> |
|
|
|
<template> |
|
|
|
<el-drawer v-model="visible" :append-to-body="true" title="发起人" class="set_promoter" :show-close="false" :size="550" :before-close="closeDrawer"> |
|
|
|
<div class="demo-drawer__content"> |
|
|
|
<!-- {{powerUnitAry.recUnitAry.masterUnitList}} --> |
|
|
|
<div class="promoter_content drawer_content"> |
|
|
|
<el-tabs v-model="nodeSetUp" class="demo-tabs"> |
|
|
|
<el-tab-pane name="first"> |
|
|
|
<template #label> |
|
|
|
<span class="wordKeyCss">属性设置</span> |
|
|
|
</template> |
|
|
|
<el-drawer |
|
|
|
v-model="visible" |
|
|
|
:append-to-body="true" |
|
|
|
title="发起人" |
|
|
|
class="set_promoter" |
|
|
|
:show-close="false" |
|
|
|
:size="550" |
|
|
|
:before-close="closeDrawer" |
|
|
|
> |
|
|
|
<div class="demo-drawer__content"> |
|
|
|
<!-- {{powerUnitAry.recUnitAry.masterUnitList}} --> |
|
|
|
<div class="promoter_content drawer_content"> |
|
|
|
<el-tabs v-model="nodeSetUp" class="demo-tabs"> |
|
|
|
<el-tab-pane name="first"> |
|
|
|
<template #label> |
|
|
|
<span class="wordKeyCss">属性设置</span> |
|
|
|
</template> |
|
|
|
|
|
|
|
<!-- <el-divider content-position="left">节点属性</el-divider> --> |
|
|
|
<div class="info_box"> |
|
|
|
<p>{{ $func.arrToStr(flowPermission) || '所有人' }}</p> |
|
|
|
<el-button type="primary" @click="addPromoter">添加/修改发起人</el-button> |
|
|
|
</div> |
|
|
|
</el-tab-pane> |
|
|
|
<el-tab-pane name="second"> |
|
|
|
<template #label> |
|
|
|
<span class="wordKeyCss">操作权限</span> |
|
|
|
</template> |
|
|
|
<!-- <el-divider content-position="left">操作权限</el-divider> --> |
|
|
|
<div class="info_box"> |
|
|
|
<div class="table_name"><el-text class="mx-1" type="primary">主表</el-text></div> |
|
|
|
<el-table v-if="powerUnitAry.recUnitAry.masterUnitList" :data="powerUnitAry.recUnitAry.masterUnitList" size="small" style="width: 100%; --el-table-border-color: none;" :header-cell-style="{background:'#eef1f6',color:'#606266'}" class="customer-no-border-table" |
|
|
|
> |
|
|
|
<el-table-column prop="name" label="字段" /> |
|
|
|
<el-table-column align="center" width="80"> |
|
|
|
<template #header> |
|
|
|
<el-checkbox v-model="isLookAll" label="" @change="lookOpenOrClose" />可见 |
|
|
|
</template> |
|
|
|
<template #default="scope"> |
|
|
|
<el-checkbox v-model="scope.row.isLook" label="" @change="oneLookSet(scope.row)" /> |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
<el-table-column align="center" width="120"> |
|
|
|
<template #header> |
|
|
|
<el-checkbox v-model="isEditAll" label="" @change="editOpenOrClose" />可编辑 |
|
|
|
</template> |
|
|
|
<template #default="scope"> |
|
|
|
<el-checkbox v-model="scope.row.isEdit" label="" @change="oneEditSet(scope.row)" /> |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
</el-table> |
|
|
|
<el-row v-if="powerUnitAry.recUnitAry.sunUnitList" v-for="(item,index) in powerUnitAry.recUnitAry.sunUnitList" :key="index"> |
|
|
|
<el-col :span="24" class="table_name"><el-text class="mx-1" type="primary">{{item.name}}</el-text>子表</el-col> |
|
|
|
<el-col :span="24"> |
|
|
|
<el-table v-if="item.masterUnitList" :data="item.masterUnitList" size="small" style="width: 100%; --el-table-border-color: none;" :header-cell-style="{background:'#eef1f6',color:'#606266'}"> |
|
|
|
<el-table-column prop="name" label="字段" /> |
|
|
|
<el-table-column label="可见" align="center" width="80"> |
|
|
|
<template #default="scope"> |
|
|
|
<el-checkbox v-model="scope.row.isLook" label="" /> |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
<el-table-column label="可编辑" align="center" width="80"> |
|
|
|
<template #default="scope"> |
|
|
|
<el-checkbox v-model="scope.row.isEdit" label="" /> |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
</el-table> |
|
|
|
</el-col> |
|
|
|
</el-row> |
|
|
|
</div> |
|
|
|
</el-tab-pane> |
|
|
|
<el-tab-pane name="helpInstructions"> |
|
|
|
<template #label> |
|
|
|
<span class="wordKeyCss">帮助说明</span> |
|
|
|
</template> |
|
|
|
<div class="info_box"> |
|
|
|
<QuillEditor v-model="props.nodeConfig.helpTips" height="400px" /> |
|
|
|
</div> |
|
|
|
</el-tab-pane> |
|
|
|
</el-tabs> |
|
|
|
|
|
|
|
<!-- <el-divider content-position="left">节点属性</el-divider> --> |
|
|
|
<div class="info_box"> |
|
|
|
<p>{{ $func.arrToStr(flowPermission) || "所有人" }}</p> |
|
|
|
<el-button type="primary" @click="addPromoter">添加/修改发起人</el-button> |
|
|
|
</div> |
|
|
|
</el-tab-pane> |
|
|
|
<el-tab-pane name="second"> |
|
|
|
<template #label> |
|
|
|
<span class="wordKeyCss">操作权限</span> |
|
|
|
</template> |
|
|
|
<!-- <el-divider content-position="left">操作权限</el-divider> --> |
|
|
|
<div class="info_box"> |
|
|
|
<div class="table_name"> |
|
|
|
<el-text class="mx-1" type="primary">主表</el-text> |
|
|
|
</div> |
|
|
|
<el-table |
|
|
|
v-if="powerUnitAry.recUnitAry.masterUnitList" |
|
|
|
:data="powerUnitAry.recUnitAry.masterUnitList" |
|
|
|
size="small" |
|
|
|
style="width: 100%; --el-table-border-color: none" |
|
|
|
:header-cell-style="{ background: '#eef1f6', color: '#606266' }" |
|
|
|
class="customer-no-border-table" |
|
|
|
> |
|
|
|
<el-table-column prop="name" label="字段" /> |
|
|
|
<el-table-column align="center" width="80"> |
|
|
|
<template #header> |
|
|
|
<el-checkbox |
|
|
|
v-model="isLookAll" |
|
|
|
label="" |
|
|
|
@change="lookOpenOrClose" |
|
|
|
/>可见 |
|
|
|
</template> |
|
|
|
<template #default="scope"> |
|
|
|
<el-checkbox |
|
|
|
v-model="scope.row.isLook" |
|
|
|
label="" |
|
|
|
@change="oneLookSet(scope.row)" |
|
|
|
/> |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
<el-table-column align="center" width="120"> |
|
|
|
<template #header> |
|
|
|
<el-checkbox |
|
|
|
v-model="isEditAll" |
|
|
|
label="" |
|
|
|
@change="editOpenOrClose" |
|
|
|
/>可编辑 |
|
|
|
</template> |
|
|
|
<template #default="scope"> |
|
|
|
<el-checkbox |
|
|
|
v-model="scope.row.isEdit" |
|
|
|
label="" |
|
|
|
@change="oneEditSet(scope.row)" |
|
|
|
/> |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
</el-table> |
|
|
|
<el-row |
|
|
|
v-if="powerUnitAry.recUnitAry.sunUnitList" |
|
|
|
v-for="(item, index) in powerUnitAry.recUnitAry.sunUnitList" |
|
|
|
:key="index" |
|
|
|
> |
|
|
|
<el-col :span="24" class="table_name" |
|
|
|
><el-text class="mx-1" type="primary">{{ item.name }}</el-text |
|
|
|
>子表</el-col |
|
|
|
> |
|
|
|
<el-col :span="24"> |
|
|
|
<el-table |
|
|
|
v-if="item.masterUnitList" |
|
|
|
:data="item.masterUnitList" |
|
|
|
size="small" |
|
|
|
style="width: 100%; --el-table-border-color: none" |
|
|
|
:header-cell-style="{ background: '#eef1f6', color: '#606266' }" |
|
|
|
> |
|
|
|
<el-table-column prop="name" label="字段" /> |
|
|
|
<el-table-column label="可见" align="center" width="80"> |
|
|
|
<template #default="scope"> |
|
|
|
<el-checkbox v-model="scope.row.isLook" label="" /> |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
<el-table-column label="可编辑" align="center" width="80"> |
|
|
|
<template #default="scope"> |
|
|
|
<el-checkbox v-model="scope.row.isEdit" label="" /> |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
</el-table> |
|
|
|
</el-col> |
|
|
|
</el-row> |
|
|
|
</div> |
|
|
|
|
|
|
|
<div class="demo-drawer__footer clear"> |
|
|
|
<el-button type="primary" @click="savePromoter">确 定</el-button> |
|
|
|
<el-button @click="closeDrawer">取 消</el-button> |
|
|
|
</el-tab-pane> |
|
|
|
<el-tab-pane name="helpInstructions"> |
|
|
|
<template #label> |
|
|
|
<span class="wordKeyCss">帮助说明</span> |
|
|
|
</template> |
|
|
|
<div class="info_box"> |
|
|
|
<QuillEditor v-model="props.nodeConfig.helpTips" height="400px" /> |
|
|
|
</div> |
|
|
|
<employees-dialog |
|
|
|
v-model:visible="promoterVisible" |
|
|
|
:isdepartment="true" |
|
|
|
:data="checkedList" |
|
|
|
@change="surePromoter" |
|
|
|
/> |
|
|
|
</div> |
|
|
|
</el-drawer> |
|
|
|
</el-tab-pane> |
|
|
|
</el-tabs> |
|
|
|
</div> |
|
|
|
|
|
|
|
<div class="demo-drawer__footer clear"> |
|
|
|
<el-button type="primary" @click="savePromoter">确 定</el-button> |
|
|
|
<el-button @click="closeDrawer">取 消</el-button> |
|
|
|
</div> |
|
|
|
<employees-dialog |
|
|
|
v-model:visible="promoterVisible" |
|
|
|
:isdepartment="true" |
|
|
|
:data="checkedList" |
|
|
|
@change="surePromoter" |
|
|
|
/> |
|
|
|
</div> |
|
|
|
</el-drawer> |
|
|
|
</template> |
|
|
|
<style lang='scss' scoped> |
|
|
|
<style lang="scss" scoped> |
|
|
|
.set_promoter { |
|
|
|
.promoter_content { |
|
|
|
padding: 0 0px; |
|
|
|
.info_box{ |
|
|
|
padding: 0 20px; |
|
|
|
} |
|
|
|
.el-button { |
|
|
|
margin-bottom: 20px; |
|
|
|
} |
|
|
|
p { |
|
|
|
padding: 18px 0; |
|
|
|
font-size: 14px; |
|
|
|
line-height: 20px; |
|
|
|
color: #000000; |
|
|
|
} |
|
|
|
.promoter_content { |
|
|
|
padding: 0 0px; |
|
|
|
.info_box { |
|
|
|
padding: 0 20px; |
|
|
|
} |
|
|
|
.el-button { |
|
|
|
margin-bottom: 20px; |
|
|
|
} |
|
|
|
p { |
|
|
|
padding: 18px 0; |
|
|
|
font-size: 14px; |
|
|
|
line-height: 20px; |
|
|
|
color: #000000; |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
.table_name{ |
|
|
|
padding : 10px 0 |
|
|
|
.table_name { |
|
|
|
padding: 10px 0; |
|
|
|
} |
|
|
|
|
|
|
|
</style> |
|
|
|
|