hi,
in the accounts module we added an integer field.
but when entering a negative number we get the error message "Invalid Value"!?
what do we need to do to allow negative numbers?
hope someone can help.
thanks.
hi,
in the accounts module we added an integer field.
but when entering a negative number we get the error message "Invalid Value"!?
what do we need to do to allow negative numbers?
hope someone can help.
thanks.
Hi,
I had the same and it took me some time but here's the answer:
Got to include/javascript/sugar_3.js
on line 363 replace:
function isFloat(floatStr) {
if(floatStr.length== 0) {
return true;
}
floatStr = unformatNumber(floatStr, num_grp_sep, dec_sep).toString();
if(!/^[0-9\.]+$/.test(floatStr))
return false
return true
}
with
function isFloat(floatStr) {
if(floatStr.length== 0) {
return true;
}
floatStr = unformatNumber(floatStr, num_grp_sep, dec_sep).toString();
if(!/^[-0-9\.]+$/.test(floatStr))
return false
return true
}
Basically Ijust added a "-" before "0-9" and that's it!
Hope this will help someone,
Cheers
Alan
Alexandre Schaeffer
Business Development
enalog business solutions GmbH
Mahlerstraße 7/22, A-1010 Wien
www.scanpoint.at, www.enalog.com
mailto: aschaeffer@enalog.com
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks