Skip to content
Extraits de code Groupes Projets
Valider 0bbbf0ee rédigé par Stefan Giehl's avatar Stefan Giehl Validation de Matthieu Aubry
Parcourir les fichiers

Add maxlength attributes to various input boxes (#10829)

* add maxlength attributes to goal input boxes

values are limited to that length by database restrictions

* limit site name input box to database limit

* limit user input boxes to database limits
parent e4d8bb44
Aucune branche associée trouvée
Aucune étiquette associée trouvée
Aucune requête de fusion associée trouvée
...@@ -10,11 +10,13 @@ ...@@ -10,11 +10,13 @@
<div piwik-form> <div piwik-form>
<div piwik-field uicontrol="text" name="goal_name" <div piwik-field uicontrol="text" name="goal_name"
ng-model="manageGoals.goal.name" ng-model="manageGoals.goal.name"
maxlength="50"
title="{{ 'Goals_GoalName'|translate|e('html_attr') }}"> title="{{ 'Goals_GoalName'|translate|e('html_attr') }}">
</div> </div>
<div piwik-field uicontrol="text" name="goal_description" <div piwik-field uicontrol="text" name="goal_description"
ng-model="manageGoals.goal.description" ng-model="manageGoals.goal.description"
maxlength="255"
title="{{ 'General_Description'|translate|e('html_attr') }}"> title="{{ 'General_Description'|translate|e('html_attr') }}">
</div> </div>
...@@ -85,6 +87,7 @@ ...@@ -85,6 +87,7 @@
<div class="col s12 m6 l4"> <div class="col s12 m6 l4">
<div piwik-field uicontrol="text" name="pattern" <div piwik-field uicontrol="text" name="pattern"
ng-model="manageGoals.goal.pattern" ng-model="manageGoals.goal.pattern"
maxlength="255"
title="{{ 'Goals_Pattern'|translate|e('html_attr') }}" title="{{ 'Goals_Pattern'|translate|e('html_attr') }}"
full-width="true"> full-width="true">
</div> </div>
......
...@@ -71,7 +71,7 @@ ...@@ -71,7 +71,7 @@
<div class="form-group row"> <div class="form-group row">
<div class="col s12 m6 input-field"> <div class="col s12 m6 input-field">
<input type="text" ng-model="site.name"/> <input type="text" ng-model="site.name" maxlength="90" />
<label>{{ 'General_Name'|translate }}</label> <label>{{ 'General_Name'|translate }}</label>
</div> </div>
<div class="col s12 m6"></div> <div class="col s12 m6"></div>
......
...@@ -144,10 +144,10 @@ ...@@ -144,10 +144,10 @@
newRowId = 'row' + newRowId; newRowId = 'row' + newRowId;
$($.parseHTML(' <tr id="' + newRowId + '" class="addNewUserRow">\ $($.parseHTML(' <tr id="' + newRowId + '" class="addNewUserRow">\
<td><input id="useradd_login" placeholder="username" size="10" /></td>\ <td><input id="useradd_login" placeholder="username" size="10" maxlength="100" /></td>\
<td><input id="useradd_password" placeholder="password" size="10" /></td>\ <td><input id="useradd_password" placeholder="password" size="10" /></td>\
<td><input id="useradd_email" placeholder="email@domain.com" size="15" /></td>\ <td><input id="useradd_email" placeholder="email@domain.com" size="15" maxlength="100" /></td>\
<td><input id="useradd_alias" placeholder="alias" size="15" /></td>\ <td><input id="useradd_alias" placeholder="alias" size="15" maxlength="45" /></td>\
<td>-</td>\ <td>-</td>\
<td>-</td>\ <td>-</td>\
<td><input type="submit" class="btn adduser" value="' + _pk_translate('General_Save') + '" /></td>\ <td><input type="submit" class="btn adduser" value="' + _pk_translate('General_Save') + '" /></td>\
......
...@@ -22,12 +22,14 @@ ...@@ -22,12 +22,14 @@
<div piwik-field uicontrol="text" name="alias" <div piwik-field uicontrol="text" name="alias"
ng-model="personalSettings.alias" ng-model="personalSettings.alias"
maxlength="45"
title="{{ 'UsersManager_Alias'|translate|e('html_attr') }}" title="{{ 'UsersManager_Alias'|translate|e('html_attr') }}"
value="{{ userAlias|raw }}"> value="{{ userAlias|raw }}">
</div> </div>
<div piwik-field uicontrol="text" name="email" <div piwik-field uicontrol="text" name="email"
ng-model="personalSettings.email" ng-model="personalSettings.email"
maxlength="100"
title="{{ 'UsersManager_Email'|translate|e('html_attr') }}" title="{{ 'UsersManager_Email'|translate|e('html_attr') }}"
value="{{ userEmail }}"> value="{{ userEmail }}">
</div> </div>
......
0% Chargement en cours ou .
You are about to add 0 people to the discussion. Proceed with caution.
Terminez d'abord l'édition de ce message.
Veuillez vous inscrire ou vous pour commenter