Example #1
0
        protected void Page_Load(object sender, EventArgs e)
        {
            hkdb.VeriSess("4");

            if (!IsPostBack)
            {
                hkdb.PassTo("10306", "0");
                qy_fjylurl.Text = Convert.ToString(SqlHelper.ExecuteScalar("SELECT qy_fjylurl FROM qy WHERE qy_id='001'"));

                //dp绑定
                SqlDataReader datar = SqlHelper.ExecuteReader("select  A.*,B.mc from OA_RWD01 A LEFT OUTER JOIN hk_ZDYLX B ON(A.RWXZ=B.ID) where A.rwid='" + hkdb.GetStr(Request.QueryString["rwid"].ToString()) + "'");
                if (datar.Read())
                {
                    rwly.Text    = datar["source"].ToString();
                    rwidstr.Text = datar["rwid"].ToString();
                    rwdh.Text    = datar["rwdh"].ToString();
                    lbljjcd.Text = datar["jjcd"].ToString();
                    lblrwxz.Text = datar["mc"].ToString();
                    lbljsdx.Text = Convert.ToString(SqlHelper.ExecuteScalar("exec sp_IdToName '" + datar["jsdx"].ToString() + "','1'"));
                    qtld.Text    = Convert.ToString(SqlHelper.ExecuteScalar("exec sp_IdToName '" + datar["qtld"].ToString() + "','1'"));
                    zrld.Text    = Convert.ToString(SqlHelper.ExecuteScalar("exec sp_IdToName '" + datar["zrld"].ToString() + "','1'"));
                    zrr.Text     = Convert.ToString(SqlHelper.ExecuteScalar("exec sp_IdToName '" + datar["zrr"].ToString() + "','1'"));
                    lblnr.Text   = hkdb.GetStrTeOut(datar["rwnr"].ToString());
                    lblynxs.Text = datar["ynxs"].ToString();
                    lblksrq.Text = datar["ksrq"].ToString();
                    lbljzrq.Text = datar["jzrq"].ToString();

                    if (datar["ynxs"].ToString() == "是")
                    {
                        Panelrq.Visible = true;
                    }

                    lblrwbt.Text       = datar["rwbt"].ToString();
                    fqsj.Text          = string.Format("{0:d}", datar["fbsj"]);
                    savefj.Text        = datar["fjmc"].ToString();
                    savelj.Text        = datar["fjlj"].ToString();
                    savefj.NavigateUrl = (datar["fjlj"] == System.DBNull.Value ? "" : "../.." + datar["fjlj"]) + datar["fjmc"].ToString();

                    datar.Close();
                }
                else
                {
                    datar.Close();
                    mydb.Alert_Close("此记录不存在,可能已被删除!");
                }
            }

            //页面绑定
            GridViewBind();
        }
Example #2
0
        protected void Page_Load(object sender, EventArgs e)
        {
            hkdb.VeriSess("4");

            if (!IsPostBack)
            {
                hkdb.PassTo("11802", "0");

                BindAttr();

                //dp绑定
                DropDownListBind();
            }
        }
