Agency exclusions & style fixes
gitea/salix/dev This commit looks good
Details
gitea/salix/dev This commit looks good
Details
This commit is contained in:
parent
0e88343649
commit
ac5d9b909b
|
@ -29,22 +29,6 @@
|
|||
on-selection="$ctrl.onCreate($days)">
|
||||
</vn-zone-calendar>
|
||||
</vn-side-menu>
|
||||
<vn-dialog
|
||||
vn-id="dialog"
|
||||
on-response="$ctrl.onSave(response)">
|
||||
<tpl-body>
|
||||
<vn-vertical>
|
||||
<vn-date-picker
|
||||
label="Day"
|
||||
model="$ctrl.selected.day">
|
||||
</vn-date-picker>
|
||||
</vn-vertical>
|
||||
</tpl-body>
|
||||
<tpl-buttons>
|
||||
<input type="button" response="CANCEL" translate-attr="{value: 'Cancel'}"/>
|
||||
<button response="ACCEPT" translate>Save</button>
|
||||
</tpl-buttons>
|
||||
</vn-dialog>
|
||||
<vn-confirm
|
||||
vn-id="confirm"
|
||||
message="This item will be deleted"
|
||||
|
|
|
@ -18,23 +18,8 @@ class Controller extends Section {
|
|||
}
|
||||
|
||||
onCreate($days) {
|
||||
this.isNew = true;
|
||||
this.selected = {day: $days[0]};
|
||||
this.$.dialog.show();
|
||||
}
|
||||
|
||||
onSave(response) {
|
||||
if (response != 'ACCEPT') return;
|
||||
|
||||
this.$http.post(this.path, this.selected)
|
||||
.then(() => {
|
||||
this.selected = null;
|
||||
this.isNew = null;
|
||||
this.$.dialog.hide();
|
||||
this.refresh();
|
||||
});
|
||||
|
||||
return false;
|
||||
this.$http.post(this.path, {day: $days[0]})
|
||||
.then(() => this.refresh());
|
||||
}
|
||||
|
||||
onDelete(id) {
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
data="zones"
|
||||
auto-load="false">
|
||||
</vn-crud-model>
|
||||
<div class="content-block">
|
||||
<div>
|
||||
<div class="vn-list">
|
||||
<vn-card pad-medium-h>
|
||||
<vn-searchbar
|
||||
|
|
Loading…
Reference in New Issue