step3.wxml
1.76 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
<!--packageUsedCar/pages/deliveryNote/components/step3/step3.wxml-->
<wxs module="utils">
// 图片展示/回显时拼接 OSS 处理参数
var getImageDisplayUrl = function(url) {
if (!url || url === '-' || url === 'null' || url === 'undefined') return url;
if (typeof url !== 'string') return url;
if (url.indexOf('x-oss-process=') !== -1) return url;
var sep = url.indexOf('?') >= 0 ? '&' : '?';
return url + sep + 'x-oss-process=image/format,jpg/quality,q_100';
};
module.exports = { getImageDisplayUrl: getImageDisplayUrl };
</wxs>
<view class="step-3">
<!-- 图片展示区域 -->
<view class="upload-box box">
<view class="title">交付照片</view>
<view class="img-list flex">
<block wx:for="{{detail.imgList}}" wx:key="index">
<view class="img-item">
<image
src="{{utils.getImageDisplayUrl(item)}}"
class="img"
mode="aspectFill"
bind:tap="previewMedia"
data-url="{{item}}"
data-type="1"
></image>
</view>
</block>
</view>
</view>
<!-- 备注区域 -->
<view class="remark-box box">
<view class="title">交付备注</view>
<view class="remark">
<rich-text nodes="{{detail.remark || '-'}}"></rich-text>
</view>
</view>
<!-- 按钮区域 -->
<view class="btn-box box flex">
<!-- 图标 -->
<view class="icon-delivery-step-2">
<image
src="{{IMG_URL}}usedCar/delivery-step-2.png"
class="step-icon"
mode="widthFix"
></image>
</view>
<view class="info">
客户提车确认
<view class="des">提车时间:{{detail.pickUpTime || '--'}}</view>
</view>
<view class="btn flex">已提车</view>
</view>
</view>