Example #3
0
        protected void Page_Load(object sender, EventArgs e)
        {
            mydb hkdb = new mydb();

            hkdb.VeriSess("3");

            if (!IsPostBack)
            {
                hkdb.PassTo("12104", "12104");
            }

            lbldt.Text = null;
            int glTMP1 = 0, glTMP2 = 0;

            this.lbldt.Text += "<table width=\"100%\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\">";
            this.lbldt.Text += "";
            SqlDataReader datar = SqlHelper.ExecuteReader("select * from OA_KlClass order by id desc");

            while (datar.Read())
            {
                this.lbldt.Text += "<tr><td><table align=\"center\" border=\"0\" cellpadding=\"0\"  cellspacing=\"0\" width=\"100%\"><tr> <td  height=\"26px\"><table  height=\"26\" border=\"0\" cellpadding=\"0\" cellspacing=\"0\" > <tr><td  height=\"26px\" width=\"17px\" ></td> <td valign=\"bottom\" ><font color=\"black\">" + datar["Name"] + "</font>&nbsp;</td></tr></table></td></tr></table></tr></td>";
                glTMP2           = 0;
                SqlDataReader dr = SqlHelper.ExecuteReader("select * from OA_KlClassSub where BigId='" + datar["id"] + "' and ((CHARINDEX('," + this.Session["userid"].ToString() + ",',','+SyUsername+',') > 0 ) or SyUsername='******' ) order by id desc");
                this.lbldt.Text += "<tr><td><table width=\"100%\" border=\"0\" cellspacing=\"0\" cellpadding=\"4\"> <tr align=\"left\"> ";
                while (dr.Read())
                {
                    this.lbldt.Text += "<td width=\"25%\"><a href=zsdtlb.aspx?LittleId=" + dr["id"] + "><img src=\"../../images/oa/zsk.gif\" width=\"16\" height=\"16\" border=0/><font color=\"#3366ff\">" + dr["Name"] + "</font></td>";
                    glTMP2           = glTMP2 + 1;
                    if (glTMP2 == 4)
                    {
                        lbldt.Text += "</tr><tr align=\"left\"> ";
                        glTMP2      = 0;
                    }
                }
                dr.Close();
                lbldt.Text += " </table>";

                this.lbldt.Text += "<table align=\"center\" background=\"../../images/bg_l.gif\" border=\"0\" cellpadding=\"0\"  cellspacing=\"0\" width=\"100%\"><tr> <td  height=\"5px\"></td></tr></table>";

                this.lbldt.Text += "</td>";
                glTMP1           = glTMP1 + 1;
                if (glTMP1 == 1)
                {
                    lbldt.Text += "</tr>";
                    glTMP1      = 0;
                }
            }
            this.lbldt.Text += " </table>";
            datar.Close();
        }
Example #4
0
        protected void Page_Load(object sender, EventArgs e)
        {
            hkdb.VeriSess("3");

            if (!IsPostBack)
            {
                hkdb.PassTo("13803", "13803");


                //页面绑定
                GridViewBind();
                GridViewBind2();
            }
        }
Example #5
0
        protected void Page_Load(object sender, EventArgs e)
        {
            hkdb.VeriSess("3");

            if (!IsPostBack)
            {
                hkdb.PassTo("60105", "60105");

                panel2.Visible = false;
                @add.Text      = "增 加";
            }

            GridViewBind();
        }
Example #6
0
        public void Page_Load(object Sender, EventArgs E)
        {
            hkdb.VeriSess("4");

            if (!IsPostBack)
            {
                hkdb.PassTo("81106", "0");

                //附件
                attKey = this.Session["fjlx"].ToString();

                BindAttr();

                Random g   = new Random();
                string rad = g.Next(10000).ToString();
                Number.Text = "" + System.DateTime.Now.Year.ToString() + "" + System.DateTime.Now.Month.ToString() + "" + System.DateTime.Now.Day.ToString() + "" + System.DateTime.Now.Hour.ToString() + "" + System.DateTime.Now.Minute.ToString() + "" + System.DateTime.Now.Second.ToString() + "" + System.DateTime.Now.Millisecond.ToString() + "" + rad + "";

                if (!string.IsNullOrEmpty(Request.QueryString["kpid"]))
                {
                    lblname.Text = SqlHelper.ExecuteScalar("SELECT UI_DESC FROM YH WHERE UI_ID='" + hkdb.GetStr(Request.QueryString["bid"].ToString()) + "'").ToString();

                    //判断重复
                    string sql = "SELECT kpzt FROM HR_Kpdf_Kpxm01 WHERE kpid='" + hkdb.GetStr(Request.QueryString["kpid"].ToString()) + "' and kpzt='未生效'";
                    if (bd.CheckRepeat(sql) == "true")
                    {
                        uploadBtn.Visible = true;
                        AttDelBtn.Visible = true;
                        SaveBtn.Visible   = true;
                    }

                    SqlDataReader dr = SqlHelper.ExecuteReader("SELECT A.* FROM HR_Kpdf_Kpxm03 A WHERE sskpid='" + hkdb.GetStr(Request.QueryString["kpid"].ToString()) + "' AND ssbid='" + hkdb.GetStr(Request.QueryString["bid"].ToString()) + "'");
                    if (dr.Read())
                    {
                        lbltitle.Text = "修改";

                        if (!string.IsNullOrEmpty(dr["kpfj"].ToString()))
                        {
                            Number.Text = dr["kpfj"].ToString();
                        }
                    }
                    else
                    {
                        lbltitle.Text = "新增";
                    }
                    dr.Close();
                }
            }

            BindDpList();
        }
