hedgequantx 2.6.20 → 2.6.21
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
CHANGED
|
@@ -788,16 +788,11 @@ const selectSymbol = async (service) => {
|
|
|
788
788
|
return (a.name || '').localeCompare(b.name || '');
|
|
789
789
|
});
|
|
790
790
|
|
|
791
|
+
// Display contracts (uniform format: NAME - DESCRIPTION)
|
|
791
792
|
const options = contracts.slice(0, 30).map(c => {
|
|
792
|
-
|
|
793
|
-
|
|
794
|
-
|
|
795
|
-
label = `${c.name} - ${c.description} (${c.exchange || 'CME'})`;
|
|
796
|
-
} else {
|
|
797
|
-
// Rithmic format
|
|
798
|
-
const name = c.name || c.baseSymbol || c.symbol;
|
|
799
|
-
label = `${c.symbol || name} (${c.exchange || 'CME'})`;
|
|
800
|
-
}
|
|
793
|
+
const name = c.name || c.symbol || c.baseSymbol;
|
|
794
|
+
const desc = c.description || '';
|
|
795
|
+
const label = desc ? `${name} - ${desc}` : name;
|
|
801
796
|
return { label, value: c };
|
|
802
797
|
});
|
|
803
798
|
|
|
@@ -119,20 +119,11 @@ const selectSymbol = async (service, account) => {
|
|
|
119
119
|
|
|
120
120
|
spinner.succeed(`FOUND ${contracts.length} CONTRACTS`);
|
|
121
121
|
|
|
122
|
-
// Display sorted contracts from API
|
|
123
|
-
// ProjectX has: name + description
|
|
124
|
-
// Rithmic has: name (or baseSymbol) + exchange
|
|
122
|
+
// Display sorted contracts from API (uniform format: NAME - DESCRIPTION)
|
|
125
123
|
const options = contracts.map(c => {
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
label = `${c.name} - ${c.description}`;
|
|
130
|
-
} else {
|
|
131
|
-
// Rithmic format
|
|
132
|
-
const name = c.name || c.baseSymbol || c.symbol;
|
|
133
|
-
const exchange = c.exchange ? ` (${c.exchange})` : '';
|
|
134
|
-
label = `${c.symbol || name}${exchange}`;
|
|
135
|
-
}
|
|
124
|
+
const name = c.name || c.symbol || c.baseSymbol;
|
|
125
|
+
const desc = c.description || '';
|
|
126
|
+
const label = desc ? `${name} - ${desc}` : name;
|
|
136
127
|
return { label, value: c };
|
|
137
128
|
});
|
|
138
129
|
|
|
@@ -768,10 +768,12 @@ class RithmicService extends EventEmitter {
|
|
|
768
768
|
const product = productsToCheck.get(productKey);
|
|
769
769
|
|
|
770
770
|
// 100% API data - no static symbol info
|
|
771
|
+
const productName = product?.productName || baseSymbol;
|
|
771
772
|
results.push({
|
|
772
773
|
symbol: contract.symbol,
|
|
773
774
|
baseSymbol,
|
|
774
|
-
name:
|
|
775
|
+
name: contract.symbol, // Use trading symbol as name
|
|
776
|
+
description: productName, // Product name as description (like ProjectX)
|
|
775
777
|
exchange: contract.exchange,
|
|
776
778
|
// All other data comes from API at runtime
|
|
777
779
|
});
|