Copied to clipboard

Flag this post as spam?

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


  • Joao Pinto 3 posts 73 karma points
    1 week ago
    Joao Pinto
    0

    V8 - Custom property editor - how to reuse umbraco umb-editor?

    Hello,

    I'm trying to update a custom property editor originally developed for Umbraco 7, to make it compatible with Umbraco 8.

    The property editor includes some fields and a content picker. For the content picker I used the original umb-editor contentPicker, but the same code is not working on Umbraco 8, it throws a 404 error.

    I tried to look at Umbraco 8 source and googled all around, but couldn't find a way to make it work, so here comes the question: What's the way to include umbraco editors inside a custom property editor? Specifically the content picker.

    Thank you.

    Code used on V7 implementation: html:

    <div ng-controller="Positioner.LinkButtonController">
      <div class="linkbutton-row">
        <label>internal link: </label>
        <div>
            <umb-editor model="contentPicker"></umb-editor>
        </div>
    </div>
    

    controller.js:

    angular.module("umbraco")
    .controller("Positioner.LinkButtonController", function ($scope, $http, $location, editorState) {
        $scope.contentPicker = {
            view: 'contentPicker',
            config: {
                minNumber: 0,
                maxNumber: 1
            },
            value: $scope.model.value.InternalLink
        };
    });
    
  • Joao Pinto 3 posts 73 karma points
    1 week ago
    Joao Pinto
    0

    Question still open...

Please Sign in or register to post replies

Write your reply to:

Draft