public CRUDResult <int> Create(RoomInsertReq obj) { var data = _repository.Value.Insert <Room>(new Room() { Name = obj.Name, MaxBet = obj.MaxBet, MinBet = obj.MinBet }); return(new CRUDResult <int>() { Data = data.Id, StatusCode = CRUDStatusCodeRes.ReturnWithData }); }
public IHttpActionResult Post([FromBody] RoomInsertReq model) { var result = _roomServices.Create(model); return(ApiHelper.ReturnHttpAction(result, this)); }