Skip to content

Commit 06213ce

Browse files
Merge pull request #3379 from kris6673/intune-scripts
FEAT: Intune scripts page
2 parents be34d7b + a45dc74 commit 06213ce

File tree

4 files changed

+66
-4
lines changed

4 files changed

+66
-4
lines changed

src/layouts/config.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -250,6 +250,7 @@ export const nativeMenuItems = [
250250
{ title: "Protection Policies", path: "/endpoint/MEM/list-appprotection-policies" },
251251
{ title: "Apply Policy", path: "/endpoint/MEM/add-policy" },
252252
{ title: "Policy Templates", path: "/endpoint/MEM/list-templates" },
253+
{ title: "Scripts", path: "/endpoint/MEM/list-scripts" },
253254
],
254255
},
255256
{

src/pages/email/tools/mailbox-restores/index.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ const Page = () => {
1616
icon: <PlayArrow />,
1717
data: {
1818
Identity: "Identity",
19-
Action: "Resume",
19+
Action: "!Resume",
2020
},
2121
confirmText: "Are you sure you want to resume this restore request?",
2222
color: "info",
@@ -28,7 +28,7 @@ const Page = () => {
2828
icon: <Pause />,
2929
data: {
3030
Identity: "Identity",
31-
Action: "Suspend",
31+
Action: "!Suspend",
3232
},
3333
confirmText: "Are you sure you want to suspend this restore request?",
3434
color: "warning",
@@ -40,7 +40,7 @@ const Page = () => {
4040
icon: <Delete />,
4141
data: {
4242
Identity: "Identity",
43-
Action: "Remove",
43+
Action: "!Remove",
4444
},
4545
confirmText: "Are you sure you want to remove this restore request?",
4646
color: "danger",

src/pages/endpoint/MEM/list-policies/index.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ const Page = () => {
6060
},
6161
{
6262
label: "Delete Policy",
63-
type: "GET",
63+
type: "POST",
6464
url: "/api/RemovePolicy",
6565
data: {
6666
ID: "id",
Lines changed: 61 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,61 @@
1+
import { Layout as DashboardLayout } from "/src/layouts/index.js";
2+
import { CippTablePage } from "/src/components/CippComponents/CippTablePage.jsx";
3+
import { Code, TrashIcon } from "@heroicons/react/24/outline";
4+
5+
const Page = () => {
6+
const pageTitle = "Scripts";
7+
8+
const actions = [
9+
{
10+
label: "Delete Script",
11+
type: "POST",
12+
url: "/api/RemoveIntuneScript",
13+
data: {
14+
ID: "id",
15+
displayName: "displayName",
16+
ScriptType: "scriptType",
17+
},
18+
confirmText: "Are you sure you want to delete this script?",
19+
icon: <TrashIcon />,
20+
color: "danger",
21+
},
22+
];
23+
24+
const offCanvas = {
25+
extendedInfoFields: [
26+
"scriptType",
27+
"id",
28+
"fileName",
29+
"displayName",
30+
"description",
31+
"lastModifiedDateTime",
32+
"runAsAccount",
33+
"createdDateTime",
34+
"runAs32Bit",
35+
"executionFrequency",
36+
"enforceSignatureCheck",
37+
],
38+
actions: actions,
39+
};
40+
41+
const simpleColumns = [
42+
"scriptType",
43+
"displayName",
44+
"description",
45+
"runAsAccount",
46+
"lastModifiedDateTime",
47+
];
48+
49+
return (
50+
<CippTablePage
51+
title={pageTitle}
52+
apiUrl="/api/ListIntuneScript"
53+
actions={actions}
54+
offCanvas={offCanvas}
55+
simpleColumns={simpleColumns}
56+
/>
57+
);
58+
};
59+
60+
Page.getLayout = (page) => <DashboardLayout allTenantsSupport={false}>{page}</DashboardLayout>;
61+
export default Page;

0 commit comments

Comments
 (0)