Skip to content

Commit

Permalink
Updates dashboard and datasources to revamped dashboard.
Browse files Browse the repository at this point in the history
  • Loading branch information
dbernstein committed Dec 5, 2024
1 parent db1a285 commit 286be7c
Show file tree
Hide file tree
Showing 3 changed files with 4,285 additions and 3,272 deletions.
18 changes: 9 additions & 9 deletions assets/data-sets/circulation_view.json
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
{
"Name": "circulation_view",
"PhysicalTableMap": {
"25046cd8-e08f-41e0-8af8-5259b64499fd": {
"5037a5a4-0ba1-470b-b5ef-0eb9e4a42917": {
"CustomSql": {
"DataSourceArn": "",
"Name": "circulation_events_view",
"SqlQuery": "select \n ce.time_stamp, \n l.short_name as libary_short_name, \n l.name as library_name,\n l.location as location,\n et.name as event_type, \n i.identifier,\n it.name as identifier_type,\n c.name as collection_name, \n ce.title, \n ce.author,\n ce.audience,\n ce.publisher,\n ce.language,\n ce.genre,\n ce.open_access,\n ce.fiction,\n ce.distributor,\n ce.medium\nfrom \n circulation_events ce,\n libraries l,\n collections c,\n circulation_event_types et,\n identifiers i,\n identifier_types it\nwhere \n ce.library_id = l.id and\n ce.event_type_id = et.id and\n ce.collection_id = c.id and\n ce.identifier_id = i.id and \n i.identifier_type_id = it.id",
"SqlQuery": "select \n ce.time_stamp, \n l.short_name as libary_short_name, \n l.name as library_name,\n l.location as location,\n et.name as event_type, \n i.identifier,\n it.name as identifier_type,\n c.name as collection_name, \n ce.title, \n ce.author,\n ce.audience,\n ce.publisher,\n ce.language,\n ce.genre,\n CASE\n WHEN ce.open_access = 1 THEN 'yes'\n WHEN ce.open_access = 0 THEN 'no'\n ELSE 'unspecified'\n END as open_access,\n CASE\n WHEN ce.fiction = 1 THEN 'fiction'\n WHEN ce.fiction = 0 THEN 'nonfiction'\n ELSE 'unspecified'\n END as fiction,\n ce.distributor,\n ce.medium\nfrom \n circulation_events ce,\n libraries l,\n collections c,\n circulation_event_types et,\n identifiers i,\n identifier_types it\nwhere \n ce.library_id = l.id and\n ce.event_type_id = et.id and\n ce.collection_id = c.id and\n ce.identifier_id = i.id and \n i.identifier_type_id = it.id",
"Columns": [
{
"Name": "time_stamp",
Expand Down Expand Up @@ -65,11 +65,11 @@
},
{
"Name": "open_access",
"Type": "BIT"
"Type": "STRING"
},
{
"Name": "fiction",
"Type": "BIT"
"Type": "STRING"
},
{
"Name": "distributor",
Expand All @@ -84,7 +84,7 @@
}
},
"LogicalTableMap": {
"6c80275e-d03d-417c-a8cd-57d93e58129b": {
"1fddc8ca-0639-4e98-a807-829990c9eb70": {
"Alias": "circulation_events_view",
"DataTransforms": [
{
Expand Down Expand Up @@ -113,7 +113,7 @@
}
],
"Source": {
"PhysicalTableId": "25046cd8-e08f-41e0-8af8-5259b64499fd"
"PhysicalTableId": "5037a5a4-0ba1-470b-b5ef-0eb9e4a42917"
}
}
},
Expand Down Expand Up @@ -176,11 +176,11 @@
},
{
"Name": "open_access",
"Type": "INTEGER"
"Type": "STRING"
},
{
"Name": "fiction",
"Type": "INTEGER"
"Type": "STRING"
},
{
"Name": "distributor",
Expand All @@ -192,7 +192,7 @@
}
],
"ImportMode": "SPICE",
"ConsumedSpiceCapacityInBytes": 1474571,
"ConsumedSpiceCapacityInBytes": 1619516442,
"FieldFolders": {},
"RowLevelPermissionTagConfiguration": {
"Status": "ENABLED",
Expand Down
19 changes: 14 additions & 5 deletions assets/data-sets/patron_events.json
Original file line number Diff line number Diff line change
@@ -1,16 +1,20 @@
{
"Name": "patron_events",
"PhysicalTableMap": {
"50873ea6-0c3a-4989-97e1-eb740e8a3348": {
"7bff0b9c-4864-4c14-ac5c-5fb751f0f48e": {
"CustomSql": {
"DataSourceArn": "",
"Name": "patron_events",
"SqlQuery": "select \n pe.time_stamp, \n l.short_name as library_short_name, \n l.name as library_name, \n l.location, \n l.state, \n ev.name as event_type \nfrom \n patron_events pe, \n libraries l, \n circulation_event_types ev \nwhere \n pe.library_id = l.id and \n pe.event_type_id = ev.id",
"SqlQuery": "select \n pe.time_stamp, \n pe.patron_uuid,\n l.short_name as library_short_name, \n l.name as library_name, \n l.location, \n l.state, \n ev.name as event_type \nfrom \n patron_events pe, \n libraries l, \n circulation_event_types ev \nwhere \n pe.library_id = l.id and \n pe.event_type_id = ev.id",
"Columns": [
{
"Name": "time_stamp",
"Type": "DATETIME"
},
{
"Name": "patron_uuid",
"Type": "STRING"
},
{
"Name": "library_short_name",
"Type": "STRING"
Expand All @@ -36,13 +40,14 @@
}
},
"LogicalTableMap": {
"4dc4e51c-76b2-4595-8b3b-1759f76a05c4": {
"d42c9db8-b6e9-4774-8324-b9f9d9f58a68": {
"Alias": "patron_events",
"DataTransforms": [
{
"ProjectOperation": {
"ProjectedColumns": [
"time_stamp",
"patron_uuid",
"library_short_name",
"library_name",
"location",
Expand All @@ -53,7 +58,7 @@
}
],
"Source": {
"PhysicalTableId": "50873ea6-0c3a-4989-97e1-eb740e8a3348"
"PhysicalTableId": "7bff0b9c-4864-4c14-ac5c-5fb751f0f48e"
}
}
},
Expand All @@ -62,6 +67,10 @@
"Name": "time_stamp",
"Type": "DATETIME"
},
{
"Name": "patron_uuid",
"Type": "STRING"
},
{
"Name": "library_short_name",
"Type": "STRING"
Expand All @@ -84,7 +93,7 @@
}
],
"ImportMode": "SPICE",
"ConsumedSpiceCapacityInBytes": 16444,
"ConsumedSpiceCapacityInBytes": 73990702,
"FieldFolders": {},
"RowLevelPermissionTagConfiguration": {
"Status": "ENABLED",
Expand Down
Loading

0 comments on commit 286be7c

Please sign in to comment.