Skip to content

Commit

Permalink
Merge pull request #94 from KelvinTegelaar/dev
Browse files Browse the repository at this point in the history
[pull] dev from KelvinTegelaar:dev
  • Loading branch information
pull[bot] authored Feb 12, 2025
2 parents fe0aa87 + 5d46544 commit 2cd6e01
Show file tree
Hide file tree
Showing 16 changed files with 629 additions and 176 deletions.
2 changes: 1 addition & 1 deletion src/components/CippComponents/CippApiResults.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -294,7 +294,7 @@ export const CippApiResults = (props) => {
))}
</>
)}
{(apiObject.isSuccess || apiObject.isError) && finalResults.length > 0 ? (
{(apiObject.isSuccess || apiObject.isError) && finalResults?.length > 0 ? (
<Box display="flex" flexDirection="row">
<Tooltip title="View Results">
<IconButton onClick={() => tableDialog.handleOpen()}>
Expand Down
2 changes: 1 addition & 1 deletion src/components/CippComponents/CippAutocomplete.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -275,7 +275,7 @@ export const CippAutoComplete = (props) => {
sx={sx}
renderInput={(params) => (
<Stack direction="row" spacing={1}>
<MemoTextField params={params} label={label} placeholder={placeholder} required= {...other} />
<MemoTextField params={params} label={label} placeholder={placeholder} required={required} {...other} />
{api?.url && api?.showRefresh && (
<IconButton
size="small"
Expand Down
2 changes: 1 addition & 1 deletion src/components/CippTable/CippGraphExplorerFilter.js
Original file line number Diff line number Diff line change
Expand Up @@ -462,7 +462,7 @@ const CippGraphExplorerFilter = ({
if (presetName) onPresetChange(presetName);
}
onSubmitFilter(values);
setCardExpanded(!cardExpanded);
setCardExpanded(false);
};

console.log(cardExpanded);
Expand Down
17 changes: 15 additions & 2 deletions src/data/standards.json
Original file line number Diff line number Diff line change
Expand Up @@ -800,7 +800,7 @@
"impact": "High Impact",
"impactColour": "danger",
"powershellEquivalent": "Update-MgBetaPolicyAuthenticationMethodPolicyAuthenticationMethodConfiguration",
"recommendedBy": []
"recommendedBy": ["CIPP"]
},
{
"name": "standards.DisableVoice",
Expand All @@ -813,7 +813,7 @@
"impact": "High Impact",
"impactColour": "danger",
"powershellEquivalent": "Update-MgBetaPolicyAuthenticationMethodPolicyAuthenticationMethodConfiguration",
"recommendedBy": []
"recommendedBy": ["CIPP"]
},
{
"name": "standards.DisableEmail",
Expand All @@ -840,6 +840,19 @@
"powershellEquivalent": "Update-MgBetaPolicyAuthenticationMethodPolicyAuthenticationMethodConfiguration",
"recommendedBy": []
},
{
"name": "standards.DisableQRCodePin",
"cat": "Entra (AAD) Standards",
"tag": ["highimpact"],
"helpText": "This blocks users from using QR Code Pin as an MFA method. If a user only has QR Code Pin as a MFA method, they will be unable to log in.",
"docsDescription": "Disables QR Code Pin as an MFA method for the tenant. If a user only has QR Code Pin as a MFA method, they will be unable to sign in.",
"addedComponent": [],
"label": "Disables QR Code Pin as an MFA method",
"impact": "High Impact",
"impactColour": "danger",
"powershellEquivalent": "Update-MgBetaPolicyAuthenticationMethodPolicyAuthenticationMethodConfiguration",
"recommendedBy": []
},
{
"name": "standards.PerUserMFA",
"cat": "Entra (AAD) Standards",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,11 +1,60 @@
import { Layout as DashboardLayout } from "/src/layouts/index.js";
import { CippTablePage } from "/src/components/CippComponents/CippTablePage.jsx";
import { EyeIcon, TrashIcon } from "@heroicons/react/24/outline";
import { TrashIcon } from "@heroicons/react/24/outline";
import { GitHub } from "@mui/icons-material";
import { ApiGetCall } from "/src/api/ApiCall";

const Page = () => {
const pageTitle = "Connection filter Templates";

const integrations = ApiGetCall({
url: "/api/ListExtensionsConfig",
queryKey: "Integrations",
});
const actions = [
{
label: "Save to GitHub",
type: "POST",
url: "/api/ExecCommunityRepo",
icon: <GitHub />,
data: {
Action: "UploadTemplate",
GUID: "GUID",
},
fields: [
{
label: "Repository",
name: "FullName",
type: "select",
api: {
url: "/api/ListCommunityRepos",
data: {
WriteAccess: true,
},
queryKey: "CommunityRepos-Write",
dataKey: "Results",
valueField: "FullName",
labelField: "FullName",
},
multiple: false,
creatable: false,
required: true,
validators: {
required: { value: true, message: "This field is required" },
},
},
{
label: "Commit Message",
placeholder: "Enter a commit message for adding this file to GitHub",
name: "Message",
type: "textField",
multiline: true,
required: true,
rows: 4,
},
],
confirmText: "Are you sure you want to save this template to the selected repository?",
condition: () => integrations.isSuccess && integrations?.data?.GitHub.Enabled,
},
{
label: "Delete Template",
type: "POST",
Expand Down
4 changes: 2 additions & 2 deletions src/pages/email/spamfilter/list-connectionfilter/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,14 +9,14 @@ const Page = () => {

const actions = [
{
label: "Create template based on rule",
label: "Create template based on filter",
type: "POST",
url: "/api/AddConnectionfilterTemplate",
dataFunction: (data) => {
return { ...data };
},
icon: <Book />,
confirmText: "Are you sure you want to create a template based on this rule?",
confirmText: "Are you sure you want to create a template based on this filter?",
},
];

Expand Down
53 changes: 51 additions & 2 deletions src/pages/email/spamfilter/list-templates/index.js
Original file line number Diff line number Diff line change
@@ -1,11 +1,60 @@
import { Layout as DashboardLayout } from "/src/layouts/index.js";
import { CippTablePage } from "/src/components/CippComponents/CippTablePage.jsx";
import { EyeIcon, TrashIcon } from "@heroicons/react/24/outline";
import { TrashIcon } from "@heroicons/react/24/outline";
import { GitHub } from "@mui/icons-material";
import { ApiGetCall } from "/src/api/ApiCall";

const Page = () => {
const pageTitle = "Spamfilter Templates";

const integrations = ApiGetCall({
url: "/api/ListExtensionsConfig",
queryKey: "Integrations",
});
const actions = [
{
label: "Save to GitHub",
type: "POST",
url: "/api/ExecCommunityRepo",
icon: <GitHub />,
data: {
Action: "UploadTemplate",
GUID: "GUID",
},
fields: [
{
label: "Repository",
name: "FullName",
type: "select",
api: {
url: "/api/ListCommunityRepos",
data: {
WriteAccess: true,
},
queryKey: "CommunityRepos-Write",
dataKey: "Results",
valueField: "FullName",
labelField: "FullName",
},
multiple: false,
creatable: false,
required: true,
validators: {
required: { value: true, message: "This field is required" },
},
},
{
label: "Commit Message",
placeholder: "Enter a commit message for adding this file to GitHub",
name: "Message",
type: "textField",
multiline: true,
required: true,
rows: 4,
},
],
confirmText: "Are you sure you want to save this template to the selected repository?",
condition: () => integrations.isSuccess && integrations?.data?.GitHub.Enabled,
},
{
label: "Delete Template",
type: "POST",
Expand Down
53 changes: 51 additions & 2 deletions src/pages/email/transport/list-connector-templates/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,62 @@ import { Button } from "@mui/material";
import Link from "next/link";
import { RocketLaunch } from "@mui/icons-material";
import { CippTablePage } from "/src/components/CippComponents/CippTablePage.jsx";
import { EyeIcon, TrashIcon } from "@heroicons/react/24/outline";
import { TrashIcon } from "@heroicons/react/24/outline";
import { GitHub } from "@mui/icons-material";
import ConnectorTemplateDetails from "../../../../components/CippComponents/ConnectorTemplateDetails";
import { ApiGetCall } from "/src/api/ApiCall";

const Page = () => {
const pageTitle = "Exchange Connector Templates";

const integrations = ApiGetCall({
url: "/api/ListExtensionsConfig",
queryKey: "Integrations",
});
const actions = [
{
label: "Save to GitHub",
type: "POST",
url: "/api/ExecCommunityRepo",
icon: <GitHub />,
data: {
Action: "UploadTemplate",
GUID: "GUID",
},
fields: [
{
label: "Repository",
name: "FullName",
type: "select",
api: {
url: "/api/ListCommunityRepos",
data: {
WriteAccess: true,
},
queryKey: "CommunityRepos-Write",
dataKey: "Results",
valueField: "FullName",
labelField: "FullName",
},
multiple: false,
creatable: false,
required: true,
validators: {
required: { value: true, message: "This field is required" },
},
},
{
label: "Commit Message",
placeholder: "Enter a commit message for adding this file to GitHub",
name: "Message",
type: "textField",
multiline: true,
required: true,
rows: 4,
},
],
confirmText: "Are you sure you want to save this template to the selected repository?",
condition: () => integrations.isSuccess && integrations?.data?.GitHub.Enabled,
},
{
label: "Delete Template",
type: "POST",
Expand Down
54 changes: 51 additions & 3 deletions src/pages/email/transport/list-templates/index.js
Original file line number Diff line number Diff line change
@@ -1,14 +1,62 @@
import { Layout as DashboardLayout } from "/src/layouts/index.js";
import { CippTablePage } from "/src/components/CippComponents/CippTablePage.jsx";
import { EyeIcon, TrashIcon } from "@heroicons/react/24/outline";
import { TrashIcon } from "@heroicons/react/24/outline";
import { Button } from "@mui/material";
import { RocketLaunch } from "@mui/icons-material";
import { RocketLaunch, GitHub } from "@mui/icons-material";
import Link from "next/link";
import { ApiGetCall } from "/src/api/ApiCall";

const Page = () => {
const pageTitle = "Transport Rule Templates";

const integrations = ApiGetCall({
url: "/api/ListExtensionsConfig",
queryKey: "Integrations",
});
const actions = [
{
label: "Save to GitHub",
type: "POST",
url: "/api/ExecCommunityRepo",
icon: <GitHub />,
data: {
Action: "UploadTemplate",
GUID: "GUID",
},
fields: [
{
label: "Repository",
name: "FullName",
type: "select",
api: {
url: "/api/ListCommunityRepos",
data: {
WriteAccess: true,
},
queryKey: "CommunityRepos-Write",
dataKey: "Results",
valueField: "FullName",
labelField: "FullName",
},
multiple: false,
creatable: false,
required: true,
validators: {
required: { value: true, message: "This field is required" },
},
},
{
label: "Commit Message",
placeholder: "Enter a commit message for adding this file to GitHub",
name: "Message",
type: "textField",
multiline: true,
required: true,
rows: 4,
},
],
confirmText: "Are you sure you want to save this template to the selected repository?",
condition: () => integrations.isSuccess && integrations?.data?.GitHub.Enabled,
},
{
label: "Delete Template",
type: "POST",
Expand Down
Loading

0 comments on commit 2cd6e01

Please sign in to comment.