guhongwei 5 anni fa
parent
commit
853d2e2454
1 ha cambiato i file con 3 aggiunte e 1 eliminazioni
  1. 3 1
      src/views/admin-user/index.vue

+ 3 - 1
src/views/admin-user/index.vue

@@ -27,6 +27,7 @@ import topInfo from '@/layout/public/top.vue';
 import dataForm from '@/components/form.vue';
 import { mapState, createNamespacedHelpers } from 'vuex';
 const { mapActions: authUser } = createNamespacedHelpers('authUser');
+const { mapActions: users } = createNamespacedHelpers('users');
 export default {
   name: 'index',
   props: {},
@@ -74,8 +75,9 @@ export default {
   },
   methods: {
     ...authUser(['query', 'update', 'create']),
+    ...users({ usersQuery: 'qiery', usersUpdate: 'update', usersCrate: 'create' }),
     async search({ skip = 0, limit = 10, ...info } = {}) {
-      const res = await this.query({ skip, limit, ...info, role: '4' });
+      const res = await this.query({ skip, limit, ...info });
       if (this.$checkRes(res)) {
         this.$set(this, `list`, res.data);
         this.$set(this, `total`, res.total);