SilverCart\Forms\FormFields\MoneyField
A formfield for editing Money values.
- Author: Sebastian Diel <sdiel@pixeltricks.de>
- Copyright: 2017 pixeltricks GmbH
- License: see license file in modules root directory
Synopsis
class MoneyField
extends MoneyField
{
- // members
- protected bool $currencyIsReadonly = true;
- // methods
- protected FormField buildCurrencyField()
- public string Field()
- public void setValue()
- public string id()
- public string prepareAmount()
- public bool getCurrencyIsReadonly()
- public MoneyField setCurrencyIsReadonly()
- public string CurrencySymbol()
Hierarchy
Extends
- SilverStripe\Forms\MoneyField
Members
protected
- $currencyIsReadonly
—
SilverCart\Forms\FormFields\bool
Determines whether the currency is a readonly property.
Methods
protected
- buildCurrencyField() — Builds a new currency field based on the allowed currencies configured.
public
- CurrencySymbol() — Returns the currency symbol.
- Field() — Returns the field markup
- getCurrencyIsReadonly() — Returns whether the currency is a readonly property.
- id() — Returns the fields id (html)
- prepareAmount() — Prepares the given amount to save in db.
- setCurrencyIsReadonly() — Sets whether the currency is a readonly property.
- setValue() — Set the Money value