Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit9491cb9

Browse files
authored
Merge pull request#1511 from lowcoder-org/fix/global_unique_variable_name
check variable name list for uniqueness of name
2 parents1f6ed88 +280387d commit9491cb9

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

‎client/packages/lowcoder/src/comps/editorState.tsx

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -493,6 +493,15 @@ export class EditorState {
493493
if(name!==oldName&&this.nameAndExposingInfo().hasOwnProperty(name)){
494494
returntrans("comp.nameExists",{name:name});
495495
}
496+
497+
//Check query variable name duplication
498+
constqueryComInfoList:string[]=[].concat(...(this.getQueriesComp()
499+
.toJsonValue().map((item:any)=>item.variables.variables.map((v:any)=>v.key))));
500+
501+
if(name!==oldName&&queryComInfoList.includes(name)){
502+
returntrans("comp.nameExists",{name:name});
503+
}
504+
496505
return"";
497506
}
498507

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp