feat: 区分普通订单和ai订单的查看物流
This commit is contained in:
@@ -17,7 +17,7 @@
|
||||
{{ formatAfterSaleStatus(props.data) }}
|
||||
</view>
|
||||
</view>
|
||||
<card_order :data="props.data" :source="props.data.__source" :delay-records="state.delayRecords" v-if="!props.isAfterSale" type="3"></card_order>
|
||||
<card_order :data="props.data" :source="props.data.__source" :delay-records="state.delayRecords" v-if="!props.isAfterSale" type="3" @openExpress="goExpressLog"></card_order>
|
||||
<view v-else class="con_item flex-center ju-between al-flex-start">
|
||||
<view class="order_img shrink">
|
||||
<image :src="`${props.data.picUrl}`" mode="aspectFill" />
|
||||
@@ -225,7 +225,9 @@
|
||||
};
|
||||
|
||||
const isAiActionOrder =
|
||||
String(props.data?.__source) === 'aishop' || Number(props.data?.type) === 5;
|
||||
String(props.data?.__source) === 'aishop' ||
|
||||
Number(props.data?.type) === 4 ||
|
||||
Number(props.data?.type) === 5;
|
||||
const isAiStoreOrder = computed(() => String(props.data?.__source) === 'aishop');
|
||||
const isPickUpOrder = computed(() => {
|
||||
if (Number(props.data?.deliveryType) === 2) return true;
|
||||
@@ -501,8 +503,15 @@
|
||||
});
|
||||
return;
|
||||
}
|
||||
// 店铺订单(source=aishop)、入店订单(type=4)、赠送店铺订单(type=5) 一律弹窗查看物流;只有普通商城订单走原生跳转
|
||||
const orderType = Number(props.data?.type ?? 0);
|
||||
if (orderType !== 0 && isAiStoreOrder.value && !isPickUpOrder.value) {
|
||||
const isStoreOrGiftOrInStore =
|
||||
isAiStoreOrder.value || orderType === 4 || orderType === 5;
|
||||
if (!isStoreOrGiftOrInStore) {
|
||||
proxy.utils.go('/pages/order/express/log', { id });
|
||||
return;
|
||||
}
|
||||
if (!isPickUpOrder.value) {
|
||||
expressListPopupRef.value?.open?.();
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -31,12 +31,7 @@
|
||||
let show = ref(false);
|
||||
let list = ref([]);
|
||||
const logistics = () => {
|
||||
if (props.code === 2) {
|
||||
emit('openExpress', { data: props.data, code: props.code });
|
||||
return;
|
||||
}
|
||||
getData();
|
||||
show.value = true;
|
||||
emit('openExpress', { data: props.data, code: props.code });
|
||||
};
|
||||
const close = () => {
|
||||
show.value = false;
|
||||
|
||||
Reference in New Issue
Block a user