コード例 #1
0
        public DataSet GetSocialCategoryViewReport(LDMFunSchema objLDMFuncSchema)
        {
            SqlConnection objConn = SQLHelper.OpenConnection();

            try
            {
                SqlParameter[] param = new SqlParameter[4];
                param[0]       = new SqlParameter("@Districtid", SqlDbType.Int);
                param[0].Value = objLDMFuncSchema.Districtid;

                param[1]       = new SqlParameter("@ShiLoanCategory", SqlDbType.VarChar);
                param[1].Value = objLDMFuncSchema.ShiLoanCategory;

                param[2]       = new SqlParameter("@KisLoanCategory", SqlDbType.VarChar);
                param[2].Value = objLDMFuncSchema.KisLoanCategory;

                param[3]       = new SqlParameter("@TarLoanCategory", SqlDbType.VarChar);
                param[3].Value = objLDMFuncSchema.TarLoanCategory;

                using (DataSet ds = SQLHelper.ExecuteDataset(objConn, null, CommandType.StoredProcedure, "rep_CategoryLevelReport", param))
                {
                    return(ds);
                }
            }
            catch (Exception)
            {
                return(null);
            }
            finally
            {
                SQLHelper.CloseConnection(objConn);
            }
        }
コード例 #2
0
ファイル: BannerDAL.cs プロジェクト: barzar90/PMMYA
        public DataSet GetKeyPersonDetails(BannerControlSchema objBannerControlSchema)
        {
            SqlConnection objConn = SQLHelper.OpenConnection();

            try
            {
                SqlParameter[] param = new SqlParameter[2];
                param[0]       = new SqlParameter("@FileType", SqlDbType.VarChar);
                param[0].Value = objBannerControlSchema.FileType;
                param[1]       = new SqlParameter("@LangType", SqlDbType.VarChar);
                param[1].Value = objBannerControlSchema.LangType;

                using (DataSet ds = SQLHelper.ExecuteDataset(objConn, null, CommandType.StoredProcedure, "UspKeyPerson", param))
                {
                    return(ds);
                }
            }
            catch (Exception ex)
            {
                return(null);
            }
            finally
            {
                SQLHelper.CloseConnection(objConn);
            }
        }
コード例 #3
0
ファイル: BannerDAL.cs プロジェクト: barzar90/PMMYA
        public DataSet GetNews(BannerControlSchema objBannerControlSchema)
        {
            SqlConnection objConn = SQLHelper.OpenConnection();

            try
            {
                SqlParameter[] param = new SqlParameter[2];
                param[0]       = new SqlParameter("@NewsCount", SqlDbType.Int);
                param[0].Value = objBannerControlSchema.NewsCount;
                param[1]       = new SqlParameter("@LangId", SqlDbType.Int);
                param[1].Value = objBannerControlSchema.LangId;

                using (DataSet ds = SQLHelper.ExecuteDataset(objConn, null, CommandType.StoredProcedure, "UspNewsControl", param))
                {
                    return(ds);
                }
            }
            catch (Exception ex)
            {
                return(null);
            }
            finally
            {
                SQLHelper.CloseConnection(objConn);
            }
        }
コード例 #4
0
        public void InsertSMSLog(string MobileNo, string Status, string ServerResponse, string Error)
        {
            try
            {
                SqlConnection objConn = SQLHelper.OpenConnection();
                try
                {
                    SqlParameter[] param = new SqlParameter[4];
                    param[0]       = new SqlParameter("@MobileNo", SqlDbType.VarChar);
                    param[0].Value = MobileNo;
                    param[1]       = new SqlParameter("@Status", SqlDbType.VarChar);
                    param[1].Value = Status;
                    param[2]       = new SqlParameter("@ServerResponse", SqlDbType.VarChar);
                    param[2].Value = ServerResponse;
                    param[3]       = new SqlParameter("@ErrorText", SqlDbType.VarChar);
                    param[3].Value = Error;

                    SQLHelper.ExecuteNonQuery(objConn, null, CommandType.StoredProcedure, "Usp_InsertSMSLog", param);
                }
                catch (Exception ex)
                {
                }
                finally
                {
                    SQLHelper.CloseConnection(objConn);
                }
            }
            catch (Exception)
            {
                throw;
            }
        }
