Text format

Text format

Postby Fike » Sat Mar 01, 2014 3:46 am

First of all, great work with nuBuilder Pro! It's simply awesome!

I am creating a new application with it but I had a problem when choosing the format '10,000.00' for a text field. When I entered a numbre it was changin the value to 'NaN' instead of formatting it.

I replaced the line 220 of nuformat.js file from:

Code: Select all
return Number(formattedNumber).toFixed(nuFormats[f].format);


to:

Code: Select all
return formattedNumber


Now it is working fine for this specific text format. However, I don't know whether this could affect some other text formats. If I notice something is going wrong with other text formats, I will report it here.

KInd regrads,

Fike
Fike
 
Posts: 79
Joined: Fri Oct 21, 2011 4:43 am

Re: Text format

Postby doubleoh0 » Sat Mar 01, 2014 6:47 am

This is a good question that leads to another I wanted to ask, and that is if there is an ability to add custom format such as money or phone numbers
doubleoh0
 
Posts: 5
Joined: Wed Feb 26, 2014 2:17 am

Re: Text format

Postby admin » Tue Mar 04, 2014 11:48 am

Thanks Fike. I have put your fix on github.

doubleoh0 you can do custom formatting with Javascript on the Events Tab of an Object..

Capture4.PNG
Capture4.PNG (24.5 KiB) Viewed 3519 times


Steven
admin
Site Admin
 
Posts: 3225
Joined: Mon Jun 15, 2009 9:53 am

Re: Text format

Postby Fike » Tue Mar 04, 2014 2:12 pm

I am glad I could help.

Kind regards,

Fike
Fike
 
Posts: 79
Joined: Fri Oct 21, 2011 4:43 am

Re: Text format

Postby admin » Tue Mar 04, 2014 2:20 pm

Fike,

Actually I found a problem with it but its all good now I think.

Thanks

Steven
admin
Site Admin
 
Posts: 3225
Joined: Mon Jun 15, 2009 9:53 am


Return to General



cron