If mining dashboard is enabled, shows pools instead of timestamp

This commit is contained in:
nymkappa
2022-03-17 18:17:22 +01:00
parent 7481e27ec2
commit a7900f6466
4 changed files with 30 additions and 3 deletions

View File

@@ -149,6 +149,15 @@ export class DashboardComponent implements OnInit {
}
acc.unshift(block);
acc = acc.slice(0, 6);
if (this.stateService.env.MINING_DASHBOARD === true) {
for (const block of acc) {
// @ts-ignore: Need to add an extra field for the template
block.extras.pool.logo = `./resources/mining-pools/` +
block.extras.pool.name.toLowerCase().replace(' ', '').replace('.', '') + '.svg';
}
}
return acc;
}, []),
);