ubuntu-bengali-manual team mailing list archive
-
ubuntu-bengali-manual team
-
Mailing list archive
-
Message #04140
[Bug 701115] Re: Template error when team has no name
As long as this line in teams/models.py contains null=True
name = models.CharField(_("Team Name"), max_length=80, null=True)
The database is valid even when a team has no name (blank=False which
means when submitting a form this field is required). But still with
importing new team or other cases that the team info is not edited by
the HTML form, its possible to have empty fields.
Is this null=True needed in any case?
--
You received this bug notification because you are a member of Ubuntu
Bengali Manual, which is subscribed to loco-directory.
https://bugs.launchpad.net/bugs/701115
Title:
Template error when team has no name
Status in LoCo Directory:
New
Bug description:
on the page http://localhost:8000/teams/<team-slug> where the team has
no name (as far not seen in live database) i got the following error
Exception Type: TemplateSyntaxError
Exception Value: Caught AttributeError while rendering: 'NoneType' object has no attribute 'replace'
In template loco_directory/templates/teams/team_detail.html, error at line 4
{% block title %}{% trans team.name %} | {% trans "Ubuntu LoCo Team Directory" %} {% endblock %}
References