| 123456789101112131415161718192021222324252627 |
- <wxs module="_">
- module.exports.getClassName = function (value, prev, key) {
- // return key !== 'reportTime' && prev && value[key] !== prev[key] ? 'highlight' : ''
- return '';
- }
- </wxs>
- <!--module/health/pages/status-record/status-record.wxml-->
- <t-navbar title="健康状况更新记录" left-arrow />
- <view class="wrapper {{orientation}}" style="{{containerStyle}}">
- <view class="header">
- <block wx:for="{{columns}}" wx:key="value" wx:for-index="i" wx:for-item="r">
- <view class="row {{i === 0 ? 'title' : i % 2 ? 'odd' : 'even'}}" style="height: {{r.height}}px;">{{r.label}}</view>
- </block>
- </view>
- <scroll-view class="scrollable" type="list" scroll-x enable-flex style="flex-direction: row;" bind:scrolltolower="loadMore">
- <view class="col" wx:for="{{dataset}}" wx:key="index">
- <block wx:for="{{columns}}" wx:key="value" wx:for-index="i" wx:for-item="r">
- <image wx:if="{{r.type==='picture'}}" style="height: {{r.height}}px;width: {{r.width}}px;" src="{{item[r.value]}}" mode="aspectFit" data-url="{{item[r.value]}}" data-item="{{item}}" catch:tap="preview"></image>
- <view wx:else class="row {{i === 0 ? 'title' : i % 2 ? 'odd' : 'even'}} {{_.getClassName(item, dataset[index+1], r.value)}}" style="height: {{r.height}}px;">
- <text max-lines="{{maxLines}}" overflow="ellipsis">{{item[r.value]}}</text>
- </view>
- </block>
- </view>
- </scroll-view>
- </view>
- <t-message id="{{$messageId}}" />
|