diff --git a/src/views/business/project-apply.vue b/src/views/business/project-apply.vue
index 8b61737..a4a10f4 100644
--- a/src/views/business/project-apply.vue
+++ b/src/views/business/project-apply.vue
@@ -525,6 +525,11 @@
+
+
+ {{ formatGuangxiTop100(row.guangxiTop100) }}
+
+
取消
取消
-
- 保存
-
提交
@@ -1903,13 +1905,7 @@ export default {
this.closeProjectForm();
});
},
- saveChangeProject() {
- this.submitChangeForm(false);
- },
submitChangeProject() {
- this.submitChangeForm(true);
- },
- submitChangeForm(needSubmit) {
this.$refs.projectForm.validate(valid => {
if (!valid) {
this.handleValidateFail();
@@ -1917,19 +1913,12 @@ export default {
}
if (!this.validateAttachmentFileTypes()) return;
this.submitLoading = true;
- const request = needSubmit ? this.api.submitChange : this.api.saveChange;
- request(this.normalizeSubmitForm({ includeChangeType: true }))
+ // 变更记录仅在提交时生成,保存草稿不落记录
+ this.api
+ .submitChange(this.normalizeSubmitForm({ includeChangeType: true }))
.then(res => {
if (res.data?.success === false || res.data?.data === false) {
- this.$message.error(
- res.data?.msg || `${needSubmit ? '提交' : '保存'}失败,请联系管理员`
- );
- return;
- }
- if (!needSubmit) {
- this.$message.success('保存成功!');
- this.closeProjectForm();
- this.onLoad(this.page, this.query);
+ this.$message.error(res.data?.msg || '提交失败,请联系管理员');
return;
}
const id = this.form.id;
@@ -2122,6 +2111,11 @@ export default {
normalizeReadonlyAmount(value) {
return this.normalizeOptionalSentinel(value);
},
+ formatGuangxiTop100(value) {
+ if (value === 1 || value === '1') return '是';
+ if (value === 0 || value === '0') return '否';
+ return value || '';
+ },
normalizeOptionalSentinel(value, emptyValue = '') {
return value === null || value === undefined || value === '' || Number(value) === -1
? emptyValue
@@ -2528,6 +2522,8 @@ export default {
id: item.id,
credit: item.maxCreditLimit || item.applyCreditLimit || '',
companyNature: item.customerNature || '',
+ guangxiTop100:
+ item.guangxiTop100 === 0 || item.guangxiTop100 === 1 ? item.guangxiTop100 : null,
legalPerson: item.legalPerson || '',
address: item.registeredAddress || '',
contact: defaultContact.contactName || item.principal || '',