hedgequantx 1.8.40 → 1.8.41
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.
- package/package.json +1 -1
- package/src/pages/algo/ui.js +2 -2
- package/src/pages/orders.js +1 -1
- package/src/pages/positions.js +1 -1
package/package.json
CHANGED
package/src/pages/algo/ui.js
CHANGED
|
@@ -157,8 +157,8 @@ class AlgoUI {
|
|
|
157
157
|
this._line(chalk.cyan(GT));
|
|
158
158
|
|
|
159
159
|
// Row 1: Account | Symbol
|
|
160
|
-
const accountName = (stats.accountName || 'N/A').substring(0, 40);
|
|
161
|
-
const symbol = (stats.symbol || 'N/A').substring(0, 35);
|
|
160
|
+
const accountName = String(stats.accountName || 'N/A').substring(0, 40);
|
|
161
|
+
const symbol = String(stats.symbol || 'N/A').substring(0, 35);
|
|
162
162
|
const r1c1 = buildCell('Account', accountName, chalk.cyan, colL);
|
|
163
163
|
const r1c2 = buildCell('Symbol', symbol, chalk.yellow, colR);
|
|
164
164
|
row(r1c1.padded, r1c2.padded);
|
package/src/pages/orders.js
CHANGED
|
@@ -69,7 +69,7 @@ const showOrders = async (service) => {
|
|
|
69
69
|
const qty = order.size || order.quantity || 0;
|
|
70
70
|
const price = order.limitPrice || order.price || 0;
|
|
71
71
|
const statusInfo = ORDER_STATUS[order.status] || { text: 'Unknown', color: 'gray', icon: '[?]' };
|
|
72
|
-
const account = (order.accountName || 'Unknown').substring(0, 12);
|
|
72
|
+
const account = String(order.accountName || 'Unknown').substring(0, 12);
|
|
73
73
|
|
|
74
74
|
const row = ' ' +
|
|
75
75
|
chalk.white(symbol.padEnd(12)) +
|
package/src/pages/positions.js
CHANGED
|
@@ -68,7 +68,7 @@ const showPositions = async (service) => {
|
|
|
68
68
|
const size = Math.abs(pos.size || pos.quantity || 0);
|
|
69
69
|
const entry = pos.averagePrice || pos.entryPrice || 0;
|
|
70
70
|
const pnl = pos.profitAndLoss || pos.unrealizedPnl || 0;
|
|
71
|
-
const account = (pos.accountName || 'Unknown').substring(0, 15);
|
|
71
|
+
const account = String(pos.accountName || 'Unknown').substring(0, 15);
|
|
72
72
|
|
|
73
73
|
const pnlColor = pnl >= 0 ? chalk.green : chalk.red;
|
|
74
74
|
const pnlStr = (pnl >= 0 ? '+' : '') + '$' + pnl.toFixed(2);
|