コード例 #5
0
        public DataSet GetCMSMoreDetails(CMSSchema objCMSSchema)
        {
            SqlConnection objConn = SQLHelper.OpenConnection();

            try
            {
                SqlParameter[] param = new SqlParameter[3];

                param[0]       = new SqlParameter("@MenuID", SqlDbType.Int);
                param[0].Value = objCMSSchema.MenuID;
                param[1]       = new SqlParameter("@LangType", SqlDbType.VarChar);
                param[1].Value = objCMSSchema.LangType;
                param[2]       = new SqlParameter("@isQuickMenu", SqlDbType.Bit);
                param[2].Value = objCMSSchema.IsQuickMenu;
                param[3]       = new SqlParameter("@MenuContentID", SqlDbType.Int);
                param[3].Value = objCMSSchema.MenucontentID;

                using (DataSet ds = SQLHelper.ExecuteDataset(objConn, null, CommandType.StoredProcedure, "Usp_GetCMSMoreControl", param))
                {
                    return(ds);
                }
            }
            catch (Exception ex)
            {
                return(null);
            }
            finally
            {
                SQLHelper.CloseConnection(objConn);
            }
        }
コード例 #6
0
        public DataTable FillVideoGrid(int Langid, string title, string filetype)
        {
            try
            {
                conn = SQLHelper.OpenConnection();
                SqlParameter[] cmdParameter = new SqlParameter[3];
                cmdParameter[0]       = new SqlParameter("@Langid", SqlDbType.Int);
                cmdParameter[0].Value = Langid;
                cmdParameter[1]       = new SqlParameter("@Title", SqlDbType.NVarChar);
                cmdParameter[1].Value = title;
                cmdParameter[2]       = new SqlParameter("@FileType", SqlDbType.VarChar);
                cmdParameter[2].Value = filetype;

                sqlQuery = "Select * from Video where Langid=@Langid and VideoName like '%' + @Title + '%'  and Type like '%' + @FileType + '%' order by LastUpdated desc";
                //sqlQuery = "Select * from Video where Langid=@Langid and VideoName like '%" + title + "%' order by VIdeoName";
                ds = SQLHelper.ExecuteDataset(conn, null, CommandType.Text, sqlQuery, cmdParameter);
                return(ds.Tables[0]);
            }
            catch (Exception)
            {
                return(null);
            }
            finally
            {
                ds = null;
                SQLHelper.CloseConnection(conn);
            }
        }
コード例 #7
0
        public DataTable ViewAudioList(UploadVideoSchema UploadVideo_Schema)
        {
            try
            {
                conn = SQLHelper.OpenConnection();
                SqlParameter[] cmdParameter = new SqlParameter[2];
                cmdParameter[0]       = new SqlParameter("@Langid", SqlDbType.Int);
                cmdParameter[0].Value = UploadVideo_Schema.langid;
                cmdParameter[1]       = new SqlParameter("@Keyword", SqlDbType.NVarChar);
                cmdParameter[1].Value = UploadVideo_Schema.Keyword;

                sqlQuery  = "Select VideoID, VideoName, VideoPath, Description as AudioDesc from Video where Type='Audio' and Langid=@Langid ";
                sqlQuery += " and ((VideoName like '%' + @Keyword + '%') or (Description like '%' + @Keyword + '%') or @Keyword='') ";
                sqlQuery += " order by VideoName";
                ds        = SQLHelper.ExecuteDataset(conn, null, CommandType.Text, sqlQuery, cmdParameter);
                return(ds.Tables[0]);
            }
            catch (Exception)
            {
                return(null);
            }
            finally
            {
                ds = null;
                SQLHelper.CloseConnection(conn);
            }
        }
コード例 #8
0
        public DataSet GetPressNewsAlbumdetails(AlbumSchema objAlbumSchema)
        {
            SqlConnection objConn = SQLHelper.OpenConnection();

            try
            {
                SqlParameter[] param = new SqlParameter[2];
                param[0]       = new SqlParameter("@Type", SqlDbType.VarChar);
                param[0].Value = objAlbumSchema.Type;
                param[1]       = new SqlParameter("@AlbumName ", SqlDbType.VarChar);
                param[1].Value = objAlbumSchema.AlbumName;

                using (DataSet ds = SQLHelper.ExecuteDataset(objConn, null, CommandType.StoredProcedure, "Usp_GetAlbumForPressNews", param))
                {
                    return(ds);
                }
            }
            catch (Exception ex)
            {
                return(null);
            }
            finally
            {
                SQLHelper.CloseConnection(objConn);
            }
        }
