Loading modules/cloud_dashboard/cloud_dashboard/src/molecules/EntityFormBlock.tsx +1 −1 Original line number Diff line number Diff line Loading @@ -189,7 +189,7 @@ const EntityFormBlock = ({ keyValueRecord, cloudContext, formData, setFormData } return !!keyValueRecord.readOnly ? <LabelBlock name={keyValueRecord.labelName} value={(value as string[]).join(', ')} /> value={(Array.isArray(value) ? value : []).join(', ')} /> : <MultiStringInputBlock label={keyValueRecord.labelName} value={value} Loading modules/cloud_dashboard/cloud_dashboard/src/molecules/MultiSelectBlock.tsx +1 −1 Original line number Diff line number Diff line Loading @@ -18,7 +18,7 @@ const MultiSelectBlock = ({ const newValue: string[] = []; for (let i = 0; i < e.currentTarget.options.length; i++) { if (e.currentTarget.options[i].selected) { newValue.push(recordList[i].label); newValue.push(recordList[i].value); } } setValue(newValue); Loading modules/cloud_dashboard/cloud_dashboard/src/molecules/UrlMultiSelectBlock.tsx +13 −1 Original line number Diff line number Diff line Loading @@ -48,7 +48,19 @@ const UrlMultiSelectBlock = ({ label, value, setValue, formData, url, cloudConte getJsonData<{ value: string, label: string, group?: string }[]>(replacedUrl).then((jsonData) => { setRecordList(jsonData); if (value.length !== 0) { setValue([]); const valueSet = new Set(); for (const r of jsonData) { valueSet.add(r.value); } const newValue: string[] = []; for (const v of value) { if (valueSet.has(v)) { newValue.push(v); } } if (value.length !== newValue.length) { setValue(newValue); } } }) } catch { Loading Loading
modules/cloud_dashboard/cloud_dashboard/src/molecules/EntityFormBlock.tsx +1 −1 Original line number Diff line number Diff line Loading @@ -189,7 +189,7 @@ const EntityFormBlock = ({ keyValueRecord, cloudContext, formData, setFormData } return !!keyValueRecord.readOnly ? <LabelBlock name={keyValueRecord.labelName} value={(value as string[]).join(', ')} /> value={(Array.isArray(value) ? value : []).join(', ')} /> : <MultiStringInputBlock label={keyValueRecord.labelName} value={value} Loading
modules/cloud_dashboard/cloud_dashboard/src/molecules/MultiSelectBlock.tsx +1 −1 Original line number Diff line number Diff line Loading @@ -18,7 +18,7 @@ const MultiSelectBlock = ({ const newValue: string[] = []; for (let i = 0; i < e.currentTarget.options.length; i++) { if (e.currentTarget.options[i].selected) { newValue.push(recordList[i].label); newValue.push(recordList[i].value); } } setValue(newValue); Loading
modules/cloud_dashboard/cloud_dashboard/src/molecules/UrlMultiSelectBlock.tsx +13 −1 Original line number Diff line number Diff line Loading @@ -48,7 +48,19 @@ const UrlMultiSelectBlock = ({ label, value, setValue, formData, url, cloudConte getJsonData<{ value: string, label: string, group?: string }[]>(replacedUrl).then((jsonData) => { setRecordList(jsonData); if (value.length !== 0) { setValue([]); const valueSet = new Set(); for (const r of jsonData) { valueSet.add(r.value); } const newValue: string[] = []; for (const v of value) { if (valueSet.has(v)) { newValue.push(v); } } if (value.length !== newValue.length) { setValue(newValue); } } }) } catch { Loading