修复socket信息弹窗问题,修复菜品状态未上菜超市显示问题

This commit is contained in:
2025-12-01 13:47:56 +08:00
parent d2ba7af340
commit 2c2a87ab19
4 changed files with 25 additions and 8 deletions

View File

@@ -24,7 +24,11 @@
>
<view class="badge">{{ item.packNumber }}</view>
</text>
<template v-if="item.subStatus &&cartStore.shopInfo.registerType=='after'">
<template
v-if="
item.subStatus && cartStore.shopInfo.registerType == 'after'
"
>
<text
class="status"
:class="[
@@ -111,13 +115,16 @@ const timer = setInterval(() => {
}, 1000);
//超时时间
const maxTime = cartStore.shopInfo.serveTime*60*1000;
const maxTime = cartStore.shopInfo.serveTime * 60 * 1000;
function returnStatusClass(item) {
if (item.subStatus == "DELIVERED") {
return "success";
}
if (item.subStatus == "READY_TO_SERVE") {
if (
item.subStatus == "READY_TO_SERVE" &&
returnSubStatusText(item) != "已超时"
) {
return "warning";
}
if (item.subStatus == "SENT_OUT") {
@@ -133,7 +140,7 @@ function returnSubStatusText(item) {
return "待起菜";
}
if (item.subStatus == "READY_TO_SERVE") {
if (item.startOrderTime&&cartStore.shopInfo.isServeTimeControl) {
if (item.startOrderTime && cartStore.shopInfo.isServeTimeControl) {
const maxWaitTime = dayjs(item.startOrderTime).add(
maxTime,
"millisecond"
@@ -265,7 +272,7 @@ function itemClick(item) {
.badge {
position: absolute;
text-align: center;
$height:32rpx;
$height: 32rpx;
line-height: $height;
height: $height;
top: calc(-#{$height} / 2);