Merge commit '9dd9f3e7b11a1295ce8dc6d67cdcdc1a877f6815'

* commit '9dd9f3e7b11a1295ce8dc6d67cdcdc1a877f6815':
  添加模拟上传
  添加上传按钮
  反馈页:添加类型tab
master
zsk 2 years ago
commit 35a0e950e0

@ -9,6 +9,10 @@ Page({
loading: false,
subLoad: false,
success: false,
troubleList:[
"投诉", "建议", "故障", "其他"
],
actived:0
},
/**
@ -25,6 +29,30 @@ Page({
* 生命周期函数--监听页面显示
*/
onShow () { },
handleUpdatType(e){
console.log(e)
this.setData({
actived:e.target.dataset.index
})
},
handleUpdateImage(){
wx.chooseMedia({
count: 1,
mediaType: ['image'],
sourceType: ['album', 'camera'],
maxDuration: 30,
camera: 'back',
success(res) {
console.log('获取上传数据:',res)
// 调用上传接口
}
})
},
/**
* 意见提交事件
*

@ -1,8 +1,23 @@
<view class="container">
<view class='type-box display-flex'>
<view wx:for="{{troubleList}}"
class="type-item {{actived == index ? 'type-active' : ''}}" data-item="{{item}}" data-index="{{index}}"
bind:tap="handleUpdatType"
>{{item}}</view>
</view>
<view class="submit" wx:if="{{!success}}" hover-class="none" hover-stop-propagation="false">
<textarea class="bgf textarea br8 f14" value="{{textVal}}" bindinput="getVal" maxlength="140" placeholder="我们想听到您的心声..." placeholder-class="f14 cccc" bindfocus bindconfirm></textarea>
<textarea class="bgf textarea br8 f14" value="{{textVal}}" bindinput="getVal" maxlength="150" placeholder="我们想听到您的心声..." placeholder-class="f14 cccc" bindfocus bindconfirm></textarea>
<view class="" style="margin-top: 16px;">
<image src="https://matripe-cms.oss-cn-beijing.aliyuncs.com/dailibaoming/my_uploadphotos.svg"
mode="widthFix"
style="width: 72px;height: 72px;"
bind:tap="handleUpdateImage"
/>
</view>
<view style="margin-top: 8px;font-size: 12px;color: #999999;">
上传照片截图最多传4张选填
</view>
<button class="normalBtn loginOut f16" hover-class="thover" bindtap="submit" style="margin-top:90px" loading="{{loading}}">提交</button>
<!-- <view class="tac mt16 f14" style="color:#576B95" bindtap="goList" hover-class="thover" hover-stop-propagation="false">查看记录</view> -->
</view>
<view class="success" wx:else hover-class="none" hover-stop-propagation="false">
<view class="tc" style="padding-top: 100px;">

@ -13,3 +13,21 @@
.lh20{
line-height: 20px;
}
.type-box{
margin-bottom: 12px;
}
.type-item{
width: 60px;
height: 30px;
text-align: center;
line-height: 30px;
border-radius: 15px;
margin-right: 8px;
background-color: #fff;
font-size: 16px;
}
.type-active{
background-color: var(--color-ysd);
color:#fff;
}

@ -8,6 +8,13 @@
"condition": {
"miniprogram": {
"list": [
{
"name": "反馈与建议",
"pathName": "pages/mine/opinion/index",
"query": "",
"launchMode": "default",
"scene": null
},
{
"name": "pages/index/index",
"pathName": "pages/index/index",

Loading…
Cancel
Save