Commit 0dd79b19 authored by 黄奎's avatar 黄奎

页面修改

parent 9185ecce
...@@ -90,19 +90,19 @@ ...@@ -90,19 +90,19 @@
}, },
//选择文件弹窗 //选择文件弹窗
attachmentSelected(fileArray) { attachmentSelected(fileArray) {
console.log("fileArray",fileArray);
if (fileArray&&fileArray.length) { if (fileArray&&fileArray.length) {
let html = ''; let html = '';
//图片 //图片
if (this.uploadType == 1) { if (this.uploadType == 1) {
for (let i in e) { for (let i in fileArray) {
html += '<img src="' + e[i].fileUrl + '" style="max-width: 100%;">'; html += '<img src="' + fileArray[i].fileUrl + '" style="max-width: 100%;">';
} }
} }
//附件 //附件
if (this.uploadType == 2 || this.uploadType == 3 ) { if (this.uploadType == 2 || this.uploadType == 3 ) {
for (let i in e) { for (let i in fileArray) {
var type = e[i].fileName.split('.')[1]; var type = fileArray[i].fileName.split('.')[1];
var imgUrl = ""; var imgUrl = "";
var dataName = ""; var dataName = "";
if (type == 'xlsx' || type == 'xls') { if (type == 'xlsx' || type == 'xls') {
...@@ -126,8 +126,8 @@ ...@@ -126,8 +126,8 @@
dataName = "mp3"; dataName = "mp3";
} }
html += html +=
`<p><span contenteditable="false" style="display:-webkit-box;margin-top:10px;background: #F7F8FA;padding: 14px 16px;max-width: 572px;overflow: hidden;cursor:pointer;-webkit-box-align: center;text-align:left;cursor:pointer;" name="${e[i].dataName}" data="${e[i].fileName}">` + `<p><span contenteditable="false" style="display:-webkit-box;margin-top:10px;background: #F7F8FA;padding: 14px 16px;max-width: 572px;overflow: hidden;cursor:pointer;-webkit-box-align: center;text-align:left;cursor:pointer;" name="${fileArray[i].dataName}" data="${fileArray[i].fileName}">` +
`<img src="${imgUrl}" style="width:42px; height:42px; overflow:hidden; margin-right:14px;border-radius:4px;"><span style="font-size:14px; color:#181E33; line-height:20px; display:block; overflow:hidden; text-overflow:ellipsis;">${e[i].fileName}</span></span></p>` `<img src="${imgUrl}" style="width:42px; height:42px; overflow:hidden; margin-right:14px;border-radius:4px;"><span style="font-size:14px; color:#181E33; line-height:20px; display:block; overflow:hidden; text-overflow:ellipsis;">${fileArray[i].fileName}</span></span></p>`
} }
} }
if(this.uploadType==3) if(this.uploadType==3)
...@@ -155,8 +155,8 @@ ...@@ -155,8 +155,8 @@
} }
html += html +=
`<p><span contenteditable="false" style="display:-webkit-box;margin-top:10px;background: #F7F8FA;padding: 14px 16px;max-width: 572px;overflow: hidden;cursor:pointer;-webkit-box-align: center;text-align:left;cursor:pointer;" name="${e[i].dataName}" data="${e[i].fileName}">` + `<p><span contenteditable="false" style="display:-webkit-box;margin-top:10px;background: #F7F8FA;padding: 14px 16px;max-width: 572px;overflow: hidden;cursor:pointer;-webkit-box-align: center;text-align:left;cursor:pointer;" name="${fileArray[i].dataName}" data="${fileArray[i].fileName}">` +
`<img src="${imgUrl}" style="width:42px; height:42px; overflow:hidden; margin-right:14px;border-radius:4px;"><span style="font-size:14px; color:#181E33; line-height:20px; display:block; overflow:hidden; text-overflow:ellipsis;">${e[i].fileName}</span></span></p>` `<img src="${imgUrl}" style="width:42px; height:42px; overflow:hidden; margin-right:14px;border-radius:4px;"><span style="font-size:14px; color:#181E33; line-height:20px; display:block; overflow:hidden; text-overflow:ellipsis;">${fileArray[i].fileName}</span></span></p>`
} }
} }
this.ue.execCommand('inserthtml', html); this.ue.execCommand('inserthtml', html);
......
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