+ client: handle clear statistics

This commit is contained in:
Ildar Kamalov 2019-08-30 18:35:27 +03:00
parent 883910c19e
commit 63049e0521
8 changed files with 91 additions and 34 deletions
client/src/api

View file

@ -496,6 +496,7 @@ export default class Api {
GET_STATS = { path: 'stats', method: 'GET' };
STATS_INFO = { path: 'stats_info', method: 'GET' };
STATS_CONFIG = { path: 'stats_config', method: 'POST' };
STATS_RESET = { path: 'stats_reset', method: 'POST' };
getStats() {
const { path, method } = this.GET_STATS;
@ -515,4 +516,9 @@ export default class Api {
};
return this.makeRequest(path, method, config);
}
resetStats() {
const { path, method } = this.STATS_RESET;
return this.makeRequest(path, method);
}
}