diff --git a/common/assets/images/partner-logos/sofrilog.jpg b/common/assets/images/partner-logos/sofrilog.jpg
new file mode 100644
index 000000000..8ef0452ab
Binary files /dev/null and b/common/assets/images/partner-logos/sofrilog.jpg differ
diff --git a/package.json b/package.json
index aa3b297a0..43fca6c91 100644
--- a/package.json
+++ b/package.json
@@ -29,7 +29,7 @@
"@testing-library/react": "^9.3.2",
"@testing-library/user-event": "^7.1.2",
"babel-eslint": "^10.0.3",
- "babel-jest": "^24.9.0",
+ "babel-jest": "^27.0.0",
"babel-loader": "^8.0.6",
"babel-plugin-named-asset-import": "^0.3.5",
"babel-plugin-recharts": "^2.0.0",
@@ -41,13 +41,13 @@
"common": "0.1.0",
"core-js": "^3.8.1",
"crisp-sdk-web": "^1.0.18",
- "css-loader": "^3.2.0",
+ "css-loader": "^3.6.0",
"csv-stringify": "^5.3.6",
"date-fns": "^2.29.3",
"dotenv": "^8.2.0",
"dotenv-expand": "^5.1.0",
"enzyme": "^3.11.0",
- "eslint": "^6.6.0",
+ "eslint": "^7.0.0",
"eslint-loader": "^3.0.2",
"eslint-plugin-flowtype": "^3.13.0",
"eslint-plugin-import": "^2.18.2",
@@ -63,9 +63,9 @@
"http-proxy-middleware": "^1.0.5",
"husky": "^4.2.5",
"identity-obj-proxy": "^3.0.0",
- "jest": "^25.0.0",
+ "jest": "^27.0.0",
"jest-environment-jsdom-fourteen": "^0.1.0",
- "jest-resolve": "^25.0.0",
+ "jest-resolve": "^26.5.0",
"jest-watch-typeahead": "^0.4.2",
"lodash": "^4.17.19",
"mini-css-extract-plugin": "^0.8.0",
@@ -94,8 +94,8 @@
"reselect": "^4.0.0",
"resolve": "^1.12.2",
"resolve-url-loader": "^3.1.1",
- "sass-loader": "^8.0.0",
- "semver": "^6.3.0",
+ "sass-loader": "^9.0.0",
+ "semver": "^7.5.4",
"source-map-explorer": "^2.5.2",
"style-loader": "1.0.0",
"terser-webpack-plugin": "^2.3.6",
@@ -195,7 +195,7 @@
"/common/**/__tests__/**/*.{js,jsx,ts,tsx}",
"/common/**/*.{spec,test}.{js,jsx,ts,tsx}"
],
- "testEnvironment": "jest-environment-jsdom-fourteen",
+ "testEnvironment": "jest-environment-jsdom",
"transform": {
"^.+\\.(js|jsx|ts|tsx)$": "/node_modules/babel-jest",
"^.+\\.css$": "/config/jest/cssTransform.js",
diff --git a/web/controller/components/details/ControllerControlHeader.js b/web/controller/components/details/ControllerControlHeader.js
index 997d5670e..a66d4f4bf 100644
--- a/web/controller/components/details/ControllerControlHeader.js
+++ b/web/controller/components/details/ControllerControlHeader.js
@@ -40,26 +40,30 @@ const useStyles = makeStyles(theme => ({
}
}));
-const ExportButton = (classes, modals, controlId) => (
- {
- modals.open("controllerExportExcelOne", { controlId });
- }}
- >
- Exporter le contrôle
-
-);
+export function ExportButton({ controlId }) {
+ const modals = useModals();
+ const classes = useStyles();
+ return (
+ {
+ modals.open("controllerExportExcelOne", { controlId });
+ }}
+ >
+ Exporter le contrôle
+
+ );
+}
export function ControllerControlHeader({
controlId,
controlDate,
- onCloseDrawer
+ onCloseDrawer,
+ enableExport = true
}) {
- const modals = useModals();
const classes = useStyles();
const isOnDesktop = useIsWidthUp("md");
return isOnDesktop ? (
@@ -82,7 +86,7 @@ export function ControllerControlHeader({
Date et heure du contrôle : {prettyFormatDayHour(controlDate)}
- {ExportButton(classes, modals, controlId)}
+ {enableExport && }
) : (
@@ -100,7 +104,7 @@ export function ControllerControlHeader({
>
Fermer
- {ExportButton(classes, modals, controlId)}
+ {enableExport && }
);
diff --git a/web/controller/components/modals/ControllerExportExcelOne.js b/web/controller/components/modals/ControllerExportExcelOne.js
index 0bdaac58a..c2d415a1c 100644
--- a/web/controller/components/modals/ControllerExportExcelOne.js
+++ b/web/controller/components/modals/ControllerExportExcelOne.js
@@ -1,13 +1,12 @@
import React from "react";
import {
+ Button,
Modal,
- ModalTitle,
ModalContent,
ModalFooter,
- Button
+ ModalTitle
} from "@dataesr/react-dsfr";
import { makeStyles } from "@mui/styles";
-import Typography from "@mui/material/Typography";
import { useApi } from "common/utils/api";
import { useSnackbarAlerts } from "../../../common/Snackbar";
import { HTTP_QUERIES } from "common/utils/apiQueries";
@@ -30,17 +29,6 @@ export default function ExportExcelOne({ open, handleClose, controlId }) {
Mobilic permet d'exporter les données des salariés contrôlés au format
Excel (.xlsx).
- Conditions d’export
-
-
- Le téléchargement produit un fichier Excel qui contient les données
- d’activité du contrôle Mobilic sélectionné.{" "}
-
- Les données du salarié sont limitées à une période qui ne peut pas
- dépasser les 28 jours précédant le contrôle (ainsi que la journée
- “en cours” lors du contrôle).
-
-
closeControl()}
+ enableExport={false}
/>
diff --git a/web/landing/stats.js b/web/landing/stats.js
index 050074406..1b42fef53 100644
--- a/web/landing/stats.js
+++ b/web/landing/stats.js
@@ -20,8 +20,7 @@ export default function Stats() {