コード例 #1
0
        /// <summary>
        /// This method is used to save voucher (Booklet)
        /// </summary>
        /// <param name="voucherInfo"></param>
        /// <param name="userId"></param>
        public static void SaveVoucherBooklet(VoucherInfo voucherInfo, string userId)
        {
            try
            {
                clsParameterCollection ParameterCollection = new clsParameterCollection();
                ParameterCollection.ProcedureName = "BS_Voucher_CreateBooklet";
                ParameterCollection.Add(new clsParameter("@vouchertypeID", voucherInfo.vouchertypeId));
                ParameterCollection.Add(new clsParameter("@denomination", voucherInfo.voucherDenomination));
                ParameterCollection.Add(new clsParameter("@quantity", voucherInfo.quantity));
                ParameterCollection.Add(new clsParameter("@amountvalue", voucherInfo.priceAmount));
                ParameterCollection.Add(new clsParameter("@leaf", voucherInfo.leafQuantity));
                ParameterCollection.Add(new clsParameter("@userid", userId));
                ParameterCollection.Add(new clsParameter("@voucherValidateDate", voucherInfo.VoucherValidity));
                ParameterCollection.Add(new clsParameter("@isThirdparty", voucherInfo.isThirdparty));
                ParameterCollection.Add(new clsParameter("@salesValidateDate", voucherInfo.SalesValidity));
                ParameterCollection.Add(new clsParameter("@showDenomination", voucherInfo.showDenomination));
                ParameterCollection.Add(new clsParameter("@redeemStore", voucherInfo.RedeemStores));

                DataAccess.ExecuteNonQuerySp(ParameterCollection);
            }
            catch (Exception Ex)
            {
                if (!Ex.Message.Contains("User Define:"))
                    BL_Exception.WriteLog(Ex);

                throw Ex;
            }
        }
コード例 #2
0
ファイル: BL_Account.cs プロジェクト: har9421/Vishwapress
        public int CheckPkgCountBeforeInsert(int PackageID, int UserID)
        {
            try
            {
                clsParameterCollection clsParaCollection = new clsParameterCollection();
                clsParaCollection.ProcedureName = Constants.VP_UserPackage_CheckPkgCountBeforeInsert;
                clsParaCollection.Add(new clsParameter { ParameterName = "@UserID", ParameterValue = UserID });
                clsParaCollection.Add(new clsParameter { ParameterName = "@PackageID", ParameterValue = PackageID });
                dt = DataAccess.ExecuteSpAndGetDataTable(clsParaCollection);
                if (dt.Rows.Count > 0)
                {
                    return Convert.ToInt32(dt.Rows[0][0]);
                }
                else
                {
                    return 0;
                }

            }

            catch (Exception ex)
            {
                BL_Exception.WriteLog(ex);
                throw ex;
            }
        }
コード例 #3
0
ファイル: BL_SalesNew.cs プロジェクト: har9421/BestSeller
        public static void SaleVoucherSeries(string FirstID, string LastId, string RequestorName, string RequestorEmail, string RequestorPhone, string Amount, string UserId)
        {
            try
            {
                clsParameterCollection ParameterCollection = new clsParameterCollection();
                ParameterCollection.ProcedureName = "BS_SalesNew_SaleSeries";
                ParameterCollection.Add(new clsParameter("@VocStart", FirstID));
                ParameterCollection.Add(new clsParameter("@VocEnd", LastId));
                ParameterCollection.Add(new clsParameter("@UserID", UserId));
                ParameterCollection.Add(new clsParameter("@name", RequestorName));
                ParameterCollection.Add(new clsParameter("@EmailId", RequestorEmail));
                ParameterCollection.Add(new clsParameter("@phoneNumber", RequestorPhone));
                ParameterCollection.Add(new clsParameter("@TotalSalesAmout", Amount));


                DataAccess.ExecuteNonQuerySp(ParameterCollection);
            }
            catch (Exception Ex)
            {
                if (!Ex.Message.Contains("User Define:"))
                    BL_Exception.WriteLog(Ex);

                throw Ex;
            }
        }
コード例 #4
0
 public DataTable GetProofReadingUserData(string UserID)
 {
     try
     {
         clsParameterCollection clsParaCollection = new clsParameterCollection();
         clsParaCollection.ProcedureName = Constants.sp_RetrieveProofReadingUserData;
         clsParaCollection.Add(new clsParameter("@UserID", UserID));
         return DataAccess.ExecuteSpAndGetDataTable(clsParaCollection);
     }
     catch (Exception Ex)
     {
         throw Ex;
     }
 }
