Git Product home page Git Product logo

extjs-currencyfield's Introduction

CurrencyField for ExtJS

ExtJS component which extends Ext.form.field.number to have more options when dealing with currency entry. Such as right aligned and always defaulting to two decimal places.

Adding package to workspace or app

Download currencyField.pkg from releases

copy: .pkg file to workspace of your project

run: sencha package add currencyField.pkg

add 'currencyField' to your app.json

   "requires": [
      "font-awesome",
      "currencyField"
   ],

If upgrading from an earlier release run this command first run sencha app refresh -packages

or start using this package by running run: sencha app refresh

Usage

Add namespaces to Ext.Application requires array.

requires: [
    'Ext.common.currency.*'
  ],
Currency number field
Ext.common.currency.Field

Use the xtype currencyfield or if in Sencha Architect use createAlias currencyfield on a 'Ext.form.field.Number' to overide.

Currency display field
Ext.common.currency.Display

Use the xtype currencydisplay or if in Sencha Architect use createAlias currencydisplay on a 'Ext.form.field.Display' to overide.

Note

I'm aware that the current namespace for this component is less than informative and will be adjusting the package accordingly in time. This package was created due to a bug in Sencha Architect

Licences

  • Code for ExtJS package release under MIT

About

This package was created as I needed a component which fixed precision and was able to use validate that an entry was correct. i.e. the value entered could be broken down into the amount specified. i.e. where

  ...
  amount:50,
  isDenomination: true,
  

This then runs the validation to check the amount entered can be broken down into that denomination.

See /Src/CurrencyField.js for the full class.

ExtJS Package built by Richard Styles.

extjs-currencyfield's People

Contributors

richardstyles avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.