1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162 |
- <view class="main">
- <view class="content">
- <view class="content_item">
- <view wx:for="{{list}}" wx:key="index" class="border" wx:if="{{item.isShow===1}}">
- <view class="cu-form-group" wx:if="{{item.customType==='下拉选择'&&item.isShow===1}}">
- <view class="title"><text class="{{item.customNameVal?'text-green':'text-red'}}">*</text>
- <text>{{item.customName}}{{item.isEditable === 0?'(禁用)':''}}</text>
- </view>
- <picker disabled="{{item.isEditable === 0}}" data-index="{{index}}" bindchange="getSelect" value="{{item.customNameVal}}" range="{{item.configurationOption}}" range-key="{{'name'}}" data-index="{{index}}">
- <view class="picker" style="{{item.customNameVal?'color: #646566':'color: #C8C9CC'}}">
- {{item.customNameVal?item.customNameVal:item.prompt ||'请选择'}}
- <van-icon class="icon" name="arrow" />
- </view>
- </picker>
- </view>
- <view class="cu-form-group" wx:if="{{item.customType==='文本' &&item.isShow===1}}">
- <view class="title"><text class="{{item.customNameVal?'text-green':'text-red'}}">*</text><text>{{item.customName}}{{item.isEditable === 0?'(禁用)':''}}</text>
- </view>
- <input disabled="{{item.isEditable === 0}}" type="text" bindinput="getValue" value="{{item.customNameVal}}" placeholder="{{item.prompt || '请填写内容'}}" data-index="{{index}}" placeholder-style="color: #C8C9CC"></input>
- </view>
- <view class="cu-form-group" wx:if="{{item.customType==='日期'&&item.isShow===1}}">
- <view class="title"><text class="{{item.customNameVal ?'text-green':'text-red'}}">*</text><text>{{item.customName}}{{item.isEditable === 0?'(禁用)':''}}</text>
- </view>
- <picker disabled="{{item.isEditable === 0}}" data-index="{{index}}" class="picker" mode="date" value="{{item.customNameVal}}" start="2015-01-01" end="2100-01-01" bindchange="getValue">
- <view class="picker" style="{{item.customNameVal?'color: #646566':'color: #C8C9CC'}}">
- {{item.customNameVal?item.customNameVal:item.prompt ||'请选择日期'}}
- </view>
- </picker>
- </view>
- <view class="cu-form-group" wx:if="{{item.customType==='时间'&&item.isShow===1}}">
- <view class="title"><text class="{{item.customNameVal?'text-green':'text-red'}}">*</text><text>{{item.customName}}{{item.isEditable === 0?'(禁用)':''}}</text>
- </view>
- <picker disabled="{{item.isEditable === 0}}" data-index="{{index}}" class="picker" mode="time" value="{{item.customNameVal}}" start="00:00" end="23:59" bindchange="getValue">
- <view class="picker" style="{{item.customNameVal?'color: #646566':'color: #C8C9CC'}}">
- {{item.customNameVal?item.customNameVal:item.prompt ||'请选择时间'}}
- </view>
- </picker>
- </view>
- <!-- 图片 -->
- <view class="cu-form-group height" wx:if="{{item.customType==='图片'&&item.isShow===1}}">
- <view class="title"><text class="{{item.customNameVal?'text-green':'text-red'}}">*</text><text>{{item.customName}}{{item.isEditable === 0?'(禁用)':''}}</text>
- </view>
- <view wx:if="{{item.customNameVal}}" class="img_box">
- <image src="{{item.customNameVal}}" class="img" bindtap="previewImg" data-src="{{item.customNameVal}}"></image>
- <image src="../../static/images/delete_img.png" class="DelImg" data-index="{{index}}" catchtap="DelImg" data-type="vvv"></image>
- </view>
- <image bindtap="doUploadAvatar" class="upload" wx:else data-index="{{index}}" src="../../static/images/default_img.png"></image>
- </view>
- <!-- 省市区(街道) -->
- <view wx:if="{{(item.customType==='省市区'||item.customType==='省市区街道')&&item.isShow===1}}">
- <!-- 标题 -->
- <view class="cu-form-group">
- <view class="title">
- <text class="{{item.customNameVal?'text-green':'text-red'}}">*</text><text>{{item.customName}}{{item.isEditable === 0?'(禁用)':''}}</text>
- </view>
- <area-picker bind:value="getAddress" content="{{item.customNameVal}}" hasStreet="{{item.customType==='省市区街道'}}" data-index="{{index}}"></area-picker>
- </view>
- </view>
- </view>
- </view>
- </view>
- </view>
|