Example #7
0
        protected void Page_Load(object sender, EventArgs e)
        {
            hkdb.VeriSess("3");

            if (!IsPostBack)
            {
                hkdb.PassTo("10203", "10203");

                AspNetPager1.PageSize = int.Parse(Request.Cookies["haoke"].Values["pagecount"]);
            }

            //页面绑定
            GridViewBind();
        }
Example #8
0
        protected void Page_Load(object sender, EventArgs e)
        {
            hkdb.VeriSess("4");

            if (!IsPostBack)
            {
                hkdb.PassTo("10509", "0");

                DropDownListBind_sjbm();

                //参数判断
                if (!string.IsNullOrEmpty(Request.QueryString["id"]))
                {
                    lbltitle.Text = "修改";
                    SqlDataReader datar = SqlHelper.ExecuteReader("select * from oa_hys where hys_id='" + hkdb.GetStr(Request.QueryString["id"].ToString()) + "'");
                    if (datar.Read())
                    {
                        mc.Text            = datar["hys_mc"].ToString();
                        ssbm.SelectedValue = datar["hys_ssbm"].ToString();
                        gmrl.Text          = datar["hys_gmrl"].ToString();
                        glry.SelectedValue = datar["hys_fzr"].ToString();
                        lxdh.Text          = datar["hys_lxdh"].ToString();
                        jj.Text            = datar["hys_jj"].ToString();

                        if (datar["hys_fwy"].ToString() == "有")
                        {
                            fwy.Checked = true;
                        }
                        else
                        {
                            fwy.Checked = false;
                        }
                        datar.Close();
                        //Init
                        DelBtn.Visible = true;
                    }
                    else
                    {
                        datar.Close();
                        mydb.Alert_Close("此记录不存在,可能已被删除!");
                    }
                }
                else
                {
                    lbltitle.Text      = "新增";
                    SaveAddBtn.Visible = true;
                }
            }
        }
Example #9
0
        protected void Page_Load(object sender, EventArgs e)
        {
            hkdb.VeriSess("3");

            if (!IsPostBack)
            {
                hkdb.PassTo("13803", "13803");


                //页面绑定
                GridViewBind();
                GridViewBind2();
                num = AspNetPager1.RecordCount + AspNetPager2.RecordCount;
            }
        }
Example #10
0
        protected void Page_Load(object Sender, EventArgs E)
        {
            hkdb.VeriSess("3");

            if (!IsPostBack)
            {
                hkdb.PassTo("81103", "81103");

                DropDownListBind();

                AspNetPager1.PageSize = int.Parse(Request.Cookies["haoke"].Values["pagecount"]);

                GridViewBind();
            }
        }
Example #11
0
        protected void Page_Load(object sender, EventArgs e)
        {
            hkdb.VeriSess("4");

            if (!IsPostBack)
            {
                hkdb.PassTo("11402", "0");

                AspNetPager1.PageSize = int.Parse(Request.Cookies["haoke"].Values["pagecount"]);

                BindDplist();
            }

            GridviewBind();
        }
