mirror of
https://gitea.mueller.network/extern/django-helpdesk.git
synced 2024-11-22 16:03:19 +01:00
add option to override default look of followups - this is work in progress.
This commit is contained in:
parent
2cee519d1c
commit
f897d5bcb4
@ -52,6 +52,10 @@ HELPDESK_TRANSLATE_TICKET_COMMENTS = getattr(settings, 'HELPDESK_TRANSLATE_TICKE
|
|||||||
# list of languages to offer. if set to false, all default google translate languages will be shown.
|
# list of languages to offer. if set to false, all default google translate languages will be shown.
|
||||||
HELPDESK_TRANSLATE_TICKET_COMMENTS_LANG = getattr(settings, 'HELPDESK_TRANSLATE_TICKET_COMMENTS_LANG', ["en", "de", "fr", "ru"])
|
HELPDESK_TRANSLATE_TICKET_COMMENTS_LANG = getattr(settings, 'HELPDESK_TRANSLATE_TICKET_COMMENTS_LANG', ["en", "de", "fr", "ru"])
|
||||||
|
|
||||||
|
# allow user to override default layout for 'followups' - work in progress.
|
||||||
|
HELPDESK_FOLLOWUP_MOD = getattr(settings, 'HELPDESK_FOLLOWUP_MOD', False)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
''' options for public pages '''
|
''' options for public pages '''
|
||||||
# show 'view a ticket' section on public page?
|
# show 'view a ticket' section on public page?
|
||||||
|
@ -153,22 +153,34 @@ td {
|
|||||||
background-color: #bcd4ec;
|
background-color: #bcd4ec;
|
||||||
}
|
}
|
||||||
|
|
||||||
div.followup {
|
div.followup, div.followup_mod {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
border-top: solid #666 1px;
|
border-top: solid #666 1px;
|
||||||
padding:0 0 2px;
|
padding:0 0 2px;
|
||||||
}
|
}
|
||||||
|
|
||||||
div.followup .title {
|
div.followup_mod {
|
||||||
|
border: solid #666 1px;
|
||||||
|
padding: 5px;
|
||||||
|
margin: 0px 0px 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
div.followup .title, div.followup_mod .title {
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
font-size: 10pt;
|
font-size: 10pt;
|
||||||
}
|
}
|
||||||
|
|
||||||
div.followup .title span {
|
div.followup .title span, div.followup_mod .title span {
|
||||||
color: #aaa;
|
color: #aaa;
|
||||||
font-weight: normal;
|
font-weight: normal;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
div.followup_mod small {
|
||||||
|
float: right;
|
||||||
|
font-weight: bold;
|
||||||
|
font-style: italic;
|
||||||
|
}
|
||||||
|
|
||||||
span.private {
|
span.private {
|
||||||
color: #aaa;
|
color: #aaa;
|
||||||
font-style: italic;
|
font-style: italic;
|
||||||
|
@ -52,15 +52,28 @@
|
|||||||
<h3>{% trans "Follow-Ups" %}</h3>
|
<h3>{% trans "Follow-Ups" %}</h3>
|
||||||
{% load ticket_to_link %}
|
{% load ticket_to_link %}
|
||||||
{% for followup in ticket.followup_set.all %}
|
{% for followup in ticket.followup_set.all %}
|
||||||
<div class='followup'>
|
{% if helpdesk_settings.HELPDESK_FOLLOWUP_MOD %}
|
||||||
<div class='title'>
|
<div class='followup_mod'>
|
||||||
{{ followup.title }} <span class='byline'>{% if followup.user %}by {{ followup.user }}{% endif %} <span title='{{ followup.date|date:"r" }}'>{{ followup.date|timesince }} ago</span>{% if not followup.public %} <span class='private'>({% trans "Private" %})</span>{% endif %}</span>
|
<div class='title'>
|
||||||
{% if helpdesk_settings.HELPDESK_SHOW_EDIT_BUTTON_FOLLOW_UP %}
|
<span class='byline'>{{ followup.user.get_full_name }} {{ followup.date }} ({{ followup.date|timesince }} ago)</span> <small>{{ followup.title }}</small>
|
||||||
{% if followup.user and request.user == followup.user and not followup.ticketchange_set.all %}
|
{% if not followup.public %} <span class='private'>({% trans "Private" %})</span>{% endif %}
|
||||||
<a href="{% url helpdesk_followup_edit ticket.id followup.id %}" class='followup-edit'><img width="60" height="15" title="Edit" alt="Edit" src="{{ STATIC_URL }}helpdesk/buttons/edit.png"></a>
|
{% if helpdesk_settings.HELPDESK_SHOW_EDIT_BUTTON_FOLLOW_UP %}
|
||||||
{% endif %}
|
{% if followup.user and request.user == followup.user and not followup.ticketchange_set.all %}
|
||||||
{% endif %}
|
<a href="{% url helpdesk_followup_edit ticket.id followup.id %}" class='followup-edit'><img width="60" height="15" title="Edit" alt="Edit" src="{{ STATIC_URL }}helpdesk/buttons/edit.png"></a>
|
||||||
</div>
|
{% endif %}
|
||||||
|
{% endif %}
|
||||||
|
</div>
|
||||||
|
{% else %}
|
||||||
|
<div class='followup'>
|
||||||
|
<div class='title'>
|
||||||
|
{{ followup.title }} <span class='byline'>{% if followup.user %}by {{ followup.user }}{% endif %} <span title='{{ followup.date|date:"r" }}'>{{ followup.date|timesince }} ago</span>{% if not followup.public %} <span class='private'>({% trans "Private" %})</span>{% endif %}</span>
|
||||||
|
{% if helpdesk_settings.HELPDESK_SHOW_EDIT_BUTTON_FOLLOW_UP %}
|
||||||
|
{% if followup.user and request.user == followup.user and not followup.ticketchange_set.all %}
|
||||||
|
<a href="{% url helpdesk_followup_edit ticket.id followup.id %}" class='followup-edit'><img width="60" height="15" title="Edit" alt="Edit" src="{{ STATIC_URL }}helpdesk/buttons/edit.png"></a>
|
||||||
|
{% endif %}
|
||||||
|
{% endif %}
|
||||||
|
</div>
|
||||||
|
{% endif %}
|
||||||
<span class='followup-desc'>{% if followup.comment %}{{ followup.comment|force_escape|urlizetrunc:50|num_to_link|linebreaksbr }}{% endif %}</span>
|
<span class='followup-desc'>{% if followup.comment %}{{ followup.comment|force_escape|urlizetrunc:50|num_to_link|linebreaksbr }}{% endif %}</span>
|
||||||
{% for change in followup.ticketchange_set.all %}
|
{% for change in followup.ticketchange_set.all %}
|
||||||
{% if forloop.first %}<div class='changes'><ul>{% endif %}
|
{% if forloop.first %}<div class='changes'><ul>{% endif %}
|
||||||
|
Loading…
Reference in New Issue
Block a user