refactoring
This commit is contained in:
@@ -126,8 +126,8 @@ class BatchCodeTableInitializer {
|
|||||||
#getBarChartDescription(barChartDescriptions, batchcode) {
|
#getBarChartDescription(barChartDescriptions, batchcode) {
|
||||||
const barChartDescription = barChartDescriptions.barChartDescriptions[batchcode];
|
const barChartDescription = barChartDescriptions.barChartDescriptions[batchcode];
|
||||||
barChartDescription.batchcode = batchcode;
|
barChartDescription.batchcode = batchcode;
|
||||||
barChartDescription['dateRange guessed'] = barChartDescriptions['dateRange guessed'];
|
barChartDescription['date range guessed'] = barChartDescriptions['date range guessed'];
|
||||||
barChartDescription['dateRange before deletion'] = barChartDescriptions['dateRange before deletion'];
|
barChartDescription['date range known'] = barChartDescriptions['date range known'];
|
||||||
return barChartDescription;
|
return barChartDescription;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -31,11 +31,11 @@ class BatchcodeByCountryBarChart {
|
|||||||
labels: barChartDescription.countries,
|
labels: barChartDescription.countries,
|
||||||
datasets: [
|
datasets: [
|
||||||
{
|
{
|
||||||
label: `known (${this.#dateRange2str(barChartDescription['dateRange before deletion'])})`,
|
label: `known (${this.#dateRange2str(barChartDescription['date range known'])})`,
|
||||||
data: barChartDescription["frequencies before deletion"]
|
data: barChartDescription["frequencies before deletion"]
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: `guessed (${this.#dateRange2str(barChartDescription['dateRange guessed'])})`,
|
label: `guessed (${this.#dateRange2str(barChartDescription['date range guessed'])})`,
|
||||||
data: barChartDescription["frequencies guessed"]
|
data: barChartDescription["frequencies guessed"]
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
|||||||
File diff suppressed because one or more lines are too long
@@ -7,8 +7,8 @@ class BarChartDescriptionTable2DictionaryConverter:
|
|||||||
@staticmethod
|
@staticmethod
|
||||||
def convert2Dictionary(barChartDescriptionTable):
|
def convert2Dictionary(barChartDescriptionTable):
|
||||||
return {
|
return {
|
||||||
'dateRange guessed': BarChartDescriptionTable2DictionaryConverter.dateRange2Str(GoogleAnalyticsReader(dataDir='data/GoogleAnalytics').getDateRange()),
|
'date range guessed': BarChartDescriptionTable2DictionaryConverter.dateRange2Str(GoogleAnalyticsReader(dataDir='data/GoogleAnalytics').getDateRange()),
|
||||||
'dateRange before deletion': BarChartDescriptionTable2DictionaryConverter.dateRange2Str(getDateRangeOfVAERSReportsBeforeDeletionOfCountryCodes()),
|
'date range known': BarChartDescriptionTable2DictionaryConverter.dateRange2Str(getDateRangeOfVAERSReportsBeforeDeletionOfCountryCodes()),
|
||||||
'barChartDescriptions': barChartDescriptionTable['BAR_CHART_DESCRIPTION'].to_dict()
|
'barChartDescriptions': barChartDescriptionTable['BAR_CHART_DESCRIPTION'].to_dict()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user