Custom Section Issue

Hi,
I built an Umbraco Backoffice extension, so I can have a Custom Section. It’s a Customers list with a link to the Customer’s detail page.
The issue occurs when I enter on the detail page. The page appears all blank (with no Umbraco menu). But if I get back to the Umbraco Backoffice Content page and try to enter the custom list → detail, it will work fine.
Investigating the HTML, when the page is all blank, I noticed that there’s a main div with ng-hide. It appears that Umbraco “thinks” I’m not logged in.
Note: I added some debuggers on the list and detail controllers and they are getting hit with no problem.
My file structure in App_Plugins is:

  • customersList.html
  • customersList.controller.js
  • customerDetail.html
  • customerDetail.controller.js
  • app.js
  • package.manifest

This is my app.js file with the routing.

angular.module("customersApp", ["ngRoute"])
    .config(function ($routeProvider) {

        $routeProvider
            .when("/customers", {
                templateUrl: "/App_Plugins/Customers/customersList.html",
                controller: "CustomersListController"
            })
            .when("/customers/detail/:id", {
                templateUrl: "/App_Plugins/Customers/customerDetail.html",
                controller: "CustomerDetailController"
            })
            .otherwise({
                redirectTo: "/customers"
            });
    });

angular.module("umbraco").requires.push("customersApp");

Let me know if you need more information.

Thank you all

It appears that Umbraco didn’t like <a> tags for the list URL’s. Changed to <button> and now it works! :slight_smile:

1 Like