Skip to content

Commit 2a7d2b3

Browse files
authored
Merge pull request #1808 from it-at-m/bugfix-zmskvr-1056-optional-textfield-in-admin
fix(ZMSKVR-1056): optional textfield in admin
2 parents 2287a1c + 8ca28cc commit 2a7d2b3

File tree

2 files changed

+14
-15
lines changed

2 files changed

+14
-15
lines changed

zmsadmin/templates/block/queue/table.twig

Lines changed: 11 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -159,13 +159,13 @@
159159
{#DL#}
160160
<td>Dieser Kunde ist geparkt</td>
161161
{% if workstation.scope.preferences.client.customTextfieldActivated|default(0) == 1 %}
162-
<td title="{{ item.customTextfield|decodeEntities }}">
162+
<td title="{{ item.customTextfield|decodeEntities }}" class="limited-width">
163163
{{ item.customTextfield|decodeEntities|slice(0, textfieldDisplayLength) }}
164164
{% if item.customTextfield|decodeEntities|length > textfieldDisplayLength %}...{% endif %}
165165
</td>
166166
{% endif %}
167167
{% if workstation.scope.preferences.client.customTextfield2Activated|default(0) == 1 %}
168-
<td title="{{ item.customTextfield2|decodeEntities }}">
168+
<td title="{{ item.customTextfield2|decodeEntities }}" class="limited-width">
169169
{{ item.customTextfield2|decodeEntities|slice(0, textfieldDisplayLength) }}
170170
{% if item.customTextfield2|decodeEntities|length > textfieldDisplayLength %}...{% endif %}
171171
</td>
@@ -422,13 +422,13 @@
422422
</p>
423423
</td>
424424
{% if workstation.scope.preferences.client.customTextfieldActivated|default(0) == 1 %}
425-
<td title="{{ item.customTextfield|decodeEntities }}">
425+
<td title="{{ item.customTextfield|decodeEntities }}" class="limited-width">
426426
{{ item.customTextfield|decodeEntities|slice(0, textfieldDisplayLength) }}
427427
{% if item.customTextfield|decodeEntities|length > textfieldDisplayLength %}...{% endif %}
428428
</td>
429429
{% endif %}
430430
{% if workstation.scope.preferences.client.customTextfield2Activated|default(0) == 1 %}
431-
<td title="{{ item.customTextfield2|decodeEntities }}">
431+
<td title="{{ item.customTextfield2|decodeEntities }}" class ="limited-width">
432432
{{ item.customTextfield2|decodeEntities|slice(0, textfieldDisplayLength) }}
433433
{% if item.customTextfield2|decodeEntities|length > textfieldDisplayLength %}...{% endif %}
434434
</td>
@@ -553,13 +553,13 @@
553553
{#DL#}
554554
<td>Dieser Kunde ist nicht erschienen</td>
555555
{% if workstation.scope.preferences.client.customTextfieldActivated|default(0) == 1 %}
556-
<td title="{{ item.customTextfield|decodeEntities }}">
556+
<td title="{{ item.customTextfield|decodeEntities }}" class="limited-width">
557557
{{ item.customTextfield|decodeEntities|slice(0, textfieldDisplayLength) }}
558558
{% if item.customTextfield|decodeEntities|length > textfieldDisplayLength %}...{% endif %}
559559
</td>
560560
{% endif %}
561561
{% if workstation.scope.preferences.client.customTextfield2Activated|default(0) == 1 %}
562-
<td title="{{ item.customTextfield2|decodeEntities }}">
562+
<td title="{{ item.customTextfield2|decodeEntities }}" class="limited-width">
563563
{{ item.customTextfield2|decodeEntities|slice(0, textfieldDisplayLength) }}
564564
{% if item.customTextfield2|decodeEntities|length > textfieldDisplayLength %}...{% endif %}
565565
</td>
@@ -719,4 +719,9 @@ content.addClass('hidden')
719719
cursor: not-allowed;
720720
pointer-events: none;
721721
}
722+
.limited-width {
723+
overflow-wrap: break-word;
724+
hyphens: auto;
725+
max-width: 300px;
726+
}
722727
</style>

zmsdb/src/Zmsdb/Query/Process.php

Lines changed: 3 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -875,15 +875,9 @@ protected function addValuesClientData($process)
875875
if ($client && $client->offsetExists('notificationsSendCount')) {
876876
$data['SMSverschickt'] = ('-1' == $client->notificationsSendCount) ? 0 : $client->notificationsSendCount;
877877
}
878-
if ($process->getAmendment()) {
879-
$data['Anmerkung'] = $process->getAmendment();
880-
}
881-
if ($process->getCustomTextfield()) {
882-
$data['custom_text_field'] = $process->getCustomTextfield();
883-
}
884-
if ($process->getCustomTextfield2()) {
885-
$data['custom_text_field2'] = $process->getCustomTextfield2();
886-
}
878+
$data['Anmerkung'] = $process->getAmendment();
879+
$data['custom_text_field'] = $process->getCustomTextfield();
880+
$data['custom_text_field2'] = $process->getCustomTextfield2();
887881
$data['zustimmung_kundenbefragung'] = ($client->surveyAccepted) ? 1 : 0;
888882
$data['Erinnerungszeitpunkt'] = $process->getReminderTimestamp();
889883
$data['AnzahlPersonen'] = $process->getClients()->count();

0 commit comments

Comments
 (0)