Gelmiş geçmiş en büyük porno sitemiz olan 2pe de her zaman en kaliteli pornoları sunmayı hedefledik. Diğer video sitemiz olan vuam da ise hd porno ağırlıklı çalışmalara başladık.

  1. #1
    Sencha Premium Member
    Join Date
    Jan 2012
    Posts
    54
    Vote Rating
    2
    cswsteve is on a distinguished road

      0  

    Default Force 2 decimals to show in a Number Field?

    Force 2 decimals to show in a Number Field?


    Is there an easy way to force 2 decimal places to always show in a Number Field or any other component in Architect? If I set the decimalPrecision to 2 it does not display 2 decimals for numbers like 0 or 1.5. I want all numbers to always show 2 decimals and display as 0.00 and 1.50.

    I have looked at these 2 forum posts but they do not work very well in Sencha Architect.
    http://www.sencha.com/forum/showthread.php?147962
    http://www.mysamplecode.com/2011/12/...ion-using.html


    To give you more details, I am creating a simple order and customer history form and have several numeric fields that need to display as a currency amount. Right now it looks odd to see the numbers with various decimal place lengths.

    Here is an example of how it currently looks setting the Number Field's decimalPrecision to 2.

    Order Total: 153.1
    Shipping: 25
    Sales Tax: 12.7
    Subtotal: 190.8

    However, what I need is this.

    Order Total: 153.10
    Shipping: 25.00
    Sales Tax: 12.70
    Subtotal: 190.80

    It seems so simple and standard that I cannot believe this feature does not exist in Architect. Am I missing something in the Config?

    Thanks!

  2. #2
    Sencha Premium Member
    Join Date
    Jun 2013
    Posts
    66
    Vote Rating
    0
    LandryAssocies is on a distinguished road

      0  

    Default


    I also need that !

  3. #3
    Ext JS Premium Member tangix's Avatar
    Join Date
    Mar 2010
    Location
    Stockholm, Sweden
    Posts
    539
    Vote Rating
    50
    tangix is a jewel in the rough tangix is a jewel in the rough tangix is a jewel in the rough

      0  

    Default


    Quick and dirty would be to add the NumberField to the project and just take the UX code and add as an override (in this example, you need to change the references to Ext.ux.form.NumericField in the code).
    This does not solve the 2 decimal problem, but fixes the currency symbol things at least.

Thread Participants: 2