Add onboarding weather and template gradients
This commit is contained in:
@@ -25,7 +25,17 @@ function enrichScreensWithConnections(screens, connectionsBySlug, onboardingName
|
||||
function buildClientRows(screens, connectionsBySlug, onboardingNameBySlug, onboardingNameByDeviceId, playerIdentifierByBaseUrl, formatDashboardDate) {
|
||||
return (screens || []).flatMap(function (screen) {
|
||||
const connectionState = connectionsBySlug[screen.slug] || { count: 0, connections: [] };
|
||||
return (connectionState.connections || []).map(function (connection) {
|
||||
const seenClientKeys = new Set();
|
||||
return (connectionState.connections || []).filter(function (connection) {
|
||||
const deviceId = String(connection && connection.deviceId || '').trim();
|
||||
const clientId = String(connection && connection.clientId || '').trim();
|
||||
const key = deviceId && clientId ? `${deviceId}:${clientId}` : String(connection && connection.id || '').trim();
|
||||
if (seenClientKeys.has(key)) {
|
||||
return false;
|
||||
}
|
||||
seenClientKeys.add(key);
|
||||
return true;
|
||||
}).map(function (connection) {
|
||||
const deviceId = String(connection.deviceId || '').trim();
|
||||
const playerBaseUrl = normalizePlayerBaseUrl(connection.playerPublicBaseUrl);
|
||||
return Object.assign({}, connection, {
|
||||
|
||||
Reference in New Issue
Block a user