|
@@ -29,6 +29,9 @@ export default {
|
|
|
|
|
|
|
|
if (this.httpType === 'get') {
|
|
if (this.httpType === 'get') {
|
|
|
this.$http.get(this.url, data, { body: 'json' }).then(res => {
|
|
this.$http.get(this.url, data, { body: 'json' }).then(res => {
|
|
|
|
|
+ if (res.first) {
|
|
|
|
|
+ this.list = [];
|
|
|
|
|
+ }
|
|
|
this.list = [...this.list, ...res.content];
|
|
this.list = [...this.list, ...res.content];
|
|
|
this.empty = res.empty;
|
|
this.empty = res.empty;
|
|
|
this.loading = false;
|
|
this.loading = false;
|
|
@@ -39,6 +42,9 @@ export default {
|
|
|
});
|
|
});
|
|
|
} else {
|
|
} else {
|
|
|
this.$http.post(this.url, data, { body: 'json' }).then(res => {
|
|
this.$http.post(this.url, data, { body: 'json' }).then(res => {
|
|
|
|
|
+ if (res.first) {
|
|
|
|
|
+ this.list = [];
|
|
|
|
|
+ }
|
|
|
this.list = [...this.list, ...res.content];
|
|
this.list = [...this.list, ...res.content];
|
|
|
this.empty = res.empty;
|
|
this.empty = res.empty;
|
|
|
this.loading = false;
|
|
this.loading = false;
|