fix: 复制合同剔除特批附件并主动查询客商风险
This commit is contained in:
@@ -1214,6 +1214,11 @@ const createCopiedDetail = (detail = {}) => {
|
||||
Object.keys(form).forEach(prop => {
|
||||
if (Object.prototype.hasOwnProperty.call(detail, prop)) form[prop] = detail[prop];
|
||||
});
|
||||
// 特批附件属于原合同的特批佐证,复制后须对新合同重新上传,否则会绕过高风险/黑名单校验
|
||||
const stripSpecAttachments = value => {
|
||||
const rows = parseArray(value).filter(item => item?.fileType !== '特批附件');
|
||||
return rows.length ? JSON.stringify(rows) : '';
|
||||
};
|
||||
return {
|
||||
...form,
|
||||
contractNo: '',
|
||||
@@ -1221,8 +1226,8 @@ const createCopiedDetail = (detail = {}) => {
|
||||
archiveStatus: '未归档',
|
||||
feeGenerationMode: detail.feeGenerationMode || '',
|
||||
billingEnabled: detail.billingEnabled,
|
||||
contractFileJson: detail.contractFileJson || '',
|
||||
attachmentsJson: detail.attachmentsJson || '',
|
||||
contractFileJson: stripSpecAttachments(detail.contractFileJson),
|
||||
attachmentsJson: stripSpecAttachments(detail.attachmentsJson),
|
||||
billingPlanJson: detail.billingPlanJson || '',
|
||||
paymentRatioJson: detail.paymentRatioJson || '',
|
||||
settlementRuleJson: detail.settlementRuleJson || '',
|
||||
@@ -2385,6 +2390,10 @@ export default {
|
||||
const options = [...new Set(names)].map(name => ({ label: name, value: name }));
|
||||
this.contractPartyAOptions = options;
|
||||
this.contractPartyBOptions = options;
|
||||
// 复制/编辑回填的甲乙方不会触发下拉 change,加载选项后主动查一次 C101-1 风险
|
||||
['partyA', 'partyB'].forEach(prop => {
|
||||
if (this.form[prop]) this.queryPartyRisk(prop);
|
||||
});
|
||||
})
|
||||
.finally(() => {
|
||||
if (requestId === this.contractPartyRequestId) this.contractPartyLoading = false;
|
||||
|
||||
Reference in New Issue
Block a user