diff --git a/myems-api/core/utilities.py b/myems-api/core/utilities.py index 8cfa9e19..edf55e4e 100644 --- a/myems-api/core/utilities.py +++ b/myems-api/core/utilities.py @@ -12,7 +12,7 @@ import statistics # rows_hourly: list of (start_datetime_utc, actual_value), should belong to one energy_category_id # start_datetime_utc: start datetime in utc # end_datetime_utc: end datetime in utc -# period_type: one of the following period types, 'hourly', 'daily', 'weekly', 'monthly' and 'yearly' +# period_type: use one of the period types, 'hourly', 'daily', 'weekly', 'monthly' and 'yearly' # Note: this procedure doesn't work with multiple energy categories ######################################################################################################################## def aggregate_hourly_data_by_period(rows_hourly, start_datetime_utc, end_datetime_utc, period_type): @@ -403,7 +403,7 @@ def get_energy_category_peak_types(cost_center_id, energy_category_id, start_dat # rows_hourly: list of (start_datetime_utc, actual_value), should belong to one energy_category_id # start_datetime_utc: start datetime in utc # end_datetime_utc: end datetime in utc -# period_type: one of the following period types, 'hourly', 'daily', 'monthly' and 'yearly' +# period_type: use one of the period types, 'hourly', 'daily', 'weekly', 'monthly' and 'yearly' # Returns: periodically data of average and maximum # Note: this procedure doesn't work with multiple energy categories ######################################################################################################################## @@ -692,7 +692,7 @@ def averaging_hourly_data_by_period(rows_hourly, start_datetime_utc, end_datetim # rows_hourly: list of (start_datetime_utc, actual_value), should belong to one energy_category_id # start_datetime_utc: start datetime in utc # end_datetime_utc: end datetime in utc -# period_type: one of the following period types, 'hourly', 'daily', 'monthly' and 'yearly' +# period_type: use one of the period types, 'hourly', 'daily', 'weekly', 'monthly' and 'yearly' # Returns: periodically data of values and statistics of mean, median, minimum, maximum, stdev and variance # Note: this procedure doesn't work with multiple energy categories ######################################################################################################################## diff --git a/myems-api/reports/tenantbill.py b/myems-api/reports/tenantbill.py index a748ecce..c5320de8 100644 --- a/myems-api/reports/tenantbill.py +++ b/myems-api/reports/tenantbill.py @@ -34,7 +34,7 @@ class Reporting: tenant_id = req.params.get('tenantid') reporting_start_datetime_local = req.params.get('reportingperiodstartdatetime') reporting_end_datetime_local = req.params.get('reportingperiodenddatetime') - + # This value is intentionally left daily period_type = 'daily' ################################################################################################################ diff --git a/web/src/i18n.js b/web/src/i18n.js index 35ac6409..e8f0b1ff 100644 --- a/web/src/i18n.js +++ b/web/src/i18n.js @@ -122,6 +122,7 @@ const resources = { "Period Types": "Period Types", "Yearly": "Yearly", "Monthly": "Monthly", + "Weekly": "Weekly", "Daily": "Daily", "Hourly": "Hourly", "Submit": "Submit", @@ -867,6 +868,7 @@ const resources = { "Period Types": "Periodentypen", "Yearly": "Jährlich", "Monthly": "Monatlich", + "Weekly": "Wöchentlich", "Daily": "Täglich", "Hourly": "Stündlich", "Submit": "einreichen",