public void WizardUpdate(EventWizardUpdateRequest model, int userId)
        {
            string  procName = "[dbo].[EventWizard_Update]";
            Product product  = null;
            Price   price    = null;

            _data.ExecuteNonQuery(procName, delegate(SqlParameterCollection col)
            {
                EventWizardParamMapper(model, col, userId, product, price);
                col.AddWithValue("@EventId", model.Id);
            }, null);
        }
Exemple #2
0
        public ActionResult <ItemResponse <int> > Update(EventWizardUpdateRequest model)
        {
            int          code     = 200;
            BaseResponse response = null;

            try
            {
                int userId = _authService.GetCurrentUserId();
                _service.WizardUpdate(model, userId);
                response = new SuccessResponse();
            }
            catch (Exception ex)
            {
                code     = 500;
                response = new ErrorResponse($"Server Error: {ex.Message}");
                base.Logger.LogError(ex.ToString());
            }

            return(StatusCode(code, response));
        }