Browse Source

修复包明细和订单详情切换tab时查询

dev-xx
qb 4 months ago
parent
commit
5caf340c30
  1. 14
      src/views/waybill/orderDetails.vue
  2. 2
      src/views/waybill/orderPackageListDetails.vue

14
src/views/waybill/orderDetails.vue

@ -106,7 +106,7 @@
</template>
<script setup lang="ts">
import { ref, reactive, toRefs, computed, onMounted, nextTick } from 'vue';
import { ref, reactive, toRefs, computed, onMounted, nextTick, watch } from 'vue';
import functions from '@/utils/functions.js';
import dayjs from 'dayjs';
import { mapGetters } from 'vuex';
@ -231,7 +231,7 @@ const onLoad = async () => {
}
};
onLoad();
// onLoad();
/** 搜索 */
const searchChange = () => {
@ -360,6 +360,16 @@ const handleShowPackageOrderList = ({ row }) => {
},
});
};
watch(
() => $route.fullPath,
() => {
if ($route.path !== '/waybill/orderDetails') return;
onLoad();
},
{ immediate: true }
);
</script>
<style scoped lang="scss">

2
src/views/waybill/orderPackageListDetails.vue

@ -910,7 +910,7 @@ const handleBatchBarcode = async () => {
};
watch(
() => $route,
() => $route.fullPath,
() => {
console.log('$route :>> ', $route);
if ($route.path !== '/waybill/orderPackageListDetails') return;

Loading…
Cancel
Save