Hello,
I’m using ionic rc1, any idea about passing param between tabs?
for example, I need to view shop profile, the shop id is 1, the shop profile have 4 tabs, profile, products, offers and branches. I need to pass the shop id between tabs so I can query the shop in the database.
Thanks
so, in app.routing i have:
{ path: 'merchant-home/:id', loadChildren: './merchant-home/merchant-home.module#MerchantHomePageModule' },
in merchant module i have routing setup:
const routes: Routes = [
{
path: '',
component: MerchantHomePage,
children: [
{
path: 'merchant-all',
children: [
{
path: '',
loadChildren: '../merchant-all/merchant-all.module#MerchantAllPageModule'
}
]
},
{
path: 'merchant-discount',
children: [
{
path: '',
loadChildren: '../merchant-discount/merchant-discount.module#MerchantDiscountPageModule'
}
]
},
{
path: 'merchant-oneday',
children: [
{
path: '',
loadChildren: '../merchant-oneday/merchant-oneday.module#MerchantOnedayPageModule'
}
]
},
{
path: '',
redirectTo: '/merchant-home/merchant-all',
pathMatch: 'full'
}
]
}
];
everything is working, so when i visit this link manually
http://localhost:8100/merchant-home/1/merchant-all
but the router take me dynamically to:
http://localhost:8100/merchant-home/merchant-all
and I can receive the id on the tabs page, but not on a single tab.