@@ -2,7 +2,13 @@ import React, { useState } from 'react'
2
2
import { CButton , CCallout , CCol , CForm , CRow , CSpinner , CTooltip } from '@coreui/react'
3
3
import { useSelector } from 'react-redux'
4
4
import { Field , Form } from 'react-final-form'
5
- import { Condition , RFFCFormInput , RFFCFormRadioList , RFFSelectSearch } from 'src/components/forms'
5
+ import {
6
+ Condition ,
7
+ RFFCFormInput ,
8
+ RFFCFormRadioList ,
9
+ RFFCFormSwitch ,
10
+ RFFSelectSearch ,
11
+ } from 'src/components/forms'
6
12
import { useLazyGenericGetRequestQuery , useLazyGenericPostRequestQuery } from 'src/store/api/app'
7
13
import { FontAwesomeIcon } from '@fortawesome/react-fontawesome'
8
14
import { faCircleNotch , faEdit , faEye } from '@fortawesome/free-solid-svg-icons'
@@ -33,11 +39,19 @@ const DeployJITAdmin = () => {
33
39
const shippedValues = {
34
40
TenantFilter : tenantDomain ,
35
41
UserId : values . UserId ?. value ,
42
+ UserPrincipalName : values . UserPrincipalName ,
43
+ FirstName : values . FirstName ,
44
+ LastName : values . LastName ,
36
45
useraction : values . useraction ,
37
46
AdminRoles : values . AdminRoles ?. map ( ( role ) => role . value ) ,
38
47
StartDate : startTime ,
39
48
EndDate : endTime ,
40
49
ExpireAction : values . expireAction . value ,
50
+ PostExecution : {
51
+ Webhook : values . webhook ,
52
+ Email : values . email ,
53
+ PSA : values . psa ,
54
+ } ,
41
55
}
42
56
genericPostRequest ( { path : '/api/ExecJITAdmin' , values : shippedValues } ) . then ( ( res ) => {
43
57
setRefreshState ( res . requestId )
@@ -181,6 +195,14 @@ const DeployJITAdmin = () => {
181
195
/>
182
196
</ CCol >
183
197
</ CRow >
198
+ < CRow className = "mb-3" >
199
+ < CCol >
200
+ < label > Send results to</ label >
201
+ < RFFCFormSwitch name = "webhook" label = "Webhook" />
202
+ < RFFCFormSwitch name = "email" label = "E-mail" />
203
+ < RFFCFormSwitch name = "psa" label = "PSA" />
204
+ </ CCol >
205
+ </ CRow >
184
206
< CRow className = "mb-3" >
185
207
< CCol md = { 6 } >
186
208
< CButton type = "submit" disabled = { submitting } >
@@ -227,7 +249,7 @@ const DeployJITAdmin = () => {
227
249
< CippDatatable
228
250
title = "JIT Admins"
229
251
path = "/api/ExecJITAdmin?Action=List"
230
- params = { { TenantFilter : tenantDomain } }
252
+ params = { { TenantFilter : tenantDomain , refreshState } }
231
253
columns = { [
232
254
{
233
255
name : 'User' ,
0 commit comments