Skip to content

Commit 66ac429

Browse files
committed
pull from origin
2 parents e1940df + 722480d commit 66ac429

File tree

25 files changed

+1246
-56
lines changed

25 files changed

+1246
-56
lines changed

.github/workflows/docker-images.yml

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
name: Build lowcoder dev image
2+
3+
on:
4+
push:
5+
branches: dev
6+
7+
jobs:
8+
build:
9+
runs-on: ubuntu-latest
10+
steps:
11+
- name: Checkout lowcoder from 'dev' branch
12+
uses: actions/checkout@v4
13+
with:
14+
ref: dev
15+
- name: Get commit short SHA
16+
run: echo "SHORT_SHA=$(echo ${{ github.sha }} | cut -c1-7)" >> $GITHUB_ENV
17+
- name: Log into Docker Hub
18+
uses: docker/login-action@v3
19+
with:
20+
username: ${{ secrets.DOCKER_LOGIN }}
21+
password: ${{ secrets.DOCKER_PASSWORD }}
22+
- name: Setup Docker Buildx with cloud driver
23+
uses: docker/setup-buildx-action@v3
24+
with:
25+
version: "lab:latest"
26+
driver: cloud
27+
endpoint: "lowcoderorg/lowcoder-cloud-builder"
28+
- name: Build and push the all-in-one image
29+
uses: docker/build-push-action@v6
30+
env:
31+
NODE_ENV: production
32+
with:
33+
file: ./deploy/docker/Dockerfile
34+
build-args: |
35+
REACT_APP_ENV=production
36+
REACT_APP_COMMIT_ID="dev #${SHORT_SHA}"
37+
platforms: |
38+
linux/amd64
39+
linux/arm64
40+
push: true
41+
tags: lowcoderorg/lowcoder-ce:dev
42+

client/packages/lowcoder/src/comps/hooks/modalComp.tsx

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@ import { withDefault } from "comps/generators";
2525
import SliderControl from "../controls/sliderControl";
2626

2727
const EventOptions = [
28+
{ label: trans("modalComp.open"), value: "open", description: trans("modalComp.openDesc") },
2829
{ label: trans("modalComp.close"), value: "close", description: trans("modalComp.closeDesc") },
2930
] as const;
3031

@@ -169,6 +170,9 @@ let TmpModalComp = (function () {
169170
afterClose={() => {
170171
props.toggleClose&&props.onEvent("close");
171172
}}
173+
afterOpenChange={(open: boolean) => {
174+
if (open) props.onEvent("open");
175+
}}
172176
zIndex={Layers.modal}
173177
modalRender={(node) => <ModalStyled $style={props.style}>{node}</ModalStyled>}
174178
mask={props.showMask}

client/packages/lowcoder/src/comps/hooks/utilsComp.ts

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,10 @@ import copy from "copy-to-clipboard";
66
import { saveDataAsFile } from "../../util/fileUtils";
77
import { openApp, recordToSearchStr } from "../../util/appUtils";
88
import { trans } from "i18n";
9+
import { logoutAction } from "redux/reduxActions/userActions";
10+
import { useDispatch } from "react-redux";
11+
import { useCallback } from "react";
12+
913

1014
const UtilsCompBase = simpleMultiComp({});
1115
export let UtilsComp = withExposingConfigs(UtilsCompBase, []);
@@ -107,4 +111,14 @@ UtilsComp = withMethodExposing(UtilsComp, [
107111
}
108112
},
109113
},
114+
{
115+
method: {
116+
name: "logoutUser",
117+
description: trans("utilsComp.downloadFile"),
118+
params: [],
119+
},
120+
execute: (comp, params) => {
121+
logoutAction({})
122+
},
123+
},
110124
]);
Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
1-
export const SERVER_HOST = `${REACT_APP_API_SERVICE_URL ?? ""}`;
2-
export const NPM_REGISTRY_URL = `${SERVER_HOST}/api/npm/registry`;
3-
export const NPM_PLUGIN_ASSETS_BASE_URL = `${SERVER_HOST}/api/npm/package`;
1+
export const SERVER_HOST = `${REACT_APP_NODE_SERVICE_URL ?? ""}`;
2+
export const NPM_REGISTRY_URL = `${SERVER_HOST}/node-service/api/npm/registry`;
3+
export const NPM_PLUGIN_ASSETS_BASE_URL = `${SERVER_HOST}/node-service/api/npm/package`;

client/packages/lowcoder/src/i18n/locales/en.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2369,6 +2369,8 @@ export const en = {
23692369

23702370

23712371
"modalComp": {
2372+
"open": "Open",
2373+
"openDesc": "Triggered When the Modal Dialog Box is Opened",
23722374
"close": "Close",
23732375
"closeDesc": "Triggered When the Modal Dialog Box is Closed",
23742376
"openModalDesc": "Open the Dialog Box",

client/packages/lowcoder/src/redux/reduxActions/userActions.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,6 @@ export const fetchApiKeysAction = () => {
7070
type: ReduxActionTypes.FETCH_API_KEYS,
7171
};
7272
};
73-
7473
export const fetchApiKeysSuccess = (payload: FetchApiKeysPayload) => {
7574
return {
7675
type: ReduxActionTypes.FETCH_API_KEYS_SUCCESS,

client/packages/lowcoder/src/util/stringUtils.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,7 @@ export const checkPhoneValid = (value: string): boolean => {
8484
};
8585

8686
export const checkEmailValid = (value: string): boolean => {
87-
return EMAIL_PATTERN.test(value);
87+
return value === "admin@localhost" || EMAIL_PATTERN.test(value);
8888
};
8989

9090
export const getNextEntityName = (

0 commit comments

Comments
 (0)