Giter Site home page Giter Site logo

Comments (2)

ncuillery avatar ncuillery commented on May 27, 2024

Hi,

The philosophy of the UI-router is different from the native one. The state machine must have to be a hierarchical tree of states. In your example, the project-detail must be a child of home state (for real, not only in breadcrumb).

To doing this, four steps:

  • change the name of the state to home.project-detail or add a parent key equals to home
  • wrap the templateUrl and controller keys under a key in a views object. The value of the key depends on the location of the ui-view directive (probably '@' if it is located in index.html, see UI-router multiple views documentation for details).
  • change the url to the fragment which has to be added to the parent state's url. Here: /:projectId (I suppose your home state have the url /project)
  • remove the ncyBreadcrumbParent property, no longer needed because the state has a real parent.

Do the same for subject-group-list.

By doing this, you will be able to use all the facilities provided by the UI-router (including state parameters inheritance between states, which is the problem here).

Here is a plunker using your configuration updated to work well with the ui-router.

from angular-breadcrumb.

whitews avatar whitews commented on May 27, 2024

Got it! I have it working now. Thanks again for your help and for providing this awesome module!

from angular-breadcrumb.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.