コード例 #5
0
ファイル: BL_Account.cs プロジェクト: har9421/Vishwapress
        public DataTable getAllUsers()
        {
            try {
                clsParameterCollection clsParaCollection = new clsParameterCollection();
                clsParaCollection.ProcedureName = Constants.sp_GetAllUsers;
                dt = DataAccess.ExecuteSpAndGetDataTable(clsParaCollection);
                return dt;

            }
            catch (Exception ex)
            {
                throw ex;
            }
        }
コード例 #6
0
ファイル: BL_Account.cs プロジェクト: har9421/Vishwapress
 public DataTable CheckUserActiveORNOT(string UserName)
 {
     try
     {
         clsParameterCollection clsParaCollection = new clsParameterCollection();
         clsParaCollection.ProcedureName = Constants.sp_IsActive;
         clsParaCollection.Add(new clsParameter { ParameterName = "@UserName", ParameterValue = UserName });
         dt = DataAccess.ExecuteSpAndGetDataTable(clsParaCollection);
         return dt;
     }
     catch (Exception ex)
     {
         throw ex;
     }
 }
コード例 #7
0
ファイル: BL_Template.cs プロジェクト: har9421/Vishwapress
        public DataTable get_IRTemplateData()
        {
            try
            {
                clsParameterCollection clsParaCollection = new clsParameterCollection();
                clsParaCollection.ProcedureName = Constants.sp_RetrieveIllustrationTemplates;

                dt = DataAccess.ExecuteSpAndGetDataTable(clsParaCollection);
                return dt;
            }
            catch (Exception ex)
            {
                throw ex;
            }
        }
コード例 #8
0
ファイル: BL_ProductNew.cs プロジェクト: har9421/Vishwapress
 public void BookAuthorInsert(DataTable dt)
 {
     try
     {
         clsParameterCollection clsParaCollection = new clsParameterCollection();
         clsParaCollection.ProcedureName = Constants.VP_athor_book_Insert;
         clsParaCollection.Add(new clsParameter("@author_book", dt));
         DataAccess.ExecuteNonQuerySp(clsParaCollection);
     }
     catch (Exception ex)
     {
         BL_Exception.WriteLog(ex);
         throw ex;
     }
 }
コード例 #9
0
ファイル: Common.cs プロジェクト: har9421/Vishwapress
 public static int GetUserId(string Email)
 {
     try
     {
         clsParameterCollection clsParaCollection = new clsParameterCollection();
         clsParaCollection.ProcedureName = Constants.GetUserID;
         clsParaCollection.Add(new clsParameter("@Email", Email));
         return Convert.ToInt32(Convert.ToString(DataAccess.ExecuteSpAndGetDataTable(clsParaCollection).Rows[0]["userid"]));
     }
     catch (Exception ex)
     {
         BL_Exception.WriteLog(ex);
         throw ex;
     }
 }
コード例 #10
0
 public DataTable get_Templates()
 {
     try
     {
         clsParameterCollection clsParaCollection = new clsParameterCollection();
         clsParaCollection.ProcedureName = Constants.sp_getIRTemplateURL;
         dt.Reset();
         dt = DataAccess.ExecuteSpAndGetDataTable(clsParaCollection);
         return dt;
     }
     catch (Exception ex)
     {
         throw ex;
     }
 }
コード例 #11
0
ファイル: BL_StateCity.cs プロジェクト: har9421/BestSeller
        public static string GetStateNameByStateId(int CityId)
        {
            try
            {
                clsParameterCollection ParameterCollection = new clsParameterCollection();
                ParameterCollection.ProcedureName = "BS_GetStateByStateId";
                ParameterCollection.Add(new clsParameter("@StateID", CityId));

                return DataAccess.ExecuteScalarSp(ParameterCollection).ToString();
            }
            catch (Exception Ex)
            {
                throw Ex;
            }
        }
