Merge pull request #11857 from Budibase/budi-6922-the-number-0-cannot-be-displayed-on-input-number-fields-when
The number 0 cannot be displayed on input number fields
This commit is contained in:
commit
c08d9e1243
|
@ -96,8 +96,8 @@
|
||||||
{disabled}
|
{disabled}
|
||||||
{readonly}
|
{readonly}
|
||||||
{id}
|
{id}
|
||||||
value={value || ""}
|
value={value ?? ""}
|
||||||
placeholder={placeholder || ""}
|
placeholder={placeholder ?? ""}
|
||||||
on:click
|
on:click
|
||||||
on:blur
|
on:blur
|
||||||
on:focus
|
on:focus
|
||||||
|
|
|
@ -45,7 +45,7 @@
|
||||||
on:focus={() => (active = true)}
|
on:focus={() => (active = true)}
|
||||||
on:blur={() => (active = false)}
|
on:blur={() => (active = false)}
|
||||||
{type}
|
{type}
|
||||||
value={value || ""}
|
value={value ?? ""}
|
||||||
on:change={handleChange}
|
on:change={handleChange}
|
||||||
spellcheck="false"
|
spellcheck="false"
|
||||||
/>
|
/>
|
||||||
|
|
|
@ -305,12 +305,7 @@ export class ExternalRequest {
|
||||||
manyRelationships: ManyRelationship[] = []
|
manyRelationships: ManyRelationship[] = []
|
||||||
for (let [key, field] of Object.entries(table.schema)) {
|
for (let [key, field] of Object.entries(table.schema)) {
|
||||||
// if set already, or not set just skip it
|
// if set already, or not set just skip it
|
||||||
if (row[key] == null || newRow[key] || !isEditableColumn(field)) {
|
if (row[key] === undefined || newRow[key] || !isEditableColumn(field)) {
|
||||||
continue
|
|
||||||
}
|
|
||||||
// if its an empty string then it means return the column to null (if possible)
|
|
||||||
if (row[key] === "") {
|
|
||||||
newRow[key] = null
|
|
||||||
continue
|
continue
|
||||||
}
|
}
|
||||||
// parse floats/numbers
|
// parse floats/numbers
|
||||||
|
|
Loading…
Reference in New Issue