Commit f32597b5 by 姜鹏凯

update

1 parent 617a7828
...@@ -192,7 +192,7 @@ ...@@ -192,7 +192,7 @@
this.aliOss() this.aliOss()
} }
}, },
aliOss() { async aliOss() {
this.loading = true this.loading = true
let file = undefined let file = undefined
if (!this.multiple || this.limit == 1) { if (!this.multiple || this.limit == 1) {
...@@ -210,20 +210,17 @@ ...@@ -210,20 +210,17 @@
return return
} }
let name = `/${dateFormat(date, 'yyyy-MM-dd')}/t${date.getTime()}-${uuid()}${format}` let name = `/${dateFormat(date, 'yyyy-MM-dd')}/t${date.getTime()}-${uuid()}${format}`
this.ossObj try {
.multipartUpload(name, file, { const data = await this.ossObj.multipartUpload(name, file, {
progress: (progressData) => { progress: (progressData) => {
console.log(progressData) console.log(progressData)
this.percentage = progressData.percent * 100 this.percentage = progressData.percent * 100
this.speed = (progressData.speed / 1024 / 1024).toFixed(2) this.speed = (progressData.speed / 1024 / 1024).toFixed(2)
} }
}) })
.then((err1, data) => { if (data) {
console.log(data)
this.percentage = this.speed = 0 this.percentage = this.speed = 0
if (err1) {
this.loading = false
this.$message.error('上传失败,请稍后再试')
} else {
let location = 'https://' + data.Location let location = 'https://' + data.Location
this.$emit('upSuccess', location) this.$emit('upSuccess', location)
this.type == 2 this.type == 2
...@@ -247,10 +244,10 @@ ...@@ -247,10 +244,10 @@
this.$emit('update:fileList', this.fileList.concat({ name, url: location })) this.$emit('update:fileList', this.fileList.concat({ name, url: location }))
} }
} }
}) } catch (e) {
.catch((err) => { this.loading = false
console.log(err) this.$message.error('上传失败,请稍后再试')
}) }
}, },
tencentFn() { tencentFn() {
this.loading = true this.loading = true
...@@ -290,7 +287,6 @@ ...@@ -290,7 +287,6 @@
}, },
(err1, data) => { (err1, data) => {
this.percentage = this.speed = 0 this.percentage = this.speed = 0
console.log(data)
if (err1) { if (err1) {
this.loading = false this.loading = false
this.$message.error('上传失败,请稍后再试') this.$message.error('上传失败,请稍后再试')
......
...@@ -7,7 +7,7 @@ ...@@ -7,7 +7,7 @@
<TextareaExtend <TextareaExtend
:disabled="isDetail" :disabled="isDetail"
v-model="talkForm.templateInfo" v-model="talkForm.templateInfo"
:toolbar="['emoji', 'insertCustomerNickName']" :toolbar="['emoji']"
maxlength="2000" maxlength="2000"
show-word-limit show-word-limit
placeholder="请输入" placeholder="请输入"
...@@ -300,6 +300,9 @@ ...@@ -300,6 +300,9 @@
baseData(val) { baseData(val) {
if (val.templateInfo) { if (val.templateInfo) {
this.form.templateInfo = val.templateInfo this.form.templateInfo = val.templateInfo
console.log(222222)
console.log(val)
console.log(3333333)
this.form.attachments = val.attachments this.form.attachments = val.attachments
if (this.form.templateInfo) { if (this.form.templateInfo) {
// this.form.templateInfo = this.baseData.templateInfo // this.form.templateInfo = this.baseData.templateInfo
......
...@@ -258,6 +258,12 @@ ...@@ -258,6 +258,12 @@
}, },
created() { created() {
this.getList() this.getList()
this.$store.dispatch(
'app/setBusininessDesc',
`
<div>通过群发、朋友圈、应用消息等多种推广形式快捷推广智能短链,触达客户</div>
`
)
} }
} }
</script> </script>
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!