浏览代码

feat: 账户管理新增是否商用经销商

Howie 1 年之前
父节点
当前提交
41707ea226
共有 1 个文件被更改,包括 13 次插入3 次删除
  1. 13 3
      src/views/setting/account.vue

+ 13 - 3
src/views/setting/account.vue

@@ -228,7 +228,7 @@
         :model="AccountForm"
         :rules="AccountFormRules"
         label-position="left"
-        label-width="80px"
+        label-width="100px"
       >
         <el-form-item label="账号" prop="account">
           <el-input v-model="AccountForm.account" autocomplete="off" placeholder="请输入账号" />
@@ -345,6 +345,13 @@
             />
           </el-select>
         </el-form-item>
+        <el-form-item label="商用经销商" prop="isShangyong">
+          <el-radio-group v-model="AccountForm.isShangyong" size="mini">
+            <el-radio v-for="item in [{label:'是',value:true},{label:'否', value:false}]" :key="item.value" :label="item.value">
+              {{item.label}}
+            </el-radio>
+          </el-radio-group>
+        </el-form-item>
       </el-form>
       <div slot="footer" class="dialog-footer">
         <el-button @click="cancelAccountForm">取 消</el-button>
@@ -492,14 +499,15 @@ export default {
         isDiscount: true,
         newPassword: '', // 新密码
         confirmPassword: '', // 确认密码
-        k3CategoryIds: []
+        k3CategoryIds: [],
+        isShangyong: false, // 是否商用经销商
       },
       AccountFormRules: {
         account: [{ required: true, validator: validateName, trigger: 'blur' }],
         nickName: [{ required: true, message: '请输入用户名', trigger: 'blur' }],
         role: [{ required: true, message: '请选择角色组', trigger: 'change' }],
         correspondIds: [{ required: true, message: '请选择可用仓库', trigger: 'change' }],
-
+        isShangyong: [{ required: true, message: '请选择商用经销商', trigger: 'change' }],
         newPassword: [{ required: true, validator: validatePass3, trigger: 'blur' }],
         confirmPassword: [{ required: true, validator: validatePass4, trigger: 'blur' }]
       },
@@ -778,6 +786,7 @@ export default {
           this.AccountForm.isDiscount = res.data.isZr
           this.AccountForm.correspondIds = res.data.stockCorrespondList
           this.AccountForm.k3CategoryIds = res.data.k3CategoryList
+          this.AccountForm.isShangyong = res.data.isShangyong
           this.$refs.tree.setCheckedKeys(res.data.adminWebsitIds || [])
         })
       }
@@ -815,6 +824,7 @@ export default {
             roleId: this.AccountForm.role,
             password: this.AccountForm.newPassword,
             correspondIds: this.AccountForm.correspondIds,
+            isShangyong: this.AccountForm.isShangyong,
             categoryIds
           }