public string Add(Stock model) { try { var newmodel = new Stock(); model.CopyTo(newmodel); _app.AddOrUpdate(newmodel); } catch (Exception ex) { BjuiResponse.statusCode = "300"; BjuiResponse.message = ex.Message; } return(JsonHelper.Instance.Serialize(BjuiResponse)); }
public string Add(Stock model) { try { var newmodel = new Stock(); model.CopyTo(newmodel); _app.AddOrUpdate(newmodel); } catch (Exception ex) { Result.Status = false; Result.Message = ex.Message; } return(JsonHelper.Instance.Serialize(Result)); }