ManageIQ/manageiq-providers-redfish

View on GitHub
app/javascript/components/firmware-update.schema.js

Summary

Maintainability
A
0 mins
Test Coverage
import { componentTypes, validatorTypes } from '@@ddf';

const createSchema = (firmwareBinaryOptions) => ({
  fields: [{
    component: componentTypes.SELECT,
    id: 'firmwareBinary',
    name: 'firmwareBinary',
    label: __('Firmware Binary'),
    placeholder: __('Select a Firmware Binary'),
    isSearchable: true,
    isRequired: true,
    validate: [{
      type: validatorTypes.REQUIRED,
      message: __('Firmware Binary is required'),
    }],
    options: firmwareBinaryOptions,
  }],
});

export default createSchema;