/// <summary> /// 退货表插入 /// </summary> /// <param name="pware"></param> /// <param name="SQLCommand"></param> /// <returns></returns> public bool insertPWarehouseTable_ReturnGoodsBll(PWarehouseTable_ReturnGoods pware, string SQLCommand) { if (pwareDal.insertPWarehouseTable_ReturnGoodsDal(pware, SQLCommand) > 0) { return(true); } else { return(false); } }
void SetTxtBox(PWarehouseTable_ReturnGoods IIM) { NOTE = IIM.note; TxtBox_PurchaseReceiptID.Text = IIM.PurchaseReceiptID; TxtBox_PurchaseNo.Text = IIM.PurchaseNo; TxtBox_SupplierName.Text = IIM.SupplierName; TxtBox_BatchNo.Text = IIM.BatchNo; TxtBox_MaterialCode.Text = IIM.MaterialCode; TxtBox_MaterialName.Text = IIM.MaterialName; TxtBox_MaterialSpecifications.Text = IIM.MaterialSpecifications; ip_ProductQuantity.Text = IIM.CheckSpecialMining == "特采"? IIM.ProductQuantity.ToString():IIM.ProductQuantity1.ToString(); }
/// <summary> /// 退货表插入 /// </summary> /// <param name="pware"></param> /// <param name="SQLCommand"></param> /// <returns></returns> public int insertPWarehouseTable_ReturnGoodsDal(PWarehouseTable_ReturnGoods pware, string SQLCommand) { string sql = SQLhelp.GetSQLCommand(SQLCommand); List <PWarehouseTable_ReturnGoods> list = new List <PWarehouseTable_ReturnGoods>(); SqlParameter[] pms = new SqlParameter[] { new SqlParameter("@PurchaseReceiptID", SqlDbType.VarChar, 100) { Value = pware.PurchaseReceiptID }, new SqlParameter("@PurchaseNo", SqlDbType.VarChar, 80) { Value = pware.PurchaseNo }, new SqlParameter("@SupplierName", SqlDbType.VarChar, 80) { Value = pware.SupplierName }, new SqlParameter("@BatchNo", SqlDbType.VarChar, 80) { Value = pware.BatchNo }, new SqlParameter("@MaterialCode", SqlDbType.VarChar, 80) { Value = pware.MaterialCode }, new SqlParameter("@MaterialName", SqlDbType.VarChar, 80) { Value = pware.MaterialName }, new SqlParameter("@MaterialSpecifications", SqlDbType.VarChar, 80) { Value = pware.MaterialSpecifications }, new SqlParameter("@ProductQuantity", SqlDbType.Int) { Value = pware.ProductQuantity1 }, new SqlParameter("@note", SqlDbType.VarChar, 200) { Value = pware.note }, new SqlParameter("@UserName", SqlDbType.VarChar, 50) { Value = pware.UserName } }; return(SQLhelp.ExecuteNonQuery(sql, CommandType.Text, pms)); }
PWarehouseTable_ReturnGoods GetPWarehouseTable_ReturnGoods() { PWarehouseTable_ReturnGoods pwar = new PWarehouseTable_ReturnGoods() { PurchaseReceiptID = TxtBox_PurchaseReceiptID.Text.Trim(), PurchaseNo = TxtBox_PurchaseNo.Text.Trim(), SupplierName = TxtBox_SupplierName.Text.Trim(), BatchNo = TxtBox_BatchNo.Text.Trim(), MaterialCode = TxtBox_MaterialCode.Text.Trim(), MaterialName = TxtBox_MaterialName.Text.Trim(), MaterialSpecifications = TxtBox_MaterialSpecifications.Text.Trim(), ProductQuantity1 = ip_ProductQuantity.Value, note = TxtBox_note.Text, UserName = UsersHelp.Userslist[0].UserName }; return(pwar); }