|
|
@@ -1,5 +1,5 @@
|
|
|
<template>
|
|
|
- <view class="review-order-card">
|
|
|
+ <view class="review-order-card" :class="{ overdue: isOverdue }">
|
|
|
<!-- 订单信息 -->
|
|
|
<view class="order-info">
|
|
|
<view class="info-row">
|
|
|
@@ -75,6 +75,14 @@ const formatWaitingTime = (milliseconds) => {
|
|
|
|
|
|
return `${pad(hours)}:${pad(minutes)}:${pad(seconds)}`;
|
|
|
};
|
|
|
+
|
|
|
+// 超时未入库:申请复审后等待时间 >= 24 小时 且 未入库
|
|
|
+const isOverdue = computed(() => {
|
|
|
+ const waitingMs = Number(props.item?.waitingTime) || 0;
|
|
|
+ const notStocked = props.item?.stockStatus === 0;
|
|
|
+ const twentyFourHours = 24 * 60 * 60 * 1000;
|
|
|
+ return notStocked && waitingMs >= twentyFourHours;
|
|
|
+});
|
|
|
</script>
|
|
|
|
|
|
<style lang="scss" scoped>
|
|
|
@@ -85,6 +93,10 @@ const formatWaitingTime = (milliseconds) => {
|
|
|
margin-bottom: 20rpx;
|
|
|
box-shadow: 0 2rpx 8rpx rgba(0, 0, 0, 0.1);
|
|
|
|
|
|
+ &.overdue {
|
|
|
+ background: #fff2f0; // 轻红色背景,提升可读性
|
|
|
+ }
|
|
|
+
|
|
|
.order-info {
|
|
|
.info-row {
|
|
|
display: flex;
|