<a href="#" class="component_icon button icon_next" onclick="f=document.getElementById('_messageForm'); f.submit(); return false;">{% trans "Send" %}</a>
</form>
</div>
-<script type="text/javascript">document.getElementById("id_body").focus();</script>
+<script type="text/javascript">document.getElementById("id_subject").focus();</script>
{% endblock %}
\ No newline at end of file
{% if user.is_authenticated %}
<div class="module_action">
- <a href="{% url postman_write user.username %}" class="component_icon button" id="action_red">{% trans "Send a message" %}</a>
+ <a href="{% url postman_write usr.username %}" class="component_icon button" id="action_red">{% trans "Send a message" %}</a>
</div>
{% endif %}
</div>
<dt>{% trans "Username" %}</dt><dd>{{ usr.username }}</dd>
{% if usr.student.get %}
- <dt>{% trans "IEJ" %}</dt><dd>{{ usr.student.get.iej }}</dd>
- <dt>{% trans "Training" %}</dt><dd>{{ usr.student.get.training }}</dd>
+ <dt>{% trans "IEJ" %}</dt><dd><a href="{% url teleforma-iej-users usr.student.get.iej.id %}">{{ usr.student.get.iej }}</a></dd>
+ <dt>{% trans "Training" %}</dt><dd><a href="{% url teleforma-training-users usr.student.get.training.id %}">{{ usr.student.get.training }}</a></dd>
<dt>{% trans "Procedure"%}</dt><dd>{{ usr.student.get.procedure.code }}</dd>
<dt>{% trans "Oral spe"%}</dt><dd>{{ usr.student.get.oral_speciality.code }}</dd>
<dt>{% trans "Written spe"%}</dt><dd>{{ usr.student.get.written_speciality.code }}</dd>
def get_context_data(self, **kwargs):
context = super(UsersTrainingView, self).get_context_data(**kwargs)
context['training'] = Training.objects.get(id=self.args[0])
- context['all_users'] = User.objects.filter(student__training__in=self.training).all()
+ context['all_users'] = self.object_list.all()
return context
@method_decorator(login_required)
def get_context_data(self, **kwargs):
context = super(UsersIejView, self).get_context_data(**kwargs)
context['iej'] = IEJ.objects.get(id=self.args[0])
- context['all_users'] = User.objects.filter(student__iej__in=self.iej).all()
+ context['all_users'] = self.object_list.all()
return context
@method_decorator(login_required)
def get_context_data(self, **kwargs):
context = super(UsersCourseView, self).get_context_data(**kwargs)
context['course'] = Course.objects.get(id=self.args[0])
- context['all_users'] = User.objects.filter(student__training__courses__in=self.course).all()
+ context['all_users'] = self.object_list.all()
return context
@method_decorator(login_required)