コード例 #12
0
ファイル: BL_CoverDesign.cs プロジェクト: har9421/Vishwapress
 ///// <summary>
 ///// This is Used to calculate Estimated Amount based on input(Number of words)
 ///// </summary>
 ///// <param name="wCount"></param>
 ///// <returns></returns>
 //public string CalculateEstimateAmt(int wCount)
 //{
 //    try
 //    {
 //        clsParameterCollection clsParaCollection = new clsParameterCollection();
 //        clsParaCollection.ProcedureName = Constants.sp_CalculateEstimateAmt;
 //        clsParaCollection.Add(new clsParameter("@Wcont", wCount));
 //        dt.Reset();
 //        dt = DataAccess.ExecuteSpAndGetDataTable(clsParaCollection);
 //        return dt.Rows[0][0].ToString();
 //    }
 //    catch (Exception ex)
 //    {
 //        BL_Exception.WriteLog(ex);
 //        throw ex;
 //    }
 //}
 /// <summary>
 /// This Method is used to Cancel service request (set status=Canceled on respective trnid)
 /// </summary>
 /// <param name="trnID"></param>
 public void Cancellation(int trnID)
 {
     try
     {
         clsParameterCollection clsParaCollection = new clsParameterCollection();
         clsParaCollection.Add(new clsParameter("@TrnID", trnID));
         clsParaCollection.ProcedureName = Constants.sp_CoverDesign_CancelRequest;
         DataAccess.ExecuteNonQuerySp(clsParaCollection);
     }
     catch (Exception ex)
     {
         BL_Exception.WriteLog(ex);
         throw ex;
     }
 }
コード例 #13
0
ファイル: BL_Common.cs プロジェクト: har9421/BestSeller
        /// <summary>
        /// This method is used to get Redeemped vouchers.
        /// </summary>
        /// <returns></returns>
        public static DataTable GetVoucherOperationDetails(string ProcedureName)
        {
            try
            {
                clsParameterCollection ParameterCollection = new clsParameterCollection();
                ParameterCollection.ProcedureName = ProcedureName;
                return DataAccess.ExecuteSpAndGetDataTable(ParameterCollection);
            }
            catch (Exception Ex)
            {
                if (!Ex.Message.Contains("User Define:"))
                    BL_Exception.WriteLog(Ex);

                throw Ex;
            }
        }
コード例 #14
0
        public static DataTable GetStoreDetails()
        {
            try
            {
                clsParameterCollection ParameterCollection = new clsParameterCollection();
                ParameterCollection.ProcedureName = "BS_EmployeeAllocation_FillStoreList";
                return DataAccess.ExecuteSpAndGetDataTable(ParameterCollection);
            }
            catch (Exception Ex)
            {
                if (!Ex.Message.Contains("User Define:"))
                    BL_Exception.WriteLog(Ex);

                throw Ex;
            }
        }
コード例 #15
0
ファイル: BL_SalesNew2.cs プロジェクト: har9421/BestSeller
        public static DataTable GetVendorList()
        {
            try
            {
                clsParameterCollection ParameterCollection = new clsParameterCollection();
                ParameterCollection.ProcedureName = "BS_SalesNew2_GetVendorList";
                return DataAccess.ExecuteSpAndGetDataTable(ParameterCollection);
            }
            catch (Exception Ex)
            {
                if (!Ex.Message.Contains("User Define:"))
                    BL_Exception.WriteLog(Ex);

                throw Ex;
            }
        }
コード例 #16
0
ファイル: BL_Cancellation.cs プロジェクト: har9421/BestSeller
        /// <summary>
        /// This method is used to get canceled vouchers
        /// </summary>
        /// <returns></returns>
        public static DataTable GetCancelledDetails()
        {
            try
            {
                clsParameterCollection ParameterCollection = new clsParameterCollection();
                ParameterCollection.ProcedureName = "BS_Cancellation_ShowVocuhers";
                return DataAccess.ExecuteSpAndGetDataTable(ParameterCollection);
            }
            catch (Exception Ex)
            {
                if (!Ex.Message.Contains("User Define:"))
                    BL_Exception.WriteLog(Ex);

                throw Ex;
            }
        }
コード例 #17
0
ファイル: BL_Template.cs プロジェクト: har9421/Vishwapress
 /// <summary>
 /// This method retrieves all available formatting templates from VP_Templates table.
 /// </summary>
 /// <returns></returns>
 public DataTable get_FRTemplateData()
 {
     try
     {
         clsParameterCollection clsParaCollection = new clsParameterCollection();
         clsParaCollection.ProcedureName = Constants.sp_RetrieveFormattingTemplates;
         dt.Reset();
         dt = DataAccess.ExecuteSpAndGetDataTable(clsParaCollection);
         return dt;
     }
     catch (Exception ex)
     {
         BL_Exception.WriteLog(ex);
         throw ex;
     }
 }
