fix(offers): align private navigation with portal dropdown menus
tests / ci (push) Canceled after 0s
tests / ci (push) Canceled after 0s
This commit is contained in:
@@ -0,0 +1,13 @@
|
||||
export type OfferListFilters = {
|
||||
state?: string;
|
||||
operational?: boolean;
|
||||
pending_reports?: boolean;
|
||||
};
|
||||
|
||||
export function offerListHref(filters: OfferListFilters = {}): string {
|
||||
const query = new URLSearchParams();
|
||||
if (filters.operational) query.set('operational', '1');
|
||||
if (filters.pending_reports) query.set('pending_reports', '1');
|
||||
if (filters.state) query.set('state', filters.state);
|
||||
return `/minhas-oportunidades/ofertas${query.size ? `?${query}` : ''}`;
|
||||
}
|
||||
@@ -347,6 +347,26 @@ export function legacyPortalNavigation(
|
||||
'Minhas oportunidades',
|
||||
profile.mine,
|
||||
),
|
||||
{
|
||||
id: 'private-offers',
|
||||
label: 'Ofertas',
|
||||
children: [
|
||||
link(
|
||||
'my-private-offers',
|
||||
'As minhas ofertas',
|
||||
'/minhas-oportunidades/ofertas',
|
||||
),
|
||||
...(profile.create
|
||||
? [
|
||||
link(
|
||||
'new-private-offer',
|
||||
'Preparar oferta',
|
||||
'/minhas-oportunidades/ofertas/criar',
|
||||
),
|
||||
]
|
||||
: []),
|
||||
],
|
||||
},
|
||||
]
|
||||
: []),
|
||||
...(profile.create
|
||||
|
||||
Reference in New Issue
Block a user