Example #12
0
        protected void Page_Load(object sender, EventArgs e)
        {
            hkdb.VeriSess("4");

            if (!IsPostBack)
            {
                hkdb.PassTo("11304", "0");

                OperQx();

                DropDownListBind();

                lblAttachSize.Text = Convert.ToString(SqlHelper.ExecuteScalar("SELECT P_STRING FROM hk_CSDA WHERE PARAMT='P_fj_size'"));
            }
        }
Example #13
0
        protected void Page_Load(object sender, EventArgs e)
        {
            hkdb.VeriSess("4");

            if (!IsPostBack)
            {
                hkdb.PassTo("11002", "0");

                OperQx();

                zymc.Text = Request.QueryString["mc"].ToString() + " " + Request.QueryString["sd"].ToString() + "至" + Request.QueryString["ed"].ToString();
            }

            GridViewBind();
        }
Example #14
0
        protected void Page_Load(object sender, EventArgs e)
        {
            mydb hkdb = new mydb();

            hkdb.VeriSess("3");

            if (!IsPostBack)
            {
                hkdb.PassTo("10102,1002", "0");

                AspNetPager1.PageSize = int.Parse(Request.Cookies["haoke"].Values["pagecount"]);

                GridViewBind();
            }
        }
Example #15
0
        protected void Page_Load(object sender, EventArgs e)
        {
            hkdb.VeriSess("4");

            if (!IsPostBack)
            {
                hkdb.PassTo("11702", "0");

                //参数判断
                if (!string.IsNullOrEmpty(Request.QueryString["id"]))
                {
                    lbltitle.Text = "修改";
                    SqlDataReader datar = SqlHelper.ExecuteReader("select * from OA_KHDA01 where khid='" + hkdb.GetStr(Request.QueryString["id"].ToString()) + "'");
                    if (datar.Read())
                    {
                        gmr.Text   = datar["gmr"].ToString();
                        sf.Text    = datar["sf"].ToString();
                        cs.Text    = datar["cs"].ToString();
                        gmrdh.Text = datar["gmrdh"].ToString();
                        gmrdw.Text = datar["gmrdw"].ToString();
                        gmrbs.Text = datar["gmrbs"].ToString();
                        gmrzw.Text = datar["gmrzw"].ToString();
                        gmrq.Text  = string.Format("{0:d}", datar["gmrq"]);
                        spmc.Text  = datar["spmc"].ToString();
                        gmsl.Text  = datar["gmsl"].ToString();
                        email.Text = datar["email"].ToString();
                        yzdz.Text  = datar["yzdz"].ToString();
                        gmbz.Text  = datar["gmbz"].ToString();
                        syr.Text   = datar["syr"].ToString();
                        syrdh.Text = datar["syrdh"].ToString();
                        syrdz.Text = datar["syrdz"].ToString();
                        syrdw.Text = datar["syrdw"].ToString();
                        sjzg.Text  = datar["sjzg"].ToString();
                        sybz.Text  = datar["sybz"].ToString();

                        RBL1hfqk.SelectedValue = datar["hfqk1"].ToString();
                        RBL2hfqk.SelectedValue = datar["hfqk2"].ToString();
                        RBL3hfqk.SelectedValue = datar["hfqk3"].ToString();
                        datar.Close();
                    }
                    else
                    {
                        datar.Close();
                        mydb.Alert("此记录不存在,可能已被删除!");
                    }
                }
            }
        }
