diff --git a/src/components/Panel/index.vue b/src/components/Panel/index.vue index 6e7337e..cd46e96 100644 --- a/src/components/Panel/index.vue +++ b/src/components/Panel/index.vue @@ -511,9 +511,9 @@ const submit = async () => { projectId: param.projectId, projectName: projectList.value.find((e) => e.projectId == param.projectId)?.projectName, lcId: curReq.value, - assessmentId: param.assessmentId, systemId: curSystemId.value, purpose: pd.value.experimentTarget, // 实验目的 + assessmentId: param.assessmentId, competitionId: param.competitionId, stageId: param.stageId, teamId: param.teamId, diff --git a/src/utils/common.ts b/src/utils/common.ts index f1b9b19..712ea3b 100644 --- a/src/utils/common.ts +++ b/src/utils/common.ts @@ -229,3 +229,15 @@ export const isIllegalNum = (str: string | number): boolean => { export const getFileExt = (fileName: string): string => { return fileName.substring(fileName.lastIndexOf('.') + 1); }; + +/** + * 返回projectId、checkpointId、assessmentId、competitionId + */ +export const getIds = (): Record => { + return { + checkpointId: +Cookies.get('sand-level') || '', + projectId: +Cookies.get('sand-projectId') || '', + assessmentId: +Cookies.get('sand-assessmentId') || '', + competitionId: +Cookies.get('sand-competitionId') || '', + }; +}; diff --git a/src/views/product/afterLoan/1029.vue b/src/views/product/afterLoan/1029.vue index 41c0fd1..6e66b1f 100644 --- a/src/views/product/afterLoan/1029.vue +++ b/src/views/product/afterLoan/1029.vue @@ -92,7 +92,7 @@ import { ref, onMounted } from 'vue'; import { ElMessage } from 'element-plus'; import { fiveLevelClassificationDetails, fiveLevelClassificationSave } from '@/api/model'; -import { getProcessInformationBasedOnRoles, addOperation } from '@/api/judgment'; +import { getProcessInformationBasedOnRoles, addOperation, getIds } from '@/api/judgment'; import { handleId } from '@/utils/common'; import Cookies from 'js-cookie'; @@ -146,10 +146,9 @@ const addRecord = async (data: Record) => { }); await addOperation({ - checkpointId: levelId, + ...getIds(), parentId: preIds, lcJudgmentRuleReq: rule, - projectId, }); }; // 提交 diff --git a/src/views/product/afterLoan/1030.vue b/src/views/product/afterLoan/1030.vue index 5279436..4dc24af 100644 --- a/src/views/product/afterLoan/1030.vue +++ b/src/views/product/afterLoan/1030.vue @@ -76,7 +76,7 @@ import { ref, onMounted } from 'vue'; import { ElMessage } from 'element-plus'; import { postLoanInspectionDetails, postLoanInspectionSave } from '@/api/model'; -import { getProcessInformationBasedOnRoles, addOperation } from '@/api/judgment'; +import { getProcessInformationBasedOnRoles, addOperation, getIds } from '@/api/judgment'; import type { TableColumnCtx } from 'element-plus'; import { handleId } from '@/utils/common'; import Cookies from 'js-cookie'; @@ -158,10 +158,9 @@ const addRecord = async (data: Record) => { }); await addOperation({ - checkpointId: levelId, + ...getIds(), parentId: preIds, lcJudgmentRuleReq: rule, - projectId, }); }; // 提交 diff --git a/src/views/product/afterLoan/1031.vue b/src/views/product/afterLoan/1031.vue index 53b3740..9d87671 100644 --- a/src/views/product/afterLoan/1031.vue +++ b/src/views/product/afterLoan/1031.vue @@ -168,7 +168,7 @@ import { ref, onMounted } from 'vue'; import { ElMessage } from 'element-plus'; import { postCreditScoreDetails, postCreditScoreSave } from '@/api/model'; -import { getProcessInformationBasedOnRoles, addOperation } from '@/api/judgment'; +import { getProcessInformationBasedOnRoles, addOperation, getIds } from '@/api/judgment'; import type { TableColumnCtx } from 'element-plus'; import { handleId } from '@/utils/common'; import Cookies from 'js-cookie'; @@ -308,10 +308,9 @@ const addRecord = async (data: Record) => { data[13].formulaOne && rule.push(handleId(1083, 291, data[13].formulaOne, `${preIds},1082,1083`, 1)); await addOperation({ - checkpointId: levelId, + ...getIds(), parentId: preIds, lcJudgmentRuleReq: rule, - projectId, }); }; // 提交 diff --git a/src/views/product/afterLoan/1032.vue b/src/views/product/afterLoan/1032.vue index 42a00cc..bf32f16 100644 --- a/src/views/product/afterLoan/1032.vue +++ b/src/views/product/afterLoan/1032.vue @@ -48,7 +48,7 @@ import { ref, onMounted } from 'vue'; import { ElMessage } from 'element-plus'; import { postLoanWarningDetails, postLoanWarningSave } from '@/api/model'; -import { getProcessInformationBasedOnRoles, addOperation } from '@/api/judgment'; +import { getProcessInformationBasedOnRoles, addOperation, getIds } from '@/api/judgment'; import { handleId } from '@/utils/common'; import Cookies from 'js-cookie'; @@ -97,10 +97,9 @@ const addRecord = async (data: Record) => { }); await addOperation({ - checkpointId: levelId, + ...getIds(), parentId: preIds, lcJudgmentRuleReq: rule, - projectId, }); }; // 提交 diff --git a/src/views/product/afterLoan/1033.vue b/src/views/product/afterLoan/1033.vue index 114d67a..e21e67f 100644 --- a/src/views/product/afterLoan/1033.vue +++ b/src/views/product/afterLoan/1033.vue @@ -45,7 +45,7 @@ import { ref, onMounted } from 'vue'; import { ElMessage } from 'element-plus'; import { collectionAfterLoanDetails, collectionAfterLoanSave } from '@/api/model'; -import { getProcessInformationBasedOnRoles, addOperation } from '@/api/judgment'; +import { getProcessInformationBasedOnRoles, addOperation, getIds } from '@/api/judgment'; import { handleId } from '@/utils/common'; import Cookies from 'js-cookie'; @@ -106,10 +106,9 @@ const addRecord = async (data: Record) => { }); await addOperation({ - checkpointId: levelId, + ...getIds(), parentId: preIds, lcJudgmentRuleReq: rule, - projectId, }); }; // 提交 diff --git a/src/views/product/bank/Add.vue b/src/views/product/bank/Add.vue index 44e8178..fbb7afb 100644 --- a/src/views/product/bank/Add.vue +++ b/src/views/product/bank/Add.vue @@ -274,7 +274,7 @@ import { ref, reactive, computed, watch, onMounted, defineEmits } from 'vue'; import { ElMessage } from 'element-plus'; import type { TabsPaneContext, FormInstance, FormRules } from 'element-plus'; import { findById, save, update } from '@/api/bank'; -import { getProcessInformationBasedOnRoles, addOperation } from '@/api/judgment'; +import { getProcessInformationBasedOnRoles, addOperation, getIds } from '@/api/judgment'; import { useRouter, useRoute } from 'vue-router'; import { handleId, isIllegalNum } from '@/utils/common'; import { getStatus } from '@/store/useProduct'; @@ -490,10 +490,9 @@ const addRecord = async (data: Record) => { lcRule.push(handleId(58, 140, data.whetherToSupportEarlyRepayment ? 345 : 346, preIds + ',58', 1)); await addOperation({ - checkpointId: levelId, + ...getIds(), parentId: preIds, lcJudgmentRuleReq: lcRule, - projectId, }); }; onMounted(() => { diff --git a/src/views/product/bank/Approve.vue b/src/views/product/bank/Approve.vue index e1d93a0..f089218 100644 --- a/src/views/product/bank/Approve.vue +++ b/src/views/product/bank/Approve.vue @@ -61,7 +61,7 @@ import Info from './Info.vue'; import { handleId } from '@/utils/common'; import { findById, examineAndApprove } from '@/api/bank'; import { getTheCurrentUserName, getOperationTime } from '@/api/config'; -import { getProcessInformationBasedOnRoles, addOperation } from '@/api/judgment'; +import { getProcessInformationBasedOnRoles, addOperation, getIds } from '@/api/judgment'; import dayjs from 'dayjs'; import Cookies from 'js-cookie'; @@ -112,10 +112,9 @@ const addRecord = async (data: Record) => { handleId(approved ? 1217 : 758, 233, signed.value ? 514 : 515, `${preIds},${approved ? '1217' : '758'}`, 1), ]; await addOperation({ - checkpointId: levelId, + ...getIds(), parentId: preIds, lcJudgmentRuleReq: lcRule, - projectId, }); }; // 提交 diff --git a/src/views/product/bank/Config.vue b/src/views/product/bank/Config.vue index 07e6eb2..652e95a 100644 --- a/src/views/product/bank/Config.vue +++ b/src/views/product/bank/Config.vue @@ -336,7 +336,7 @@ import { ref, reactive, computed, watch, onMounted } from 'vue'; import { ElMessage } from 'element-plus'; import type { TabsPaneContext, FormInstance } from 'element-plus'; import { findById, riskSave, riskUpdate } from '@/api/bank'; -import { getProcessInformationBasedOnRoles, addOperation } from '@/api/judgment'; +import { getProcessInformationBasedOnRoles, addOperation, getIds } from '@/api/judgment'; import { listCredit } from '@/api/model'; import { useRouter, useRoute } from 'vue-router'; import { handleId } from '@/utils/common'; @@ -622,10 +622,9 @@ const addRecord = async (data: Record) => { } await addOperation({ - checkpointId: levelId, + ...getIds(), parentId: preIds, lcJudgmentRuleReq: lcRule, - projectId, }); }; diff --git a/src/views/product/fund/Add.vue b/src/views/product/fund/Add.vue index 38c9778..41f863a 100644 --- a/src/views/product/fund/Add.vue +++ b/src/views/product/fund/Add.vue @@ -315,7 +315,7 @@ import { ref, reactive, computed, watch, onMounted, defineEmits } from 'vue'; import { ElMessage } from 'element-plus'; import { Plus, Minus } from '@element-plus/icons-vue'; import { getAListOfAShares, saveFund } from '@/api/fund'; -import { getProcessInformationBasedOnRoles, addOperation } from '@/api/judgment'; +import { getProcessInformationBasedOnRoles, addOperation, getIds } from '@/api/judgment'; import { useRouter, useRoute } from 'vue-router'; import { handleId, isIllegalNum } from '@/utils/common'; import Cookies from 'js-cookie'; @@ -503,10 +503,9 @@ const addRecord = async (data: Record) => { ); await addOperation({ - checkpointId: levelId, + ...getIds(), parentId: preIds, lcJudgmentRuleReq: rule, - projectId, }); }; // 提交 diff --git a/src/views/product/insurance/Add.vue b/src/views/product/insurance/Add.vue index 0dc62d5..3c9f4de 100644 --- a/src/views/product/insurance/Add.vue +++ b/src/views/product/insurance/Add.vue @@ -115,7 +115,7 @@ import { ref, reactive, computed, watch, onMounted, defineEmits } from 'vue'; import { ElMessage } from 'element-plus'; import { insuranceProductDetails, addInsuranceProducts } from '@/api/insurance'; -import { getProcessInformationBasedOnRoles, addOperation } from '@/api/judgment'; +import { getProcessInformationBasedOnRoles, addOperation, getIds } from '@/api/judgment'; import { useRouter, useRoute } from 'vue-router'; import { handleId, isIllegalNum } from '@/utils/common'; import Cookies from 'js-cookie'; @@ -201,10 +201,9 @@ const addRecord = async (data: Record) => { data.exemptionFromLiability && rule.push(handleId(301, 139, data.exemptionFromLiability, preIds + ',301', 1)); await addOperation({ - checkpointId: levelId, + ...getIds(), parentId: preIds, lcJudgmentRuleReq: rule, - projectId, }); }; // 提交 diff --git a/src/views/product/interestRate/772.vue b/src/views/product/interestRate/772.vue index 13831ab..bcef96c 100644 --- a/src/views/product/interestRate/772.vue +++ b/src/views/product/interestRate/772.vue @@ -87,7 +87,7 @@ import { ref, onMounted } from 'vue'; import { ElMessage, ElLoading } from 'element-plus'; import { personalCreditModelDetails, personalCreditModelSaveOrUpdate } from '@/api/model'; -import { getProcessInformationBasedOnRoles, addOperation } from '@/api/judgment'; +import { getProcessInformationBasedOnRoles, addOperation, getIds } from '@/api/judgment'; import type { TableColumnCtx } from 'element-plus'; import { useRouter, useRoute } from 'vue-router'; import { handleId } from '@/utils/common'; @@ -277,10 +277,9 @@ const addRecord = async (data: Record) => { } }); await addOperation({ - checkpointId: levelId, + ...getIds(), parentId: preIds, lcJudgmentRuleReq: rule, - projectId, }); }; // 提交 diff --git a/src/views/product/interestRate/773.vue b/src/views/product/interestRate/773.vue index 65e98c7..579bdbf 100644 --- a/src/views/product/interestRate/773.vue +++ b/src/views/product/interestRate/773.vue @@ -88,7 +88,7 @@ import { ref, onMounted } from 'vue'; import { ElMessage, ElLoading } from 'element-plus'; import { businessQuotaModelDetails, businessQuotaModelSaveOrUpdate } from '@/api/model'; -import { getProcessInformationBasedOnRoles, addOperation } from '@/api/judgment'; +import { getProcessInformationBasedOnRoles, addOperation, getIds } from '@/api/judgment'; import { useRouter, useRoute } from 'vue-router'; import { handleId } from '@/utils/common'; import Cookies from 'js-cookie'; @@ -153,10 +153,9 @@ const addRecord = async (data: Record) => { data.sixthMode && rule.push(handleId(785, 237, getItemId(data.sixthMode), preIds + ',784,785', 1)); await addOperation({ - checkpointId: levelId, + ...getIds(), parentId: preIds, lcJudgmentRuleReq: rule, - projectId, }); }; // 提交 diff --git a/src/views/product/interestRate/935.vue b/src/views/product/interestRate/935.vue index a633cdb..003f18c 100644 --- a/src/views/product/interestRate/935.vue +++ b/src/views/product/interestRate/935.vue @@ -20,13 +20,14 @@