예제 #1
0
        public async Task <IActionResult> SingleEquipmentType([FromRoute] string request)
        {
            try
            {
                var result = await _service.GetEquipmentType(request);

                return(Ok(result));
            }
            catch (BusinessLogicException ex)
            {
                return(BadRequest(new Response
                {
                    Status = false,
                    Message = ex.Message
                }));
            }
            catch (Exception e)
            {
                return(BadRequest(new Response
                {
                    Status = false,
                    Message = ErrorMessages.UnkownError
                }));
            }
        }
예제 #2
0
        public IActionResult UpdateEquipmentType(int id)
        {
            EquipmentType equipmentType = _dal.GetEquipmentType(id);

            return(View(equipmentType));
        }