fix(base): Use correct url for back button

.#227 #240
This commit is contained in:
2024-08-15 22:08:05 +09:30
parent 300fe283d6
commit 68c3b64424
2 changed files with 4 additions and 1 deletions

View File

@ -160,3 +160,6 @@ class DetailForm(ServiceForm):
self.tabs['details'].update({
"edit_url": reverse('ITIM:_service_change', args=(self.instance.pk,))
})
self.url_index_view = reverse('ITAM:Services')

View File

@ -4,7 +4,7 @@
<div class="content-navigation-tabs">
<button onclick="window.location='{% url 'ITIM:Services' %}';" style="vertical-align: middle; padding: auto; margin: 0px">
<button onclick="window.location='{{ form.url_index_view }}';" style="vertical-align: middle; padding: auto; margin: 0px">
<svg xmlns="http://www.w3.org/2000/svg" height="25px" viewBox="0 -960 960 960" width="25px"
style="vertical-align: middle; margin: 0px; padding: 0px border: none; " fill="#6a6e73">
<path d="m313-480 155 156q11 11 11.5 27.5T468-268q-11 11-28 11t-28-11L228-452q-6-6-8.5-13t-2.5-15q0-8 2.5-15t8.5-13l184-184q11-11 27.5-11.5T468-692q11 11 11 28t-11 28L313-480Zm264 0 155 156q11 11 11.5 27.5T732-268q-11 11-28 11t-28-11L492-452q-6-6-8.5-13t-2.5-15q0-8 2.5-15t8.5-13l184-184q11-11 27.5-11.5T732-692q11 11 11 28t-11 28L577-480Z" />