public ResponseBo UpdateIncludeExclude(BasketProductIncludeExcludeUpdateBo updateBo) { ResponseBo responseBo = new ResponseBo(); try { using (SqlConnection conn = DbAccess.Connection.GetConn()) { var p = new DynamicParameters(); p.Add("@Message", dbType: DbType.String, direction: ParameterDirection.Output, size: 255); p.Add("@IsSuccess", dbType: DbType.Boolean, direction: ParameterDirection.Output); p.Add("@BasketProductId", updateBo.BasketProductId, DbType.Int64, ParameterDirection.Input); p.Add("@IEIdListCommaSpr", updateBo.IncludeExcludeIdList.ToStrSeparated(), DbType.String, ParameterDirection.Input, 1000); p.Add("@ApiSessionId", updateBo.Session.ApiSessionId, DbType.Int64, ParameterDirection.Input); p.Add("@MyPersonId", updateBo.Session.MyPerson.Id, DbType.Int64, ParameterDirection.Input); p.Add("@OperatorRealId", updateBo.Session.RealPerson.Id, DbType.Int64, ParameterDirection.Input); p.Add("@LanguageId", updateBo.Session.RealPerson.LanguageId, DbType.Int32, ParameterDirection.Input); conn.Execute("spBasketProductIncludeExcludeUpdate", p, commandType: CommandType.StoredProcedure); responseBo.Message = p.Get <string>("@Message"); responseBo.IsSuccess = p.Get <bool>("@IsSuccess"); } } catch (Exception ex) { responseBo = base.SaveExLog(ex, this.GetType(), MethodBase.GetCurrentMethod().Name, updateBo); } return(responseBo); }
public ResponseDto UpdateIncludeExclude(BasketProductIncludeExcludeUpdateDto updateDto) { ResponseDto responseDto = new ResponseDto(); BasketProductIncludeExcludeUpdateBo updateBo = new BasketProductIncludeExcludeUpdateBo() { BasketProductId = updateDto.BasketProductId, IncludeExcludeIdList = updateDto.IncludeExcludeIdList, Session = Session }; ResponseBo responseBo = basketProductBusiness.UpdateIncludeExclude(updateBo); responseDto = responseBo.ToResponseDto(); return(responseDto); }