You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

156 lines
5.8 KiB

<view class="page" bind:tap="handleHideKeyboard">
<view class="page-header">
<view class="user">
<image class="avatar" src="{{patientDetail.userAvatar}}"></image>
<view class="wrap">
<view class="name">
<view class="left">{{patientDetail.patientName}}</view>
</view>
<view class="date">注册时间:{{patientDetail.BecomePatientTime}}</view>
</view>
<view class="detail" bind:tap="handlePatientDetail">查看档案</view>
</view>
</view>
<view class="page-container" id="page-container">
<scroll-view
class="scroll-view"
scroll-y="{{true}}"
scroll-top="{{scrollTop}}"
scroll-into-view="{{scrollIntoView}}"
scroll-with-animation
bindscrolltoupper="scrolltoupper"
>
<van-loading wx:if="{{isLoad && !isFinish}}" />
<view
class="view-wrap"
wx:for="{{messageList}}"
wx:key="msgId"
wx:for-item="message"
wx:for-index="mIndex"
id="view{{mIndex}}"
>
<view class="date" wx:if="{{message.showTime}}">{{message.msgCreateTimeName}}</view>
<view class="patient" wx:if="{{message.msgFromType==='1'}}">
<view class="avatar">
<image class="a-img" src="{{patientDetail.userAvatar}}"></image>
</view>
<view class="p-container">
<view class="message">{{message.msgContent}}</view>
</view>
</view>
<view class="doctor" wx:if="{{message.msgFromType==='2'}}">
<view class="d-container">
<view class="guide" wx:if="{{message.msgContentType==='5'}}">
<view class="title">以下是门诊常见提问,您也可以在对话框下方的"快速提问"里查询更多:</view>
<view class="list">
<view class="l-item" wx:for="{{message.welcomeMsg.hotQuestion}}" wx:key="questionId">
<view class="order">{{index+1}}</view>
<view class="content">{{item.question}}</view>
</view>
</view>
</view>
<block wx:elif="{{message.msgContentType==='1'|| message.msgContentType==='11' || message.msgContentType==='12'}}">
<view class="message">{{message.msgContent}}</view>
</block>
<view class="week" wx:elif="{{message.msgContentType==='2'}}">
<view class="w-title">以下是我的出诊时间</view>
<view class="w-container">
<view wx:if="{{message.msgVisitTimeType==2}}" class="w-content pre-line">{{message.msgVisitTime}}</view>
<block wx:else>
<view class="row" wx:for="{{message.msgVisitTime}}" wx:key="index">
<view class="label">{{week[item.weekday-1]}}</view>
<view class="content">{{timeDay[item.timeType]}}</view>
</view>
</block>
</view>
</view>
<view class="adl" wx:elif="{{message.msgContentType==='10'}}">
<image class="adl-img" src="{{imageUrl}}bg20.png?t={{Timestamp}}"></image>
</view>
</view>
<view class="avatar">
<image class="a-img" mode="aspectFill" src="{{doctor.Img}}"></image>
</view>
</view>
</view>
<view id="place" class="place"></view>
</scroll-view>
</view>
<view class="page-footer">
<view class="send" wx:if="{{doctor.IsOpenOneToOne!=1 || true}}">
<view class="content" catch:tap="handleInputShow">{{customMessage || '输入文字'}}</view>
<view class="btn" catch:tap="handleSendShow">快捷回复</view>
</view>
<view wx:else class="short-send" bind:tap="handleSendShow">发送消息</view>
<view class="send-date" bind:tap="handleSendDate">
<image class="icon" src="{{imageUrl}}icon56.png?t={{Timestamp}}"></image>
<view>出诊时间</view>
</view>
</view>
</view>
<view wx:if="{{inputShow}}" class="custom-input {{maxTextArea && 'custom-input-max'}}">
<image
wx:if="{{maxTextArea}}"
class="icon"
src="{{imageUrl}}icon98.png?t={{Timestamp}}"
catch:tap="toggleMaxTextarea"
></image>
<image wx:else class="icon" src="{{imageUrl}}icon97.png?t={{Timestamp}}" catch:tap="toggleMaxTextarea"></image>
<view class="wrap" catch:tap="catchFooterInput">
<textarea
class="textarea"
model:value="{{customMessage}}"
focus="{{focus}}"
hold-keyboard
disable-default-padding
confirm-type="send"
adjust-keyboard-to="bottom"
maxlength="{{500}}"
placeholder="输入文字"
bind:blur="bindblur"
bindconfirm="handleConfirm"
>
<keyboard-accessory class="ka" hold-keyboard="{{true}}" style="background-color: #fff;">
<cover-view class="ka-container">
<cover-view class="stat {{customMessage.length==500 && 'red'}}">{{customMessage.length}}/500</cover-view>
<cover-view class="send-btn" bind:tap="handleConfirm">发送</cover-view>
</cover-view>
</keyboard-accessory>
</textarea>
<view class="w-footer"></view>
</view>
</view>
<van-popup
show="{{ messageListShow }}"
style="--popup-close-icon-color: #283031"
position="bottom"
round
bind:close="handlePopupMessageClose"
closeable
>
<view class="popup-message">
<view class="title">快捷回复</view>
<view class="list">
<view
class="l-item {{wordIndex===index && 'active'}}"
wx:for="{{wordList}}"
wx:key="wordId"
bind:tap="handleWord"
data-index="{{index}}"
>
{{item.word}}
</view>
</view>
<view class="submit" bind:tap="handleSendWord">发送</view>
</view>
</van-popup>
<toast
show="{{popupShow}}"
type="{{popupType}}"
params="{{popupParams}}"
bind:ok="handlePopupOk"
bind:cancel="handlePopupCancel"
></toast>