Skip to content

Commit

Permalink
moved boxes over card.
Browse files Browse the repository at this point in the history
  • Loading branch information
KelvinTegelaar committed May 10, 2024
1 parent 4cb9fef commit d214ad3
Showing 1 changed file with 60 additions and 63 deletions.
123 changes: 60 additions & 63 deletions src/views/tenant/standards/ListAppliedStandards.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -368,6 +368,66 @@ const ApplyNewStandard = () => {
{getResults.error.message}
</CippCallout>
)}
<CRow>
<CCol md={4}>
<CWidgetStatsB
className="mb-3"
progress={{
color: 'info',
value:
totalAvailableStandards > 0
? Math.round((enabledWarningsCount / totalAvailableStandards) * 1000) / 10
: 0,
}}
text={
listStandardResults.length > 0 && listStandardResults[0].appliedBy
? `Created by ${listStandardResults[0].appliedBy}`
: 'None'
}
title={`${enabledWarningsCount} out of ${totalAvailableStandards}`}
value="Enabled Warnings"
/>
</CCol>
<CCol md={4}>
<CWidgetStatsB
className="mb-3"
progress={{
color: 'info',
value:
totalAvailableStandards > 0
? Math.round((enabledAlertsCount / totalAvailableStandards) * 1000) / 10
: 0,
}}
text={
listStandardResults.length > 0 && listStandardResults[0].appliedBy
? `Created by ${listStandardResults[0].appliedBy}`
: 'None'
}
title={`${enabledAlertsCount} out of ${totalAvailableStandards}`}
value="Enabled Alerts"
/>
</CCol>
<CCol md={4}>
<CWidgetStatsB
className="mb-3"
progress={{
color: 'info',
value:
totalAvailableStandards > 0
? Math.round((enabledRemediationsCount / totalAvailableStandards) * 1000) /
10
: 0,
}}
text={
listStandardResults.length > 0 && listStandardResults[0].appliedBy
? `Created by ${listStandardResults[0].appliedBy}`
: 'None'
}
title={`${enabledRemediationsCount} out of ${totalAvailableStandards}`}
value="Enabled Remediations"
/>
</CCol>
</CRow>
<CippContentCard
button={
<>
Expand Down Expand Up @@ -400,69 +460,6 @@ const ApplyNewStandard = () => {
return (
<CForm onSubmit={handleSubmit}>
<CRow className="mb-3">
<CCol md={4}>
<CWidgetStatsB
className="mb-3"
progress={{
color: 'info',
value:
totalAvailableStandards > 0
? Math.round(
(enabledWarningsCount / totalAvailableStandards) * 1000,
) / 10
: 0,
}}
text={
listStandardResults[0].appliedBy
? `Created by ${listStandardResults[0].appliedBy}`
: 'None'
}
title={`${enabledWarningsCount} out of ${totalAvailableStandards}`}
value="Enabled Warnings"
/>
</CCol>
<CCol md={4}>
<CWidgetStatsB
className="mb-3"
progress={{
color: 'info',
value:
totalAvailableStandards > 0
? Math.round(
(enabledAlertsCount / totalAvailableStandards) * 1000,
) / 10
: 0,
}}
text={
listStandardResults[0].appliedBy
? `Created by ${listStandardResults[0].appliedBy}`
: 'None'
}
title={`${enabledAlertsCount} out of ${totalAvailableStandards}`}
value="Enabled Alerts"
/>
</CCol>
<CCol md={4}>
<CWidgetStatsB
className="mb-3"
progress={{
color: 'info',
value:
totalAvailableStandards > 0
? Math.round(
(enabledRemediationsCount / totalAvailableStandards) * 1000,
) / 10
: 0,
}}
text={
listStandardResults[0].appliedBy
? `Created by ${listStandardResults[0].appliedBy}`
: 'None'
}
title={`${enabledRemediationsCount} out of ${totalAvailableStandards}`}
value="Enabled Remediations"
/>
</CCol>
<CAccordion
alwaysOpen
activeItemKey={
Expand Down

0 comments on commit d214ad3

Please sign in to comment.