Saturday, April 6, 2019

Re: In the browser it looks ugly, why?

Short answer, it's giving you exactly what you asked for: the query set inside <ul> tags.
What you probably want is to loop through the ingredients and place them inside <li> tags. Something like:
<ul>
{% for ingredient in object.ingredientes.all %}
<li>{{ ingredient.cantidad }} {{ ingredient.nombre }}</li>
{% endfor %}
</ul>

On Sat, Apr 6, 2019 at 4:28 PM Barkalez XX <barkala19@gmail.com> wrote:
Why does this happen to me?






 html:                        https://dpaste.de/AVti  


 views.py:            https://dpaste.de/44Jz   


 models.py:         https://dpaste.de/Dfwy



I want to list all the ingredients in that recipe and make it look beautiful.

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/07ff0403-914f-46ae-a418-6c42a9de8ac2%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/CA%2Bv0ZYUMiGD0ZWXwWXOih%2BbGuWoX8nSDAKkC5V75scuDcs2JhQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

No comments:

Post a Comment