|
@@ -57,22 +57,24 @@ export default {
|
|
|
methods: {
|
|
|
...users(['query', 'delete', 'update']),
|
|
|
...exportuser({ exportuserQuery: 'query' }),
|
|
|
- async search({ skip = 0, limit = 10, ...info } = {}) {
|
|
|
+ async search({ ...info } = {}) {
|
|
|
if (this.user.code.length == 3) {
|
|
|
- const res = await this.query({ skip, limit, ...info });
|
|
|
- const resTwo = await this.exportuserQuery({ skip, limit, ...info });
|
|
|
+ const res = await this.query({ ...info });
|
|
|
+ const resTwo = await this.exportuserQuery({ ...info });
|
|
|
var newData = res.data.concat(resTwo.data);
|
|
|
if (this.$checkRes(newData)) {
|
|
|
var arr = newData.filter(item => item.pid == undefined && item.status != '3');
|
|
|
+ console.log(arr);
|
|
|
this.$set(this, `list`, arr);
|
|
|
this.$set(this, `total`, arr.length);
|
|
|
}
|
|
|
} else {
|
|
|
- const res = await this.query({ skip, limit, code: this.user.code, ...info });
|
|
|
- const resTwo = await this.exportuserQuery({ skip, limit, code: this.user.code, ...info });
|
|
|
+ const res = await this.query({ code: this.user.code, ...info });
|
|
|
+ const resTwo = await this.exportuserQuery({ code: this.user.code, ...info });
|
|
|
var newData = res.data.concat(resTwo.data);
|
|
|
if (this.$checkRes(newData)) {
|
|
|
var arr = newData.filter(item => item.pid == undefined && item.status != '3');
|
|
|
+ console.log(arr);
|
|
|
this.$set(this, `list`, arr);
|
|
|
this.$set(this, `total`, arr.length);
|
|
|
}
|