From bbf9bdad288cf29452b5289f7bed98559b7d3c89 Mon Sep 17 00:00:00 2001 From: Johan Girod Date: Thu, 28 Sep 2023 18:51:24 +0200 Subject: [PATCH] =?UTF-8?q?R=C3=A9pare=20le=20bug=20dans=20fetchstats=20du?= =?UTF-8?q?=20=C3=A0=20la=20cloture=20des=20comptes=20zammad=20et=20crisp?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- site/scripts/stats/fetch-stats.js | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/site/scripts/stats/fetch-stats.js b/site/scripts/stats/fetch-stats.js index 1ed940801..a58b66a01 100644 --- a/site/scripts/stats/fetch-stats.js +++ b/site/scripts/stats/fetch-stats.js @@ -328,6 +328,7 @@ async function fetchZammadUserAnswersStats() { return answer.index.count } +// eslint-disable-next-line no-unused-vars async function fetchAllUserAnswerStats() { const zammadAnswersCount = await fetchZammadUserAnswersStats() const cripsAnswersCount = await fetchCrispAnsweredConversationsLastMonth() @@ -424,6 +425,7 @@ async function fetchZammadUserFeedbackIssues() { ) } +// eslint-disable-next-line no-unused-vars async function fetchAllUserFeedbackIssues() { const crispFeedbackIssues = await fetchCrispUserFeedbackIssues() const zammadFeedbackIssues = await fetchZammadUserFeedbackIssues() @@ -510,14 +512,14 @@ if ( visitesJours, visitesMois, rawSatisfaction, - retoursUtilisateurs, - nbAnswersLast30days, + // retoursUtilisateurs, + // nbAnswersLast30days, ] = await Promise.all([ fetchDailyVisits(), fetchMonthlyVisits(), fetchApi(buildSatisfactionQuery), - fetchAllUserFeedbackIssues(), - fetchAllUserAnswerStats(), + // fetchAllUserFeedbackIssues(), + // fetchAllUserAnswerStats(), ]) const satisfaction = uniformiseData(flattenPage(rawSatisfaction)).map( (page) => { @@ -538,7 +540,8 @@ if ( ]) ), satisfaction: mergePreviousData(baseData.satisfaction, satisfaction), - retoursUtilisateurs, - nbAnswersLast30days, + // We use old data because we don't have account on Zammad and Crisp anymore + retoursUtilisateurs: baseData.retoursUtilisateurs, + nbAnswersLast30days: baseData.nbAnswersLast30days, }) }