Example #16
0
        protected void Page_Load(object sender, EventArgs e)
        {
            hkdb.VeriSess("4");

            if (!IsPostBack)
            {
                hkdb.PassTo("10111", "0");

                BindAttr();

                DropDownListBind();
                //dp绑定

                //Random f = new Random();
                //string sjs = f.Next(10000).ToString();
                //Number.Text = "" + System.DateTime.Now.Year.ToString() + "" + System.DateTime.Now.Month.ToString() + "" + System.DateTime.Now.Day.ToString() + "" + System.DateTime.Now.Hour.ToString() + "" + System.DateTime.Now.Minute.ToString() + "" + System.DateTime.Now.Second.ToString() + "" + System.DateTime.Now.Millisecond.ToString() + "" + sjs + "";

                if (!IsPostBack)
                {
                    SqlDataReader datar = SqlHelper.ExecuteReader("select *  from OA_KnowLedge where ID='" + hkdb.GetStr(Request.QueryString["id"].ToString()) + "'");
                    if (datar.Read())
                    {
                        BigName.SelectedValue = datar["Bigid"].ToString();
                        //知识小类
                        LittleName.Items.Clear();

                        string sql_LittleName = "select ID,Name from OA_KlClassSub  where BigId='" + BigName.SelectedValue + "' order by ID";
                        bd.Bind_DropDownList(LittleName, sql_LittleName, "ID", "Name", "", "");


                        TitleName.Text           = datar["Title"].ToString();
                        Content.Text             = datar["Content"].ToString();
                        AthourSay.Text           = datar["AthourSay"].ToString();
                        KeyWord.Text             = datar["KeyWord"].ToString();
                        UserName.Text            = datar["QxYdRealname"].ToString();
                        UserID.Text              = datar["QxYdUsername"].ToString();
                        LittleName.SelectedValue = datar["LittleId"].ToString();
                        Number.Text              = datar["Number"].ToString();
                        datar.Close();
                    }
                    else
                    {
                        datar.Close();
                        mydb.Alert_Close("此记录不存在,可能已被删除!");
                    }
                }
            }
        }
Example #17
0
        protected void Page_Load(object sender, EventArgs e)
        {
            mydb hkdb = new mydb();

            hkdb.VeriSess("4");

            if (!IsPostBack)
            {
                hkdb.PassTo("10111", "0");

                if (!string.IsNullOrEmpty(Request.QueryString["id"]))
                {
                    SqlDataReader datar = SqlHelper.ExecuteReader("select * from OA_KlChap where id='" + hkdb.GetStr(Request.QueryString["id"]) + "'");
                    if (datar.Read())
                    {
                        Name.Text   = datar["Name"].ToString();
                        lblnr.Text  = datar["Content"].ToString();
                        Number.Text = datar["Number"].ToString();

                        SqlDataReader datar1 = SqlHelper.ExecuteReader("select  * from OA_KlChapAtt where KeyField='" + hkdb.GetStr(Number.Text) + "' order by id desc");

                        this.fjlb.Text = null;
                        int i = 0;
                        this.fjlb.Text += "<table width=100% border=0 cellspacing=0 cellpadding=4>";
                        this.fjlb.Text += "<tr>";
                        while (datar1.Read())
                        {
                            this.fjlb.Text += " <td width=100% >·<a href=zszj_down.aspx?number=" + datar1["NewName"].ToString() + "  target=_blank>" + datar1["Name"].ToString() + "</a></td>";

                            i = i + 1;
                            if (i == 1)
                            {
                                fjlb.Text += "</tr><TR>";
                                i          = 0;
                            }
                        }
                        this.fjlb.Text += " </table>";
                        datar1.Close();
                        datar.Close();
                    }
                    else
                    {
                        datar.Close();
                        mydb.Alert_Close("此记录不存在,可能已被删除!");
                    }
                }
            }
        }