コード例 #9
0
        public DataSet GetAlbumDetails(AlbumSchema objAlbumSchema)
        {
            SqlConnection objConn = SQLHelper.OpenConnection();

            try
            {
                var param = new SqlParameter[]
                {
                    new SqlParameter("@ActionType", objAlbumSchema.Actiontype == null ? (object)DBNull.Value : objAlbumSchema.Actiontype),
                    new SqlParameter("@AlbumID", Convert.ToInt32(objAlbumSchema.AlbumID) == 0 ? 0 : Convert.ToInt32(objAlbumSchema.AlbumID)),
                    new SqlParameter("@PhotoSubAlbumID", objAlbumSchema.PhotoSubAlbumID == 0 ? 0 : objAlbumSchema.PhotoSubAlbumID),
                    new SqlParameter("@Name", objAlbumSchema.Name == null ? (object)DBNull.Value : objAlbumSchema.Name)
                };

                using (DataSet ds = SQLHelper.ExecuteDataset(objConn, null, CommandType.StoredProcedure, "Usp_GetAlbumDetails", param))
                {
                    return(ds);
                }
            }
            catch (Exception ex)
            {
                return(null);
            }
            finally
            {
                SQLHelper.CloseConnection(objConn);
            }
        }
コード例 #10
0
ファイル: EmailDAL.cs プロジェクト: barzar90/PMMYA
        public DataSet GetEmailDetails(EmailSchema ObjEmailSchema)
        {
            SqlConnection objConn = SQLHelper.OpenConnection();

            try
            {
                SqlParameter[] param = new SqlParameter[1];

                param[0]       = new SqlParameter("@ApplicationID", SqlDbType.VarChar);
                param[0].Value = ObjEmailSchema.ApplicationID;

                using (DataSet ds = SQLHelper.ExecuteDataset(objConn, null, CommandType.StoredProcedure, "Usp_GetEmailIDDetails", param))
                {
                    return(ds);
                }
            }
            catch (Exception ex)
            {
                return(null);
            }
            finally
            {
                SQLHelper.CloseConnection(objConn);
            }
        }
コード例 #11
0
ファイル: ViewPhotoAlbumDAL.cs プロジェクト: barzar90/PMMYA
        public DataSet CheckValidAlbum(ViewPhotoAlbumSchema objviewPhotoAlbumSchema)
        {
            SqlConnection objConn = SQLHelper.OpenConnection();

            try
            {
                var param = new SqlParameter[]
                {
                    new SqlParameter("@ActionType", objviewPhotoAlbumSchema.ActionType == null ? (object)DBNull.Value : objviewPhotoAlbumSchema.ActionType),
                    new SqlParameter("@PhotoAlbumID", objviewPhotoAlbumSchema.Photoalbumid == 0 ? 0 : objviewPhotoAlbumSchema.Photoalbumid),
                    new SqlParameter("@Name", objviewPhotoAlbumSchema.Name == null ? (object)DBNull.Value : objviewPhotoAlbumSchema.Name)
                };
                using (DataSet ds = SQLHelper.ExecuteDataset(objConn, null, CommandType.StoredProcedure, "Usp_CheckValidAlbum", null))
                {
                    return(ds);
                }
            }
            catch (Exception ex)
            {
                return(null);
            }
            finally
            {
                SQLHelper.CloseConnection(objConn);
            }
        }
コード例 #12
0
        public DataSet GetGridViewData(LDMFunSchema objLDMFuncSchema)
        {
            SqlConnection objConn = SQLHelper.OpenConnection();

            try
            {
                SqlParameter[] param = new SqlParameter[1];

                param[0]       = new SqlParameter("@Districtid", SqlDbType.Int);
                param[0].Value = objLDMFuncSchema.Districtid;

                using (DataSet ds = SQLHelper.ExecuteDataset(objConn, null, CommandType.StoredProcedure, "GetGridViewData", param))
                {
                    return(ds);
                }
            }
            catch (Exception)
            {
                return(null);
            }
            finally
            {
                SQLHelper.CloseConnection(objConn);
            }
        }
