diff --git a/pages/news1/feedback.vue b/pages/news1/feedback.vue index 63ca490..672b864 100644 --- a/pages/news1/feedback.vue +++ b/pages/news1/feedback.vue @@ -17,7 +17,7 @@ - + @@ -39,15 +39,24 @@ - + + - + - + + + @@ -212,8 +221,8 @@ export default { onLoad(params) { }, - onReachBottom() { - if (this.feedBackList.length < this.total && this.OrderType!=0) { + onReachBottom() { + if (this.feedBackList.length < this.total && this.OrderType != 0) { this.pageNum++; this.getFeedBack(this.OrderType) } @@ -238,6 +247,35 @@ export default { .catch(reject) }) }, + //接受上传返回的数据 + transferSuccess(list) { + if (list.length > 0) { + const { + response + } = list[0]; + if (response.status == 200) { + uni.showToast({ + title: "上传成功" + }) + let idList = [] + list.forEach(item => { + idList.push(item.response.data.fileInfo.file_id) + }); + this.image_id = idList.join(','); + } + } + }, + transferRemove(file, fileList) { + this.image_id = this.handleRemove(file, fileList); + }, + handleRemove: function (file, fileList) { + let idList = [] + fileList.forEach(item => { + idList.push(item.response.data.fileInfo.file_id) + }); + return idList.join(',') + + }, submit() { const that = this if (that.form.comment == '') { @@ -312,70 +350,7 @@ export default { this.form.shopText = this.shopList[index].text; this.shop_id = this.shopList[index].id }, - // 新增图片 - async afterRead(event) { - - let lists = [].concat(event.file) - let fileListLen = this[`fileList${event.name}`].length - lists.map((item) => { - this[`fileList${event.name}`].push({ - ...item, - status: 'uploading', - message: '上传中' - }) - }) - for (let i = 0; i < lists.length; i++) { - const result = await this.uploadFilePromise(lists[i].url) - - if (JSON.parse(result).code == 1) { - let item = this[`fileList${event.name}`][fileListLen] - this[`fileList${event.name}`].splice(fileListLen, 1, Object.assign(item, { - status: 'success', - message: '', - url: result - })) - fileListLen++ - } else { - this[`fileList${event.name}`].splice(fileListLen, 1) - } - - } - - }, - //上传照片 - uploadFilePromise(url) { - return new Promise((resolve, reject) => { - let a = uni.uploadFile({ - url: this.baseUrl + '/api/common/upload', // 仅为示例,非真实的接口地址 - filePath: url, - name: 'file', - formData: { - user: 'test', - token: getToken() - }, - success: (res) => { - if (JSON.parse(res.data).code == 1) { - setTimeout(() => { - this.finishImageList.push({ url: JSON.parse(res.data).data.fullurl, path: JSON.parse(res.data).data.url }) - resolve(res.data) - }, 1000) - } else { - uni.$u.toast(JSON.parse(res.data).msg) - - resolve(res.data) - } - }, - fail: (res) => { - console.log(res, "rrr") - } - }); - }) - }, - //删除图片 - deletePic(event) { - this.finishImageList.splice(event.index, 1) - }, } } @@ -388,6 +363,45 @@ page { } +.c { + padding-top: 20rpx; + overflow: hidden; + + .slot-btn { + width: 180rpx; + height: 180rpx; + background: #F6F6F6; + border-radius: 10rpx; + border: 1px solid #C0C0C0; + text-align: center; + font-size: 28rpx; + font-weight: 500; + color: #6D6D6D; + + .l { + line-height: 30rpx; + margin-top: 10rpx; + } + + image { + width: 50rpx; + height: 50rpx; + display: block; + margin: 0 auto; + margin-top: 30rpx; + } + } +} + +.realAddr { + ::v-deep .u-input { + padding: 10rpx 22upx !important; + background: #F7F8FA; + border-radius: 6rpx !important; + } + +} + /* 订单tab */ .order-tab { @@ -464,13 +478,6 @@ page { border: none; } - // .textarea { - // height: 258rpx; - // border-radius: 3px; - // border: solid 1upx #F7F8FA; - - // } - ::v-deep .u-input__textarea { padding: 26rpx; } @@ -566,14 +573,17 @@ page { color: #FF4D4D; flex-shrink: 1; } - .fbFlag2{ + + .fbFlag2 { border: 1px solid #41B4EC; color: #41B4EC; } - .fbFlag3{ + + .fbFlag3 { border: 1px solid #2DC37F; color: #2DC37F } + .fbTitleText { flex: 1; font-size: 28rpx; @@ -629,4 +639,5 @@ page { justify-content: center; flex-direction: column; height: calc(100vh - 102rpx); -} +} + diff --git a/pages/news1/huoyuan.vue b/pages/news1/huoyuan.vue index c000fbe..b784225 100644 --- a/pages/news1/huoyuan.vue +++ b/pages/news1/huoyuan.vue @@ -6,32 +6,32 @@ - + - + - {{item.title}} - {{item.subTitle}} + {{ item.title }} + {{ item.subTitle }} - + - + - - + + - + @@ -40,9 +40,9 @@ - + - - + @@ -54,397 +54,424 @@ - - - - - - - - - - 上传图片 - {{imageList.length>0?imageList.length:0}}/{{maxImageLength}} - - + + + + - - + - - + + + + - + + +