Esempio n. 1
0
    public void bindPagedata()
    {
        PMModel pIM = new PMModel();

        pIM = PMAction.GetSingleInfo(this.tpcode);
        this.TextBind(pIM);
    }
Esempio n. 2
0
 protected void Page_Load(object sender, System.EventArgs e)
 {
     base.Response.Cache.SetNoStore();
     if (!this.Page.IsPostBack)
     {
         PMModel pMModel = new PMModel();
         pMModel             = PMAction.GetSingleInfo(base.Request.QueryString["subpc"]);
         this.lbPrjName.Text = pMModel.PrjName;
         this.FillTrees1.Nodes.Clear();
         this.TVDept_AppendNodeFill();
     }
 }
Esempio n. 3
0
 protected void Page_Load(object sender, System.EventArgs e)
 {
     if (!this.Page.IsPostBack)
     {
         string sqlString = "select NoteID,CodeName from  dbo.XPM_Basic_CodeList where TypeID=146 and IsValid='true' and IsVisible='true'";
         System.Data.DataTable dataSource = publicDbOpClass.DataTableQuary(sqlString);
         this.ddlXmgroup.DataSource     = dataSource;
         this.ddlXmgroup.DataValueField = "NoteID";
         this.ddlXmgroup.DataTextField  = "CodeName";
         this.ddlXmgroup.DataBind();
         this.ddlXmgroup.Items.Insert(0, new ListItem("--请选择--", "-1"));
         this.txt_StartDate.Attributes["onactivate"] = "getBeginDate();";
         this.txt_EndDate.Attributes["onactivate"]   = "getEndDate();";
         this.Drop_QualityClass_Bind();
         this.Drop_PrjKindClass_Bind();
         this.ddt_Area_Bind();
         this.Drop_zzGrade_Bind();
         this.Drop_ysType_Bind();
         this.Drop_cbType_Bind();
         this.Drop_Payment_Bind();
         this.Drop_zbType_Bind();
         this.Drop_jsType_Bind();
         this.Drop_PrimaryGrade_Bind();
         this.Drop_jzType_Bind();
         if (base.Request.QueryString["TypeCode"] == null)
         {
             this.Page.RegisterStartupScript("warn", "<script language=\"JavaScript\">alert(\"参数不正确!\");window.close();</script>");
         }
         else
         {
             this.ViewState["TYPECODE"] = base.Request.QueryString["TypeCode"].ToString();
         }
         if (base.Request.QueryString["op"] == null)
         {
             this.Page.RegisterStartupScript("warn", "<script language=\"JavaScript\">alert(\"参数不正确!\");window.close();</script>");
         }
         else
         {
             this.ViewState["OP"] = base.Request.QueryString["op"].ToString();
         }
         string a;
         if ((a = this.ViewState["OP"].ToString().ToLower()) != null)
         {
             if (a == "add")
             {
                 this.txt_StartDate.Text   = System.DateTime.Now.ToString("yyyy-M-dd");
                 this.txt_EndDate.Text     = System.DateTime.Now.ToString("yyyy-M-dd");
                 base.Header.Title         = "添加资源分类";
                 this.tbxPreCode.Text      = this.ViewState["TYPECODE"].ToString();
                 this.tbxPreCode.ReadOnly  = true;
                 this.TxtTypeCode.ReadOnly = true;
                 if (this.ViewState["TYPECODE"].ToString().Trim() != "")
                 {
                     string text = PMAction.MakeClassCode(this.ViewState["TYPECODE"].ToString().Trim());
                     this.TxtTypeCode.Text = text.Substring(this.tbxPreCode.Text.Trim().Length, text.Length - this.tbxPreCode.Text.Trim().Length);
                 }
                 else
                 {
                     string text = PMAction.MakeClassCode("");
                     this.TxtTypeCode.Text = text;
                 }
                 this.hdfGuid.Value  = System.Guid.NewGuid().ToString();
                 this.FileLink1.MID  = 18;
                 this.FileLink1.FID  = this.hdfGuid.Value;
                 this.FileLink1.Type = 1;
                 return;
             }
             if (a == "upd")
             {
                 PMModel pIM = new PMModel();
                 pIM = PMAction.GetSingleInfo(this.ViewState["TYPECODE"].ToString());
                 this.TextBind(pIM);
                 base.Header.Title         = "更新资源分类";
                 this.tbxPreCode.Visible   = false;
                 this.TxtTypeCode.Columns  = 20;
                 this.TxtTypeCode.ReadOnly = true;
                 this.SetModuleState(this.ViewState["TYPECODE"].ToString());
                 this.FileLink1.MID  = 18;
                 this.FileLink1.FID  = this.hdfGuid.Value;
                 this.FileLink1.Type = 1;
                 return;
             }
         }
         this.Page.RegisterStartupScript("warn", "<script language=\"JavaScript\">alert(\"参数不正确!\");window.close();</script>");
     }
 }