本文整理汇总了C#中LumexDBPlayer.ExecuteNonQuery方法的典型用法代码示例。如果您正苦于以下问题:C# LumexDBPlayer.ExecuteNonQuery方法的具体用法?C# LumexDBPlayer.ExecuteNonQuery怎么用?C# LumexDBPlayer.ExecuteNonQuery使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类LumexDBPlayer
的用法示例。
在下文中一共展示了LumexDBPlayer.ExecuteNonQuery方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: ChangeChequeStatusForOutFlow
internal bool ChangeChequeStatusForOutFlow(LumexDBPlayer db, chequeInventoryBLL chequeInventoryBLL, string statusType)
{
bool status = false;
try
{
db.AddParameters("@Serial", chequeInventoryBLL.chequeSerial.Trim());
db.AddParameters("@CreatedBy", LumexSessionManager.Get("ActiveUserId").ToString().Trim());
db.AddParameters("@CreatedFrom", LumexLibraryManager.GetTerminal());
db.AddParameters("@Trandate",chequeInventoryBLL.Finaldate.Trim());
db.AddParameters("@Naration", chequeInventoryBLL.naration.Trim());
if (statusType == "R")
{
status = Convert.ToBoolean(db.ExecuteNonQuery("UPDATE_CHEQUE_INVENTORY_WHEN_REJECT", true));
}
if (statusType == "A")
{
status = Convert.ToBoolean(db.ExecuteNonQuery("[UPDATE_CHEQUE_INVENTORY_FOR_OUT_WHEN_APPROVE]", true));
}
if (statusType == "AC")
{
status = Convert.ToBoolean(db.ExecuteNonQuery("[UPDATE_CHEQUE_INVENTORY_FOR_OUT_WHEN_APPROVE_BY_CASH]", true));
}
}
catch (Exception ex)
{
throw;
}
return status;
}
示例2: SaveProductTransferRecord
public string SaveProductTransferRecord(ProductTransferRecordBLL productTransferRecord, DataTable dtPrdList, LumexDBPlayer db)
{
string transferRecordId = "";
try
{
db.AddParameters("@TransferOrderId", productTransferRecord.TransferOrderId.Trim());
db.AddParameters("@TransferFrom", productTransferRecord.TransferFrom.Trim());
db.AddParameters("@TransferTo", productTransferRecord.TransferTo.Trim());
db.AddParameters("@TransferType", productTransferRecord.TransferType.Trim());
db.AddParameters("@Description", productTransferRecord.Description.Trim());
db.AddParameters("@CreatedBy", LumexSessionManager.Get("ActiveUserId").ToString());
db.AddParameters("@CreatedFrom", LumexLibraryManager.GetTerminal());
DataTable dt = db.ExecuteDataTable("INSERT_PRODUCT_TRANSFER_RECORD", true);
if (dt.Rows.Count > 0)
{
transferRecordId = dt.Rows[0][0].ToString();
}
for (int i = 0; i < dtPrdList.Rows.Count; i++)
{
db.ClearParameters();
db.AddParameters("@TransferRecordId", transferRecordId.Trim());
db.AddParameters("@ProductId", dtPrdList.Rows[i]["ProductId"].ToString());
db.AddParameters("@ReceivedQuantity", dtPrdList.Rows[i]["ReceivedQuantity"].ToString());
db.AddParameters("@DisappearedQuantity", dtPrdList.Rows[i]["DisappearedQuantity"].ToString());
db.AddParameters("@Status", dtPrdList.Rows[i]["Status"].ToString());
db.AddParameters("@Narration", dtPrdList.Rows[i]["Narration"].ToString());
db.ExecuteNonQuery("INSERT_PRODUCT_TRANSFER_RECORD_PRODUCT", true);
}
db.ClearParameters();
db.AddParameters("@TransferOrderId", productTransferRecord.TransferOrderId.Trim());
db.AddParameters("@Status", productTransferRecord.Status.Trim());
db.AddParameters("@CanceledBy", "");
db.AddParameters("@CanceledFrom", "");
db.ExecuteNonQuery("UPDATE_PRODUCT_TRANSFER_ORDER_STATUS_BY_ID", true);
return transferRecordId;
}
catch (Exception)
{
throw;
}
finally
{
productTransferRecord = null;
}
}
示例3: SaveUserSalesCentersByUserId
public void SaveUserSalesCentersByUserId(string userId, List<string> salesCenters, LumexDBPlayer db)
{
try
{
db.AddParameters("@UserId", userId);
db.ExecuteNonQuery("DELETE_USER_SALES_CENTERS_BY_USER_ID", true);
for (int i = 0; i < salesCenters.Count; i++)
{
db.ClearParameters();
db.AddParameters("@UserId", userId);
db.AddParameters("@SalesCenterId", salesCenters[i].ToString());
db.AddParameters("@CreatedBy", LumexSessionManager.Get("ActiveUserId").ToString());
db.AddParameters("@CreatedFrom", LumexLibraryManager.GetTerminal());
db.ExecuteDataTable("INSERT_USER_SALES_CENTERS_BY_USER_ID", true);
}
}
catch (Exception)
{
throw;
}
finally
{
salesCenters = null;
}
}
示例4: SaveProductVendorsByProductId
public void SaveProductVendorsByProductId(string productId, List<string> vendors, LumexDBPlayer db)
{
try
{
db.AddParameters("@ProductId", productId);
db.ExecuteNonQuery("DELETE_PRODUCT_VENDORS_BY_PRODUCT_ID", true);
for (int i = 0; i < vendors.Count; i++)
{
db.ClearParameters();
db.AddParameters("@ProductId", productId);
db.AddParameters("@VendorId", vendors[i].ToString());
db.AddParameters("@CreatedBy", LumexSessionManager.Get("ActiveUserId").ToString());
db.AddParameters("@CreatedFrom", LumexLibraryManager.GetTerminal());
db.ExecuteDataTable("INSERT_PRODUCT_VENDORS_BY_PRODUCT_ID", true);
}
}
catch (Exception)
{
throw;
}
finally
{
vendors = null;
}
}
示例5: SaveJournalVoucher
public DataTable SaveJournalVoucher(string SalesCenter,DataTable dtJournalList, LumexDBPlayer db)
{
try
{
decimal amt = -1;
int transactionNo = 0;
db.AddParameters("@Flag", "JV");
DataTable dtJournalNumber = db.ExecuteDataTable("GET_AND_UPDATE_AUTO_SERIAL_NUMBER_BY_FLAG", true);
string journalNumber = dtJournalNumber.Rows[0][0].ToString();
for (int i = 0; i < dtJournalList.Rows.Count; i++)
{
db.ClearParameters();
db.AddParameters("@JournalNumber", journalNumber.Trim());
db.AddParameters("@TransactionNumber", dtJournalList.Rows[i]["SN"].ToString());
db.AddParameters("@ManualVoucherNumber", dtJournalList.Rows[i]["VoucherNumber"].ToString());
db.AddParameters("@AccountId", dtJournalList.Rows[i]["AccountHead"].ToString());
db.AddParameters("@DebitCredit", dtJournalList.Rows[i]["DebitCredit"].ToString());
db.AddParameters("@Amount", dtJournalList.Rows[i]["Amount"].ToString());
db.AddParameters("@Bank", dtJournalList.Rows[i]["Bank"].ToString());
db.AddParameters("@BankBranch", dtJournalList.Rows[i]["BankBranch"].ToString());
db.AddParameters("@ChequeNumber", dtJournalList.Rows[i]["ChequeNumber"].ToString());
db.AddParameters("@ChequeDate", dtJournalList.Rows[i]["ChequeDate"].ToString());
db.AddParameters("@PayToFromCompany", dtJournalList.Rows[i]["PayToFromCompany"].ToString());
db.AddParameters("@Narration", dtJournalList.Rows[i]["Narration"].ToString());
db.AddParameters("@OfficeBranchId", SalesCenter);
db.AddParameters("@CreatedBy", LumexSessionManager.Get("ActiveUserId").ToString());
db.AddParameters("@CreatedFrom", LumexLibraryManager.GetTerminal());
DataTable dt = db.ExecuteDataTable("INSERT_JOURNAL_VOUCHER", true);
if (amt < decimal.Parse(dtJournalList.Rows[i]["Amount"].ToString()))
{
amt = decimal.Parse(dtJournalList.Rows[i]["Amount"].ToString());
transactionNo = int.Parse(dtJournalList.Rows[i]["SN"].ToString());
}
}
db.ClearParameters();
db.AddParameters("@JournalNumber", journalNumber.Trim());
db.AddParameters("@TransactionNumber", transactionNo);
db.ExecuteNonQuery("INSERT_JOURNAL_VOUCHER_INTO_GENERAL_LEDGER_APPROVAL_BY_JOURNAL", true);
return dtJournalNumber;
}
catch (Exception)
{
throw;
}
finally
{
dtJournalList = null;
}
}
示例6: UpdateProductTransferOrderOnTransport
public void UpdateProductTransferOrderOnTransport(string transferOrderId, LumexDBPlayer db)
{
try
{
db.AddParameters("@TransferOrderId", transferOrderId.Trim());
db.ExecuteNonQuery("UPDATE_PRODUCT_TRANSFER_ORDER_ON_TRANSPORT", true);
}
catch (Exception)
{
throw;
}
}
示例7: updateActiveMessage
internal void updateActiveMessage(string Message, LumexDBPlayer db)
{
try
{
db.AddParameters("@Msg", Message);
db.ExecuteNonQuery("[UPDATE_ACTIVE_MESSAGE]", true);
}
catch (Exception)
{
throw;
}
}
示例8: DeleteUserGroup
public void DeleteUserGroup(string userGroupId, LumexDBPlayer db)
{
try
{
db.AddParameters("@UserGroupId", userGroupId);
db.AddParameters("@DeletedBy", LumexSessionManager.Get("ActiveUserId"));
db.AddParameters("@DeletedFrom", LumexLibraryManager.GetTerminal());
db.AddParameters("@BranchId", LumexSessionManager.Get("UserBranchId"));
db.ExecuteNonQuery("DELETE_USER_GROUP_BY_ID", true);
}
catch (Exception)
{
throw;
}
}
示例9: SaveProductionDetails
public bool SaveProductionDetails(LumexDBPlayer db,newproductionBLL newProduction,DataTable dtRawmetarial)
{
DataTable dt = new DataTable();
bool st = false;
try
{
db.AddParameters("@ProductionId", newProduction.productionId);
db.AddParameters("@WarehouseId", newProduction.wareHouseID);
db.AddParameters("@ProductId", newProduction.productID);
db.AddParameters("@ProduceWight", newProduction.produceWeight);
db.AddParameters("@ProduceBundle", newProduction.produceBundle);
db.AddParameters("@ProduceDate", newProduction.produceDate);
db.AddParameters("@UnitCost", newProduction.unitCost);
db.AddParameters("@ProductionCost", newProduction.productionCost);
db.AddParameters("@TotalQualnity", newProduction.totalQuantity);
db.AddParameters("@RawMaterialCost", newProduction.rawMetarialCost);
db.AddParameters("@OtherAmount",newProduction.otherAmmount);
db.AddParameters("@WorkingCost",newProduction.workingCost);
db.AddParameters("@DecreaseWeight", newProduction.decreaseWeight);
db.AddParameters("@DecreaseRate", newProduction.decreaseRate);
db.AddParameters("@DescripTions", newProduction.description);
db.AddParameters("@CreatedBy", newProduction.createdBy);
db.AddParameters("@CreatedDate", newProduction.createdDate);
db.AddParameters("@ForStock",Convert.ToDecimal(newProduction.forStock));
dt = db.ExecuteDataTable("INSERT_PRODUCTION", true);
for (int i = 0; i < dtRawmetarial.Rows.Count; i++)
{
db.ClearParameters();
db.AddParameters("@ProductionId", newProduction.productionId);
db.AddParameters("@ProductId", dtRawmetarial.Rows[i]["productId"].ToString().Trim());
db.AddParameters("@ProductQuantity", dtRawmetarial.Rows[i]["quantity"].ToString().Trim());
//db.AddParameters("@ProductRate", dtRawmetarial.Rows[i]["rate"].ToString().Trim());
//db.AddParameters("@TotalCost", dtRawmetarial.Rows[i]["cost"].ToString().Trim());
db.ExecuteNonQuery("INSERT_PRODUCTION_RAW", true);
}
st = true;
}
catch (Exception)
{
throw;
}
return st;
}
示例10: SaveProductRequisition
public string SaveProductRequisition(List<ProductRequisitionBLL> productRequisitions, string salesCenterId,string warehouseId,string requisationType, string narration, LumexDBPlayer db)
{
string productRequisitionId = string.Empty;
try
{
db.ClearParameters();
db.AddParameters("@SalesCenterId", salesCenterId.Trim());
db.AddParameters("@WarehouseId", warehouseId.Trim());
db.AddParameters("@RequisationType", requisationType.Trim());
db.AddParameters("@Narration", narration.Trim());
db.AddParameters("@CreatedBy", LumexSessionManager.Get("ActiveUserId").ToString());
db.AddParameters("@CreatedFrom", LumexLibraryManager.GetTerminal());
DataTable dt = db.ExecuteDataTable("INSERT_PRODUCT_REQUISITION", true);
if (dt.Rows.Count > 0)
{
productRequisitionId = dt.Rows[0][0].ToString();
for (int i = 0; i < productRequisitions.Count; i++)
{
db.ClearParameters();
db.AddParameters("@ProductRequisitionId", productRequisitionId.Trim());
db.AddParameters("@ProductId", productRequisitions[i].ProductId.Trim());
db.AddParameters("@RequisitionQuantity", productRequisitions[i].RequisitionQuantity.Trim());
db.AddParameters("@RequiredDate", productRequisitions[i].RequiredDate.Trim());
db.AddParameters("@Narration", productRequisitions[i].ProductNarration.Trim());
db.ExecuteNonQuery("INSERT_PRODUCT_REQUISITION_PRODUCT", true);
}
}
else
{
// db.ExecuteDataTable("there_is_no_procedure_to_execute", false);
}
return productRequisitionId;
}
catch (Exception)
{
throw;
}
finally
{
productRequisitions = null;
}
}
示例11: SavePurchaseOrder
public string SavePurchaseOrder(List<PurchaseOrderBLL> purchaseOrders, string warehouseId, string narration, LumexDBPlayer db)
{
string purchaseOrderId = string.Empty;
try
{
db.ClearParameters();
//db.AddParameters("@WarehouseId", warehouseId.Trim());
//db.AddParameters("@Narration", narration.Trim());
//db.AddParameters("@CreatedBy", LumexSessionManager.Get("ActiveUserId").ToString());
//db.AddParameters("@CreatedFrom", LumexLibraryManager.GetTerminal());
DataTable dt = db.ExecuteDataTable("", true);
if (dt.Rows.Count > 0)
{
purchaseOrderId = dt.Rows[0][0].ToString();
for (int i = 0; i < purchaseOrders.Count; i++)
{
db.ClearParameters();
//db.AddParameters("@PurchaseOrderId", purchaseOrderId.Trim());
//db.AddParameters("@ProductId", purchaseOrders[i].ProductId.Trim());
//db.AddParameters("@OrderQuantity", purchaseOrders[i].OrderQuantity.Trim());
//db.AddParameters("@RequiredDate", purchaseOrders[i].RequiredDate.Trim());
//db.AddParameters("@Narration", purchaseOrders[i].ProductNarration.Trim());
db.ExecuteNonQuery("", true);
}
}
else
{
db.ExecuteDataTable("there_is_no_procedure_to_execute", false);
}
return purchaseOrderId;
}
catch (Exception)
{
throw;
}
finally
{
purchaseOrders = null;
}
}
示例12: UpdateTodaysCashOutEntryBySerial
public void UpdateTodaysCashOutEntryBySerial(CashOutBLL cashOut, LumexDBPlayer db)
{
try
{
db.AddParameters("@Serial", cashOut.Serial.Trim());
db.AddParameters("@AccountId", cashOut.AccountId);
db.AddParameters("@EntryDate", cashOut.EntryDate.Trim());
db.AddParameters("@Amount", cashOut.Amount.Trim());
db.AddParameters("@Narration", cashOut.Narration.Trim());
db.AddParameters("@ModifiedBy", LumexSessionManager.Get("ActiveUserId").ToString());
db.AddParameters("@ModifiedFrom", LumexLibraryManager.GetTerminal());
db.ExecuteNonQuery("UPDATE_CASH_OUT_ENTRY_BY_SERIAL", true);
}
catch (Exception)
{
throw;
}
}
示例13: rejectPurchaseRecord
internal bool rejectPurchaseRecord(string salesCenterId, string purchaseRecordId, LumexDBPlayer db)
{
bool status = false;
try
{
db.AddParameters("@SalesCenterId", salesCenterId.Trim());
db.AddParameters("@PurchaseRecordId", purchaseRecordId.Trim());
db.AddParameters("@ApprovedBy", LumexSessionManager.Get("ActiveUserId").ToString());
db.AddParameters("@ApprovedFrom", LumexLibraryManager.GetTerminal());
status = Convert.ToBoolean(db.ExecuteNonQuery("REJECT_SALES_CENTER_PURCHASE_RECORD", true));
}
catch (Exception)
{
throw;
}
return status;
}
示例14: UpdateSalesPerson
public void UpdateSalesPerson(SalesPersonBLL salesPerson, LumexDBPlayer db)
{
try
{
db.AddParameters("@SalesPersonId", salesPerson.SalesPersonId.Trim());
db.AddParameters("@SalesPersonName", salesPerson.SalesPersonName.Trim());
db.AddParameters("@Address", salesPerson.Address.Trim());
db.AddParameters("@PostalCode", salesPerson.PostalCode.Trim());
db.AddParameters("@City", salesPerson.City.Trim());
db.AddParameters("@District", salesPerson.District.Trim());
db.AddParameters("@Country", salesPerson.Country.Trim());
db.AddParameters("@NationalId", salesPerson.NationalId.Trim());
db.AddParameters("@PassportNumber", salesPerson.PassportNumber.Trim());
db.AddParameters("@ContactNumber", salesPerson.ContactNumber.Trim());
db.AddParameters("@Email", salesPerson.Email.Trim());
db.AddParameters("@JoiningSalesCenterId", salesPerson.JoiningSalesCenterId.Trim());
db.AddParameters("@WorkingSalesCenterId", salesPerson.WorkingSalesCenterId.Trim());
db.AddParameters("@JoinDate", salesPerson.JoinDate.Trim());
db.AddParameters("@ModifiedBy", LumexSessionManager.Get("ActiveUserId").ToString());
db.AddParameters("@ModifiedFrom", LumexLibraryManager.GetTerminal());
db.ExecuteNonQuery("UPDATE_SALES_PERSON_BY_ID", true);
}
catch (Exception)
{
throw;
}
finally
{
salesPerson = null;
}
}
示例15: UpdateSalesPersonActivation
public void UpdateSalesPersonActivation(string salesPersonId, string activationStatus, LumexDBPlayer db)
{
try
{
db.AddParameters("@SalesPersonId", salesPersonId);
db.AddParameters("@IsActive", activationStatus);
db.AddParameters("@ActivatedBy", LumexSessionManager.Get("ActiveUserId").ToString());
db.AddParameters("@ActivatedFrom", LumexLibraryManager.GetTerminal());
db.ExecuteNonQuery("UPDATE_SALES_PERSON_ACTIVATION", true);
}
catch (Exception)
{
throw;
}
}