Skip to main content

Adding custom endpoints / menus to Customer Portal

It appears that adding custom endpoints or menu items to the Customer Portal (or reorganizing the existing ones) is not currently supported.

It would be extremely helpful if you could provide an estimated timeline for when the relevant hooks, filters, or actions will become available. πŸ™

Vibe Code

I thought FluentCart already supports adding custom endpoints and menu items to the Customer Portal. Did you check that or you assume it's not supported?

The API Already Exists

FluentCart exposes a public API via fluent_cart_api() (defined in boot/globals.php:193), which returns a FluentCartGeneralApi singleton with a dedicated method:

fluent_cart_api()->addCustomerDashboardEndpoint($slug, $args);

Source: api/FluentCartGeneralApi.php:25-93

What's NOT Extensible

  1. Vue router β€” Routes are hardcoded in Start.js. You can't add Vue-based SPA pages from PHP
  2. Secondary nav (CustomerDashboardNav.vue) β€” The in-page tab bar is hardcoded with no filter
  3. Existing page modifications β€” You can filter data via REST response filters, but you can't inject Vue components into existing pages
  4. Menu ordering β€” Custom items always go before "Profile". No priority system

I'm building that convenient plugin, did tests already so above will work... anyway we will see soon

Vibe Code

you can try this plugin https://fchub.co/docs/fchub-portal-extender

I reckon it's something you asked for

Jonathan Gwyer

Vibe CodeΒ brilliant!

1.00

Vibe Code

Jonathan GwyerΒ well... that's a quote from one of my clients... she said that when I told her to add some ready to use code to functions.php

Sascha Leem

Vibe CodeΒ pretty funny line, actually πŸ˜…

Sascha Leem

Oh wow, thank you so much, Vibe Code πŸ™ Will test tomorrow and report ...