Example #18
0
        protected void Page_Load(object sender, EventArgs e)
        {
            hkdb.VeriSess("4");

            if (!IsPostBack)
            {
                hkdb.PassTo("11102", "0");

                DropDownListBind_fl();
                qy_fjylurl.Text = Convert.ToString(SqlHelper.ExecuteScalar("SELECT qy_fjylurl FROM qy WHERE qy_id='001'"));

                lblAttachSize.Text = Convert.ToString(SqlHelper.ExecuteScalar("SELECT P_STRING FROM hk_CSDA WHERE PARAMT='P_fj_size'"));

                //短信
                dxtz.Visible = Convert.ToBoolean(hkdb.VeriSms());

                if (!string.IsNullOrEmpty(Request.QueryString["id"]))
                {
                    lbltitle.Text = "修改";
                    SqlDataReader datar = SqlHelper.ExecuteReader("select * from OA_XWNR where xwid='" + hkdb.GetStr(Request.QueryString["id"].ToString()) + "' and zt='草稿'");
                    if (datar.Read())
                    {
                        xwbt.Text          = datar["xwbt"].ToString();
                        xwzy.Text          = datar["xwzy"].ToString();
                        xwly.Text          = datar["xwly"].ToString();
                        xwfl.SelectedValue = datar["fl"].ToString();
                        xwzz.Text          = datar["xwzz"].ToString();
                        editor.Value       = datar["xwnr"].ToString();
                        xwsj.Text          = hkdb.GetDate(datar["xwsj"].ToString());
                        savefj.Text        = datar["fjmc"].ToString();
                        savelj.Text        = datar["fjlj"].ToString();
                        savefj.NavigateUrl = (datar["fjlj"] == System.DBNull.Value ? "" : "../.." + datar["fjlj"].ToString()) + datar["fjmc"].ToString();

                        datar.Close();
                    }
                    else
                    {
                        datar.Close();
                        mydb.Alert_Close("此记录不存在,可能已被删除!");
                    }
                }
                else
                {
                    lbltitle.Text   = "新增";
                    SendBtn.Enabled = false;
                }
            }
        }
Example #19
0
        protected void Page_Load(object sender, EventArgs e)
        {
            hkdb.VeriSess("4");

            if (!IsPostBack)
            {
                hkdb.PassTo("10108", "0");

                //短信
                dxtz.Visible = Convert.ToBoolean(hkdb.VeriSms());

                DropDownListBind();

                sqbm.SelectedValue = this.Session["deptid"].ToString();
            }
        }
Example #20
0
        protected void Page_Load(object sender, EventArgs e)
        {
            hkdb.VeriSess("4");

            if (!IsPostBack)
            {
                hkdb.PassTo("10301", "0");

                DropDownListBind();

                lblAttachSize.Text = Convert.ToString(SqlHelper.ExecuteScalar("SELECT P_STRING FROM hk_CSDA WHERE PARAMT='P_fj_size'"));

                ynxs.Checked    = false;
                Panelrq.Visible = false;
            }
        }
Example #21
0
        protected void Page_Load(object sender, EventArgs e)
        {
            hkdb.VeriSess("4");

            if (!IsPostBack)
            {
                hkdb.PassTo("10107", "0");

                DropDownListBind();
                qy_fjylurl.Text = Convert.ToString(SqlHelper.ExecuteScalar("SELECT qy_fjylurl FROM qy WHERE qy_id='001'"));

                lblAttachSize.Text = Convert.ToString(SqlHelper.ExecuteScalar("SELECT P_STRING FROM hk_CSDA WHERE PARAMT='P_fj_size'"));

                GridViewBind();
            }
        }
Example #22
0
        protected void Page_Load(object sender, EventArgs e)
        {
            hkdb.VeriSess("3");

            SqlHelper.ExecuteSql("DELETE FROM hk_Work WHERE wStatus='等待送审' AND PromoterID='" + this.Session["UserID"].ToString() + "'");

            if (!IsPostBack)
            {
                hkdb.PassTo("11404", "11404");

                AspNetPager1.PageSize = int.Parse(Request.Cookies["haoke"].Values["pagecount"]);

                BindDplist();
                DataBindToGridview(CreateMidSql());
            }
        }
