This commit is contained in:
lik
2026-06-04 09:14:50 +08:00
parent c121ebdb94
commit 535827b17b
19 changed files with 1648 additions and 251 deletions

View File

@@ -0,0 +1,319 @@
<view class="container">
<!-- 状态头部 -->
<view class="status-header" style="background: {{record.statusGradient}};">
<view class="status-main">
<text class="status-text">{{record.statusText}}</text>
<text class="status-desc">{{record.statusDesc}}</text>
</view>
<view class="status-icon-wrap">
<t-icon name="{{record.statusIcon}}" size="80rpx" color="rgba(255,255,255,0.6)" />
</view>
</view>
<!-- 就诊人信息 -->
<view class="detail-card">
<view class="card-title">
<t-icon name="user" class="card-icon" size="36rpx" />
<text>就诊人信息</text>
<view class="card-edit-btn" bindtap="onEditPatientInfo" wx:if="{{!editingPatient}}">
<t-icon name="edit" size="28rpx" color="#D4A853" />
<text class="edit-text">修改</text>
</view>
</view>
<view wx:if="{{!editingPatient}}">
<view class="info-row">
<text class="info-label">姓名</text>
<text class="info-value">{{record.patientName || '--'}}</text>
</view>
<view class="info-row">
<text class="info-label">性别</text>
<text class="info-value">{{record.patientSexText || '--'}}</text>
</view>
<view class="info-row">
<text class="info-label">年龄</text>
<text class="info-value">{{record.patientAge ? record.patientAge + '岁' : '--'}}</text>
</view>
<view class="info-row">
<text class="info-label">体重</text>
<text class="info-value">{{record.patientWeight ? record.patientWeight + 'kg' : '--'}}</text>
</view>
<view class="info-row">
<text class="info-label">身高</text>
<text class="info-value">{{record.patientHeight ? record.patientHeight + 'cm' : '--'}}</text>
</view>
<view class="info-row">
<text class="info-label">联系电话</text>
<text class="info-value phone" bindtap="onCallPatient">{{record.patientMobile || '--'}}</text>
</view>
<view class="info-row" wx:if="{{record.patientIdnumber}}">
<text class="info-label">身份证号</text>
<text class="info-value">{{record.patientIdnumber}}</text>
</view>
</view>
<view wx:if="{{editingPatient}}">
<view class="edit-row">
<text class="edit-label">姓名</text>
<input class="edit-input" value="{{editPatient.name}}" placeholder="请输入姓名" data-field="name" bindinput="onPatientInfoInput" />
</view>
<view class="edit-row">
<text class="edit-label">性别</text>
<view class="edit-radio-group">
<view class="edit-radio {{editPatient.sex === 'male' ? 'active' : ''}}" data-field="sex" data-value="male" bindtap="onPatientSexChange">男</view>
<view class="edit-radio {{editPatient.sex === 'female' ? 'active' : ''}}" data-field="sex" data-value="female" bindtap="onPatientSexChange">女</view>
</view>
</view>
<view class="edit-row">
<text class="edit-label">年龄</text>
<input class="edit-input" type="number" value="{{editPatient.age}}" placeholder="请输入年龄" data-field="age" bindinput="onPatientInfoInput" />
</view>
<view class="edit-row">
<text class="edit-label">体重(kg)</text>
<input class="edit-input" type="digit" value="{{editPatient.weight}}" placeholder="请输入体重" data-field="weight" bindinput="onPatientInfoInput" />
</view>
<view class="edit-row">
<text class="edit-label">身高(cm)</text>
<input class="edit-input" type="digit" value="{{editPatient.height}}" placeholder="请输入身高" data-field="height" bindinput="onPatientInfoInput" />
</view>
<view class="edit-row">
<text class="edit-label">联系电话</text>
<input class="edit-input" type="number" value="{{editPatient.mobile}}" placeholder="请输入联系电话" data-field="mobile" bindinput="onPatientInfoInput" />
</view>
<view class="edit-row">
<text class="edit-label">身份证号</text>
<input class="edit-input" value="{{editPatient.idnumber}}" placeholder="请输入身份证号" data-field="idnumber" bindinput="onPatientInfoInput" />
</view>
<view class="edit-actions">
<button class="edit-btn cancel" bindtap="onCancelEditPatientInfo">取消</button>
<button class="edit-btn confirm" bindtap="onSavePatientInfo">保存</button>
</view>
</view>
</view>
<!-- 医院预约信息 -->
<view class="detail-card">
<view class="card-title">
<t-icon name="hospital" class="card-icon" size="36rpx" />
<text>医院预约信息</text>
</view>
<view class="info-row">
<text class="info-label">就诊省份</text>
<text class="info-value">{{record.hospitalProvince || '--'}}</text>
</view>
<view class="info-row">
<text class="info-label">就诊医院</text>
<text class="info-value">{{record.hospitalName || '--'}}</text>
</view>
<view class="info-row" wx:if="{{record.hospitalAddress}}">
<text class="info-label">医院地址</text>
<text class="info-value">{{record.hospitalAddress}}</text>
</view>
<view class="info-row">
<text class="info-label">就诊科室</text>
<text class="info-value">{{record.hospitalDepartment || '--'}}</text>
</view>
<view class="info-row" wx:if="{{record.hospitalDoctor}}">
<text class="info-label">就诊医生</text>
<text class="info-value">{{record.hospitalDoctor}}</text>
</view>
<view class="info-row" wx:if="{{record.medicalRecordNo}}">
<text class="info-label">病历号</text>
<text class="info-value">{{record.medicalRecordNo}}</text>
</view>
<view class="info-row">
<text class="info-label">预约日期</text>
<text class="info-value">{{record.scheduleDate || '--'}}</text>
</view>
<view class="info-row">
<text class="info-label">预约时间</text>
<text class="info-value">{{record.scheduleStartTime || '--'}}</text>
</view>
<view class="info-row" wx:if="{{record.scheduleEndTime}}">
<text class="info-label">结束时间</text>
<text class="info-value">{{record.scheduleEndTime}}</text>
</view>
<view class="info-row" wx:if="{{record.scheduleDuration}}">
<text class="info-label">陪诊时长</text>
<text class="info-value">{{record.scheduleDuration}}分钟</text>
</view>
</view>
<!-- 陪诊服务信息 -->
<view class="detail-card">
<view class="card-title">
<t-icon name="service" class="card-icon" size="36rpx" />
<text>陪诊服务</text>
</view>
<view class="info-row">
<text class="info-label">服务类型</text>
<text class="info-value">{{record.escortServiceName || '陪诊服务'}}</text>
</view>
<view class="info-row">
<text class="info-label">性别要求</text>
<text class="info-value">{{record.escortSexRequirementText}}</text>
</view>
<view class="info-row">
<text class="info-label">陪诊员</text>
<text class="info-value">{{record.attendantName}}</text>
</view>
<view class="info-row">
<text class="info-label">陪诊员性别</text>
<text class="info-value">{{record.attendantSexText}}</text>
</view>
<view class="info-row">
<text class="info-label">陪诊员电话</text>
<text class="info-value phone" bindtap="onCallAttendant">{{record.attendantMobile}}</text>
</view>
</view>
<!-- 陪诊需求 / 症状描述 -->
<view class="detail-card">
<view class="card-title">
<t-icon name="edit-1" class="card-icon" size="36rpx" />
<text>陪诊需求与症状</text>
<view class="card-edit-btn" bindtap="onEditPatientNote" wx:if="{{!editing}}">
<t-icon name="edit" size="28rpx" color="#D4A853" />
<text class="edit-text">修改</text>
</view>
</view>
<view class="note-section" wx:if="{{record.patientNote || editing}}">
<textarea
wx:if="{{editing}}"
class="note-textarea"
value="{{editPatientNote}}"
placeholder="请输入陪诊需求或症状描述"
maxlength="500"
placeholder-class="input-placeholder"
bindinput="onPatientNoteInput"
focus="{{editing}}"
/>
<text wx:else class="note-content">{{record.patientNote || '暂无备注'}}</text>
<view class="note-actions" wx:if="{{editing}}">
<button class="note-btn cancel" bindtap="onCancelEdit">取消</button>
<button class="note-btn confirm" bindtap="onSavePatientNote">保存</button>
</view>
</view>
<view class="note-section" wx:if="{{record.escortNote}}">
<text class="note-label">陪诊记录</text>
<text class="note-content">{{record.escortNote}}</text>
</view>
<view class="note-section" wx:if="{{record.medicalSummary}}">
<text class="note-label">就诊摘要</text>
<text class="note-content">{{record.medicalSummary}}</text>
</view>
<view class="empty-note" wx:if="{{!record.patientNote && !record.escortNote && !record.medicalSummary && !editing}}">
<text class="empty-note-text">暂无备注信息,点击添加</text>
<view class="add-note-btn" bindtap="onEditPatientNote">
<t-icon name="add" size="28rpx" color="#D4A853" />
</view>
</view>
</view>
<!-- 费用信息 -->
<view class="detail-card">
<view class="card-title">
<t-icon name="wallet" class="card-icon" size="36rpx" />
<text>费用信息</text>
</view>
<view class="info-row">
<text class="info-label">服务费用</text>
<text class="info-value fee">¥{{record.totalFee}}</text>
</view>
<view class="info-row">
<text class="info-label">已支付</text>
<text class="info-value">¥{{record.paidFee}}</text>
</view>
<view class="info-row">
<text class="info-label">支付状态</text>
<view class="payment-badge" style="color: {{record.paymentStatusColor}}; background: {{record.paymentStatusBg}};">
{{record.paymentStatusText}}
</view>
</view>
</view>
<!-- 订单信息 -->
<view class="detail-card">
<view class="card-title">
<t-icon name="order" class="card-icon" size="36rpx" />
<text>订单信息</text>
</view>
<view class="info-row">
<text class="info-label">订单编号</text>
<text class="info-value order-id">{{record._id || '--'}}</text>
</view>
<view class="info-row">
<text class="info-label">订单状态</text>
<view class="status-badge-small" style="color: {{record.statusColor}}; background: {{record.statusBg}};">
{{record.statusText}}
</view>
</view>
<view class="info-row">
<text class="info-label">创建时间</text>
<text class="info-value">{{record.createTime || '--'}}</text>
</view>
<view class="info-row">
<text class="info-label">更新时间</text>
<text class="info-value">{{record.updateTime || '--'}}</text>
</view>
</view>
<!-- 底部占位 -->
<view class="bottom-placeholder"></view>
<!-- 底部操作栏 -->
<view class="bottom-bar">
<view class="bottom-right">
<view
class="action-btn cancel-btn"
wx:if="{{record.status === 'pending' || record.status === 'confirmed'}}"
bindtap="onCancelOrder"
>取消订单</view>
<view
class="action-btn cancel-btn"
wx:if="{{record.paymentStatus === 'unpaid' && record.status !== 'completed'}}"
bindtap="onDeleteOrder"
>删除订单</view>
<view
class="action-btn confirm-btn"
wx:if="{{record.status === 'completed'}}"
bindtap="onConfirmComplete"
>确认完成</view>
<view
class="action-btn rebook-btn"
wx:if="{{record.status === 'completed' || record.status === 'cancelled'}}"
bindtap="onRebook"
>再次预约</view>
</view>
</view>
<!-- 取消订单弹窗 -->
<view class="popup-mask {{showCancelPopup ? 'show' : ''}}" bindtap="onCloseCancelPopup"></view>
<view class="popup-content {{showCancelPopup ? 'show' : ''}}">
<view class="popup-header">
<text class="popup-title">取消订单</text>
<view class="popup-close" bindtap="onCloseCancelPopup">
<t-icon name="close" size="40rpx" />
</view>
</view>
<view class="popup-body">
<text class="cancel-tip">确定要取消该陪诊订单吗?取消后陪诊员将收到通知。</text>
<view class="cancel-reason-list">
<view
class="cancel-reason-item {{cancelReason === item ? 'active' : ''}}"
wx:for="{{cancelReasons}}"
wx:key="*this"
data-reason="{{item}}"
bindtap="onSelectCancelReason"
>
<view class="reason-radio">
<view class="reason-radio-inner" wx:if="{{cancelReason === item}}"></view>
</view>
<text class="reason-text">{{item}}</text>
</view>
</view>
</view>
<view class="popup-footer">
<button class="popup-cancel-btn" bindtap="onCloseCancelPopup">再想想</button>
<button class="popup-confirm-btn" bindtap="onConfirmCancel">确认取消</button>
</view>
</view>
</view>