|
@@ -141,7 +141,7 @@ import upload from '@/components/uploadone.vue';
|
|
|
import dataTable from '@/components/data-table.vue';
|
|
|
import { mapState, createNamespacedHelpers } from 'vuex';
|
|
|
const { mapActions: users } = createNamespacedHelpers('users');
|
|
|
-const { mapActions: exportuser } = createNamespacedHelpers('exportuser');
|
|
|
+const { mapActions: expertsuser } = createNamespacedHelpers('expertsuser');
|
|
|
export default {
|
|
|
name: 'index',
|
|
|
props: {},
|
|
@@ -218,7 +218,7 @@ export default {
|
|
|
},
|
|
|
methods: {
|
|
|
...users(['create', 'query', 'update', 'delete', 'userquery']),
|
|
|
- ...exportuser({ exportuserFetch: 'fetch', exportuserCreate: 'create', exportuserUpdate: 'update' }),
|
|
|
+ ...expertsuser({ exportuserFetch: 'fetch', exportuserCreate: 'create', exportuserUpdate: 'update' }),
|
|
|
async search({ skip = 0, limit = 10, pid = '', ...info } = {}) {
|
|
|
if (this.user.code.length == 3) {
|
|
|
const res = await this.userquery({ skip, limit, ...info });
|
|
@@ -247,6 +247,7 @@ export default {
|
|
|
async handleSave() {
|
|
|
let data = this.form;
|
|
|
if (data.role == '4' || data.role == '5') {
|
|
|
+ data.id = data.uid;
|
|
|
let res = await this.update(data);
|
|
|
if (this.$checkRes(res)) {
|
|
|
this.$message({
|
|
@@ -256,10 +257,11 @@ export default {
|
|
|
this.handleClose();
|
|
|
}
|
|
|
} else if (data.role == '6') {
|
|
|
+ data.id = data.uid;
|
|
|
let res = await this.exportuserUpdate(data);
|
|
|
if (this.$checkRes(res)) {
|
|
|
this.$message({
|
|
|
- message: '添加信息成功',
|
|
|
+ message: '修改信息成功',
|
|
|
type: 'success',
|
|
|
});
|
|
|
this.handleClose();
|