Beispiel #1
0
 public IList <FieldConfig> GetHardwareInputSelectorToBoardForm(int hardwareInputSelectorId)
 {
     var form = new List <FieldConfig>
     {
         new()
         {
             FieldType = FieldType.Select,
             Options   = _hardwareBoardService.GetAllHardwareBoards()
                         .Select(c => new KeyValuePair <string, string>(c.Id.ToString(), c.Name)),
             Validations = new List <FieldValidatorConfig>
             {
                 new()
                 {
                     FieldValidationType = FieldValidationType.Required,
                     Message             = "Hardware Board is Required"
                 }
             },
             Label = "Hardware Board Selection",
             Name  = "hardwareBoardId",
             Hint  = "Select Hardware Board that is responsible for such Hardware Input"
         },
Beispiel #2
0
        public IList <HardwareBoardDto> GetAllHardwareBoards()
        {
            var hardwareBoardDtos = _hardwareBoardService.GetAllHardwareBoards();

            return(hardwareBoardDtos);
        }