29944
This commit is contained in:
@@ -141,12 +141,21 @@
|
|||||||
|
|
||||||
addPhoto () {
|
addPhoto () {
|
||||||
uni.chooseImage({
|
uni.chooseImage({
|
||||||
count: 1,
|
count: 9,
|
||||||
sizeType: ['compressed'],
|
sizeType: ['compressed'],
|
||||||
success: res => {
|
success: res => {
|
||||||
this.$loading()
|
res.tempFiles.forEach(v => {
|
||||||
|
this.upload(v)
|
||||||
|
})
|
||||||
|
}
|
||||||
|
})
|
||||||
|
},
|
||||||
|
|
||||||
|
upload (img) {
|
||||||
let formData = new FormData()
|
let formData = new FormData()
|
||||||
formData.append('file', res.tempFiles[0])
|
formData.append('file', img)
|
||||||
|
|
||||||
|
this.$loading()
|
||||||
this.$http.post('/admin/file/add2?type=image', formData).then(res => {
|
this.$http.post('/admin/file/add2?type=image', formData).then(res => {
|
||||||
if (res.code === 0) {
|
if (res.code === 0) {
|
||||||
this.richList.push({
|
this.richList.push({
|
||||||
@@ -157,8 +166,6 @@
|
|||||||
this.$u.toast(res.msg)
|
this.$u.toast(res.msg)
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
}
|
|
||||||
})
|
|
||||||
},
|
},
|
||||||
|
|
||||||
confirm () {
|
confirm () {
|
||||||
|
|||||||
@@ -150,12 +150,21 @@
|
|||||||
|
|
||||||
addPhoto () {
|
addPhoto () {
|
||||||
uni.chooseImage({
|
uni.chooseImage({
|
||||||
count: 1,
|
count: 9,
|
||||||
sizeType: ['compressed'],
|
sizeType: ['compressed'],
|
||||||
success: res => {
|
success: res => {
|
||||||
this.$loading()
|
res.tempFiles.forEach(v => {
|
||||||
|
this.upload(v)
|
||||||
|
})
|
||||||
|
}
|
||||||
|
})
|
||||||
|
},
|
||||||
|
|
||||||
|
upload (img) {
|
||||||
let formData = new FormData()
|
let formData = new FormData()
|
||||||
formData.append('file', res.tempFiles[0])
|
formData.append('file', img)
|
||||||
|
|
||||||
|
this.$loading()
|
||||||
this.$http.post('/admin/file/add2?type=image', formData).then(res => {
|
this.$http.post('/admin/file/add2?type=image', formData).then(res => {
|
||||||
if (res.code === 0) {
|
if (res.code === 0) {
|
||||||
this.richList.push({
|
this.richList.push({
|
||||||
@@ -166,8 +175,6 @@
|
|||||||
this.$u.toast(res.msg)
|
this.$u.toast(res.msg)
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
}
|
|
||||||
})
|
|
||||||
},
|
},
|
||||||
|
|
||||||
confirm () {
|
confirm () {
|
||||||
|
|||||||
@@ -171,12 +171,21 @@
|
|||||||
|
|
||||||
addPhoto () {
|
addPhoto () {
|
||||||
uni.chooseImage({
|
uni.chooseImage({
|
||||||
count: 1,
|
count: 9,
|
||||||
sizeType: ['compressed'],
|
sizeType: ['compressed'],
|
||||||
success: res => {
|
success: res => {
|
||||||
this.$loading()
|
res.tempFiles.forEach(v => {
|
||||||
|
this.upload(v)
|
||||||
|
})
|
||||||
|
}
|
||||||
|
})
|
||||||
|
},
|
||||||
|
|
||||||
|
upload (img) {
|
||||||
let formData = new FormData()
|
let formData = new FormData()
|
||||||
formData.append('file', res.tempFiles[0])
|
formData.append('file', img)
|
||||||
|
|
||||||
|
this.$loading()
|
||||||
this.$http.post('/admin/file/add2?type=image', formData).then(res => {
|
this.$http.post('/admin/file/add2?type=image', formData).then(res => {
|
||||||
if (res.code === 0) {
|
if (res.code === 0) {
|
||||||
this.richList.push({
|
this.richList.push({
|
||||||
@@ -187,8 +196,6 @@
|
|||||||
this.$u.toast(res.msg)
|
this.$u.toast(res.msg)
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
}
|
|
||||||
})
|
|
||||||
},
|
},
|
||||||
|
|
||||||
confirm () {
|
confirm () {
|
||||||
|
|||||||
@@ -141,14 +141,22 @@
|
|||||||
|
|
||||||
addPhoto () {
|
addPhoto () {
|
||||||
uni.chooseImage({
|
uni.chooseImage({
|
||||||
count: 1,
|
count: 9,
|
||||||
sizeType: ['compressed'],
|
sizeType: ['compressed'],
|
||||||
success: res => {
|
success: res => {
|
||||||
this.$loading()
|
res.tempFiles.forEach(v => {
|
||||||
|
this.upload(v)
|
||||||
|
})
|
||||||
|
}
|
||||||
|
})
|
||||||
|
},
|
||||||
|
|
||||||
|
upload (img) {
|
||||||
let formData = new FormData()
|
let formData = new FormData()
|
||||||
formData.append('file', res.tempFiles[0])
|
formData.append('file', img)
|
||||||
|
|
||||||
|
this.$loading()
|
||||||
this.$http.post('/admin/file/add2?type=image', formData).then(res => {
|
this.$http.post('/admin/file/add2?type=image', formData).then(res => {
|
||||||
console.log(res)
|
|
||||||
if (res.code === 0) {
|
if (res.code === 0) {
|
||||||
this.richList.push({
|
this.richList.push({
|
||||||
type: 'img',
|
type: 'img',
|
||||||
@@ -158,8 +166,6 @@
|
|||||||
this.$u.toast(res.msg)
|
this.$u.toast(res.msg)
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
}
|
|
||||||
})
|
|
||||||
},
|
},
|
||||||
|
|
||||||
confirm () {
|
confirm () {
|
||||||
|
|||||||
Reference in New Issue
Block a user