|
|
@@ -43,8 +43,6 @@ const props = defineProps<{
|
|
|
blockOrder?: string[];
|
|
|
blocksEditable?: boolean;
|
|
|
metricLabelFontSize?: number;
|
|
|
- // TASK-006 [MOCK] 订单状态补充行(S1/S7 专用,其他卡片不传此 prop)
|
|
|
- orderStatus?: { completed: number; inProgress: number; delayed: number };
|
|
|
}>();
|
|
|
|
|
|
const emit = defineEmits<{
|
|
|
@@ -70,12 +68,7 @@ const shouldShowStatusLabel = computed(() => props.showStatusLabel ?? true);
|
|
|
const shouldShowProgress = computed(() => props.showProgress ?? true);
|
|
|
const isWide = computed(() => (props.cardSpan ?? 1) > 1);
|
|
|
|
|
|
-// TASK-006:orderStatus 存在时在末尾追加 order-status 块,避免非订单卡片多出空占位
|
|
|
-const activeBlockOrder = computed(() => {
|
|
|
- const base = props.blockOrder ?? DEFAULT_BLOCK_ORDER;
|
|
|
- if (!props.orderStatus) return base;
|
|
|
- return base.includes('order-status') ? base : [...base, 'order-status'];
|
|
|
-});
|
|
|
+const activeBlockOrder = computed(() => props.blockOrder ?? DEFAULT_BLOCK_ORDER);
|
|
|
|
|
|
// S8-STAGE-CARD-SEMANTIC-LAYOUT-EXEC-1:从 values 解析自然数(绿=正常,黄=关注,红=严重)。
|
|
|
function safeNum(v: unknown): number {
|
|
|
@@ -167,12 +160,6 @@ const yellowBarWidth = computed(() => {
|
|
|
</div>
|
|
|
</template>
|
|
|
|
|
|
- <!-- TASK-006 [MOCK]:订单状态补充行,仅 orderStatus prop 存在时渲染(S1/S7 订单类卡片) -->
|
|
|
- <template #order-status>
|
|
|
- <div v-if="orderStatus" class="stage-card__order-status">
|
|
|
- 订单状态:已完成 <span class="stage-card__order-status-num">{{ orderStatus.completed }}</span> 进行中 <span class="stage-card__order-status-num">{{ orderStatus.inProgress }}</span> 延误 <span class="stage-card__order-status-num">{{ orderStatus.delayed }}</span>
|
|
|
- </div>
|
|
|
- </template>
|
|
|
</CardBlockLayout>
|
|
|
</article>
|
|
|
</template>
|
|
|
@@ -466,20 +453,4 @@ const yellowBarWidth = computed(() => {
|
|
|
}
|
|
|
}
|
|
|
|
|
|
-/* TASK-006 [MOCK]:订单状态补充行样式 */
|
|
|
-.stage-card__order-status {
|
|
|
- font-size: 11px;
|
|
|
- color: rgba(198, 198, 205, 0.6);
|
|
|
- letter-spacing: 0.02em;
|
|
|
- white-space: nowrap;
|
|
|
- overflow: hidden;
|
|
|
- text-overflow: ellipsis;
|
|
|
- margin-top: 2px;
|
|
|
-}
|
|
|
-
|
|
|
-.stage-card__order-status-num {
|
|
|
- font-family: 'Roboto Mono', monospace;
|
|
|
- font-size: 12px;
|
|
|
- color: rgba(198, 198, 205, 0.85);
|
|
|
-}
|
|
|
</style>
|