"Maximum file size" displayed on upload forms is incorrect
I just discovered a small issue: Setting "Maximum attachment size" in the Administrator's panel to 25600 kB causes a "Maximum file size" to be shown as 30 MB.
Steps to reproduce:
- Log in as administrator and set "Maximum attachment size" to 25600 kB
- Change to a project
- Go to the file tab
- Select "New file"
- Observe "Maximum file size" being displayed as 30 MB
- Go back to a project
- Select "New issue"
- Observe "Maximum size" being displayed as 30 MB
- Debian Squeeze
- PostgreSQL 8.4.11-0squeeze1
- Ruby 220.127.116.112-2squeeze1
- Rails 3.2.3
- Redmine 2.0.1
#6 Updated by Etienne Massip over 7 years ago
- Status changed from Closed to Reopened
Jean-Philippe Lang wrote:
Etienne Massip wrote:
Please also have a look at.
You're right, reverted to KB in r9784. I personally dislike IEC prefixes.
Acttually I'm right about the inconsistency betweenthe prefix used in settings tkB for 1000 bytes) and the actual chech based on a
Numeric#kilobytes of 1024 bytes, but was wrong about the revert: KB is indeed not a legal prefix. So, maybe we should either set kB back again and change the check to use
number_human_format_size :prefix => :si or set the prefix in settings to 'KiB' which is arguabilly not very understandable yet?