diff --git a/core/lib/Thelia/Form/ConfigCreationForm.php b/core/lib/Thelia/Form/ConfigCreationForm.php index 5594830bc..fc65d3d44 100644 --- a/core/lib/Thelia/Form/ConfigCreationForm.php +++ b/core/lib/Thelia/Form/ConfigCreationForm.php @@ -40,11 +40,19 @@ class ConfigCreationForm extends BaseForm $this->formBuilder ->add("name", "text", array( - "constraints" => $name_constraints + "constraints" => $name_constraints, + "label" => "Name *", + "label_attr" => array( + "for" => "name" + ) )) ->add("title", "text", array( "constraints" => array( new Constraints\NotBlank() + ), + "label" => "Purpose *", + "label_attr" => array( + "for" => "purpose" ) )) ->add("locale", "hidden", array( @@ -52,7 +60,12 @@ class ConfigCreationForm extends BaseForm new Constraints\NotBlank() ) )) - ->add("value", "text", array()) + ->add("value", "text", array( + "label" => "Value *", + "label_attr" => array( + "for" => "value" + ) + )) ->add("hidden", "hidden", array()) ->add("secured", "hidden", array()) ; diff --git a/templates/admin/default/variables.html b/templates/admin/default/variables.html index bbab0ae72..6373618f9 100644 --- a/templates/admin/default/variables.html +++ b/templates/admin/default/variables.html @@ -22,99 +22,105 @@
- - - - + + + - + - {module_include location='variables_table_header'} + - - + {module_include location='variables_table_header'} - {loop name="config" type="config" hidden="0" secured="*" backend_context="1" lang="$lang_id" order="$order"} - + + + + + {loop name="config" type="config" hidden="0" secured="*" backend_context="1" lang="$lang_id" order="$order"} + - + - + - + - {module_include location='variables_table_row'} + {module_include location='variables_table_row'} - - - {/loop} + {loop type="auth" name="can_delete" roles="ADMIN" permissions="admin.configuration.variables.delete"} + + {/loop} + + {else} + + {/if} + + + {/loop} +
+ {intl l='Thelia system variables'} {loop type="auth" name="can_create" roles="ADMIN" permissions="admin.configuration.variables.create"} - - - - +
+ + + + +
{/loop}
- {admin_sortable_header - current_order=$order - order='title' - reverse_order='title_reverse' - path={url path='/admin/configuration/variables'} - label={intl l='Purpose'} - } - - {admin_sortable_header - current_order=$order - order='name' - reverse_order='name_reverse' - path={url path='/admin/configuration/variables'} - label={intl l='Name'} - } -
+ {admin_sortable_header + current_order=$order + order='title' + reverse_order='title_reverse' + path={url path='/admin/configuration/variables'} + label={intl l='Purpose'} + } + - {admin_sortable_header - current_order=$order - order='value' - reverse_order='value_reverse' - path={url path='/admin/configuration/variables'} - label={intl l='Value'} - } - + {admin_sortable_header + current_order=$order + order='name' + reverse_order='name_reverse' + path={url path='/admin/configuration/variables'} + label={intl l='Name'} + } + + {admin_sortable_header + current_order=$order + order='value' + reverse_order='value_reverse' + path={url path='/admin/configuration/variables'} + label={intl l='Value'} + } +  
{intl l='Action'}
{$TITLE}{$TITLE} - {if ! $SECURED} - {loop type="auth" name="can_change" roles="ADMIN" permissions="admin.configuration.variables.change"} - {$NAME} - {/loop} - {elseloop rel="can_change"} - {$NAME} - {/elseloop} - {else} - {$NAME} - {/if} - + {if ! $SECURED} + {loop type="auth" name="can_change" roles="ADMIN" permissions="admin.configuration.variables.change"} + {$NAME} + {/loop} + {elseloop rel="can_change"} + {$NAME} + {/elseloop} + {else} + {$NAME} + {/if} + - {if $SECURED} - {$VALUE} - {else} - - {/if} - + {if $SECURED} + {$VALUE} + {else} + + {/if} + - {if ! $SECURED} -
- +
+ {if ! $SECURED} +
+ - {loop type="auth" name="can_change" roles="ADMIN" permissions="admin.configuration.variables.change"} - - {/loop} + {loop type="auth" name="can_change" roles="ADMIN" permissions="admin.configuration.variables.change"} + + {/loop} - {loop type="auth" name="can_delete" roles="ADMIN" permissions="admin.configuration.variables.delete"} - - {/loop} -
- {else} - - {/if} -
@@ -129,129 +135,115 @@ {* Adding a new variable *} -