MenuHelper improvements

5 views
Skip to first unread message

Alexander Obuhovich

unread,
Aug 27, 2012, 1:11:36 PM8/27/12
to Development In-Portal
Right now we have nice <inp2:st_CachedMenu .../> tag, that prints every menu on website without doing a database query.
This works good, however in some projects I came across situations where a new database field (e.g. extra css class name) was added to a page (category) and this field needs to be used during menu printing.

This requires to override 2 methods in MenuHelper class.

I'm proposing to create an array (as a property of MenuHelper class), where mapping is created between Categories database table fields and parameter names, used to retrieve their values from template.

Here is an example array:

Array (
'parent_path' => 'ParentPath',
'icon' => Array ('Icon', 'resize:100x100'),
);

Then these parameters would be used with GetField method.

Dmitry A.

unread,
Sep 16, 2012, 12:56:50 AM9/16/12
to in-por...@googlegroups.com
Yes, I totally support this idea.

Please go ahead and file new task. Perhaps, it can go to In-Portal 5.2.1 as minor addition / optimization?


DA

Alexander Obuhovich

unread,
Sep 16, 2012, 7:48:20 AM9/16/12
to in-por...@googlegroups.com
Here is a new task:  http://tracker.in-portal.org/view.php?id=1400

Added to 5.3.0 since it's a feature none the less.
Reply all
Reply to author
Forward
0 new messages