Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

LinkItemCollection showing [Object, object] #876

Open
whoisyourvladie opened this issue Sep 15, 2022 · 0 comments
Open

LinkItemCollection showing [Object, object] #876

whoisyourvladie opened this issue Sep 15, 2022 · 0 comments

Comments

@whoisyourvladie
Copy link

MenuItemBlock showing [Object object] instead of link names

There are traces that there was an attempt to fix it:

  • a dojo file ~\src\Foundation\modules_protected\Foundation\Scripts\MenuChildItems.js that tries to fix it.
  • Attribute [ClientEditor(ClientEditingClass = "foundation/MenuChildItems")] over the ChildItems property in ~\src\Foundation\Features\Blocks\MenuItemBlock\MenuItemBlock.cs (commented out)

If you uncomment the attribute - the block won't open for editing and you get an error in browser console:

Uncaught Error: declare: mixin #0 is not a callable constructor. at err (dojo.js:3999:32) at c3mro (dojo.js:4012:5) at declare (dojo.js:4732:12) at MenuChildItems.js:15:16 at runFactory (dojo.js:1107:43) at execModule (dojo.js:1236:5) at dojo.js:1271:6 at guardCheckComplete (dojo.js:1251:5) at checkComplete (dojo.js:1266:4) at onLoadCallback (dojo.js:1428:7)

To Reproduce
Steps to reproduce the behavior:

  1. Login to CMS Admin
  2. Open Demo Settings Import page
  3. In Top Content Area find Layout Settings block
  4. Edit Layout Settings block
  5. Go to Menu Tab
  6. In Main Menu content Area try to edit the first block
  7. Scroll to bottom and observe [Object object] in Child links column of Child Items section
  8. Uncomment in the source code attribute [ClientEditor(ClientEditingClass = "foundation/MenuChildItems")] over the ChildItems property in ~\src\Foundation\Features\Blocks\MenuItemBlock\MenuItemBlock.cs
  9. Restart the project, open browser dev tools and repeat steps 1-6
    10.Observe the error in dev tools console

Note
Use main branch

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant