Comments (7)
I'll check that later today and push a fix if needed. Thanks
from bootstrap-breadcrumbs.
Can you test latest code from github? If it works I'll push new version to pypi. Thanks
from bootstrap-breadcrumbs.
I'll test it tonight.
from bootstrap-breadcrumbs.
This no longer throws an error, but this does not render any breakcrumbs
{% block breadcrumbs %}
{% breadcrumb customer 'customer-details' cust_id=customer.id %}
{% breadcrumb customer 'contact-details' cust_id=customer.id contact_id=contact.id %}
{% endblock %}
{% block content %}
bc{% render_breadcrumbs %}cb
...
{% endblock content %}
from bootstrap-breadcrumbs.
can you retry with latest code from github?
from bootstrap-breadcrumbs.
if it still doesn't work please paste contact-details
and urls.py for it (only view definition, not full code), maybe I'm missing test case for it
from bootstrap-breadcrumbs.
Ok, the problem is one of documentation. Notice above how I have two blocks, one for breadcrumbs
and one for content
, you can't do that because you don't know which order the blocks will be rendered in. The docs need to say do all of it inline in one block like this:
{% breadcrumb customer 'customer-details' cust_id=customer.id %}
{% breadcrumb customer 'contact-details' cust_id=customer.id contact_id=contact.id %}
{% render_breadcrumbs %}
This works as expected. I had to go thru the debugger to understand what was happening, but it really was this simple.
The kwargs problem was a real problem, this last issue was just documentation that wasn't explicit enough.
Even though the blocks were in the right order in this template, they were in a different order in the site base template and therefore they rendered incorrectly. In my case breadcrumbs were added AFTER they had been rendered.
from bootstrap-breadcrumbs.
Related Issues (20)
- Replace GPL with a more permissive license, like BSD or MIT HOT 3
- bootstrap_for template tag does not support named view with namespace HOT 6
- add breadcrumb_raw without translation
- Make TEMPLATE_CONTEXT_PROCESSORS checks smarter or more lenient HOT 3
- named route and kwargs not respected HOT 1
- How user with Class View ? HOT 2
- Templatetag is causing 'RemovedInDjango110Warning: render() must be called with a dict, not a RequestContext.' HOT 3
- the templates aren't support to rich snippets HOT 3
- Dynamic variable to view function HOT 1
- No module named 'django.core.urlresolvers' HOT 2
- Space between slash and crumb HOT 4
- Issues with crumb not appearing HOT 14
- Labels are not links
- Labels translation not working
- Deprecation warnings under django-3.0 HOT 1
- No spacing after divider "/" HOT 2
- smart_text() is deprecated in favor of smart_str() HOT 3
- How to add additional html class for render_breadcrumbs?
- Templates not working as expected
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from bootstrap-breadcrumbs.