show whether data is updated after pull down

This commit is contained in:
MaysWind
2023-06-18 22:43:47 +08:00
parent 55ad7b2e81
commit eb2e2b0a26
15 changed files with 102 additions and 17 deletions
+6 -1
View File
@@ -58,13 +58,18 @@ export default {
},
reload(done) {
const self = this;
const force = !!done;
self.transactionCategoriesStore.loadAllCategories({
force: true
force: force
}).then(() => {
if (done) {
done();
}
if (force) {
self.$toast('Category list has been updated');
}
}).catch(error => {
if (done) {
done();
+6 -1
View File
@@ -242,13 +242,18 @@ export default {
}
const self = this;
const force = !!done;
self.transactionCategoriesStore.loadAllCategories({
force: true
force: force
}).then(() => {
if (done) {
done();
}
if (force) {
self.$toast('Category list has been updated');
}
}).catch(error => {
if (done) {
done();