Example #23
0
        protected void Page_Load(object sender, EventArgs e)
        {
            hkdb.VeriSess("4");

            if (!IsPostBack)
            {
                hkdb.PassTo("10505", "0");
                qy_fjylurl.Text = Convert.ToString(SqlHelper.ExecuteScalar("SELECT qy_fjylurl FROM qy WHERE qy_id='001'"));

                //短信
                dxtz.Visible = Convert.ToBoolean(hkdb.VeriSms());
                GridViewBind();

                SpBtn.Enabled = false;
            }
        }
Example #24
0
        protected void Page_Load(object sender, EventArgs e)
        {
            mydb hkdb = new mydb();

            hkdb.VeriSess("3");

            if (!IsPostBack)
            {
                hkdb.PassTo("10108", "10108");

                dropdownlistBind();
            }

            GridViewBindzy();
            GridViewBindcl();
        }
Example #25
0
        protected void Page_Load(object sender, EventArgs e)
        {
            hkdb.VeriSess("4");

            if (!IsPostBack)
            {
                hkdb.PassTo("81109", "0");

                //短信
                dxtx.Visible = Convert.ToBoolean(hkdb.VeriSms());

                lblcbry.Text = SqlHelper.ExecuteScalar("SELECT PWXM FROM HR_Kpdf_Pw WHERE PID='" + hkdb.GetStr(Request.QueryString["bid"]) + "'").ToString();

                txnr.Text = "关于【" + SqlHelper.ExecuteScalar("SELECT KPQS FROM HR_Kpdf_Kpxm01 WHERE KPID='" + hkdb.GetStr(Request.QueryString["kpid"]) + "'").ToString() + "】的绩效考评项目,请您尽快完成评分,谢谢!";
            }
        }
Example #26
0
        protected void Page_Load(object sender, EventArgs e)
        {
            mydb hkdb = new mydb();

            hkdb.VeriSess("3");

            if (!IsPostBack)
            {
                hkdb.PassTo("10508", "10508");

                string UserJqm = Dns.GetHostName();
                string UserIp  = Request.UserHostAddress;
                ipdz.Text = UserIp;
                jqm.Text  = UserJqm;
            }
        }
Example #27
0
        protected void Page_Load(object Sender, EventArgs E)
        {
            hkdb.VeriSess("4");

            if (!IsPostBack)
            {
                hkdb.PassTo("81103", "0");

                BindAttr();

                if (!string.IsNullOrEmpty(Request.QueryString["id"]))
                {
                    lbltitle.Text = "修改";

                    if (!string.IsNullOrEmpty(Request.QueryString["id"]))
                    {
                        SqlDataReader datar = SqlHelper.ExecuteReader("SELECT * FROM HR_Kpdf_Bkpr01 WHERE BID='" + hkdb.GetStr(Request.QueryString["id"].ToString()) + "'");
                        if (datar.Read())
                        {
                            bid.Text    = datar["bid"].ToString();
                            xm.Text     = datar["xm"].ToString();
                            bs.Text     = datar["bs"].ToString();
                            gw.Text     = datar["gw"].ToString();
                            fgzrid.Text = datar["fgzrid"].ToString();
                            fgzrmc.Text = datar["fgzrmc"].ToString();
                            bz.Text     = datar["bz"].ToString();
                            datar.Close();

                            //Init
                            DelBtn.Visible     = true;
                            SaveAddBtn.Visible = false;
                            img1.Visible       = false;
                        }
                        else
                        {
                            datar.Close();
                            mydb.Alert_Close("此记录不存在,可能已被删除!");
                        }
                    }
                }
                else
                {
                    lbltitle.Text      = "新增";
                    SaveAddBtn.Visible = true;
                }
            }
        }
