fixed : dynamic btid in shared display
This commit is contained in:
parent
72b00c71eb
commit
0c5a48e8af
@ -1,6 +1,6 @@
|
|||||||
<!-- Navbar for the shared display -->
|
<!-- Navbar for the shared display -->
|
||||||
<div class="shared-navbar custom-navbar-style d-flex justify-content-between align-items-center px-4 py-2">
|
<div class="shared-navbar custom-navbar-style d-flex justify-content-between align-items-center px-4 py-2">
|
||||||
<div class="text-start"><strong>B.T.No:</strong> 1111</div>
|
<div class="text-start"><strong>B.T.No:</strong> {{ btid }}</div>
|
||||||
<div class="text-center"><strong>Venue:</strong> {{ selectedVenue }}</div>
|
<div class="text-center"><strong>Venue:</strong> {{ selectedVenue }}</div>
|
||||||
<div class="text-end"><strong>Race No:</strong> {{ selectedRace }}</div>
|
<div class="text-end"><strong>Race No:</strong> {{ selectedRace }}</div>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@ -13,6 +13,7 @@ interface SharedData {
|
|||||||
salesTotal: number;
|
salesTotal: number;
|
||||||
receiveTotal: number;
|
receiveTotal: number;
|
||||||
totalClicks: number;
|
totalClicks: number;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
@ -31,6 +32,8 @@ export class SharedDisplayComponent implements OnInit {
|
|||||||
{ col1: 'Payout', col2: 0, col3: 0 },
|
{ col1: 'Payout', col2: 0, col3: 0 },
|
||||||
{ col1: 'Receive', col2: 0, col3: 0 },
|
{ col1: 'Receive', col2: 0, col3: 0 },
|
||||||
];
|
];
|
||||||
|
|
||||||
|
btid: string | null = null;
|
||||||
filledRows: SelectionData[] = Array.from({ length: 5 }, () => ({
|
filledRows: SelectionData[] = Array.from({ length: 5 }, () => ({
|
||||||
label: '',
|
label: '',
|
||||||
numbers: [],
|
numbers: [],
|
||||||
@ -49,7 +52,7 @@ export class SharedDisplayComponent implements OnInit {
|
|||||||
|
|
||||||
ngOnInit(): void {
|
ngOnInit(): void {
|
||||||
console.log('[SHARED DISPLAY] Initializing, electronAPI available:', !!window.electronAPI);
|
console.log('[SHARED DISPLAY] Initializing, electronAPI available:', !!window.electronAPI);
|
||||||
|
this.btid = localStorage.getItem('btid');
|
||||||
this.sharedStateService.sharedData$.subscribe((data) => {
|
this.sharedStateService.sharedData$.subscribe((data) => {
|
||||||
console.log('[SHARED DISPLAY] Received shared data:', data);
|
console.log('[SHARED DISPLAY] Received shared data:', data);
|
||||||
if (!data) return;
|
if (!data) return;
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user