Skip to content
Open

Dev #49

Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
68 commits
Select commit Hold shift + click to select a range
72bf848
updaet to next 15
github4touchdouble Nov 22, 2024
95c27c7
added billing
github4touchdouble Nov 24, 2024
2c82c62
added billing
github4touchdouble Nov 24, 2024
526f8e8
fixed issue #40: client token claim and access token claim
github4touchdouble Nov 24, 2024
949e777
fixed issue #46: press avatar in proile setttings to update image
github4touchdouble Nov 24, 2024
9bfdd73
fixed issue #46: press avatar in proile setttings to update image
github4touchdouble Nov 24, 2024
09dc5f9
fixed issue #46: press avatar in proile setttings to update image
github4touchdouble Nov 24, 2024
6453a64
fixed issue #46: press avatar in proile setttings to update image
github4touchdouble Nov 24, 2024
466b106
set next version
github4touchdouble Nov 25, 2024
aefc297
set next version
github4touchdouble Nov 25, 2024
a9080d5
fixed issue #39: date values in job, application, sectret table is ch…
github4touchdouble Nov 25, 2024
e81802a
working commit
github4touchdouble Nov 27, 2024
81febed
finished application form preview
github4touchdouble Nov 27, 2024
6ca38e7
finished application form preview
github4touchdouble Nov 27, 2024
5ff8717
working commit
github4touchdouble Nov 27, 2024
cc5ca34
updated application vie
github4touchdouble Nov 28, 2024
3910b10
worring commit
github4touchdouble Nov 29, 2024
d9e7186
rage com it
github4touchdouble Nov 29, 2024
c6540e3
rage com it
github4touchdouble Nov 29, 2024
74556e4
rage com it
github4touchdouble Nov 29, 2024
9dca718
bugfix - no more rage
github4touchdouble Nov 30, 2024
4482af7
Updated editor
github4touchdouble Dec 1, 2024
5ee3646
job editor preliminary done
github4touchdouble Dec 1, 2024
58bcf7e
bugfix
github4touchdouble Dec 1, 2024
a4427f8
updated applicant info
github4touchdouble Dec 1, 2024
c074949
buffixed alpplciation forme ditor
github4touchdouble Dec 1, 2024
2fdc1b3
added remove button
github4touchdouble Dec 1, 2024
f353c31
added prelim new job builder
github4touchdouble Dec 1, 2024
ab4e214
working commit
github4touchdouble Dec 1, 2024
b360ea5
added unlist/list
github4touchdouble Dec 1, 2024
640d2f9
bufgix
github4touchdouble Dec 1, 2024
58fc22d
added up/down buttons
github4touchdouble Dec 4, 2024
3a17b14
Updated job detail layout
github4touchdouble Dec 4, 2024
05c433d
bugfix: tooltip has background color now and is no longer transparent
github4touchdouble Dec 4, 2024
e025351
bugfix: editableEmbloyH1 doesnt switch to normal EmbloyH1 when new co…
github4touchdouble Dec 4, 2024
3464cc8
addded active integrations only
github4touchdouble Dec 4, 2024
7773c54
wortking commit
github4touchdouble Dec 5, 2024
8de73d6
fixed otolip bug
github4touchdouble Dec 5, 2024
ef67985
working commit
github4touchdouble Dec 9, 2024
da1ae01
working commit
github4touchdouble Dec 9, 2024
3bb17b5
working commit
github4touchdouble Dec 9, 2024
a73180f
working commit
github4touchdouble Dec 11, 2024
08e1473
working commit
github4touchdouble Dec 11, 2024
737589d
working commit
github4touchdouble Dec 11, 2024
3e9f9b7
working commit
github4touchdouble Dec 11, 2024
56090be
working commit
github4touchdouble Dec 11, 2024
e10113b
working commit
github4touchdouble Dec 11, 2024
f361282
working commit
github4touchdouble Dec 12, 2024
975f28f
working commit
github4touchdouble Dec 12, 2024
b49d639
added headings
github4touchdouble Dec 14, 2024
9c4e7cf
workng commit
github4touchdouble Dec 19, 2024
b058385
working commit
github4touchdouble Dec 20, 2024
bd9105d
working commit
github4touchdouble Dec 20, 2024
5f35c1b
falty woirkgin kommit
github4touchdouble Dec 22, 2024
56a926e
working commit
github4touchdouble Dec 26, 2024
32e5b84
working commit
github4touchdouble Dec 29, 2024
a5f655f
working commit
github4touchdouble Dec 30, 2024
5e1a399
eorking commit
github4touchdouble Dec 30, 2024
de51a63
working commirt
github4touchdouble Dec 30, 2024
7afa4ea
fixed remove bug
github4touchdouble Dec 31, 2024
6762dd9
fixed issue #50: specific error message for too large company logo fi…
github4touchdouble Dec 31, 2024
d601bf2
fixed issue #51: redirect to stripe session is now correct
github4touchdouble Dec 31, 2024
30bf43c
added N/A placeholder to jobdatatable and removed view column until v…
github4touchdouble Dec 31, 2024
eddef85
working commit
github4touchdouble Dec 31, 2024
d302a20
added board to anvbar and prevented /recruitment?tab=postings toolbar…
github4touchdouble Jan 1, 2025
4c03ccc
fixed build issues
github4touchdouble Jan 1, 2025
67b40c9
fixed bug: when file application option item is created in form edito…
github4touchdouble Jan 1, 2025
fef3e2b
Empty commit to trigger new deployment
carlobortolan Jan 2, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
<h1><a href="https://about.embloy.com">Embloy Genius</a></h1>


