This commit is contained in:
2020-02-21 20:41:25 +00:00
parent ab355de84d
commit 4049fa747b

View File

@@ -1,6 +1,6 @@
<template>
<v-container>
<div>
<!-- <div>
READY: {{ formState.ready }}
<br />
LOADING: {{ formState.loading }}
@@ -12,7 +12,7 @@
READONLY: {{ formState.readOnly }}
<br />
</div>
<!-- -->
-->
<v-row v-if="this.formState.ready">
<v-col>
@@ -427,25 +427,26 @@
const FORM_KEY = "ay-data-list-view";
const API_BASE_URL = "DataListView/";
export default {
beforeRouteEnter(to, from, next) {
var ltKeysRequired = ["DataListView", "GridFilterName"];
// beforeRouteEnter(to, from, next) {
// var ltKeysRequired = ["DataListView", "GridFilterName"];
window.$gz.locale.fetch(ltKeysRequired).then(next);
},
beforeRouteLeave(to, from, next) {
//var vm = this;
if (this.formState.dirty) {
window.$gz.dialog.confirmLeaveUnsaved().then(dialogResult => {
if (dialogResult == true) {
next();
} else {
next(false);
}
});
} else {
next();
}
},
// window.$gz.locale.fetch(ltKeysRequired).then(next);
// },
//unsaved changes are actually valid for this form so no need to warn
// beforeRouteLeave(to, from, next) {
// //var vm = this;
// if (this.formState.dirty) {
// window.$gz.dialog.confirmLeaveUnsaved().then(dialogResult => {
// if (dialogResult == true) {
// next();
// } else {
// next(false);
// }
// });
// } else {
// next();
// }
// },
beforeDestroy() {
window.$gz.eventBus.$off("menu-click", clickHandler);
},
@@ -939,6 +940,8 @@ function initForm(vm) {
//
function fetchUILocalizedText(vm) {
var ltKeysRequired = [
"DataListView",
"GridFilterName",
"Include",
"AnyUser",
"Sort",