Only set the tags of they're not null

parent a21b6919
...@@ -31,7 +31,9 @@ ...@@ -31,7 +31,9 @@
}, },
watch: { watch: {
currentTags: function () { currentTags: function () {
this.tags = this.currentTags; if (this.currentTags !== null) {
this.tags = this.currentTags;
}
} }
}, },
mounted() { mounted() {
......
...@@ -69914,7 +69914,8 @@ Object.defineProperty(__webpack_exports__, "__esModule", { value: true }); ...@@ -69914,7 +69914,8 @@ Object.defineProperty(__webpack_exports__, "__esModule", { value: true });
mixins: [__WEBPACK_IMPORTED_MODULE_1__Core_Assets_js_mixins_Translate__["a" /* default */], __WEBPACK_IMPORTED_MODULE_2__Core_Assets_js_mixins_Slugify__["a" /* default */]], mixins: [__WEBPACK_IMPORTED_MODULE_1__Core_Assets_js_mixins_Translate__["a" /* default */], __WEBPACK_IMPORTED_MODULE_2__Core_Assets_js_mixins_Slugify__["a" /* default */]],
props: { props: {
locales: { default: null }, locales: { default: null },
pageId: { default: null } pageId: { default: null },
route: { default: null }
}, },
data: function data() { data: function data() {
return { return {
...@@ -69948,7 +69949,7 @@ Object.defineProperty(__webpack_exports__, "__esModule", { value: true }); ...@@ -69948,7 +69949,7 @@ Object.defineProperty(__webpack_exports__, "__esModule", { value: true });
this.form = new __WEBPACK_IMPORTED_MODULE_3_form_backend_validation___default.a(_.merge(this.page, { tags: this.tags })); this.form = new __WEBPACK_IMPORTED_MODULE_3_form_backend_validation___default.a(_.merge(this.page, { tags: this.tags }));
this.loading = true; this.loading = true;
this.form.post(route('api.page.page.store')).then(function (response) { this.form.post(this.route).then(function (response) {
_this.loading = false; _this.loading = false;
_this.$message({ _this.$message({
type: 'success', type: 'success',
...@@ -70933,7 +70934,9 @@ Object.defineProperty(__webpack_exports__, "__esModule", { value: true }); ...@@ -70933,7 +70934,9 @@ Object.defineProperty(__webpack_exports__, "__esModule", { value: true });
}, },
watch: { watch: {
currentTags: function currentTags() { currentTags: function currentTags() {
this.tags = this.currentTags; if (this.currentTags !== null) {
this.tags = this.currentTags;
}
} }
}, },
mounted: function mounted() { mounted: function mounted() {
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment