Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Thomas Beckert 162 posts 369 karma points
    Jan 22, 2016 @ 18:37
    Thomas Beckert
    0

    dialogService contentPicker filter by doctype

    Hi,

    I did not find any code example, so I don't know, if it is possible out of the box. But how do I have to change this code so that the user only can select content of a certain documentType:

    dialogService.contentPicker({            
            multiPicker: false,
            callback: function (data) {
                $scope.model.value.content = data.id + " " + data.name;
            }
        });
    
  • Yasir Butt 157 posts 366 karma points
    Jan 22, 2016 @ 18:54
    Yasir Butt
    100

    There is already exist Multinode Tree picker, which you can limited the doctype and even choose the start node for dialog

  • Thomas Beckert 162 posts 369 karma points
    Jan 22, 2016 @ 19:20
    Thomas Beckert
    0

    Hi,

    I need it in my custom property editor. So how can I use the Multinode Tree picker in Javascript, without copy&paste the code from the Multinode Tree Picker editor?

  • Thomas Beckert 162 posts 369 karma points
    Jan 22, 2016 @ 20:32
    Thomas Beckert
    1

    Ok. I found the solution thanks to your hint.

    The code should be:

     dialogService.contentPicker({
            multiPicker: true,
            filterCssClass: 'not-allowed not-published',
            filter: 'yourDocType1, yourDocType2',
            callback: function (data) {
                angular.forEach(data, function (value, key) {
                   //do something with value
                });
    
            }
        });
    
  • Harsheet 71 posts 302 karma points
    1 week ago
    Harsheet
    0

    Do you know how to hide the other nodes?

Please Sign in or register to post replies

Write your reply to:

Draft