diff --git a/src/views/tool/Instead/index.vue b/src/views/tool/Instead/index.vue index b3e622c..5547ffa 100644 --- a/src/views/tool/Instead/index.vue +++ b/src/views/tool/Instead/index.vue @@ -803,15 +803,14 @@ onMounted(async () => { // tableCode, // }); let res = '' - if (carts.table_code) { - res = await orderApi.getHistoryList({ - // orderId: carts.oldOrder.id, - tableCode: carts.table_code, - }); - } else { + if (id) { res = await orderApi.getHistoryList({ orderId: id, }) + } else { + res = await orderApi.getHistoryList({ + tableCode: carts.table_code, + }); } const noPayStatus = {