From daae3c89e763d62f3ed0ffe1fbd91c3855919e58 Mon Sep 17 00:00:00 2001 From: lvjunzhao <967725@dms.yudean.com> Date: Thu, 10 Apr 2025 17:12:15 +0800 Subject: [PATCH 1/6] =?UTF-8?q?feat:=E7=99=BB=E5=BD=95-=E6=96=B0=E5=A2=9E?= =?UTF-8?q?=E7=94=A8=E6=88=B7=E8=B4=A6=E5=8F=B7=E7=99=BB=E5=BD=95=20?= =?UTF-8?q?=E9=AA=8C=E8=AF=81=E7=A0=81=20ipBlock=201.=20=E6=96=B0=E5=A2=9E?= =?UTF-8?q?=20=E7=99=BB=E5=BD=95=E7=9A=84=20=E5=9B=BE=E5=BD=A2=E6=A0=A1?= =?UTF-8?q?=E9=AA=8C=E7=A0=81=202.=20=E9=81=97=E8=90=BD=E9=97=AE=E9=A2=98?= =?UTF-8?q?=EF=BC=8C=E7=99=BB=E5=BD=95=E9=A1=B5=E7=9A=84=E6=8F=90=E4=BA=A4?= =?UTF-8?q?=EF=BC=8C=E8=A1=A8=E5=8D=95=E5=85=A8=E9=83=A8=E7=BB=9F=E4=B8=80?= =?UTF-8?q?=E4=BA=86=E3=80=82=E6=B2=A1=E6=9C=89=E5=8C=BA=E5=88=86=E7=B1=BB?= =?UTF-8?q?=E5=9E=8B=EF=BC=8C=E8=80=8C=E4=B8=94=E7=B1=BB=E5=9E=8B=E7=9A=84?= =?UTF-8?q?=E6=9E=9A=E4=B8=BE=E5=92=8C=E6=A0=A1=E9=AA=8C=E6=B2=A1=E7=9C=9F?= =?UTF-8?q?=E6=AD=A3=E4=BD=BF=E7=94=A8=E3=80=82=E8=BF=98=E6=9C=89=E5=85=B6?= =?UTF-8?q?=E4=BB=96=E5=8A=9F=E8=83=BD=E5=A6=82=E6=B3=A8=E5=86=8C=EF=BC=8C?= =?UTF-8?q?=E6=94=B9=E5=AF=86=E7=A0=81=E9=83=BD=E6=B2=A1=E5=BC=80=E5=87=BA?= =?UTF-8?q?=E6=9D=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/system/login/index.ts | 12 ++ src/api/system/login/model/index.ts | 1 + src/views/secondDev/Login.vue | 5 + src/views/secondDev/LoginForm.vue | 89 +++++++++++++-- src/views/sys/login/useLogin.ts | 11 ++ src/views/system/loginSetting/loginInfo.vue | 120 ++++++++++++++++++++ 6 files changed, 231 insertions(+), 7 deletions(-) diff --git a/src/api/system/login/index.ts b/src/api/system/login/index.ts index 87320dc..506fda1 100644 --- a/src/api/system/login/index.ts +++ b/src/api/system/login/index.ts @@ -34,6 +34,7 @@ enum Api { loginConfig = '/system/loginConfig', mobileLoginCode = '/system/captcha', mobileLoginImg = '/system/captchaImg', + checkAccountCaptcha = '/system/checkAccountCaptcha', } /** @@ -262,3 +263,14 @@ export function sendMobileLoginCode(params, mode: ErrorMessageMode = 'modal') { }, ); } +export function checkAccountCaptchaApi(params, mode: ErrorMessageMode = 'modal') { + return defHttp.get( + { + url: Api.checkAccountCaptcha, + params: params, + }, + { + errorMessageMode: mode, + }, + ); +} diff --git a/src/api/system/login/model/index.ts b/src/api/system/login/model/index.ts index b95ba73..9eecbce 100644 --- a/src/api/system/login/model/index.ts +++ b/src/api/system/login/model/index.ts @@ -8,6 +8,7 @@ export interface LoginParams { password: string; tenantCode: string; deviceType?: number; + captchaCode: string; } export interface RoleInfo { diff --git a/src/views/secondDev/Login.vue b/src/views/secondDev/Login.vue index ecef95d..7a9bf68 100644 --- a/src/views/secondDev/Login.vue +++ b/src/views/secondDev/Login.vue @@ -279,3 +279,8 @@ } } + diff --git a/src/views/secondDev/LoginForm.vue b/src/views/secondDev/LoginForm.vue index d712a2a..a1e3165 100644 --- a/src/views/secondDev/LoginForm.vue +++ b/src/views/secondDev/LoginForm.vue @@ -3,7 +3,7 @@
- + @@ -17,6 +17,22 @@ + + + + + + + @@ -43,8 +59,10 @@ + + +
+ {{ t('添加会签事件') }} +
+ + + + +
+ +
+ {{ t('添加预审前事件') }} +
+ + + + +
+ +
+ {{ t('添加预审后事件') }} +
+ + + + +
+ +
+ {{ t('添加同意事件') }} +
+ + + + +
+ +
+ {{ t('添加退回事件') }} +
+ + + + +
@@ -167,6 +479,9 @@ import Sortable from 'sortablejs'; import { NodeEventExType } from '/@/enums/workflowEnum'; import { NodeEventConfig } from '/@/model/workflow/workflowConfig'; + import { + BpmnNodeKey, + } from '/@/enums/workflowEnum'; const { t } = useI18n(); const { showPanel, formInfo, nodeName } = useStateFormInfo(); const updateElementName = inject('updateElementName') as any; @@ -222,7 +537,12 @@ () => { if ( formInfo.value.endEventConfigs?.length > 0 || - formInfo.value.startEventConfigs?.length > 0 + formInfo.value.startEventConfigs?.length > 0 || + formInfo.value.setSignEventConfigs?.length > 0 || + formInfo.value.prequalifyBeforeEventConfigs?.length > 0 || + formInfo.value.prequalifyAfterEventConfigs?.length > 0 || + formInfo.value.agreeEventConfigs?.length > 0 || + formInfo.value.rejectEventConfigs?.length > 0 ) { nextTick(() => { const tbody: any = document.querySelector('.ant-table-tbody'); @@ -246,6 +566,66 @@ const getList = async () => { liteFlowOptions.value = (await getLiteflowList()) || []; }; + + //新增会签 因为旧值中不包含,所以html 判断node节点,这里对add 可以新增空数组 + const addSetSignEvent = () => { + formInfo.value.setSignEventConfigs = formInfo.value.setSignEventConfigs==null?[]:formInfo.value.setSignEventConfigs; + formInfo.value.setSignEventConfigs.push({ + type: NodeEventExType.API, + apiConfig: {}, + } as NodeEventConfig); + }; + const deleteSetSignEvent = (index) => { + formInfo.value.setSignEventConfigs.splice(index, 1); + }; + + // 预审前 因为旧值中不包含,所以html 判断node节点,这里对add 可以新增空数组 + const addPrequalifyBeforeEvent = () => { + formInfo.value.prequalifyBeforeEventConfigs = formInfo.value.prequalifyBeforeEventConfigs==null?[]:formInfo.value.prequalifyBeforeEventConfigs; + formInfo.value.prequalifyBeforeEventConfigs.push({ + type: NodeEventExType.API, + apiConfig: {}, + } as NodeEventConfig); + }; + const deletePrequalifyBeforeEvent = (index) => { + formInfo.value.prequalifyBeforeEventConfigs.splice(index, 1); + }; + + // 预审后 因为旧值中不包含,所以html 判断node节点,这里对add 可以新增空数组 + const addPrequalifyAfterEvent = () => { + formInfo.value.prequalifyAfterEventConfigs = formInfo.value.prequalifyAfterEventConfigs==null?[]:formInfo.value.prequalifyAfterEventConfigs; + formInfo.value.prequalifyAfterEventConfigs.push({ + type: NodeEventExType.API, + apiConfig: {}, + } as NodeEventConfig); + }; + const deletePrequalifyAfterEvent = (index) => { + formInfo.value.prequalifyAfterEventConfigs.splice(index, 1); + }; + + // 同意 因为旧值中不包含,所以html 判断node节点,这里对add 可以新增空数组 + const addAgreeEvent = () => { + formInfo.value.agreeEventConfigs = formInfo.value.agreeEventConfigs==null?[]:formInfo.value.agreeEventConfigs; + formInfo.value.agreeEventConfigs.push({ + type: NodeEventExType.API, + apiConfig: {}, + } as NodeEventConfig); + }; + const deleteAgreeEvent = (index) => { + formInfo.value.agreeEventConfigs.splice(index, 1); + }; + + // 退回 因为旧值中不包含,所以html 判断node节点,这里对add 可以新增空数组 + const addRejectEvent = () => { + formInfo.value.rejectEventConfigs = formInfo.value.rejectEventConfigs==null?[]:formInfo.value.rejectEventConfigs; + formInfo.value.rejectEventConfigs.push({ + type: NodeEventExType.API, + apiConfig: {}, + } as NodeEventConfig); + }; + const deleteRejectEvent = (index) => { + formInfo.value.rejectEventConfigs.splice(index, 1); + }; \ No newline at end of file + diff --git a/src/views/system/group/components/Form.vue b/src/views/system/group/components/Form.vue index 315841f..7664367 100644 --- a/src/views/system/group/components/Form.vue +++ b/src/views/system/group/components/Form.vue @@ -110,8 +110,8 @@ await systemFormRef.value.resetFields(); } // 设置表单数据全部为Disabled 【查看】 - async function setDisabledForm() { - data.formDataProps.schemas = changeSchemaDisabled(cloneDeep(data.formDataProps.schemas)); + async function setDisabledForm(isDisabled) { + data.formDataProps.schemas = changeSchemaDisabled(cloneDeep(data.formDataProps.schemas), isDisabled); } // 获取行键值 function getRowKey() { diff --git a/src/views/workflow/task/ProcessMonitor.vue b/src/views/workflow/task/ProcessMonitor.vue index a70baec..53b3dda 100644 --- a/src/views/workflow/task/ProcessMonitor.vue +++ b/src/views/workflow/task/ProcessMonitor.vue @@ -57,7 +57,11 @@ - + {{ t('关闭') }} @@ -22,20 +22,20 @@ import { onActivated, onMounted, ref } from 'vue'; import { useI18n } from '/@/hooks/web/useI18n'; const { t } = useI18n(); - const props = defineProps({ - processId: { - type: String, - default: '' - }, - taskId: { - type: String, - default: '' - }, - visible: { - type: Boolean, - default: false - }, - }) + const props = withDefaults( + defineProps<{ + processId: string; + taskId: string; + schemaId: string; + visible?: boolean; + }>(), + { + processId: '', + taskId: '', + schemaId: '', + visible: false, + }, +); let emits = defineEmits(['close']); let visible = ref(false); let showLoading = ref(false); diff --git a/src/views/workflow/task/components/WorkflowApprovalProcess.vue b/src/views/workflow/task/components/WorkflowApprovalProcess.vue index 1c03108..3f2f50b 100644 --- a/src/views/workflow/task/components/WorkflowApprovalProcess.vue +++ b/src/views/workflow/task/components/WorkflowApprovalProcess.vue @@ -10,6 +10,7 @@ :taskRecords="data.taskRecords" :predecessorTasks="selectedPredecessorTasks" :processId="props.processId" + :schemaId="props.schemaId" position="top" > -
{{ item.formName }} +
+ +
{{ item.formName }}
@@ -38,25 +39,11 @@
-
- - -
+ + @@ -383,7 +370,7 @@ }; } - function handleCancel() { +function handleCancel() { itemRefs.value[activeIndex.value].setDisabledForm(true); forms.modes[activeIndex.value] = 'view'; itemRefs.value[activeIndex.value].setFieldsValue(forms.formModels[activeIndex.value]); diff --git a/src/views/workflow/task/components/flow/LookTask.vue b/src/views/workflow/task/components/flow/LookTask.vue index b38ecd7..cfc735e 100644 --- a/src/views/workflow/task/components/flow/LookTask.vue +++ b/src/views/workflow/task/components/flow/LookTask.vue @@ -1,5 +1,5 @@