Skip to content
Snippets Groups Projects
Commit 2a180988 authored by Bastien DUMONT's avatar Bastien DUMONT :angel:
Browse files

Merge remote-tracking branch 'origin/dev' into feat/us675-matomo

parents 3308772a 478d6a1b
No related branches found
No related tags found
2 merge requests!624Feat/us780 matomo opt out,!515Feat/us675 matomo
Showing
with 338 additions and 147 deletions
## Description du problème
(Donnez une description briève du problème)
## L'environnement
* Utilisez vous l'application sur:
- [ ] Mobile
- [ ] Ordinateur
(Mettez un x dans la case correspondante)
* En cas de mobile:
- Quel type de mobile utilisez-vous?
- [ ] Android
- [ ] iphone / iOS
(Mettez un x dans la case correspondante)
- Quel navigateur utilisez-vous?
- [ ] Chrome
- [ ] Safari
- [ ] Autre
(Mettez un x dans la case correspondante)
* En cas d'ordinateur:
- Quel navigateur utilisez-vous?
- [ ] Chrome
- [ ] Firefox
- [ ] Safari
- [ ] Autre
(Mettez un x dans la case correspondante)
## Le problème
- Quelles sont les étapes réalisée qui ont menées au problème?
(Donnez une description des étapes, celle-ci peut être appuyé par des captures d'écran)
- Quel est le comportement obtenu?
(Donnez une description du comportement obtenu, celle-ci peut être appuyé par des captures d'écran)
- Quel est le comportement attendu?
(Donnez une description du comportement attendu)
/title [Scope] Description
### Résumé du problème
_Donnez une description briève du problème._
### L'environnement
1. Utilisez vous l'application sur:
- [ ] Mobile
- [ ] Ordinateur
- En cas de mobile, quel type de mobile utilisez-vous ?
- [ ] Android
- [ ] iphone / iOS
2. Quel navigateur utilisez-vous ?
- [ ] Chrome
- [ ] Firefox
- [ ] Safari
- [ ] Autre
### Les étapes pour reproduire le bug
_Listez les étapes qui vous permettent de reproduire ce bug, cette étape est très importante._
### Décrivez le comportement du _bug_ ?
### Quel serez le comportement _attendu_ ?
### Logs et/ou screenshots
### Possible fixes
/label ~"type::bug"
/label ~"type::ecolyo"
/title [Konnecteur] Description
### Résumé du problème
_Donnez une briève description du problème._
### Les étapes pour reproduire le bug
_Listez les étapes qui vous permettent de reproduire ce bug, cette étape est très importante._
### Décrivez le comportement du _bug_ ?
### Quel serez le comportement _attendu_ ?
### Logs et/ou screenshots
### Possible fixes
/label ~"type::bug"
/label ~"type::konnector"
/title [Scope] Description
### Résumé du problème
_Donnez une description briève du problème._
### Les étapes pour reproduire le bug
_Listez les étapes qui vous permettent de reproduire ce bug, cette étape est très importante._
### Décrivez le comportement du _bug_ ?
### Quel serez le comportement _attendu_ ?
### Logs et/ou screenshots
### Possible fixes
/label ~"type::bug"
......@@ -11,15 +11,20 @@ import { newProfileEcogestureEntry } from 'store/profileEcogesture/profileEcoges
import { useDispatch } from 'react-redux'
import { updateProfile } from 'store/profile/profile.actions'
import { useHistory } from 'react-router-dom'
import { ProfileTypeStepForm } from 'enum/profileType.enum'
interface EcogestureFormEquipmentProps {
profileEcogesture: ProfileEcogesture
setPreviousStep: Function
setNextStep?: Function
step: ProfileTypeStepForm | EcogestureStepForm
}
const EcogestureFormEquipment: React.FC<EcogestureFormEquipmentProps> = ({
profileEcogesture,
setPreviousStep,
setNextStep,
step,
}: EcogestureFormEquipmentProps) => {
const { t } = useI18n()
const dispatch = useDispatch()
......@@ -30,12 +35,13 @@ const EcogestureFormEquipment: React.FC<EcogestureFormEquipmentProps> = ({
setPreviousStep(profileEcogesture)
}, [profileEcogesture, setPreviousStep])
const handleFinish = useCallback(() => {
const handleNext = useCallback(() => {
profileEcogesture.equipments = answer as EquipmentType[]
dispatch(newProfileEcogestureEntry(profileEcogesture))
dispatch(updateProfile({ isProfileEcogestureCompleted: true }))
history.push('/ecogesture-selection')
}, [profileEcogesture, answer, dispatch, history])
// Check if gestureForm is used from Big profile or small profile
setNextStep ? setNextStep() : history.push('/ecogesture-selection')
}, [profileEcogesture, setNextStep, answer, dispatch, history])
const isChecked = useCallback(
(value: string): boolean => {
......@@ -103,9 +109,9 @@ const EcogestureFormEquipment: React.FC<EcogestureFormEquipmentProps> = ({
</div>
</div>
<FormNavigation
step={EcogestureStepForm.EQUIPMENTS}
step={step}
handlePrevious={handlePrevious}
handleNext={handleFinish}
handleNext={handleNext}
disableNextButton={answer === []}
isEcogesture={true}
/>
......
......@@ -128,6 +128,7 @@ const EcogestureFormView: React.FC = () => {
<Content height={headerHeight}>
{step === EcogestureStepForm.EQUIPMENTS && (
<EcogestureFormEquipment
step={EcogestureStepForm.EQUIPMENTS}
profileEcogesture={profileEcogesture}
setPreviousStep={setPreviousStep}
/>
......
......@@ -305,7 +305,6 @@ exports[`EcogestureFormEquipment component should be rendered correctly 1`] = `
handleNext={[Function]}
handlePrevious={[Function]}
isEcogesture={true}
step={3}
>
<div
className="profile-navigation"
......@@ -448,7 +447,7 @@ exports[`EcogestureFormEquipment component should be rendered correctly 1`] = `
</ForwardRef(Button)>
</WithStyles(ForwardRef(Button))>
<WithStyles(ForwardRef(Button))
aria-label="profile_type.accessibility.button_end"
aria-label="profile_type.accessibility.button_next"
className="profile-navigation-button"
classes={
Object {
......@@ -460,7 +459,7 @@ exports[`EcogestureFormEquipment component should be rendered correctly 1`] = `
onClick={[Function]}
>
<ForwardRef(Button)
aria-label="profile_type.accessibility.button_end"
aria-label="profile_type.accessibility.button_next"
className="profile-navigation-button"
classes={
Object {
......@@ -499,7 +498,7 @@ exports[`EcogestureFormEquipment component should be rendered correctly 1`] = `
onClick={[Function]}
>
<WithStyles(ForwardRef(ButtonBase))
aria-label="profile_type.accessibility.button_end"
aria-label="profile_type.accessibility.button_next"
className="MuiButton-root btn-profile-next rounded MuiButton-text profile-navigation-button"
component="button"
disabled={false}
......@@ -509,7 +508,7 @@ exports[`EcogestureFormEquipment component should be rendered correctly 1`] = `
type="button"
>
<ForwardRef(ButtonBase)
aria-label="profile_type.accessibility.button_end"
aria-label="profile_type.accessibility.button_next"
className="MuiButton-root btn-profile-next rounded MuiButton-text profile-navigation-button"
classes={
Object {
......@@ -526,7 +525,7 @@ exports[`EcogestureFormEquipment component should be rendered correctly 1`] = `
type="button"
>
<button
aria-label="profile_type.accessibility.button_end"
aria-label="profile_type.accessibility.button_next"
className="MuiButtonBase-root MuiButton-root btn-profile-next rounded MuiButton-text profile-navigation-button"
disabled={false}
onBlur={[Function]}
......@@ -547,7 +546,7 @@ exports[`EcogestureFormEquipment component should be rendered correctly 1`] = `
<span
className="MuiButton-label text-16-normal"
>
profile_type.form.button_end
profile_type.form.button_next &gt;
</span>
<NoSsr>
<WithStyles(memo)
......
......@@ -29,12 +29,18 @@ import { AppStore } from 'store'
import { DateTime } from 'luxon'
import ProfileTypeFormService from 'services/profileTypeForm.service'
import ProfileTypeFormDateSelection from './ProfileTypeFormDateSelection'
import EcogestureFormEquipment from 'components/EcogestureForm/EcogestureFormEquipment'
import { ProfileEcogesture } from 'models/profileEcogesture.model'
const ProfileTypeView = () => {
const profile = useSelector((state: AppStore) => state.ecolyo.profile)
const curProfileType = useSelector(
(state: AppStore) => state.ecolyo.profileType
)
const curProfileEcogesture: ProfileEcogesture = useSelector(
(state: AppStore) => state.ecolyo.profileEcogesture
)
const [headerHeight, setHeaderHeight] = useState<number>(0)
const [profileType, setProfileType] = useState<ProfileType>({
updateDate: DateTime.local()
......@@ -58,6 +64,7 @@ const ProfileTypeView = () => {
warmingFluid: WarmingType.ELECTRICITY,
hotWaterFluid: FluidType.ELECTRICITY,
cookingFluid: FluidType.ELECTRICITY,
equipments: '',
})
const [step, setStep] = useState<ProfileTypeStepForm>(
ProfileTypeStepForm.HOUSING_TYPE
......@@ -76,9 +83,17 @@ const ProfileTypeView = () => {
}, [])
const setNextStep = useCallback(
(_profileType: ProfileType) => {
setProfileType(_profileType)
const profileTypeFormService = new ProfileTypeFormService(_profileType)
(_profileType?: ProfileType) => {
let profileTypeFormService: ProfileTypeFormService
if (_profileType) {
setProfileType(_profileType)
profileTypeFormService = new ProfileTypeFormService(_profileType)
} else {
// if equipments are updated, keep profileType as it is
profileTypeFormService = new ProfileTypeFormService({
...profileType,
})
}
const nextStep: ProfileTypeStepForm = profileTypeFormService.getNextFormStep(
step,
!profile.isProfileTypeCompleted
......@@ -89,10 +104,10 @@ const ProfileTypeView = () => {
}
setStep(nextStep)
},
[profile.isProfileTypeCompleted, step, viewedStep]
[profile.isProfileTypeCompleted, profileType, step, viewedStep]
)
const setPrevioustStep = useCallback(
const setPreviousStep = useCallback(
(_profileType: ProfileType) => {
setProfileType(_profileType)
const profileTypeFormService = new ProfileTypeFormService(_profileType)
......@@ -115,7 +130,7 @@ const ProfileTypeView = () => {
answerType={answerType}
setNextStep={setNextStep}
isProfileTypeComplete={profile.isProfileTypeCompleted}
setPrevioustStep={setPrevioustStep}
setPrevioustStep={setPreviousStep}
/>
)
} else if (answerType.type === ProfileTypeFormType.MULTI_CHOICE) {
......@@ -126,7 +141,7 @@ const ProfileTypeView = () => {
profileType={profileType}
answerType={answerType}
setNextStep={setNextStep}
setPrevioustStep={setPrevioustStep}
setPrevioustStep={setPreviousStep}
isProfileTypeComplete={profile.isProfileTypeCompleted}
/>
)
......@@ -139,7 +154,7 @@ const ProfileTypeView = () => {
answerType={answerType}
setNextStep={setNextStep}
isProfileTypeComplete={profile.isProfileTypeCompleted}
setPrevioustStep={setPrevioustStep}
setPrevioustStep={setPreviousStep}
/>
)
} else if (answerType.type === ProfileTypeFormType.NUMBER_SELECTION) {
......@@ -151,7 +166,7 @@ const ProfileTypeView = () => {
answerType={answerType}
setNextStep={setNextStep}
isProfileTypeComplete={profile.isProfileTypeCompleted}
setPrevioustStep={setPrevioustStep}
setPrevioustStep={setPreviousStep}
/>
)
} else if (answerType.type === ProfileTypeFormType.DATE_SELECTION) {
......@@ -163,7 +178,18 @@ const ProfileTypeView = () => {
answerType={answerType}
setNextStep={setNextStep}
isProfileTypeComplete={profile.isProfileTypeCompleted}
setPrevioustStep={setPrevioustStep}
setPrevioustStep={setPreviousStep}
/>
)
} else if (answerType.type === ProfileTypeFormType.EQUIPMENT_SELECTION) {
return (
<EcogestureFormEquipment
step={step}
// viewedStep={viewedStep}
// answerType={answerType}
profileEcogesture={curProfileEcogesture}
setNextStep={setNextStep}
setPreviousStep={setPreviousStep}
/>
)
}
......
......@@ -73,8 +73,9 @@ export enum ProfileTypeStepForm {
HOT_WATER_FLUID = 13,
HOT_WATER_EQUIPMENT = 14,
COOKING_FLUID = 15,
UPDATE_DATE = 16,
END = 17,
EQUIPMENTS = 16,
UPDATE_DATE = 17,
END = 18,
}
export enum ProfileTypeFormType {
......@@ -83,4 +84,5 @@ export enum ProfileTypeFormType {
NUMBER_SELECTION = 2,
NUMBER = 3,
DATE_SELECTION = 4,
EQUIPMENT_SELECTION = 5,
}
......@@ -48,6 +48,7 @@ export interface ProfileType extends ProfileTypeIndexableTypes {
hotWaterFluid: FluidType | null
cookingFluid: FluidType
updateDate: DateTime
equipments: string
}
export interface MonthlyForecast {
......
......@@ -331,6 +331,11 @@ describe('ProfileType service', () => {
ProfileTypeStepForm.COOKING_FLUID,
false
)
expect(nextStep).toEqual(ProfileTypeStepForm.EQUIPMENTS)
nextStep = profileTypeFormService.getNextFormStep(
ProfileTypeStepForm.EQUIPMENTS,
false
)
expect(nextStep).toEqual(ProfileTypeStepForm.UPDATE_DATE)
nextStep = profileTypeFormService.getNextFormStep(
ProfileTypeStepForm.UPDATE_DATE,
......
import { EquipmentType } from 'enum/ecogesture.enum'
import { FluidType } from 'enum/fluid.enum'
import {
ConstructionYear,
......@@ -72,6 +73,8 @@ export default class ProfileTypeFormService {
case ProfileTypeStepForm.HOT_WATER_EQUIPMENT:
return ProfileTypeStepForm.COOKING_FLUID
case ProfileTypeStepForm.COOKING_FLUID:
return ProfileTypeStepForm.EQUIPMENTS
case ProfileTypeStepForm.EQUIPMENTS:
return firstProfileType
? ProfileTypeStepForm.END
: ProfileTypeStepForm.UPDATE_DATE
......@@ -129,8 +132,10 @@ export default class ProfileTypeFormService {
return this.profileType.hotWater === IndividualOrCollective.INDIVIDUAL
? ProfileTypeStepForm.HOT_WATER_EQUIPMENT
: ProfileTypeStepForm.HOT_WATER
case ProfileTypeStepForm.UPDATE_DATE:
case ProfileTypeStepForm.EQUIPMENTS:
return ProfileTypeStepForm.COOKING_FLUID
case ProfileTypeStepForm.UPDATE_DATE:
return ProfileTypeStepForm.EQUIPMENTS
default:
return ProfileTypeStepForm.HOUSING_TYPE
}
......@@ -244,6 +249,12 @@ export default class ProfileTypeFormService {
attribute: 'cookingFluid',
choices: [FluidType.ELECTRICITY, FluidType.GAS],
}
case ProfileTypeStepForm.EQUIPMENTS:
return {
type: ProfileTypeFormType.EQUIPMENT_SELECTION,
attribute: 'equipments',
choices: Object.keys(EquipmentType),
}
case ProfileTypeStepForm.UPDATE_DATE:
return {
type: ProfileTypeFormType.DATE_SELECTION,
......
......@@ -381,16 +381,24 @@ const calculateConnectedKonnectorPerDay = async (client: Client) => {
*/
const buildProfileWithFuildType = async (
client: Client,
fluidType: FluidType
fluidType: FluidType,
monthToAggregate?: number
): Promise<string> => {
let formatedProfile = ''
const profile = await new ProfileService(client).getProfile()
// If profile is not filled, return empty string
if (profile && !profile.isProfileTypeCompleted) return formatedProfile
const profileType = await new ProfileTypeEntityService(
client
).getProfileType()
if (profile && !profile.isProfileTypeCompleted) return formatedProfile
const date = monthToAggregate
? DateTime.local()
.setZone('utc', {
keepLocalTime: true,
})
.set({ month: monthToAggregate })
: null
const profileType = await new ProfileTypeEntityService(client).getProfileType(
date
)
if (fluidType === FluidType.ELECTRICITY) {
if (
profile &&
......@@ -473,10 +481,15 @@ const buildProfileWithFuildType = async (
const getConsumptionValue = async (
client: Client,
fluidType: FluidType[]
fluidType: FluidType[],
monthToAggregate?: number
): Promise<PerformanceIndicator[]> => {
const consumptionService = new ConsumptionService(client)
const analysisDate = DateTime.local().setZone('utc', { keepLocalTime: true })
const analysisDate = monthToAggregate
? DateTime.local()
.setZone('utc', { keepLocalTime: true })
.set({ month: monthToAggregate })
: DateTime.local().setZone('utc', { keepLocalTime: true })
const periods = {
timePeriod: {
startDate: analysisDate.minus({ month: 1 }).startOf('month'),
......@@ -501,13 +514,16 @@ const getConsumptionValue = async (
* @param client
* @group [{ slug }, { seniority (in month) }, { profile (ECS, chauffage, etc...) }],
*/
const calculateConsumptionVariation = async (client: Client) => {
const calculateConsumptionVariation = async (
client: Client,
monthToAggregate?: number
) => {
log('info', `calculateConsumptionVariation`)
const consumptionData = await getConsumptionValue(client, [
FluidType.ELECTRICITY,
FluidType.GAS,
FluidType.WATER,
])
const consumptionData = await getConsumptionValue(
client,
[FluidType.ELECTRICITY, FluidType.GAS, FluidType.WATER],
monthToAggregate
)
for (const fluidType in [
FluidType.ELECTRICITY,
FluidType.GAS,
......@@ -521,21 +537,40 @@ const calculateConsumptionVariation = async (client: Client) => {
})
if (firstConnectionEvent) {
const seniority = DateTime.local()
.setZone('utc', {
keepLocalTime: true,
})
.diff(firstConnectionEvent.eventDate).months
const seniority = 0
// Seniority is set to 0, otherwise the indicator is too specific
// monthToAggregate
// ? DateTime.local()
// .setZone('utc', {
// keepLocalTime: true,
// })
// .set({ month: monthToAggregate })
// .diff(firstConnectionEvent.eventDate, 'month')
// .get('month')
// : DateTime.local()
// .setZone('utc', {
// keepLocalTime: true,
// })
// .diff(firstConnectionEvent.eventDate, 'month')
// .get('month')
const consumptionVariationIndicator: Indicator = {
createdBy: 'ecolyo',
measureName: DaccEvent.CONSUMPTION_VARIATION_MONTHLY,
startDate: DateTime.local()
.setZone('utc', {
keepLocalTime: true,
})
.startOf('day')
.toISODate(),
startDate: monthToAggregate
? DateTime.local()
.setZone('utc', {
keepLocalTime: true,
})
.set({ month: monthToAggregate })
.startOf('day')
.toISODate()
: DateTime.local()
.setZone('utc', {
keepLocalTime: true,
})
.startOf('day')
.toISODate(),
value:
consumptionData[fluidType] &&
consumptionData[fluidType].percentageVariation
......@@ -544,37 +579,63 @@ const calculateConsumptionVariation = async (client: Client) => {
// eslint-disable-next-line @typescript-eslint/camelcase
group1: { fluid_type: FluidType[fluidType].toLowerCase() },
// eslint-disable-next-line @typescript-eslint/camelcase
group2: { seniority: seniority.toString() },
group2: { seniority: Math.round(seniority).toString() },
group3: {
// eslint-disable-next-line @typescript-eslint/camelcase
fluid_usage: await buildProfileWithFuildType(
client,
getFluidType(FluidType[fluidType])
getFluidType(FluidType[fluidType]),
monthToAggregate
),
},
}
// if user wasnt connected during current month, dont send indicator
const events: UsageEvent[] = await UsageEventService.getEvents(client, {
eventDate: {
$lt: DateTime.local()
.setZone('utc', {
keepLocalTime: true,
})
.endOf('month')
.minus({ month: 1 })
.toString(),
$gt: DateTime.local()
.setZone('utc', {
keepLocalTime: true,
})
.startOf('month')
.minus({ month: 1 })
.toString(),
},
eventDate: monthToAggregate
? {
$lt: DateTime.local()
.setZone('utc', {
keepLocalTime: true,
})
.set({ month: monthToAggregate })
.endOf('month')
.minus({ month: 1 })
.toString(),
$gt: DateTime.local()
.setZone('utc', {
keepLocalTime: true,
})
.set({ month: monthToAggregate })
.startOf('month')
.minus({ month: 1 })
.toString(),
}
: {
$lt: DateTime.local()
.setZone('utc', {
keepLocalTime: true,
})
.endOf('month')
.minus({ month: 1 })
.toString(),
$gt: DateTime.local()
.setZone('utc', {
keepLocalTime: true,
})
.startOf('month')
.minus({ month: 1 })
.toString(),
},
})
if (events.length > 0 && consumptionVariationIndicator.value !== 0) {
log(
'info',
`Send variation indicator for ${monthToAggregate} : ${JSON.stringify(
consumptionVariationIndicator
)}`
)
await sendIndicator(consumptionVariationIndicator, client)
}
}
......@@ -582,27 +643,49 @@ const calculateConsumptionVariation = async (client: Client) => {
}
}
const sendConnectionCount = async (client: Client) => {
const sendConnectionCount = async (
client: Client,
monthToAggregate?: number
) => {
log('info', `sendConnectionCount`)
// Get daily connexion
const events: UsageEvent[] = await UsageEventService.getEvents(client, {
type: UsageEventType.CONNECTION_EVENT,
eventDate: {
$lt: DateTime.local()
.setZone('utc', {
keepLocalTime: true,
})
.endOf('month')
.minus({ month: 1 })
.toString(),
$gt: DateTime.local()
.setZone('utc', {
keepLocalTime: true,
})
.startOf('month')
.minus({ month: 1 })
.toString(),
},
eventDate: monthToAggregate
? {
$lt: DateTime.local()
.setZone('utc', {
keepLocalTime: true,
})
.set({ month: monthToAggregate })
.minus({ month: 1 })
.endOf('month')
.toString(),
$gt: DateTime.local()
.setZone('utc', {
keepLocalTime: true,
})
.set({ month: monthToAggregate })
.minus({ month: 1 })
.startOf('month')
.toString(),
}
: {
$lt: DateTime.local()
.setZone('utc', {
keepLocalTime: true,
})
.endOf('month')
.minus({ month: 1 })
.toString(),
$gt: DateTime.local()
.setZone('utc', {
keepLocalTime: true,
})
.startOf('month')
.minus({ month: 1 })
.toString(),
},
})
let uniqueDates = 0
......@@ -616,14 +699,28 @@ const sendConnectionCount = async (client: Client) => {
const connectionMonthly: Indicator = {
createdBy: 'ecolyo',
measureName: DaccEvent.CONNECTION_COUNT_MONTHLY,
startDate: DateTime.local()
.setZone('utc', {
keepLocalTime: true,
})
.startOf('day')
.toISODate(),
startDate: monthToAggregate
? DateTime.local()
.setZone('utc', {
keepLocalTime: true,
})
.set({ month: monthToAggregate })
.startOf('day')
.toISODate()
: DateTime.local()
.setZone('utc', {
keepLocalTime: true,
})
.startOf('day')
.toISODate(),
value: uniqueDates,
}
log(
'info',
`Send connectionMonthly indicator for ${monthToAggregate} : ${JSON.stringify(
connectionMonthly
)}`
)
await sendIndicator(connectionMonthly, client)
}
......@@ -1226,14 +1323,30 @@ const AggregatorUsageEvents = async ({
})
.startOf('day').day === profile.monthlyAnalysisDate.day
) {
sendKonnectorAttemptsMonthly(client)
calculateConsumptionVariation(client)
sendEmailSubscription(client)
sendHalfHourConsumption(client)
sendKonnectorEvents(client)
sendConnectionCount(client)
sendProfileCount(client)
await sendKonnectorAttemptsMonthly(client)
await calculateConsumptionVariation(client)
await sendEmailSubscription(client)
await sendHalfHourConsumption(client)
await sendKonnectorEvents(client)
await sendConnectionCount(client)
await sendProfileCount(client)
}
log('info', `Recalculates errored indicators`)
const today: DateTime = DateTime.local()
.setZone('utc', {
keepLocalTime: true,
})
.startOf('day')
const lastMonth = 5
if (today.day === 3 && today.month === lastMonth) {
let monthToAggregate = 1
for (monthToAggregate; monthToAggregate <= lastMonth; monthToAggregate++) {
await calculateConsumptionVariation(client, monthToAggregate)
await sendConnectionCount(client, monthToAggregate)
}
}
const uniqueReadUsageEvents: UsageEvent[] = uniq(readUsageEvents)
log(
'info',
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment