新增历史补单与服务中状态
This commit is contained in:
@@ -35,7 +35,7 @@ Page({
|
||||
appointment,
|
||||
isUnassigned: appointment.assignmentStatus === 'UNASSIGNED' || !appointment.artistId,
|
||||
avatarText: String(appointment.customerName || '客').slice(0, 1),
|
||||
timeText: `${(appointment.startTime || '').slice(0, 16)} - ${(appointment.endTime || '').slice(11, 16)}`,
|
||||
timeText: appointment.historicalBackfill && !appointment.startTime ? '时间未记录' : `${(appointment.startTime || '').slice(0, 16)} - ${(appointment.endTime || '').slice(11, 16)}`,
|
||||
loadError: ''
|
||||
})
|
||||
},
|
||||
@@ -56,6 +56,7 @@ Page({
|
||||
},
|
||||
|
||||
confirm() {
|
||||
if (this.data.appointment.historicalBackfill) return
|
||||
this.updateStatus(1)
|
||||
},
|
||||
|
||||
@@ -68,6 +69,7 @@ Page({
|
||||
},
|
||||
|
||||
goTransfer() {
|
||||
if (this.data.appointment.historicalBackfill) return
|
||||
wx.navigateTo({ url: `/pages/artist-transfer/index?id=${this.data.id}` })
|
||||
},
|
||||
|
||||
|
||||
@@ -14,8 +14,9 @@
|
||||
</view>
|
||||
</view>
|
||||
<view class="detail-actions">
|
||||
<text class="tag">{{appointment.statusText}}</text>
|
||||
<button class="small-action" bindtap="goTransfer">{{isUnassigned ? '分配员工' : '改派'}}</button>
|
||||
<text wx:if="{{appointment.historicalBackfill}}" class="tag">历史补单 · {{appointment.statusText}}</text>
|
||||
<text wx:else class="tag">{{appointment.statusText}}</text>
|
||||
<button wx:if="{{!appointment.historicalBackfill}}" class="small-action" bindtap="goTransfer">{{isUnassigned ? '分配员工' : '改派'}}</button>
|
||||
</view>
|
||||
</view>
|
||||
<view class="detail-grid">
|
||||
@@ -44,8 +45,8 @@
|
||||
</view>
|
||||
|
||||
<view wx:if="{{!loadError}}" class="fixed-bottom action-row">
|
||||
<button class="secondary-btn" disabled="{{isUnassigned}}" bindtap="confirm">{{isUnassigned ? '待分配' : '确认'}}</button>
|
||||
<button class="primary-btn" disabled="{{isUnassigned}}" bindtap="complete">完成</button>
|
||||
<button wx:if="{{!appointment.historicalBackfill}}" class="secondary-btn" disabled="{{isUnassigned}}" bindtap="confirm">{{isUnassigned ? '待分配' : '确认'}}</button>
|
||||
<button class="primary-btn" disabled="{{isUnassigned}}" bindtap="complete">{{appointment.historicalBackfill ? '完成补单' : '完成'}}</button>
|
||||
<button class="danger-btn" bindtap="cancel">取消</button>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
Reference in New Issue
Block a user