This repository contains the code for the web application of Embloy Genius. In the future it will be available online at: [https://genius.embloy.com](https://genius.embloy.com)
## License

Expand Down
20 changes: 11 additions & 9 deletions app/analytics/page.js
Original file line number Diff line number Diff line change
@@ -1,18 +1,20 @@
"use client";
import React from "react";
import React, { useEffect } from "react";
import { useRouter } from "next/navigation";
import { EmbloyPageMount, EmbloyPage, EmbloyPageBody } from "@/app/components/ui/misc/page";

import { EmbloyPageMount, EmbloyPage, EmbloyPageBody, EmbloyPageBodySection, EmbloySubPage } from "@/app/components/ui/misc/page";
export default function Analytics() {
const router = useRouter();

export default function Analytics() { return (
useEffect(() => {
router.back();
}, [router]);

return (
<EmbloyPageMount className="overflow-hidden">
<EmbloyPage sandboxed={false}>
<EmbloyPageBody >

</EmbloyPageBody >
<EmbloyPageBody />
</EmbloyPage>



</EmbloyPageMount>
);
}
4 changes: 2 additions & 2 deletions app/components/dom/bottom/footerbar.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,14 +17,14 @@ const Footerbar = () => {
}


let user = useContext(UserContext)
let {user, company, subscription} = useContext(UserContext)
let store = useContext(StoreContext)


return (
<>
<div
className="z-20 w-full h-14 border-t-[1px] border-vesuvio dark:border-ischia flex flex-row items-center justify-center bg-body">
className="z-20 w-full h-14 border-t-[1px] border-etna dark:border-ischia flex flex-row items-center justify-center bg-body">
<div className="container h-full max-w-7/12 flex flex-row items-center justify-center gap-12">

<div className="flex flex-row items-center justify-start gap-2">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ export function DataTableColumnHeader<TData, TValue>({
<div className={cn("w-full flex items-center space-x-2", className)}>
<div className="focus:outline-none">
<DropdownMenu>
<DropdownMenuTrigger asChild className="text-xs font-normal focus:outline-none bg-transparent dark:bg-transparent cursor-pointer hover:text-leidoveneta dark:hover:text-barbera rounded-full">
<DropdownMenuTrigger asChild className="text-xs font-normal focus:outline-none bg-transparent dark:bg-transparent cursor-pointer hover:text-capri dark:hover:text-barbera rounded-full">
<Button
variant="ghost"
size="sm"
Expand Down
14 changes: 7 additions & 7 deletions app/components/dom/main/datatable/DataTablePagination.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -64,13 +64,14 @@ export function DataTablePagination<TData>({
onValueChange={(value) => {
table.setPageSize(Number(value))
}}

>
<SelectTrigger className={undefined}>
<SelectTrigger className={"border-[1px] border-etna dark:border-rubeno dark:bg-nebbiolo"}>
<SelectValue placeholder={table.getState().pagination.pageSize} />
</SelectTrigger>
<SelectContent side="top">
{[10, 20, 30, 40, 50].map((pageSize) => (
<SelectItem key={pageSize} value={`${pageSize}`}>
<SelectItem key={pageSize} className="cursor-pointer" value={`${pageSize}`}>
{pageSize}
</SelectItem>
))}
Expand All @@ -94,7 +95,6 @@ export function DataTablePagination<TData>({
className="relative"
/>
</button>
<div className="w-1" />
<button
onMouseEnter={handlePreviousHover}
onMouseLeave={handlePreviousNotHover}
Expand All @@ -110,10 +110,12 @@ export function DataTablePagination<TData>({
className="relative"
/>
</button>
<div className="w-1" />
<EmbloyP className="flex items-center justify-center text-xs ">
Page {table.getState().pagination.pageIndex + 1} of{" "}
{table.getPageCount()}
</EmbloyP >
<div className="w-1" />
<button
onMouseEnter={handleNextHover}
onMouseLeave={handleNextNotHover}
Expand All @@ -129,7 +131,6 @@ export function DataTablePagination<TData>({
className="relative"
/>
</button>
<div className="w-1" />
<button
onMouseEnter={handleDoubleNextHover}
onMouseLeave={handleDoubleNextNotHover}
Expand All @@ -146,7 +147,6 @@ export function DataTablePagination<TData>({
/>
</button>
</div>

</div>
</div>
)
Expand All @@ -164,14 +164,14 @@ export function DataTablePagination<TData>({
<div className="flex items-center justify-between px-2">
<div className="flex items-center justify-end space-x-2 gap-4">
<div className="flex items-center space-x-2">
<EmbloyP className="text-xs">Rows per page</EmbloyP>
<EmbloyP className="text-xs">Rows/page</EmbloyP>
<Select
value={`${table.getRowModel().rows.length}`}
onValueChange={(value) => {
table.setPageSize(Number(value))
}}
>
<SelectTrigger className="h-8 w-[70px]">
<SelectTrigger className={"border-[1px] border-etna dark:border-rubeno dark:bg-nebbiolo"}>
<SelectValue placeholder={table.getState().pagination.pageSize} />
</SelectTrigger>
<SelectContent side="top">
Expand Down
172 changes: 172 additions & 0 deletions app/components/dom/main/datatable/job_remove_button.jsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,172 @@
"use client";
import React, { useEffect, useRef, useState } from "react";
import '@/app/globals.css';
import { Modal, ModalContent, ModalBody, ModalFooter, Button, useDisclosure } from "@nextui-org/react";
import { cn } from "@/lib/utils";
import { EmbloyToolboxImgAdvanced } from "@/app/components/ui/misc/toolbox";
import { EmbloyP } from "@/app/components/ui/misc/text";
import { not_core_get } from "@/lib/api/core";

export function RemoveJobButton({ getSelectedRows, onUploadSuccess, getJob }) {
const consentModal = useDisclosure();
const [numOfJobs, setNumOfJobs] = useState(0); // State to track the number of jobs

const updateNumOfJobs = () => {
const selectedRows = getSelectedRows();
let num = 0;
for (const jobId of Object.keys(selectedRows)) {
const job = getJob(jobId);
if (job?.job_status !== "listed") {
num++;
}
}
setNumOfJobs(num);
};

const handleDivClick = () => {
if (!consentModal.isOpen && numOfJobs > 0) {
consentModal.onOpen();
}
};

const [status, setStatus] = useState(null);

const handleRemoval = async () => {
const selectedRows = getSelectedRows();
if (selectedRows) {
setStatus("loading");
let accumulatedErrors = [];
for (const jobId of Object.keys(selectedRows)) {
const job = getJob(jobId);
const job_id = job?.id;
if (!job_id || job.job_status === "listed") {
continue;
}
try {
await not_core_get("PATCH", `/jobs?id=${job_id}`, { job_status: "archived" });
} catch (e) {
accumulatedErrors.push(e);
}
}
if (accumulatedErrors.length === 0) {
onUploadSuccess();
setStatus(null);
} else {
setStatus("error");
}
consentModal.onClose();
updateNumOfJobs(); // Update the count after removal
}
};

const [isWindows, setIsWindows] = useState(false);

useEffect(() => {
if (typeof navigator !== "undefined") {
setIsWindows(navigator.userAgent.includes("Windows"));
}
}, []);

useEffect(() => {
updateNumOfJobs(); // Update the count whenever the component renders
}, [getSelectedRows]);

return (
<div
onClick={handleDivClick}
className={cn(
numOfJobs > 0 ? "relative inline-block cursor-pointer" : "relative inline-block cursor-not-allowed"
)}
>
<div className={cn(numOfJobs > 0 ? "cursor-pointer" : "pointer-events-none")}>
<EmbloyToolboxImgAdvanced
tooltip="Remove Active Posting(s)"
path="/icons/svg/black/bin.svg"
path_hovered="/icons/svg/capri/bin.svg"
dark_path="/icons/svg/amarone/bin.svg"
dark_path_hovered="/icons/svg/barbera/bin.svg"
height="12"
width="12"
disabled={numOfJobs === 0}
path_disabled={"/icons/svg/etna/bin.svg"}
dark_path_disabled={"/icons/svg/nebbiolo/bin.svg"}
/>
</div>

<Modal
isOpen={consentModal.isOpen}
scrollBehavior="inside"
size="xs"
className={`${isWindows && "w-64 rounded-md bg-white dark:bg-chianti border-[1px] border-etna dark:border-nebbiolo"} select-text cursor-auto`}
onOpenChange={consentModal.onOpenChange}
>
<ModalContent className={`${!isWindows && "pt-4"}`}>
<>
<ModalBody
className={cn(
isWindows && "w-full flex flex-col items-end",
status === "loading" ? "opacity-25" : "opacity-100"
)}
>
<EmbloyP className="text-sm w-full text-left">
{`Remove ${numOfJobs} job${numOfJobs > 1 ? "s" : ""}?`}
</EmbloyP>
</ModalBody>
<ModalFooter>
{status === "loading" && (
<button
className="rounded-full c2-5 hover:underline text-xs bgneg"
disabled={status === "loading"}
>
<div role="status">
<svg
aria-hidden="true"
className="inline w-4 h-4 mr-2 text-gray-500 animate-spin fill-white"
viewBox="0 0 100 101"
fill="none"
xmlns="http://www.w3.org/2000/svg"
>
<path
d="M100 50.5908C100 78.2051 77.6142 100.591 50 100.591C22.3858 100.591 0 78.2051 0 50.5908C0 22.9766 22.3858 0.59082 50 0.59082C77.6142 0.59082 100 22.9766 100 50.5908ZM9.08144 50.5908C9.08144 73.1895 27.4013 91.5094 50 91.5094C72.5987 91.5094 90.9186 73.1895 90.9186 50.5908C90.9186 27.9921 72.5987 9.67226 50 9.67226C27.4013 9.67226 9.08144 27.9921 9.08144 50.5908Z"
fill="currentColor"
/>
<path
d="M93.9676 39.0409C96.393 38.4038 97.8624 35.9116 97.0079 33.5539C95.2932 28.8227 92.871 24.3692 89.8167 20.348C85.8452 15.1192 80.8826 10.7238 75.2124 7.41289C69.5422 4.10194 63.2754 1.94025 56.7698 1.05124C51.7666 0.367541 46.6976 0.446843 41.7345 1.27873C39.2613 1.69328 37.813 4.19778 38.4501 6.62326C39.0873 9.04874 41.5694 10.4717 44.0505 10.1071C47.8511 9.54855 51.7191 9.52689 55.5402 10.0491C60.8642 10.7766 65.9928 12.5457 70.6331 15.2552C75.2735 17.9648 79.3347 21.5619 82.5849 25.841C84.9175 28.9121 86.7997 32.2913 88.1811 35.8758C89.083 38.2158 91.5421 39.6781 93.9676 39.0409Z"
fill="currentFill"
/>
</svg>
<span className="sr-only">Loading...</span>
</div>
</button>
)}
<button
onClick={consentModal.onClose}
className={cn(
status === "loading"
? "cursor-not-allowed py-0.5 px-1.5"
: "rounded-md py-0.5 px-1.5"
)}
disabled={status === "loading"}
>
<EmbloyP className="text-xs text-capri dark:text-capri hover:underline">Cancel</EmbloyP>
</button>
<button
onClick={handleRemoval}
className={cn(
status === "loading"
? "cursor-not-allowed py-0.5 px-1.5"
: "rounded-sm py-0.5 px-1.5 transition-colors duration-200"
)}
disabled={status === "loading"}
>
<EmbloyP className="text-xs text-primitivo dark:text-primitivo hover:underline">
Remove
</EmbloyP>
</button>
</ModalFooter>
</>
</ModalContent>
</Modal>
</div>
);
}
Loading