|
@@ -97,27 +97,33 @@ export default {
|
|
let toDay = moment().format('YYYY-MM-DD HH:mm:ss');
|
|
let toDay = moment().format('YYYY-MM-DD HH:mm:ss');
|
|
this.$set(this, `toDay`, toDay);
|
|
this.$set(this, `toDay`, toDay);
|
|
await this.search();
|
|
await this.search();
|
|
|
|
+ await this.initNode();
|
|
},
|
|
},
|
|
mounted() {
|
|
mounted() {
|
|
this.channel();
|
|
this.channel();
|
|
if (this.serveTime) {
|
|
if (this.serveTime) {
|
|
- this.searchNode();
|
|
|
|
|
|
+ // this.searchNode();
|
|
this.searchNode = false;
|
|
this.searchNode = false;
|
|
}
|
|
}
|
|
},
|
|
},
|
|
methods: {
|
|
methods: {
|
|
...topmessage(['query', 'querytwo']),
|
|
...topmessage(['query', 'querytwo']),
|
|
- async search({ skip = 0, limit = 300, ...info } = {}) {
|
|
|
|
|
|
+ async search({ skip = 0, limit = 20, ...info } = {}) {
|
|
let res = await this.query({ skip, limit, ...info });
|
|
let res = await this.query({ skip, limit, ...info });
|
|
if (this.$checkRes(res)) {
|
|
if (this.$checkRes(res)) {
|
|
this.$set(this, `hyyh`, res.data);
|
|
this.$set(this, `hyyh`, res.data);
|
|
this.$set(this, `hyyy`, res.data.reverse());
|
|
this.$set(this, `hyyy`, res.data.reverse());
|
|
}
|
|
}
|
|
},
|
|
},
|
|
- // 页面一次性请求
|
|
|
|
- async searchNode() {
|
|
|
|
- let res = await this.querytwo();
|
|
|
|
|
|
+ async initNode() {
|
|
|
|
+ const time = moment(this.toDay).format('YYYY-MM-DD');
|
|
|
|
+ let res = await this.querytwo({ skip: 0, limit: 35, time });
|
|
|
|
+ if (this.$checkRes(res)) {
|
|
|
|
+ this.$set(this, 'hyjd', res.data);
|
|
|
|
+ }
|
|
},
|
|
},
|
|
|
|
+ // 页面一次性请求
|
|
|
|
+ async searchNode() {},
|
|
channel() {
|
|
channel() {
|
|
this.$stomp({
|
|
this.$stomp({
|
|
[`/exchange/service_count/nodes`]: this.onMessage,
|
|
[`/exchange/service_count/nodes`]: this.onMessage,
|