|
@@ -2,6 +2,7 @@ import OSticky from '@/components/o-sticky'
|
|
|
import { useRect } from '@vant/use'
|
|
|
import { Cell, CellGroup, Image, Tab, Tabs } from 'vant'
|
|
|
import { defineComponent, onMounted, reactive, ref } from 'vue'
|
|
|
+import { useRoute } from 'vue-router'
|
|
|
import PaidList from './component/paid-list'
|
|
|
import RefundList from './component/refund-list'
|
|
|
import WaitPay from './component/wait-pay'
|
|
@@ -10,9 +11,10 @@ import styles from './index.module.less'
|
|
|
export default defineComponent({
|
|
|
name: 'trade-record',
|
|
|
setup() {
|
|
|
+ const route = useRoute()
|
|
|
const tabs = sessionStorage.getItem('tradeRecordTabs')
|
|
|
const state = reactive({
|
|
|
- tabValue: (tabs || 'wait_pay') as 'wait_pay' | 'paid' | 'refund',
|
|
|
+ tabValue: (route.query.tab || tabs || 'wait_pay') as 'wait_pay' | 'paid' | 'refund',
|
|
|
height: 50
|
|
|
})
|
|
|
const tabsRef = ref()
|