Compare commits
3 Commits
e1f1093d84
...
63b1926056
| Author | SHA1 | Date | |
|---|---|---|---|
|
63b1926056
|
|||
|
25dc50e05c
|
|||
|
a403832735
|
@@ -169,20 +169,22 @@ export default function () {
|
|||||||
Decisions:
|
Decisions:
|
||||||
<br />
|
<br />
|
||||||
Approved:
|
Approved:
|
||||||
{Object.keys(currentInactivity.decisions ?? {}).filter(
|
{Object.keys(currentInactivity.decisions ?? {})
|
||||||
(d) => currentInactivity.decisions[d],
|
.filter((d) => currentInactivity.decisions[d])
|
||||||
)}
|
.join(", ")}
|
||||||
<br />
|
<br />
|
||||||
Denied:
|
Denied:
|
||||||
{Object.keys(currentInactivity.decisions ?? {}).filter(
|
{Object.keys(currentInactivity.decisions ?? {})
|
||||||
(d) => !currentInactivity.decisions[d],
|
.filter((d) => !currentInactivity.decisions[d])
|
||||||
)}
|
.join(", ")}
|
||||||
<br />
|
<br />
|
||||||
Pending:
|
Pending:
|
||||||
{currentInactivity.departments?.filter(
|
{currentInactivity.departments
|
||||||
(d: "DM" | "ET" | "FM" | "WM") =>
|
?.filter(
|
||||||
typeof currentInactivity.decisions[d] === "undefined",
|
(d: "DM" | "ET" | "FM" | "WM") =>
|
||||||
)}
|
typeof currentInactivity.decisions[d] === "undefined",
|
||||||
|
)
|
||||||
|
.join(", ")}
|
||||||
</ListItem>
|
</ListItem>
|
||||||
</UnorderedList>
|
</UnorderedList>
|
||||||
</ModalBody>
|
</ModalBody>
|
||||||
|
|||||||
@@ -91,8 +91,10 @@ export async function onRequestPost(context: RequestContext) {
|
|||||||
requestedNotice.decisions,
|
requestedNotice.decisions,
|
||||||
);
|
);
|
||||||
|
|
||||||
for (const department of userAdminDepartments)
|
for (const department of userAdminDepartments) {
|
||||||
|
if (!JSON.parse(requestedNotice.departments).includes(department)) continue;
|
||||||
decisions[department] = accepted;
|
decisions[department] = accepted;
|
||||||
|
}
|
||||||
|
|
||||||
const applicableDepartments = JSON.parse(requestedNotice.departments).length;
|
const applicableDepartments = JSON.parse(requestedNotice.departments).length;
|
||||||
|
|
||||||
|
|||||||
@@ -183,9 +183,10 @@ export async function onRequestPost(context: RequestContext) {
|
|||||||
|
|
||||||
const uploadUrlResults = await Promise.allSettled(uploadUrlPromises);
|
const uploadUrlResults = await Promise.allSettled(uploadUrlPromises);
|
||||||
|
|
||||||
const reportId = `${Date.now()}${context.request.headers.get(
|
const reportId = `${Date.now()}${context.request.headers
|
||||||
"cf-ray",
|
.get("cf-ray")
|
||||||
)}${crypto.randomUUID().replaceAll("-", "")}`;
|
?.split("-")
|
||||||
|
?.at(0)}${crypto.randomUUID().replaceAll("-", "")}`;
|
||||||
|
|
||||||
const { current_user: currentUser } = context.data;
|
const { current_user: currentUser } = context.data;
|
||||||
if (filesToProcess.length)
|
if (filesToProcess.length)
|
||||||
|
|||||||
Reference in New Issue
Block a user