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

页面修改

parent 9185ecce
......@@ -90,19 +90,19 @@
},
//选择文件弹窗
attachmentSelected(fileArray) {
console.log("fileArray",fileArray);
if (fileArray&&fileArray.length) {
let html = '';
//图片
if (this.uploadType == 1) {
for (let i in e) {
html += '<img src="' + e[i].fileUrl + '" style="max-width: 100%;">';
for (let i in fileArray) {
html += '<img src="' + fileArray[i].fileUrl + '" style="max-width: 100%;">';
}
}
//附件
if (this.uploadType == 2 || this.uploadType == 3 ) {
for (let i in e) {
var type = e[i].fileName.split('.')[1];
for (let i in fileArray) {
var type = fileArray[i].fileName.split('.')[1];
var imgUrl = "";
var dataName = "";
if (type == 'xlsx' || type == 'xls') {
......@@ -126,8 +126,8 @@
dataName = "mp3";
}
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}">` +
`<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>`
`<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;">${fileArray[i].fileName}</span></span></p>`
}
}
if(this.uploadType==3)
......@@ -155,8 +155,8 @@
}
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}">` +
`<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>`
`<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;">${fileArray[i].fileName}</span></span></p>`
}
}
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