public DataTable LoadIVDetailsByCompanyName(RecruiterProfileBO ObjRecruiterProfileBO1)
        {
            ObjDatabaseObject.DBDataTable = new DataTable();

            ObjDatabaseObject.DBAdapter = new SqlDataAdapter();

            ObjDatabaseObject.DBAdapter.SelectCommand = new SqlCommand(@"uspLoadIVDetailsByCompanyName", ObjDatabaseObject.DBConnection);

            SqlParameter Param1 = new SqlParameter();
            Param1.ParameterName = "@CompanyName";
            Param1.Value = ObjRecruiterProfileBO1.CompanyName;

            ObjDatabaseObject.DBAdapter.SelectCommand.CommandType = CommandType.StoredProcedure;
            ObjDatabaseObject.DBAdapter.SelectCommand.Parameters.Add(Param1);
            ObjDatabaseObject.DBAdapter.Fill(ObjDatabaseObject.DBDataTable);

            return ObjDatabaseObject.DBDataTable;
        }
 public int UpdateRecruiterAddress(RecruiterProfileBO recruiterProfileBOObject)
 {
     return recruiterProfileBLLObject.UpdateRecruiterAddress(recruiterProfileBOObject);
 }
 public int UpdatePhoneNumber(RecruiterProfileBO recruiterProfileBOObject)
 {
     return recruiterProfileBLLObject.UpdatePhoneNumber(recruiterProfileBOObject);
 }
 public int UpdateEmailId(RecruiterProfileBO recruiterProfileBOObject)
 {
     return recruiterProfileBLLObject.UpdateEmailId(recruiterProfileBOObject);
 }
 public int InsertRecruitmentProfileDetails(RecruiterProfileBO recruiterProfile)
 {
     return recruiterProfileBLLObject.InsertRecruitmentProfileDetails(recruiterProfile);
 }
 public string GetUniqueCodeIfExists(RecruiterProfileBO recruiterProfileBOObject)
 {
     return recruiterProfileBLLObject.GetUniqueCodeIfExists(recruiterProfileBOObject);
 }
 public DataTable LoadIVDetailsByCompanyName(RecruiterProfileBO ObjRecruiterProfileBO1)
 {
     return ObjInterviewApprovalDAL.LoadIVDetailsByCompanyName(ObjRecruiterProfileBO1);
 }
        public string GetUniqueCodeIfExists(RecruiterProfileBO recruiterProfileBOObject)
        {
            string uniqueCodeExists = string.Empty;
            databaseObject.DBCommand = new SqlCommand();

            databaseObject.DBCommand.CommandText = @"uspGetUniqueCodeIfExists";
            databaseObject.DBCommand.CommandType = CommandType.StoredProcedure;

            SqlParameter param1 = new SqlParameter();
            param1.ParameterName = "@CompanyName";
            param1.Value = recruiterProfileBOObject.CompanyName;

            SqlParameter param2 = new SqlParameter();
            param2.ParameterName = "@RecruiterName";
            param2.Value = recruiterProfileBOObject.RecruiterName;

            try
            {
                databaseObject.DBCommand.Connection = databaseObject.DBConnection;

                databaseObject.DBConnection.Open();

                databaseObject.DBCommand.Parameters.Add(param1);
                databaseObject.DBCommand.Parameters.Add(param2);

                databaseObject.DBDataReader = databaseObject.DBCommand.ExecuteReader();

                if (databaseObject.DBDataReader.HasRows == true)
                {
                    while (databaseObject.DBDataReader.Read())
                    {
                        uniqueCodeExists = (databaseObject.DBDataReader[0].ToString());
                    }

                }
                else
                {
                }
            }
            catch (SqlException ex)
            {
                return ex.ErrorCode.ToString();

            }
            finally
            {
                databaseObject.DBConnection.Close();
            }

            return uniqueCodeExists;
        }
        public int UpdateRecruiterAddress(RecruiterProfileBO recruiterProfileBOObject1)
        {
            int queryStatus = 0;

            databaseObject.DBCommand = new SqlCommand();

            databaseObject.DBCommand.CommandText = @"uspUpdateAddress";
            databaseObject.DBCommand.CommandType = CommandType.StoredProcedure;

            SqlParameter param1 = new SqlParameter();
            param1.ParameterName = "@Address";
            param1.Value = recruiterProfileBOObject1.Address;

            SqlParameter param2 = new SqlParameter();
            param2.ParameterName = "@UniqueCode";
            param2.Value = recruiterProfileBOObject1.UniqueCode;

            try
            {
                databaseObject.DBCommand.Connection = databaseObject.DBConnection;

                databaseObject.DBConnection.Open();

                databaseObject.DBCommand.Parameters.Add(param1);
                databaseObject.DBCommand.Parameters.Add(param2);

                queryStatus = databaseObject.DBCommand.ExecuteNonQuery();

            }
            catch (SqlException ex)
            {
            }
            finally
            {
                databaseObject.DBConnection.Close();
            }
            return queryStatus;
        }
        public int InsertRecruitmentProfileDetails(RecruiterProfileBO recruiterProfile)
        {
            int queryStatus = 0;

            databaseObject.DBCommand = new SqlCommand();

            databaseObject.DBCommand.CommandText = @"uspInsertRecruiterProfile";
            databaseObject.DBCommand.CommandType = CommandType.StoredProcedure;

            databaseObject.DBDataTable = new DataTable();

            databaseObject.DBDataTable.Columns.Add("LoginId", typeof(long));
            databaseObject.DBDataTable.Columns.Add("RecruiterName", typeof(string));
            databaseObject.DBDataTable.Columns.Add("CompanyName", typeof(string));
            databaseObject.DBDataTable.Columns.Add("Address", typeof(string));
            databaseObject.DBDataTable.Columns.Add("Mail id", typeof(string));
            databaseObject.DBDataTable.Columns.Add("Phone", typeof(string));
            databaseObject.DBDataTable.Columns.Add("UniqueCode", typeof(string));

            databaseObject.DBDataTable.Rows.Add(recruiterProfile.LoginId, recruiterProfile.RecruiterName, recruiterProfile.CompanyName,
                                                recruiterProfile.Address, recruiterProfile.EmailId, recruiterProfile.Phone, recruiterProfile.UniqueCode);

            SqlParameter param1 = new SqlParameter();
            param1.ParameterName = "@RecruiterDetails";
            param1.Value = databaseObject.DBDataTable;

            param1.SqlDbType = SqlDbType.Structured;

            try
            {
                databaseObject.DBCommand.Connection = databaseObject.DBConnection;

                databaseObject.DBConnection.Open();

                databaseObject.DBCommand.Parameters.Add(param1);

                queryStatus=databaseObject.DBCommand.ExecuteNonQuery();

            }
            catch (SqlException ex)
            {
            }
            finally
            {
                databaseObject.DBConnection.Close();
            }

            return queryStatus;
        }
 public DataTable ViewPostsByCompanyName(RecruiterProfileBO ObjRecruiterProfileBO1)
 {
     return ObjJobPostingApprovalDAL.ViewPostsByCompanyName(ObjRecruiterProfileBO1);
 }
        public DataTable ViewPostsByCompanyName(RecruiterProfileBO ObjRecruiterProfileBO1)
        {
            ObjDatabaseObject.DBDataTable = new DataTable();

            ObjDatabaseObject.DBAdapter = new SqlDataAdapter();

            //ObjDatabaseObject.DBCommand = new SqlCommand(@"uspViewPostsByCompanyName", ObjDatabaseObject.DBConnection);

            ObjDatabaseObject.DBAdapter.SelectCommand = new SqlCommand(@"uspViewPostsByCompanyName", ObjDatabaseObject.DBConnection);

            ObjDatabaseObject.DBAdapter.SelectCommand.Parameters.Add(new SqlParameter("@CompanyName",ObjRecruiterProfileBO1.CompanyName));

            ObjDatabaseObject.DBAdapter.SelectCommand.CommandType= CommandType.StoredProcedure;

            ObjDatabaseObject.DBAdapter.Fill(ObjDatabaseObject.DBDataTable);

            return ObjDatabaseObject.DBDataTable;
        }