Browse Source

修改部分BUG

qin_v3
超级管理员 1 year ago
parent
commit
aba5e99600
  1. 8
      src/api/DesignForm/requestapi.ts
  2. 1
      src/api/date/type.ts
  3. 2
      src/components/IconSelect/appMenuSvgPage.vue
  4. 77
      src/components/workflow/drwer/approverDrawer.vue
  5. 4
      src/styles/index.scss
  6. 1
      src/utils/workflow/const.ts
  7. 2
      src/utils/workflow/index.ts
  8. 30
      src/views/sysworkflow/lowcodepage/appPage/appMenus.vue
  9. 31
      src/views/sysworkflow/lowcodepage/appPage/releaseApp/index.vue

8
src/api/DesignForm/requestapi.ts

@ -597,3 +597,11 @@ export function gainFormPageMapCont(data: any) {
data: data data: data
}); });
} }
//编辑APP菜单图标
export function editAppMenusIcon(data: any) {
return request({
url: '/systemapi/app/editAppMenusIcon',
method: 'post',
data: data
});
}

1
src/api/date/type.ts

@ -277,6 +277,7 @@ export interface appNodeConfig{
sendBackNode: string; sendBackNode: string;
settype: number; settype: number;
type: number; type: number;
orgList: string;
} }
//app工作流附件 //app工作流附件
export interface appMatrix{ export interface appMatrix{

2
src/components/IconSelect/appMenuSvgPage.vue

@ -59,7 +59,7 @@ const handleClose = () => {
@ 功能: 确定 @ 功能: 确定
*/ */
const handleSelect = (svgName:string) => { const handleSelect = (svgName:string) => {
// console.log("",props.svgId) console.log("确定",props.svgId,svgName)
emits("update:svgName",svgName) emits("update:svgName",svgName)
handleClose() handleClose()
} }

77
src/components/workflow/drwer/approverDrawer.vue

@ -9,6 +9,8 @@ import { setTypes, selectModes, selectRanges } from '@/utils/workflow/const'
import { useStore } from '@/store/workflow/index' import { useStore } from '@/store/workflow/index'
import { getAllParentNode,judgeOptionalNode,analysisForm,setFlowFormKeyPower } from '@/api/workflowapi/index' import { getAllParentNode,judgeOptionalNode,analysisForm,setFlowFormKeyPower } from '@/api/workflowapi/index'
import { govthree } from '@/api/opk/opk/api'
import PositionDialog from '@/components/workflow/dialog/positionDialog.vue' import PositionDialog from '@/components/workflow/dialog/positionDialog.vue'
import FormWord from '@/components/workflow/dialog/formWord.vue' import FormWord from '@/components/workflow/dialog/formWord.vue'
import MatrixPage from '@/components/workflow/dialog/matrix.vue' import MatrixPage from '@/components/workflow/dialog/matrix.vue'
@ -44,10 +46,17 @@ let props = defineProps({
} }
} }
}); });
const flowOrgTree = ref()
const isExecutor = ref(false) const isExecutor = ref(false)
const nodeTitle = ref<string>("审批人设置") const nodeTitle = ref<string>("审批人设置")
const nodeOptional = ref<any[]>() //线 const nodeOptional = ref<any[]>() //线
const nodeAllVerify = ref<any[]>() const nodeAllVerify = ref<any[]>()
const orgList = ref<any[]>() //
const orgProps = {
value: 'id',
label: 'name',
children: 'child',
}
const isLookAll = ref(false) const isLookAll = ref(false)
const isEditAll = ref(false) const isEditAll = ref(false)
@ -385,6 +394,48 @@ const oneEditSet = (val: any) => {
} }
} }
} }
//
watch(()=>approverConfig.value.settype,(val:any)=>{
console.log("监听审批人设置选项",approverConfig.value)
switch (val) {
case 10:
let sendOrg = {
id: 313,
idstr: "313",
level: 4,
all: 1
}
govthree(sendOrg)
.then(({data})=>{
console.log("监听审批人设置选项",data)
orgList.value = data
})
break;
default:
break;
}
},{
deep:true
})
/**
@ 作者: 秦东
@ 时间: 2024-08-08 15:54:07
@ 功能: 选中的哪个行政组织
*/
const handleNodeClickOrg = (val:any) => {
console.log(val)
}
/**
@ 作者: 秦东
@ 时间: 2024-08-08 16:07:49
@ 功能: 设置选项
*/
const setOrgTree = (val:any) => {
console.log("设置选项",val)
flowOrgTree.value!.setCheckedKeys([val], true)
}
</script> </script>
<template> <template>
@ -528,6 +579,24 @@ const oneEditSet = (val: any) => {
<option value="2">执行人</option> <option value="2">执行人</option>
</select> </select>
</div> </div>
<el-divider v-if="approverConfig.settype==10" content-position="left">指定部门负责人</el-divider>
<div v-if="approverConfig.settype==10" class="approver_manager">
<el-button type="primary" @click="setOrgTree(102)">设置行政组织</el-button>
<el-tree-v2
ref="flowOrgTree"
style="border: 1px solid #ccc;"
:data="orgList"
:props="orgProps"
:height="300"
node-key="id"
:check-strictly="true"
:highlight-current="true"
:expand-on-click-node="false"
:check-on-click-node="true"
:default-checked-keys="defaultCheckedKeys"
@node-click="handleNodeClickOrg"
/>
</div>
<MatrixPage <MatrixPage
v-if="approverConfig.settype==9" v-if="approverConfig.settype==9"
v-model:isshow="matrixIsShow" v-model:isshow="matrixIsShow"
@ -535,16 +604,16 @@ const oneEditSet = (val: any) => {
@change="updateMatrix" @change="updateMatrix"
/> />
<!--补充审批信息--> <!--补充审批信息-->
<el-divider v-if="(approverConfig.settype==1&&approverConfig.nodeUserList.length>1)||approverConfig.settype==2||approverConfig.settype==6||(approverConfig.settype==4&&approverConfig.selectMode==2)||approverConfig.settype==8||approverConfig.settype==9" content-position="left">多人审批时采用的审批方式</el-divider> <el-divider v-if="(approverConfig.settype==1&&approverConfig.nodeUserList.length>1)||approverConfig.settype==2||approverConfig.settype==6||(approverConfig.settype==4&&approverConfig.selectMode==2)||approverConfig.settype==8||approverConfig.settype==9||approverConfig.settype==10" content-position="left">多人审批时采用的审批方式</el-divider>
<div v-if="(approverConfig.settype==1&&approverConfig.nodeUserList.length>1)||approverConfig.settype==2||approverConfig.settype==6||(approverConfig.settype==4&&approverConfig.selectMode==2)||approverConfig.settype==8||approverConfig.settype==9" class="approver_some"> <div v-if="(approverConfig.settype==1&&approverConfig.nodeUserList.length>1)||approverConfig.settype==2||approverConfig.settype==6||(approverConfig.settype==4&&approverConfig.selectMode==2)||approverConfig.settype==8||approverConfig.settype==9||approverConfig.settype==10" class="approver_some">
<el-radio-group v-model="approverConfig.examineMode" class="clear"> <el-radio-group v-model="approverConfig.examineMode" class="clear">
<el-radio :label="1">依次审批</el-radio> <el-radio :label="1">依次审批</el-radio>
<el-radio v-if="approverConfig.settype!=2" :label="2">会签(须所有审批人同意)</el-radio> <el-radio v-if="approverConfig.settype!=2" :label="2">会签(须所有审批人同意)</el-radio>
<el-radio v-if="approverConfig.settype!=2" :label="3">或签(有一位审批人同意即可)</el-radio> <el-radio v-if="approverConfig.settype!=2" :label="3">或签(有一位审批人同意即可)</el-radio>
</el-radio-group> </el-radio-group>
</div> </div>
<el-divider v-if="approverConfig.settype==2||approverConfig.settype==6||approverConfig.settype==9" content-position="left">审批人为空时</el-divider> <el-divider v-if="approverConfig.settype==2||approverConfig.settype==6||approverConfig.settype==9||approverConfig.settype==10" content-position="left">审批人为空时</el-divider>
<div v-if="approverConfig.settype==2||approverConfig.settype==6||approverConfig.settype==9" class="approver_some"> <div v-if="approverConfig.settype==2||approverConfig.settype==6||approverConfig.settype==9||approverConfig.settype==10" class="approver_some">
<el-radio-group v-model="approverConfig.noHanderAction" class="clear"> <el-radio-group v-model="approverConfig.noHanderAction" class="clear">
<el-radio :label="1">自动审批通过/不允许发起</el-radio> <el-radio :label="1">自动审批通过/不允许发起</el-radio>
<br/> <br/>

4
src/styles/index.scss

@ -43,7 +43,7 @@
.el-table th.el-table__cell { .el-table th.el-table__cell {
background-color: #F4F5F9 !important; background-color: #F4F5F9 !important;
color: #020203 !important; color: #020203 !important;
font-size: 16px; // font-size: 16px;
} }
.el-table .el-table__body td.el-table__cell { .el-table .el-table__body td.el-table__cell {
@ -117,4 +117,4 @@
.glm-btn-box { .glm-btn-box {
padding: 20px 20px 0 20px; padding: 20px 20px 0 20px;
} }

1
src/utils/workflow/const.ts

@ -11,6 +11,7 @@ export let setTypes = [
{value: 4, label: '发起人自选'}, {value: 4, label: '发起人自选'},
{value: 5, label: '发起人自己'}, {value: 5, label: '发起人自己'},
{value: 6, label: '连续多级主管'}, {value: 6, label: '连续多级主管'},
{value: 10, label: '指定部门负责人'},
{value: 7, label: '指定前置审批为本节点设置审批人'}, {value: 7, label: '指定前置审批为本节点设置审批人'},
{value: 8, label: '表单字段'}, {value: 8, label: '表单字段'},
{value: 9, label: '权限矩阵'} {value: 9, label: '权限矩阵'}

2
src/utils/workflow/index.ts

@ -137,6 +137,8 @@ All.prototype = {
} }
} }
}else if (nodeConfig.settype == 9){
return "指定部门负责人"
} }
}, },
dealStr(str:any, obj:any) { dealStr(str:any, obj:any) {

30
src/views/sysworkflow/lowcodepage/appPage/appMenus.vue

@ -9,7 +9,7 @@ import type {
NodeDropType, NodeDropType,
} from 'element-plus/es/components/tree/src/tree.type' } from 'element-plus/es/components/tree/src/tree.type'
import { appMenuTreeInfo,appSetInfo } from "@/api/date/type" import { appMenuTreeInfo,appSetInfo } from "@/api/date/type"
import { gainAllAppMenu,editAppMenuCont,appMenuShowOrHide,delAppMenu } from '@/api/DesignForm/requestapi' import { gainAllAppMenu,editAppMenuCont,appMenuShowOrHide,delAppMenu,editAppMenusIcon } from '@/api/DesignForm/requestapi'
import SvgIcon from "@/components/SvgIcon/index.vue"; import SvgIcon from "@/components/SvgIcon/index.vue";
import { threeShiyanData } from "@/api/date/type" import { threeShiyanData } from "@/api/date/type"
@ -128,14 +128,16 @@ onMounted(()=>{
const svgName = ref("") const svgName = ref("")
const svgId= ref("") const svgId= ref("")
const setAppMenusSvg = (val:any) =>{ const setAppMenusSvg = (val:any) =>{
// console.log("----setAppMenusSvg--->",val)
svgName.value = val.svg svgName.value = val.svg
svgId.value = val.id svgId.value = val.id
treeList.value = val
svgIsShow.value = true; svgIsShow.value = true;
} }
watch(()=>svgName.value,(val:string)=>{ watch(()=>svgName.value,(val:string)=>{
// console.log("----svgName--->",val) // console.log("----svgName--->",val)
// console.log("----threeShiyanData--->",threeShiyanData) // console.log("----threeShiyanData--->",threeShiyanData)
diguiData(treeList.value) diguiData(appMenuTree.value)
}) })
/** /**
@ -144,11 +146,22 @@ watch(()=>svgName.value,(val:string)=>{
@ 功能: 递归判断是哪个节点换了图标 @ 功能: 递归判断是哪个节点换了图标
*/ */
const diguiData = (val:any) =>{ const diguiData = (val:any) =>{
// console.log(':', val);
if(Array.isArray(val)){ if(Array.isArray(val)){
try { try {
val.forEach((item:any) => { val.forEach((item:any) => {
// console.log('--1-->:',item.id);
// console.log('---->:',svgId.value);
if(item.id == svgId.value){ if(item.id == svgId.value){
item.svg = svgName.value item.svg = svgName.value
let sendInfo = {
id:item.id.toString(),
label:svgName.value
}
editAppMenusIcon(sendInfo)
.then(({data}) => {
})
throw item; throw item;
} }
if(item.children&&Array.isArray(item.children)){ if(item.children&&Array.isArray(item.children)){
@ -251,11 +264,20 @@ const createNewPage = (val?:string) => {
@ 功能: 判断能否拖入此节点 @ 功能: 判断能否拖入此节点
*/ */
const allowDrop = (draggingNode: Node, dropNode: Node, type: AllowDropType) => { const allowDrop = (draggingNode: Node, dropNode: Node, type: AllowDropType) => {
if (dropNode.data.type === 2) { // console.log("draggingNode--->",draggingNode)
// console.log("dropNode--->",dropNode)
// console.log("type--->",type)
// if (dropNode.data.type === 2) {
// return false
// } else {
// return true
// }
if(draggingNode.data.type === 2 && dropNode.data.type === 2 && type == "inner"){
return false return false
} else { }else{
return true return true
} }
// return true
} }
/** /**
@ 作者: 秦东 @ 作者: 秦东

31
src/views/sysworkflow/lowcodepage/appPage/releaseApp/index.vue

@ -35,21 +35,21 @@ onMounted(()=>{
isEdit.value = true; isEdit.value = true;
}) })
}) })
watch(()=>appStatue.value,(val:boolean) => { // watch(()=>appStatue.value,(val:boolean) => {
let sta = 1 // let sta = 1
if(val){ // if(val){
props.appCont.state = 1 // props.appCont.state = 1
sta = 1 // sta = 1
}else{ // }else{
props.appCont.state = 2 // props.appCont.state = 2
sta = 2 // sta = 2
} // }
setUpState(sta) // setUpState(sta)
}) // })
/** /**
@ 作者: 秦东 @ 作者: 秦东
@ 时间: 2024-05-29 14:38:01 @ 时间: 2024-05-29 14:38:01
@ -58,6 +58,7 @@ watch(()=>appStatue.value,(val:boolean) => {
const setUpState = (val:number) => { const setUpState = (val:number) => {
setCustomerFormState({id:props.appCont.uuid,state:val}) setCustomerFormState({id:props.appCont.uuid,state:val})
.then((data)=>{ .then((data)=>{
props.appCont.state = appStatue.value
// ElMessage({ // ElMessage({
// showClose: true, // showClose: true,
// message: data.msg, // message: data.msg,
@ -65,6 +66,13 @@ const setUpState = (val:number) => {
// }) // })
}) })
} }
const switchChang = () =>{
if(appStatue.value == 1){
setUpState(1)
}else{
setUpState(2)
}
}
</script> </script>
<template> <template>
<div class="appBox"> <div class="appBox">
@ -97,6 +105,7 @@ const setUpState = (val:number) => {
style="--el-switch-on-color: #13ce66; --el-switch-off-color: #ff4949" style="--el-switch-on-color: #13ce66; --el-switch-off-color: #ff4949"
active-text="已启用" active-text="已启用"
inactive-text="已停用" inactive-text="已停用"
@change="switchChang"
/> />
</td> </td>
</tr> </tr>

Loading…
Cancel
Save