Skip to content

Dev to release #3958

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 51 commits into from
Apr 13, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
51 commits
Select commit Hold shift + click to select a range
973571f
feat: Phishing Simulation Configuration standard
OfficialEsco Mar 27, 2025
9a0c926
feat: Spoof Intelligence standard
OfficialEsco Mar 28, 2025
9921e1b
feat: DefaultPlatformRestrictions standard
OfficialEsco Mar 31, 2025
fcd89d4
fix multiple link clicks
JohnDuprey Mar 31, 2025
ae64d69
Add enable/disable mailbox rule actions with confirmation prompts
kris6673 Mar 31, 2025
572b38f
Merge pull request #3899 from kris6673/feat-set-mailbox-rules
KelvinTegelaar Mar 31, 2025
94e0413
Merge pull request #3897 from Ren-Roros-Digital/DefaultPlatformRestri…
KelvinTegelaar Mar 31, 2025
119fc6e
Merge pull request #3895 from Ren-Roros-Digital/PhishSimSpoofIntellig…
KelvinTegelaar Mar 31, 2025
ab38d8a
Merge pull request #3883 from Ren-Roros-Digital/PhishingSimulations
KelvinTegelaar Mar 31, 2025
b3db8ed
object flattening for better CSV export
JohnDuprey Apr 2, 2025
5558270
handle formatting on nested objects
JohnDuprey Apr 2, 2025
f0d1ce9
sort integration companies
JohnDuprey Apr 2, 2025
82a3180
feat: add litigation hold action to CippExchangeActions component
kris6673 Apr 2, 2025
9b34ba6
fix: update litigation hold action to use 'Identity' and add conditio…
kris6673 Apr 3, 2025
6dc321c
Better text maybe?
kris6673 Apr 3, 2025
eb7613a
fix replace text on JSX elements in CippApiDialog
JohnDuprey Apr 4, 2025
816201b
offcanvas support for CippInfoBar
JohnDuprey Apr 4, 2025
7e9fc57
feat: add rename ap device action with validation
kris6673 Apr 4, 2025
1be89a0
Reorder
kris6673 Apr 4, 2025
2de712b
feat: add edit group tag action for autopilot devices with validation
kris6673 Apr 4, 2025
9fc8b10
Merge pull request #3931 from kris6673/ap-device-renmaing
JohnDuprey Apr 5, 2025
3031591
Merge pull request #3922 from kris6673/feat-lithold
JohnDuprey Apr 5, 2025
35f7da5
multipost for quartinune
KelvinTegelaar Apr 8, 2025
8a9667a
message trace id
KelvinTegelaar Apr 8, 2025
6d6fe86
feat: Sharepoint Mass Deletion Alert standard
OfficialEsco Apr 7, 2025
a0eb6ab
dev feat: cspell
OfficialEsco Apr 9, 2025
d34a722
fix BEC polling
JohnDuprey Apr 9, 2025
08a325b
fix add group template
JohnDuprey Apr 11, 2025
181bf3f
fix bpa sync
JohnDuprey Apr 11, 2025
e5332e8
fix edit alert with tenant exclusions
JohnDuprey Apr 11, 2025
edff8a6
Update Close_Stale_Issues_and_PRs.yml
kris6673 Apr 11, 2025
6c11192
chore: more words & cleanup standards.json
OfficialEsco Apr 11, 2025
5d29667
Merge pull request #3933 from Ren-Roros-Digital/SharePointMassDeletio…
JohnDuprey Apr 11, 2025
61538c0
Merge pull request #3942 from Ren-Roros-Digital/spellcheck
JohnDuprey Apr 11, 2025
016ef6b
Merge pull request #3954 from kris6673/kris6673-patch-2
JohnDuprey Apr 11, 2025
8534996
chore: add missing powershellEquivalent value
OfficialEsco Apr 11, 2025
79888db
Merge pull request #3955 from Ren-Roros-Digital/powershellEquivalent
JohnDuprey Apr 11, 2025
18db036
Sherweb code changes
KelvinTegelaar Apr 12, 2025
da805ec
fix scheduler form and add run now
JohnDuprey Apr 12, 2025
3064fba
new scheduled task details
JohnDuprey Apr 12, 2025
a7ca3d3
add more filters and tweaks to scheduled task detail
JohnDuprey Apr 12, 2025
96935f7
standards ui tweaks
JohnDuprey Apr 12, 2025
c668b0d
also filter by category
JohnDuprey Apr 12, 2025
c9dc223
add status check for if reporting is enabled on the template
JohnDuprey Apr 13, 2025
49d2bee
update extensions
JohnDuprey Apr 13, 2025
015cf88
fix resubmit support
JohnDuprey Apr 13, 2025
84f4e75
scheduled task info page
JohnDuprey Apr 13, 2025
69fe571
Add sort
KelvinTegelaar Apr 13, 2025
9bf1fee
task removal
KelvinTegelaar Apr 13, 2025
d8e150a
standards organization
JohnDuprey Apr 13, 2025
0077702
version up
KelvinTegelaar Apr 13, 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
4 changes: 2 additions & 2 deletions .github/workflows/Close_Stale_Issues_and_PRs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,6 @@ jobs:
stale-issue-message: 'This issue is stale because it has been open 10 days with no activity. We will close this issue soon. If you want this feature implemented you can contribute it. See: https://docs.cipp.app/dev-documentation/contributing-to-the-code . Please notify the team if you are working on this yourself.'
close-issue-message: 'This issue was closed because it has been stalled for 14 days with no activity.'
stale-issue-label: 'no-activity'
exempt-issue-labels: 'planned'
exempt-issue-labels: 'planned,bug'
days-before-stale: 9
days-before-close: 14
days-before-close: 5
6 changes: 6 additions & 0 deletions .vscode/extensions.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"recommendations": [
"editorconfig.editorconfig",
"streetsidesoftware.code-spell-checker",
]
}
31 changes: 31 additions & 0 deletions cspell.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
{
"version": "0.2",
"ignorePaths": [],
"dictionaryDefinitions": [],
"dictionaries": [],
"words": [
"CIPP",
"CIPP-API",
"Entra",
"Intune",
"GDAP",
"OBEE",
"AITM",
"Passwordless",
"Yubikey",
"Sherweb",
"Autotask",
"Datto",
"Syncro",
"ImmyBot",
"Choco",
],
"ignoreWords": [
"CIPPAPI",
"locationcipp",
"TNEF",
"winmail",
"PSTN",
],
"import": []
}
2 changes: 1 addition & 1 deletion public/version.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
"version": "7.4.2"
"version": "7.5.0"
}
150 changes: 97 additions & 53 deletions src/components/CippCards/CippInfoBar.jsx
Original file line number Diff line number Diff line change
@@ -1,58 +1,102 @@
import React, { useState } from "react";
import { Box, Card, Stack, SvgIcon, Typography, Skeleton } from "@mui/material";
import Grid from "@mui/material/Grid";
import { CippOffCanvas } from "../CippComponents/CippOffCanvas";
import { CippPropertyListCard } from "./CippPropertyListCard";