コード例 #18
0
ファイル: BL_Menu.cs プロジェクト: har9421/BestSeller
        /// <summary>
        /// This method is used to get child menu details.
        /// </summary>
        /// <returns></returns>
        public static DataTable GetSubMenu(int MenuId)
        {
            try
            {
                clsParameterCollection ParameterCollection = new clsParameterCollection();
                ParameterCollection.ProcedureName = "BS_GetSubMenu";
                ParameterCollection.Add(new clsParameter("@MenuId", MenuId));
                return DataAccess.ExecuteSpAndGetDataTable(ParameterCollection);
            }
            catch (Exception Ex)
            {
                if (!Ex.Message.Contains("User Define:"))
                    BL_Exception.WriteLog(Ex);

                throw Ex;
            }
        }
コード例 #19
0
        public string GetUserName(ProofReading pr)
        {
            try
            {
                clsParameterCollection clsParaCollection = new clsParameterCollection();
                clsParaCollection.ProcedureName = Constants.sp_GetUserName;
                clsParaCollection.Add(new clsParameter("@TrnId", pr.PTran_ID));
                dt.Reset();
                dt = DataAccess.ExecuteSpAndGetDataTable(clsParaCollection);
                return dt.Rows[0][0].ToString();

            }
            catch (Exception ex)
            {
                throw ex;
            }
        }
コード例 #20
0
        public static void CancelRedemption(string UserID)
        {
            try
            {
                clsParameterCollection ParameterCollection = new clsParameterCollection();
                ParameterCollection.ProcedureName = "BS_RedemptionChange3Cancel";
                ParameterCollection.Add(new clsParameter("@UserID", UserID));
                DataAccess.ExecuteNonQuerySp(ParameterCollection);
            }
            catch (Exception Ex)
            {
                if (!Ex.Message.Contains("User Define:"))
                    BL_Exception.WriteLog(Ex);

                throw Ex;
            }
        }
コード例 #21
0
        public string CalculateEstimateAmt(int wCount)
        {
            try
            {
                clsParameterCollection clsParaCollection = new clsParameterCollection();
                clsParaCollection.ProcedureName = Constants.sp_CalculateEstimateAmt;
                clsParaCollection.Add(new clsParameter("@Wcont", wCount));
                dt.Reset();
                dt = DataAccess.ExecuteSpAndGetDataTable(clsParaCollection);
                return dt.Rows[0][0].ToString();

            }
            catch (Exception ex)
            {
                throw ex;
            }
        }
コード例 #22
0
        /// <summary>
        /// This method is used to get user details by email-id.
        /// </summary>
        /// <param name="txtEmail"></param>
        /// <returns></returns>
        public static DataTable GetEmailuser(string txtEmail)
        {
            try
            {
                clsParameterCollection ParameterCollection = new clsParameterCollection();
                ParameterCollection.ProcedureName = "GetEmailuser";
                ParameterCollection.Add(new clsParameter("@EmailId", txtEmail));
                return DataAccess.ExecuteSpAndGetDataTable(ParameterCollection);
            }
            catch (Exception Ex)
            {
                if (!Ex.Message.Contains("User Define:"))
                    BL_Exception.WriteLog(Ex);

                throw Ex;
            }
        }
コード例 #23
0
ファイル: BL_Sales.cs プロジェクト: har9421/BestSeller
        /// <summary>
        /// This method is used to get city's.
        /// </summary>
        /// <param name="StateID"></param>
        /// <returns></returns>
        public static DataTable FillCity(string StateID)
        {
            try
            {
                clsParameterCollection ParameterCollection = new clsParameterCollection();
                ParameterCollection.ProcedureName = "BS_ShowCity";
                ParameterCollection.Add(new clsParameter("@stateId", StateID));
                return DataAccess.ExecuteSpAndGetDataTable(ParameterCollection);
            }
            catch (Exception Ex)
            {
                if (!Ex.Message.Contains("User Define:"))
                    BL_Exception.WriteLog(Ex);

                throw Ex;
            }
        }
コード例 #24
0
ファイル: BL_Sales.cs プロジェクト: har9421/BestSeller
        /// <summary>
        /// This method is used to Get all sold voucher details.
        /// </summary>
        /// <returns></returns>
        public static DataTable GetSoldVouchers(string UserID)
        {
            try
            {
                clsParameterCollection ParameterCollection = new clsParameterCollection();
                ParameterCollection.ProcedureName = "BS_Sales_ShowVouchers";
                ParameterCollection.Add(new clsParameter("@UserID", UserID));
                return DataAccess.ExecuteSpAndGetDataTable(ParameterCollection);
            }
            catch (Exception Ex)
            {
                if (!Ex.Message.Contains("User Define:"))
                    BL_Exception.WriteLog(Ex);

                throw Ex;
            }
        }
