improve: 装修问题处理

This commit is contained in:
From-wh 2023-04-23 16:37:00 +08:00
parent c801f89915
commit 0e3b376df9
3 changed files with 13 additions and 10 deletions

View File

@ -115,24 +115,25 @@ export default {
},
addHotTxt() {
let val = {
children: [
chiild: [
{
max: 20,
pla: '选填,不超过四个字',
title: '标题',
val: 'CRMEB v4.2.2 正式发布',
val: '',
},
{
max: 99,
pla: '选填',
title: '链接',
val: '链接',
val: '',
},
],
};
if (this.name == 'newList') {
let obj = JSON.parse(JSON.stringify(this.datas[this.name].list[this.datas[this.name].list.length - 1]));
this.datas[this.name].list.push(obj);
let arrs = this.datas[this.name].list[this.datas[this.name].list.length - 1];
let obj = arrs ? JSON.parse(JSON.stringify(arrs)) : '';
this.datas[this.name].list.push(obj || val);
return;
}
if (this.datas[this.name].list.length == 0) {

View File

@ -477,9 +477,10 @@ export default {
log(evt) {
// 中间拖拽排序
if (evt.moved) {
if (evt.moved.element.name == 'search_box') {
if (evt.moved.element.name == 'search_box' || evt.moved.element.name == 'nav_bar') {
return this.$Message.warning('该组件禁止拖拽');
}
// if (evt.moved.element.name == "nav_bar") {
// return this.$Message.warning("该组件禁止拖拽");
// }
@ -542,7 +543,7 @@ export default {
return;
}
}
if (item.name == 'search_box') {
if (item.name == 'search_box' || item.name == 'nav_bar') {
return this.$Message.warning('该组件禁止移动');
}
// if (item.name == "nav_bar") {

View File

@ -207,7 +207,7 @@ export default {
components: {
footPage,
html2canvas,
draggable: vuedraggable
draggable: vuedraggable,
},
filters: {
filterTxt(val) {
@ -402,7 +402,7 @@ export default {
log(evt) {
// 中间拖拽排序
if (evt.moved) {
if (evt.moved.element.name == 'search_box') {
if (evt.moved.element.name == 'search_box' || evt.moved.element.name == 'nav_bar') {
return this.$Message.warning('该组件禁止拖拽');
}
// if (evt.moved.element.name == "nav_bar") {
@ -467,9 +467,10 @@ export default {
return;
}
}
if (item.name == 'search_box') {
if (item.name == 'search_box' || item.name == 'nav_bar') {
return this.$Message.warning('该组件禁止移动');
}
console.log(item);
// if (item.name == "nav_bar") {
// return this.$Message.warning("该组件禁止移动");
// }