Skip to content

Commit

Permalink
Adds company members request modal
Browse files Browse the repository at this point in the history
  • Loading branch information
kornifex committed Jan 13, 2025
1 parent 5cc4854 commit 8030e3b
Show file tree
Hide file tree
Showing 11 changed files with 404 additions and 188 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ describe("query membershipRequest", () => {
status: "PENDING",
email: requester.email,
siret: company.siret,
name: company.name,
name: requester.name,
sentTo: [admin.email, "so****@test.fr"] // emails not belonging to user email domain are partially redacted
});
});
Expand All @@ -127,7 +127,7 @@ describe("query membershipRequest", () => {
status: "PENDING",
email: requester.email,
siret: company.siret,
name: company.name
name: requester.name
});
});

Expand Down Expand Up @@ -157,7 +157,7 @@ describe("query membershipRequest", () => {
status: "PENDING",
email: requester.email,
siret: company.orgId,
name: company.name
name: requester.name
});
});
});
2 changes: 1 addition & 1 deletion back/src/users/resolvers/queries/membershipRequest.ts
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ const invitationRequestResolver: QueryResolvers["membershipRequest"] = async (
status: invitationRequest.status,
email: membershipRequestUser.email,
siret: company.orgId,
name: company.name ?? ""
name: membershipRequestUser.name ?? ""
};
};

Expand Down
168 changes: 0 additions & 168 deletions front/src/Apps/Account/AccountMembershipRequest.tsx

This file was deleted.

2 changes: 2 additions & 0 deletions front/src/Apps/Companies/CompanyMembers/CompanyMembers.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ import * as COMPANY_CONSTANTS from "@td/constants";

import "./companyMembers.scss";
import CompanyMembersList from "./CompanyMembersList";
import CompanyMembersRequestsList from "./CompanyMembersRequestsList";

const { VITE_VERIFY_COMPANY } = import.meta.env;

Expand All @@ -35,6 +36,7 @@ const CompanyMembers = ({

return (
<div className="company-members">
{isAdmin && <CompanyMembersRequestsList company={company} />}
{isAdmin &&
(VITE_VERIFY_COMPANY !== "true" ||
!isProfessional ||
Expand Down
Loading

0 comments on commit 8030e3b

Please sign in to comment.