gaoluyang
2025-02-13 3e04c2102a31ea3306277203449097cb027215ae
客户管理页面联调
已修改1个文件
16 ■■■■■ 文件已修改
src/views/system/customer/index.vue 16 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/system/customer/index.vue
@@ -105,9 +105,7 @@
      formTitle: '',
      addDia: false,
      addPower: true,
      user: {
        name: null
      },
      user: {},
      userRules: {
        company: [{ required: true, message: '请输入客户名称', trigger: 'blur' }],
        companyEn: [{ required: true, message: '请输入客户名称EN', trigger: 'blur' }],
@@ -153,19 +151,23 @@
          this.loading = true
          if (this.operationType === 'add') {
            addCustom(this.user).then(res => {
              if (res.code === 201) return
              this.loading = false
              if (res.code !== 200) return
              this.$message.success('新增成功')
              this.getList()
              this.loading = false
              this.reset()
            }).catch(err => {
              this.loading = false
            })
          } else {
            upCustom(this.user).then(res => {
              if (res.code === 201) return
              this.loading = false
              if (res.code !== 200) return
              this.$message.success('修改成功')
              this.getList()
              this.loading = false
              this.reset()
            }).catch(err => {
              this.loading = false
            })
          }
        }