@@ -328,10 +328,6 @@ const ManageDriftPage = () => {
328
328
status = "Accepted" ;
329
329
actionText = "accept" ;
330
330
break ;
331
- case "deny-remove" :
332
- status = "Denied" ;
333
- actionText = "deny and remove" ;
334
- break ;
335
331
case "deny-delete" :
336
332
status = "DeniedDelete" ;
337
333
actionText = "deny and delete" ;
@@ -554,7 +550,8 @@ const ManageDriftPage = () => {
554
550
const deviationItemsWithActions = deviationItems . map ( ( item ) => {
555
551
// Check if this is a template that supports delete action
556
552
const supportsDelete =
557
- item . standardName === "ConditionalAccessTemplate" || item . standardName === "IntuneTemplate" ;
553
+ item . standardName ?. includes ( "ConditionalAccessTemplate" ) ||
554
+ item . standardName ?. includes ( "IntuneTemplate" ) ;
558
555
559
556
return {
560
557
...item ,
@@ -584,7 +581,7 @@ const ManageDriftPage = () => {
584
581
{ supportsDelete && (
585
582
< MenuItem onClick = { ( ) => handleAction ( "deny-delete" , item . id ) } >
586
583
< Block sx = { { mr : 1 , color : "error.main" } } />
587
- Deny Deviation - Delete
584
+ Deny Deviation - Delete Policy
588
585
</ MenuItem >
589
586
) }
590
587
< MenuItem onClick = { ( ) => handleAction ( "deny-remediate" , item . id ) } >
@@ -601,7 +598,8 @@ const ManageDriftPage = () => {
601
598
const acceptedDeviationItemsWithActions = acceptedDeviationItems . map ( ( item ) => {
602
599
// Check if this is a template that supports delete action
603
600
const supportsDelete =
604
- item . standardName === "ConditionalAccessTemplate" || item . standardName === "IntuneTemplate" ;
601
+ item . standardName ?. includes ( "ConditionalAccessTemplate" ) ||
602
+ item . standardName ?. includes ( "IntuneTemplate" ) ;
605
603
606
604
return {
607
605
...item ,
@@ -623,7 +621,7 @@ const ManageDriftPage = () => {
623
621
{ supportsDelete && (
624
622
< MenuItem onClick = { ( ) => handleDeviationAction ( "deny-delete" , item ) } >
625
623
< Block sx = { { mr : 1 , color : "error.main" } } />
626
- Deny - Delete
624
+ Deny - Delete Policy
627
625
</ MenuItem >
628
626
) }
629
627
< MenuItem onClick = { ( ) => handleDeviationAction ( "deny-remediate" , item ) } >
@@ -644,7 +642,8 @@ const ManageDriftPage = () => {
644
642
const customerSpecificDeviationItemsWithActions = customerSpecificDeviationItems . map ( ( item ) => {
645
643
// Check if this is a template that supports delete action
646
644
const supportsDelete =
647
- item . standardName === "ConditionalAccessTemplate" || item . standardName === "IntuneTemplate" ;
645
+ item . standardName ?. includes ( "ConditionalAccessTemplate" ) ||
646
+ item . standardName ?. includes ( "IntuneTemplate" ) ;
648
647
649
648
return {
650
649
...item ,
@@ -861,8 +860,8 @@ const ManageDriftPage = () => {
861
860
{ /* Only show delete option if there are template deviations that support deletion */ }
862
861
{ processedDriftData . currentDeviations . some (
863
862
( deviation ) =>
864
- deviation . standardName === "ConditionalAccessTemplate" ||
865
- deviation . standardName === "IntuneTemplate"
863
+ deviation . standardName ?. includes ( "ConditionalAccessTemplate" ) ||
864
+ deviation . standardName ?. includes ( "IntuneTemplate" )
866
865
) && (
867
866
< MenuItem onClick = { ( ) => handleBulkAction ( "deny-all-delete" ) } >
868
867
< Block sx = { { mr : 1 , color : "error.main" } } />
@@ -878,22 +877,6 @@ const ManageDriftPage = () => {
878
877
Remove Drift Customization
879
878
</ MenuItem >
880
879
</ Menu >
881
-
882
- < Menu
883
- anchorEl = { whatIfAnchorEl }
884
- open = { Boolean ( whatIfAnchorEl ) }
885
- onClose = { ( ) => setWhatIfAnchorEl ( null ) }
886
- >
887
- { availableStandards . map ( ( standard ) => (
888
- < MenuItem
889
- key = { standard . id }
890
- onClick = { ( ) => handleWhatIfAction ( standard . id ) }
891
- >
892
- < Science sx = { { mr : 1 , color : "primary.main" } } />
893
- { standard . name }
894
- </ MenuItem >
895
- ) ) }
896
- </ Menu >
897
880
</ Box >
898
881
</ Box >
899
882
< CippBannerListCard
0 commit comments