コード例 #13
0
        public DataSet SelectApplicationForm(string spAction, string appId, string status)
        {
            SqlConnection objConn = SQLHelper.OpenConnection();

            try
            {
                SqlParameter[] param = new SqlParameter[3];
                param[0]       = new SqlParameter("@Status", SqlDbType.VarChar);
                param[0].Value = status;
                param[1]       = new SqlParameter("@ApplicationID", SqlDbType.VarChar);
                param[1].Value = appId;
                param[2]       = new SqlParameter("@ActionType", SqlDbType.VarChar);
                param[2].Value = spAction;
                using (DataSet ds = SQLHelper.ExecuteDataset(objConn, null, CommandType.StoredProcedure, "getFormApplicationDetails", param))
                {
                    return(ds);
                }
            }
            catch (Exception ex)
            {
                return(null);
            }
            finally
            {
                SQLHelper.CloseConnection(objConn);
            }
        }
コード例 #14
0
        //Ldm Application Form
        public DataSet GetApplicationForm(LDMFunSchema objLDMFuncSchema)
        {
            SqlConnection objConn = SQLHelper.OpenConnection();

            try
            {
                SqlParameter[] param = new SqlParameter[3];
                param[0]       = new SqlParameter("@Status", SqlDbType.VarChar);
                param[0].Value = objLDMFuncSchema.Status;
                param[1]       = new SqlParameter("@ApplicationID", SqlDbType.VarChar);
                param[1].Value = objLDMFuncSchema.ApplicationID;
                param[2]       = new SqlParameter("@ActionType", SqlDbType.VarChar);
                param[2].Value = objLDMFuncSchema.ActionType;
                using (DataSet ds = SQLHelper.ExecuteDataset(objConn, null, CommandType.StoredProcedure, "getFormApplicationDetails"))
                {
                    return(ds);
                }
            }
            catch (Exception ex)
            {
                return(null);
            }
            finally
            {
                SQLHelper.CloseConnection(objConn);
            }
        }
コード例 #15
0
        public Int64 DeleteVideo(String VideoID)
        {
            try
            {
                conn    = SQLHelper.OpenConnection();
                objtran = conn.BeginTransaction();

                SqlParameter[] cmdParameters = new SqlParameter[1];
                cmdParameters[0]       = new SqlParameter("@VideoID", SqlDbType.BigInt);
                cmdParameters[0].Value = VideoID;
                intCount = SQLHelper.ExecuteNonQuery(conn, objtran, CommandType.Text, "Delete from Video where VideoID=@VideoID", cmdParameters);
                objtran.Commit();
                return(intCount);
            }
            catch (Exception)
            {
                objtran.Rollback();
                return(0);
            }
            finally
            {
                SQLHelper.CloseConnection(conn);
                intCount = 0;
            }
        }
コード例 #16
0
        public DataSet GetViewAlbum(AlbumSchema objAlbumSchema)
        {
            SqlConnection objConn = SQLHelper.OpenConnection();

            try
            {
                SqlParameter[] param = new SqlParameter[4];
                param[0]       = new SqlParameter("@ActionType", SqlDbType.VarChar);
                param[0].Value = objAlbumSchema.Actiontype;
                param[1]       = new SqlParameter("@PhotoType", SqlDbType.VarChar);
                param[1].Value = objAlbumSchema.PhotoType;
                param[2]       = new SqlParameter("@PhotoAlbumID", SqlDbType.Int);
                param[2].Value = objAlbumSchema.PhotoAlbumID;
                param[3]       = new SqlParameter("@PhotoSubAlbumID", SqlDbType.Int);
                param[3].Value = objAlbumSchema.PhotoSubAlbumID;

                using (DataSet ds = SQLHelper.ExecuteDataset(objConn, null, CommandType.StoredProcedure, "Usp_GetViewAlbum", param))
                {
                    return(ds);
                }
            }
            catch (Exception ex)
            {
                return(null);
            }
            finally
            {
                SQLHelper.CloseConnection(objConn);
            }
        }
コード例 #17
0
        public Int64 DeleteVideoRecord(UploadVideoSchema objUploadVideoSchema)
        {
            try
            {
                conn    = SQLHelper.OpenConnection();
                objtran = conn.BeginTransaction();

                SqlParameter[] cmdParameters = new SqlParameter[3];
                cmdParameters[0]       = new SqlParameter("@VideoID", SqlDbType.BigInt);
                cmdParameters[0].Value = objUploadVideoSchema.VideoID;
                cmdParameters[1]       = new SqlParameter("@CreatedBy", SqlDbType.UniqueIdentifier);
                cmdParameters[1].Value = objUploadVideoSchema.CreatedBy;
                cmdParameters[2]       = new SqlParameter("@IPAddress", SqlDbType.NVarChar);
                cmdParameters[2].Value = objUploadVideoSchema.IPAddress;

                intCount = SQLHelper.ExecuteNonQuery(conn, objtran, CommandType.StoredProcedure, "spDeleteVideo", cmdParameters);
                objtran.Commit();
                return(intCount);
            }
            catch (Exception)
            {
                objtran.Rollback();
                return(0);
            }
            finally
            {
                SQLHelper.CloseConnection(conn);
                intCount = 0;
            }
        }
