6d269887 by lihua

产品上架修改接口调用

1 parent e4afe105
...@@ -155,9 +155,9 @@ export const getContractDataProduct = (tenantGuid) => request({ ...@@ -155,9 +155,9 @@ export const getContractDataProduct = (tenantGuid) => request({
155 }) 155 })
156 156
157 /** 获取下拉数据产品列表的去重字段 */ 157 /** 获取下拉数据产品列表的去重字段 */
158 export const getDamFieldsByProductGuid = (productGuid) => request({ 158 export const getDamFieldsByProductGuid = (productGuid, isTds = 'N') => request({
159 url: `${import.meta.env.VITE_API_NEW_PORTAL}/dam-catalog-table/field-by-dam-guid?damGuid=${productGuid}`, 159 url: `${import.meta.env.VITE_APP_DIGITAL_CONTRACT_URL}/connector-invoke/field-by-dam-guid?damGuid=${productGuid}&isTds=${isTds}`,
160 method: 'post' 160 method: 'get'
161 }) 161 })
162 162
163 /** 创建合约 */ 163 /** 创建合约 */
......
...@@ -405,65 +405,69 @@ const tableBtnClick = (scope, btn) => { ...@@ -405,65 +405,69 @@ const tableBtnClick = (scope, btn) => {
405 405
406 } 406 }
407 if (type == 'pass') { 407 if (type == 'pass') {
408 if (getFirstNodePromise.value[row.guid]) { 408 // if (getFirstNodePromise.value[row.guid]) {
409 return; 409 // return;
410 }
411 getFirstNodePromise.value[row.guid] = isMyFirstNode({
412 deploymentId: row.approveVO.camundaDeploymentId,
413 processInstanceId: row.approveVO.camundaInstanceId,
414 staffGuid: userData.staffGuid
415 }).then((res: any) => {
416 getFirstNodePromise.value[row.guid] = null;
417 if (res?.code == proxy.$passCode) {
418 if (res.data) {
419 approveSuggest.value = '';
420 dynamicPlaceholder.value = '请填写通过理由(选填)';
421 // if (listingFormRef.value) {
422 // clearFormValues(listingFormRef.value.formInline);
423 // listingFormRef.value.ruleFormRef.clearValidate(formInfo.value.items.map(item => item.field))
424 // listingFormRef.value.ruleFormRef.resetFields(formInfo.value.items.map(item => item.field))
425 // } 410 // }
426
427 approveType.value = 'pass';
428 dialogTitle.value = '通过流程'
429 dialogVisible.value = true;
430 } else {
431 passCommonDialogInfo.value.visible = true; 411 passCommonDialogInfo.value.visible = true;
432 } 412 passCommonDialogInfo.value.contents[0].formInfo.items[0].default = '';
433 } else { 413 // getFirstNodePromise.value[row.guid] = isMyFirstNode({
434 proxy.$ElMessage.error(res.msg); 414 // deploymentId: row.approveVO.camundaDeploymentId,
435 } 415 // processInstanceId: row.approveVO.camundaInstanceId,
436 }) 416 // staffGuid: userData.staffGuid
417 // }).then((res: any) => {
418 // getFirstNodePromise.value[row.guid] = null;
419 // if (res?.code == proxy.$passCode) {
420 // if (res.data) {
421 // approveSuggest.value = '';
422 // dynamicPlaceholder.value = '请填写通过理由(选填)';
423 // // if (listingFormRef.value) {
424 // // clearFormValues(listingFormRef.value.formInline);
425 // // listingFormRef.value.ruleFormRef.clearValidate(formInfo.value.items.map(item => item.field))
426 // // listingFormRef.value.ruleFormRef.resetFields(formInfo.value.items.map(item => item.field))
427 // // }
428
429 // approveType.value = 'pass';
430 // dialogTitle.value = '通过流程'
431 // dialogVisible.value = true;
432 // } else {
433 // passCommonDialogInfo.value.visible = true;
434 // }
435 // } else {
436 // proxy.$ElMessage.error(res.msg);
437 // }
438 // })
437 } 439 }
438 if (type == 'reject') { 440 if (type == 'reject') {
439 if (getFirstNodePromise1.value[row.guid]) {
440 return;
441 }
442 getFirstNodePromise1.value[row.guid] = isMyFirstNode({
443 deploymentId: row.approveVO.camundaDeploymentId,
444 processInstanceId: row.approveVO.camundaInstanceId,
445 staffGuid: userData.staffGuid
446 }).then((res: any) => {
447 getFirstNodePromise1.value[row.guid] = null;
448 if (res?.code == proxy.$passCode) {
449 if (res.data) {
450 approveSuggest.value = '';
451 dynamicPlaceholder.value = '请填写驳回理由(必填)';
452 // if (listingFormRef.value) {
453 // clearFormValues(listingFormRef.value.formInline);
454 // listingFormRef.value.ruleFormRef.clearValidate(formInfo.value.items.map(item => item.field))
455 // listingFormRef.value.ruleFormRef.resetFields(formInfo.value.items.map(item => item.field))
456 // }
457 approveType.value = 'reject';
458 dialogTitle.value = '驳回流程'
459 dialogVisible.value = true;
460 } else {
461 rejectDialogInfo.value.visible = true; 441 rejectDialogInfo.value.visible = true;
462 } 442 rejectDialogInfo.value.contents[0].formInfo.items[0].default = '';
463 } else { 443 // if (getFirstNodePromise1.value[row.guid]) {
464 proxy.$ElMessage.error(res.msg); 444 // return;
465 } 445 // }
466 }) 446 // getFirstNodePromise1.value[row.guid] = isMyFirstNode({
447 // deploymentId: row.approveVO.camundaDeploymentId,
448 // processInstanceId: row.approveVO.camundaInstanceId,
449 // staffGuid: userData.staffGuid
450 // }).then((res: any) => {
451 // getFirstNodePromise1.value[row.guid] = null;
452 // if (res?.code == proxy.$passCode) {
453 // if (res.data) {
454 // approveSuggest.value = '';
455 // dynamicPlaceholder.value = '请填写驳回理由(必填)';
456 // // if (listingFormRef.value) {
457 // // clearFormValues(listingFormRef.value.formInline);
458 // // listingFormRef.value.ruleFormRef.clearValidate(formInfo.value.items.map(item => item.field))
459 // // listingFormRef.value.ruleFormRef.resetFields(formInfo.value.items.map(item => item.field))
460 // // }
461 // approveType.value = 'reject';
462 // dialogTitle.value = '驳回流程'
463 // dialogVisible.value = true;
464 // } else {
465 // rejectDialogInfo.value.visible = true;
466 // }
467 // } else {
468 // proxy.$ElMessage.error(res.msg);
469 // }
470 // })
467 } 471 }
468 if (type == 'up') { 472 if (type == 'up') {
469 if (row.exchangeGuid) { 473 if (row.exchangeGuid) {
...@@ -662,6 +666,7 @@ const passCommonDialogInfo = ref({ ...@@ -662,6 +666,7 @@ const passCommonDialogInfo = ref({
662 field: "approveSuggest", 666 field: "approveSuggest",
663 clearable: true, 667 clearable: true,
664 maxlength: 400, 668 maxlength: 400,
669 default: '',
665 block: true, 670 block: true,
666 col: 'margin_b_0', 671 col: 'margin_b_0',
667 } 672 }
...@@ -725,6 +730,7 @@ const rejectDialogInfo = ref({ ...@@ -725,6 +730,7 @@ const rejectDialogInfo = ref({
725 type: "textarea", 730 type: "textarea",
726 placeholder: "请填写驳回理由(必填)", 731 placeholder: "请填写驳回理由(必填)",
727 field: "approveSuggest", 732 field: "approveSuggest",
733 default: '',
728 clearable: true, 734 clearable: true,
729 block: true, 735 block: true,
730 col: 'margin_b_0', 736 col: 'margin_b_0',
......
Styling with Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!