@odatano/core 0.3.1

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.
Files changed (98) hide show
  1. package/LICENSE +201 -0
  2. package/README.md +212 -0
  3. package/cds-plugin.js +5 -0
  4. package/config/preview/cardano-node/alonzo-genesis.json +196 -0
  5. package/config/preview/cardano-node/byron-genesis.json +117 -0
  6. package/config/preview/cardano-node/config.json +118 -0
  7. package/config/preview/cardano-node/conway-genesis.json +297 -0
  8. package/config/preview/cardano-node/shelley-genesis.json +68 -0
  9. package/config/preview/cardano-node/topology.json +19 -0
  10. package/db/schema.cds +1318 -0
  11. package/package.json +125 -0
  12. package/src/index.d.ts.map +1 -0
  13. package/src/index.js +96 -0
  14. package/src/index.js.map +1 -0
  15. package/src/plugin.d.ts.map +1 -0
  16. package/src/plugin.js +92 -0
  17. package/src/plugin.js.map +1 -0
  18. package/srv/blockchain/backends/blockfrost-backend.d.ts.map +1 -0
  19. package/srv/blockchain/backends/blockfrost-backend.js +398 -0
  20. package/srv/blockchain/backends/blockfrost-backend.js.map +1 -0
  21. package/srv/blockchain/backends/cardano-backend.d.ts.map +1 -0
  22. package/srv/blockchain/backends/cardano-backend.js +12 -0
  23. package/srv/blockchain/backends/cardano-backend.js.map +1 -0
  24. package/srv/blockchain/backends/koios-backend.d.ts.map +1 -0
  25. package/srv/blockchain/backends/koios-backend.js +537 -0
  26. package/srv/blockchain/backends/koios-backend.js.map +1 -0
  27. package/srv/blockchain/backends/ogmios-backend.d.ts.map +1 -0
  28. package/srv/blockchain/backends/ogmios-backend.js +516 -0
  29. package/srv/blockchain/backends/ogmios-backend.js.map +1 -0
  30. package/srv/blockchain/cardano-client.d.ts.map +1 -0
  31. package/srv/blockchain/cardano-client.js +377 -0
  32. package/srv/blockchain/cardano-client.js.map +1 -0
  33. package/srv/blockchain/cardano-indexer.d.ts.map +1 -0
  34. package/srv/blockchain/cardano-indexer.js +542 -0
  35. package/srv/blockchain/cardano-indexer.js.map +1 -0
  36. package/srv/blockchain/cardano-tx-builder.d.ts.map +1 -0
  37. package/srv/blockchain/cardano-tx-builder.js +232 -0
  38. package/srv/blockchain/cardano-tx-builder.js.map +1 -0
  39. package/srv/blockchain/circuit-breaker.d.ts.map +1 -0
  40. package/srv/blockchain/circuit-breaker.js +110 -0
  41. package/srv/blockchain/circuit-breaker.js.map +1 -0
  42. package/srv/blockchain/signing/external-signer.d.ts.map +1 -0
  43. package/srv/blockchain/signing/external-signer.js +302 -0
  44. package/srv/blockchain/signing/external-signer.js.map +1 -0
  45. package/srv/blockchain/signing/signature-verifier.d.ts.map +1 -0
  46. package/srv/blockchain/signing/signature-verifier.js +249 -0
  47. package/srv/blockchain/signing/signature-verifier.js.map +1 -0
  48. package/srv/blockchain/transaction-building/buildooor-tx.d.ts.map +1 -0
  49. package/srv/blockchain/transaction-building/buildooor-tx.js +636 -0
  50. package/srv/blockchain/transaction-building/buildooor-tx.js.map +1 -0
  51. package/srv/blockchain/transaction-building/cardano-tx.d.ts.map +1 -0
  52. package/srv/blockchain/transaction-building/cardano-tx.js +3 -0
  53. package/srv/blockchain/transaction-building/cardano-tx.js.map +1 -0
  54. package/srv/blockchain/transaction-building/csl-tx.d.ts.map +1 -0
  55. package/srv/blockchain/transaction-building/csl-tx.js +766 -0
  56. package/srv/blockchain/transaction-building/csl-tx.js.map +1 -0
  57. package/srv/blockchain/transaction-building/tx-builder-registry.d.ts.map +1 -0
  58. package/srv/blockchain/transaction-building/tx-builder-registry.js +67 -0
  59. package/srv/blockchain/transaction-building/tx-builder-registry.js.map +1 -0
  60. package/srv/cardano-service.cds +179 -0
  61. package/srv/cardano-service.d.ts.map +1 -0
  62. package/srv/cardano-service.js +227 -0
  63. package/srv/cardano-service.js.map +1 -0
  64. package/srv/cardano-tx-service.cds +298 -0
  65. package/srv/cardano-tx-service.d.ts.map +1 -0
  66. package/srv/cardano-tx-service.js +646 -0
  67. package/srv/cardano-tx-service.js.map +1 -0
  68. package/srv/cardano-ui.cds +2949 -0
  69. package/srv/server.d.ts.map +1 -0
  70. package/srv/server.js +212 -0
  71. package/srv/server.js.map +1 -0
  72. package/srv/utils/backend-request-handler.d.ts.map +1 -0
  73. package/srv/utils/backend-request-handler.js +47 -0
  74. package/srv/utils/backend-request-handler.js.map +1 -0
  75. package/srv/utils/const.d.ts.map +1 -0
  76. package/srv/utils/const.js +86 -0
  77. package/srv/utils/const.js.map +1 -0
  78. package/srv/utils/error-codes.d.ts.map +1 -0
  79. package/srv/utils/error-codes.js +49 -0
  80. package/srv/utils/error-codes.js.map +1 -0
  81. package/srv/utils/errors.d.ts.map +1 -0
  82. package/srv/utils/errors.js +389 -0
  83. package/srv/utils/errors.js.map +1 -0
  84. package/srv/utils/mappers.d.ts.map +1 -0
  85. package/srv/utils/mappers.js +723 -0
  86. package/srv/utils/mappers.js.map +1 -0
  87. package/srv/utils/signing-helper.d.ts.map +1 -0
  88. package/srv/utils/signing-helper.js +128 -0
  89. package/srv/utils/signing-helper.js.map +1 -0
  90. package/srv/utils/tx-build-helper.d.ts.map +1 -0
  91. package/srv/utils/tx-build-helper.js +135 -0
  92. package/srv/utils/tx-build-helper.js.map +1 -0
  93. package/srv/utils/types.d.ts.map +1 -0
  94. package/srv/utils/types.js +36 -0
  95. package/srv/utils/types.js.map +1 -0
  96. package/srv/utils/validators.d.ts.map +1 -0
  97. package/srv/utils/validators.js +382 -0
  98. package/srv/utils/validators.js.map +1 -0
