Merge branch 'master' into BUDI-7500/validation-not-triggering-for-required-foreign-keys

This commit is contained in:
Adria Navarro 2023-10-02 15:35:26 +02:00 committed by GitHub
commit 3169962a0a
3 changed files with 10 additions and 4 deletions

View File

@ -1,5 +1,5 @@
{ {
"version": "2.11.1", "version": "2.11.3",
"npmClient": "yarn", "npmClient": "yarn",
"packages": [ "packages": [
"packages/*" "packages/*"

View File

@ -3,6 +3,8 @@
import RelationshipCell from "./RelationshipCell.svelte" import RelationshipCell from "./RelationshipCell.svelte"
import { FieldSubtype } from "@budibase/types" import { FieldSubtype } from "@budibase/types"
export let api
const { API } = getContext("grid") const { API } = getContext("grid")
const { subtype } = $$props.schema const { subtype } = $$props.schema
@ -17,8 +19,11 @@
throw `Search for '${subtype}' not implemented` throw `Search for '${subtype}' not implemented`
} }
// As we are overriding the search function from RelationshipCell, we want to map one shape to the expected one for the specific API
const email = Object.values(searchParams.query.string)[0]
const results = await API.searchUsers({ const results = await API.searchUsers({
...searchParams, email,
}) })
// Mapping to the expected data within RelationshipCell // Mapping to the expected data within RelationshipCell
@ -31,6 +36,7 @@
</script> </script>
<RelationshipCell <RelationshipCell
bind:api
{...$$props} {...$$props}
{schema} {schema}
{searchFunction} {searchFunction}

View File

@ -19,7 +19,7 @@ docker run --rm \
-v ${PWD}/generated:/generated \ -v ${PWD}/generated:/generated \
-v ${PWD}/config.json:/config.json \ -v ${PWD}/config.json:/config.json \
-u $(id -u):$(id -g) \ -u $(id -u):$(id -g) \
swaggerapi/swagger-codegen-cli-v3 generate \ swaggerapi/swagger-codegen-cli-v3:3.0.46 generate \
-i /openapi.yml \ -i /openapi.yml \
-l javascript \ -l javascript \
-o /generated \ -o /generated \
@ -34,4 +34,4 @@ if [[ -f "openapi.yaml" ]]; then
fi fi
if [[ -d "generated" ]]; then if [[ -d "generated" ]]; then
rm -r generated rm -r generated
fi fi