This commit is contained in:
2020-02-24 19:44:56 +00:00
parent 77f2149627
commit 9d5c608ccf

View File

@@ -500,14 +500,14 @@ export default {
//Logic for detecting if a post or put: if id then it was a post, if no id then it was a put
if (res.data.id) {
//Handle "post" of new record (CREATE)
vm.obj = res.data;
window.$gz.form.setFormState({
vm: vm,
dirty: false,
readOnly: res.readOnly ? true : false
});
// vm.obj = res.data;
// window.$gz.form.setFormState({
// vm: vm,
// dirty: false,
// readOnly: res.readOnly ? true : false
// });
//change url to new record in history and actually navigate but with the actual id at the end instead of zero:
//change url to new record in history and trigger navigate but with the id at the end instead of zero:
vm.$router.replace(
vm.$route.fullPath.slice(0, -1) + res.data.id
);