Files
wxapp_escort/pages/health/profilelist.wxml
T
2026-10-06 21:19:20 +08:00

70 lines
2.9 KiB
Plaintext

<view class="container">
<!-- 说明砖:浅橙底 + 2rpx --brand-line 描边托形(不加阴影),走全站「说明砖」档;
文案说明就诊人的用途 -->
<view class="tip-card" wx:if="{{profiles.length > 0}}">
<t-icon name="info-circle" class="tip-icon" size="28rpx" />
<text class="tip-text">下单时可直接选择已保存的就诊人,无需重复填写</text>
</view>
<!-- 就诊人列表:通栏白块(白面 + 上下 2rpx 发丝线 + 中性阴影,圆角 0),
与「邮寄地址」列表同源。每条主体可点进编辑(右侧 chevron 是点击暗示),
不做无暗示的整卡可点;删除动作单独一行、走 --muted -->
<view class="profile-list" wx:if="{{profiles.length > 0}}">
<view
class="profile-card {{index === profiles.length - 1 ? 'profile-card-last' : ''}}"
wx:for="{{profiles}}"
wx:key="_id"
>
<view class="profile-main" data-id="{{item._id}}" bindtap="onEdit" hover-class="profile-main-hover">
<view class="profile-info">
<view class="profile-top">
<text class="profile-name">{{item.name}}</text>
<text class="sex-tag" wx:if="{{item.sexText}}">{{item.sexText}}</text>
</view>
<view class="info-row">
<text class="info-label">出生年月</text>
<text class="info-value">{{item.birth || '未填写'}}</text>
</view>
<view class="info-row">
<text class="info-label">联系电话</text>
<text class="info-value">{{item.mobile || '未填写'}}</text>
</view>
<view class="info-row">
<text class="info-label">证件号</text>
<text class="info-value">{{item.idnumberText}}</text>
</view>
<view class="info-row" wx:if="{{item.remark}}">
<text class="info-label">健康备注</text>
<text class="info-value">{{item.remark}}</text>
</view>
</view>
<t-icon name="chevron-right" class="profile-arrow" size="32rpx" />
</view>
<view class="profile-actions">
<view class="profile-action" data-id="{{item._id}}" bindtap="onDelete">
<t-icon name="delete" class="profile-action-icon" size="32rpx" />
<text class="profile-action-text">删除</text>
</view>
</view>
</view>
</view>
<!-- 空状态 -->
<view class="profile-empty" wx:if="{{!loading && profiles.length === 0}}">
<t-icon name="user-checked" class="profile-empty-icon" size="80rpx" />
<text class="profile-empty-text">还没有就诊人,添加后下单即可一键带入</text>
</view>
<!-- 加载中 -->
<view class="loading-wrap" wx:if="{{loading}}">
<t-loading theme="circular" size="40rpx" text="加载中..." />
</view>
<!-- 底部固定操作栏 -->
<view class="footer-bar">
<button class="primary-btn" bindtap="onAdd">新增就诊人</button>
</view>
</view>