d0f9b24a by lxs

数据资产登记更新

1 parent 8e4f7bc0
...@@ -943,7 +943,7 @@ const passDialogInfo = ref({ ...@@ -943,7 +943,7 @@ const passDialogInfo = ref({
943 footer: { 943 footer: {
944 btns: [ 944 btns: [
945 { type: "default", label: "取消", value: "cancel" }, 945 { type: "default", label: "取消", value: "cancel" },
946 { type: "primary", label: "确定", value: "submit" }, 946 { type: "primary", label: "确定", value: "submit", loading: false },
947 ], 947 ],
948 }, 948 },
949 }); 949 });
...@@ -975,6 +975,7 @@ const passDialogBtnClick = (btn, info) => { ...@@ -975,6 +975,7 @@ const passDialogBtnClick = (btn, info) => {
975 if (submitPromise.value) { 975 if (submitPromise.value) {
976 return; 976 return;
977 } 977 }
978 passDialogInfo.value.footer.btns[1].loading = true;
978 let params = { 979 let params = {
979 guid: detailInfo.value.approveVO.approveGuid, 980 guid: detailInfo.value.approveVO.approveGuid,
980 flowType: detailInfo.value.approveVO.flowType, 981 flowType: detailInfo.value.approveVO.flowType,
...@@ -983,6 +984,7 @@ const passDialogBtnClick = (btn, info) => { ...@@ -983,6 +984,7 @@ const passDialogBtnClick = (btn, info) => {
983 } 984 }
984 submitPromise.value = passFlowData(params, tenantGuid).then((res: any) => { 985 submitPromise.value = passFlowData(params, tenantGuid).then((res: any) => {
985 submitPromise.value = null; 986 submitPromise.value = null;
987 passDialogInfo.value.footer.btns[1].loading = false;
986 if (res?.code == proxy.$passCode) { 988 if (res?.code == proxy.$passCode) {
987 if (res.data) { 989 if (res.data) {
988 ElMessage.success('审批成功'); 990 ElMessage.success('审批成功');
...@@ -995,11 +997,14 @@ const passDialogBtnClick = (btn, info) => { ...@@ -995,11 +997,14 @@ const passDialogBtnClick = (btn, info) => {
995 } else { 997 } else {
996 ElMessage.error(res.msg); 998 ElMessage.error(res.msg);
997 } 999 }
1000 }).catch(() => {
1001 passDialogInfo.value.footer.btns[1].loading = false;
998 }); 1002 });
999 } else if (detailType.value == 'qualityEvaluate') { 1003 } else if (detailType.value == 'qualityEvaluate') {
1000 if (submitPromise.value) { 1004 if (submitPromise.value) {
1001 return; 1005 return;
1002 } 1006 }
1007 passDialogInfo.value.footer.btns[1].loading = true;
1003 submitPromise.value = qualityAllow({ 1008 submitPromise.value = qualityAllow({
1004 bizGuid: detailInfo.value.guid, 1009 bizGuid: detailInfo.value.guid,
1005 flowType: detailInfo.value.approveVO.flowType, 1010 flowType: detailInfo.value.approveVO.flowType,
...@@ -1017,6 +1022,7 @@ const passDialogBtnClick = (btn, info) => { ...@@ -1017,6 +1022,7 @@ const passDialogBtnClick = (btn, info) => {
1017 }) || [], 1022 }) || [],
1018 }, tenantGuid).then((res: any) => { 1023 }, tenantGuid).then((res: any) => {
1019 submitPromise.value = null; 1024 submitPromise.value = null;
1025 passDialogInfo.value.footer.btns[1].loading = false;
1020 if (res?.code == proxy.$passCode) { 1026 if (res?.code == proxy.$passCode) {
1021 if (res.data) { 1027 if (res.data) {
1022 ElMessage.success('审批成功'); 1028 ElMessage.success('审批成功');
...@@ -1034,6 +1040,7 @@ const passDialogBtnClick = (btn, info) => { ...@@ -1034,6 +1040,7 @@ const passDialogBtnClick = (btn, info) => {
1034 if (submitPromise.value) { 1040 if (submitPromise.value) {
1035 return; 1041 return;
1036 } 1042 }
1043 passDialogInfo.value.footer.btns[1].loading = true;
1037 submitPromise.value = costAssessAllow({ 1044 submitPromise.value = costAssessAllow({
1038 bizGuid: detailInfo.value.guid, 1045 bizGuid: detailInfo.value.guid,
1039 flowType: detailInfo.value.approveVO.flowType, 1046 flowType: detailInfo.value.approveVO.flowType,
...@@ -1050,6 +1057,7 @@ const passDialogBtnClick = (btn, info) => { ...@@ -1050,6 +1057,7 @@ const passDialogBtnClick = (btn, info) => {
1050 }) || [] 1057 }) || []
1051 }, tenantGuid).then((res: any) => { 1058 }, tenantGuid).then((res: any) => {
1052 submitPromise.value = null; 1059 submitPromise.value = null;
1060 passDialogInfo.value.footer.btns[1].loading = false;
1053 if (res?.code == proxy.$passCode) { 1061 if (res?.code == proxy.$passCode) {
1054 if (res.data) { 1062 if (res.data) {
1055 ElMessage.success('审批成功'); 1063 ElMessage.success('审批成功');
...@@ -1067,6 +1075,7 @@ const passDialogBtnClick = (btn, info) => { ...@@ -1067,6 +1075,7 @@ const passDialogBtnClick = (btn, info) => {
1067 if (submitPromise.value) { 1075 if (submitPromise.value) {
1068 return; 1076 return;
1069 } 1077 }
1078 passDialogInfo.value.footer.btns[1].loading = true;
1070 submitPromise.value = updateCertificate({ 1079 submitPromise.value = updateCertificate({
1071 guid: certificateGuid.value, 1080 guid: certificateGuid.value,
1072 tenantGuid: userData.tenantGuid, 1081 tenantGuid: userData.tenantGuid,
...@@ -1075,6 +1084,7 @@ const passDialogBtnClick = (btn, info) => { ...@@ -1075,6 +1084,7 @@ const passDialogBtnClick = (btn, info) => {
1075 documentFile: info.documentFile?.map(f => f.url) || [] 1084 documentFile: info.documentFile?.map(f => f.url) || []
1076 }).then((res: any) => { 1085 }).then((res: any) => {
1077 submitPromise.value = null; 1086 submitPromise.value = null;
1087 passDialogInfo.value.footer.btns[1].loading = false;
1078 if (res?.code == proxy.$passCode) { 1088 if (res?.code == proxy.$passCode) {
1079 ElMessage.success('该资产发证确认成功'); 1089 ElMessage.success('该资产发证确认成功');
1080 passDialogInfo.value.visible = false; 1090 passDialogInfo.value.visible = false;
...@@ -1121,7 +1131,7 @@ const rejectDialogInfo = ref({ ...@@ -1121,7 +1131,7 @@ const rejectDialogInfo = ref({
1121 footer: { 1131 footer: {
1122 btns: [ 1132 btns: [
1123 { type: "default", label: "取消", value: "cancel" }, 1133 { type: "default", label: "取消", value: "cancel" },
1124 { type: "primary", label: "确定", value: "submit", loading: true }, 1134 { type: "primary", label: "确定", value: "submit", loading: false },
1125 ], 1135 ],
1126 }, 1136 },
1127 }); 1137 });
......
...@@ -417,7 +417,7 @@ const passDialogInfo = ref({ ...@@ -417,7 +417,7 @@ const passDialogInfo = ref({
417 footer: { 417 footer: {
418 btns: [ 418 btns: [
419 { type: "default", label: "取消", value: "cancel" }, 419 { type: "default", label: "取消", value: "cancel" },
420 { type: "primary", label: "确定", value: "submit" }, 420 { type: "primary", label: "确定", value: "submit", loading: false },
421 ], 421 ],
422 }, 422 },
423 }); 423 });
......
Styling with Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!