CompanyStore.aspx.cs

(完整代码) 1KB

using System;
using System.Data;
using System.Configuration;
using System.Collections;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;

public partial class CompanyStore : System.Web.UI.Page
{
    public int RowNo = 0;
    protected void Page_Load(object sender, EventArgs e)
    {
        this.Title = "网上人才招聘系统";
        if (!IsPostBack)
        {
            Label1.Text = Session["UserName"].ToString();
            try
            {
                if ((Session["UserName"].ToString() != ""))
                {
                    Bind();
                }
            }
            catch
            {
                Response.Redirect("Error.aspx");
            }
        }

    }
    private void Bind()
    {
        DataSet ds = Hr.component.ApplyRecord.GetPersonByCompanyId(int.Parse(Session["UserId"].ToString()));
        Label1.Text = "所有的申请人:" + ds.Tables[0].Rows.Count.ToString();
        this.DataGrid1.DataSource = ds.Tables[0].DefaultView;
        this.DataGrid1.DataBind();
    }
    protected void DataGrid1_PageIndexChanged1(object source, DataGridPageChangedEventArgs e)
    {
        DataGrid1.CurrentPageIndex = e.NewPageIndex;
        Bind();
    }
    protected void DataGrid1_DeleteCommand1(object source, DataGridCommandEventArgs e)
    {
        try
        {
            int id = Convert.ToInt32(e.Item.Cells[0].Text);
            Hr.component.ApplyRecord.DeleteApplyRecordByID(id);
            Response.Redirect("CompanyStore.aspx");
        }
        catch
        {
            lblInfo.Text = "删除申请记录失败!";
        }
    }
}

24 小时内免费解锁 3 个项目,之后 1 算力/个。 规则说明

AI 解读 AI

登录后可用,每次 10 算力,解读结果公开显示在下面。

还没有人解读过这个文件。