Skip to content

Commit 6c4105b

Browse files
committed
merged with dev
2 parents e1842bc + 237ad45 commit 6c4105b

File tree

90 files changed

+13459
-33844
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

90 files changed

+13459
-33844
lines changed

Diff for: client-reactjs/package-lock.json

+12,130-32,771
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Diff for: client-reactjs/package.json

+11-7
Original file line numberDiff line numberDiff line change
@@ -3,29 +3,33 @@
33
"version": "1.0.0",
44
"private": true,
55
"dependencies": {
6-
"@ant-design/charts": "^1.4.2",
6+
"@ant-design/charts": "^2.0.3",
7+
"@ant-design/plots": "2.1.14",
78
"@ant-design/icons": "^4.7.0",
89
"@antv/layout": "^0.1.31",
9-
"@antv/x6": "^1.31.0",
10-
"@antv/x6-react-components": "^1.1.15",
11-
"@antv/x6-react-shape": "^1.6.0",
10+
"@antv/x6": "^2.18.1",
11+
"@antv/x6-plugin-stencil": "^2.1.5",
12+
"@antv/x6-react-components": "^2.0.8",
13+
"@antv/x6-react-shape": "^2.2.3",
1214
"@azure/msal-browser": "^2.21.0",
1315
"@azure/msal-react": "^1.1.0",
1416
"@monaco-editor/react": "^4.4.5",
15-
"antd": "^4.21.3",
17+
"antd": "^5.13.2",
1618
"cronstrue": "^2.14.0",
1719
"d3-color": "^3.1.0",
20+
"dayjs": "^1.11.10",
1821
"downloadjs": "^1.4.7",
1922
"font-awesome": "^4.7.0",
2023
"http-proxy-middleware": "^1.0.6",
2124
"i18next": "^21.9.1",
2225
"i18next-http-backend": "^1.4.1",
2326
"jspdf": "^2.3.1",
2427
"jwt-decode": "^2.2.0",
28+
"moment": "^2.30.1",
2529
"papaparse": "^5.2.0",
2630
"re-resizable": "^6.9.1",
27-
"react": "^16.14.0",
28-
"react-dom": "^16.14.0",
31+
"react": "^18.2.0",
32+
"react-dom": "^18.2.0",
2933
"react-i18next": "^11.18.4",
3034
"react-markdown": "^5.0.3",
3135
"react-redux": "^7.2.2",

Diff for: client-reactjs/src/components/admin/AddRegulations.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -148,11 +148,11 @@ class AddRegulations extends Component {
148148
<div>
149149
<Modal
150150
title={this.state.title}
151-
visible={true}
151+
open={true}
152152
onOk={this.handleOk.bind(this)}
153153
onCancel={this.handleCancel}
154154
destroyOnClose={true}
155-
bodyStyle={{ height: '560px' }}
155+
styles={{ height: '560px' }}
156156
okText="Save">
157157
<Form layout="vertical">
158158
<Form.Item {...formItemLayout} label="Compliance :">

Diff for: client-reactjs/src/components/admin/ClusterDetails.jsx

+3-7
Original file line numberDiff line numberDiff line change
@@ -148,15 +148,15 @@ function ClusterDetails() {
148148
</Form>
149149
{directoryDetails ? (
150150
<div style={{ marginTop: '20px' }}>
151-
<Card title="Basic Details" size="small" headStyle={{ fontWeight: 700 }}>
151+
<Card title="Basic Details" size="small">
152152
<Descriptions column={1} size="small" labelStyle={{ fontWeight: 500 }}>
153153
<Descriptions.Item label="Total Directories">{directoryDetails.directoryCount}</Descriptions.Item>
154154
<Descriptions.Item label="Total Files">{directoryDetails.fileCount}</Descriptions.Item>
155155
</Descriptions>
156156
</Card>
157157

158158
{directoryDetails?.oldestFile ? (
159-
<Card title="Oldest File" size="small" headStyle={{ fontWeight: 700 }} style={{ marginTop: '2px' }}>
159+
<Card title="Oldest File" size="small" style={{ marginTop: '2px' }}>
160160
<Descriptions column={1} size="small">
161161
{Object.keys(directoryDetails.oldestFile).map((key) => (
162162
<Descriptions key={key} label={key}>
@@ -168,11 +168,7 @@ function ClusterDetails() {
168168
) : null}
169169

170170
{directoryDetails?.filesAndDirectories.length > 0 ? (
171-
<Card
172-
title="Files and Directories"
173-
size="small"
174-
headStyle={{ fontWeight: 700 }}
175-
style={{ marginTop: '2px' }}>
171+
<Card title="Files and Directories" size="small" style={{ marginTop: '2px' }}>
176172
{directoryDetails?.filesAndDirectories.map((directory, index) => (
177173
<Collapse
178174
key={index}

Diff for: client-reactjs/src/components/admin/Clusters.jsx

+2-2
Original file line numberDiff line numberDiff line change
@@ -254,7 +254,7 @@ function Clusters() {
254254
/>
255255

256256
<Modal
257-
visible={addClusterModalVisible}
257+
open={addClusterModalVisible}
258258
onCancel={handleCancel}
259259
okText={<Text text="Add" />}
260260
onOk={addCluster}
@@ -322,7 +322,7 @@ function Clusters() {
322322
</Modal>
323323

324324
<Modal
325-
visible={clusterDetailModalVisible}
325+
open={clusterDetailModalVisible}
326326
onCancel={handleCancel}
327327
okText={<Text text="Close" />}
328328
onOk={handleCancel}

Diff for: client-reactjs/src/components/admin/Compliance/Constraints/ConstraintForm.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ const ConstraintForm = ({ modal, onClose }) => {
7575
onOk={handleOk}
7676
onCancel={onClose}
7777
okText={getOKtext()}
78-
visible={modal.isOpen}
78+
open={modal.isOpen}
7979
confirmLoading={sending.loading}>
8080
<Form layout="vertical" form={form}>
8181
<Form.Item

Diff for: client-reactjs/src/components/admin/Compliance/Constraints/ConstraintsTags.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ const TagWithPopUp = ({ record, file, showAll }) => {
6161
width={1000}
6262
footer={null}
6363
closable={false}
64-
visible={visible}
64+
open={visible}
6565
title={record.name}
6666
onCancel={() => setVisible(false)}>
6767
<ConstraintDescription record={record} />

Diff for: client-reactjs/src/components/admin/Compliance/Propagation/Propagation.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ const Propagation = () => {
7272
width={1000}
7373
title={<Text>Would you like to compare against base line?</Text>}
7474
onCancel={() => setModal({ isOpen: false })}
75-
visible={modal.isOpen}
75+
open={modal.isOpen}
7676
footer={[
7777
<Button key="current" type="secondary" onClick={handleUseCurrentState}>
7878
<Text> Use Current State</Text>

Diff for: client-reactjs/src/components/admin/Consumers.js

+3-3
Original file line numberDiff line numberDiff line change
@@ -466,7 +466,7 @@ class Consumers extends Component {
466466
/>
467467
</>
468468
}
469-
visible={this.state.showAddConsumer}
469+
open={this.state.showAddConsumer}
470470
onOk={this.handleAddConsumerOk.bind(this)}
471471
onCancel={this.handleAddConsumerCancel}
472472
confirmLoading={confirmLoading}
@@ -586,8 +586,8 @@ class Consumers extends Component {
586586
<Form.Item label="AD Group">
587587
<AutoComplete
588588
className="certain-category-search"
589-
dropdownClassName="certain-category-search-dropdown"
590-
dropdownMatchSelectWidth={false}
589+
popupClassName="certain-category-search-dropdown"
590+
popupMatchSelectWidth={false}
591591
dropdownStyle={{ width: 300 }}
592592
size="large"
593593
style={{ width: '100%' }}

Diff for: client-reactjs/src/components/admin/Integrations/IntegrationSettings.jsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ function IntegrationSettings() {
3333
(i) => i.name === integrationName && i.application_id === applicationId
3434
).integration_to_app_mapping_id;
3535

36-
const IntegrationComponent = require(`./${integrationName}`).default;
36+
const IntegrationComponent = require(`./${integrationName.toLowerCase()}`).default;
3737

3838
return <IntegrationComponent integration_to_app_mapping_id={relation_id} />;
3939
} catch (error) {

Diff for: client-reactjs/src/components/admin/Users.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -273,7 +273,7 @@ class Users extends Component {
273273
<div>
274274
<Modal
275275
title="Add User"
276-
visible={this.state.showAddUsers}
276+
open={this.state.showAddUsers}
277277
onOk={this.handleAddUserOk}
278278
onCancel={this.handleAddUserCancel}
279279
confirmLoading={confirmLoading}>

Diff for: client-reactjs/src/components/admin/apps/AddApplication.jsx

+25-5
Original file line numberDiff line numberDiff line change
@@ -63,9 +63,12 @@ function AddApplication(props) {
6363
const appWithSameTitleExists = props.applications.some((app) => app.title === form.getFieldValue('title'));
6464
if (appWithSameTitleExists) return message.error('App with same title already exists');
6565
}
66-
await form.validateFields();
66+
67+
await validateForms();
68+
6769
try {
6870
const fieldValues = form.getFieldsValue();
71+
6972
let payload = {
7073
...fieldValues,
7174
user_id: props.user.username,
@@ -110,6 +113,20 @@ function AddApplication(props) {
110113
}
111114
};
112115

116+
//validate forms before saving
117+
const validateForms = async () => {
118+
let validationError = null;
119+
let formData = {};
120+
121+
try {
122+
formData = await form.validateFields();
123+
} catch (err) {
124+
validationError = err;
125+
}
126+
127+
return { validationError, formData };
128+
};
129+
113130
// CANCEL / CLOSE MODAL WHEN CANCEL OR 'X' IS CLICKED
114131
const handleModalCancel = () => {
115132
props.closeAddApplicationModal();
@@ -119,7 +136,7 @@ function AddApplication(props) {
119136
//JSX
120137
return (
121138
<Modal
122-
visible={props.showAddApplicationModal}
139+
open={props.showAddApplicationModal}
123140
title={
124141
props?.selectedApplication?.title ? (
125142
<>
@@ -157,7 +174,8 @@ function AddApplication(props) {
157174
<Form className="formInModal" form={form} initialValues={{ visibility: 'Private' }}>
158175
<Form.Item
159176
{...formItemLayout}
160-
label={<Text text="Title" />}
177+
label="Title"
178+
labelAlign="left"
161179
name="title"
162180
validateTrigger={['onChange', 'onBlur']}
163181
rules={[
@@ -178,7 +196,8 @@ function AddApplication(props) {
178196
</Form.Item>
179197

180198
<Form.Item
181-
label={<Text text="Description" />}
199+
label="Description"
200+
labelAlign="left"
182201
name="description"
183202
{...formItemLayout}
184203
validateTrigger={['onChange', 'onBlur']}
@@ -204,7 +223,8 @@ function AddApplication(props) {
204223

205224
<Form.Item
206225
{...formItemLayout}
207-
label={<Text text="Visibility" />}
226+
label="Visibility"
227+
labelAlign="left"
208228
rules={[
209229
{
210230
required: props.isCreatingNewApp || isEditing,

0 commit comments

Comments
 (0)