reload_card_volume
gitea/salix/2080-reload_card_volume This commit looks good Details

This commit is contained in:
Bernat Exposito Domenech 2020-02-07 07:43:22 +01:00
parent 4deda8588b
commit 2f81727594
2 changed files with 3 additions and 5 deletions

View File

@ -1,5 +1,5 @@
<vn-portal slot="menu">
<vn-route-descriptor route="$ctrl.route"></vn-route-descriptor>
<vn-route-descriptor route="$ctrl.route" card-reload="$ctrl.reload()"></vn-route-descriptor>
<vn-left-menu source="card"></vn-left-menu>
</vn-portal>
<ui-view></ui-view>

View File

@ -70,7 +70,7 @@ class Controller {
let url = `Routes/${this.route.id}/updateVolume`;
this.$http.post(url).then(() => {
this.vnApp.showSuccess(this.$translate.instant('Volume updated'));
if (this.card) this.card.reload();
this.cardReload();
});
}
}
@ -82,10 +82,8 @@ ngModule.component('vnRouteDescriptor', {
template: require('./index.html'),
bindings: {
route: '<',
cardReload: '&?',
quicklinks: '<'
},
require: {
card: '^?vnRouteCard'
},
controller: Controller
});