简体   繁体   English

Joomla自定义组件需要创建菜单

[英]Joomla custom component need to create menu

I am using Joomla 1.5 . 我正在使用Joomla 1.5。 I have developed a custom component that's basically a product catalog but with many custom admin options for the product page and categories. 我已经开发了一个自定义组件,该组件基本上是产品目录,但具有用于产品页面和类别的许多自定义管理选项。 I have also created a custom view. 我还创建了一个自定义视图。 In the component, you can create categories and assign them to the products. 在组件中,您可以创建类别并将其分配给产品。 After every category I add, I need to go to the Products menu in Joomla admin and add new item and assign the custom view, which is the category view. 添加完每个类别后,我需要转到Joomla管理员中的“产品”菜单并添加新项并分配自定义视图,即类别视图。 Basically I need some indications about how can I automate this process, I mean add a new category and on save to auto create the menu item, with the selected view, pass category name. 基本上,我需要一些有关如何自动执行此过程的指示,我的意思是添加一个新类别,并保存后自动创建带有选定视图的菜单项,并传递类别名称。 Has anyone done this before ? 有人做过吗? Maybe some article you know about this... 也许您对此有所了解...

Thanks. 谢谢。

In joomla , for every action there will be a data entry. 在joomla中,每个动作都会有一个数据条目。

On creating category or creating menu. 关于创建类别或创建菜单。

Just look what all tables are updated on creating category. 只需查看所有表在创建类别时已更新。

Then you can write a function for automation. 然后,您可以编写自动化功能。

When a category is created , call function and update or insert menu tables for a new menu. 创建类别后,调用功能并更新或插入新菜单的菜单表。

You can do it man. 你可以做的人。

I saw no answers after 4 hours , thats why am posting something like a pseudo code. 4小时后我没有看到任何答案,这就是为什么要发布伪代码之类的东西。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM