Sample Route: /apps/subscriptions/subscription-list
I'd like to use "KDDataTable" to render my data, but in demo they use a static typescript list.
const data = ref([
{
id: 1,
customer: "Emma Smith",
status: "Active",
color: "success",
billing: "Auto-debit",
product: "Basic",
createdDate: "Oct 25, 2021",
},
{
id: 2,
customer: "Melody Macy",
status: "Active",
color: "success",
billing: "Manual - Credit Card",
product: "Basic",
createdDate: "Mar 10, 2021",
},
{
id: 3,
customer: "Max Smith",
status: "Active",
color: "primary",
billing: "Manual - Cash",
product: "Teams Bundle",
createdDate: "Jul 25, 2021",
}
.... }
But, I use my own data by axios request and all the fields can work properly, but the only field "Actions", if I don't use a static list as I click the button the sub-menu not show but force refresh the page.
My Code:
http://codepad.org/sULPH9Ln
Hi Anthony,
The problem is related to our MenuComponent, we initialize this component on every page to create menu instances. Since table data is rendered asynchronously at the moment of component initialization, menu items in the table don't exist. To fix this you can just reinitialize the menu component when data is received.
Call the reinitialization function of MenuComponent.
MenuComponent.reinitialization();
Thanks, I will try.
Hi Anthony,
Let me know if you will need any further help from us
Regards,
Lauris Stepanovs,
Keenthemes Support Team