html格式化优化
This commit is contained in:
@@ -207,13 +207,20 @@
|
||||
</el-button>
|
||||
</span>
|
||||
</el-dialog>
|
||||
<el-dialog ref="multAdd" title="Add in bulk" z-index="1000"
|
||||
<el-dialog ref="multAdd" title="Html layOut" z-index="1000"
|
||||
:visible.sync="multAddVisible"
|
||||
width="800px">
|
||||
<div>
|
||||
<div class="logtips">
|
||||
<p >Paste the contents of the wold file here, delete the carriage return at the end and click "Submit".</p>
|
||||
</div>
|
||||
<div class="istitle" v-if="saveMode == 'edit'">
|
||||
<span>Title set: </span>
|
||||
<el-radio-group v-model="multAdd.isTitle">
|
||||
<el-radio :label="0">Is not title</el-radio>
|
||||
<el-radio :label="1">Is title</el-radio>
|
||||
</el-radio-group>
|
||||
</div>
|
||||
<vue-ueditor-wrap v-model="wordText" :config="editorConfig" editor-id="editor-demo-01"></vue-ueditor-wrap>
|
||||
</div>
|
||||
<span slot="footer">
|
||||
@@ -276,6 +283,8 @@ import VueUeditorWrap from 'vue-ueditor-wrap'; // ES6 Module
|
||||
|
||||
contents:[], // 识别出的word引用数组
|
||||
article_main_id:null,
|
||||
isTitle:0
|
||||
|
||||
},
|
||||
saveMode:''
|
||||
|
||||
@@ -363,9 +372,10 @@ import VueUeditorWrap from 'vue-ueditor-wrap'; // ES6 Module
|
||||
saveEdit(){
|
||||
this.$api
|
||||
.post('api/Production/editWebMain', {
|
||||
article_main_id: this.multAdd.article_main_id,
|
||||
type: 'content',
|
||||
content: this.wordText
|
||||
'article_main_id': this.multAdd.article_main_id,
|
||||
'type': 'content',
|
||||
'content': this.wordText,
|
||||
'is_title':this.multAdd.isTitle
|
||||
})
|
||||
.then(res => {
|
||||
if (res.code == 0) {
|
||||
@@ -374,6 +384,7 @@ import VueUeditorWrap from 'vue-ueditor-wrap'; // ES6 Module
|
||||
this.multAdd.article_main_id = ''
|
||||
this.wordText = ''
|
||||
this.saveMode = ''
|
||||
this.multAdd.isTitle = 0
|
||||
this.getDate()
|
||||
} else {
|
||||
this.$message.error(res.msg);
|
||||
@@ -390,7 +401,7 @@ import VueUeditorWrap from 'vue-ueditor-wrap'; // ES6 Module
|
||||
'article_id':this.Art_web_Id ,
|
||||
'pre_id': this.multAdd.pre_id,
|
||||
'type': 'content',
|
||||
'content': this.wordText,
|
||||
'content': this.wordText,
|
||||
})
|
||||
.then(res => {
|
||||
if (res.code == 0) {
|
||||
@@ -398,7 +409,7 @@ import VueUeditorWrap from 'vue-ueditor-wrap'; // ES6 Module
|
||||
this.multAddVisible = false
|
||||
this.multAdd.pre_id = ''
|
||||
this.wordText = ''
|
||||
this.saveMode = ''
|
||||
this.saveMode = ''
|
||||
this.getDate()
|
||||
} else {
|
||||
this.$message.error(res.msg);
|
||||
@@ -450,6 +461,7 @@ import VueUeditorWrap from 'vue-ueditor-wrap'; // ES6 Module
|
||||
this.multAdd.article_main_id = val.article_main_id;
|
||||
this.wordText = val.text
|
||||
this.multAddVisible = true
|
||||
this.multAdd.isTitle = val.is_title
|
||||
this.saveMode = 'edit'
|
||||
// 以前的
|
||||
// this.txtVisible = true
|
||||
@@ -943,4 +955,5 @@ import VueUeditorWrap from 'vue-ueditor-wrap'; // ES6 Module
|
||||
height: 120px;
|
||||
display: block;
|
||||
}
|
||||
.istitle{margin: 20px 0;}
|
||||
</style>
|
||||
|
||||
Reference in New Issue
Block a user