Ejemplo n.º 1
0
        public ActionResult CreateCartesianPoint(string stepId)
        {
            var point = new CartesianPointViewModel
            {
                StepId = stepId
            };

            return(View(point));
        }
Ejemplo n.º 2
0
        public ActionResult CreateCartesianPoint(CartesianPointViewModel point)
        {
            if (!ModelState.IsValid)
            {
                return(View(point));
            }

            _robotProgramModel.AddCartesianPoint(point);
            return(RedirectToAction("GetPoints", new { stepId = point.StepId }));
        }
        public void UpdateCartesianPoint(CartesianPointViewModel point)
        {
            try
            {
                CartesianPointDto pointDto = Mapper.Map <CartesianPointDto>(point);

                _robotProgramService.UpdateCartesianPoint(pointDto);
            }
            catch (FaultException ex)
            {
                throw new HttpException((int)HttpStatusCode.InternalServerError, "Error occured while updating point", ex);
            }
        }