|
@@ -41,7 +41,7 @@
|
|
|
</el-table-column>
|
|
|
<el-table-column align="center" label="操作" width="180">
|
|
|
<template slot-scope="scope">
|
|
|
- <el-button type="text" @click="addOrEdit('edit', scope.row)">修改</el-button>
|
|
|
+ <el-button type="text" @click="addOrEdit('edit', scope.row)">重置密码</el-button>
|
|
|
<!-- <el-button
|
|
|
v-if="checkBtnRole('detail')"
|
|
|
type="text"
|
|
@@ -117,7 +117,7 @@
|
|
|
<el-form-item v-if="addFormType !== 'edit'" label="账号" prop="account">
|
|
|
<el-input v-model="ruleForm.account" type="text" autocomplete="off" disabled placeholder="系统自动生成" />
|
|
|
</el-form-item>
|
|
|
- <el-form-item label="子经销商" prop="customerId">
|
|
|
+ <el-form-item v-if="addFormType !== 'edit'" label="子经销商" prop="customerId">
|
|
|
<el-select v-model="ruleForm.customerId" placeholder="请选择子经销商" filterable style="width:100%">
|
|
|
<el-option
|
|
|
v-for="item in subCustomerList"
|
|
@@ -152,7 +152,7 @@ import {
|
|
|
getMenuList,
|
|
|
getRoleChecked,
|
|
|
setMenuRole,
|
|
|
- changePassword
|
|
|
+ resetPassword
|
|
|
} from '@/api/setting'
|
|
|
|
|
|
export default {
|
|
@@ -299,10 +299,9 @@ export default {
|
|
|
}
|
|
|
if (valid) {
|
|
|
if (this.addFormType === 'edit') {
|
|
|
- changePassword({
|
|
|
- userName: this.ruleForm.account,
|
|
|
- password: this.ruleForm.password,
|
|
|
- newPassword: this.ruleForm.password
|
|
|
+ resetPassword({
|
|
|
+ adminUserId: this.ruleForm.adminUserId,
|
|
|
+ password: this.ruleForm.password
|
|
|
}).then(res => {
|
|
|
this.cancelAddForm()
|
|
|
this.getList()
|