コード例 #25
0
ファイル: BL_StateCity.cs プロジェクト: har9421/BestSeller
        public static void fnUpdateStateList(int Id)
        {
            try
            {
                clsParameterCollection ParameterCollection = new clsParameterCollection();
                ParameterCollection.ProcedureName = "GV_UpdateStateList";
                ParameterCollection.Add(new clsParameter("@StateId", Id));

                DataAccess.ExecuteNonQuerySp(ParameterCollection);
            }
            catch (Exception Ex)
            {
                if (!Ex.Message.Contains("User Define:"))
                    BL_Exception.WriteLog(Ex);
                throw Ex;
            }
        }
コード例 #26
0
ファイル: BL_InwardStore.cs プロジェクト: har9421/BestSeller
        /// <summary>
        /// This Method is used to show all store list.
        /// </summary>
        /// <param name="Drp"></param>
        public static DataTable FillStoreCode()
        {
            try
            {
                clsParameterCollection objStore = new clsParameterCollection();
                objStore.ProcedureName = "BS_InwardAtStore_FillStoreList";
                return DataAccess.ExecuteSpAndGetDataTable(objStore);
            }
            catch (Exception Ex)
            {
                if (!Ex.Message.Contains("User Define:"))
                    BL_Exception.WriteLog(Ex);

                throw Ex;
            }

        }
コード例 #27
0
        /// <summary>
        /// This method is used to get all store codes.
        /// </summary>
        /// <returns></returns>
        public static DataTable GetStoreCdoes(string LoginUserStore)
        {
            try
            {
                clsParameterCollection ParameterCollection = new clsParameterCollection();
                ParameterCollection.ProcedureName = "BS_StoreAllocation_FillStoreList";
                ParameterCollection.Add(new clsParameter("@StoreCode", LoginUserStore));
                return DataAccess.ExecuteSpAndGetDataTable(ParameterCollection);
            }
            catch (Exception Ex)
            {
                if (!Ex.Message.Contains("User Define:"))
                    BL_Exception.WriteLog(Ex);

                throw Ex;
            }
        }
コード例 #28
0
 /// <summary>
 /// Fill DropDonw List
 /// </summary>
 /// <param name="Drp"></param>
 public static void FillDropDown(DropDownList Drp)
 {
     try
     {
         clsParameterCollection ParameterCollection = new clsParameterCollection();
         ParameterCollection.ProcedureName = "BS_VendorDiscount_FillVendorList";
         ParameterCollection.Add(new clsParameter("@StoreCode", 0));
         DataTable dt = DataAccess.ExecuteSpAndGetDataTable(ParameterCollection);
         DataAccess.FillDropDown(Drp, dt);
     }
     catch (Exception Ex)
     {
         if (!Ex.Message.Contains("User Define:"))
             BL_Exception.WriteLog(Ex);
         throw Ex;
     }
 }
コード例 #29
0
        /// <summary>
        /// This method is used to save received vouchers/booklets.
        /// </summary>
        public static void SaveReceivedVouchers(string UserID)
        {
            try
            {
                clsParameterCollection ParameterCollection = new clsParameterCollection();
                ParameterCollection.ProcedureName = "BS_ReceivedatHO_ADDVoucher";
                ParameterCollection.ParaCollection.Add(new clsParameter("@UserID", UserID));
                DataAccess.ExecuteNonQuerySp(ParameterCollection);
            }
            catch (Exception Ex)
            {
                if (!Ex.Message.Contains("User Define:"))
                    BL_Exception.WriteLog(Ex);

                throw Ex;
            }
        }
コード例 #30
0
ファイル: BL_Account.cs プロジェクト: har9421/Vishwapress
 /// <summary>
 /// This Method is used to Check that partucular role has permisions assigned or not (Validation on ManagePermissions View on Assign button and Remove nutton click)
 /// </summary>
 /// <param name="RoleName"></param>
 /// <param name="ViewName"></param>
 /// <returns></returns>
 public DataTable checkPermissionForRole(string RoleName,string ViewName)
 {
     try
     {
         clsParameterCollection clsParaCollection = new clsParameterCollection();
         clsParaCollection.ProcedureName = Constants.sp_checkPermissionForRole;
         clsParaCollection.Add(new clsParameter { ParameterName="@RoleName",ParameterValue=RoleName});
         clsParaCollection.Add(new clsParameter { ParameterName="@ViewName",ParameterValue=ViewName});
         dt = DataAccess.ExecuteSpAndGetDataTable(clsParaCollection);
         return dt;
     }
     catch (Exception ex)
     {
         BL_Exception.WriteLog(ex);
         throw ex;
     }
 }