@@ -129,7 +129,7 @@ discard block |
||
129 | 129 | 'create' => [ |
130 | 130 | 'link' => 'javascript:;', |
131 | 131 | 'title' => __('admin_create_new_entry'), |
132 | - 'onclick' => 'event.preventDefault(); selectEntryType("'.$this->getEntryID($query).'", 0);' |
|
132 | + 'onclick' => 'event.preventDefault(); selectEntryType("' . $this->getEntryID($query) . '", 0);' |
|
133 | 133 | ] |
134 | 134 | ] |
135 | 135 | ] |
@@ -156,7 +156,7 @@ discard block |
||
156 | 156 | $parts = [0 => '']; |
157 | 157 | } |
158 | 158 | |
159 | - $type = isset($query['type']) ? $query['type']: ''; |
|
159 | + $type = isset($query['type']) ? $query['type'] : ''; |
|
160 | 160 | |
161 | 161 | return flextype('twig')->render( |
162 | 162 | $response, |
@@ -257,7 +257,7 @@ discard block |
||
257 | 257 | if (flextype('registry')->has('plugins.site')) { |
258 | 258 | $template_path = PATH['project'] . '/themes/' . flextype('registry')->get('plugins.site.settings.theme') . '/templates/' . $data['fieldset'] . '.html'; |
259 | 259 | $template = (Filesystem::has($template_path)) ? $data['fieldset'] : 'default'; |
260 | - $data_from_post['template'] = $template; |
|
260 | + $data_from_post['template'] = $template; |
|
261 | 261 | } |
262 | 262 | |
263 | 263 | //foreach ($fieldset['sections'] as $section_name => $section_body) { |
@@ -737,7 +737,7 @@ discard block |
||
737 | 737 | |
738 | 738 | ], |
739 | 739 | 'edit_entry' => [ |
740 | - 'link' => flextype('router')->pathFor('admin.entries.edit') . '?id=' . $this->getEntryID($query). '&type=editor', |
|
740 | + 'link' => flextype('router')->pathFor('admin.entries.edit') . '?id=' . $this->getEntryID($query) . '&type=editor', |
|
741 | 741 | 'title' => __('admin_editor'), |
742 | 742 | |
743 | 743 | ], |
@@ -890,15 +890,15 @@ discard block |
||
890 | 890 | $data = $request->getParsedBody(); |
891 | 891 | |
892 | 892 | // Delete system fields |
893 | - isset($data['slug']) and Arrays::delete($data, 'slug'); |
|
894 | - isset($data['id']) and Arrays::delete($data, 'id'); |
|
895 | - isset($data['csrf_value']) and Arrays::delete($data, 'csrf_value'); |
|
896 | - isset($data['csrf_name']) and Arrays::delete($data, 'csrf_name'); |
|
897 | - isset($data['form-save-action']) and Arrays::delete($data, 'form-save-action'); |
|
898 | - isset($data['trumbowyg-icons-path']) and Arrays::delete($data, 'trumbowyg-icons-path'); |
|
899 | - isset($data['trumbowyg-locale']) and Arrays::delete($data, 'trumbowyg-locale'); |
|
893 | + isset($data['slug']) and Arrays::delete($data, 'slug'); |
|
894 | + isset($data['id']) and Arrays::delete($data, 'id'); |
|
895 | + isset($data['csrf_value']) and Arrays::delete($data, 'csrf_value'); |
|
896 | + isset($data['csrf_name']) and Arrays::delete($data, 'csrf_name'); |
|
897 | + isset($data['form-save-action']) and Arrays::delete($data, 'form-save-action'); |
|
898 | + isset($data['trumbowyg-icons-path']) and Arrays::delete($data, 'trumbowyg-icons-path'); |
|
899 | + isset($data['trumbowyg-locale']) and Arrays::delete($data, 'trumbowyg-locale'); |
|
900 | 900 | isset($data['flatpickr-date-format']) and Arrays::delete($data, 'flatpickr-date-format'); |
901 | - isset($data['flatpickr-locale']) and Arrays::delete($data, 'flatpickr-locale'); |
|
901 | + isset($data['flatpickr-locale']) and Arrays::delete($data, 'flatpickr-locale'); |
|
902 | 902 | |
903 | 903 | $data['published_by'] = flextype('session')->get('uuid'); |
904 | 904 | |
@@ -922,7 +922,7 @@ discard block |
||
922 | 922 | |
923 | 923 | if (isset($data['routable'])) { |
924 | 924 | $data['routable'] = (bool) $data['routable']; |
925 | - } elseif(isset($entry['routable'])) { |
|
925 | + } elseif (isset($entry['routable'])) { |
|
926 | 926 | $data['routable'] = (bool) $entry['routable']; |
927 | 927 | } else { |
928 | 928 | $data['routable'] = true; |
@@ -93,6 +93,6 @@ |
||
93 | 93 | flextype()->post('/api/access/delete', 'ApiAccessController:deleteProcess')->setName('admin.api_access.deleteProcess'); |
94 | 94 | |
95 | 95 | })->add(new AclIsUserLoggedInMiddleware(['redirect' => 'admin.accounts.login'])) |
96 | - ->add(new AclIsUserLoggedInRolesInMiddleware(['redirect' => (flextype('acl')->isUserLoggedIn() ? 'admin.accounts.no-access' : 'admin.accounts.login'), |
|
96 | + ->add(new AclIsUserLoggedInRolesInMiddleware(['redirect' => (flextype('acl')->isUserLoggedIn() ? 'admin.accounts.no-access' : 'admin.accounts.login'), |
|
97 | 97 | 'roles' => 'admin'])) |
98 | - ->add('csrf'); |
|
98 | + ->add('csrf'); |