Example #28
0
        protected void Page_Load(object sender, EventArgs e)
        {
            hkdb.VeriSess("4");

            if (!IsPostBack)
            {
                hkdb.PassTo("11301", "0");

                OperQx();

                //附件
                SqlDataReader dr_fj = SqlHelper.ExecuteReader("SELECT p_string FROM hk_CSDA WHERE paramt='P_AttType'");
                if (dr_fj.Read())
                {
                    attKey = dr_fj["p_string"].ToString();
                }
                dr_fj.Close();

                BindAttr();

                Random g   = new Random();
                string rad = g.Next(10000).ToString();
                fjNumber.Text = "" + System.DateTime.Now.Year.ToString() + "" + System.DateTime.Now.Month.ToString() + "" + System.DateTime.Now.Day.ToString() + "" + System.DateTime.Now.Hour.ToString() + "" + System.DateTime.Now.Minute.ToString() + "" + System.DateTime.Now.Second.ToString() + "" + System.DateTime.Now.Millisecond.ToString() + "" + rad + "";

                //使用范围
                if (this.Session["systype"].ToString() == "A")     //主登录页
                {
                    SqlDataReader datar1 = SqlHelper.ExecuteReader("SELECT xh FROM hk_Init WHERE produID IN('M','V','F')");
                    if (datar1.Read())
                    {
                        lx.Visible = true;
                    }
                    datar1.Close();
                }
                else  //子登录页
                {
                    if (this.Session["systype"].ToString() == "M" | this.Session["systype"].ToString() == "V" | this.Session["systype"].ToString() == "F")
                    {
                        lx.Visible = true;
                    }
                }

                DropDownListBind();
            }

            BindDpList();
        }
Example #29
0
        protected void Page_Load(object sender, EventArgs e)
        {
            hkdb.VeriSess("4");

            if (!IsPostBack)
            {
                hkdb.PassTo("11728", "0");

                if (!string.IsNullOrEmpty(Request.QueryString["id"]))
                {
                    SqlDataReader dr = SqlHelper.ExecuteReader("SELECT * from OA_KQ_QJD01 WHERE QID='" + hkdb.GetStr(Request.QueryString["id"].ToString()) + "'");
                    if (dr.Read())
                    {
                        qjlx.SelectedValue   = dr["qjlx"].ToString();
                        gjlb.SelectedValue   = dr["gjlb"].ToString();
                        qjkssj.Text          = hkdb.GetDate(dr["qjkssj"].ToString());
                        qjkssd.SelectedValue = dr["qjkssd"].ToString();
                        qjjssj.Text          = hkdb.GetDate(dr["qjjssj"].ToString());
                        qjjssd.SelectedValue = dr["qjjssd"].ToString();
                        qjts.Text            = dr["qjts"].ToString();
                        lblqjly.Text         = dr["qjly"].ToString();
                        lblgztzqk.Text       = dr["gztzqk"].ToString();
                        lblsqr.Text          = dr["sqrmc"].ToString();
                        lblsqbmmc.Text       = dr["sqbmmc"].ToString();
                        Number.Text          = dr["qjfj"].ToString();
                        bgyy.Text            = dr["bgyy"].ToString();
                        dr.Close();

                        if (qjlx.SelectedValue == "公假")
                        {
                            lblgjlb.Visible = true;
                            gjlb.Visible    = true;
                        }

                        bd.GetAtt(Number.Text, "o2", "oa/qjd", fujian);
                    }
                    else
                    {
                        dr.Close();
                    }
                }
                else
                {
                    mydb.Alert_Close("此记录不存在,可能已被删除!");
                }
            }
        }
Example #30
0
        protected void Page_Load(object sender, EventArgs e)
        {
            hkdb.VeriSess("3");

            if (!IsPostBack)
            {
                hkdb.PassTo("10301", "10301");

                //AspNetPager1.PageSize = int.Parse(Request.Cookies["haoke"].Values["pagecount"]);

                //短信
                dxtz.Visible = Convert.ToBoolean(hkdb.VeriSms());

                //页面绑定
                GridViewBind();
            }
        }