Ejemplo n.º 1
0
    protected void Page_Load(object sender, EventArgs e)
    {
        if (!Roles.IsUserInRole(ConfigurationManager.AppSettings["jobseekerrolename"]))
        {
            Response.Redirect("~/customerrorpages/NotAuthorized.aspx");
        }

        if (!Page.IsPostBack)
        {
            FillCountries();
            FillStates();
            lblJobCount.Text = "(Currently we have " + JobPosting.GetJobPostingCount() + " jobs!!!)";

            if (Request.QueryString["mysearchid"] != null)
            {
                MySearch s = MySearch.GetMySearch(int.Parse(Request.QueryString["mysearchid"]));
                txtSkills.Text           = s.Criteria;
                txtCity.Text             = s.City;
                ddlCountry.SelectedIndex = s.CountryID;
                FillStates();
                ListItem li = ddlState.Items.FindByValue(s.StateID.ToString());
                if (li != null)
                {
                    ddlState.ClearSelection();
                    li.Selected = true;
                }
            }
        }
    }
Ejemplo n.º 2
0
 protected void Page_Load(object sender, EventArgs e)
 {
     //获取公司总数
     lblCompanies.Text = Company.GetCompanyCount().ToString();
     //获取职位总数
     lblJobs.Text = JobPosting.GetJobPostingCount().ToString();
     //获取简历总数
     lblResumes.Text = Resume.GetResumeCount().ToString();
 }