This commit is contained in:
@@ -6,14 +6,14 @@
|
||||
<v-flex xs12 mt-1 mb-2>
|
||||
<v-alert
|
||||
ref="errorbox"
|
||||
v-show="this.$gzv.ErrorBoxErrors(this)"
|
||||
v-show="errorBoxMessage"
|
||||
color="error"
|
||||
icon="fa-exclamation-circle "
|
||||
value="true"
|
||||
transition="scale-transition"
|
||||
class="multi-line"
|
||||
outline
|
||||
>{{this.$gzv.ErrorBoxErrors(this)}}</v-alert>
|
||||
>{{errorBoxMessage}}</v-alert>
|
||||
</v-flex>
|
||||
<v-flex xs12 sm6 lg4 xl3 px-2>
|
||||
<v-text-field
|
||||
@@ -174,6 +174,7 @@ export default {
|
||||
return {
|
||||
obj: {},
|
||||
serverError: {},
|
||||
errorBoxMessage:null,
|
||||
formReady: false
|
||||
};
|
||||
},
|
||||
@@ -194,11 +195,13 @@ export default {
|
||||
var url = "Widget/" + this.$route.params.id;
|
||||
|
||||
//clear any errors that might be around from previous submit
|
||||
this.$gzutil.RemoveAllPropertiesFromObject(this.serverError);
|
||||
this.$gzv.ClearServerErrors(this);
|
||||
//this.$gzutil.RemoveAllPropertiesFromObject(this.serverError);
|
||||
|
||||
this.$gzapi.upsert(url, this.obj).then(res => {
|
||||
if (res.error) {
|
||||
that.serverError = res.error;
|
||||
that.$gzv.SetErrorBoxErrors(that);
|
||||
} else {
|
||||
//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.id) {
|
||||
|
||||
Reference in New Issue
Block a user