FSM Citizen UI
Was this helpful?
Was this helpful?
<CardText> {t("ES_VEHICLE CAPACITY")} </CardText>
<RadioOrSelect
options={vehicleMenu?.map((vehicle) => ({ ...vehicle, label: vehicle.capacity }))}
selectedOption={vehicleCapacity}
optionKey="capacity"
onSelect={selectVehicle}
optionCardStyles={{ zIndex: "60" }}
t={t}
isMandatory={config.isMandatory}isDropDown={true}
/>const allVehicles = dsoData.reduce((acc, curr) => {
return curr.vehicles && curr.vehicles.length ? acc.concat(curr.vehicles) : acc;
}, []);
const cpacityMenu = Array.from(new Set(allVehicles.map((a) => a.capacity)))
.map((capacity) => allVehicles.find((a) => a.capacity === capacity));