Skip to content

Commit

Permalink
fix: stats
Browse files Browse the repository at this point in the history
  • Loading branch information
jonat75 committed Jan 14, 2025
1 parent 93feb9d commit 123967f
Show file tree
Hide file tree
Showing 5 changed files with 5 additions and 46 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ export class PostgresPublicStatsRepo implements IPublicStatsRepo {
FROM
${this.declarationTable}
WHERE
year >= EXTRACT(YEAR FROM CURRENT_DATE) - 3
year >= EXTRACT(YEAR FROM CURRENT_DATE) - 4
AND (data->'entreprise'->'effectif'->'tranche')::text IS NOT NULL
GROUP BY
year, workforce_range
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ export class GetPublicStats extends AbstractCachedUseCase<never, PublicStatsDTO>
if (countRepEq === 0) return emptyPublicStats as PublicStatsDTO;

const stats = await this.publicStatsRepo.getAll();
console.log("stats", stats.index.lastThreeYearsAverage);
return publicStatsMap.toDTO(stats);
} catch (error: unknown) {
console.error(error);
Expand Down
2 changes: 1 addition & 1 deletion packages/app/src/app/(default)/aide-index/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,7 @@ const AideSimulation = () => {
L.1111-2
</Link>{" "}
et{" "}
<Link href="https://www.legifrance.gouv.fr/codes/article_lc/LEGIARTI000019353569" target="_blank">
<Link href="https://www.legifrance.gouv.fr/codes/article_lc/LEGIARTI000031565369" target="_blank">
L.1111-3
</Link>{" "}
du code du travail.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -174,17 +174,11 @@ export const EffectifsForm = () => {
L’entreprise ou l’unité économique et sociale (UES) doit définir son assujettissement chaque année à la
date de l’obligation de publication de l’index, soit le 1er mars. Le calcul des effectifs assujettis est
celui prévu aux articles{" "}
<Link
href="https://www.legifrance.gouv.fr/codes/article_lc/LEGIARTI000006900783/2008-05-01#:~:text=2%C2%B0%20Les%20salari%C3%A9s%20titulaires,l'entreprise%20%C3%A0%20due%20proportion"
target="_blank"
>
<Link href="https://www.legifrance.gouv.fr/codes/article_lc/LEGIARTI000019353569" target="_blank">
L.1111-2
</Link>{" "}
et{" "}
<Link
href="https://www.legifrance.gouv.fr/codes/section_lc/LEGITEXT000006072050/LEGISCTA000006177833/#:~:text=3%C2%B0%20Les%20salari%C3%A9s%20%C3%A0,la%20dur%C3%A9e%20conventionnelle%20du%20travail"
target="_blank"
>
<Link href="https://www.legifrance.gouv.fr/codes/article_lc/LEGIARTI000031565369" target="_blank">
L.1111-3
</Link>{" "}
du code du travail. <br />
Expand Down
36 changes: 0 additions & 36 deletions packages/app/src/app/(default)/mon-espace/les-entreprises/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -69,18 +69,6 @@ const MesEntreprisesPage = async ({ searchParams }: NextServerPageProps<never, "
<Box mt="2w">
<SirenInput />
</Box>
<p>
<br />
Vous souhaitez rattacher votre adresse email à une autre entreprise,{" "}
<Link
target="_blank"
href={`https://app${
config.api.security.moncomptepro.appTest ? "-sandbox" : ""
}.moncomptepro.beta.gouv.fr/manage-organizations`}
>
cliquez ici
</Link>
</p>
</Box>
</MessageProvider>
);
Expand All @@ -97,18 +85,6 @@ const MesEntreprisesPage = async ({ searchParams }: NextServerPageProps<never, "
<Box mt="2w">
<SirenInput isImpersonating={isImpersonating} loadedSiren={selectedSiren} />
</Box>
<p>
<br />
Vous souhaitez rattacher votre adresse email à une autre entreprise,{" "}
<Link
target="_blank"
href={`https://app${
config.api.security.moncomptepro.appTest ? "-sandbox" : ""
}.moncomptepro.beta.gouv.fr/manage-organizations`}
>
cliquez ici
</Link>
</p>
<Box mt="4w">
<Heading as="h1" variant="h6" text="Adresses emails rattachées" />
<EmailOwnerList isEmailLogin={isEmailLogin} siren={selectedSiren} emails={emails} />
Expand All @@ -127,18 +103,6 @@ const MesEntreprisesPage = async ({ searchParams }: NextServerPageProps<never, "
<Box mt="2w">
<SirenInput />
</Box>
<p>
<br />
Vous souhaitez rattacher votre adresse email à une autre entreprise,{" "}
<Link
target="_blank"
href={`https://app${
config.api.security.moncomptepro.appTest ? "-sandbox" : ""
}.moncomptepro.beta.gouv.fr/manage-organizations`}
>
cliquez ici
</Link>
</p>
<Box mt="4w">Pas d'utilisateur pour ce Siren ou Url invalide</Box>
</Box>
</MessageProvider>
Expand Down

0 comments on commit 123967f

Please sign in to comment.