Improving compliance stuff (#2963)
* Improving compliance stuff * Fixing padding on mobile
Этот коммит содержится в:
коммит произвёл
Christopher Speller
родитель
7babccfa51
Коммит
04f7273461
@@ -75,24 +75,25 @@ export default class Audits extends React.Component {
|
|||||||
<div>
|
<div>
|
||||||
<ComplianceReports/>
|
<ComplianceReports/>
|
||||||
|
|
||||||
<div className='panel'>
|
<div className='panel audit-panel'>
|
||||||
<h3>
|
<h3>
|
||||||
<FormattedMessage
|
<FormattedMessage
|
||||||
id='admin.audits.title'
|
id='admin.audits.title'
|
||||||
defaultMessage='User Activity'
|
defaultMessage='User Activity Logs'
|
||||||
/>
|
/>
|
||||||
|
<button
|
||||||
|
type='submit'
|
||||||
|
className='btn btn-link pull-right'
|
||||||
|
onClick={this.reload}
|
||||||
|
>
|
||||||
|
<i className='fa fa-refresh'></i>
|
||||||
|
<FormattedMessage
|
||||||
|
id='admin.audits.reload'
|
||||||
|
defaultMessage='Reload User Activity Logs'
|
||||||
|
/>
|
||||||
|
</button>
|
||||||
</h3>
|
</h3>
|
||||||
<button
|
<div className='audit-panel__table'>
|
||||||
type='submit'
|
|
||||||
className='btn btn-primary'
|
|
||||||
onClick={this.reload}
|
|
||||||
>
|
|
||||||
<FormattedMessage
|
|
||||||
id='admin.audits.reload'
|
|
||||||
defaultMessage='Reload'
|
|
||||||
/>
|
|
||||||
</button>
|
|
||||||
<div className='audit__panel'>
|
|
||||||
{content}
|
{content}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -266,7 +266,7 @@ export default class ComplianceReports extends React.Component {
|
|||||||
}
|
}
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div className='panel'>
|
<div className='panel compliance-panel'>
|
||||||
<h3>
|
<h3>
|
||||||
<FormattedMessage
|
<FormattedMessage
|
||||||
id='admin.compliance_reports.title'
|
id='admin.compliance_reports.title'
|
||||||
@@ -274,112 +274,113 @@ export default class ComplianceReports extends React.Component {
|
|||||||
/>
|
/>
|
||||||
</h3>
|
</h3>
|
||||||
|
|
||||||
<table>
|
<div className='row'>
|
||||||
<tbody>
|
<div className='col-sm-6 col-md-4 form-group'>
|
||||||
<tr>
|
<label>
|
||||||
<td colSpan='5'
|
<FormattedMessage
|
||||||
style={{paddingBottom: '6px'}}
|
id='admin.compliance_reports.desc'
|
||||||
>
|
defaultMessage='Job Name:'
|
||||||
<FormattedMessage
|
/>
|
||||||
id='admin.compliance_reports.desc'
|
</label>
|
||||||
defaultMessage='Job Name:'
|
<input
|
||||||
/>
|
type='text'
|
||||||
<input
|
className='form-control'
|
||||||
style={{width: '425px'}}
|
id='desc'
|
||||||
type='text'
|
ref='desc'
|
||||||
className='form-control'
|
placeholder={Utils.localizeMessage('admin.compliance_reports.desc_placeholder', 'E.g. "Audit 445 for HR"')}
|
||||||
id='desc'
|
/>
|
||||||
ref='desc'
|
</div>
|
||||||
placeholder={Utils.localizeMessage('admin.compliance_reports.desc_placeholder', 'Ex "Audit 445 for HR"')}
|
<div className='col-sm-3 col-md-2 form-group'>
|
||||||
/>
|
<label>
|
||||||
</td>
|
<FormattedMessage
|
||||||
</tr>
|
id='admin.compliance_reports.from'
|
||||||
<tr>
|
defaultMessage='From:'
|
||||||
<td>
|
/>
|
||||||
<FormattedMessage
|
</label>
|
||||||
id='admin.compliance_reports.from'
|
<input
|
||||||
defaultMessage='From:'
|
type='text'
|
||||||
/>
|
className='form-control'
|
||||||
<input
|
id='from'
|
||||||
type='text'
|
ref='from'
|
||||||
className='form-control'
|
placeholder={Utils.localizeMessage('admin.compliance_reports.from_placeholder', 'E.g. "2016-03-11"')}
|
||||||
id='from'
|
/>
|
||||||
ref='from'
|
</div>
|
||||||
placeholder={Utils.localizeMessage('admin.compliance_reports.from_placeholder', 'Ex "2016-03-11"')}
|
<div className='col-sm-3 col-md-2 form-group'>
|
||||||
/>
|
<label>
|
||||||
</td>
|
<FormattedMessage
|
||||||
<td style={{paddingLeft: '4px'}}>
|
id='admin.compliance_reports.to'
|
||||||
<FormattedMessage
|
defaultMessage='To:'
|
||||||
id='admin.compliance_reports.to'
|
/>
|
||||||
defaultMessage='To:'
|
</label>
|
||||||
/>
|
<input
|
||||||
<input
|
type='text'
|
||||||
type='text'
|
className='form-control'
|
||||||
className='form-control'
|
id='to'
|
||||||
id='to'
|
ref='to'
|
||||||
ref='to'
|
placeholder={Utils.localizeMessage('admin.compliance_reports.to_placeholder', 'E.g. "2016-03-15"')}
|
||||||
placeholder={Utils.localizeMessage('admin.compliance_reports.to_placeholder', 'Ex "2016-03-15"')}
|
/>
|
||||||
/>
|
</div>
|
||||||
</td>
|
</div>
|
||||||
<td style={{paddingLeft: '4px'}}>
|
<div className='row'>
|
||||||
<FormattedMessage
|
<div className='col-sm-6 col-md-4 form-group'>
|
||||||
id='admin.compliance_reports.emails'
|
<label>
|
||||||
defaultMessage='Emails:'
|
<FormattedMessage
|
||||||
/>
|
id='admin.compliance_reports.emails'
|
||||||
<input
|
defaultMessage='Emails:'
|
||||||
style={{width: '325px'}}
|
/>
|
||||||
type='text'
|
</label>
|
||||||
className='form-control'
|
<input
|
||||||
id='emails'
|
type='text'
|
||||||
ref='emails'
|
className='form-control'
|
||||||
placeholder={Utils.localizeMessage('admin.compliance_reports.emails_placeholder', 'Ex "bill@example.com, bob@example.com"')}
|
id='emails'
|
||||||
/>
|
ref='emails'
|
||||||
</td>
|
placeholder={Utils.localizeMessage('admin.compliance_reports.emails_placeholder', 'E.g. "bill@example.com, bob@example.com"')}
|
||||||
<td style={{paddingLeft: '4px'}}>
|
/>
|
||||||
<FormattedMessage
|
</div>
|
||||||
id='admin.compliance_reports.keywords'
|
<div className='col-sm-6 col-md-4 form-group'>
|
||||||
defaultMessage='Keywords:'
|
<label>
|
||||||
/>
|
<FormattedMessage
|
||||||
<input
|
id='admin.compliance_reports.keywords'
|
||||||
style={{width: '250px'}}
|
defaultMessage='Keywords:'
|
||||||
type='text'
|
/>
|
||||||
className='form-control'
|
</label>
|
||||||
id='keywords'
|
<input
|
||||||
ref='keywords'
|
type='text'
|
||||||
placeholder={Utils.localizeMessage('admin.compliance_reports.keywords_placeholder', 'Ex "shorting stock"')}
|
className='form-control'
|
||||||
/>
|
id='keywords'
|
||||||
</td>
|
ref='keywords'
|
||||||
<td>
|
placeholder={Utils.localizeMessage('admin.compliance_reports.keywords_placeholder', 'E.g. "shorting stock"')}
|
||||||
<button
|
/>
|
||||||
id='run-button'
|
</div>
|
||||||
type='submit'
|
</div>
|
||||||
className='btn btn-primary'
|
<div className='clearfix'>
|
||||||
onClick={this.runReport}
|
|
||||||
style={{marginTop: '20px', marginLeft: '20px'}}
|
|
||||||
>
|
|
||||||
<FormattedMessage
|
|
||||||
id='admin.compliance_reports.run'
|
|
||||||
defaultMessage='Run'
|
|
||||||
/>
|
|
||||||
</button>
|
|
||||||
</td>
|
|
||||||
</tr>
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
{serverError}
|
|
||||||
<div style={{marginTop: '20px'}}>
|
|
||||||
<button
|
<button
|
||||||
|
id='run-button'
|
||||||
type='submit'
|
type='submit'
|
||||||
className='btn btn-primary'
|
className='btn btn-primary'
|
||||||
onClick={this.reload}
|
onClick={this.runReport}
|
||||||
>
|
>
|
||||||
<FormattedMessage
|
<FormattedMessage
|
||||||
id='admin.compliance_reports.reload'
|
id='admin.compliance_reports.run'
|
||||||
defaultMessage='Reload'
|
defaultMessage='Run Compliance Report'
|
||||||
/>
|
/>
|
||||||
</button>
|
</button>
|
||||||
</div>
|
</div>
|
||||||
<div className='compliance__panel'>
|
{serverError}
|
||||||
|
<div className='text-right'>
|
||||||
|
<button
|
||||||
|
type='submit'
|
||||||
|
className='btn btn-link'
|
||||||
|
onClick={this.reload}
|
||||||
|
>
|
||||||
|
<i className='fa fa-refresh'></i>
|
||||||
|
<FormattedMessage
|
||||||
|
id='admin.compliance_reports.reload'
|
||||||
|
defaultMessage='Reload Completed Compliance Reports'
|
||||||
|
/>
|
||||||
|
</button>
|
||||||
|
</div>
|
||||||
|
<div className='compliance-panel__table'>
|
||||||
{content}
|
{content}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -75,8 +75,8 @@
|
|||||||
"add_outgoing_webhook.triggerWOrds": "Trigger Words (One Per Line)",
|
"add_outgoing_webhook.triggerWOrds": "Trigger Words (One Per Line)",
|
||||||
"add_outgoing_webhook.triggerWords": "Trigger Words (One Per Line)",
|
"add_outgoing_webhook.triggerWords": "Trigger Words (One Per Line)",
|
||||||
"add_outgoing_webhook.triggerWordsOrChannelRequired": "A valid channel or a list of trigger words is required",
|
"add_outgoing_webhook.triggerWordsOrChannelRequired": "A valid channel or a list of trigger words is required",
|
||||||
"admin.audits.reload": "Reload",
|
"admin.audits.reload": "Reload User Activity Logs",
|
||||||
"admin.audits.title": "User Activity",
|
"admin.audits.title": "User Activity Logs",
|
||||||
"admin.compliance.directoryDescription": "Directory to which compliance reports are written. If blank, will be set to ./data/.",
|
"admin.compliance.directoryDescription": "Directory to which compliance reports are written. If blank, will be set to ./data/.",
|
||||||
"admin.compliance.directoryExample": "Ex \"./data/\"",
|
"admin.compliance.directoryExample": "Ex \"./data/\"",
|
||||||
"admin.compliance.directoryTitle": "Compliance Directory Location:",
|
"admin.compliance.directoryTitle": "Compliance Directory Location:",
|
||||||
@@ -91,18 +91,18 @@
|
|||||||
"admin.compliance.title": "Compliance Settings",
|
"admin.compliance.title": "Compliance Settings",
|
||||||
"admin.compliance.true": "true",
|
"admin.compliance.true": "true",
|
||||||
"admin.compliance_reports.desc": "Job Name:",
|
"admin.compliance_reports.desc": "Job Name:",
|
||||||
"admin.compliance_reports.desc_placeholder": "Ex \"Audit 445 for HR\"",
|
"admin.compliance_reports.desc_placeholder": "E.g. \"Audit 445 for HR\"",
|
||||||
"admin.compliance_reports.emails": "Emails:",
|
"admin.compliance_reports.emails": "Emails:",
|
||||||
"admin.compliance_reports.emails_placeholder": "Ex \"bill@example.com, bob@example.com\"",
|
"admin.compliance_reports.emails_placeholder": "E.g. \"bill@example.com, bob@example.com\"",
|
||||||
"admin.compliance_reports.from": "From:",
|
"admin.compliance_reports.from": "From:",
|
||||||
"admin.compliance_reports.from_placeholder": "Ex \"2016-03-11\"",
|
"admin.compliance_reports.from_placeholder": "E.g. \"2016-03-11\"",
|
||||||
"admin.compliance_reports.keywords": "Keywords:",
|
"admin.compliance_reports.keywords": "Keywords:",
|
||||||
"admin.compliance_reports.keywords_placeholder": "Ex \"shorting stock\"",
|
"admin.compliance_reports.keywords_placeholder": "E.g. \"shorting stock\"",
|
||||||
"admin.compliance_reports.reload": "Reload",
|
"admin.compliance_reports.reload": "Reload Completed Compliance Reports",
|
||||||
"admin.compliance_reports.run": "Run",
|
"admin.compliance_reports.run": "Run Compliance Report",
|
||||||
"admin.compliance_reports.title": "Compliance Reports",
|
"admin.compliance_reports.title": "Compliance Reports",
|
||||||
"admin.compliance_reports.to": "To:",
|
"admin.compliance_reports.to": "To:",
|
||||||
"admin.compliance_reports.to_placeholder": "Ex \"2016-03-15\"",
|
"admin.compliance_reports.to_placeholder": "E.g. \"2016-03-15\"",
|
||||||
"admin.compliance_table.desc": "Description",
|
"admin.compliance_table.desc": "Description",
|
||||||
"admin.compliance_table.download": "Download",
|
"admin.compliance_table.download": "Download",
|
||||||
"admin.compliance_table.params": "Params",
|
"admin.compliance_table.params": "Params",
|
||||||
|
|||||||
@@ -11,6 +11,15 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.compliance-panel,
|
||||||
|
.audit-panel {
|
||||||
|
.row {
|
||||||
|
> .form-group {
|
||||||
|
padding-left: 15px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
.user-popover {
|
.user-popover {
|
||||||
pointer-events: none;
|
pointer-events: none;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -160,17 +160,6 @@
|
|||||||
width: 100%;
|
width: 100%;
|
||||||
}
|
}
|
||||||
|
|
||||||
.compliance__panel,
|
|
||||||
.audit__panel {
|
|
||||||
background-color: $white;
|
|
||||||
border: 1px solid $border-gray;
|
|
||||||
height: 70vh;
|
|
||||||
margin-top: 10px;
|
|
||||||
overflow: auto;
|
|
||||||
padding: 5px;
|
|
||||||
width: 100%;
|
|
||||||
}
|
|
||||||
|
|
||||||
.app__content {
|
.app__content {
|
||||||
color: #333;
|
color: #333;
|
||||||
|
|
||||||
|
|||||||
38
webapp/sass/routes/_compliance.scss
Обычный файл
38
webapp/sass/routes/_compliance.scss
Обычный файл
@@ -0,0 +1,38 @@
|
|||||||
|
@charset 'UTF-8';
|
||||||
|
|
||||||
|
.compliance-panel__table,
|
||||||
|
.audit-panel__table {
|
||||||
|
background-color: $white;
|
||||||
|
border: 1px solid $border-gray;
|
||||||
|
margin-top: 10px;
|
||||||
|
max-height: 70vh;
|
||||||
|
min-height: 100px;
|
||||||
|
overflow: auto;
|
||||||
|
padding: 5px;
|
||||||
|
width: 100%;
|
||||||
|
}
|
||||||
|
|
||||||
|
.compliance-panel,
|
||||||
|
.audit-panel {
|
||||||
|
.row {
|
||||||
|
> .form-group {
|
||||||
|
padding-left: 0;
|
||||||
|
|
||||||
|
&:first-child {
|
||||||
|
padding-left: 15px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
label {
|
||||||
|
font-weight: 600;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.fa-refresh {
|
||||||
|
margin-right: 5px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.compliance-panel {
|
||||||
|
margin-bottom: 3em;
|
||||||
|
}
|
||||||
@@ -4,6 +4,7 @@
|
|||||||
@import 'activity-log';
|
@import 'activity-log';
|
||||||
@import 'admin-console';
|
@import 'admin-console';
|
||||||
@import 'backstage';
|
@import 'backstage';
|
||||||
|
@import 'compliance';
|
||||||
@import 'docs';
|
@import 'docs';
|
||||||
@import 'error-page';
|
@import 'error-page';
|
||||||
@import 'loading';
|
@import 'loading';
|
||||||
|
|||||||
Ссылка в новой задаче
Block a user