コード例 #18
0
        public DataSet GetUploadPDFDetails(UploadDocumentSchema objUploadDocumentSchema)
        {
            SqlConnection objConn = SQLHelper.OpenConnection();

            try
            {
                var param = new SqlParameter[]
                {
                    new SqlParameter("@ActionType", objUploadDocumentSchema.Actiontype == null ? (object)DBNull.Value : objUploadDocumentSchema.Actiontype),
                    new SqlParameter("@EnumerationValueID", objUploadDocumentSchema.Enumarationvalueid == null ? (object)DBNull.Value : objUploadDocumentSchema.Enumarationvalueid),
                    new SqlParameter("@DocumentType", objUploadDocumentSchema.Documenttype == null ? (object)DBNull.Value : objUploadDocumentSchema.Documenttype),
                    new SqlParameter("@chkArchive", objUploadDocumentSchema.ChkArchive == false ? Convert.ToBoolean(0) : objUploadDocumentSchema.ChkArchive),
                    new SqlParameter("@parent_EnumerationValueID", objUploadDocumentSchema.Parent_Enumarationvalueid == null ? (object)DBNull.Value : objUploadDocumentSchema.Parent_Enumarationvalueid),
                    new SqlParameter("@DocumentID", objUploadDocumentSchema.Documentid == null ? (object)DBNull.Value : objUploadDocumentSchema.Documentid)
                };

                using (DataSet ds = SQLHelper.ExecuteDataset(objConn, null, CommandType.StoredProcedure, "Usp_UploadPDF", param))
                {
                    return(ds);
                }
            }
            catch (Exception ex)
            {
                return(null);
            }
            finally
            {
                SQLHelper.CloseConnection(objConn);
            }
        }
コード例 #19
0
        public DataTable FillVideoGridpager(int Langid, string title, string filetype, int PageSize, int PageIndex)
        {
            try
            {
                conn = SQLHelper.OpenConnection();
                SqlParameter[] cmdParameter = new SqlParameter[5];
                cmdParameter[0]       = new SqlParameter("@Langid", SqlDbType.Int);
                cmdParameter[0].Value = Langid;
                cmdParameter[1]       = new SqlParameter("@Title", SqlDbType.NVarChar);
                cmdParameter[1].Value = title;
                cmdParameter[2]       = new SqlParameter("@FileType", SqlDbType.VarChar);
                cmdParameter[2].Value = filetype;
                cmdParameter[3]       = new SqlParameter("@PageSize", SqlDbType.Int);
                cmdParameter[3].Value = PageSize;
                cmdParameter[4]       = new SqlParameter("@PageIndex", SqlDbType.Int);
                cmdParameter[4].Value = PageIndex;

                ds = SQLHelper.ExecuteDataset(conn, null, CommandType.StoredProcedure, "spSearchVideo", cmdParameter);
                return(ds.Tables[0]);
            }
            catch (Exception)
            {
                return(null);
            }
            finally
            {
                ds = null;
                SQLHelper.CloseConnection(conn);
            }
        }
コード例 #20
0
ファイル: LoginDAL.cs プロジェクト: barzar90/PMMYA
        //added Mahesh Patel on 27-12-2018
        public int GetUserPasswordLDM(LoginSchema objLoginSchema)
        {
            try
            {
                ds = new DataSet();
                int password;
                login_conn = new SqlConnection();
                login_conn = SQLHelper.OpenConnection();

                SqlParameter[] _param = new SqlParameter[1];
                _param[0]       = new SqlParameter("@UserName", SqlDbType.VarChar);
                _param[0].Value = objLoginSchema.UserName;
                _param[0].Size  = 50;

                SqlCommand command = new SqlCommand();

                command.CommandText    = "[uspGetUserLDMPassword]";
                command.CommandTimeout = 5000;
                command.CommandType    = CommandType.StoredProcedure;

                password = Convert.ToInt32(HelperCls.ExecuteScalar(login_conn, null, command.CommandType, command.CommandText, _param));

                return(password);
            }
            catch (Exception ex)
            {
                throw ex;
            }
            finally
            {
                SQLHelper.CloseConnection(login_conn);

                login_conn.Dispose();
            }
        }
