1. 诊所管理
This commit is contained in:
@@ -30,7 +30,7 @@
|
||||
<u-tag v-if="doctorInfo.DoctorInfo.user.status==3" text="审核未通过" type="warning" size="mini"
|
||||
border-color="#A7ABB0" bgColor="#A7ABB0" color="#fff" />
|
||||
</view>
|
||||
<text>
|
||||
<text style="width: 400rpx;">
|
||||
{{`${doctorInfo.store.store.name}(${doctorInfo.DoctorInfo.depart['name']})`}}
|
||||
</text>
|
||||
</view>
|
||||
@@ -397,6 +397,9 @@ export default {
|
||||
systemList: [],
|
||||
see_rate: "",
|
||||
acceptingPatientList: [], // 正在接诊的患者列表
|
||||
refreshTimer: null,
|
||||
refreshIntervalMs: 10000,
|
||||
isReceptionRefreshing: false,
|
||||
};
|
||||
},
|
||||
watch: {
|
||||
@@ -421,6 +424,7 @@ export default {
|
||||
|
||||
},
|
||||
onUnload() {
|
||||
this.stopRefreshTimer();
|
||||
if (this.__doctorImRoomUpdateHandler) {
|
||||
uni.$off('doctor-im-room-update', this.__doctorImRoomUpdateHandler);
|
||||
this.__doctorImRoomUpdateHandler = null;
|
||||
@@ -433,6 +437,7 @@ export default {
|
||||
uni.$off('doctor-im-room-update', this.__doctorImRoomUpdateHandler);
|
||||
uni.$on('doctor-im-room-update', this.__doctorImRoomUpdateHandler);
|
||||
this.refreshWorkbenchData();
|
||||
this.startRefreshTimer();
|
||||
},
|
||||
onPullDownRefresh() {
|
||||
this.refreshWorkbenchData().finally(() => {
|
||||
@@ -440,6 +445,7 @@ export default {
|
||||
});
|
||||
},
|
||||
onHide() {
|
||||
this.stopRefreshTimer();
|
||||
if (this.__doctorImRoomUpdateHandler) {
|
||||
uni.$off('doctor-im-room-update', this.__doctorImRoomUpdateHandler);
|
||||
}
|
||||
@@ -454,6 +460,31 @@ export default {
|
||||
this.getAcceptingPatientList()
|
||||
]);
|
||||
},
|
||||
refreshReceptionData() {
|
||||
if (this.isReceptionRefreshing) {
|
||||
return Promise.resolve();
|
||||
}
|
||||
this.isReceptionRefreshing = true;
|
||||
return Promise.all([
|
||||
this.getInfo(),
|
||||
this.getList(),
|
||||
this.getAcceptingPatientList()
|
||||
]).finally(() => {
|
||||
this.isReceptionRefreshing = false;
|
||||
});
|
||||
},
|
||||
startRefreshTimer() {
|
||||
this.stopRefreshTimer();
|
||||
this.refreshTimer = setInterval(() => {
|
||||
this.refreshReceptionData();
|
||||
}, this.refreshIntervalMs);
|
||||
},
|
||||
stopRefreshTimer() {
|
||||
if (this.refreshTimer) {
|
||||
clearInterval(this.refreshTimer);
|
||||
this.refreshTimer = null;
|
||||
}
|
||||
},
|
||||
call () {
|
||||
uni.makePhoneCall({
|
||||
phoneNumber: '18157126670',
|
||||
|
||||
@@ -2,7 +2,8 @@
|
||||
<clinic-page-layout title="商品订单" :show-back="true">
|
||||
<view class="order-list-container">
|
||||
<!-- 顶部筛选 -->
|
||||
<page-sticky-header>
|
||||
<view class="native-sticky-header" :style="{ top: navTopOffset + 'px' }">
|
||||
<view class="header-solid-bg">
|
||||
<view class="quick-filter">
|
||||
<view class="filter-row date-row">
|
||||
<picker mode="date" :value="dateStart" @change="onStart">
|
||||
@@ -12,9 +13,10 @@
|
||||
<picker mode="date" :value="dateEnd" @change="onEnd">
|
||||
<view class="filter-picker date-picker">{{ dateEnd || '结束日期' }}</view>
|
||||
</picker>
|
||||
<view class="btn-query" @click="reload">查询</view>
|
||||
</view>
|
||||
<view class="filter-query-btn" @click="reload">查询</view>
|
||||
</view>
|
||||
|
||||
<collapsible-filter-panel title="订单筛选" @clear="resetFilter">
|
||||
<view class="filter-row">
|
||||
<text class="filter-label">订单号</text>
|
||||
@@ -39,7 +41,8 @@
|
||||
</picker>
|
||||
</view>
|
||||
</collapsible-filter-panel>
|
||||
</page-sticky-header>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<!-- 统计卡片区 -->
|
||||
<scroll-view v-if="statItems.length" class="stats-scroll" scroll-x>
|
||||
@@ -607,4 +610,69 @@ $color-text-muted: #86909C;
|
||||
padding: 120rpx 0;
|
||||
font-size: 28rpx;
|
||||
}
|
||||
|
||||
|
||||
/* ================= 核心:完美吸顶方案 ================= */
|
||||
/* 原生 sticky 结合 Vue 计算出的精确导航栏高度(top),严丝合缝拦截在导航栏正下方 */
|
||||
.native-sticky-header {
|
||||
position: -webkit-sticky;
|
||||
position: sticky;
|
||||
z-index: 100; /* 高层级,保证滑动时覆盖在下方的卡片上 */
|
||||
background-color: $color-bg-base; /* 必须有底色用于防穿透遮挡 */
|
||||
}
|
||||
|
||||
.header-solid-bg {
|
||||
/* 使用 padding 将内容向内挤,防止滑动过程的透明间隙穿透问题 */
|
||||
padding: 16rpx 24rpx 16rpx;
|
||||
}
|
||||
|
||||
/* 筛选项 UI 美化 */
|
||||
.quick-filter {
|
||||
background: #fff;
|
||||
padding: 16rpx 20rpx;
|
||||
border-radius: 20rpx;
|
||||
box-shadow: 0 4rpx 16rpx rgba(0, 0, 0, 0.04);
|
||||
}
|
||||
.filter-row {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 16rpx;
|
||||
margin-bottom: 24rpx;
|
||||
&:last-child { margin-bottom: 0; }
|
||||
}
|
||||
.date-row {
|
||||
margin-bottom: 0;
|
||||
justify-content: space-between;
|
||||
}
|
||||
.filter-label {
|
||||
font-size: 28rpx;
|
||||
color: $color-text-body;
|
||||
min-width: 130rpx;
|
||||
}
|
||||
.filter-input, .filter-picker {
|
||||
flex: 1;
|
||||
font-size: 26rpx;
|
||||
padding: 14rpx 20rpx;
|
||||
background: #F7F8FA;
|
||||
border-radius: 12rpx;
|
||||
color: $color-text-main;
|
||||
}
|
||||
.date-picker { text-align: center; }
|
||||
.sep { color: $color-text-muted; font-size: 24rpx; }
|
||||
|
||||
/* 重新设计的紧凑型查询按钮 */
|
||||
.btn-query {
|
||||
flex-shrink: 0;
|
||||
background: $theme-primary;
|
||||
color: #fff;
|
||||
padding: 0 32rpx;
|
||||
height: 60rpx;
|
||||
line-height: 60rpx;
|
||||
border-radius: 30rpx; /* 胶囊圆角 */
|
||||
font-size: 26rpx;
|
||||
font-weight: 500;
|
||||
box-shadow: 0 4rpx 12rpx rgba(106, 205, 187, 0.3);
|
||||
transition: opacity 0.2s;
|
||||
&:active { opacity: 0.8; }
|
||||
}
|
||||
</style>
|
||||
Reference in New Issue
Block a user