Skip to content

Commit

Permalink
[Bug][scaleph-ui-react] fix webui error (#663)
Browse files Browse the repository at this point in the history
* fix: seatunnel version error

* fix: flink kubernetes job update error

* fix: elasticsearch source connector drawer error

* prepare 2.0.1 release
  • Loading branch information
kalencaya authored Dec 15, 2023
1 parent d7bedf8 commit cb16338
Show file tree
Hide file tree
Showing 5 changed files with 40 additions and 30 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ Scaleph is driven by personal interest and evolves actively through faithful dev
### data integration

* Web-ui click-and-drag data integration ways backended by Apache SeaTunnel(incubating)
* Support 2.3.2 V2 out-of-the-box connectors and transforms
* Support 2.3.3 V2 out-of-the-box connectors and transforms
* DataSource management

### data develop
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,13 @@ import {RocketMQParams, STEP_ATTR_TYPE} from '../../constant';
import {WsDiJobService} from '@/services/project/WsDiJobService';
import {
ProForm,
ProFormDependency, ProFormDigit,
ProFormDependency,
ProFormDigit,
ProFormGroup,
ProFormSelect,
ProFormSwitch,
ProFormText
} from '@ant-design/pro-components';
import FieldItem from "@/pages/Project/Workspace/Artifact/DI/DiJobFlow/Dag/steps/fields";

const SinkRocketMQStepForm: React.FC<
ModalFormProps<{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import {
ProFormTextArea
} from '@ant-design/pro-components';
import {NsGraph} from '@antv/xflow';
import {Form, message, Modal} from 'antd';
import {Button, Drawer, Form, message} from 'antd';
import {useEffect} from 'react';
import {getIntl, getLocale} from 'umi';
import {ElasticsearchParams, SchemaParams, STEP_ATTR_TYPE} from '../../constant';
Expand All @@ -33,31 +33,38 @@ const SourceElasticsearchStepForm: React.FC<ModalFormProps<{
}, []);

return (
<Modal
<Drawer
open={visible}
title={nodeInfo.data.displayName}
width={780}
bodyStyle={{overflowY: 'scroll', maxHeight: '640px'}}
bodyStyle={{overflowY: 'scroll'}}
destroyOnClose={true}
onCancel={onCancel}
onOk={() => {
form.validateFields().then((values) => {
let map: Map<string, any> = new Map();
map.set(STEP_ATTR_TYPE.jobId, jobInfo.id);
map.set(STEP_ATTR_TYPE.jobGraph, JSON.stringify(jobGraph));
map.set(STEP_ATTR_TYPE.stepCode, nodeInfo.id);
StepSchemaService.formatEsSource(values)
StepSchemaService.formatSchema(values);
map.set(STEP_ATTR_TYPE.stepAttrs, values);
WsDiJobService.saveStepAttr(map).then((resp) => {
if (resp.success) {
message.success(intl.formatMessage({id: 'app.common.operate.success'}));
onCancel();
onOK ? onOK(values) : null;
}
});
});
}}
onClose={onCancel}
extra={
<Button
type="primary"
onClick={() => {
form.validateFields().then((values) => {
let map: Map<string, any> = new Map();
map.set(STEP_ATTR_TYPE.jobId, jobInfo.id);
map.set(STEP_ATTR_TYPE.jobGraph, JSON.stringify(jobGraph));
map.set(STEP_ATTR_TYPE.stepCode, nodeInfo.id);
StepSchemaService.formatEsSource(values)
StepSchemaService.formatSchema(values);
map.set(STEP_ATTR_TYPE.stepAttrs, values);
WsDiJobService.saveStepAttr(map).then((resp) => {
if (resp.success) {
message.success(intl.formatMessage({id: 'app.common.operate.success'}));
onCancel();
onOK ? onOK(values) : null;
}
});
});
}}
>
{intl.formatMessage({id: 'app.common.operate.confirm.label'})}
</Button>
}
>
<ProForm form={form} initialValues={nodeInfo.data.attrs} grid={true} submitter={false}>
<ProFormText
Expand Down Expand Up @@ -139,7 +146,7 @@ const SourceElasticsearchStepForm: React.FC<ModalFormProps<{
</ProFormList>
</ProFormGroup>
</ProForm>
</Modal>
</Drawer>
);
};

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,8 @@ const FlinkKubernetesJobForm: React.FC<ModalFormProps<WsFlinkKubernetesJob>> = (
const [form] = Form.useForm();
const projectId = localStorage.getItem(WORKSPACE_CONF.projectId);

console.log('FlinkKubernetesJobForm', data)

return (
<Modal
open={visible}
Expand Down Expand Up @@ -84,12 +86,13 @@ const FlinkKubernetesJobForm: React.FC<ModalFormProps<WsFlinkKubernetesJob>> = (
id: data?.id,
name: data?.name,
executionMode: data?.executionMode?.value,
flinkDeploymentMode: data?.flinkDeploymentMode?.value,
deploymentKind: data?.deploymentKind?.value,
flinkDeploymentId: data?.flinkDeployment?.id,
flinkSessionClusterId: data?.flinkSessionCluster?.id,
type: data?.type?.value,
flinkArtifactJarId: data?.flinkArtifactJar?.id,
flinkArtifactSqlId: data?.flinkArtifactSql?.id,
wsDiJobId: data?.wsDiJob?.id,
remark: data?.remark
}}
>
Expand Down
6 changes: 3 additions & 3 deletions tools/docker/deploy/scaleph/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
services:

scaleph-api:
image: ghcr.io/flowerfine/scaleph/scaleph-api:latest
image: ghcr.io/flowerfine/scaleph/scaleph-api:2.0.1
container_name: scaleph-api
depends_on:
mysql:
Expand All @@ -39,7 +39,7 @@ services:
- scaleph

scaleph-ui-react:
image: ghcr.io/flowerfine/scaleph/scaleph-ui-react:latest
image: ghcr.io/flowerfine/scaleph/scaleph-ui-react:2.0.1
container_name: scaleph-ui-react
depends_on:
scaleph-api:
Expand All @@ -52,7 +52,7 @@ services:
- scaleph

mysql:
image: ghcr.io/flowerfine/scaleph/mysql:latest
image: ghcr.io/flowerfine/scaleph/mysql:2.0.1
container_name: mysql
environment:
- TZ=Asia/Shanghai
Expand Down

0 comments on commit cb16338

Please sign in to comment.