export const CippInfoBar = ({ data, isFetching }) => (
<Card>
<Grid container>
{data.map((item) => (
<Grid
xs={12}
sm={6}
md={3}
key={item.name}
sx={{
borderBottom: (theme) => ({
xs: `1px solid ${theme.palette.divider}`,
md: "none",
}),
borderRight: (theme) => ({
md: `1px solid ${theme.palette.divider}`,
}),
"&:nth-of-type(3)": {
borderBottom: (theme) => ({
xs: `1px solid ${theme.palette.divider}`,
sm: "none",
}),
},
"&:nth-of-type(4)": {
borderBottom: "none",
borderRight: "none",
},
}}
>
<Stack alignItems="center" direction="row" spacing={2} sx={{ p: 2 }}>
{item?.icon && (
<SvgIcon color={item.color ? item.color : "primary"} fontSize="small">
{item.icon}
</SvgIcon>
)}
<Box
sx={() => {
if (!item?.icon) {
return { pl: 2 };
}
export const CippInfoBar = ({ data, isFetching }) => {
const [visibleIndex, setVisibleIndex] = useState(null);

return (
<Card>
<Grid container>
{data.map((item, index) => (
<>
<Grid
xs={12}
sm={6}
md={3}
key={item.name}
onClick={item.offcanvas ? () => setVisibleIndex(index) : undefined}
sx={{
cursor: item.offcanvas ? "pointer" : "default",
borderBottom: (theme) => ({
xs: `1px solid ${theme.palette.divider}`,
md: "none",
}),
borderRight: (theme) => ({
md: `1px solid ${theme.palette.divider}`,
}),
"&:nth-of-type(3)": {
borderBottom: (theme) => ({
xs: `1px solid ${theme.palette.divider}`,
sm: "none",
}),
},
"&:nth-of-type(4)": {
borderBottom: "none",
borderRight: "none",
},
}}
>
<Typography color="text.secondary" variant="overline">
{item.name}
</Typography>
<Typography variant="h6">
{isFetching ? <Skeleton width={"100%"} /> : item.data}
</Typography>
</Box>
</Stack>
</Grid>
))}
</Grid>
</Card>
);
<Stack alignItems="center" direction="row" spacing={2} sx={{ p: 2 }}>
{item?.icon && (
<SvgIcon color={item.color ? item.color : "primary"} fontSize="small">
{item.icon}
</SvgIcon>
)}
<Box
sx={() => {
if (!item?.icon) {
return { pl: 2 };
}
}}
>
<Typography color="text.secondary" variant="overline">
{item.name}
</Typography>
<Typography variant="h6">
{isFetching ? <Skeleton width={"100%"} /> : item.data}
</Typography>
</Box>
</Stack>
</Grid>
{item.offcanvas && (
<>
{console.log("item.offcanvas", item.offcanvas)}
<CippOffCanvas
title={item?.offcanvas?.title || "Details"}
size="md"
visible={visibleIndex === index}
onClose={() => setVisibleIndex(null)}
>
<Box
sx={{
overflowY: "auto",
maxHeight: "100%",
display: "flex",
flexDirection: "column",
}}
>
<Grid container spacing={1}>
<Grid item xs={12}>
{item?.offcanvas?.propertyItems?.length > 0 && (
<CippPropertyListCard
isFetching={isFetching}
align="vertical"
title={item?.offcanvas?.title}
propertyItems={item.offcanvas.propertyItems ?? []}
/>
)}
</Grid>
</Grid>
</Box>
</CippOffCanvas>
</>
)}
</>
))}
</Grid>
</Card>
);
};
92 changes: 92 additions & 0 deletions src/components/CippComponents/BPASyncDialog.jsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,92 @@
import React, { useState } from "react";
import {
Dialog,
DialogContent,
DialogTitle,
Button,
DialogActions,
Alert,
CircularProgress,
} from "@mui/material";
import { CheckCircle, Error, Sync } from "@mui/icons-material";
import { useForm, FormProvider } from "react-hook-form";
import { CippFormTenantSelector } from "./CippFormTenantSelector";
import { ApiPostCall } from "/src/api/ApiCall";
import { CippApiResults } from "./CippApiResults";

export const BPASyncDialog = ({ createDialog }) => {
const methods = useForm({
defaultValues: {
tenantFilter: {
value: "AllTenants",
label: "*All Tenants",
},
},
});

// Use methods for form handling and control
const { handleSubmit, control } = methods;

const [tenantId, setTenantId] = useState("");
const [isSyncing, setIsSyncing] = useState(false);

// Use ApiGetCall instead of useApiCall
const bpaSyncResults = ApiPostCall({
urlfromdata: true,
});

const handleForm = (values) => {
setTenantId(values.tenantFilter || "");
setIsSyncing(true);

bpaSyncResults.mutate({
url: "/api/ExecBPA",
queryKey: `bpa-sync-${tenantId}`,
data: tenantId ? { TenantFilter: tenantId } : {},
});
};

// Reset syncing state when dialog is closed
const handleClose = () => {
setIsSyncing(false);
createDialog.handleClose();
};

return (
<Dialog open={createDialog.open} onClose={handleClose} maxWidth="sm" fullWidth>
<FormProvider {...methods}>
<form onSubmit={handleSubmit(handleForm)}>
<DialogTitle>Force BPA Sync</DialogTitle>
<DialogContent>
<div className="mb-3">
<p>
This will force a Best Practice Analyzer (BPA) sync. Select a tenant (or all
tenants) below.
</p>
<CippFormTenantSelector
formControl={control}
name="tenantFilter"
required={false}
disableClearable={false}
allTenants={true}
type="single"
/>
</div>
<CippApiResults apiObject={bpaSyncResults} alertSx={{ mt: 2 }} />
</DialogContent>
<DialogActions>
<Button onClick={handleClose}>Cancel</Button>
<Button
type="submit"
variant="contained"
disabled={isSyncing && bpaSyncResults.isLoading}
startIcon={<Sync />}
>
Sync BPA
</Button>
</DialogActions>
</form>
</FormProvider>
</Dialog>
);
};
50 changes: 38 additions & 12 deletions src/components/CippComponents/CippApiDialog.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { Button, Dialog, DialogActions, DialogContent, DialogTitle, Grid } from
import { Stack } from "@mui/system";
import { CippApiResults } from "./CippApiResults";
import { ApiGetCall, ApiPostCall } from "../../api/ApiCall";
import { useEffect, useState } from "react";
import React, { useEffect, useState } from "react";
import { useForm } from "react-hook-form";
import { useSettings } from "../../hooks/use-settings";
import CippFormComponent from "./CippFormComponent";
Expand Down Expand Up @@ -284,6 +284,10 @@ export const CippApiDialog = (props) => {

const [linkClicked, setLinkClicked] = useState(false);

useEffect(() => {
setLinkClicked(false);
}, [api.link]);

useEffect(() => {
if (api.link && !linkClicked && row && Object.keys(row).length > 0) {
const timeoutId = setTimeout(() => {
Expand Down Expand Up @@ -319,18 +323,40 @@ export const CippApiDialog = (props) => {
};

var confirmText;
if (typeof api?.confirmText === "string" && !Array.isArray(row)) {
confirmText = api.confirmText.replace(/\[([^\]]+)\]/g, (_, key) => {
return getNestedValue(row, key) || `[${key}]`;
});
} else if (Array.isArray(row) && row.length > 1) {
confirmText = api.confirmText.replace(/\[([^\]]+)\]/g, "the selected rows");
} else if (Array.isArray(row) && row.length === 1) {
confirmText = api.confirmText.replace(/\[([^\]]+)\]/g, (_, key) => {
return getNestedValue(row[0], key) || `[${key}]`;
});
if (typeof api?.confirmText === "string") {
if (!Array.isArray(row)) {
confirmText = api.confirmText.replace(/\[([^\]]+)\]/g, (_, key) => {
return getNestedValue(row, key) || `[${key}]`;
});
} else if (row.length > 1) {
confirmText = api.confirmText.replace(/\[([^\]]+)\]/g, "the selected rows");
} else if (row.length === 1) {
confirmText = api.confirmText.replace(/\[([^\]]+)\]/g, (_, key) => {
return getNestedValue(row[0], key) || `[${key}]`;
});
}
} else {
confirmText = api.confirmText;
// Handle JSX/Component confirmText
const replaceTextInElement = (element) => {
if (!element) return element;
if (typeof element === "string") {
if (Array.isArray(row) && row.length > 1) {
return element.replace(/\[([^\]]+)\]/g, "the selected rows");
} else if (Array.isArray(row) && row.length === 1) {
return element.replace(
/\[([^\]]+)\]/g,
(_, key) => getNestedValue(row[0], key) || `[${key}]`
);
}
return element.replace(/\[([^\]]+)\]/g, (_, key) => getNestedValue(row, key) || `[${key}]`);
}
if (React.isValidElement(element)) {
const newChildren = React.Children.map(element.props.children, replaceTextInElement);
return React.cloneElement(element, {}, newChildren);
}
return element;
};
confirmText = replaceTextInElement(api?.confirmText);
}

return (
Expand Down
2 changes: 1 addition & 1 deletion src/components/CippComponents/CippApiResults.jsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { Close, Download, RouterOutlined } from "@mui/icons-material";
import { Close, Download } from "@mui/icons-material";
import {
Alert,
CircularProgress,
Expand Down
Loading
Loading