@@ -0,0 +1,2949 @@
1
+ using {CardanoODataService as srv} from './cardano-service';
2
+ using {CardanoTransactionService as txsrv} from './cardano-tx-service';
3
+
4
+ // ============================================================================
5
+ // Annotations for SAP Fiori Elements UI
6
+ // ============================================================================
7
+
8
+ // ----------------------------------------------------------------------------
9
+ // NetworkInformation
10
+ // ----------------------------------------------------------------------------
11
+ annotate srv.NetworkInformation with @(
12
+ UI.HeaderInfo : {
13
+ TypeName : 'Network Information',
14
+ TypeNamePlural: 'Network Information',
15
+ Title : {Value: network}
16
+ },
17
+
18
+ UI.SelectionFields : [network],
19
+
20
+ UI.LineItem : [
21
+ {
22
+ Value: network,
23
+ Label: 'Network'
24
+ },
25
+ {
26
+ Value: maxSupply,
27
+ Label: 'Max Supply'
28
+ },
29
+ {
30
+ Value: totalSupply,
31
+ Label: 'Total Supply'
32
+ },
33
+ {
34
+ Value: circulatingSupply,
35
+ Label: 'Circulating Supply'
36
+ },
37
+ {
38
+ Value: lockedSupply,
39
+ Label: 'Locked Supply'
40
+ },
41
+ {
42
+ Value: treasurySupply,
43
+ Label: 'Treasury Supply'
44
+ },
45
+ {
46
+ Value: reservesSupply,
47
+ Label: 'Reserves Supply'
48
+ },
49
+ {
50
+ Value: liveStake,
51
+ Label: 'Live Stake'
52
+ },
53
+ {
54
+ Value: activeStake,
55
+ Label: 'Active Stake'
56
+ },
57
+ {
58
+ $Type : 'UI.DataFieldForAction',
59
+ Action: 'CardanoODataService.EntityContainer/GetNetworkInformation',
60
+ Label : 'Refresh Network Info'
61
+ }
62
+ ],
63
+
64
+ UI.Identification : [{
65
+ $Type : 'UI.DataFieldForAction',
66
+ Action: 'CardanoODataService.EntityContainer/GetNetworkInformation',
67
+ Label : 'Refresh Network Info'
68
+ }],
69
+
70
+ UI.HeaderFacets : [
71
+ {
72
+ $Type : 'UI.ReferenceFacet',
73
+ Label : 'Total Supply',
74
+ Target: '@UI.DataPoint#TotalSupply'
75
+ },
76
+ {
77
+ $Type : 'UI.ReferenceFacet',
78
+ Label : 'Circulating Supply',
79
+ Target: '@UI.DataPoint#Circulating'
80
+ },
81
+ {
82
+ $Type : 'UI.ReferenceFacet',
83
+ Label : 'Live Stake',
84
+ Target: '@UI.DataPoint#LiveStake'
85
+ }
86
+ ],
87
+
88
+ UI.DataPoint #TotalSupply: {
89
+ Value: totalSupply,
90
+ Title: 'Total Supply'
91
+ },
92
+ UI.DataPoint #Circulating: {
93
+ Value: circulatingSupply,
94
+ Title: 'Circulating Supply'
95
+ },
96
+ UI.DataPoint #LiveStake : {
97
+ Value: liveStake,
98
+ Title: 'Live Stake'
99
+ },
100
+
101
+ UI.Facets : [
102
+ {
103
+ $Type : 'UI.ReferenceFacet',
104
+ Label : 'Overview',
105
+ Target: '@UI.FieldGroup#Overview'
106
+ },
107
+ {
108
+ $Type : 'UI.ReferenceFacet',
109
+ Label : 'Supply',
110
+ Target: '@UI.FieldGroup#Supply'
111
+ },
112
+ {
113
+ $Type : 'UI.ReferenceFacet',
114
+ Label : 'Stake',
115
+ Target: '@UI.FieldGroup#Stake'
116
+ }
117
+ ],
118
+
119
+ UI.FieldGroup #Overview : {Data: [{
120
+ $Type: 'UI.DataField',
121
+ Value: network,
122
+ Label: 'Network'
123
+ }]},
124
+
125
+ UI.FieldGroup #Supply : {Data: [
126
+ {
127
+ $Type: 'UI.DataField',
128
+ Value: maxSupply,
129
+ Label: 'Max Supply'
130
+ },
131
+ {
132
+ $Type: 'UI.DataField',
133
+ Value: totalSupply,
134
+ Label: 'Total Supply'
135
+ },
136
+ {
137
+ $Type: 'UI.DataField',
138
+ Value: circulatingSupply,
139
+ Label: 'Circulating Supply'
140
+ },
141
+ {
142
+ $Type: 'UI.DataField',
143
+ Value: lockedSupply,
144
+ Label: 'Locked Supply'
145
+ },
146
+ {
147
+ $Type: 'UI.DataField',
148
+ Value: treasurySupply,
149
+ Label: 'Treasury Supply'
150
+ },
151
+ {
152
+ $Type: 'UI.DataField',
153
+ Value: reservesSupply,
154
+ Label: 'Reserves Supply'
155
+ }
156
+ ]},
157
+
158
+ UI.FieldGroup #Stake : {Data: [
159
+ {
160
+ $Type: 'UI.DataField',
161
+ Value: liveStake,
162
+ Label: 'Live Stake'
163
+ },
164
+ {
165
+ $Type: 'UI.DataField',
166
+ Value: activeStake,
167
+ Label: 'Active Stake'
168
+ }
169
+ ]}
170
+ );
171
+
172
+
173
+ // ----------------------------------------------------------------------------
174
+ // Blocks
175
+ // ----------------------------------------------------------------------------
176
+ annotate srv.Blocks with @(
177
+ UI.HeaderInfo : {
178
+ TypeName : 'Block',
179
+ TypeNamePlural: 'Blocks',
180
+ Title : {Value: hash}
181
+ },
182
+
183
+ UI.SelectionFields : [
184
+ height,
185
+ epochNumber
186
+ ],
187
+
188
+ UI.LineItem : [
189
+ {
190
+ Value: hash,
191
+ Label: 'Hash'
192
+ },
193
+ {
194
+ Value: time,
195
+ Label: 'Time'
196
+ },
197
+ {
198
+ Value: height,
199
+ Label: 'Height'
200
+ },
201
+ {
202
+ Value: slotLeader,
203
+ Label: 'Slot Leader'
204
+ },
205
+ {
206
+ Value: epochNumber,
207
+ Label: 'Epoch Number'
208
+ },
209
+ {
210
+ Value: epochSlot,
211
+ Label: 'Epoch Slot'
212
+ },
213
+ {
214
+ Value: size,
215
+ Label: 'Size'
216
+ },
217
+ {
218
+ Value: txCount,
219
+ Label: 'Tx Count'
220
+ },
221
+ {
222
+ Value: fees,
223
+ Label: 'Fees'
224
+ },
225
+ {
226
+ $Type : 'UI.DataFieldForAction',
227
+ Action: 'CardanoODataService.EntityContainer/GetBlockByHash',
228
+ Label : 'Get Block by Hash'
229
+ }
230
+ ],
231
+
232
+ UI.Identification : [{
233
+ $Type : 'UI.DataFieldForAction',
234
+ Action: 'CardanoODataService.EntityContainer/GetBlockByHash',
235
+ Label : 'Get Block by Hash'
236
+ }],
237
+
238
+ UI.HeaderFacets : [
239
+ {
240
+ $Type : 'UI.ReferenceFacet',
241
+ Label : 'Height',
242
+ Target: '@UI.DataPoint#Height'
243
+ },
244
+ {
245
+ $Type : 'UI.ReferenceFacet',
246
+ Label : 'Tx Count',
247
+ Target: '@UI.DataPoint#TxCount'
248
+ },
249
+ {
250
+ $Type : 'UI.ReferenceFacet',
251
+ Label : 'Fees',
252
+ Target: '@UI.DataPoint#Fees'
253
+ }
254
+ ],
255
+
256
+ UI.DataPoint #Height : {
257
+ Value: height,
258
+ Title: 'Height'
259
+ },
260
+ UI.DataPoint #TxCount : {
261
+ Value: txCount,
262
+ Title: 'Tx Count'
263
+ },
264
+ UI.DataPoint #Fees : {
265
+ Value: fees,
266
+ Title: 'Fees'
267
+ },
268
+
269
+ UI.Facets : [
270
+ {
271
+ $Type : 'UI.ReferenceFacet',
272
+ Label : 'Overview',
273
+ Target: '@UI.FieldGroup#Overview'
274
+ },
275
+ {
276
+ $Type : 'UI.ReferenceFacet',
277
+ Label : 'Epoch',
278
+ Target: '@UI.FieldGroup#Epoch'
279
+ }
280
+ ],
281
+
282
+ UI.FieldGroup #Overview: {Data: [
283
+ {
284
+ $Type: 'UI.DataField',
285
+ Value: hash,
286
+ Label: 'Hash'
287
+ },
288
+ {
289
+ $Type: 'UI.DataField',
290
+ Value: time,
291
+ Label: 'Time'
292
+ },
293
+ {
294
+ $Type: 'UI.DataField',
295
+ Value: height,
296
+ Label: 'Height'
297
+ },
298
+ {
299
+ $Type: 'UI.DataField',
300
+ Value: slotLeader,
301
+ Label: 'Slot Leader'
302
+ },
303
+ {
304
+ $Type: 'UI.DataField',
305
+ Value: size,
306
+ Label: 'Size'
307
+ },
308
+ {
309
+ $Type: 'UI.DataField',
310
+ Value: txCount,
311
+ Label: 'Tx Count'
312
+ },
313
+ {
314
+ $Type: 'UI.DataField',
315
+ Value: fees,
316
+ Label: 'Fees'
317
+ }
318
+ ]},
319
+
320
+ UI.FieldGroup #Epoch : {Data: [
321
+ {
322
+ $Type: 'UI.DataField',
323
+ Value: epochNumber,
324
+ Label: 'Epoch Number'
325
+ },
326
+ {
327
+ $Type: 'UI.DataField',
328
+ Value: epochSlot,
329
+ Label: 'Epoch Slot'
330
+ }
331
+ ]}
332
+ );
333
+
334
+ // ----------------------------------------------------------------------------
335
+ // Epochs
336
+ // ----------------------------------------------------------------------------
337
+ annotate srv.Epochs with @(
338
+ UI.HeaderInfo : {
339
+ TypeName : 'Epoch',
340
+ TypeNamePlural: 'Epochs',
341
+ Title : {Value: epoch}
342
+ },
343
+
344
+ UI.SelectionFields : [epoch],
345
+
346
+ UI.LineItem : [
347
+ {
348
+ Value: epoch,
349
+ Label: 'Epoch'
350
+ },
351
+ {
352
+ Value: startTime,
353
+ Label: 'Start Time'
354
+ },
355
+ {
356
+ Value: endTime,
357
+ Label: 'End Time'
358
+ },
359
+ {
360
+ Value: blockCount,
361
+ Label: 'Block Count'
362
+ },
363
+ {
364
+ Value: txCount,
365
+ Label: 'Tx Count'
366
+ },
367
+ {
368
+ Value: fees,
369
+ Label: 'Fees'
370
+ },
371
+ {
372
+ Value: activeStake,
373
+ Label: 'Active Stake'
374
+ },
375
+ {
376
+ $Type : 'UI.DataFieldForAction',
377
+ Action: 'CardanoODataService.EntityContainer/GetEpochByNumber',
378
+ Label : 'Get Epoch by Number'
379
+ }
380
+ ],
381
+
382
+ UI.Identification : [{
383
+ $Type : 'UI.DataFieldForAction',
384
+ Action: 'CardanoODataService.EntityContainer/GetEpochByNumber',
385
+ Label : 'Get Epoch by Number'
386
+ }],
387
+
388
+ UI.HeaderFacets : [
389
+ {
390
+ $Type : 'UI.ReferenceFacet',
391
+ Label : 'Blocks',
392
+ Target: '@UI.DataPoint#BlockCount'
393
+ },
394
+ {
395
+ $Type : 'UI.ReferenceFacet',
396
+ Label : 'Txs',
397
+ Target: '@UI.DataPoint#TxCount'
398
+ },
399
+ {
400
+ $Type : 'UI.ReferenceFacet',
401
+ Label : 'Fees',
402
+ Target: '@UI.DataPoint#Fees'
403
+ }
404
+ ],
405
+
406
+ UI.DataPoint #BlockCount: {
407
+ Value: blockCount,
408
+ Title: 'Block Count'
409
+ },
410
+ UI.DataPoint #TxCount : {
411
+ Value: txCount,
412
+ Title: 'Tx Count'
413
+ },
414
+ UI.DataPoint #Fees : {
415
+ Value: fees,
416
+ Title: 'Fees'
417
+ },
418
+
419
+ UI.Facets : [
420
+ {
421
+ $Type : 'UI.ReferenceFacet',
422
+ Label : 'Overview',
423
+ Target: '@UI.FieldGroup#Overview'
424
+ },
425
+ {
426
+ $Type : 'UI.ReferenceFacet',
427
+ Label : 'Stake',
428
+ Target: '@UI.FieldGroup#Stake'
429
+ }
430
+ ],
431
+
432
+ UI.FieldGroup #Overview : {Data: [
433
+ {
434
+ $Type: 'UI.DataField',
435
+ Value: epoch,
436
+ Label: 'Epoch'
437
+ },
438
+ {
439
+ $Type: 'UI.DataField',
440
+ Value: startTime,
441
+ Label: 'Start Time'
442
+ },
443
+ {
444
+ $Type: 'UI.DataField',
445
+ Value: endTime,
446
+ Label: 'End Time'
447
+ },
448
+ {
449
+ $Type: 'UI.DataField',
450
+ Value: blockCount,
451
+ Label: 'Block Count'
452
+ },
453
+ {
454
+ $Type: 'UI.DataField',
455
+ Value: txCount,
456
+ Label: 'Tx Count'
457
+ },
458
+ {
459
+ $Type: 'UI.DataField',
460
+ Value: fees,
461
+ Label: 'Fees'
462
+ }
463
+ ]},
464
+
465
+ UI.FieldGroup #Stake : {Data: [{
466
+ $Type: 'UI.DataField',
467
+ Value: activeStake,
468
+ Label: 'Active Stake'
469
+ }]}
470
+ );
471
+
472
+ // ----------------------------------------------------------------------------
473
+ // Pools
474
+ // ----------------------------------------------------------------------------
475
+ annotate srv.Pools with @(
476
+ UI.HeaderInfo : {
477
+ TypeName : 'Pool',
478
+ TypeNamePlural: 'Pools',
479
+ Title : {Value: poolId}
480
+ },
481
+
482
+ UI.SelectionFields : [poolId],
483
+
484
+ UI.LineItem : [
485
+ {
486
+ Value: poolId,
487
+ Label: 'Pool ID'
488
+ },
489
+ {
490
+ Value: vrfKeyHash,
491
+ Label: 'VRF Key Hash'
492
+ },
493
+ {
494
+ Value: blocksMinted,
495
+ Label: 'Blocks Minted'
496
+ },
497
+ {
498
+ Value: blocksEpoch,
499
+ Label: 'Blocks This Epoch'
500
+ },
501
+ {
502
+ Value: liveStake,
503
+ Label: 'Live Stake'
504
+ },
505
+ {
506
+ Value: liveSize,
507
+ Label: 'Live Size'
508
+ },
509
+ {
510
+ Value: liveSaturation,
511
+ Label: 'Live Saturation'
512
+ },
513
+ {
514
+ Value: liveDelegators,
515
+ Label: 'Live Delegators'
516
+ },
517
+ {
518
+ Value: activeStake,
519
+ Label: 'Active Stake'
520
+ },
521
+ {
522
+ Value: activeSize,
523
+ Label: 'Active Size'
524
+ },
525
+ {
526
+ Value: pledge,
527
+ Label: 'Pledge'
528
+ },
529
+ {
530
+ Value: margin,
531
+ Label: 'Margin'
532
+ },
533
+ {
534
+ Value: fixedCost,
535
+ Label: 'Fixed Cost'
536
+ },
537
+ {
538
+ Value: rewardAccount,
539
+ Label: 'Reward Account'
540
+ },
541
+ {
542
+ $Type : 'UI.DataFieldForAction',
543
+ Action: 'CardanoODataService.EntityContainer/GetPoolById',
544
+ Label : 'Get Pool by ID'
545
+ }
546
+ ],
547
+
548
+ UI.Identification : [{
549
+ $Type : 'UI.DataFieldForAction',
550
+ Action: 'CardanoODataService.EntityContainer/GetPoolById',
551
+ Label : 'Get Pool by ID'
552
+ }],
553
+
554
+ UI.HeaderFacets : [
555
+ {
556
+ $Type : 'UI.ReferenceFacet',
557
+ Label : 'Live Stake',
558
+ Target: '@UI.DataPoint#LiveStake'
559
+ },
560
+ {
561
+ $Type : 'UI.ReferenceFacet',
562
+ Label : 'Pledge',
563
+ Target: '@UI.DataPoint#Pledge'
564
+ },
565
+ {
566
+ $Type : 'UI.ReferenceFacet',
567
+ Label : 'Delegators',
568
+ Target: '@UI.DataPoint#Delegators'
569
+ }
570
+ ],
571
+
572
+ UI.DataPoint #LiveStake : {
573
+ Value: liveStake,
574
+ Title: 'Live Stake'
575
+ },
576
+ UI.DataPoint #Pledge : {
577
+ Value: pledge,
578
+ Title: 'Pledge'
579
+ },
580
+ UI.DataPoint #Delegators: {
581
+ Value: liveDelegators,
582
+ Title: 'Live Delegators'
583
+ },
584
+
585
+ UI.Facets : [
586
+ {
587
+ $Type : 'UI.ReferenceFacet',
588
+ Label : 'Overview',
589
+ Target: '@UI.FieldGroup#Overview'
590
+ },
591
+ {
592
+ $Type : 'UI.ReferenceFacet',
593
+ Label : 'Live',
594
+ Target: '@UI.FieldGroup#Live'
595
+ },
596
+ {
597
+ $Type : 'UI.ReferenceFacet',
598
+ Label : 'Active',
599
+ Target: '@UI.FieldGroup#Active'
600
+ },
601
+ {
602
+ $Type : 'UI.ReferenceFacet',
603
+ Label : 'Rewards',
604
+ Target: '@UI.FieldGroup#Rewards'
605
+ }
606
+ ],
607
+
608
+ UI.FieldGroup #Overview : {Data: [
609
+ {
610
+ $Type: 'UI.DataField',
611
+ Value: poolId,
612
+ Label: 'Pool ID'
613
+ },
614
+ {
615
+ $Type: 'UI.DataField',
616
+ Value: vrfKeyHash,
617
+ Label: 'VRF Key Hash'
618
+ }
619
+ ]},
620
+
621
+ UI.FieldGroup #Live : {Data: [
622
+ {
623
+ $Type: 'UI.DataField',
624
+ Value: liveStake,
625
+ Label: 'Live Stake'
626
+ },
627
+ {
628
+ $Type: 'UI.DataField',
629
+ Value: liveSize,
630
+ Label: 'Live Size'
631
+ },
632
+ {
633
+ $Type: 'UI.DataField',
634
+ Value: liveSaturation,
635
+ Label: 'Live Saturation'
636
+ },
637
+ {
638
+ $Type: 'UI.DataField',
639
+ Value: liveDelegators,
640
+ Label: 'Live Delegators'
641
+ }
642
+ ]},
643
+
644
+ UI.FieldGroup #Active : {Data: [
645
+ {
646
+ $Type: 'UI.DataField',
647
+ Value: activeStake,
648
+ Label: 'Active Stake'
649
+ },
650
+ {
651
+ $Type: 'UI.DataField',
652
+ Value: activeSize,
653
+ Label: 'Active Size'
654
+ },
655
+ {
656
+ $Type: 'UI.DataField',
657
+ Value: blocksMinted,
658
+ Label: 'Blocks Minted'
659
+ },
660
+ {
661
+ $Type: 'UI.DataField',
662
+ Value: blocksEpoch,
663
+ Label: 'Blocks This Epoch'
664
+ }
665
+ ]},
666
+
667
+ UI.FieldGroup #Rewards : {Data: [
668
+ {
669
+ $Type: 'UI.DataField',
670
+ Value: pledge,
671
+ Label: 'Pledge'
672
+ },
673
+ {
674
+ $Type: 'UI.DataField',
675
+ Value: margin,
676
+ Label: 'Margin'
677
+ },
678
+ {
679
+ $Type: 'UI.DataField',
680
+ Value: fixedCost,
681
+ Label: 'Fixed Cost'
682
+ },
683
+ {
684
+ $Type: 'UI.DataField',
685
+ Value: rewardAccount,
686
+ Label: 'Reward Account'
687
+ }
688
+ ]}
689
+ );
690
+
691
+ // ----------------------------------------------------------------------------
692
+ // Dreps
693
+ // ----------------------------------------------------------------------------
694
+ annotate srv.Dreps with @(
695
+ UI.HeaderInfo : {
696
+ TypeName : 'DRep',
697
+ TypeNamePlural: 'DReps',
698
+ Title : {Value: drepId}
699
+ },
700
+
701
+ // List Report filter
702
+ UI.SelectionFields : [drepId],
703
+
704
+ // List Report table
705
+ UI.LineItem : [
706
+ {
707
+ Value: drepId,
708
+ Label: 'DRep ID'
709
+ },
710
+ {
711
+ Value: amount,
712
+ Label: 'Voting Power'
713
+ },
714
+ {
715
+ Value: hasScript,
716
+ Label: 'Has Script'
717
+ },
718
+ {
719
+ Value: lastActiveEpoch,
720
+ Label: 'Last Active Epoch'
721
+ },
722
+ {
723
+ Value: retired,
724
+ Label: 'Retired'
725
+ },
726
+ {
727
+ Value: expired,
728
+ Label: 'Expired'
729
+ },
730
+
731
+ {
732
+ $Type : 'UI.DataFieldForAction',
733
+ Action: 'CardanoODataService.EntityContainer/GetDrepById',
734
+ Label : 'Get DRep by ID'
735
+ }
736
+ ],
737
+
738
+ UI.Identification : [{
739
+ $Type : 'UI.DataFieldForAction',
740
+ Action: 'CardanoODataService.EntityContainer/GetDrepById',
741
+ Label : 'Get DRep by ID'
742
+ }],
743
+
744
+ UI.HeaderFacets : [{
745
+ $Type : 'UI.ReferenceFacet',
746
+ Label : 'Voting Power',
747
+ Target: '@UI.DataPoint#VotingPower'
748
+ }],
749
+
750
+ UI.DataPoint #VotingPower: {
751
+ Value: amount,
752
+ Title: 'Voting Power'
753
+ },
754
+
755
+ // Object Page: clean sections
756
+ UI.Facets : [
757
+ {
758
+ $Type : 'UI.ReferenceFacet',
759
+ Label : 'Overview',
760
+ Target: '@UI.FieldGroup#Overview'
761
+ },
762
+ {
763
+ $Type : 'UI.ReferenceFacet',
764
+ Label : 'Status',
765
+ Target: '@UI.FieldGroup#Status'
766
+ }
767
+ ],
768
+
769
+ UI.FieldGroup #Overview : {Data: [
770
+ {
771
+ $Type: 'UI.DataField',
772
+ Value: drepId,
773
+ Label: 'DRep ID'
774
+ },
775
+ {
776
+ $Type: 'UI.DataField',
777
+ Value: hex,
778
+ Label: 'Hex'
779
+ }
780
+ ]},
781
+
782
+ UI.FieldGroup #Status : {Data: [
783
+ {
784
+ $Type: 'UI.DataField',
785
+ Value: hasScript,
786
+ Label: 'Has Script'
787
+ },
788
+ {
789
+ $Type: 'UI.DataField',
790
+ Value: lastActiveEpoch,
791
+ Label: 'Last Active Epoch'
792
+ },
793
+ {
794
+ $Type: 'UI.DataField',
795
+ Value: retired,
796
+ Label: 'Retired'
797
+ },
798
+ {
799
+ $Type: 'UI.DataField',
800
+ Value: expired,
801
+ Label: 'Expired'
802
+ }
803
+ ]}
804
+ );
805
+
806
+ // Provide consistent labels everywhere (List + Object Page)
807
+ annotate srv.Dreps with {
808
+ drepId @Common.Label: 'DRep ID';
809
+ hex @Common.Label: 'Hex';
810
+ amount @Common.Label: 'Voting Power (Lovelace)';
811
+ hasScript @Common.Label: 'Has Script';
812
+ lastActiveEpoch @Common.Label: 'Last Active Epoch';
813
+ retired @Common.Label: 'Retired';
814
+ expired @Common.Label: 'Expired';
815
+ };
816
+
817
+ // ----------------------------------------------------------------------------
818
+ // Addresses & related Assets + UTxOs
819
+ // ----------------------------------------------------------------------------
820
+ annotate srv.Addresses with @(
821
+ UI.HeaderInfo : {
822
+ TypeName : 'Address',
823
+ TypeNamePlural: 'Addresses',
824
+ Title : {Value: address}
825
+ },
826
+
827
+ UI.SelectionFields : [
828
+ address,
829
+ type
830
+ ],
831
+
832
+ UI.LineItem : [
833
+ {
834
+ Value: address,
835
+ Label: 'Address'
836
+ },
837
+ {
838
+ Value: stakeAddress,
839
+ Label: 'Stake Address'
840
+ },
841
+ {
842
+ Value: type,
843
+ Label: 'Type'
844
+ },
845
+ {
846
+ Value: isScript,
847
+ Label: 'Is Script'
848
+ },
849
+ {
850
+ Value: totalLovelace,
851
+ Label: 'Total Lovelace'
852
+ },
853
+ {
854
+ $Type : 'UI.DataFieldForAction',
855
+ Action: 'CardanoODataService.EntityContainer/GetAddressByBech32',
856
+ Label : 'Get Address by Bech32'
857
+ }
858
+ ],
859
+
860
+ UI.Identification : [{
861
+ $Type : 'UI.DataFieldForAction',
862
+ Action: 'CardanoODataService.EntityContainer/GetAddressByBech32',
863
+ Label : 'Get Address by Bech32'
864
+ }],
865
+
866
+ UI.HeaderFacets : [{
867
+ $Type : 'UI.ReferenceFacet',
868
+ Label : 'Total Lovelace',
869
+ Target: '@UI.DataPoint#TotalLovelace'
870
+ }],
871
+
872
+ UI.DataPoint #TotalLovelace : {
873
+ Value: totalLovelace,
874
+ Title: 'Total Lovelace'
875
+ },
876
+
877
+ UI.Facets : [
878
+ {
879
+ $Type : 'UI.ReferenceFacet',
880
+ Label : 'Overview',
881
+ Target: '@UI.FieldGroup#Overview'
882
+ },
883
+ {
884
+ $Type : 'UI.ReferenceFacet',
885
+ Label : 'Account Details',
886
+ Target: '@UI.FieldGroup#AccountDetails'
887
+ },
888
+
889
+ // existing navigations preserved
890
+ {
891
+ $Type : 'UI.ReferenceFacet',
892
+ Label : 'Assets',
893
+ Target : 'assets/@UI.LineItem',
894
+ ![@UI.Hidden]: (not hasAssets)
895
+ },
896
+ {
897
+ $Type : 'UI.ReferenceFacet',
898
+ Label : 'UTxOs',
899
+ Target : 'utxos/@UI.LineItem',
900
+ ![@UI.Hidden]: (not hasUTxOs)
901
+ }
902
+ ],
903
+
904
+ UI.FieldGroup #Overview : {Data: [
905
+ {
906
+ $Type: 'UI.DataField',
907
+ Value: address,
908
+ Label: 'Address'
909
+ },
910
+ {
911
+ $Type: 'UI.DataField',
912
+ Value: stakeAddress,
913
+ Label: 'Stake Address'
914
+ },
915
+ {
916
+ $Type: 'UI.DataField',
917
+ Value: type,
918
+ Label: 'Type'
919
+ },
920
+ {
921
+ $Type: 'UI.DataField',
922
+ Value: isScript,
923
+ Label: 'Is Script'
924
+ },
925
+ {
926
+ $Type: 'UI.DataField',
927
+ Value: totalLovelace,
928
+ Label: 'Total Lovelace'
929
+ }
930
+ ]},
931
+
932
+ UI.FieldGroup #AccountDetails: {Data: [{
933
+ $Type: 'UI.DataField',
934
+ Value: stakeAddress,
935
+ Label: 'Stake Address'
936
+ }]}
937
+ );
938
+
939
+ annotate srv.AddressAssets with @(
940
+ UI.HeaderInfo : {
941
+ TypeName : 'Address Asset',
942
+ TypeNamePlural: 'Address Assets',
943
+ Title : {Value: unit}
944
+ },
945
+
946
+ UI.LineItem : [
947
+ {
948
+ Value: unit,
949
+ Label: 'Unit'
950
+ },
951
+ {
952
+ Value: asset_quantity,
953
+ Label: 'Quantity'
954
+ },
955
+ {
956
+ Value: asset_policyId,
957
+ Label: 'Policy ID'
958
+ },
959
+ {
960
+ Value: asset_assetName,
961
+ Label: 'Asset Name'
962
+ },
963
+ {
964
+ Value: asset_fingerprint,
965
+ Label: 'Fingerprint'
966
+ }
967
+ ],
968
+
969
+ UI.HeaderFacets : [{
970
+ $Type : 'UI.ReferenceFacet',
971
+ Label : 'Quantity',
972
+ Target: '@UI.DataPoint#Quantity'
973
+ }],
974
+
975
+ UI.DataPoint #Quantity : {
976
+ Value: asset_quantity,
977
+ Title: 'Quantity'
978
+ },
979
+
980
+ UI.Facets : [{
981
+ $Type : 'UI.ReferenceFacet',
982
+ Label : 'Asset Details',
983
+ Target: '@UI.FieldGroup#AssetDetails'
984
+ }],
985
+
986
+ UI.FieldGroup #AssetDetails: {Data: [
987
+ {
988
+ $Type: 'UI.DataField',
989
+ Value: unit,
990
+ Label: 'Unit'
991
+ },
992
+ {
993
+ $Type: 'UI.DataField',
994
+ Value: asset_quantity,
995
+ Label: 'Quantity'
996
+ },
997
+ {
998
+ $Type: 'UI.DataField',
999
+ Value: asset_policyId,
1000
+ Label: 'Policy ID'
1001
+ },
1002
+ {
1003
+ $Type: 'UI.DataField',
1004
+ Value: asset_assetNameHex,
1005
+ Label: 'Asset Name (Hex)'
1006
+ },
1007
+ {
1008
+ $Type: 'UI.DataField',
1009
+ Value: asset_assetName,
1010
+ Label: 'Asset Name'
1011
+ },
1012
+ {
1013
+ $Type: 'UI.DataField',
1014
+ Value: asset_fingerprint,
1015
+ Label: 'Fingerprint'
1016
+ }
1017
+ ]}
1018
+ );
1019
+
1020
+ annotate srv.AddressUTxOs with @(
1021
+ UI.HeaderInfo : {
1022
+ TypeName : 'Address UTxO',
1023
+ TypeNamePlural: 'Address UTxOs',
1024
+ Title : {Value: hash},
1025
+ Description : {Value: index}
1026
+ },
1027
+
1028
+ UI.LineItem : [
1029
+ {
1030
+ Value: hash,
1031
+ Label: 'Transaction Hash'
1032
+ },
1033
+ {
1034
+ Value: index,
1035
+ Label: 'Output Index'
1036
+ },
1037
+ {
1038
+ Value: blockHash,
1039
+ Label: 'Block Hash'
1040
+ },
1041
+ {
1042
+ Value: utxodata_dataHash,
1043
+ Label: 'Data Hash'
1044
+ },
1045
+ {
1046
+ Value: hasAssets,
1047
+ Label: 'Has Assets'
1048
+ }
1049
+ ],
1050
+
1051
+ UI.HeaderFacets : [
1052
+ {
1053
+ $Type : 'UI.ReferenceFacet',
1054
+ Label : 'UTxO Index',
1055
+ Target: '@UI.DataPoint#Index'
1056
+ },
1057
+ {
1058
+ $Type : 'UI.ReferenceFacet',
1059
+ Label : 'Has Assets',
1060
+ Target: '@UI.DataPoint#HasAssets'
1061
+ }
1062
+ ],
1063
+
1064
+ UI.DataPoint #Index : {
1065
+ Value: index,
1066
+ Title: 'UTxO Index'
1067
+ },
1068
+ UI.DataPoint #HasAssets : {
1069
+ Value: hasAssets,
1070
+ Title: 'Has Assets'
1071
+ },
1072
+
1073
+ UI.Facets : [
1074
+ {
1075
+ $Type : 'UI.ReferenceFacet',
1076
+ Label : 'Assets',
1077
+ Target : 'assets/@UI.LineItem',
1078
+ ![@UI.Hidden]: (not hasAssets)
1079
+ },
1080
+ {
1081
+ $Type : 'UI.ReferenceFacet',
1082
+ Label : 'UTxO Details',
1083
+ Target: '@UI.FieldGroup#UTxODetails'
1084
+ }
1085
+ ],
1086
+
1087
+ UI.FieldGroup #UTxODetails: {Data: [
1088
+ {
1089
+ $Type: 'UI.DataField',
1090
+ Value: hash,
1091
+ Label: 'Transaction Hash'
1092
+ },
1093
+ {
1094
+ $Type: 'UI.DataField',
1095
+ Value: index,
1096
+ Label: 'Output Index'
1097
+ },
1098
+ {
1099
+ $Type: 'UI.DataField',
1100
+ Value: blockHash,
1101
+ Label: 'Block Hash'
1102
+ },
1103
+ {
1104
+ $Type: 'UI.DataField',
1105
+ Value: utxodata_dataHash,
1106
+ Label: 'Data Hash'
1107
+ },
1108
+ {
1109
+ $Type: 'UI.DataField',
1110
+ Value: utxodata_inlineDatum,
1111
+ Label: 'Inline Datum'
1112
+ },
1113
+ {
1114
+ $Type: 'UI.DataField',
1115
+ Value: utxodata_referenceScriptHash,
1116
+ Label: 'Reference Script Hash'
1117
+ }
1118
+ ]}
1119
+ );
1120
+
1121
+ annotate srv.UTxOAssets with @(
1122
+ UI.HeaderInfo : {
1123
+ TypeName : 'UTxO Asset',
1124
+ TypeNamePlural: 'UTxO Assets',
1125
+ Title : {Value: unit}
1126
+ },
1127
+
1128
+ UI.LineItem : [
1129
+ {
1130
+ Value: unit,
1131
+ Label: 'Unit'
1132
+ },
1133
+ {
1134
+ Value: asset_quantity,
1135
+ Label: 'Quantity'
1136
+ },
1137
+ {
1138
+ Value: asset_policyId,
1139
+ Label: 'Policy ID'
1140
+ },
1141
+ {
1142
+ Value: asset_assetName,
1143
+ Label: 'Asset Name'
1144
+ },
1145
+ {
1146
+ Value: asset_fingerprint,
1147
+ Label: 'Fingerprint'
1148
+ }
1149
+ ],
1150
+
1151
+ UI.HeaderFacets : [{
1152
+ $Type : 'UI.ReferenceFacet',
1153
+ Label : 'Quantity',
1154
+ Target: '@UI.DataPoint#Quantity'
1155
+ }],
1156
+
1157
+ UI.DataPoint #Quantity : {
1158
+ Value: asset_quantity,
1159
+ Title: 'Quantity'
1160
+ },
1161
+
1162
+ UI.Facets : [{
1163
+ $Type : 'UI.ReferenceFacet',
1164
+ Label : 'Asset Details',
1165
+ Target: '@UI.FieldGroup#AssetDetails'
1166
+ }],
1167
+
1168
+ UI.FieldGroup #AssetDetails: {Data: [
1169
+ {
1170
+ $Type: 'UI.DataField',
1171
+ Value: unit,
1172
+ Label: 'Unit'
1173
+ },
1174
+ {
1175
+ $Type: 'UI.DataField',
1176
+ Value: asset_quantity,
1177
+ Label: 'Quantity'
1178
+ },
1179
+ {
1180
+ $Type: 'UI.DataField',
1181
+ Value: asset_policyId,
1182
+ Label: 'Policy ID'
1183
+ },
1184
+ {
1185
+ $Type: 'UI.DataField',
1186
+ Value: asset_assetNameHex,
1187
+ Label: 'Asset Name (Hex)'
1188
+ },
1189
+ {
1190
+ $Type: 'UI.DataField',
1191
+ Value: asset_assetName,
1192
+ Label: 'Asset Name'
1193
+ },
1194
+ {
1195
+ $Type: 'UI.DataField',
1196
+ Value: asset_fingerprint,
1197
+ Label: 'Fingerprint'
1198
+ }
1199
+ ]}
1200
+ );
1201
+
1202
+
1203
+ // ----------------------------------------------------------------------------
1204
+ // Transactions
1205
+ // ----------------------------------------------------------------------------
1206
+ annotate srv.Transactions with @(
1207
+ UI.HeaderInfo : {
1208
+ TypeName : 'Transaction',
1209
+ TypeNamePlural: 'Transactions',
1210
+ Title : {Value: hash},
1211
+ Description : {Value: blockTime}
1212
+ },
1213
+
1214
+ UI.SelectionFields : [
1215
+ hash,
1216
+ blockHeight
1217
+ ],
1218
+
1219
+ UI.LineItem : [
1220
+ {
1221
+ Value: hash,
1222
+ Label: 'Hash'
1223
+ },
1224
+ {
1225
+ Value: blockHeight,
1226
+ Label: 'Block Height'
1227
+ },
1228
+ {
1229
+ Value: blockTime,
1230
+ Label: 'Block Time'
1231
+ },
1232
+ {
1233
+ Value: slot,
1234
+ Label: 'Slot'
1235
+ },
1236
+ {
1237
+ Value: txIndex,
1238
+ Label: 'Tx Index'
1239
+ },
1240
+ {
1241
+ Value: fee,
1242
+ Label: 'Fee'
1243
+ },
1244
+ {
1245
+ Value: deposit,
1246
+ Label: 'Deposit'
1247
+ },
1248
+ {
1249
+ Value: size,
1250
+ Label: 'Size'
1251
+ },
1252
+ {
1253
+ $Type : 'UI.DataFieldForAction',
1254
+ Action: 'CardanoODataService.EntityContainer/GetTransactionByHash',
1255
+ Label : 'Get Transaction by Hash'
1256
+ }
1257
+ ],
1258
+
1259
+ UI.Identification : [{
1260
+ $Type : 'UI.DataFieldForAction',
1261
+ Action: 'CardanoODataService.EntityContainer/GetTransactionByHash',
1262
+ Label : 'Get Transaction by Hash'
1263
+ }],
1264
+
1265
+ UI.HeaderFacets : [
1266
+ {
1267
+ $Type : 'UI.ReferenceFacet',
1268
+ Label : 'Fee',
1269
+ Target: '@UI.DataPoint#Fee'
1270
+ },
1271
+ {
1272
+ $Type : 'UI.ReferenceFacet',
1273
+ Label : 'Deposit',
1274
+ Target: '@UI.DataPoint#Deposit'
1275
+ },
1276
+ {
1277
+ $Type : 'UI.ReferenceFacet',
1278
+ Label : 'Size',
1279
+ Target: '@UI.DataPoint#Size'
1280
+ }
1281
+ ],
1282
+
1283
+ UI.DataPoint #Fee : {
1284
+ Value: fee,
1285
+ Title: 'Fee'
1286
+ },
1287
+ UI.DataPoint #Deposit : {
1288
+ Value: deposit,
1289
+ Title: 'Deposit'
1290
+ },
1291
+ UI.DataPoint #Size : {
1292
+ Value: size,
1293
+ Title: 'Size'
1294
+ },
1295
+
1296
+ UI.Facets : [
1297
+ {
1298
+ $Type : 'UI.ReferenceFacet',
1299
+ Label : 'Overview',
1300
+ Target: '@UI.FieldGroup#Overview'
1301
+ },
1302
+
1303
+ // existing navigations preserved
1304
+ {
1305
+ $Type : 'UI.ReferenceFacet',
1306
+ Label : 'Metadata',
1307
+ Target : 'metadata/@UI.LineItem',
1308
+ ![@UI.Hidden]: (not hasMetadata)
1309
+ },
1310
+ {
1311
+ $Type : 'UI.ReferenceFacet',
1312
+ Label : 'Inputs',
1313
+ Target : 'inputs/@UI.LineItem',
1314
+ ![@UI.Hidden]: (not hasInputs)
1315
+ },
1316
+ {
1317
+ $Type : 'UI.ReferenceFacet',
1318
+ Label : 'Outputs',
1319
+ Target : 'outputs/@UI.LineItem',
1320
+ ![@UI.Hidden]: (not hasOutputs)
1321
+ }
1322
+ ],
1323
+
1324
+ UI.FieldGroup #Overview: {Data: [
1325
+ {
1326
+ $Type: 'UI.DataField',
1327
+ Value: hash,
1328
+ Label: 'Hash'
1329
+ },
1330
+ {
1331
+ $Type: 'UI.DataField',
1332
+ Value: blockHash,
1333
+ Label: 'Block Hash'
1334
+ },
1335
+ {
1336
+ $Type: 'UI.DataField',
1337
+ Value: blockHeight,
1338
+ Label: 'Block Height'
1339
+ },
1340
+ {
1341
+ $Type: 'UI.DataField',
1342
+ Value: blockTime,
1343
+ Label: 'Block Time'
1344
+ },
1345
+ {
1346
+ $Type: 'UI.DataField',
1347
+ Value: slot,
1348
+ Label: 'Slot'
1349
+ },
1350
+ {
1351
+ $Type: 'UI.DataField',
1352
+ Value: txIndex,
1353
+ Label: 'Tx Index'
1354
+ },
1355
+ {
1356
+ $Type: 'UI.DataField',
1357
+ Value: fee,
1358
+ Label: 'Fee'
1359
+ },
1360
+ {
1361
+ $Type: 'UI.DataField',
1362
+ Value: deposit,
1363
+ Label: 'Deposit'
1364
+ },
1365
+ {
1366
+ $Type: 'UI.DataField',
1367
+ Value: size,
1368
+ Label: 'Size'
1369
+ }
1370
+ ]}
1371
+ );
1372
+
1373
+ // ----------------------------------------------------------------------------
1374
+ // Transaction Metadata
1375
+ // ----------------------------------------------------------------------------
1376
+ annotate srv.TransactionMetadata with @(UI.LineItem: [
1377
+ {
1378
+ Value: label,
1379
+ Label: 'Label'
1380
+ },
1381
+ {
1382
+ Value: payload,
1383
+ Label: 'Payload'
1384
+ }
1385
+ ]);
1386
+ // ----------------------------------------------------------------------------
1387
+ // Transaction Inputs & Inputs Assets
1388
+ // ----------------------------------------------------------------------------
1389
+
1390
+ annotate srv.TransactionInputs with @(
1391
+ UI.HeaderInfo : {
1392
+ TypeName : 'Transaction Input',
1393
+ TypeNamePlural: 'Transaction Inputs',
1394
+ Title : {Value: inputIndex},
1395
+ Description : {Value: address_address}
1396
+ },
1397
+
1398
+ UI.LineItem : [
1399
+ {
1400
+ Value: inputIndex,
1401
+ Label: 'Input Index'
1402
+ },
1403
+ {
1404
+ Value: address_address,
1405
+ Label: 'Address'
1406
+ },
1407
+ {
1408
+ Value: utxoData_dataHash,
1409
+ Label: 'Data Hash'
1410
+ },
1411
+ {
1412
+ Value: isCollateral,
1413
+ Label: 'Is Collateral'
1414
+ },
1415
+ {
1416
+ Value: isReference,
1417
+ Label: 'Is Reference'
1418
+ },
1419
+ {
1420
+ Value: hasAssets,
1421
+ Label: 'Has Assets'
1422
+ }
1423
+ ],
1424
+
1425
+ UI.PresentationVariant : {Visualizations: ['@UI.LineItem']},
1426
+
1427
+ UI.HeaderFacets : [
1428
+ {
1429
+ $Type : 'UI.ReferenceFacet',
1430
+ Label : 'Input Index',
1431
+ Target: '@UI.DataPoint#InputIndex'
1432
+ },
1433
+ {
1434
+ $Type : 'UI.ReferenceFacet',
1435
+ Label : 'Has Assets',
1436
+ Target: '@UI.DataPoint#HasAssets'
1437
+ }
1438
+ ],
1439
+
1440
+ UI.DataPoint #InputIndex: {
1441
+ Value: inputIndex,
1442
+ Title: 'Input Index'
1443
+ },
1444
+ UI.DataPoint #HasAssets : {
1445
+ Value: hasAssets,
1446
+ Title: 'Has Assets'
1447
+ },
1448
+
1449
+ UI.Facets : [
1450
+ {
1451
+ $Type : 'UI.ReferenceFacet',
1452
+ Label : 'Assets',
1453
+ Target : 'assets/@UI.LineItem',
1454
+ ![@UI.Hidden]: (not hasAssets)
1455
+ },
1456
+ {
1457
+ $Type : 'UI.ReferenceFacet',
1458
+ Label : 'Details',
1459
+ Target: '@UI.FieldGroup#Details'
1460
+ }
1461
+ ],
1462
+
1463
+ UI.FieldGroup #Details : {Data: [
1464
+ {
1465
+ $Type: 'UI.DataField',
1466
+ Value: inputIndex,
1467
+ Label: 'Input Index'
1468
+ },
1469
+ {
1470
+ $Type: 'UI.DataField',
1471
+ Value: address_address,
1472
+ Label: 'Address'
1473
+ },
1474
+ {
1475
+ $Type: 'UI.DataField',
1476
+ Value: utxoData_dataHash,
1477
+ Label: 'Data Hash'
1478
+ },
1479
+ {
1480
+ $Type: 'UI.DataField',
1481
+ Value: utxoData_inlineDatum,
1482
+ Label: 'Inline Datum'
1483
+ },
1484
+ {
1485
+ $Type: 'UI.DataField',
1486
+ Value: utxoData_referenceScriptHash,
1487
+ Label: 'Reference Script Hash'
1488
+ },
1489
+ {
1490
+ $Type: 'UI.DataField',
1491
+ Value: isCollateral,
1492
+ Label: 'Is Collateral'
1493
+ },
1494
+ {
1495
+ $Type: 'UI.DataField',
1496
+ Value: isReference,
1497
+ Label: 'Is Reference'
1498
+ }
1499
+ ]}
1500
+ );
1501
+
1502
+ annotate srv.TransactionInputAssets with @(
1503
+ UI.HeaderInfo : {
1504
+ TypeName : 'Input Asset',
1505
+ TypeNamePlural: 'Input Assets',
1506
+ Title : {Value: unit}
1507
+ },
1508
+
1509
+ UI.LineItem : [
1510
+ {
1511
+ Value: unit,
1512
+ Label: 'Unit'
1513
+ },
1514
+ {
1515
+ Value: asset_quantity,
1516
+ Label: 'Quantity'
1517
+ },
1518
+ {
1519
+ Value: asset_policyId,
1520
+ Label: 'Policy ID'
1521
+ },
1522
+ {
1523
+ Value: asset_assetName,
1524
+ Label: 'Asset Name'
1525
+ },
1526
+ {
1527
+ Value: asset_fingerprint,
1528
+ Label: 'Fingerprint'
1529
+ }
1530
+ ],
1531
+
1532
+ UI.Facets : [{
1533
+ $Type : 'UI.ReferenceFacet',
1534
+ Label : 'Asset Details',
1535
+ Target: '@UI.FieldGroup#AssetDetails'
1536
+ }],
1537
+
1538
+ UI.FieldGroup #AssetDetails: {Data: [
1539
+ {
1540
+ $Type: 'UI.DataField',
1541
+ Value: unit,
1542
+ Label: 'Unit'
1543
+ },
1544
+ {
1545
+ $Type: 'UI.DataField',
1546
+ Value: asset_quantity,
1547
+ Label: 'Quantity'
1548
+ },
1549
+ {
1550
+ $Type: 'UI.DataField',
1551
+ Value: asset_policyId,
1552
+ Label: 'Policy ID'
1553
+ },
1554
+ {
1555
+ $Type: 'UI.DataField',
1556
+ Value: asset_assetNameHex,
1557
+ Label: 'Asset Name (Hex)'
1558
+ },
1559
+ {
1560
+ $Type: 'UI.DataField',
1561
+ Value: asset_assetName,
1562
+ Label: 'Asset Name'
1563
+ },
1564
+ {
1565
+ $Type: 'UI.DataField',
1566
+ Value: asset_fingerprint,
1567
+ Label: 'Fingerprint'
1568
+ }
1569
+ ]}
1570
+ );
1571
+
1572
+ // ----------------------------------------------------------------------------
1573
+ // Transaction Outputs & Output Assets
1574
+ // ----------------------------------------------------------------------------
1575
+
1576
+ annotate srv.TransactionOutputs with @(
1577
+ UI.HeaderInfo : {
1578
+ TypeName : 'Transaction Output',
1579
+ TypeNamePlural: 'Transaction Outputs',
1580
+ Title : {Value: outputIndex},
1581
+ Description : {Value: address_address}
1582
+ },
1583
+
1584
+ UI.PresentationVariant : {Visualizations: ['@UI.LineItem']},
1585
+
1586
+ UI.LineItem : [
1587
+ {
1588
+ Value: outputIndex,
1589
+ Label: 'Output Index'
1590
+ },
1591
+ {
1592
+ Value: address_address,
1593
+ Label: 'Address'
1594
+ },
1595
+ {
1596
+ Value: hasAssets,
1597
+ Label: 'Has Assets'
1598
+ }
1599
+ ],
1600
+
1601
+ UI.HeaderFacets : [
1602
+ {
1603
+ $Type : 'UI.ReferenceFacet',
1604
+ Label : 'Output Index',
1605
+ Target: '@UI.DataPoint#OutputIndex'
1606
+ },
1607
+ {
1608
+ $Type : 'UI.ReferenceFacet',
1609
+ Label : 'Has Assets',
1610
+ Target: '@UI.DataPoint#HasAssets'
1611
+ }
1612
+ ],
1613
+
1614
+ UI.DataPoint #OutputIndex: {
1615
+ Value: outputIndex,
1616
+ Title: 'Output Index'
1617
+ },
1618
+ UI.DataPoint #HasAssets : {
1619
+ Value: hasAssets,
1620
+ Title: 'Has Assets'
1621
+ },
1622
+
1623
+ UI.Facets : [
1624
+ {
1625
+ $Type : 'UI.ReferenceFacet',
1626
+ Label : 'Assets',
1627
+ Target : 'assets/@UI.LineItem',
1628
+ ![@UI.Hidden]: (not hasAssets)
1629
+ },
1630
+ {
1631
+ $Type : 'UI.ReferenceFacet',
1632
+ Label : 'Details',
1633
+ Target: '@UI.FieldGroup#Details'
1634
+ },
1635
+ {
1636
+ $Type : 'UI.ReferenceFacet',
1637
+ Label : 'UTxO Data',
1638
+ Target: '@UI.FieldGroup#UTxOData'
1639
+ }
1640
+ ],
1641
+
1642
+ UI.FieldGroup #Details : {Data: [
1643
+ {
1644
+ $Type: 'UI.DataField',
1645
+ Value: outputIndex,
1646
+ Label: 'Output Index'
1647
+ },
1648
+ {
1649
+ $Type: 'UI.DataField',
1650
+ Value: address_address,
1651
+ Label: 'Address'
1652
+ },
1653
+ {
1654
+ $Type: 'UI.DataField',
1655
+ Value: hasAssets,
1656
+ Label: 'Has Assets'
1657
+ }
1658
+ ]},
1659
+
1660
+ UI.FieldGroup #UTxOData : {Data: [
1661
+ {
1662
+ $Type: 'UI.DataField',
1663
+ Value: utxo_dataHash,
1664
+ Label: 'Data Hash'
1665
+ },
1666
+ {
1667
+ $Type: 'UI.DataField',
1668
+ Value: utxo_inlineDatum,
1669
+ Label: 'Inline Datum'
1670
+ },
1671
+ {
1672
+ $Type: 'UI.DataField',
1673
+ Value: utxo_referenceScriptHash,
1674
+ Label: 'Reference Script Hash'
1675
+ }
1676
+ ]}
1677
+ );
1678
+
1679
+ annotate srv.TransactionOutputAssets with @(
1680
+ UI.HeaderInfo : {
1681
+ TypeName : 'Output Asset',
1682
+ TypeNamePlural: 'Output Assets',
1683
+ Title : {Value: unit},
1684
+ Description : {Value: asset_assetName}
1685
+ },
1686
+
1687
+ UI.LineItem : [
1688
+ {
1689
+ Value: unit,
1690
+ Label: 'Unit'
1691
+ },
1692
+ {
1693
+ Value: asset_quantity,
1694
+ Label: 'Quantity'
1695
+ },
1696
+ {
1697
+ Value: asset_policyId,
1698
+ Label: 'Policy ID'
1699
+ },
1700
+ {
1701
+ Value: asset_assetName,
1702
+ Label: 'Asset Name'
1703
+ },
1704
+ {
1705
+ Value: asset_fingerprint,
1706
+ Label: 'Fingerprint'
1707
+ }
1708
+ ],
1709
+
1710
+ UI.Facets : [{
1711
+ $Type : 'UI.ReferenceFacet',
1712
+ Label : 'Asset Details',
1713
+ Target: '@UI.FieldGroup#AssetDetails'
1714
+ }],
1715
+
1716
+ UI.FieldGroup #AssetDetails: {Data: [
1717
+ {
1718
+ $Type: 'UI.DataField',
1719
+ Value: unit,
1720
+ Label: 'Unit'
1721
+ },
1722
+ {
1723
+ $Type: 'UI.DataField',
1724
+ Value: asset_quantity,
1725
+ Label: 'Quantity'
1726
+ },
1727
+ {
1728
+ $Type: 'UI.DataField',
1729
+ Value: asset_policyId,
1730
+ Label: 'Policy ID'
1731
+ },
1732
+ {
1733
+ $Type: 'UI.DataField',
1734
+ Value: asset_assetNameHex,
1735
+ Label: 'Asset Name (Hex)'
1736
+ },
1737
+ {
1738
+ $Type: 'UI.DataField',
1739
+ Value: asset_assetName,
1740
+ Label: 'Asset Name'
1741
+ },
1742
+ {
1743
+ $Type: 'UI.DataField',
1744
+ Value: asset_fingerprint,
1745
+ Label: 'Fingerprint'
1746
+ }
1747
+ ]}
1748
+ );
1749
+
1750
+
1751
+ // ----------------------------------------------------------------------------
1752
+ // Accounts
1753
+ // ----------------------------------------------------------------------------
1754
+ annotate srv.Accounts with @(
1755
+ UI.HeaderInfo : {
1756
+ TypeName : 'Account',
1757
+ TypeNamePlural: 'Accounts',
1758
+ Title : {Value: stakeAddress}
1759
+ },
1760
+
1761
+ UI.SelectionFields : [stakeAddress],
1762
+
1763
+ UI.LineItem : [
1764
+ {
1765
+ Value: stakeAddress,
1766
+ Label: 'Stake Address'
1767
+ },
1768
+ {
1769
+ Value: active,
1770
+ Label: 'Active'
1771
+ },
1772
+ {
1773
+ Value: activeEpoch,
1774
+ Label: 'Active Epoch'
1775
+ },
1776
+ {
1777
+ Value: controlledAmount,
1778
+ Label: 'Controlled Amount'
1779
+ },
1780
+ {
1781
+ Value: rewardsSum,
1782
+ Label: 'Rewards Sum'
1783
+ },
1784
+ {
1785
+ Value: withdrawalsSum,
1786
+ Label: 'Withdrawals Sum'
1787
+ },
1788
+ {
1789
+ Value: reservesSum,
1790
+ Label: 'Reserves Sum'
1791
+ },
1792
+ {
1793
+ Value: treasurySum,
1794
+ Label: 'Treasury Sum'
1795
+ },
1796
+ {
1797
+ Value: withdrawableAmount,
1798
+ Label: 'Withdrawable Amount'
1799
+ },
1800
+ {
1801
+ Value: poolId_poolId,
1802
+ Label: 'Pool ID'
1803
+ },
1804
+ {
1805
+ Value: drepId_drepId,
1806
+ Label: 'DRep ID'
1807
+ },
1808
+ {
1809
+ Value: hasAddresses,
1810
+ Label: 'Has Addresses'
1811
+ },
1812
+ {
1813
+ $Type : 'UI.DataFieldForAction',
1814
+ Action: 'CardanoODataService.EntityContainer/GetAccountByStakeAddress',
1815
+ Label : 'Get Account by Stake Address'
1816
+ }
1817
+ ],
1818
+
1819
+ UI.Identification : [{
1820
+ $Type : 'UI.DataFieldForAction',
1821
+ Action: 'CardanoODataService.EntityContainer/GetAccountByStakeAddress',
1822
+ Label : 'Get Account by Stake Address'
1823
+ }],
1824
+
1825
+ UI.HeaderFacets : [
1826
+ {
1827
+ $Type : 'UI.ReferenceFacet',
1828
+ Label : 'Controlled',
1829
+ Target: '@UI.DataPoint#Controlled'
1830
+ },
1831
+ {
1832
+ $Type : 'UI.ReferenceFacet',
1833
+ Label : 'Withdrawable',
1834
+ Target: '@UI.DataPoint#Withdrawable'
1835
+ }
1836
+ ],
1837
+
1838
+ UI.DataPoint #Controlled : {
1839
+ Value: controlledAmount,
1840
+ Title: 'Controlled Amount'
1841
+ },
1842
+ UI.DataPoint #Withdrawable: {
1843
+ Value: withdrawableAmount,
1844
+ Title: 'Withdrawable Amount'
1845
+ },
1846
+
1847
+ UI.Facets : [
1848
+ {
1849
+ $Type : 'UI.ReferenceFacet',
1850
+ Label : 'Overview',
1851
+ Target: '@UI.FieldGroup#Overview'
1852
+ },
1853
+ {
1854
+ $Type : 'UI.ReferenceFacet',
1855
+ Label : 'Sums',
1856
+ Target: '@UI.FieldGroup#Sums'
1857
+ },
1858
+
1859
+ {
1860
+ $Type : 'UI.ReferenceFacet',
1861
+ Label : 'Addresses',
1862
+ Target : 'Address/@UI.LineItem',
1863
+ ![@UI.Hidden]: (not hasAddresses)
1864
+ }
1865
+ ],
1866
+
1867
+ UI.FieldGroup #Overview : {Data: [
1868
+ {
1869
+ $Type: 'UI.DataField',
1870
+ Value: stakeAddress,
1871
+ Label: 'Stake Address'
1872
+ },
1873
+ {
1874
+ $Type: 'UI.DataField',
1875
+ Value: active,
1876
+ Label: 'Active'
1877
+ },
1878
+ {
1879
+ $Type: 'UI.DataField',
1880
+ Value: activeEpoch,
1881
+ Label: 'Active Epoch'
1882
+ },
1883
+ {
1884
+ $Type: 'UI.DataField',
1885
+ Value: poolId_poolId,
1886
+ Label: 'Pool ID'
1887
+ },
1888
+ {
1889
+ $Type: 'UI.DataField',
1890
+ Value: drepId_drepId,
1891
+ Label: 'DRep ID'
1892
+ },
1893
+ {
1894
+ $Type: 'UI.DataField',
1895
+ Value: hasAddresses,
1896
+ Label: 'Has Addresses'
1897
+ }
1898
+ ]},
1899
+
1900
+ UI.FieldGroup #Sums : {Data: [
1901
+ {
1902
+ $Type: 'UI.DataField',
1903
+ Value: controlledAmount,
1904
+ Label: 'Controlled Amount'
1905
+ },
1906
+ {
1907
+ $Type: 'UI.DataField',
1908
+ Value: rewardsSum,
1909
+ Label: 'Rewards Sum'
1910
+ },
1911
+ {
1912
+ $Type: 'UI.DataField',
1913
+ Value: withdrawalsSum,
1914
+ Label: 'Withdrawals Sum'
1915
+ },
1916
+ {
1917
+ $Type: 'UI.DataField',
1918
+ Value: reservesSum,
1919
+ Label: 'Reserves Sum'
1920
+ },
1921
+ {
1922
+ $Type: 'UI.DataField',
1923
+ Value: treasurySum,
1924
+ Label: 'Treasury Sum'
1925
+ },
1926
+ {
1927
+ $Type: 'UI.DataField',
1928
+ Value: withdrawableAmount,
1929
+ Label: 'Withdrawable Amount'
1930
+ }
1931
+ ]}
1932
+ );
1933
+
1934
+ // ============================================================================
1935
+ // M2 - Transaction Building & Submission UI Annotations
1936
+ // ============================================================================
1937
+
1938
+ // ----------------------------------------------------------------------------
1939
+ // LedgerProtocolParameters
1940
+ // ----------------------------------------------------------------------------
1941
+ annotate srv.LedgerProtocolParameters with @(
1942
+ UI.HeaderInfo : {
1943
+ TypeName : 'Protocol Parameters',
1944
+ TypeNamePlural: 'Protocol Parameters',
1945
+ Title : {Value: network},
1946
+ Description : {Value: epoch}
1947
+ },
1948
+
1949
+ UI.SelectionFields : [
1950
+ network,
1951
+ epoch
1952
+ ],
1953
+
1954
+ UI.LineItem : [
1955
+ {
1956
+ Value: network,
1957
+ Label: 'Network'
1958
+ },
1959
+ {
1960
+ Value: epoch,
1961
+ Label: 'Epoch'
1962
+ },
1963
+ {
1964
+ Value: minFeeA,
1965
+ Label: 'Min Fee A'
1966
+ },
1967
+ {
1968
+ Value: minFeeB,
1969
+ Label: 'Min Fee B'
1970
+ },
1971
+ {
1972
+ Value: maxTxSize,
1973
+ Label: 'Max Tx Size'
1974
+ },
1975
+ {
1976
+ Value: protocolMajorVer,
1977
+ Label: 'Protocol Major'
1978
+ },
1979
+ {
1980
+ Value: protocolMinorVer,
1981
+ Label: 'Protocol Minor'
1982
+ },
1983
+ {
1984
+ $Type : 'UI.DataFieldForAction',
1985
+ Action: 'CardanoODataService.EntityContainer/GetLedgerProtocolParameters',
1986
+ Label : 'Refresh Protocol Parameters'
1987
+ }
1988
+ ],
1989
+
1990
+ UI.Identification : [{
1991
+ $Type : 'UI.DataFieldForAction',
1992
+ Action: 'CardanoODataService.EntityContainer/GetLedgerProtocolParameters',
1993
+ Label : 'Refresh Protocol Parameters'
1994
+ }],
1995
+
1996
+ UI.HeaderFacets : [
1997
+ {
1998
+ $Type : 'UI.ReferenceFacet',
1999
+ Label : 'Protocol Version',
2000
+ Target: '@UI.DataPoint#ProtocolVersion'
2001
+ },
2002
+ {
2003
+ $Type : 'UI.ReferenceFacet',
2004
+ Label : 'Max Tx Size',
2005
+ Target: '@UI.DataPoint#MaxTxSize'
2006
+ }
2007
+ ],
2008
+
2009
+ UI.DataPoint #ProtocolVersion: {
2010
+ Value: protocolMajorVer,
2011
+ Title: 'Protocol Major Version'
2012
+ },
2013
+ UI.DataPoint #MaxTxSize : {
2014
+ Value: maxTxSize,
2015
+ Title: 'Max Transaction Size'
2016
+ },
2017
+
2018
+ UI.Facets : [
2019
+ {
2020
+ $Type : 'UI.ReferenceFacet',
2021
+ Label : 'Fee Parameters',
2022
+ Target: '@UI.FieldGroup#FeeParams'
2023
+ },
2024
+ {
2025
+ $Type : 'UI.ReferenceFacet',
2026
+ Label : 'Size Limits',
2027
+ Target: '@UI.FieldGroup#SizeLimits'
2028
+ },
2029
+ {
2030
+ $Type : 'UI.ReferenceFacet',
2031
+ Label : 'Deposits',
2032
+ Target: '@UI.FieldGroup#Deposits'
2033
+ },
2034
+ {
2035
+ $Type : 'UI.ReferenceFacet',
2036
+ Label : 'Execution Units',
2037
+ Target: '@UI.FieldGroup#ExecUnits'
2038
+ },
2039
+ {
2040
+ $Type : 'UI.ReferenceFacet',
2041
+ Label : 'Pool Parameters',
2042
+ Target: '@UI.FieldGroup#PoolParams'
2043
+ }
2044
+ ],
2045
+
2046
+ UI.FieldGroup #FeeParams : {Data: [
2047
+ {
2048
+ $Type: 'UI.DataField',
2049
+ Value: minFeeA,
2050
+ Label: 'Min Fee A (per byte)'
2051
+ },
2052
+ {
2053
+ $Type: 'UI.DataField',
2054
+ Value: minFeeB,
2055
+ Label: 'Min Fee B (constant)'
2056
+ },
2057
+ {
2058
+ $Type: 'UI.DataField',
2059
+ Value: priceMem,
2060
+ Label: 'Price Memory'
2061
+ },
2062
+ {
2063
+ $Type: 'UI.DataField',
2064
+ Value: priceStep,
2065
+ Label: 'Price Step'
2066
+ },
2067
+ {
2068
+ $Type: 'UI.DataField',
2069
+ Value: coinsPerUtxoSize,
2070
+ Label: 'Coins per UTxO Size'
2071
+ }
2072
+ ]},
2073
+
2074
+ UI.FieldGroup #SizeLimits : {Data: [
2075
+ {
2076
+ $Type: 'UI.DataField',
2077
+ Value: maxBlockSize,
2078
+ Label: 'Max Block Size'
2079
+ },
2080
+ {
2081
+ $Type: 'UI.DataField',
2082
+ Value: maxTxSize,
2083
+ Label: 'Max Transaction Size'
2084
+ },
2085
+ {
2086
+ $Type: 'UI.DataField',
2087
+ Value: maxBlockHeaderSize,
2088
+ Label: 'Max Block Header Size'
2089
+ },
2090
+ {
2091
+ $Type: 'UI.DataField',
2092
+ Value: maxValSize,
2093
+ Label: 'Max Value Size'
2094
+ }
2095
+ ]},
2096
+
2097
+ UI.FieldGroup #Deposits : {Data: [
2098
+ {
2099
+ $Type: 'UI.DataField',
2100
+ Value: keyDeposit,
2101
+ Label: 'Key Deposit'
2102
+ },
2103
+ {
2104
+ $Type: 'UI.DataField',
2105
+ Value: poolDeposit,
2106
+ Label: 'Pool Deposit'
2107
+ }
2108
+ ]},
2109
+
2110
+ UI.FieldGroup #ExecUnits : {Data: [
2111
+ {
2112
+ $Type: 'UI.DataField',
2113
+ Value: maxTxExMem,
2114
+ Label: 'Max Tx Execution Memory'
2115
+ },
2116
+ {
2117
+ $Type: 'UI.DataField',
2118
+ Value: maxTxExSteps,
2119
+ Label: 'Max Tx Execution Steps'
2120
+ },
2121
+ {
2122
+ $Type: 'UI.DataField',
2123
+ Value: maxBlockExMem,
2124
+ Label: 'Max Block Execution Memory'
2125
+ },
2126
+ {
2127
+ $Type: 'UI.DataField',
2128
+ Value: maxBlockExSteps,
2129
+ Label: 'Max Block Execution Steps'
2130
+ },
2131
+ {
2132
+ $Type: 'UI.DataField',
2133
+ Value: collateralPercent,
2134
+ Label: 'Collateral Percent'
2135
+ },
2136
+ {
2137
+ $Type: 'UI.DataField',
2138
+ Value: maxCollateralInputs,
2139
+ Label: 'Max Collateral Inputs'
2140
+ }
2141
+ ]},
2142
+
2143
+ UI.FieldGroup #PoolParams : {Data: [
2144
+ {
2145
+ $Type: 'UI.DataField',
2146
+ Value: nOpt,
2147
+ Label: 'Target Pool Count (nOpt)'
2148
+ },
2149
+ {
2150
+ $Type: 'UI.DataField',
2151
+ Value: a0,
2152
+ Label: 'Pledge Influence (a0)'
2153
+ },
2154
+ {
2155
+ $Type: 'UI.DataField',
2156
+ Value: rho,
2157
+ Label: 'Monetary Expansion (rho)'
2158
+ },
2159
+ {
2160
+ $Type: 'UI.DataField',
2161
+ Value: tau,
2162
+ Label: 'Treasury Cut (tau)'
2163
+ },
2164
+ {
2165
+ $Type: 'UI.DataField',
2166
+ Value: minPoolCost,
2167
+ Label: 'Min Pool Cost'
2168
+ },
2169
+ {
2170
+ $Type: 'UI.DataField',
2171
+ Value: eMax,
2172
+ Label: 'Pool Retirement Epochs'
2173
+ }
2174
+ ]}
2175
+ );
2176
+
2177
+ // ----------------------------------------------------------------------------
2178
+ // TransactionBuilds
2179
+ // ----------------------------------------------------------------------------
2180
+ annotate txsrv.TransactionBuilds with @(
2181
+ UI.HeaderInfo : {
2182
+ TypeName : 'Transaction Build',
2183
+ TypeNamePlural: 'Transaction Builds',
2184
+ Title : {Value: id},
2185
+ Description : {Value: network}
2186
+ },
2187
+
2188
+ UI.SelectionFields : [
2189
+ network,
2190
+ senderAddress,
2191
+ wasSubmitted
2192
+ ],
2193
+
2194
+ UI.LineItem : [
2195
+ {
2196
+ Value: id,
2197
+ Label: 'Build ID'
2198
+ },
2199
+ {
2200
+ Value: network,
2201
+ Label: 'Network'
2202
+ },
2203
+ {
2204
+ Value: builderEngine,
2205
+ Label: 'Builder Engine'
2206
+ },
2207
+ {
2208
+ Value: senderAddress,
2209
+ Label: 'Sender Address'
2210
+ },
2211
+ {
2212
+ Value: fee,
2213
+ Label: 'Estimated Fee'
2214
+ },
2215
+ {
2216
+ Value: size,
2217
+ Label: 'Size (bytes)'
2218
+ },
2219
+ {
2220
+ Value: wasSubmitted,
2221
+ Label: 'Submitted'
2222
+ },
2223
+ {
2224
+ $Type : 'UI.DataFieldForAction',
2225
+ Action: 'CardanoTransactionService.EntityContainer/BuildSimpleAdaTransaction',
2226
+ Label : 'Build Simple ADA Tx'
2227
+ },
2228
+ {
2229
+ $Type : 'UI.DataFieldForAction',
2230
+ Action: 'CardanoTransactionService.EntityContainer/BuildTransactionWithMetadata',
2231
+ Label : 'Build Tx with Metadata'
2232
+ }
2233
+ ],
2234
+
2235
+ UI.Identification : [
2236
+ {
2237
+ $Type : 'UI.DataFieldForAction',
2238
+ Action: 'CardanoTransactionService.EntityContainer/BuildSimpleAdaTransaction',
2239
+ Label : 'Build Simple ADA Tx'
2240
+ },
2241
+ {
2242
+ $Type : 'UI.DataFieldForAction',
2243
+ Action: 'CardanoTransactionService.EntityContainer/BuildTransactionWithMetadata',
2244
+ Label : 'Build Tx with Metadata'
2245
+ },
2246
+ {
2247
+ $Type : 'UI.DataFieldForAction',
2248
+ Action: 'CardanoTransactionService.EntityContainer/BuildMultiAssetTransaction',
2249
+ Label : 'Build Multi-Asset Tx'
2250
+ },
2251
+ {
2252
+ $Type : 'UI.DataFieldForAction',
2253
+ Action: 'CardanoTransactionService.EntityContainer/SubmitTransaction',
2254
+ Label : 'Submit Transaction'
2255
+ }
2256
+ ],
2257
+
2258
+ UI.HeaderFacets : [
2259
+ {
2260
+ $Type : 'UI.ReferenceFacet',
2261
+ Label : 'Fee',
2262
+ Target: '@UI.DataPoint#Fee'
2263
+ },
2264
+ {
2265
+ $Type : 'UI.ReferenceFacet',
2266
+ Label : 'Size',
2267
+ Target: '@UI.DataPoint#Size'
2268
+ },
2269
+ {
2270
+ $Type : 'UI.ReferenceFacet',
2271
+ Label : 'Status',
2272
+ Target: '@UI.DataPoint#Submitted'
2273
+ }
2274
+ ],
2275
+
2276
+ UI.DataPoint #Fee : {
2277
+ Value: fee,
2278
+ Title: 'Estimated Fee'
2279
+ },
2280
+ UI.DataPoint #Size : {
2281
+ Value: size,
2282
+ Title: 'Transaction Size'
2283
+ },
2284
+ UI.DataPoint #Submitted : {
2285
+ Value: wasSubmitted,
2286
+ Title: 'Was Submitted'
2287
+ },
2288
+
2289
+ UI.Facets : [
2290
+ {
2291
+ $Type : 'UI.ReferenceFacet',
2292
+ Label : 'Overview',
2293
+ Target: '@UI.FieldGroup#Overview'
2294
+ },
2295
+ {
2296
+ $Type : 'UI.ReferenceFacet',
2297
+ Label : 'Transaction Data',
2298
+ Target: '@UI.FieldGroup#TxData'
2299
+ },
2300
+ {
2301
+ $Type : 'UI.ReferenceFacet',
2302
+ Label : 'Inputs',
2303
+ Target : 'inputs/@UI.LineItem',
2304
+ ![@UI.Hidden]: (not hasInputs)
2305
+ },
2306
+ {
2307
+ $Type : 'UI.ReferenceFacet',
2308
+ Label : 'Outputs',
2309
+ Target : 'outputs/@UI.LineItem',
2310
+ ![@UI.Hidden]: (not hasOutputs)
2311
+ },
2312
+ {
2313
+ $Type : 'UI.ReferenceFacet',
2314
+ Label : 'Submission',
2315
+ Target : 'submission/@UI.FieldGroup#SubmissionDetails',
2316
+ ![@UI.Hidden]: (not wasSubmitted)
2317
+ }
2318
+ ],
2319
+
2320
+ UI.FieldGroup #Overview : {Data: [
2321
+ {
2322
+ $Type: 'UI.DataField',
2323
+ Value: id,
2324
+ Label: 'Build ID'
2325
+ },
2326
+ {
2327
+ $Type: 'UI.DataField',
2328
+ Value: network,
2329
+ Label: 'Network'
2330
+ },
2331
+ {
2332
+ $Type: 'UI.DataField',
2333
+ Value: builderEngine,
2334
+ Label: 'Builder Engine'
2335
+ },
2336
+ {
2337
+ $Type: 'UI.DataField',
2338
+ Value: senderAddress,
2339
+ Label: 'Sender Address'
2340
+ },
2341
+ {
2342
+ $Type: 'UI.DataField',
2343
+ Value: changeAddress,
2344
+ Label: 'Change Address'
2345
+ },
2346
+ {
2347
+ $Type: 'UI.DataField',
2348
+ Value: createdAt,
2349
+ Label: 'Created At'
2350
+ }
2351
+ ]},
2352
+
2353
+ UI.FieldGroup #TxData : {Data: [
2354
+ {
2355
+ $Type: 'UI.DataField',
2356
+ Value: txBodyHash,
2357
+ Label: 'Tx Body Hash'
2358
+ },
2359
+ {
2360
+ $Type: 'UI.DataField',
2361
+ Value: fee,
2362
+ Label: 'Estimated Fee'
2363
+ },
2364
+ {
2365
+ $Type: 'UI.DataField',
2366
+ Value: size,
2367
+ Label: 'Size (bytes)'
2368
+ },
2369
+ {
2370
+ $Type: 'UI.DataField',
2371
+ Value: unsignedTxCbor,
2372
+ Label: 'Unsigned Tx CBOR'
2373
+ }
2374
+ ]}
2375
+ );
2376
+
2377
+ // ----------------------------------------------------------------------------
2378
+ // TransactionBuildInputs
2379
+ // ----------------------------------------------------------------------------
2380
+ annotate txsrv.TransactionBuildInputs with @(
2381
+ UI.HeaderInfo : {
2382
+ TypeName : 'Build Input',
2383
+ TypeNamePlural: 'Build Inputs',
2384
+ Title : {Value: inputIndex},
2385
+ Description : {Value: address}
2386
+ },
2387
+
2388
+ UI.LineItem : [
2389
+ {
2390
+ Value: inputIndex,
2391
+ Label: 'Input Index'
2392
+ },
2393
+ {
2394
+ Value: txHash,
2395
+ Label: 'UTxO Tx Hash'
2396
+ },
2397
+ {
2398
+ Value: outputIndex,
2399
+ Label: 'UTxO Output Index'
2400
+ },
2401
+ {
2402
+ Value: address,
2403
+ Label: 'Address'
2404
+ },
2405
+ {
2406
+ Value: lovelace,
2407
+ Label: 'Lovelace'
2408
+ },
2409
+ {
2410
+ Value: hasAssets,
2411
+ Label: 'Has Assets'
2412
+ }
2413
+ ],
2414
+
2415
+ UI.HeaderFacets : [
2416
+ {
2417
+ $Type : 'UI.ReferenceFacet',
2418
+ Label : 'Lovelace',
2419
+ Target: '@UI.DataPoint#Lovelace'
2420
+ },
2421
+ {
2422
+ $Type : 'UI.ReferenceFacet',
2423
+ Label : 'Has Assets',
2424
+ Target: '@UI.DataPoint#HasAssets'
2425
+ }
2426
+ ],
2427
+
2428
+ UI.DataPoint #Lovelace : {
2429
+ Value: lovelace,
2430
+ Title: 'Lovelace Amount'
2431
+ },
2432
+ UI.DataPoint #HasAssets : {
2433
+ Value: hasAssets,
2434
+ Title: 'Has Assets'
2435
+ },
2436
+
2437
+ UI.Facets : [
2438
+ {
2439
+ $Type : 'UI.ReferenceFacet',
2440
+ Label : 'Assets',
2441
+ Target : 'assets/@UI.LineItem',
2442
+ ![@UI.Hidden]: (not hasAssets)
2443
+ },
2444
+ {
2445
+ $Type : 'UI.ReferenceFacet',
2446
+ Label : 'UTxO Details',
2447
+ Target: '@UI.FieldGroup#UTxODetails'
2448
+ }
2449
+ ],
2450
+
2451
+ UI.FieldGroup #UTxODetails: {Data: [
2452
+ {
2453
+ $Type: 'UI.DataField',
2454
+ Value: inputIndex,
2455
+ Label: 'Input Index'
2456
+ },
2457
+ {
2458
+ $Type: 'UI.DataField',
2459
+ Value: txHash,
2460
+ Label: 'UTxO Tx Hash'
2461
+ },
2462
+ {
2463
+ $Type: 'UI.DataField',
2464
+ Value: outputIndex,
2465
+ Label: 'UTxO Output Index'
2466
+ },
2467
+ {
2468
+ $Type: 'UI.DataField',
2469
+ Value: address,
2470
+ Label: 'Address'
2471
+ },
2472
+ {
2473
+ $Type: 'UI.DataField',
2474
+ Value: lovelace,
2475
+ Label: 'Lovelace'
2476
+ }
2477
+ ]}
2478
+ );
2479
+
2480
+ // ----------------------------------------------------------------------------
2481
+ // TransactionBuildInputAssets
2482
+ // ----------------------------------------------------------------------------
2483
+ annotate txsrv.TransactionBuildInputAssets with @(
2484
+ UI.HeaderInfo : {
2485
+ TypeName : 'Build Input Asset',
2486
+ TypeNamePlural: 'Build Input Assets',
2487
+ Title : {Value: unit}
2488
+ },
2489
+
2490
+ UI.LineItem : [
2491
+ {
2492
+ Value: unit,
2493
+ Label: 'Unit'
2494
+ },
2495
+ {
2496
+ Value: asset_quantity,
2497
+ Label: 'Quantity'
2498
+ },
2499
+ {
2500
+ Value: asset_policyId,
2501
+ Label: 'Policy ID'
2502
+ },
2503
+ {
2504
+ Value: asset_assetName,
2505
+ Label: 'Asset Name'
2506
+ },
2507
+ {
2508
+ Value: asset_fingerprint,
2509
+ Label: 'Fingerprint'
2510
+ }
2511
+ ],
2512
+
2513
+ UI.Facets : [{
2514
+ $Type : 'UI.ReferenceFacet',
2515
+ Label : 'Asset Details',
2516
+ Target: '@UI.FieldGroup#AssetDetails'
2517
+ }],
2518
+
2519
+ UI.FieldGroup #AssetDetails: {Data: [
2520
+ {
2521
+ $Type: 'UI.DataField',
2522
+ Value: unit,
2523
+ Label: 'Unit'
2524
+ },
2525
+ {
2526
+ $Type: 'UI.DataField',
2527
+ Value: asset_quantity,
2528
+ Label: 'Quantity'
2529
+ },
2530
+ {
2531
+ $Type: 'UI.DataField',
2532
+ Value: asset_policyId,
2533
+ Label: 'Policy ID'
2534
+ },
2535
+ {
2536
+ $Type: 'UI.DataField',
2537
+ Value: asset_assetNameHex,
2538
+ Label: 'Asset Name (Hex)'
2539
+ },
2540
+ {
2541
+ $Type: 'UI.DataField',
2542
+ Value: asset_assetName,
2543
+ Label: 'Asset Name'
2544
+ },
2545
+ {
2546
+ $Type: 'UI.DataField',
2547
+ Value: asset_fingerprint,
2548
+ Label: 'Fingerprint'
2549
+ }
2550
+ ]}
2551
+ );
2552
+
2553
+ // ----------------------------------------------------------------------------
2554
+ // TransactionBuildOutputs
2555
+ // ----------------------------------------------------------------------------
2556
+ annotate txsrv.TransactionBuildOutputs with @(
2557
+ UI.HeaderInfo : {
2558
+ TypeName : 'Build Output',
2559
+ TypeNamePlural: 'Build Outputs',
2560
+ Title : {Value: outputIndex},
2561
+ Description : {Value: address}
2562
+ },
2563
+
2564
+ UI.LineItem : [
2565
+ {
2566
+ Value: outputIndex,
2567
+ Label: 'Output Index'
2568
+ },
2569
+ {
2570
+ Value: address,
2571
+ Label: 'Recipient Address'
2572
+ },
2573
+ {
2574
+ Value: lovelace,
2575
+ Label: 'Lovelace'
2576
+ },
2577
+ {
2578
+ Value: isChange,
2579
+ Label: 'Is Change'
2580
+ },
2581
+ {
2582
+ Value: hasAssets,
2583
+ Label: 'Has Assets'
2584
+ }
2585
+ ],
2586
+
2587
+ UI.HeaderFacets : [
2588
+ {
2589
+ $Type : 'UI.ReferenceFacet',
2590
+ Label : 'Lovelace',
2591
+ Target: '@UI.DataPoint#Lovelace'
2592
+ },
2593
+ {
2594
+ $Type : 'UI.ReferenceFacet',
2595
+ Label : 'Is Change',
2596
+ Target: '@UI.DataPoint#IsChange'
2597
+ }
2598
+ ],
2599
+
2600
+ UI.DataPoint #Lovelace : {
2601
+ Value: lovelace,
2602
+ Title: 'Lovelace Amount'
2603
+ },
2604
+ UI.DataPoint #IsChange : {
2605
+ Value: isChange,
2606
+ Title: 'Change Output'
2607
+ },
2608
+
2609
+ UI.Facets : [
2610
+ {
2611
+ $Type : 'UI.ReferenceFacet',
2612
+ Label : 'Assets',
2613
+ Target : 'assets/@UI.LineItem',
2614
+ ![@UI.Hidden]: (not hasAssets)
2615
+ },
2616
+ {
2617
+ $Type : 'UI.ReferenceFacet',
2618
+ Label : 'Output Details',
2619
+ Target: '@UI.FieldGroup#OutputDetails'
2620
+ }
2621
+ ],
2622
+
2623
+ UI.FieldGroup #OutputDetails: {Data: [
2624
+ {
2625
+ $Type: 'UI.DataField',
2626
+ Value: outputIndex,
2627
+ Label: 'Output Index'
2628
+ },
2629
+ {
2630
+ $Type: 'UI.DataField',
2631
+ Value: address,
2632
+ Label: 'Recipient Address'
2633
+ },
2634
+ {
2635
+ $Type: 'UI.DataField',
2636
+ Value: lovelace,
2637
+ Label: 'Lovelace'
2638
+ },
2639
+ {
2640
+ $Type: 'UI.DataField',
2641
+ Value: isChange,
2642
+ Label: 'Is Change Output'
2643
+ }
2644
+ ]}
2645
+ );
2646
+
2647
+ // ----------------------------------------------------------------------------
2648
+ // TransactionBuildOutputAssets
2649
+ // ----------------------------------------------------------------------------
2650
+ annotate txsrv.TransactionBuildOutputAssets with @(
2651
+ UI.HeaderInfo : {
2652
+ TypeName : 'Build Output Asset',
2653
+ TypeNamePlural: 'Build Output Assets',
2654
+ Title : {Value: unit}
2655
+ },
2656
+
2657
+ UI.LineItem : [
2658
+ {
2659
+ Value: unit,
2660
+ Label: 'Unit'
2661
+ },
2662
+ {
2663
+ Value: asset_quantity,
2664
+ Label: 'Quantity'
2665
+ },
2666
+ {
2667
+ Value: asset_policyId,
2668
+ Label: 'Policy ID'
2669
+ },
2670
+ {
2671
+ Value: asset_assetName,
2672
+ Label: 'Asset Name'
2673
+ },
2674
+ {
2675
+ Value: asset_fingerprint,
2676
+ Label: 'Fingerprint'
2677
+ }
2678
+ ],
2679
+
2680
+ UI.Facets : [{
2681
+ $Type : 'UI.ReferenceFacet',
2682
+ Label : 'Asset Details',
2683
+ Target: '@UI.FieldGroup#AssetDetails'
2684
+ }],
2685
+
2686
+ UI.FieldGroup #AssetDetails: {Data: [
2687
+ {
2688
+ $Type: 'UI.DataField',
2689
+ Value: unit,
2690
+ Label: 'Unit'
2691
+ },
2692
+ {
2693
+ $Type: 'UI.DataField',
2694
+ Value: asset_quantity,
2695
+ Label: 'Quantity'
2696
+ },
2697
+ {
2698
+ $Type: 'UI.DataField',
2699
+ Value: asset_policyId,
2700
+ Label: 'Policy ID'
2701
+ },
2702
+ {
2703
+ $Type: 'UI.DataField',
2704
+ Value: asset_assetNameHex,
2705
+ Label: 'Asset Name (Hex)'
2706
+ },
2707
+ {
2708
+ $Type: 'UI.DataField',
2709
+ Value: asset_assetName,
2710
+ Label: 'Asset Name'
2711
+ },
2712
+ {
2713
+ $Type: 'UI.DataField',
2714
+ Value: asset_fingerprint,
2715
+ Label: 'Fingerprint'
2716
+ }
2717
+ ]}
2718
+ );
2719
+
2720
+ // ----------------------------------------------------------------------------
2721
+ // TransactionSubmissions
2722
+ // ----------------------------------------------------------------------------
2723
+ annotate txsrv.TransactionSubmissions with @(
2724
+ UI.HeaderInfo : {
2725
+ TypeName : 'Transaction Submission',
2726
+ TypeNamePlural: 'Transaction Submissions',
2727
+ Title : {Value: id},
2728
+ Description : {Value: status}
2729
+ },
2730
+
2731
+ UI.SelectionFields : [status],
2732
+
2733
+ UI.LineItem : [
2734
+ {
2735
+ Value: id,
2736
+ Label: 'Submission ID'
2737
+ },
2738
+ {
2739
+ Value: txHash,
2740
+ Label: 'Tx Hash'
2741
+ },
2742
+ {
2743
+ Value: status,
2744
+ Label: 'Status'
2745
+ },
2746
+ {
2747
+ Value: hasErrors,
2748
+ Label: 'Has Errors'
2749
+ },
2750
+ {
2751
+ $Type : 'UI.DataFieldForAction',
2752
+ Action: 'CardanoTransactionService.EntityContainer/SubmitTransaction',
2753
+ Label : 'Submit Transaction'
2754
+ },
2755
+ {
2756
+ $Type : 'UI.DataFieldForAction',
2757
+ Action: 'CardanoTransactionService.CheckSubmissionStatus',
2758
+ Label : 'Check Status'
2759
+ }
2760
+ ],
2761
+
2762
+ UI.Identification : [
2763
+ {
2764
+ $Type : 'UI.DataFieldForAction',
2765
+ Action: 'CardanoTransactionService.CheckSubmissionStatus',
2766
+ Label : 'Check Status'
2767
+ },
2768
+ {
2769
+ $Type : 'UI.DataFieldForAction',
2770
+ Action: 'CardanoTransactionService.EntityContainer/SubmitSignedTransaction',
2771
+ Label : 'Submit Signed Tx'
2772
+ }
2773
+ ],
2774
+
2775
+ UI.HeaderFacets : [
2776
+ {
2777
+ $Type : 'UI.ReferenceFacet',
2778
+ Label : 'Status',
2779
+ Target: '@UI.DataPoint#Status'
2780
+ }
2781
+ ],
2782
+
2783
+ UI.DataPoint #Status : {
2784
+ Value : status,
2785
+ Title : 'Submission Status',
2786
+ Criticality: status
2787
+ },
2788
+
2789
+ UI.Facets : [
2790
+ {
2791
+ $Type : 'UI.ReferenceFacet',
2792
+ Label : 'Submission Details',
2793
+ Target: '@UI.FieldGroup#SubmissionDetails'
2794
+ },
2795
+ {
2796
+ $Type : 'UI.ReferenceFacet',
2797
+ Label : 'Error Details',
2798
+ Target : '@UI.FieldGroup#ErrorDetails',
2799
+ ![@UI.Hidden]: (not hasErrors)
2800
+ },
2801
+ {
2802
+ $Type : 'UI.ReferenceFacet',
2803
+ Label : 'Errors',
2804
+ Target : 'errors/@UI.LineItem',
2805
+ ![@UI.Hidden]: (not hasErrors)
2806
+ }
2807
+ ],
2808
+
2809
+ UI.FieldGroup #SubmissionDetails: {Data: [
2810
+ {
2811
+ $Type: 'UI.DataField',
2812
+ Value: id,
2813
+ Label: 'Submission ID'
2814
+ },
2815
+ {
2816
+ $Type: 'UI.DataField',
2817
+ Value: txHash,
2818
+ Label: 'Transaction Hash'
2819
+ },
2820
+ {
2821
+ $Type: 'UI.DataField',
2822
+ Value: status,
2823
+ Label: 'Status'
2824
+ },
2825
+ {
2826
+ $Type: 'UI.DataField',
2827
+ Value: signedTxCbor,
2828
+ Label: 'Signed Tx CBOR'
2829
+ }
2830
+ ]},
2831
+
2832
+ UI.FieldGroup #ErrorDetails : {Data: [
2833
+ {
2834
+ $Type: 'UI.DataField',
2835
+ Value: errorCode,
2836
+ Label: 'Error Code'
2837
+ },
2838
+ {
2839
+ $Type: 'UI.DataField',
2840
+ Value: errorMessage,
2841
+ Label: 'Error Message'
2842
+ }
2843
+ ]}
2844
+ );
2845
+
2846
+ // ----------------------------------------------------------------------------
2847
+ // TransactionSubmissionErrors
2848
+ // ----------------------------------------------------------------------------
2849
+ annotate txsrv.TransactionSubmissionErrors with @(
2850
+ UI.HeaderInfo : {
2851
+ TypeName : 'Submission Error',
2852
+ TypeNamePlural: 'Submission Errors',
2853
+ Title : {Value: errorType},
2854
+ Description : {Value: errorCode}
2855
+ },
2856
+
2857
+ UI.LineItem : [
2858
+ {
2859
+ Value: id,
2860
+ Label: 'Error ID'
2861
+ },
2862
+ {
2863
+ Value: errorType,
2864
+ Label: 'Error Type'
2865
+ },
2866
+ {
2867
+ Value: errorCode,
2868
+ Label: 'Error Code'
2869
+ },
2870
+ {
2871
+ Value: errorMessage,
2872
+ Label: 'Error Message'
2873
+ },
2874
+ {
2875
+ Value: occurredAt,
2876
+ Label: 'Occurred At'
2877
+ },
2878
+ {
2879
+ Value: isRecoverable,
2880
+ Label: 'Recoverable'
2881
+ }
2882
+ ],
2883
+
2884
+ UI.HeaderFacets : [
2885
+ {
2886
+ $Type : 'UI.ReferenceFacet',
2887
+ Label : 'Error Type',
2888
+ Target: '@UI.DataPoint#ErrorType'
2889
+ },
2890
+ {
2891
+ $Type : 'UI.ReferenceFacet',
2892
+ Label : 'Recoverable',
2893
+ Target: '@UI.DataPoint#Recoverable'
2894
+ }
2895
+ ],
2896
+
2897
+ UI.DataPoint #ErrorType : {
2898
+ Value: errorType,
2899
+ Title: 'Error Type'
2900
+ },
2901
+ UI.DataPoint #Recoverable: {
2902
+ Value: isRecoverable,
2903
+ Title: 'Is Recoverable'
2904
+ },
2905
+
2906
+ UI.Facets : [{
2907
+ $Type : 'UI.ReferenceFacet',
2908
+ Label : 'Error Details',
2909
+ Target: '@UI.FieldGroup#ErrorDetails'
2910
+ }],
2911
+
2912
+ UI.FieldGroup #ErrorDetails: {Data: [
2913
+ {
2914
+ $Type: 'UI.DataField',
2915
+ Value: id,
2916
+ Label: 'Error ID'
2917
+ },
2918
+ {
2919
+ $Type: 'UI.DataField',
2920
+ Value: errorType,
2921
+ Label: 'Error Type'
2922
+ },
2923
+ {
2924
+ $Type: 'UI.DataField',
2925
+ Value: errorCode,
2926
+ Label: 'Error Code'
2927
+ },
2928
+ {
2929
+ $Type: 'UI.DataField',
2930
+ Value: errorMessage,
2931
+ Label: 'Error Message'
2932
+ },
2933
+ {
2934
+ $Type: 'UI.DataField',
2935
+ Value: errorDetails,
2936
+ Label: 'Error Details (JSON)'
2937
+ },
2938
+ {
2939
+ $Type: 'UI.DataField',
2940
+ Value: occurredAt,
2941
+ Label: 'Occurred At'
2942
+ },
2943
+ {
2944
+ $Type: 'UI.DataField',
2945
+ Value: isRecoverable,
2946
+ Label: 'Is Recoverable'
2947
+ }
2948
+ ]}
2949
+ );