Community Tip - Want the oppurtunity to discuss enhancements to PTC products? Join a working group! X
I've been trying to add a custom menu item to an existing AMU installation. The documentation specifies that you need to add entries to a couple of tables in the database. (link)
It seems like a straightforward process, however I haven't been able to get it to work. No matter what I try it doesn't show a new menu. I know I'm in the right tables because I can edit the existing items and see the changes in the application, but any new entry is disregarded.
Has anyone had any success with this? Could it be something to do with the license? Maybe there's an extra step after the DB edits?
Solved! Go to Solution.
Replying to my own post,
After a support session with @mstarnaud we found that, because I was copying and pasting values from Excel into the MSSQL database, at the end of every entry there was an invisible CR LF (Carriage Return / Line Feed) character. Because of this, ThingWorx was unable to find the user group I was refering to in the DB and the necessary permissions for the added menu were not been granted. As a result, the added custom menu was not shown.
Having removed every CR/LF character from the row in the DB, everything is working as expected.
A big thank you to everyone from support and a special shout out to Michel!
Hi Gonzalo
Can you tell us the hierarchy you're trying to add? Here's an example : "beside the AMU icon I want to add a Project icon, and in its sub-menu I want to add 2 icons : Configuration and Execution. But my Project icon is not showing up and I can't access the sub-menu"
I ask mostly because the 2 levels act very differently so it's important to know which one is not working. And recently we discovered an issue where icons in the main menu (MenuContext table) will not show up if they don't have any child sub-menu icons (Menu & MenuContextLink tables). Also, items for which you don't have the permissions will not appear in the menu (MenuContext.UserGroupName and Menu..UserGroupName).
We don't do any license checks for menu items, so this can't be the reason. And I'm pretty sure the only other step that's not in SQL is adding the necessary items in Composer if you do use new items (images, Mashup, localization token). And if those Composer items are missing, I believe they just show with displaying issues (like the square being blank, but you do see a square).
If you're willing, you could share the data that you added in the database (all 3 tables, all columns) and we can try to debug them.
Replying to my own post,
After a support session with @mstarnaud we found that, because I was copying and pasting values from Excel into the MSSQL database, at the end of every entry there was an invisible CR LF (Carriage Return / Line Feed) character. Because of this, ThingWorx was unable to find the user group I was refering to in the DB and the necessary permissions for the added menu were not been granted. As a result, the added custom menu was not shown.
Having removed every CR/LF character from the row in the DB, everything is working as expected.
A big thank you to everyone from support and a special shout out to Michel!