Project

General

Profile

Actions

Defect #12833

closed

Input fields restricted on length should have maxlength parameter set

Added by Harald Glock almost 12 years ago. Updated almost 12 years ago.

Status:
Closed
Priority:
Normal
Assignee:
-
Category:
UI
Target version:
Start date:
Due date:
% Done:

0%

Estimated time:
Resolution:
Fixed
Affected version:

Description

When entering the subject of a ticket/issue or writing a comment in the timelog, you can enter as many characters in the input field as you want. But if you entered more then 255 characters, this will give an error later when sending it to the redmine instance ("... too long (maximum 255 characters)").

It would be better if the HTML input field already has the maxlength parameter set to 255 then. Having this parameter set, you cannot enter more than maxlength characters into the input field. Thus, the user would immediately recognize that he cannot enter more characters instead of getting an error later when he already typed the too long input.

I just checked for the 2 mentioned input fields, there are probably a lot more of them.


Files

setMaximumLenght.diff (1.33 KB) setMaximumLenght.diff Fixes maximum lenght for issues subject and timelog comment Daniel Felix, 2013-01-13 19:47
Actions #1

Updated by Daniel Felix almost 12 years ago

Hi,

I've attached a small patch which corrects this for timelog comments and issue subjects.

Best regards,
Daniel

Actions #2

Updated by Harald Glock almost 12 years ago

Thanks Daniel.

Applied the patch with small change to redmine-2.1.4 (line no in app/views/timelog/_form.html.erb has changed since 2.1.4) and it works as expected.

Hope it will make it into redmine.

Actions #3

Updated by Toshi MARUYAMA almost 12 years ago

  • Category set to UI
Actions #4

Updated by Daniel Felix almost 12 years ago

  • Status changed from New to Resolved
  • Target version set to Candidate for next minor release
  • Resolution set to Fixed
Actions #5

Updated by Daniel Felix almost 12 years ago

  • Target version changed from Candidate for next minor release to 2.2.2
Actions #6

Updated by Jean-Philippe Lang almost 12 years ago

  • Status changed from Resolved to Closed

Committed.

Actions

Also available in: Atom PDF