コード例 #21
0
        //DataSet ds;
        #endregion


        public DataSet SearchDetails(SearchSchema objSearchSchema)
        {
            SqlConnection objConn = SQLHelper.OpenConnection();

            try
            {
                var param = new SqlParameter[]
                {
                    new SqlParameter("@LangID", objSearchSchema.LangID == 0 ? 0  : objSearchSchema.LangID),
                    new SqlParameter("@Keyword", objSearchSchema.Keyword == null ? (object)DBNull.Value : objSearchSchema.Keyword),
                };

                using (DataSet ds = SQLHelper.ExecuteDataset(objConn, null, CommandType.StoredProcedure, "spSearchSite", param))
                {
                    return(ds);
                }
            }
            catch (Exception ex)
            {
                return(null);
            }
            finally
            {
                SQLHelper.CloseConnection(objConn);
            }
        }
コード例 #22
0
ファイル: MenuDAL.cs プロジェクト: barzar90/PMMYA
        public DataSet GetMenuListDetails(MenuSchema objmenuschema)
        {
            SqlConnection objConn = SQLHelper.OpenConnection();

            try
            {
                SqlParameter[] param = new SqlParameter[3];

                param[0]       = new SqlParameter("@ActionType", SqlDbType.VarChar);
                param[0].Value = objmenuschema.ActionType;
                param[1]       = new SqlParameter("@MenuID", SqlDbType.Int);
                param[1].Value = objmenuschema.Menuid;
                param[2]       = new SqlParameter("@MenuCategory", SqlDbType.VarChar);
                param[2].Value = objmenuschema.MenuCategory;
                using (DataSet ds = SQLHelper.ExecuteDataset(objConn, null, CommandType.StoredProcedure, "UspGetMenuListDetails", param))
                {
                    return(ds);
                }
            }
            catch (Exception ex)
            {
                return(null);
            }
            finally
            {
                SQLHelper.CloseConnection(objConn);
            }
        }
コード例 #23
0
ファイル: FeedbackDAL.cs プロジェクト: barzar90/PMMYA
        public DataSet GetDPOEmail(FeddbackSchema objFeedback_Schema)
        {
            SqlConnection objConn = SQLHelper.OpenConnection();

            try
            {
                SqlParameter[] param = new SqlParameter[1];

                param[0]       = new SqlParameter("@DistrictId", SqlDbType.Int);
                param[0].Value = objFeedback_Schema.Districtid;

                using (DataSet ds = SQLHelper.ExecuteDataset(objConn, null, CommandType.StoredProcedure, "usp_GetDPOEmail", param))
                {
                    return(ds);
                }
            }
            catch (Exception ex)
            {
                return(null);
            }
            finally
            {
                SQLHelper.CloseConnection(objConn);
            }
        }
コード例 #24
0
ファイル: MenuDAL.cs プロジェクト: barzar90/PMMYA
        public DataSet GetParentList()
        {
            SqlConnection objConn = SQLHelper.OpenConnection();

            try
            {
                SqlParameter[] param = new SqlParameter[1];

                param[0]       = new SqlParameter("@MenuType", SqlDbType.VarChar);
                param[0].Value = "BindParent";

                using (DataSet ds = SQLHelper.ExecuteDataset(objConn, null, CommandType.StoredProcedure, "UspGetMenuDetails", param))
                {
                    return(ds);
                }
            }
            catch (Exception ex)
            {
                return(null);
            }
            finally
            {
                SQLHelper.CloseConnection(objConn);
            }
        }
コード例 #25
0
        public DataSet GetLeftMenuDetails(CMSSchema objCMSSchema)
        {
            SqlConnection objConn = SQLHelper.OpenConnection();

            try
            {
                SqlParameter[] param = new SqlParameter[1];

                param[0]       = new SqlParameter("@MenuID", SqlDbType.Int);
                param[0].Value = objCMSSchema.MenuID;

                using (DataSet ds = SQLHelper.ExecuteDataset(objConn, null, CommandType.StoredProcedure, "Usp_GetLeftMenu", param))
                {
                    return(ds);
                }
            }
            catch (Exception ex)
            {
                return(null);
            }
            finally
            {
                SQLHelper.CloseConnection(objConn);
            }
        }
