public int InsertStockIn(StockInDomain stock) { commandString = @"INSERT INTO StockIn (ItemID, InQty, Date) VALUES (" + stock.ItemID + ", " + stock.InQty + ", '" + stock.Date + "')"; sqlCommand = new SqlCommand(commandString, sqlConnection); sqlConnection.Open(); int isExecuted; isExecuted = sqlCommand.ExecuteNonQuery(); sqlConnection.Close(); return(isExecuted); }
public int InsertStockIn(StockInDomain stock) { return(_stockRepository.InsertStockIn(stock)); }
public StockIn() { InitializeComponent(); stockIn = new StockInDomain(); }