adaptic-backend 1.0.266 → 1.0.267
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/Account.cjs +27 -27
- package/Action.cjs +81 -81
- package/Alert.cjs +51 -51
- package/AlpacaAccount.cjs +99 -99
- package/Asset.cjs +111 -111
- package/Authenticator.cjs +27 -27
- package/Contract.cjs +90 -90
- package/Customer.cjs +27 -27
- package/Deliverable.cjs +36 -36
- package/NewsArticle.cjs +18 -18
- package/NewsArticleAssetSentiment.cjs +48 -48
- package/Order.cjs +108 -108
- package/Position.cjs +93 -93
- package/Session.cjs +27 -27
- package/StopLoss.cjs +51 -51
- package/TakeProfit.cjs +51 -51
- package/Trade.cjs +108 -108
- package/User.cjs +51 -51
- package/package.json +1 -1
- package/server/Account.js.map +1 -1
- package/server/Account.mjs +27 -27
- package/server/Action.js.map +1 -1
- package/server/Action.mjs +81 -81
- package/server/Alert.js.map +1 -1
- package/server/Alert.mjs +51 -51
- package/server/AlpacaAccount.js.map +1 -1
- package/server/AlpacaAccount.mjs +99 -99
- package/server/Asset.js.map +1 -1
- package/server/Asset.mjs +111 -111
- package/server/Authenticator.js.map +1 -1
- package/server/Authenticator.mjs +27 -27
- package/server/Contract.js.map +1 -1
- package/server/Contract.mjs +90 -90
- package/server/Customer.js.map +1 -1
- package/server/Customer.mjs +27 -27
- package/server/Deliverable.js.map +1 -1
- package/server/Deliverable.mjs +36 -36
- package/server/NewsArticle.js.map +1 -1
- package/server/NewsArticle.mjs +18 -18
- package/server/NewsArticleAssetSentiment.js.map +1 -1
- package/server/NewsArticleAssetSentiment.mjs +48 -48
- package/server/Order.js.map +1 -1
- package/server/Order.mjs +108 -108
- package/server/Position.js.map +1 -1
- package/server/Position.mjs +93 -93
- package/server/Session.js.map +1 -1
- package/server/Session.mjs +27 -27
- package/server/StopLoss.js.map +1 -1
- package/server/StopLoss.mjs +51 -51
- package/server/TakeProfit.js.map +1 -1
- package/server/TakeProfit.mjs +51 -51
- package/server/Trade.js.map +1 -1
- package/server/Trade.mjs +108 -108
- package/server/User.js.map +1 -1
- package/server/User.mjs +51 -51
@@ -761,7 +761,7 @@ export const NewsArticleAssetSentiment = {
|
|
761
761
|
set: props.sentimentLabel
|
762
762
|
} : undefined,
|
763
763
|
news: props.news ?
|
764
|
-
typeof props.news === 'object' && Object.keys(props.news).length === 1 && Object.keys(props.news)[0] === 'id'
|
764
|
+
typeof props.news === 'object' && Object.keys(props.news).length === 1 && (Object.keys(props.news)[0] === 'id' || Object.keys(props.news)[0] === 'symbol')
|
765
765
|
? {
|
766
766
|
connect: {
|
767
767
|
id: props.news.id
|
@@ -844,7 +844,7 @@ export const NewsArticleAssetSentiment = {
|
|
844
844
|
}
|
845
845
|
} : undefined,
|
846
846
|
asset: props.asset ?
|
847
|
-
typeof props.asset === 'object' && Object.keys(props.asset).length === 1 && Object.keys(props.asset)[0] === 'id'
|
847
|
+
typeof props.asset === 'object' && Object.keys(props.asset).length === 1 && (Object.keys(props.asset)[0] === 'id' || Object.keys(props.asset)[0] === 'symbol')
|
848
848
|
? {
|
849
849
|
connect: {
|
850
850
|
id: props.asset.id
|
@@ -1031,7 +1031,7 @@ export const NewsArticleAssetSentiment = {
|
|
1031
1031
|
set: props.asset.bidPrice
|
1032
1032
|
} : undefined,
|
1033
1033
|
trades: props.asset.trades ?
|
1034
|
-
Array.isArray(props.asset.trades) && props.asset.trades.length > 0 && props.asset.trades.every((item) => typeof item === 'object' && 'id' in item && Object.keys(item).length === 1) ? {
|
1034
|
+
Array.isArray(props.asset.trades) && props.asset.trades.length > 0 && props.asset.trades.every((item) => typeof item === 'object' && ('id' in item || 'symbol' in item) && Object.keys(item).length === 1) ? {
|
1035
1035
|
connect: props.asset.trades.map((item) => ({
|
1036
1036
|
id: item.id
|
1037
1037
|
}))
|
@@ -1083,7 +1083,7 @@ export const NewsArticleAssetSentiment = {
|
|
1083
1083
|
set: item.status
|
1084
1084
|
} : undefined,
|
1085
1085
|
alpacaAccount: item.alpacaAccount ?
|
1086
|
-
typeof item.alpacaAccount === 'object' && Object.keys(item.alpacaAccount).length === 1 && Object.keys(item.alpacaAccount)[0] === 'id'
|
1086
|
+
typeof item.alpacaAccount === 'object' && Object.keys(item.alpacaAccount).length === 1 && (Object.keys(item.alpacaAccount)[0] === 'id' || Object.keys(item.alpacaAccount)[0] === 'symbol')
|
1087
1087
|
? {
|
1088
1088
|
connect: {
|
1089
1089
|
id: item.alpacaAccount.id
|
@@ -1147,7 +1147,7 @@ export const NewsArticleAssetSentiment = {
|
|
1147
1147
|
}
|
1148
1148
|
} : undefined,
|
1149
1149
|
actions: item.actions ?
|
1150
|
-
Array.isArray(item.actions) && item.actions.length > 0 && item.actions.every((item) => typeof item === 'object' && 'id' in item && Object.keys(item).length === 1) ? {
|
1150
|
+
Array.isArray(item.actions) && item.actions.length > 0 && item.actions.every((item) => typeof item === 'object' && ('id' in item || 'symbol' in item) && Object.keys(item).length === 1) ? {
|
1151
1151
|
connect: item.actions.map((item) => ({
|
1152
1152
|
id: item.id
|
1153
1153
|
}))
|
@@ -1276,7 +1276,7 @@ export const NewsArticleAssetSentiment = {
|
|
1276
1276
|
}))
|
1277
1277
|
} : undefined,
|
1278
1278
|
orders: props.asset.orders ?
|
1279
|
-
Array.isArray(props.asset.orders) && props.asset.orders.length > 0 && props.asset.orders.every((item) => typeof item === 'object' && 'id' in item && Object.keys(item).length === 1) ? {
|
1279
|
+
Array.isArray(props.asset.orders) && props.asset.orders.length > 0 && props.asset.orders.every((item) => typeof item === 'object' && ('id' in item || 'symbol' in item) && Object.keys(item).length === 1) ? {
|
1280
1280
|
connect: props.asset.orders.map((item) => ({
|
1281
1281
|
id: item.id
|
1282
1282
|
}))
|
@@ -1377,7 +1377,7 @@ export const NewsArticleAssetSentiment = {
|
|
1377
1377
|
set: item.takeProfitId
|
1378
1378
|
} : undefined,
|
1379
1379
|
stopLoss: item.stopLoss ?
|
1380
|
-
typeof item.stopLoss === 'object' && Object.keys(item.stopLoss).length === 1 && Object.keys(item.stopLoss)[0] === 'id'
|
1380
|
+
typeof item.stopLoss === 'object' && Object.keys(item.stopLoss).length === 1 && (Object.keys(item.stopLoss)[0] === 'id' || Object.keys(item.stopLoss)[0] === 'symbol')
|
1381
1381
|
? {
|
1382
1382
|
connect: {
|
1383
1383
|
id: item.stopLoss.id
|
@@ -1409,7 +1409,7 @@ export const NewsArticleAssetSentiment = {
|
|
1409
1409
|
}
|
1410
1410
|
} : undefined,
|
1411
1411
|
takeProfit: item.takeProfit ?
|
1412
|
-
typeof item.takeProfit === 'object' && Object.keys(item.takeProfit).length === 1 && Object.keys(item.takeProfit)[0] === 'id'
|
1412
|
+
typeof item.takeProfit === 'object' && Object.keys(item.takeProfit).length === 1 && (Object.keys(item.takeProfit)[0] === 'id' || Object.keys(item.takeProfit)[0] === 'symbol')
|
1413
1413
|
? {
|
1414
1414
|
connect: {
|
1415
1415
|
id: item.takeProfit.id
|
@@ -1441,7 +1441,7 @@ export const NewsArticleAssetSentiment = {
|
|
1441
1441
|
}
|
1442
1442
|
} : undefined,
|
1443
1443
|
alpacaAccount: item.alpacaAccount ?
|
1444
|
-
typeof item.alpacaAccount === 'object' && Object.keys(item.alpacaAccount).length === 1 && Object.keys(item.alpacaAccount)[0] === 'id'
|
1444
|
+
typeof item.alpacaAccount === 'object' && Object.keys(item.alpacaAccount).length === 1 && (Object.keys(item.alpacaAccount)[0] === 'id' || Object.keys(item.alpacaAccount)[0] === 'symbol')
|
1445
1445
|
? {
|
1446
1446
|
connect: {
|
1447
1447
|
id: item.alpacaAccount.id
|
@@ -1505,7 +1505,7 @@ export const NewsArticleAssetSentiment = {
|
|
1505
1505
|
}
|
1506
1506
|
} : undefined,
|
1507
1507
|
action: item.action ?
|
1508
|
-
typeof item.action === 'object' && Object.keys(item.action).length === 1 && Object.keys(item.action)[0] === 'id'
|
1508
|
+
typeof item.action === 'object' && Object.keys(item.action).length === 1 && (Object.keys(item.action)[0] === 'id' || Object.keys(item.action)[0] === 'symbol')
|
1509
1509
|
? {
|
1510
1510
|
connect: {
|
1511
1511
|
id: item.action.id
|
@@ -1565,7 +1565,7 @@ export const NewsArticleAssetSentiment = {
|
|
1565
1565
|
}
|
1566
1566
|
} : undefined,
|
1567
1567
|
contract: item.contract ?
|
1568
|
-
typeof item.contract === 'object' && Object.keys(item.contract).length === 1 && Object.keys(item.contract)[0] === 'id'
|
1568
|
+
typeof item.contract === 'object' && Object.keys(item.contract).length === 1 && (Object.keys(item.contract)[0] === 'id' || Object.keys(item.contract)[0] === 'symbol')
|
1569
1569
|
? {
|
1570
1570
|
connect: {
|
1571
1571
|
id: item.contract.id
|
@@ -1846,7 +1846,7 @@ export const NewsArticleAssetSentiment = {
|
|
1846
1846
|
}))
|
1847
1847
|
} : undefined,
|
1848
1848
|
positions: props.asset.positions ?
|
1849
|
-
Array.isArray(props.asset.positions) && props.asset.positions.length > 0 && props.asset.positions.every((item) => typeof item === 'object' && 'id' in item && Object.keys(item).length === 1) ? {
|
1849
|
+
Array.isArray(props.asset.positions) && props.asset.positions.length > 0 && props.asset.positions.every((item) => typeof item === 'object' && ('id' in item || 'symbol' in item) && Object.keys(item).length === 1) ? {
|
1850
1850
|
connect: props.asset.positions.map((item) => ({
|
1851
1851
|
id: item.id
|
1852
1852
|
}))
|
@@ -1913,7 +1913,7 @@ export const NewsArticleAssetSentiment = {
|
|
1913
1913
|
set: item.closed
|
1914
1914
|
} : undefined,
|
1915
1915
|
alpacaAccount: item.alpacaAccount ?
|
1916
|
-
typeof item.alpacaAccount === 'object' && Object.keys(item.alpacaAccount).length === 1 && Object.keys(item.alpacaAccount)[0] === 'id'
|
1916
|
+
typeof item.alpacaAccount === 'object' && Object.keys(item.alpacaAccount).length === 1 && (Object.keys(item.alpacaAccount)[0] === 'id' || Object.keys(item.alpacaAccount)[0] === 'symbol')
|
1917
1917
|
? {
|
1918
1918
|
connect: {
|
1919
1919
|
id: item.alpacaAccount.id
|
@@ -2024,7 +2024,7 @@ export const NewsArticleAssetSentiment = {
|
|
2024
2024
|
}))
|
2025
2025
|
} : undefined,
|
2026
2026
|
contracts: props.asset.contracts ?
|
2027
|
-
Array.isArray(props.asset.contracts) && props.asset.contracts.length > 0 && props.asset.contracts.every((item) => typeof item === 'object' && 'id' in item && Object.keys(item).length === 1) ? {
|
2027
|
+
Array.isArray(props.asset.contracts) && props.asset.contracts.length > 0 && props.asset.contracts.every((item) => typeof item === 'object' && ('id' in item || 'symbol' in item) && Object.keys(item).length === 1) ? {
|
2028
2028
|
connect: props.asset.contracts.map((item) => ({
|
2029
2029
|
id: item.id
|
2030
2030
|
}))
|
@@ -2111,7 +2111,7 @@ export const NewsArticleAssetSentiment = {
|
|
2111
2111
|
set: item.orderId
|
2112
2112
|
} : undefined,
|
2113
2113
|
deliverables: item.deliverables ?
|
2114
|
-
Array.isArray(item.deliverables) && item.deliverables.length > 0 && item.deliverables.every((item) => typeof item === 'object' && 'id' in item && Object.keys(item).length === 1) ? {
|
2114
|
+
Array.isArray(item.deliverables) && item.deliverables.length > 0 && item.deliverables.every((item) => typeof item === 'object' && ('id' in item || 'symbol' in item) && Object.keys(item).length === 1) ? {
|
2115
2115
|
connect: item.deliverables.map((item) => ({
|
2116
2116
|
id: item.id
|
2117
2117
|
}))
|
@@ -2170,7 +2170,7 @@ export const NewsArticleAssetSentiment = {
|
|
2170
2170
|
}))
|
2171
2171
|
} : undefined,
|
2172
2172
|
order: item.order ?
|
2173
|
-
typeof item.order === 'object' && Object.keys(item.order).length === 1 && Object.keys(item.order)[0] === 'id'
|
2173
|
+
typeof item.order === 'object' && Object.keys(item.order).length === 1 && (Object.keys(item.order)[0] === 'id' || Object.keys(item.order)[0] === 'symbol')
|
2174
2174
|
? {
|
2175
2175
|
connect: {
|
2176
2176
|
id: item.order.id
|
@@ -3517,7 +3517,7 @@ export const NewsArticleAssetSentiment = {
|
|
3517
3517
|
set: props.sentimentLabel
|
3518
3518
|
} : undefined,
|
3519
3519
|
news: props.news ?
|
3520
|
-
typeof props.news === 'object' && Object.keys(props.news).length === 1 && Object.keys(props.news)[0] === 'id'
|
3520
|
+
typeof props.news === 'object' && Object.keys(props.news).length === 1 && (Object.keys(props.news)[0] === 'id' || Object.keys(props.news)[0] === 'symbol')
|
3521
3521
|
? {
|
3522
3522
|
connect: {
|
3523
3523
|
id: props.news.id
|
@@ -3600,7 +3600,7 @@ export const NewsArticleAssetSentiment = {
|
|
3600
3600
|
}
|
3601
3601
|
} : undefined,
|
3602
3602
|
asset: props.asset ?
|
3603
|
-
typeof props.asset === 'object' && Object.keys(props.asset).length === 1 && Object.keys(props.asset)[0] === 'id'
|
3603
|
+
typeof props.asset === 'object' && Object.keys(props.asset).length === 1 && (Object.keys(props.asset)[0] === 'id' || Object.keys(props.asset)[0] === 'symbol')
|
3604
3604
|
? {
|
3605
3605
|
connect: {
|
3606
3606
|
id: props.asset.id
|
@@ -3787,7 +3787,7 @@ export const NewsArticleAssetSentiment = {
|
|
3787
3787
|
set: props.asset.bidPrice
|
3788
3788
|
} : undefined,
|
3789
3789
|
trades: props.asset.trades ?
|
3790
|
-
Array.isArray(props.asset.trades) && props.asset.trades.length > 0 && props.asset.trades.every((item) => typeof item === 'object' && 'id' in item && Object.keys(item).length === 1) ? {
|
3790
|
+
Array.isArray(props.asset.trades) && props.asset.trades.length > 0 && props.asset.trades.every((item) => typeof item === 'object' && ('id' in item || 'symbol' in item) && Object.keys(item).length === 1) ? {
|
3791
3791
|
connect: props.asset.trades.map((item) => ({
|
3792
3792
|
id: item.id
|
3793
3793
|
}))
|
@@ -3839,7 +3839,7 @@ export const NewsArticleAssetSentiment = {
|
|
3839
3839
|
set: item.status
|
3840
3840
|
} : undefined,
|
3841
3841
|
alpacaAccount: item.alpacaAccount ?
|
3842
|
-
typeof item.alpacaAccount === 'object' && Object.keys(item.alpacaAccount).length === 1 && Object.keys(item.alpacaAccount)[0] === 'id'
|
3842
|
+
typeof item.alpacaAccount === 'object' && Object.keys(item.alpacaAccount).length === 1 && (Object.keys(item.alpacaAccount)[0] === 'id' || Object.keys(item.alpacaAccount)[0] === 'symbol')
|
3843
3843
|
? {
|
3844
3844
|
connect: {
|
3845
3845
|
id: item.alpacaAccount.id
|
@@ -3903,7 +3903,7 @@ export const NewsArticleAssetSentiment = {
|
|
3903
3903
|
}
|
3904
3904
|
} : undefined,
|
3905
3905
|
actions: item.actions ?
|
3906
|
-
Array.isArray(item.actions) && item.actions.length > 0 && item.actions.every((item) => typeof item === 'object' && 'id' in item && Object.keys(item).length === 1) ? {
|
3906
|
+
Array.isArray(item.actions) && item.actions.length > 0 && item.actions.every((item) => typeof item === 'object' && ('id' in item || 'symbol' in item) && Object.keys(item).length === 1) ? {
|
3907
3907
|
connect: item.actions.map((item) => ({
|
3908
3908
|
id: item.id
|
3909
3909
|
}))
|
@@ -4032,7 +4032,7 @@ export const NewsArticleAssetSentiment = {
|
|
4032
4032
|
}))
|
4033
4033
|
} : undefined,
|
4034
4034
|
orders: props.asset.orders ?
|
4035
|
-
Array.isArray(props.asset.orders) && props.asset.orders.length > 0 && props.asset.orders.every((item) => typeof item === 'object' && 'id' in item && Object.keys(item).length === 1) ? {
|
4035
|
+
Array.isArray(props.asset.orders) && props.asset.orders.length > 0 && props.asset.orders.every((item) => typeof item === 'object' && ('id' in item || 'symbol' in item) && Object.keys(item).length === 1) ? {
|
4036
4036
|
connect: props.asset.orders.map((item) => ({
|
4037
4037
|
id: item.id
|
4038
4038
|
}))
|
@@ -4133,7 +4133,7 @@ export const NewsArticleAssetSentiment = {
|
|
4133
4133
|
set: item.takeProfitId
|
4134
4134
|
} : undefined,
|
4135
4135
|
stopLoss: item.stopLoss ?
|
4136
|
-
typeof item.stopLoss === 'object' && Object.keys(item.stopLoss).length === 1 && Object.keys(item.stopLoss)[0] === 'id'
|
4136
|
+
typeof item.stopLoss === 'object' && Object.keys(item.stopLoss).length === 1 && (Object.keys(item.stopLoss)[0] === 'id' || Object.keys(item.stopLoss)[0] === 'symbol')
|
4137
4137
|
? {
|
4138
4138
|
connect: {
|
4139
4139
|
id: item.stopLoss.id
|
@@ -4165,7 +4165,7 @@ export const NewsArticleAssetSentiment = {
|
|
4165
4165
|
}
|
4166
4166
|
} : undefined,
|
4167
4167
|
takeProfit: item.takeProfit ?
|
4168
|
-
typeof item.takeProfit === 'object' && Object.keys(item.takeProfit).length === 1 && Object.keys(item.takeProfit)[0] === 'id'
|
4168
|
+
typeof item.takeProfit === 'object' && Object.keys(item.takeProfit).length === 1 && (Object.keys(item.takeProfit)[0] === 'id' || Object.keys(item.takeProfit)[0] === 'symbol')
|
4169
4169
|
? {
|
4170
4170
|
connect: {
|
4171
4171
|
id: item.takeProfit.id
|
@@ -4197,7 +4197,7 @@ export const NewsArticleAssetSentiment = {
|
|
4197
4197
|
}
|
4198
4198
|
} : undefined,
|
4199
4199
|
alpacaAccount: item.alpacaAccount ?
|
4200
|
-
typeof item.alpacaAccount === 'object' && Object.keys(item.alpacaAccount).length === 1 && Object.keys(item.alpacaAccount)[0] === 'id'
|
4200
|
+
typeof item.alpacaAccount === 'object' && Object.keys(item.alpacaAccount).length === 1 && (Object.keys(item.alpacaAccount)[0] === 'id' || Object.keys(item.alpacaAccount)[0] === 'symbol')
|
4201
4201
|
? {
|
4202
4202
|
connect: {
|
4203
4203
|
id: item.alpacaAccount.id
|
@@ -4261,7 +4261,7 @@ export const NewsArticleAssetSentiment = {
|
|
4261
4261
|
}
|
4262
4262
|
} : undefined,
|
4263
4263
|
action: item.action ?
|
4264
|
-
typeof item.action === 'object' && Object.keys(item.action).length === 1 && Object.keys(item.action)[0] === 'id'
|
4264
|
+
typeof item.action === 'object' && Object.keys(item.action).length === 1 && (Object.keys(item.action)[0] === 'id' || Object.keys(item.action)[0] === 'symbol')
|
4265
4265
|
? {
|
4266
4266
|
connect: {
|
4267
4267
|
id: item.action.id
|
@@ -4321,7 +4321,7 @@ export const NewsArticleAssetSentiment = {
|
|
4321
4321
|
}
|
4322
4322
|
} : undefined,
|
4323
4323
|
contract: item.contract ?
|
4324
|
-
typeof item.contract === 'object' && Object.keys(item.contract).length === 1 && Object.keys(item.contract)[0] === 'id'
|
4324
|
+
typeof item.contract === 'object' && Object.keys(item.contract).length === 1 && (Object.keys(item.contract)[0] === 'id' || Object.keys(item.contract)[0] === 'symbol')
|
4325
4325
|
? {
|
4326
4326
|
connect: {
|
4327
4327
|
id: item.contract.id
|
@@ -4602,7 +4602,7 @@ export const NewsArticleAssetSentiment = {
|
|
4602
4602
|
}))
|
4603
4603
|
} : undefined,
|
4604
4604
|
positions: props.asset.positions ?
|
4605
|
-
Array.isArray(props.asset.positions) && props.asset.positions.length > 0 && props.asset.positions.every((item) => typeof item === 'object' && 'id' in item && Object.keys(item).length === 1) ? {
|
4605
|
+
Array.isArray(props.asset.positions) && props.asset.positions.length > 0 && props.asset.positions.every((item) => typeof item === 'object' && ('id' in item || 'symbol' in item) && Object.keys(item).length === 1) ? {
|
4606
4606
|
connect: props.asset.positions.map((item) => ({
|
4607
4607
|
id: item.id
|
4608
4608
|
}))
|
@@ -4669,7 +4669,7 @@ export const NewsArticleAssetSentiment = {
|
|
4669
4669
|
set: item.closed
|
4670
4670
|
} : undefined,
|
4671
4671
|
alpacaAccount: item.alpacaAccount ?
|
4672
|
-
typeof item.alpacaAccount === 'object' && Object.keys(item.alpacaAccount).length === 1 && Object.keys(item.alpacaAccount)[0] === 'id'
|
4672
|
+
typeof item.alpacaAccount === 'object' && Object.keys(item.alpacaAccount).length === 1 && (Object.keys(item.alpacaAccount)[0] === 'id' || Object.keys(item.alpacaAccount)[0] === 'symbol')
|
4673
4673
|
? {
|
4674
4674
|
connect: {
|
4675
4675
|
id: item.alpacaAccount.id
|
@@ -4780,7 +4780,7 @@ export const NewsArticleAssetSentiment = {
|
|
4780
4780
|
}))
|
4781
4781
|
} : undefined,
|
4782
4782
|
contracts: props.asset.contracts ?
|
4783
|
-
Array.isArray(props.asset.contracts) && props.asset.contracts.length > 0 && props.asset.contracts.every((item) => typeof item === 'object' && 'id' in item && Object.keys(item).length === 1) ? {
|
4783
|
+
Array.isArray(props.asset.contracts) && props.asset.contracts.length > 0 && props.asset.contracts.every((item) => typeof item === 'object' && ('id' in item || 'symbol' in item) && Object.keys(item).length === 1) ? {
|
4784
4784
|
connect: props.asset.contracts.map((item) => ({
|
4785
4785
|
id: item.id
|
4786
4786
|
}))
|
@@ -4867,7 +4867,7 @@ export const NewsArticleAssetSentiment = {
|
|
4867
4867
|
set: item.orderId
|
4868
4868
|
} : undefined,
|
4869
4869
|
deliverables: item.deliverables ?
|
4870
|
-
Array.isArray(item.deliverables) && item.deliverables.length > 0 && item.deliverables.every((item) => typeof item === 'object' && 'id' in item && Object.keys(item).length === 1) ? {
|
4870
|
+
Array.isArray(item.deliverables) && item.deliverables.length > 0 && item.deliverables.every((item) => typeof item === 'object' && ('id' in item || 'symbol' in item) && Object.keys(item).length === 1) ? {
|
4871
4871
|
connect: item.deliverables.map((item) => ({
|
4872
4872
|
id: item.id
|
4873
4873
|
}))
|
@@ -4926,7 +4926,7 @@ export const NewsArticleAssetSentiment = {
|
|
4926
4926
|
}))
|
4927
4927
|
} : undefined,
|
4928
4928
|
order: item.order ?
|
4929
|
-
typeof item.order === 'object' && Object.keys(item.order).length === 1 && Object.keys(item.order)[0] === 'id'
|
4929
|
+
typeof item.order === 'object' && Object.keys(item.order).length === 1 && (Object.keys(item.order)[0] === 'id' || Object.keys(item.order)[0] === 'symbol')
|
4930
4930
|
? {
|
4931
4931
|
connect: {
|
4932
4932
|
id: item.order.id
|
@@ -5724,7 +5724,7 @@ export const NewsArticleAssetSentiment = {
|
|
5724
5724
|
set: prop.sentimentLabel
|
5725
5725
|
} : undefined,
|
5726
5726
|
news: prop.news ?
|
5727
|
-
typeof prop.news === 'object' && Object.keys(prop.news).length === 1 && Object.keys(prop.news)[0] === 'id'
|
5727
|
+
typeof prop.news === 'object' && Object.keys(prop.news).length === 1 && (Object.keys(prop.news)[0] === 'id' || Object.keys(prop.news)[0] === 'symbol')
|
5728
5728
|
? {
|
5729
5729
|
connect: {
|
5730
5730
|
id: prop.news.id
|
@@ -5807,7 +5807,7 @@ export const NewsArticleAssetSentiment = {
|
|
5807
5807
|
}
|
5808
5808
|
} : undefined,
|
5809
5809
|
asset: prop.asset ?
|
5810
|
-
typeof prop.asset === 'object' && Object.keys(prop.asset).length === 1 && Object.keys(prop.asset)[0] === 'id'
|
5810
|
+
typeof prop.asset === 'object' && Object.keys(prop.asset).length === 1 && (Object.keys(prop.asset)[0] === 'id' || Object.keys(prop.asset)[0] === 'symbol')
|
5811
5811
|
? {
|
5812
5812
|
connect: {
|
5813
5813
|
id: prop.asset.id
|
@@ -5994,7 +5994,7 @@ export const NewsArticleAssetSentiment = {
|
|
5994
5994
|
set: prop.asset.bidPrice
|
5995
5995
|
} : undefined,
|
5996
5996
|
trades: prop.asset.trades ?
|
5997
|
-
Array.isArray(prop.asset.trades) && prop.asset.trades.length > 0 && prop.asset.trades.every((item) => typeof item === 'object' && 'id' in item && Object.keys(item).length === 1) ? {
|
5997
|
+
Array.isArray(prop.asset.trades) && prop.asset.trades.length > 0 && prop.asset.trades.every((item) => typeof item === 'object' && ('id' in item || 'symbol' in item) && Object.keys(item).length === 1) ? {
|
5998
5998
|
connect: prop.asset.trades.map((item) => ({
|
5999
5999
|
id: item.id
|
6000
6000
|
}))
|
@@ -6046,7 +6046,7 @@ export const NewsArticleAssetSentiment = {
|
|
6046
6046
|
set: item.status
|
6047
6047
|
} : undefined,
|
6048
6048
|
alpacaAccount: item.alpacaAccount ?
|
6049
|
-
typeof item.alpacaAccount === 'object' && Object.keys(item.alpacaAccount).length === 1 && Object.keys(item.alpacaAccount)[0] === 'id'
|
6049
|
+
typeof item.alpacaAccount === 'object' && Object.keys(item.alpacaAccount).length === 1 && (Object.keys(item.alpacaAccount)[0] === 'id' || Object.keys(item.alpacaAccount)[0] === 'symbol')
|
6050
6050
|
? {
|
6051
6051
|
connect: {
|
6052
6052
|
id: item.alpacaAccount.id
|
@@ -6110,7 +6110,7 @@ export const NewsArticleAssetSentiment = {
|
|
6110
6110
|
}
|
6111
6111
|
} : undefined,
|
6112
6112
|
actions: item.actions ?
|
6113
|
-
Array.isArray(item.actions) && item.actions.length > 0 && item.actions.every((item) => typeof item === 'object' && 'id' in item && Object.keys(item).length === 1) ? {
|
6113
|
+
Array.isArray(item.actions) && item.actions.length > 0 && item.actions.every((item) => typeof item === 'object' && ('id' in item || 'symbol' in item) && Object.keys(item).length === 1) ? {
|
6114
6114
|
connect: item.actions.map((item) => ({
|
6115
6115
|
id: item.id
|
6116
6116
|
}))
|
@@ -6239,7 +6239,7 @@ export const NewsArticleAssetSentiment = {
|
|
6239
6239
|
}))
|
6240
6240
|
} : undefined,
|
6241
6241
|
orders: prop.asset.orders ?
|
6242
|
-
Array.isArray(prop.asset.orders) && prop.asset.orders.length > 0 && prop.asset.orders.every((item) => typeof item === 'object' && 'id' in item && Object.keys(item).length === 1) ? {
|
6242
|
+
Array.isArray(prop.asset.orders) && prop.asset.orders.length > 0 && prop.asset.orders.every((item) => typeof item === 'object' && ('id' in item || 'symbol' in item) && Object.keys(item).length === 1) ? {
|
6243
6243
|
connect: prop.asset.orders.map((item) => ({
|
6244
6244
|
id: item.id
|
6245
6245
|
}))
|
@@ -6340,7 +6340,7 @@ export const NewsArticleAssetSentiment = {
|
|
6340
6340
|
set: item.takeProfitId
|
6341
6341
|
} : undefined,
|
6342
6342
|
stopLoss: item.stopLoss ?
|
6343
|
-
typeof item.stopLoss === 'object' && Object.keys(item.stopLoss).length === 1 && Object.keys(item.stopLoss)[0] === 'id'
|
6343
|
+
typeof item.stopLoss === 'object' && Object.keys(item.stopLoss).length === 1 && (Object.keys(item.stopLoss)[0] === 'id' || Object.keys(item.stopLoss)[0] === 'symbol')
|
6344
6344
|
? {
|
6345
6345
|
connect: {
|
6346
6346
|
id: item.stopLoss.id
|
@@ -6372,7 +6372,7 @@ export const NewsArticleAssetSentiment = {
|
|
6372
6372
|
}
|
6373
6373
|
} : undefined,
|
6374
6374
|
takeProfit: item.takeProfit ?
|
6375
|
-
typeof item.takeProfit === 'object' && Object.keys(item.takeProfit).length === 1 && Object.keys(item.takeProfit)[0] === 'id'
|
6375
|
+
typeof item.takeProfit === 'object' && Object.keys(item.takeProfit).length === 1 && (Object.keys(item.takeProfit)[0] === 'id' || Object.keys(item.takeProfit)[0] === 'symbol')
|
6376
6376
|
? {
|
6377
6377
|
connect: {
|
6378
6378
|
id: item.takeProfit.id
|
@@ -6404,7 +6404,7 @@ export const NewsArticleAssetSentiment = {
|
|
6404
6404
|
}
|
6405
6405
|
} : undefined,
|
6406
6406
|
alpacaAccount: item.alpacaAccount ?
|
6407
|
-
typeof item.alpacaAccount === 'object' && Object.keys(item.alpacaAccount).length === 1 && Object.keys(item.alpacaAccount)[0] === 'id'
|
6407
|
+
typeof item.alpacaAccount === 'object' && Object.keys(item.alpacaAccount).length === 1 && (Object.keys(item.alpacaAccount)[0] === 'id' || Object.keys(item.alpacaAccount)[0] === 'symbol')
|
6408
6408
|
? {
|
6409
6409
|
connect: {
|
6410
6410
|
id: item.alpacaAccount.id
|
@@ -6468,7 +6468,7 @@ export const NewsArticleAssetSentiment = {
|
|
6468
6468
|
}
|
6469
6469
|
} : undefined,
|
6470
6470
|
action: item.action ?
|
6471
|
-
typeof item.action === 'object' && Object.keys(item.action).length === 1 && Object.keys(item.action)[0] === 'id'
|
6471
|
+
typeof item.action === 'object' && Object.keys(item.action).length === 1 && (Object.keys(item.action)[0] === 'id' || Object.keys(item.action)[0] === 'symbol')
|
6472
6472
|
? {
|
6473
6473
|
connect: {
|
6474
6474
|
id: item.action.id
|
@@ -6528,7 +6528,7 @@ export const NewsArticleAssetSentiment = {
|
|
6528
6528
|
}
|
6529
6529
|
} : undefined,
|
6530
6530
|
contract: item.contract ?
|
6531
|
-
typeof item.contract === 'object' && Object.keys(item.contract).length === 1 && Object.keys(item.contract)[0] === 'id'
|
6531
|
+
typeof item.contract === 'object' && Object.keys(item.contract).length === 1 && (Object.keys(item.contract)[0] === 'id' || Object.keys(item.contract)[0] === 'symbol')
|
6532
6532
|
? {
|
6533
6533
|
connect: {
|
6534
6534
|
id: item.contract.id
|
@@ -6809,7 +6809,7 @@ export const NewsArticleAssetSentiment = {
|
|
6809
6809
|
}))
|
6810
6810
|
} : undefined,
|
6811
6811
|
positions: prop.asset.positions ?
|
6812
|
-
Array.isArray(prop.asset.positions) && prop.asset.positions.length > 0 && prop.asset.positions.every((item) => typeof item === 'object' && 'id' in item && Object.keys(item).length === 1) ? {
|
6812
|
+
Array.isArray(prop.asset.positions) && prop.asset.positions.length > 0 && prop.asset.positions.every((item) => typeof item === 'object' && ('id' in item || 'symbol' in item) && Object.keys(item).length === 1) ? {
|
6813
6813
|
connect: prop.asset.positions.map((item) => ({
|
6814
6814
|
id: item.id
|
6815
6815
|
}))
|
@@ -6876,7 +6876,7 @@ export const NewsArticleAssetSentiment = {
|
|
6876
6876
|
set: item.closed
|
6877
6877
|
} : undefined,
|
6878
6878
|
alpacaAccount: item.alpacaAccount ?
|
6879
|
-
typeof item.alpacaAccount === 'object' && Object.keys(item.alpacaAccount).length === 1 && Object.keys(item.alpacaAccount)[0] === 'id'
|
6879
|
+
typeof item.alpacaAccount === 'object' && Object.keys(item.alpacaAccount).length === 1 && (Object.keys(item.alpacaAccount)[0] === 'id' || Object.keys(item.alpacaAccount)[0] === 'symbol')
|
6880
6880
|
? {
|
6881
6881
|
connect: {
|
6882
6882
|
id: item.alpacaAccount.id
|
@@ -6987,7 +6987,7 @@ export const NewsArticleAssetSentiment = {
|
|
6987
6987
|
}))
|
6988
6988
|
} : undefined,
|
6989
6989
|
contracts: prop.asset.contracts ?
|
6990
|
-
Array.isArray(prop.asset.contracts) && prop.asset.contracts.length > 0 && prop.asset.contracts.every((item) => typeof item === 'object' && 'id' in item && Object.keys(item).length === 1) ? {
|
6990
|
+
Array.isArray(prop.asset.contracts) && prop.asset.contracts.length > 0 && prop.asset.contracts.every((item) => typeof item === 'object' && ('id' in item || 'symbol' in item) && Object.keys(item).length === 1) ? {
|
6991
6991
|
connect: prop.asset.contracts.map((item) => ({
|
6992
6992
|
id: item.id
|
6993
6993
|
}))
|
@@ -7074,7 +7074,7 @@ export const NewsArticleAssetSentiment = {
|
|
7074
7074
|
set: item.orderId
|
7075
7075
|
} : undefined,
|
7076
7076
|
deliverables: item.deliverables ?
|
7077
|
-
Array.isArray(item.deliverables) && item.deliverables.length > 0 && item.deliverables.every((item) => typeof item === 'object' && 'id' in item && Object.keys(item).length === 1) ? {
|
7077
|
+
Array.isArray(item.deliverables) && item.deliverables.length > 0 && item.deliverables.every((item) => typeof item === 'object' && ('id' in item || 'symbol' in item) && Object.keys(item).length === 1) ? {
|
7078
7078
|
connect: item.deliverables.map((item) => ({
|
7079
7079
|
id: item.id
|
7080
7080
|
}))
|
@@ -7133,7 +7133,7 @@ export const NewsArticleAssetSentiment = {
|
|
7133
7133
|
}))
|
7134
7134
|
} : undefined,
|
7135
7135
|
order: item.order ?
|
7136
|
-
typeof item.order === 'object' && Object.keys(item.order).length === 1 && Object.keys(item.order)[0] === 'id'
|
7136
|
+
typeof item.order === 'object' && Object.keys(item.order).length === 1 && (Object.keys(item.order)[0] === 'id' || Object.keys(item.order)[0] === 'symbol')
|
7137
7137
|
? {
|
7138
7138
|
connect: {
|
7139
7139
|
id: item.order.id
|