Project

General

Profile

Actions

Defect #16169

closed

Wrong validation when updating integer custom field with spaces

Added by Vincent Robert almost 11 years ago. Updated almost 11 years ago.

Status:
Closed
Priority:
Normal
Category:
Custom fields
Target version:
Start date:
Due date:
% Done:

0%

Estimated time:
Resolution:
Fixed
Affected version:

Description

Our project custom field is an integer. When we update its value, we get an error message if we enter letters (that's fine) but we can enter and save spaces.
A string composed of spaces should not be authorized.

When the custom_value table contains wrong spaces values, it breaks some requests on custom fields because the current requests cast the values to decimals (like in the sql_for_field method in the query class).

Environment:
Redmine version 2.5.0.devel.12927
Ruby version 1.9.3-p484 (2013-11-22) [x86_64-darwin13.0.0]
Rails version 3.2.17
Database adapter PostgreSQL 9.3

Actions #1

Updated by Jean-Philippe Lang almost 11 years ago

  • Status changed from New to Resolved
  • Assignee set to Jean-Philippe Lang
  • Target version set to 2.4.4
  • Resolution set to Fixed

Fixed in r12938, thanks for pointing this out.

Actions #2

Updated by Jean-Philippe Lang almost 11 years ago

  • Status changed from Resolved to Closed
Actions

Also available in: Atom PDF