Skip to content

Commit

Permalink
feat(admin-ui): little refactoring on licence details page #399
Browse files Browse the repository at this point in the history
  • Loading branch information
syntrydy committed Aug 30, 2022
1 parent a8a40e1 commit 45bc00e
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 5 deletions.
4 changes: 4 additions & 0 deletions admin-ui/app/routes/Apps/Gluu/styles/applicationstyle.js
Original file line number Diff line number Diff line change
Expand Up @@ -34,4 +34,8 @@ export default {
borderRadius: 24,
padding: 12,
},
licensePanel: {
backgroundColor: '#F5F5F5',
float: 'left',
},
}
10 changes: 5 additions & 5 deletions admin-ui/app/routes/License/LicenseDetailsPage.js
Original file line number Diff line number Diff line change
Expand Up @@ -24,21 +24,21 @@ function LicenseDetailsPage({ item, loading, dispatch }) {
}, [])

function formatDate(date) {
if (date == undefined) {
return ''
if (!date) {
return '-'
}
if (date.length > 10) {
return date.substring(0, 10)
}
return ''
return '-'
}
SetTitle(t('fields.licenseDetails'))
return (
<GluuLoader blocking={loading}>
<Card className="mb-3" style={applicationStyle.mainCard}>
<CardBody>
{item.licenseEnabled ? (
<Container style={{ backgroundColor: '#F5F5F5', float: 'left' }}>
<Container style={applicationStyle.licensePanel}>
<Row>
<Col sm={6}>
<GluuFormDetailRow
Expand Down Expand Up @@ -102,7 +102,7 @@ function LicenseDetailsPage({ item, loading, dispatch }) {
<Col sm={6}>
<GluuFormDetailRow
label="fields.customerName"
value={item.customerFirstName + ' ' + item.customerLastName}
value={`${item.customerFirstName} ${item.customerLastName}`}
isBadge={true}
lsize={3}
rsize={9}
Expand Down

0 comments on commit 45bc00e

Please sign in to comment.