From 99697943a45c384183bceb445ce69fd84eb179a1 Mon Sep 17 00:00:00 2001 From: spearec Date: Mon, 26 Jun 2023 12:45:05 +0000 Subject: [PATCH] requested changes --- src/client/app/actions/admin.ts | 2 -- .../containers/maps/MapCalibrationChartDisplayContainer.ts | 1 - src/client/app/utils/api/ReadingsApi.ts | 4 ++-- src/client/app/utils/calculateCompare.ts | 4 ++-- 4 files changed, 4 insertions(+), 7 deletions(-) diff --git a/src/client/app/actions/admin.ts b/src/client/app/actions/admin.ts index 186f49c6d..cf1e4a932 100644 --- a/src/client/app/actions/admin.ts +++ b/src/client/app/actions/admin.ts @@ -76,8 +76,6 @@ function markPreferencesSubmitted(defaultMeterReadingFrequency: string): t.MarkP return { type: ActionType.MarkPreferencesSubmitted, defaultMeterReadingFrequency }; } -/* eslint-enable */ - /** * Dispatches a fetch for admin preferences and sets the state based upon the result */ diff --git a/src/client/app/containers/maps/MapCalibrationChartDisplayContainer.ts b/src/client/app/containers/maps/MapCalibrationChartDisplayContainer.ts index d127a2b24..7d1661b87 100644 --- a/src/client/app/containers/maps/MapCalibrationChartDisplayContainer.ts +++ b/src/client/app/containers/maps/MapCalibrationChartDisplayContainer.ts @@ -99,7 +99,6 @@ function mapStateToProps(state: State) { return props; } -/* eslint-enable */ /** * use a transparent heatmap to capture which point the user clicked on the map * @param imageDimensions Normalized dimensions of the image diff --git a/src/client/app/utils/api/ReadingsApi.ts b/src/client/app/utils/api/ReadingsApi.ts index 55b3bbc75..b06be5bf5 100644 --- a/src/client/app/utils/api/ReadingsApi.ts +++ b/src/client/app/utils/api/ReadingsApi.ts @@ -60,7 +60,7 @@ export default class ReadingsApi { * @param timeInterval The range of time to get readings for * @param barWidthDays The width of the bar in days * @param unitID The unit id that the reading should be returned in, i.e., the graphic unit - * @returns LineReadings in sorted order + * @returns BarReadings in sorted order */ public async meterBarReadings(meterIDs: number[], timeInterval: TimeInterval, barWidthDays: number, unitID: number): Promise { const stringifiedIDs = meterIDs.join(','); @@ -76,7 +76,7 @@ export default class ReadingsApi { * @param timeInterval The range of time to get readings for * @param barWidthDays The width of the bar in days * @param unitID The unit id that the reading should be returned in, i.e., the graphic unit - * @returns LineReadings in sorted order + * @returns BarReadings in sorted order */ public async groupBarReadings(groupIDs: number[], timeInterval: TimeInterval, barWidthDays: number, unitID: number): Promise { const stringifiedIDs = groupIDs.join(','); diff --git a/src/client/app/utils/calculateCompare.ts b/src/client/app/utils/calculateCompare.ts index a930de9d1..499c5bac1 100644 --- a/src/client/app/utils/calculateCompare.ts +++ b/src/client/app/utils/calculateCompare.ts @@ -156,7 +156,7 @@ export interface ComparePeriodLabels { /** * Determines the human-readable names of a comparison period. * @param comparePeriod the machine-readable name of the period - * @returns human-readable names for the compare period + * @returns human-readable names for the compare period as {{prev: string, current: string}} */ export function getComparePeriodLabels(comparePeriod: ComparePeriod): ComparePeriodLabels { switch (comparePeriod) { @@ -176,7 +176,7 @@ export function getComparePeriodLabels(comparePeriod: ComparePeriod): ComparePer * Composes a label to summarize compare chart data. * @param change the ratio of change between the current and previous period * @param name the name of the entity being measured - * @param labels the names of the periods in question + * @param labels the names of the periods in question as {{prev: string, current: string}} * @returns The label summary */ export function getCompareChangeSummary(change: number, name: string, labels: ComparePeriodLabels): string {