|
50 | 50 |
|
51 | 51 | <td> |
52 | 52 | <div class="btn-group"> |
53 | | - <f:if condition="{redirect.is_regexp} || {redirect.source_host} === '*'"> |
| 53 | + <f:if condition="{canEditRedirects}"> |
54 | 54 | <f:then> |
55 | | - <span class="btn btn-default disabled"><core:icon identifier="empty-empty" /></span> |
| 55 | + <f:if condition="{redirect.is_regexp} || {redirect.source_host} === '*'"> |
| 56 | + <f:then> |
| 57 | + <span class="btn btn-default disabled"><core:icon identifier="empty-empty" /></span> |
| 58 | + </f:then> |
| 59 | + <f:else> |
| 60 | + <f:link.external class="btn btn-default" uri="{redirect.source_host}{redirect.source_path}" target="_blank" title="{f:translate(key: 'LLL:EXT:redirects/Resources/Private/Language/locallang_module_redirect.xlf:view_redirect')}"> |
| 61 | + <core:icon identifier="actions-view-page" /> |
| 62 | + </f:link.external> |
| 63 | + </f:else> |
| 64 | + </f:if> |
| 65 | + <f:if condition="{redirect.disabled} == 1"> |
| 66 | + <f:then> |
| 67 | + <a class="btn btn-default" href="{be:moduleLink(route:'tce_db', arguments:'{redirect: returnUrl}', query:'data[sys_redirect][{redirect.uid}][disabled]=0', currentUrlParameterName:'redirect')}" title="{f:translate(key:'LLL:EXT:core/Resources/Private/Language/locallang_mod_web_list.xlf:unHide')}"><core:icon identifier="actions-edit-unhide" /></a> |
| 68 | + </f:then> |
| 69 | + <f:else> |
| 70 | + <a class="btn btn-default" href="{be:moduleLink(route:'tce_db', arguments:'{redirect: returnUrl}', query:'data[sys_redirect][{redirect.uid}][disabled]=1', currentUrlParameterName:'redirect')}" title="{f:translate(key:'LLL:EXT:core/Resources/Private/Language/locallang_mod_web_list.xlf:hide')}"><core:icon identifier="actions-edit-hide" /></a> |
| 71 | + </f:else> |
| 72 | + </f:if> |
| 73 | + <be:link.editRecord returnUrl="{returnUrl}" class="btn btn-default" table="sys_redirect" uid="{redirect.uid}" title="{f:translate(key: 'LLL:EXT:core/Resources/Private/Language/locallang_mod_web_list.xlf:edit')}"> |
| 74 | + <core:icon identifier="actions-open" /> |
| 75 | + </be:link.editRecord> |
| 76 | + <a class="btn btn-default t3js-modal-trigger" |
| 77 | + href="{be:moduleLink(route:'tce_db', arguments:'{redirect: returnUrl}', query:'cmd[sys_redirect][{redirect.uid}][delete]=1', currentUrlParameterName:'redirect')}" |
| 78 | + title="{f:translate(key: 'LLL:EXT:core/Resources/Private/Language/locallang_mod_web_list.xlf:delete')}" |
| 79 | + data-severity="warning" |
| 80 | + data-title="{f:translate(key: 'LLL:EXT:backend/Resources/Private/Language/locallang_alt_doc.xlf:label.confirm.delete_record.title')}" |
| 81 | + data-bs-content="{f:translate(key: 'LLL:EXT:backend/Resources/Private/Language/locallang_alt_doc.xlf:deleteWarning')}" |
| 82 | + data-button-close-text="{f:translate(key: 'LLL:EXT:backend/Resources/Private/Language/locallang_alt_doc.xlf:buttons.confirm.delete_record.no')}"> |
| 83 | + <core:icon identifier="actions-delete" /> |
| 84 | + </a> |
56 | 85 | </f:then> |
57 | | - <f:else> |
58 | | - <f:link.external class="btn btn-default" uri="{redirect.source_host}{redirect.source_path}" target="_blank" title="{f:translate(key: 'LLL:EXT:redirects/Resources/Private/Language/locallang_module_redirect.xlf:view_redirect')}"> |
59 | | - <core:icon identifier="actions-view-page" /> |
60 | | - </f:link.external> |
61 | | - </f:else> |
62 | 86 | </f:if> |
63 | | - <f:if condition="{redirect.disabled} == 1"> |
64 | | - <f:then> |
65 | | - <a class="btn btn-default" href="{be:moduleLink(route:'tce_db', arguments:'{redirect: returnUrl}', query:'data[sys_redirect][{redirect.uid}][disabled]=0', currentUrlParameterName:'redirect')}" title="{f:translate(key:'LLL:EXT:core/Resources/Private/Language/locallang_mod_web_list.xlf:unHide')}"><core:icon identifier="actions-edit-unhide" /></a> |
66 | | - </f:then> |
67 | | - <f:else> |
68 | | - <a class="btn btn-default" href="{be:moduleLink(route:'tce_db', arguments:'{redirect: returnUrl}', query:'data[sys_redirect][{redirect.uid}][disabled]=1', currentUrlParameterName:'redirect')}" title="{f:translate(key:'LLL:EXT:core/Resources/Private/Language/locallang_mod_web_list.xlf:hide')}"><core:icon identifier="actions-edit-hide" /></a> |
69 | | - </f:else> |
70 | | - </f:if> |
71 | | - <be:link.editRecord returnUrl="{returnUrl}" class="btn btn-default" table="sys_redirect" uid="{redirect.uid}" title="{f:translate(key: 'LLL:EXT:core/Resources/Private/Language/locallang_mod_web_list.xlf:edit')}"> |
72 | | - <core:icon identifier="actions-open" /> |
73 | | - </be:link.editRecord> |
74 | | - <a class="btn btn-default t3js-modal-trigger" |
75 | | - href="{be:moduleLink(route:'tce_db', arguments:'{redirect: returnUrl}', query:'cmd[sys_redirect][{redirect.uid}][delete]=1', currentUrlParameterName:'redirect')}" |
76 | | - title="{f:translate(key: 'LLL:EXT:core/Resources/Private/Language/locallang_mod_web_list.xlf:delete')}" |
77 | | - data-severity="warning" |
78 | | - data-title="{f:translate(key: 'LLL:EXT:backend/Resources/Private/Language/locallang_alt_doc.xlf:label.confirm.delete_record.title')}" |
79 | | - data-bs-content="{f:translate(key: 'LLL:EXT:backend/Resources/Private/Language/locallang_alt_doc.xlf:deleteWarning')}" |
80 | | - data-button-close-text="{f:translate(key: 'LLL:EXT:backend/Resources/Private/Language/locallang_alt_doc.xlf:buttons.confirm.delete_record.no')}"> |
81 | | - <core:icon identifier="actions-delete" /> |
82 | | - </a> |
83 | 87 | </div> |
84 | 88 | </td> |
85 | 89 | </tr> |
|
92 | 96 | <f:else> |
93 | 97 | <f:be.infobox state="-1" title="{f:translate(key: 'LLL:EXT:redirects/Resources/Private/Language/locallang_module_redirect.xlf:redirect_not_found.title')}"> |
94 | 98 | <p><f:translate key="LLL:EXT:redirects/Resources/Private/Language/locallang_module_redirect.xlf:redirect_not_found.message"/></p> |
95 | | - <be:link.newRecord returnUrl="{returnUrl}" class="btn btn-primary" table="sys_redirect"> |
96 | | - <f:translate key="LLL:EXT:redirects/Resources/Private/Language/locallang_module_redirect.xlf:redirect_create"/> |
97 | | - </be:link.newRecord> |
| 99 | + <f:if condition="{canEditRedirects}"> |
| 100 | + <f:then> |
| 101 | + <be:link.newRecord returnUrl="{returnUrl}" class="btn btn-primary" table="sys_redirect"> |
| 102 | + <f:translate key="LLL:EXT:redirects/Resources/Private/Language/locallang_module_redirect.xlf:redirect_create"/> |
| 103 | + </be:link.newRecord> |
| 104 | + </f:then> |
| 105 | + </f:if> |
98 | 106 | </f:be.infobox> |
99 | 107 | </f:else> |
100 | 108 | </f:if> |
|
0 commit comments