<!--pages/record/record.wxml-->

<view class="top-items">
  <image style='width: 40vw; height: 40vw; border-radius: 10rpx;' src='/assets/kehuishou.png' data-type="1" bindtap="showDetail"></image>
  <image style='width: 40vw; height: 40vw; border-radius: 10rpx;' src='/assets/chuyu.png' data-type="2" bindtap="showDetail"></image>
  <image style='width: 40vw; height: 40vw;border-radius: 10rpx;' src='/assets/youhai.png' data-type="3" bindtap="showDetail"></image>
  <image style='width: 40vw; height: 40vw; border-radius: 10rpx;' src='/assets/qita.png' data-type="4" bindtap="showDetail"></image> 
</view>
<!-- <view class="search-input">
  <button class="mini-btn" type="primary" size="mini" bindtap="addDetail">新增</button>
</view> -->
<t-pull-down-refresh value="{{enable}}" loadingProps="{{loadingProps}}" loadingTexts="{{['下拉刷新', '松手刷新', '正在刷新', '刷新完成']}}" bind:refresh="onRefresh">
  <view>
    <view wx:if="{{list.length> 0}}">
      <t-swipe-cell wx:for="{{ list }}" wx:key="index">
        <t-cell bordered="{{true}}" title="标题：{{ item.name}}" description="{{item.created_time}}" note=""
        bindtap="showDialog"  data-id="{{ item.id}}" data-type="{{item.type}}" data-name="{{item.name}}" data-content="{{item.content}}" >
        </t-cell>
      </t-swipe-cell>
    </view>
    <t-empty wx:else="{{list.length <= 0}}" t-class="empty-cls" t-class-image="t-empty__image" image="{{noDataImage}}" description="暂无数据" />
  </view>
</t-pull-down-refresh>
<t-dialog id="t-dialog" />
<t-toast id="t-toast" />