@@ -95,6 +95,7 @@ const getNestedValue = (obj, path) => {
95
95
} , obj )
96
96
}
97
97
const BestPracticeAnalyser = ( ) => {
98
+ const [ reportTemplate , setReportTemplate ] = useState ( 'CIPP Best Practices v1.0 - Table view' )
98
99
const { data : templates = [ ] , isLoading : templatesfetch } = useGenericGetRequestQuery ( {
99
100
path : 'api/listBPATemplates' ,
100
101
} )
@@ -106,9 +107,10 @@ const BestPracticeAnalyser = () => {
106
107
const [ visibleA , setVisibleA ] = useState ( true )
107
108
const handleSubmit = async ( values ) => {
108
109
setVisibleA ( false )
110
+ setReportTemplate ( values . reportTemplate )
109
111
const shippedValues = {
110
112
SearchNow : true ,
111
- Report : values . reportTemplate ,
113
+ Report : reportTemplate ,
112
114
tenantFilter : tenant . customerId ,
113
115
random : ( Math . random ( ) + 1 ) . toString ( 36 ) . substring ( 7 ) ,
114
116
}
@@ -180,7 +182,7 @@ const BestPracticeAnalyser = () => {
180
182
path : 'api/listBPA' ,
181
183
params : {
182
184
tenantFilter : tenant . customerId ,
183
- Report : Report ,
185
+ Report : reportTemplate ,
184
186
SearchNow : SearchNow ,
185
187
} ,
186
188
} )
@@ -272,7 +274,7 @@ const BestPracticeAnalyser = () => {
272
274
< >
273
275
< CRow >
274
276
{ graphrequest . data . Columns . map ( ( info , idx ) => (
275
- < CCol sm = { 10 } md = { 4 } className = "mb-3" >
277
+ < CCol md = { 12 } xl = { 4 } className = "mb-3" >
276
278
< CCard className = "h-100" >
277
279
< CCardHeader >
278
280
< CCardTitle > { info . name } </ CCardTitle >
0 commit comments