Get Categories Method

  • LAC Webadmin
  • Topic Author
  • Offline
  • Senior Boarder
  • Senior Boarder
More
5 months 1 week ago #120841 by LAC Webadmin
Get Categories Method was created by LAC Webadmin
Hi Tuan,

Is there any method to get categories which includes all categories including subcategories? I tried EventbookingModelCategories but it will only pull the parent categories.

Thanks,

Jackson

Please Log in or Create an account to join the conversation.

More
5 months 1 week ago #120854 by Tuan Pham Ngoc
Replied by Tuan Pham Ngoc on topic Get Categories Method
Hi

We don't have that method available. However, you can look at the method EventbookingHelper::getTotalEvent and borrow some code from there to get all children categories of a given category

Tuan

Please Log in or Create an account to join the conversation.

  • LAC Webadmin
  • Topic Author
  • Offline
  • Senior Boarder
  • Senior Boarder
More
5 months 1 week ago #120884 by LAC Webadmin
Replied by LAC Webadmin on topic Get Categories Method
Hi Tuan,

Got it! Just like I thought, I actually borrowed the code from the categories view model.

Thanks,

Jackson

Please Log in or Create an account to join the conversation.

More
5 months 1 week ago #120910 by Tuan Pham Ngoc
Replied by Tuan Pham Ngoc on topic Get Categories Method
OK, great.

Please Log in or Create an account to join the conversation.

Moderators: Tuan Pham Ngoc