|
@@ -63,8 +63,7 @@ const column = [
|
|
|
]
|
|
|
|
|
|
|
|
|
-async function getList(parmas) {
|
|
|
- console.log('getList', parmas);
|
|
|
+async function getList() {
|
|
|
try {
|
|
|
uni.hideLoading();
|
|
|
uni.showLoading({
|
|
@@ -112,22 +111,18 @@ function onChange(tabItem) {
|
|
|
|
|
|
|
|
|
|
|
|
-// onMounted(init)
|
|
|
+onMounted(getList)
|
|
|
|
|
|
-onLoad((options) => {
|
|
|
- console.log('options',options);
|
|
|
- tab.value = options.status;
|
|
|
-})
|
|
|
|
|
|
onShow(() => {
|
|
|
const params = getApp().globalData.switchTabParams;
|
|
|
+ if(!params.tabKey) return;
|
|
|
tabKey.value = params.tabKey;
|
|
|
console.log(params); // { id: 123, type: "test" }
|
|
|
onChange(column[tabKey.value])
|
|
|
// 使用后建议清除参数,避免重复读取
|
|
|
getApp().globalData.switchTabParams = null;
|
|
|
|
|
|
- // init();
|
|
|
})
|
|
|
</script>
|
|
|
|