Umbraco-cms: Cannot set property 'selected' of undefined when moving items in a listview

Created on 27 Feb 2019  路  3Comments  路  Source: umbraco/Umbraco-CMS

I've installed the new Umbraco 8 Starter Kit, then created a new document type called Product Category and made it a child of the Products node (setting relevant permissions so that Products can be placed under it as well). I can create a new content node "Apparel" with the new Content Type, but when I select one or more products in the ListView and try to move them, I get the following error when I attempt to select the "Apparel" node:

angular.js?cdv=369272066:15536 TypeError: Cannot set property 'selected' of undefined
    at nodeSelectHandler (umbraco.controllers.js?cdv=369272066:2485)
    at ChildScope.MoveController.$scope.selectListViewNode (umbraco.controllers.js?cdv=369272066:2519)
    at fn (eval at compile (angular.js?cdv=369272066:16387), <anonymous>:4:241)
    at Scope.destination.(anonymous function) [as onSelect] (http://localhost:38903/umbraco/lib/angular/angular.js?cdv=369272066:11376:22)
    at ChildScope.scope.selectNode (umbraco.directives.js?cdv=369272066:12521)
    at fn (eval at compile (angular.js?cdv=369272066:16387), <anonymous>:4:220)
    at callback (angular.js?cdv=369272066:28815)
    at ChildScope.$eval (angular.js?cdv=369272066:19356)
    at ChildScope.$apply (angular.js?cdv=369272066:19455)
    at HTMLDivElement.<anonymous> (angular.js?cdv=369272066:28819)

Reproduction

  • Install Umbraco 8.0.0 and the starterkit
  • Add a new Document Type "Product Category"
  • Add Product to the list of allowed children of the new doc type
  • Add "Product Category" to the list of allowed children of the Products Document Type
  • Add a new node under Products called "Apparel"
  • Select an item from the list of Products in the Child View
  • Select Move from the actions along the top
  • Find and select the Apparel Node in the dialog

The Apparel node should be ticked at this stage, but it's not and the above error shows up in the console. It appears to be something to do with the listview item picker as the tree picker selects items perfectly fine.

communitpr releas8.0.1 typbug

All 3 comments

Myself and Sam are looking into this for UDUF 19 hack day

This can be reproduced with any product, not just the newly created Apparel item

Upon further investigation, it has been discovered that the function function nodeSelectHandler(args) was recently refactored and used to be function nodeSelectHandler(ev, args). When this was refactored, the calls to this function were not also refactored to include just one parameter. We have discussed this issue with @Shazwazza and we will update this issue to include the refactoring of all of the calls to the nodeSelectHandler function to pass the correct parameters.

Was this page helpful?
0 / 5 - 0 ratings