diff --git a/server/api-service/lowcoder-server/src/main/java/org/lowcoder/api/query/LibraryQueryController.java b/server/api-service/lowcoder-server/src/main/java/org/lowcoder/api/query/LibraryQueryController.java index dae78359c..adcee61c2 100644 --- a/server/api-service/lowcoder-server/src/main/java/org/lowcoder/api/query/LibraryQueryController.java +++ b/server/api-service/lowcoder-server/src/main/java/org/lowcoder/api/query/LibraryQueryController.java @@ -35,13 +35,13 @@ public class LibraryQueryController implements LibraryQueryEndpoints private GidService gidService; @Override - public Mono>> dropDownList(@RequestParam(required = false) String name) { + public Mono>> dropDownList(@RequestParam(required = false, defaultValue = "") String name) { return libraryQueryApiService.dropDownList(name) .map(ResponseView::success); } @Override - public Mono>> list(@RequestParam(required = false) String name) { + public Mono>> list(@RequestParam(required = false, defaultValue = "") String name) { return libraryQueryApiService.listLibraryQueries(name) .map(ResponseView::success); } diff --git a/server/api-service/lowcoder-server/src/main/java/org/lowcoder/api/query/LibraryQueryEndpoints.java b/server/api-service/lowcoder-server/src/main/java/org/lowcoder/api/query/LibraryQueryEndpoints.java index 97f6947d8..1be240f50 100644 --- a/server/api-service/lowcoder-server/src/main/java/org/lowcoder/api/query/LibraryQueryEndpoints.java +++ b/server/api-service/lowcoder-server/src/main/java/org/lowcoder/api/query/LibraryQueryEndpoints.java @@ -29,7 +29,7 @@ public interface LibraryQueryEndpoints description = "Retrieve Library Queries in a dropdown format within Lowcoder, suitable for selection in user interfaces." ) @GetMapping("/dropDownList") - public Mono>> dropDownList(@RequestParam(required = false) String name); + public Mono>> dropDownList(@RequestParam(required = false, defaultValue = "") String name); @Operation( tags = TAG_LIBRARY_QUERY_MANAGEMENT, @@ -38,7 +38,7 @@ public interface LibraryQueryEndpoints description = "Retrieve a list of Library Queries for a specific Organization within Lowcoder." ) @GetMapping("/listByOrg") - public Mono>> list(@RequestParam(required = false) String name); + public Mono>> list(@RequestParam(required = false, defaultValue = "") String name); @Operation( tags = TAG_LIBRARY_QUERY_MANAGEMENT,