#8087: Template tags 'ifin' and 'ifnotin' checking if element is present in sequence ---------------------------------------------+------------------------------ Reporter: emes | Owner: nobody Status: new | Milestone: Component: Template system | Version: SVN Resolution: | Keywords: templatetag, tag, sequence Stage: Design decision needed | Has_patch: 1 Needs_docs: 0 | Needs_tests: 0 Needs_better_patch: 0 | ---------------------------------------------+------------------------------ Comment (by tomevans222):
I was the submitter of #10821, and the more I think on it, the more a separate tag seems ridiculous. Surely this behaviour should be supported in the default if tag? {{{ {% if foo in bar or a_bool or a_list %}{% wibble %}{% endif %} }}} dc: This would make your hard to do example: {{{ {% if user.is_anonymous or user in ban_list %} }}} Which do you think is easier to read and has a clearer intention? I will prepare a patch that achieves this. Cheers -- Ticket URL: <http://code.djangoproject.com/ticket/8087#comment:10> Django <http://code.djangoproject.com/> The Web framework for perfectionists with deadlines. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Django updates" group. To post to this group, send email to django-updates@googlegroups.com To unsubscribe from this group, send email to django-updates+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-updates?hl=en -~----------~----~----~----~------~----~------~--~---