コード例 #26
0
ファイル: MenuDAL.cs プロジェクト: barzar90/PMMYA
        public DataSet GetPageUrl(MenuSchema objmenuschema)
        {
            SqlConnection objConn = SQLHelper.OpenConnection();

            try
            {
                SqlParameter[] param = new SqlParameter[2];

                param[0]       = new SqlParameter("@MenuType", SqlDbType.VarChar);
                param[0].Value = "GetPageUrl";
                param[1]       = new SqlParameter("@RowID", SqlDbType.Int);
                param[1].Value = objmenuschema.Rowid;

                using (DataSet ds = SQLHelper.ExecuteDataset(objConn, null, CommandType.StoredProcedure, "UspGetMenuDetails", param))
                {
                    return(ds);
                }
            }
            catch (Exception ex)
            {
                return(null);
            }
            finally
            {
                SQLHelper.CloseConnection(objConn);
            }
        }
コード例 #27
0
ファイル: BannerDAL.cs プロジェクト: barzar90/PMMYA
        public DataSet GetLastReviewDate(BannerControlSchema objBannerControlSchema)
        {
            SqlConnection objConn = SQLHelper.OpenConnection();

            try
            {
                SqlParameter[] param = new SqlParameter[2];
                param[0]       = new SqlParameter("@ContentID", SqlDbType.Int);
                param[0].Value = objBannerControlSchema.ContentID;
                param[1]       = new SqlParameter("@MenuID", SqlDbType.Int);
                param[1].Value = objBannerControlSchema.MenuID;

                using (DataSet ds = SQLHelper.ExecuteDataset(objConn, null, CommandType.StoredProcedure, "Usp_LastReviewDateControl", param))
                {
                    return(ds);
                }
            }
            catch (Exception ex)
            {
                return(null);
            }
            finally
            {
                SQLHelper.CloseConnection(objConn);
            }
        }
コード例 #28
0
        public DataSet GetNews(UploadNewsSchema obuploadnewsschema)
        {
            SqlConnection objConn = SQLHelper.OpenConnection();

            try
            {
                var param = new SqlParameter[]
                {
                    new SqlParameter("@Para", obuploadnewsschema.Para == null ? (object)DBNull.Value : obuploadnewsschema.Para),
                    new SqlParameter("@Search", obuploadnewsschema.Search == null ? (object)DBNull.Value : obuploadnewsschema.Search),
                };

                using (DataSet ds = SQLHelper.ExecuteDataset(objConn, null, CommandType.StoredProcedure, "usp_Getnews", param))
                {
                    return(ds);
                }
            }
            catch (Exception ex)
            {
                return(null);
            }
            finally
            {
                SQLHelper.CloseConnection(objConn);
            }
        }
コード例 #29
0
        public DataSet GetDetails(LoanApplicatinFormSchema objLoanApplicatinFormSchema)
        {
            SqlConnection objConn = SQLHelper.OpenConnection();

            try
            {
                var param = new SqlParameter[]
                {
                    new SqlParameter("@Application_ID", objLoanApplicatinFormSchema.Application_ID),
                };

                using (DataSet ds = SQLHelper.ExecuteDataset(objConn, null, CommandType.StoredProcedure, "SP_GetdetailsfromPMMY_APP_LOAN_FORM", param))
                {
                    return(ds);
                }
            }
            catch (Exception ex)
            {
                return(null);
            }
            finally
            {
                SQLHelper.CloseConnection(objConn);
            }
        }
コード例 #30
0
        //Get Social Category
        public DataSet GetAllCategory(string CategoryName)
        {
            SqlConnection objConn = SQLHelper.OpenConnection();

            try
            {
                SqlParameter[] param = new SqlParameter[1];
                param[0] = new SqlParameter("@CategoryName", SqlDbType.VarChar)
                {
                    Value = CategoryName
                };
                using (DataSet ds = SQLHelper.ExecuteDataset(objConn, null, CommandType.StoredProcedure, "getAllSocialCategory", param))
                {
                    return(ds);
                }
            }
            catch (Exception)
            {
                return(null);
            }
            finally
            {
                SQLHelper.CloseConnection(objConn);
            }
        }