🐛 Fixing build
This commit is contained in:
parent
8ff373271b
commit
6425f8ba5e
@ -49,7 +49,7 @@ export default function Alert(props: IProps) {
|
||||
<Typography typo={ETypo.TEXT_LG_SEMIBOLD} color={ETypoColor.COLOR_NEUTRAL_950}>
|
||||
{title}
|
||||
</Typography>
|
||||
<Typography typo={ETypo.TEXT_MD_light} color={ETypoColor.COLOR_NEUTRAL_700}>
|
||||
<Typography typo={ETypo.TEXT_MD_LIGHT} color={ETypoColor.COLOR_NEUTRAL_700}>
|
||||
{description}
|
||||
</Typography>
|
||||
</div>
|
||||
|
@ -1,17 +1,11 @@
|
||||
import Module from "@Front/Config/Module";
|
||||
import { OfficeFolder } from "le-coffre-resources/dist/Notary";
|
||||
import { EDocumentStatus } from "le-coffre-resources/dist/Notary/Document";
|
||||
import Link from "next/link";
|
||||
import { useRouter } from "next/router";
|
||||
import React, { useCallback, useEffect } from "react";
|
||||
|
||||
import Button from "../Button";
|
||||
import SearchBar from "../SearchBar";
|
||||
import classes from "./classes.module.scss";
|
||||
import Rules, { RulesMode } from "@Front/Components/Elements/Rules";
|
||||
import { AppRuleActions, AppRuleNames } from "@Front/Api/Entities/rule";
|
||||
import { IBlock } from "../SearchBlockList/BlockList/Block";
|
||||
import BlockList from "../SearchBlockList/BlockList";
|
||||
import SearchBlockList from "../SearchBlockList";
|
||||
|
||||
type IProps = {
|
||||
@ -30,27 +24,6 @@ export default function FolderListContainer(props: IProps) {
|
||||
? Module.getInstance().get().modules.pages.Folder.pages.FolderArchived.pages.FolderInformation.props.path
|
||||
: Module.getInstance().get().modules.pages.Folder.pages.FolderInformation.props.path;
|
||||
|
||||
const filterFolders = (value: string): void => {
|
||||
const filteredFolders: OfficeFolder[] = folders.filter((folder) => {
|
||||
const name = folder.name.toLowerCase();
|
||||
const number = folder.folder_number.toLowerCase();
|
||||
value = value.toLowerCase();
|
||||
if (folder.customers) {
|
||||
const customerNames = folder.customers
|
||||
.map((customer) => {
|
||||
return `${customer.contact?.first_name.toLowerCase()} ${customer.contact?.last_name.toLowerCase()}`;
|
||||
})
|
||||
.join(", ");
|
||||
|
||||
return name.includes(value) || number.includes(value) || customerNames.includes(value);
|
||||
}
|
||||
|
||||
return name.includes(value) || number.includes(value);
|
||||
});
|
||||
|
||||
setBlocks(getBlocks(filteredFolders));
|
||||
};
|
||||
|
||||
const getBlocks = useCallback(
|
||||
(folders: OfficeFolder[]): IBlock[] => {
|
||||
const pendingFolders = folders
|
||||
@ -102,7 +75,6 @@ export default function FolderListContainer(props: IProps) {
|
||||
setBlocks(getBlocks(folders));
|
||||
}, [folders, getBlocks]);
|
||||
|
||||
//const navigatePath = Module.getInstance().get().modules.pages.Folder.pages.CreateFolder.props.path;
|
||||
return (
|
||||
<div className={classes["root"]}>
|
||||
<SearchBlockList
|
||||
@ -113,22 +85,6 @@ export default function FolderListContainer(props: IProps) {
|
||||
text: "Créer un dossier",
|
||||
}}
|
||||
/>
|
||||
{/* {!isArchived && (
|
||||
<div>
|
||||
<Rules
|
||||
mode={RulesMode.NECESSARY}
|
||||
rules={[
|
||||
{
|
||||
action: AppRuleActions.create,
|
||||
name: AppRuleNames.officeFolders,
|
||||
},
|
||||
]}>
|
||||
<Link href={navigatePath}>
|
||||
<Button fullwidth={true}>Créer un dossier</Button>
|
||||
</Link>
|
||||
</Rules>
|
||||
</div>
|
||||
)} */}
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
@ -45,7 +45,7 @@ export default function SearchBlockList(props: IProps) {
|
||||
return {
|
||||
maxHeight: `calc(100% - ${heightToSubstract}px)`,
|
||||
};
|
||||
}, []);
|
||||
}, [bottomButton]);
|
||||
|
||||
useEffect(() => {
|
||||
setBlocksShowing(blocks);
|
||||
|
@ -3,9 +3,10 @@ import React, { useCallback, useState } from "react";
|
||||
import classes from "./classes.module.scss";
|
||||
import SearchBar from "@Front/Components/DesignSystem/SearchBar";
|
||||
import User from "le-coffre-resources/dist/Notary";
|
||||
import BlockList, { IBlock } from "@Front/Components/DesignSystem/BlockList";
|
||||
import { useRouter } from "next/router";
|
||||
import Module from "@Front/Config/Module";
|
||||
import { IBlock } from "@Front/Components/DesignSystem/SearchBlockList/BlockList/Block";
|
||||
import BlockList from "@Front/Components/DesignSystem/SearchBlockList/BlockList";
|
||||
|
||||
type IProps = {
|
||||
collaborators: User[];
|
||||
@ -50,7 +51,7 @@ export default function CollaboratorListContainer(props: IProps) {
|
||||
<BlockList
|
||||
blocks={filteredUsers.map((user) => {
|
||||
return {
|
||||
name: user.contact?.first_name + " " + user.contact?.last_name,
|
||||
primaryText: user.contact?.first_name + " " + user.contact?.last_name,
|
||||
id: user.uid!,
|
||||
selected: user.uid === collaboratorUid,
|
||||
rightIcon: user.seats?.some((seat) => new Date(seat.subscription!.end_date) >= new Date()) ? (
|
||||
|
@ -1,5 +1,4 @@
|
||||
import DeedTypes from "@Front/Api/LeCoffreApi/Admin/DeedTypes/DeedTypes";
|
||||
import BlockList, { IBlock } from "@Front/Components/DesignSystem/BlockList";
|
||||
import Button from "@Front/Components/DesignSystem/Button";
|
||||
import SearchBar from "@Front/Components/DesignSystem/SearchBar";
|
||||
import Module from "@Front/Config/Module";
|
||||
@ -9,6 +8,8 @@ import { useRouter } from "next/router";
|
||||
import React, { useCallback, useState } from "react";
|
||||
|
||||
import classes from "./classes.module.scss";
|
||||
import { IBlock } from "@Front/Components/DesignSystem/SearchBlockList/BlockList/Block";
|
||||
import BlockList from "@Front/Components/DesignSystem/SearchBlockList/BlockList";
|
||||
|
||||
type IProps = {
|
||||
deedTypes: DeedType[];
|
||||
@ -50,7 +51,7 @@ export default function DeedListContainer(props: IProps) {
|
||||
<BlockList
|
||||
blocks={filteredUsers.map((deed) => {
|
||||
return {
|
||||
name: deed.name,
|
||||
primaryText: deed.name,
|
||||
id: deed.uid!,
|
||||
selected: deedTypeUid === deed.uid,
|
||||
};
|
||||
|
@ -1,4 +1,3 @@
|
||||
import BlockList, { IBlock } from "@Front/Components/DesignSystem/BlockList";
|
||||
import Button from "@Front/Components/DesignSystem/Button";
|
||||
import SearchBar from "@Front/Components/DesignSystem/SearchBar";
|
||||
import Module from "@Front/Config/Module";
|
||||
@ -8,6 +7,8 @@ import { useRouter } from "next/router";
|
||||
import React, { useCallback, useState } from "react";
|
||||
|
||||
import classes from "./classes.module.scss";
|
||||
import { IBlock } from "@Front/Components/DesignSystem/SearchBlockList/BlockList/Block";
|
||||
import BlockList from "@Front/Components/DesignSystem/SearchBlockList/BlockList";
|
||||
|
||||
type IProps = {
|
||||
documentTypes: DocumentType[];
|
||||
@ -49,7 +50,7 @@ export default function DocumentTypeListContainer(props: IProps) {
|
||||
<BlockList
|
||||
blocks={filteredDocumentTypes.map((documentType) => {
|
||||
return {
|
||||
name: documentType.name,
|
||||
primaryText: documentType.name,
|
||||
id: documentType.uid!,
|
||||
selected: documentType.uid === documentTypeUid,
|
||||
};
|
||||
|
@ -1,4 +1,3 @@
|
||||
import BlockList, { IBlock } from "@Front/Components/DesignSystem/BlockList";
|
||||
import SearchBar from "@Front/Components/DesignSystem/SearchBar";
|
||||
import Module from "@Front/Config/Module";
|
||||
import { Office } from "le-coffre-resources/dist/SuperAdmin";
|
||||
@ -6,6 +5,8 @@ import { useRouter } from "next/router";
|
||||
import React, { useCallback, useState } from "react";
|
||||
|
||||
import classes from "./classes.module.scss";
|
||||
import { IBlock } from "@Front/Components/DesignSystem/SearchBlockList/BlockList/Block";
|
||||
import BlockList from "@Front/Components/DesignSystem/SearchBlockList/BlockList";
|
||||
|
||||
type IProps = {
|
||||
offices: Office[];
|
||||
@ -49,7 +50,7 @@ export default function OfficeListContainer(props: IProps) {
|
||||
<BlockList
|
||||
blocks={filteredOffices.map((office) => {
|
||||
return {
|
||||
name: office.crpcen + " - " + office.name,
|
||||
primaryText: office.crpcen + " - " + office.name,
|
||||
id: office.uid!,
|
||||
selected: office.uid === officeUid,
|
||||
};
|
||||
|
@ -1,4 +1,3 @@
|
||||
import BlockList, { IBlock } from "@Front/Components/DesignSystem/BlockList";
|
||||
import SearchBar from "@Front/Components/DesignSystem/SearchBar";
|
||||
import Module from "@Front/Config/Module";
|
||||
import { OfficeRole } from "le-coffre-resources/dist/Admin";
|
||||
@ -8,6 +7,8 @@ import React, { useCallback, useState } from "react";
|
||||
import classes from "./classes.module.scss";
|
||||
import Link from "next/link";
|
||||
import Button from "@Front/Components/DesignSystem/Button";
|
||||
import { IBlock } from "@Front/Components/DesignSystem/SearchBlockList/BlockList/Block";
|
||||
import BlockList from "@Front/Components/DesignSystem/SearchBlockList/BlockList";
|
||||
|
||||
type IProps = {
|
||||
roles: OfficeRole[];
|
||||
@ -55,7 +56,7 @@ export default function RoleListContainer(props: IProps) {
|
||||
})
|
||||
.map((role) => {
|
||||
return {
|
||||
name: role.name,
|
||||
primaryText: role.name,
|
||||
id: role.uid!,
|
||||
selected: role.uid === roleUid,
|
||||
};
|
||||
|
@ -1,4 +1,3 @@
|
||||
import BlockList, { IBlock } from "@Front/Components/DesignSystem/BlockList";
|
||||
import SearchBar from "@Front/Components/DesignSystem/SearchBar";
|
||||
import Module from "@Front/Config/Module";
|
||||
import User from "le-coffre-resources/dist/Notary";
|
||||
@ -6,6 +5,8 @@ import { useRouter } from "next/router";
|
||||
import React, { useCallback, useState } from "react";
|
||||
|
||||
import classes from "./classes.module.scss";
|
||||
import { IBlock } from "@Front/Components/DesignSystem/SearchBlockList/BlockList/Block";
|
||||
import BlockList from "@Front/Components/DesignSystem/SearchBlockList/BlockList";
|
||||
|
||||
type IProps = {
|
||||
users: User[];
|
||||
@ -50,7 +51,7 @@ export default function UserListContainer(props: IProps) {
|
||||
<BlockList
|
||||
blocks={filteredUsers.map((user) => {
|
||||
return {
|
||||
name: user.contact?.first_name + " " + user.contact?.last_name,
|
||||
primaryText: user.contact?.first_name + " " + user.contact?.last_name,
|
||||
id: user.uid!,
|
||||
selected: user.uid === userUid,
|
||||
};
|
||||
|
@ -24,7 +24,7 @@ export default function DeleteCustomerModal(props: IProps) {
|
||||
title={"Êtes-vous sûr de vouloir supprimer ce client du dossier ?"}
|
||||
firstButton={{ children: "Annuler", onClick: onClose }}
|
||||
secondButton={{ children: "Supprimer le client", onClick: handleDelete }}>
|
||||
<Typography typo={ETypo.TEXT_MD_light}>
|
||||
<Typography typo={ETypo.TEXT_MD_LIGHT}>
|
||||
Cette action retirera le client de ce dossier. Vous ne pourrez plus récupérer les informations associées à ce client dans ce
|
||||
dossier une fois supprimées.
|
||||
</Typography>
|
||||
|
@ -131,7 +131,7 @@ export default function ClientBox(props: IProps) {
|
||||
onClose={closeErrorModal}
|
||||
title={"Suppression impossible"}
|
||||
secondButton={{ children: "Fermer", onClick: closeErrorModal, fullwidth: true }}>
|
||||
<Typography typo={ETypo.TEXT_MD_light}>
|
||||
<Typography typo={ETypo.TEXT_MD_LIGHT}>
|
||||
Ce client ne peut pas être supprimé car des documents sont associés à son dossier. Veuillez d'abord gérer ou supprimer
|
||||
ces documents avant de tenter de supprimer le client.
|
||||
</Typography>
|
||||
|
@ -31,7 +31,7 @@ export default function DeleteAskedDocumentModal(props: IProps) {
|
||||
title={"Êtes-vous sûr de vouloir supprimer cette demande de document ?"}
|
||||
firstButton={{ children: "Annuler", onClick: onClose }}
|
||||
secondButton={{ children: "Supprimer la demande", onClick: onDelete }}>
|
||||
<Typography typo={ETypo.TEXT_MD_light}>Cette action annulera la demande du document en cours.</Typography>
|
||||
<Typography typo={ETypo.TEXT_MD_LIGHT}>Cette action annulera la demande du document en cours.</Typography>
|
||||
</Modal>
|
||||
);
|
||||
}
|
||||
|
@ -34,7 +34,7 @@ export default function DeleteFolderModal(props: IProps) {
|
||||
title={"Êtes-vous sûr de vouloir supprimer ce dossier ?"}
|
||||
firstButton={{ children: "Annuler", onClick: onClose }}
|
||||
secondButton={{ children: "Supprimer le dossier", onClick: onDelete }}>
|
||||
<Typography typo={ETypo.TEXT_MD_light}>
|
||||
<Typography typo={ETypo.TEXT_MD_LIGHT}>
|
||||
Cette action est irréversible. En supprimant ce dossier, toutes les informations associées seront définitivement perdues.
|
||||
</Typography>
|
||||
</Modal>
|
||||
|
@ -44,13 +44,13 @@ export default function AnchoringModal(props: IProps) {
|
||||
firstButton={!isAnchoring ? { children: "Non, Annuler", onClick: onClose } : undefined}
|
||||
secondButton={!isAnchoring ? { children: "Oui, certifier et ancrer", onClick: anchor } : undefined}>
|
||||
{!isAnchoring ? (
|
||||
<Typography typo={ETypo.TEXT_MD_light}>
|
||||
<Typography typo={ETypo.TEXT_MD_LIGHT}>
|
||||
La certification et l'ancrage de ce dossier dans la blockchain sont des actions définitives et garantiront la sécurité
|
||||
et l'authenticité de tous les documents. Veuillez confirmer que vous souhaitez continuer.
|
||||
</Typography>
|
||||
) : (
|
||||
<div className={classes["anchoring"]}>
|
||||
<Typography typo={ETypo.TEXT_MD_light}>
|
||||
<Typography typo={ETypo.TEXT_MD_LIGHT}>
|
||||
Vos documents sont en train d'être ancrés dans la blockchain. Cela peut prendre quelques instants. Merci de votre
|
||||
patience.
|
||||
</Typography>
|
||||
|
@ -37,7 +37,7 @@ export default function ArchiveModal(props: IProps) {
|
||||
firstButton={{ children: "Annuler", onClick: onClose }}
|
||||
secondButton={{ children: "Archiver le dossier", onClick: archive }}>
|
||||
<div className={classes["root"]}>
|
||||
<Typography typo={ETypo.TEXT_MD_light}>
|
||||
<Typography typo={ETypo.TEXT_MD_LIGHT}>
|
||||
Archiver ce dossier le déplacera dans la section des dossiers archivés. Vous pouvez ajouter une note de dossier avant
|
||||
d'archiver si vous le souhaitez.
|
||||
</Typography>
|
||||
|
@ -38,7 +38,7 @@ export default function DownloadAnchoringProofModal(props: IProps) {
|
||||
title={"Félicitations ! Dossier ancré avec succès"}
|
||||
firstButton={{ children: "Fermer", onClick: onClose }}
|
||||
secondButton={{ children: "Télécharger la preuve d’ancrage", onClick: downloadAnchoringProof }}>
|
||||
<Typography typo={ETypo.TEXT_MD_light}>
|
||||
<Typography typo={ETypo.TEXT_MD_LIGHT}>
|
||||
Votre dossier a été validé et ancré dans la blockchain. Vous pouvez maintenant télécharger la preuve d'ancrage pour vos
|
||||
archives.
|
||||
</Typography>
|
||||
|
@ -23,7 +23,7 @@ export default function RequireAnchoringModal(props: IProps) {
|
||||
title={"Archiver le dossier, action requise : Ancrer et certifier le dossier"}
|
||||
firstButton={{ children: "Annuler", onClick: onClose }}
|
||||
secondButton={{ children: "Ancrer le dossier", onClick: onAnchor }}>
|
||||
<Typography typo={ETypo.TEXT_MD_light}>
|
||||
<Typography typo={ETypo.TEXT_MD_LIGHT}>
|
||||
Pour archiver ce dossier, il est nécessaire de l'ancrer dans la blockchain afin de garantir la sécurité et l'authenticité
|
||||
des documents. Veuillez procéder à l'ancrage avant de continuer.
|
||||
</Typography>
|
||||
|
@ -1,5 +1,4 @@
|
||||
import Folders from "@Front/Api/LeCoffreApi/Customer/Folders/Folders";
|
||||
import BlockList, { IBlock } from "@Front/Components/DesignSystem/BlockList";
|
||||
import Typography, { ETypo } from "@Front/Components/DesignSystem/Typography";
|
||||
import DefaultDoubleSidePage from "@Front/Components/LayoutTemplates/DefaultDoubleSidePage";
|
||||
import JwtService from "@Front/Services/JwtService/JwtService";
|
||||
@ -9,6 +8,8 @@ import { useCallback, useEffect, useState } from "react";
|
||||
|
||||
import LandingImage from "../Login/landing-connect.jpeg";
|
||||
import classes from "./classes.module.scss";
|
||||
import { IBlock } from "@Front/Components/DesignSystem/SearchBlockList/BlockList/Block";
|
||||
import BlockList from "@Front/Components/DesignSystem/SearchBlockList/BlockList";
|
||||
|
||||
export default function SelectFolder() {
|
||||
const [folders, setFolders] = useState<OfficeFolder[]>([]);
|
||||
@ -66,7 +67,7 @@ export default function SelectFolder() {
|
||||
blocks={folders.map((folder) => {
|
||||
return {
|
||||
id: folder.uid!,
|
||||
name: folder.name!,
|
||||
primaryText: folder.name!,
|
||||
selected: false,
|
||||
};
|
||||
})}
|
||||
|
Loading…
x
Reference in New Issue
Block a user