完善店务员工工时与订单记录

This commit is contained in:
2026-07-24 14:23:13 +08:00
parent 3a543f1d69
commit eff4e73427
20 changed files with 440 additions and 225 deletions
@@ -1,12 +1,31 @@
<view class="page no-tab">
<view class="card mini-calendar">
<view wx:for="{{days}}" wx:key="date" class="mini-day {{item.rest ? 'rest' : ''}}">{{item.day}}</view>
</view>
<view class="section">
<view class="section-title">请假记录</view>
<view class="list">
<view wx:for="{{records}}" wx:key="date" class="card list-card">{{item.date}} {{item.text}}</view>
<view class="card leave-form">
<view class="field">
<text class="field-label">请假日期</text>
<picker mode="date" value="{{leaveForm.workDate}}" bindchange="onLeaveDateChange">
<view class="field-value">{{leaveForm.workDate}}</view>
</picker>
</view>
<view class="field">
<text class="field-label">备注</text>
<input value="{{leaveForm.remark}}" bindinput="onLeaveRemarkInput" placeholder="可选,例如全天请假" />
</view>
</view>
<view class="fixed-bottom"><button class="primary-btn" bindtap="add">新增请假</button></view>
<view class="section">
<view class="section-title">工时记录</view>
<view class="list">
<view wx:if="{{loading}}" class="empty card">工时记录加载中...</view>
<view wx:elif="{{loadError}}" class="empty card error">
<text>{{loadError}}</text>
<button class="secondary-btn retry-btn" bindtap="loadRecords">重试</button>
</view>
<view wx:elif="{{records.length === 0}}" class="empty card">暂无请假记录</view>
<view wx:for="{{records}}" wx:key="id" class="card list-card leave-record">
<text class="leave-date">{{item.date}}</text>
<text class="leave-text">{{item.text}}</text>
</view>
</view>
</view>
<view class="fixed-bottom"><button class="primary-btn" loading="{{saving}}" bindtap="add">新增请假</button></view>
</view>