@barchart/portfolio-api-common 1.0.203 → 1.0.204
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -19,8 +19,8 @@ module.exports = (() => {
|
|
|
19
19
|
* @static
|
|
20
20
|
* @returns {FailureType}
|
|
21
21
|
*/
|
|
22
|
-
static get
|
|
23
|
-
return
|
|
22
|
+
static get POSITION_CREATE_FAILED_NO_PORTFOLIO() {
|
|
23
|
+
return positionCreateFailedNoPortfolio;
|
|
24
24
|
}
|
|
25
25
|
|
|
26
26
|
/**
|
|
@@ -71,7 +71,8 @@ module.exports = (() => {
|
|
|
71
71
|
}
|
|
72
72
|
}
|
|
73
73
|
|
|
74
|
-
const
|
|
74
|
+
const positionCreateFailedNoPortfolio = new FailureType('POSITION_CREATE_FAILED_OUT_OF_SEQUENCE', 'Unable to create transaction. The referenced portfolio does not exist. Has it been deleted?');
|
|
75
|
+
|
|
75
76
|
const transactionCreateFailedOutOfSequence = new FailureType('TRANSACTION_CREATE_FAILED_OUT_OF_SEQUENCE', 'Unable to create transaction, because the transaction date is out-of-sequence. In other words, it would occur before an existing transaction. Please confirm your intent to re-write transaction history (which could take some time and alter the historical results for this position).');
|
|
76
77
|
const transactionCreateFailedDirectionSwitch = new FailureType('TRANSACTION_CREATE_FAILED_DIRECTION_SWITCH', 'Unable to create transaction, because the position direction would be switched (from long to short or vice versa). Please close the position (to a zero balance) first, then enter a second transaction.');
|
|
77
78
|
const transactionCreateRewriteUnsupported = new FailureType('TRANSACTION_CREATE_REWRITE_UNSUPPORTED', 'Unable to re-write transaction history. This operation is not currently supported (but will be implemented soon).');
|