diff --git a/src/components/tinymce-editor/index.vue b/src/components/tinymce-editor/index.vue index 29a2415..0b2a2c5 100644 --- a/src/components/tinymce-editor/index.vue +++ b/src/components/tinymce-editor/index.vue @@ -38,13 +38,13 @@ export default { // skin_url: '/tinymce/skins/lightgray', height: 400, menu: { - file: {title: '文件', items: 'newdocument'}, - edit: {title: '编辑', items: 'undo redo | cut copy paste pastetext | selectall'}, - insert: {title: '插入', items: 'image | inserttable'}, - view: {title: '查看', items: 'visualaid'}, - format: {title: '格式', items: 'bold italic underline strikethrough superscript subscript | formats | removeformat'}, - table: {title: '表格', items: 'inserttable tableprops deletetable | cell row column'}, - tools: {title: '工具', items: 'spellchecker code'} + file: { title: '文件', items: 'newdocument' }, + edit: { title: '编辑', items: 'undo redo | cut copy paste pastetext | selectall' }, + insert: { title: '插入', items: 'image | inserttable' }, + view: { title: '查看', items: 'visualaid' }, + format: { title: '格式', items: 'bold italic underline strikethrough superscript subscript | formats | removeformat' }, + table: { title: '表格', items: 'inserttable tableprops deletetable | cell row column' }, + tools: { title: '工具', items: 'spellchecker code' } }, menubar: 'edit insert format table', plugins: 'powerpaste link lists image code table colorpicker textcolor wordcount contextmenu', @@ -56,16 +56,15 @@ export default { statusbar: false, powerpaste_word_import: 'merge', images_upload_handler: (blobInfo, success, failure) => { - console.log('images_upload_handler') - var form = new FormData(); - form.append('file', blobInfo.blob(), blobInfo.filename()); - axios.post(`${window.SITE_CONFIG['apiURL']}/oss/file/upload?token=${Cookies.get('token')}`, form).then(res => { - if (res.data.code == 0 && res.data.msg == 'success') { - success(res.data.data.url) - } else { - failure(res.data.msg) - } - }) + var form = new FormData() + form.append('file', blobInfo.blob(), blobInfo.filename()) + axios.post(`${window.SITE_CONFIG['apiURL']}/oss/file/upload?token=${Cookies.get('token')}`, form).then(res => { + if (res.data.code === 0 && res.data.msg === 'success') { + success(res.data.data.url) + } else { + failure(res.data.msg) + } + }) } } } @@ -79,7 +78,7 @@ export default { } }, watch: { - value: function(newVal) { + value: function (newVal) { this.tinymceHtml = newVal } }, diff --git a/src/views/modules/case/typicalcase-add-or-update.vue b/src/views/modules/case/typicalcase-add-or-update.vue index 49d34da..bc833e5 100644 --- a/src/views/modules/case/typicalcase-add-or-update.vue +++ b/src/views/modules/case/typicalcase-add-or-update.vue @@ -59,7 +59,7 @@ - + @@ -69,19 +69,6 @@ - @@ -108,13 +95,8 @@