Share and Money Management 0.18devel
|
Dialog to insert and change transactions. More...
Public Member Functions | |
def | __init__ (self, parent, kind="buy", share=None, position=None) |
Initialise dialog. More... | |
def | OnActivateExistingPosition (self, unused=None) |
Activate "Existing position". More... | |
def | OnActivateNewPosition (self, unused=None) |
Activate "New position". More... | |
def | OnActivateBuy (self, unused=None) |
Activate "Buy" radiobutton after a secondary widget has been focused. More... | |
def | OnActivateDividend (self, unused=None) |
Activate "Dividend" radiobutton after a secondary widget has been focused. More... | |
def | OnActivateSell (self, unused=None) |
Activate "Sell" radiobutton after a secondary widget has been focused. More... | |
def | OnActivateSplit (self, unused=None) |
Activate "Split" radiobutton after a secondary widget has been focused. More... | |
def | OnActivateSwap (self, unused=None) |
Activate "Swap" radiobutton after a secondary widget has been focused. More... | |
def | OnUpdateBuyValue (self, unused=None) |
Update buy value after changing buy sum. More... | |
def | OnUpdateBuySum (self, unused=None) |
Update buy sum after changing buy value or share count. More... | |
def | OnUpdateDividendValue (self, unused=None) |
Update dividend value after changing dividend sum. More... | |
def | OnUpdateDividendSum (self, unused=None) |
Update dividend sum after changing dividend value or count. More... | |
def | OnUpdateCurrency (self, unused=None) |
Update dialog after the currency has changed. More... | |
def | OnUpdateExistingPosition (self, unused=None) |
Update position related widgets. More... | |
def | OnUpdateNewPosition (self, unused=None) |
Update share related widgets. More... | |
def | configureDecimalWidget (self, widget, value=None) |
Set format of a decimal widget (monetary or non-monetary) More... | |
def | __init__ (self, *args, **kwds) |
Initialise dialog. More... | |
Public Member Functions inherited from gui.controls.BaseDialog | |
def | __init__ (self, *args, **kwargs) |
Initialise dialog. More... | |
def | installOwnOKEventHandler (self) |
Bind own event handler for pressing OK to allow a proper validation. More... | |
def | OnOK (self, event) |
Own OK button handler to validate the dialog logically using validateDialog() More... | |
def | ShowModal (self) |
Show the dialog modal and process dialogs input. More... | |
Private Member Functions | |
def | _getDecimal (self, widget) |
Return decimal value of any decimal or money widget. More... | |
def | _setDecimal (self, widget, value) |
Set value at a decimal widget (monetary and non-monetary) More... | |
def | _setCurrency (self, currency) |
Store the currency. More... | |
def | _updateCalcMode (self, mode) |
Set mode for calculation buy sum / sell sum. More... | |
def | _updateDateRangePosition (self) |
Update date ranges triggered by setting / selecting a position. More... | |
def | _updateDateRangeShare (self) |
Update date ranges triggered by setting / selecting a share. More... | |
def | _updateMoneyFormat (self, widget) |
Change widget mask to update the currency sign / code. More... | |
def | _validateInput (self) |
Validate input data and store results in results. More... | |
def | _prepareBuy (self) |
Prepare "Buy" transaction by storing all related values in results. More... | |
def | _prepareDividend (self) |
Prepare "Dividend" transaction by storing all related values in results. More... | |
def | _prepareSell (self) |
Prepare "Sell" transaction by storing all related values in results. More... | |
def | _prepareSplit (self) |
Prepare "Split" transaction by storing all related values in results. More... | |
def | _prepareSwap (self) |
Prepare "Swap" transaction by storing all related values in results. More... | |
def | _validateDateWidget (self, widget, first) |
Validate content of a DatePickerCtrl widget. More... | |
def | _validateDecimalWidget (self, widget, allowZero=False) |
Validate content of a decimal widget. More... | |
def | _processInput (self) |
Create a transaction using all data. More... | |
Private Attributes | |
_dateWidgets | |
List of all date widgets. More... | |
_decimalWidgets | |
List of all decimal widgets (monetary and non-monetary) More... | |
_moneyWidgets | |
List of all money widgets only (subset of _decimalWidgets) More... | |
_decimalPlaces | |
Number of decimal places for all decimal widgets (monetary and non-monetary) More... | |
Additional Inherited Members | |
Static Public Attributes inherited from gui.UITrade.UITrade | |
flags_label = wx.ALL|wx.ALIGN_CENTER_VERTICAL | |
Flags used with all label widgets (wx.StaticText) More... | |
flags_input = wx.ALL|wx.EXPAND|wx.ALIGN_CENTER_VERTICAL | |
Flags used for all input widgets. More... | |
tuple | max_size = (300, 27) |
Maximum widget size. More... | |
Dialog to insert and change transactions.
def gui.dialogs.DlgTrade.__init__ | ( | self, | |
parent, | |||
kind = "buy" , |
|||
share = None , |
|||
position = None |
|||
) |
Initialise dialog.
self | The object pointer |
parent | The parent object |
kind | Kind of transaction, valid are sell , buy or None |
share | A Share object |
position | A Position object |
Creating this dialog using the arguments share
and position
causes an ValueError
exception.
ValueError | For unknown transaction kinds |
ValueError | If share and position is set |
Reimplemented from gui.UITrade.UITrade.
|
private |
Return decimal value of any decimal or money widget.
References gui.dialogs.DlgTrade._decimalWidgets, gui.dialogs.DlgTrade._moneyWidgets, gui.dialogs.DlgTrade.currency_escaped, gui.dialogs.DlgTrade.locale_db, and gui.dialogs.DlgTrade.widget2name.
Referenced by gui.dialogs.DlgTrade._prepareBuy(), gui.dialogs.DlgTrade._prepareDividend(), gui.dialogs.DlgTrade._prepareSell(), gui.dialogs.DlgTrade._prepareSplit(), gui.dialogs.DlgTrade._prepareSwap(), gui.dialogs.DlgTrade._updateMoneyFormat(), gui.dialogs.DlgTrade._validateDecimalWidget(), gui.dialogs.DlgTrade.OnUpdateBuySum(), gui.dialogs.DlgTrade.OnUpdateBuyValue(), gui.dialogs.DlgTrade.OnUpdateDividendSum(), and gui.dialogs.DlgTrade.OnUpdateDividendValue().
|
private |
Prepare "Buy" transaction by storing all related values in results.
References gui.dialogs.DlgTrade._getDecimal(), gui.dialogs.DlgTrade.calc_mode, gui.UITrade.UITrade.cc_BuyExchange, gui.UITrade.UITrade.dp_BuyDate, gui.dialogs.DlgTrade.position, gui.panel.PanelOpenPositionDetails.position, smm.objects.Transaction.position, gui.UITrade.UITrade.rbn_existing_position, gui.UITrade.UITrade.rbn_WatchNote_append, gui.UITrade.UITrade.rbn_WatchNote_ignore, gui.dialogs.DlgTrade.results, gui.dialogs.DlgTrade.share, gui.dialogs.DlgShare.share, smm.objects.DailyQuote.share, smm.objects.Watch.share, smm.objects.Position.share, gui.UITrade.UITrade.tc_BuyCount, gui.UITrade.UITrade.tc_BuyFee, and gui.UITrade.UITrade.tc_BuySum.
Referenced by gui.dialogs.DlgTrade._validateInput().
|
private |
Prepare "Dividend" transaction by storing all related values in results.
References gui.dialogs.DlgTrade._getDecimal(), gui.UITrade.UITrade.dp_DividendDate, gui.dialogs.DlgTrade.results, gui.UITrade.UITrade.tc_DividendCount, and gui.UITrade.UITrade.tc_DividendValue.
Referenced by gui.dialogs.DlgTrade._validateInput().
|
private |
Prepare "Sell" transaction by storing all related values in results.
References gui.dialogs.DlgTrade._getDecimal(), gui.dialogs.DlgTrade.calc_mode, gui.UITrade.UITrade.cb_SellCloseEmpty, gui.UITrade.UITrade.cb_SellPositionReport, gui.UITrade.UITrade.cb_SellWorthless, gui.UITrade.UITrade.cc_BuyExchange, gui.UITrade.UITrade.dp_BuyDate, gui.dialogs.DlgTrade.results, gui.UITrade.UITrade.tc_BuyCount, gui.UITrade.UITrade.tc_BuyFee, and gui.UITrade.UITrade.tc_BuySum.
Referenced by gui.dialogs.DlgTrade._validateInput().
|
private |
Prepare "Split" transaction by storing all related values in results.
References gui.dialogs.DlgTrade._getDecimal(), gui.UITrade.UITrade.dp_SplitDate, gui.dialogs.DlgTrade.results, gui.UITrade.UITrade.tc_SplitNewRatio, and gui.UITrade.UITrade.tc_SplitOldRatio.
Referenced by gui.dialogs.DlgTrade._validateInput().
|
private |
Prepare "Swap" transaction by storing all related values in results.
References gui.dialogs.DlgTrade._getDecimal(), gui.UITrade.UITrade.cb_SwapCloseEmpty, gui.UITrade.UITrade.cb_SwapPositionReport, gui.UITrade.UITrade.cc_SwapNewShare, gui.UITrade.UITrade.dp_SwapDate, gui.dialogs.DlgTrade.results, gui.UITrade.UITrade.tc_SwapNewRatio, gui.UITrade.UITrade.tc_SwapNewValue, gui.UITrade.UITrade.tc_SwapOldRatio, and gui.UITrade.UITrade.tc_SwapOldValue.
Referenced by gui.dialogs.DlgTrade._validateInput().
|
private |
Create a transaction using all data.
Reimplemented from gui.controls.BaseDialog.
References gui.dialogs.DlgTrade.position, gui.panel.PanelOpenPositionDetails.position, smm.objects.Transaction.position, and gui.dialogs.DlgTrade.results.
Referenced by gui.controls.BaseDialog.ShowModal().
|
private |
Store the currency.
References gui.dialogs.DlgTrade.currency, smm.objects.Share.currency, smm.objects.DailyQuote.currency, smm.objects.Position.currency, and gui.dialogs.DlgTrade.currency_escaped.
Referenced by gui.dialogs.DlgTrade.OnUpdateCurrency(), and gui.dialogs.DlgTrade.OnUpdateExistingPosition().
|
private |
Set value at a decimal widget (monetary and non-monetary)
References gui.dialogs.DlgTrade._decimalPlaces, gui.dialogs.DlgTrade._moneyWidgets, gui.dialogs.DlgTrade.currency, smm.objects.Share.currency, smm.objects.DailyQuote.currency, smm.objects.Position.currency, gui.dialogs.DlgTrade.integer_width, gui.dialogs.DlgTrade.locale_db, and gui.dialogs.DlgTrade.widget2name.
Referenced by gui.dialogs.DlgTrade._updateMoneyFormat(), gui.dialogs.DlgTrade.configureDecimalWidget(), gui.dialogs.DlgTrade.OnUpdateBuySum(), gui.dialogs.DlgTrade.OnUpdateBuyValue(), gui.dialogs.DlgTrade.OnUpdateDividendSum(), gui.dialogs.DlgTrade.OnUpdateDividendValue(), gui.dialogs.DlgTrade.OnUpdateExistingPosition(), and gui.dialogs.DlgTrade.OnUpdateNewPosition().
|
private |
Set mode for calculation buy sum / sell sum.
References gui.dialogs.DlgTrade.calc_mode, gui.dialogs.DlgTrade.OnUpdateBuySum(), gui.UITrade.UITrade.st_BuyPlus1, and gui.UITrade.UITrade.st_BuyPlus2.
Referenced by gui.dialogs.DlgTrade.OnActivateBuy(), and gui.dialogs.DlgTrade.OnActivateSell().
|
private |
Update date ranges triggered by setting / selecting a position.
References gui.dialogs.DlgTrade._dateWidgets, gui.dialogs.DlgTrade.epoch_wx, gui.dialogs.DlgTrade.position, gui.panel.PanelOpenPositionDetails.position, smm.objects.Transaction.position, and gui.dialogs.DlgTrade.today_wx.
Referenced by gui.dialogs.DlgTrade.OnUpdateExistingPosition().
|
private |
Update date ranges triggered by setting / selecting a share.
References gui.dialogs.DlgTrade._dateWidgets, gui.dialogs.DlgTrade.epoch_wx, and gui.dialogs.DlgTrade.today_wx.
Referenced by gui.dialogs.DlgTrade.OnUpdateNewPosition().
|
private |
Change widget mask to update the currency sign / code.
References gui.dialogs.DlgTrade._getDecimal(), gui.dialogs.DlgTrade._setDecimal(), and gui.dialogs.DlgTrade.configureDecimalWidget().
Referenced by gui.dialogs.DlgTrade.OnUpdateCurrency(), and gui.dialogs.DlgTrade.OnUpdateExistingPosition().
|
private |
Validate content of a DatePickerCtrl widget.
self | The object pointer |
widget | DatePickerCtrl widget |
first | Date of the first transaction as wx.DateTime |
References gui.controls.BaseDialog._markWidget(), and gui.dialogs.DlgTrade.today_wx.
Referenced by gui.dialogs.DlgTrade._validateInput().
|
private |
Validate content of a decimal widget.
self | The object pointer |
widget | Decimal widget |
allowZero | Allow 0 value |
References gui.dialogs.DlgTrade._getDecimal(), and gui.controls.BaseDialog._markWidget().
Referenced by gui.dialogs.DlgTrade._validateInput().
|
private |
Validate input data and store results in results.
Reimplemented from gui.controls.BaseDialog.
References gui.dialogs.DlgTrade._prepareBuy(), gui.dialogs.DlgTrade._prepareDividend(), gui.dialogs.DlgTrade._prepareSell(), gui.dialogs.DlgTrade._prepareSplit(), gui.dialogs.DlgTrade._prepareSwap(), gui.controls.BaseDialog._unmarkWidget(), gui.dialogs.DlgTrade._validateDateWidget(), gui.dialogs.DlgTrade._validateDecimalWidget(), gui.controls.ShareDetailsPanel.cc_Currency, gui.controls.PositionDetailsPanel.cc_Currency, gui.UIShare.UIShare.cc_Currency, gui.UITrade.UITrade.cc_Currency, gui.UITrade.UITrade.cc_Position, gui.controls.PositionDetailsPanel.cc_Share, gui.controls.WatchDetailsPanel.cc_Share, gui.UITrade.UITrade.cc_Share, gui.UITrade.UITrade.dp_BuyDate, gui.UITrade.UITrade.dp_DividendDate, gui.UITrade.UITrade.dp_SplitDate, gui.UITrade.UITrade.dp_SwapDate, gui.dialogs.DlgTrade.OnActivateExistingPosition(), gui.dialogs.DlgTrade.position, gui.panel.PanelOpenPositionDetails.position, smm.objects.Transaction.position, gui.UITrade.UITrade.rbn_Buy, gui.UITrade.UITrade.rbn_Dividend, gui.UITrade.UITrade.rbn_existing_position, gui.UITrade.UITrade.rbn_new_position, gui.UITrade.UITrade.rbn_Sell, gui.UITrade.UITrade.rbn_Split, gui.UITrade.UITrade.rbn_Swap, gui.dialogs.DlgTrade.results, gui.UITrade.UITrade.tc_BuyCount, gui.UITrade.UITrade.tc_BuyFee, gui.UITrade.UITrade.tc_BuyValue, gui.UITrade.UITrade.tc_DividendCount, gui.UITrade.UITrade.tc_DividendSum, gui.UITrade.UITrade.tc_DividendValue, gui.UITrade.UITrade.tc_SplitNewRatio, gui.UITrade.UITrade.tc_SplitOldRatio, gui.UITrade.UITrade.tc_SwapNewRatio, gui.UITrade.UITrade.tc_SwapNewValue, gui.UITrade.UITrade.tc_SwapOldRatio, and gui.UITrade.UITrade.tc_SwapOldValue.
Referenced by gui.controls.BaseDialog.OnOK().
def gui.dialogs.DlgTrade.configureDecimalWidget | ( | self, | |
widget, | |||
value = None |
|||
) |
Set format of a decimal widget (monetary or non-monetary)
self | The object pointer |
widget | Decimal widget |
value | Value to set |
References gui.dialogs.DlgTrade._decimalPlaces, gui.dialogs.DlgTrade._moneyWidgets, gui.dialogs.DlgTrade._setDecimal(), gui.dialogs.DlgTrade.currency_escaped, gui.dialogs.DlgTrade.integer_width, and gui.dialogs.DlgTrade.locale_db.
Referenced by gui.dialogs.DlgTrade._updateMoneyFormat().
def gui.dialogs.DlgTrade.OnActivateBuy | ( | self, | |
unused = None |
|||
) |
Activate "Buy" radiobutton after a secondary widget has been focused.
References gui.dialogs.DlgTrade._updateCalcMode(), gui.UITrade.UITrade.rbn_Buy, and gui.UITrade.UITrade.rbn_Sell.
Referenced by gui.dialogs.DlgTrade.OnActivateNewPosition().
def gui.dialogs.DlgTrade.OnActivateDividend | ( | self, | |
unused = None |
|||
) |
Activate "Dividend" radiobutton after a secondary widget has been focused.
References gui.UITrade.UITrade.rbn_Dividend.
def gui.dialogs.DlgTrade.OnActivateExistingPosition | ( | self, | |
unused = None |
|||
) |
Activate "Existing position".
Enable all transactions
All transaction kind are possible with an existing position.
References gui.dialogs.DlgTrade.nonBuyWidgets, gui.dialogs.DlgTrade.OnUpdateExistingPosition(), gui.UITrade.UITrade.rbn_existing_position, gui.UITrade.UITrade.rbn_WatchNote_append, gui.UITrade.UITrade.rbn_WatchNote_ignore, and gui.UITrade.UITrade.rbn_WatchNote_replace.
Referenced by gui.dialogs.DlgTrade._validateInput().
def gui.dialogs.DlgTrade.OnActivateNewPosition | ( | self, | |
unused = None |
|||
) |
Activate "New position".
Disable all transactions except "buy"
The only transaction kind for a new transaction (within this dialog) is to "buy" something. Thereby all non-buy transactions will be disabled to a new position.
References gui.dialogs.DlgTrade.nonBuyWidgets, gui.dialogs.DlgTrade.OnActivateBuy(), gui.dialogs.DlgTrade.OnUpdateCurrency(), gui.dialogs.DlgTrade.OnUpdateNewPosition(), and gui.UITrade.UITrade.rbn_new_position.
def gui.dialogs.DlgTrade.OnActivateSell | ( | self, | |
unused = None |
|||
) |
Activate "Sell" radiobutton after a secondary widget has been focused.
References gui.dialogs.DlgTrade._updateCalcMode(), and gui.UITrade.UITrade.rbn_Sell.
def gui.dialogs.DlgTrade.OnActivateSplit | ( | self, | |
unused = None |
|||
) |
Activate "Split" radiobutton after a secondary widget has been focused.
References gui.UITrade.UITrade.rbn_Split.
def gui.dialogs.DlgTrade.OnActivateSwap | ( | self, | |
unused = None |
|||
) |
Activate "Swap" radiobutton after a secondary widget has been focused.
References gui.UITrade.UITrade.rbn_Swap.
def gui.dialogs.DlgTrade.OnUpdateBuySum | ( | self, | |
unused = None |
|||
) |
Update buy sum after changing buy value or share count.
References gui.dialogs.DlgTrade._getDecimal(), gui.dialogs.DlgTrade._setDecimal(), gui.dialogs.DlgTrade.calc_mode, gui.UITrade.UITrade.tc_BuyCount, gui.UITrade.UITrade.tc_BuyFee, gui.UITrade.UITrade.tc_BuySum, and gui.UITrade.UITrade.tc_BuyValue.
Referenced by gui.dialogs.DlgTrade._updateCalcMode(), gui.dialogs.DlgTrade.OnUpdateExistingPosition(), and gui.dialogs.DlgTrade.OnUpdateNewPosition().
def gui.dialogs.DlgTrade.OnUpdateBuyValue | ( | self, | |
unused = None |
|||
) |
Update buy value after changing buy sum.
References gui.dialogs.DlgTrade._getDecimal(), gui.dialogs.DlgTrade._setDecimal(), gui.dialogs.DlgTrade.calc_mode, gui.UITrade.UITrade.tc_BuyCount, gui.UITrade.UITrade.tc_BuyFee, gui.UITrade.UITrade.tc_BuySum, and gui.UITrade.UITrade.tc_BuyValue.
def gui.dialogs.DlgTrade.OnUpdateCurrency | ( | self, | |
unused = None |
|||
) |
Update dialog after the currency has changed.
References gui.dialogs.DlgTrade._moneyWidgets, gui.dialogs.DlgTrade._setCurrency(), gui.dialogs.DlgTrade._updateMoneyFormat(), gui.controls.ShareDetailsPanel.cc_Currency, gui.controls.PositionDetailsPanel.cc_Currency, gui.UIShare.UIShare.cc_Currency, and gui.UITrade.UITrade.cc_Currency.
Referenced by gui.dialogs.DlgTrade.OnActivateNewPosition().
def gui.dialogs.DlgTrade.OnUpdateDividendSum | ( | self, | |
unused = None |
|||
) |
Update dividend sum after changing dividend value or count.
References gui.dialogs.DlgTrade._getDecimal(), gui.dialogs.DlgTrade._setDecimal(), gui.UITrade.UITrade.tc_DividendCount, gui.UITrade.UITrade.tc_DividendSum, and gui.UITrade.UITrade.tc_DividendValue.
Referenced by gui.dialogs.DlgTrade.OnUpdateExistingPosition(), and gui.dialogs.DlgTrade.OnUpdateNewPosition().
def gui.dialogs.DlgTrade.OnUpdateDividendValue | ( | self, | |
unused = None |
|||
) |
Update dividend value after changing dividend sum.
References gui.dialogs.DlgTrade._getDecimal(), gui.dialogs.DlgTrade._setDecimal(), gui.UITrade.UITrade.tc_DividendCount, gui.UITrade.UITrade.tc_DividendSum, and gui.UITrade.UITrade.tc_DividendValue.
def gui.dialogs.DlgTrade.OnUpdateExistingPosition | ( | self, | |
unused = None |
|||
) |
Update position related widgets.
References gui.dialogs.DlgTrade._moneyWidgets, gui.dialogs.DlgTrade._setCurrency(), gui.dialogs.DlgTrade._setDecimal(), gui.dialogs.DlgTrade._updateDateRangePosition(), gui.dialogs.DlgTrade._updateMoneyFormat(), gui.UITrade.UITrade.cc_Position, gui.dialogs.DlgTrade.OnUpdateBuySum(), gui.dialogs.DlgTrade.OnUpdateDividendSum(), gui.dialogs.DlgTrade.position, gui.panel.PanelOpenPositionDetails.position, smm.objects.Transaction.position, gui.dialogs.DlgTrade.share, gui.dialogs.DlgShare.share, smm.objects.DailyQuote.share, smm.objects.Watch.share, smm.objects.Position.share, gui.UITrade.UITrade.tc_BuyCount, and gui.UITrade.UITrade.tc_DividendCount.
Referenced by gui.dialogs.DlgTrade.OnActivateExistingPosition().
def gui.dialogs.DlgTrade.OnUpdateNewPosition | ( | self, | |
unused = None |
|||
) |
Update share related widgets.
References gui.dialogs.DlgTrade._setDecimal(), gui.dialogs.DlgTrade._updateDateRangeShare(), gui.controls.PositionDetailsPanel.cc_Share, gui.controls.WatchDetailsPanel.cc_Share, gui.UITrade.UITrade.cc_Share, gui.dialogs.DlgTrade.OnUpdateBuySum(), gui.dialogs.DlgTrade.OnUpdateDividendSum(), gui.dialogs.DlgTrade.position, gui.panel.PanelOpenPositionDetails.position, smm.objects.Transaction.position, gui.UITrade.UITrade.rbn_WatchNote_append, gui.UITrade.UITrade.rbn_WatchNote_ignore, gui.UITrade.UITrade.rbn_WatchNote_replace, gui.dialogs.DlgTrade.share, gui.dialogs.DlgShare.share, smm.objects.DailyQuote.share, smm.objects.Watch.share, smm.objects.Position.share, gui.UITrade.UITrade.st_WatchEntry, gui.UITrade.UITrade.tc_BuyCount, and gui.UITrade.UITrade.tc_DividendCount.
Referenced by gui.dialogs.DlgTrade.OnActivateNewPosition().
|
private |
List of all date widgets.
Referenced by gui.dialogs.DlgTrade._updateDateRangePosition(), and gui.dialogs.DlgTrade._updateDateRangeShare().
|
private |
Number of decimal places for all decimal widgets (monetary and non-monetary)
0
is default, thereby 0
entries are skipped
Referenced by gui.dialogs.DlgTrade._setDecimal(), and gui.dialogs.DlgTrade.configureDecimalWidget().
|
private |
List of all decimal widgets (monetary and non-monetary)
Referenced by gui.dialogs.DlgTrade._getDecimal().
|
private |
List of all money widgets only (subset of _decimalWidgets)
Referenced by gui.dialogs.DlgTrade._getDecimal(), gui.dialogs.DlgTrade._setDecimal(), gui.dialogs.DlgTrade.configureDecimalWidget(), gui.dialogs.DlgTrade.OnUpdateCurrency(), and gui.dialogs.DlgTrade.OnUpdateExistingPosition().
gui.dialogs.DlgTrade.calc_mode |
Mode for calculation buy sum / sell sum.
Fee is adding to sum in "buy" mode opposite to "sell" mode where fee decreased the transaction sum.
Referenced by gui.dialogs.DlgTrade._prepareBuy(), gui.dialogs.DlgTrade._prepareSell(), gui.dialogs.DlgTrade._updateCalcMode(), gui.dialogs.DlgTrade.OnUpdateBuySum(), and gui.dialogs.DlgTrade.OnUpdateBuyValue().
gui.dialogs.DlgTrade.currency |
Currency selected within the dialog.
The currency could be the currency of the selected position or a separate specified currency
Referenced by smm.objects.DailyQuote.__str__(), smm.objects.Position.__str__(), gui.dialogs.DlgTrade._setCurrency(), gui.dialogs.DlgTrade._setDecimal(), smm.objects.Position.getLastQuote(), smm.objects.Share.getPrefCurrency(), and smm.objects.Position.swap().
gui.dialogs.DlgTrade.currency_escaped |
Formatted and escaped currency (to fit mask syntax)
Referenced by gui.dialogs.DlgTrade._getDecimal(), gui.dialogs.DlgTrade._setCurrency(), and gui.dialogs.DlgTrade.configureDecimalWidget().
gui.dialogs.DlgTrade.defaultValues |
Default values for decimal and money widgets.
gui.dialogs.DlgTrade.epoch |
Earliest date for date controls (native Python)
gui.dialogs.DlgTrade.epoch_wx |
Earliest date for date controls (wx format)
Referenced by gui.dialogs.DlgTrade._updateDateRangePosition(), and gui.dialogs.DlgTrade._updateDateRangeShare().
gui.dialogs.DlgTrade.integer_width |
Width of the formatted integer part of a value.
Referenced by gui.dialogs.DlgTrade._setDecimal(), and gui.dialogs.DlgTrade.configureDecimalWidget().
gui.dialogs.DlgTrade.locale_db |
Database of the local conventions as a dictionary.
Referenced by gui.dialogs.DlgTrade._getDecimal(), gui.dialogs.DlgTrade._setDecimal(), and gui.dialogs.DlgTrade.configureDecimalWidget().
gui.dialogs.DlgTrade.nonBuyWidgets |
List of widgets to block in case of new position.
Referenced by gui.dialogs.DlgTrade.OnActivateExistingPosition(), and gui.dialogs.DlgTrade.OnActivateNewPosition().
gui.dialogs.DlgTrade.position |
Position to add the current Transaction.
Referenced by smm.objects.Transaction.__init__(), smm.objects.Transaction.__str__(), gui.dialogs.DlgTrade._prepareBuy(), gui.dialogs.DlgTrade._processInput(), gui.dialogs.DlgTrade._updateDateRangePosition(), gui.dialogs.DlgTrade._validateInput(), gui.panel.PanelOpenPositionDetails.OnItemSelected(), gui.panel.PanelOpenPositionDetails.OnSave(), gui.panel.PanelOpenPositionDetails.OnTrade(), gui.dialogs.DlgTrade.OnUpdateExistingPosition(), gui.dialogs.DlgTrade.OnUpdateNewPosition(), gui.panel.PanelOpenPositionDetails.psUpdateContent(), smm.objects.Transaction.remove(), and gui.panel.PanelOpenPositionDetails.showDetails().
gui.dialogs.DlgTrade.results |
Dialog results stored after validation by _validateInput()
Referenced by gui.dialogs.DlgTrade._prepareBuy(), gui.dialogs.DlgTrade._prepareDividend(), gui.dialogs.DlgTrade._prepareSell(), gui.dialogs.DlgTrade._prepareSplit(), gui.dialogs.DlgTrade._prepareSwap(), gui.dialogs.DlgTrade._processInput(), and gui.dialogs.DlgTrade._validateInput().
gui.dialogs.DlgTrade.share |
Share to trade with.
Referenced by smm.objects.Watch.__init__(), smm.objects.DailyQuote.__str__(), smm.objects.Watch.__str__(), smm.objects.Position.__str__(), gui.dialogs.DlgTrade._prepareBuy(), gui.dialogs.DlgShare._processInput(), gui.dialogs.DlgShare._setShare(), gui.dialogs.DlgShare._validateInput(), smm.objects.Position.getLastQuote(), smm.objects.Position.getPerf(), gui.dialogs.DlgTrade.OnUpdateExistingPosition(), gui.dialogs.DlgTrade.OnUpdateNewPosition(), smm.objects.Watch.remove(), and smm.objects.Position.split().
gui.dialogs.DlgTrade.today |
Today's date (native Python)
gui.dialogs.DlgTrade.today_wx |
Todays date (wx format)
Referenced by gui.dialogs.DlgTrade._updateDateRangePosition(), gui.dialogs.DlgTrade._updateDateRangeShare(), and gui.dialogs.DlgTrade._validateDateWidget().
gui.dialogs.DlgTrade.widget2name |
Dictionary to convert widgets instances to human-readable names.
Referenced by gui.dialogs.DlgTrade._getDecimal(), and gui.dialogs.DlgTrade._setDecimal().