示例#1
0
    private void u_init()
    {
        string     sql  = "select rdn,tableName1 from jci_tableList order by sortid asc";
        SqlConnect conn = new SqlConnect();

        //DataTable dt = conn.ExcuteSelect(sql);
        conn.DropDownListBind(sql, typeList);
        //typeList.SelectedIndex = typeList.Items.Count;
    }
示例#2
0
    private void u_init(string sqlWhere)
    {
        string     sql  = "select top 1000 * from dbo.JCI_patient_brifeInfo where 1=1 " + sqlWhere + " order by rdn DESC";
        SqlConnect conn = new SqlConnect();
        DataTable  dt   = conn.ExcuteSelect(sql);

        rpt_patient.DataSource = dt;
        rpt_patient.DataBind();

        sql = "select code,name from JCI_patient_dic where dicType='科室' order by orderNum ASC ";
        conn.DropDownListBind(sql, ddl_dept);

        sql = "select code,name from JCI_patient_dic where dicType='楼层' order by orderNum ASC ";
        conn.DropDownListBind(sql, ddl_floor);

        DataTable dt1 = new DataTable();

        dt1.Columns.Add("code");
        dt1.Columns.Add("name");
        dt1.Rows.Add("医疗", "医疗");
        dt1.Rows.Add("护理", "护理");
        dt1.Rows.Add("医技", "医技");
        dt1.Rows.Add("后勤", "后勤");
        dt1.Rows.Add("行政-收费", "行政-收费");

        ddl_category1.DataSource     = dt1;
        ddl_category1.DataValueField = "code";
        ddl_category1.DataTextField  = "name";
        ddl_category1.DataBind();

        ddl_category2.DataSource     = dt1;
        ddl_category2.DataValueField = "code";
        ddl_category2.DataTextField  = "name";
        ddl_category2.DataBind();
        //added by Chunhui Chen 2014-05-18
        DateTime now = new DateTime(DateTime.Now.Year, DateTime.Now.Month, 1);

        tbox_beginDate.Text = now.ToString("yyyy-MM-dd");
        tbox_endDate.Text   = now.AddMonths(1).AddDays(-1).ToString("yyyy-MM-dd");
    }
示例#3
0
    protected void Page_Load(object sender, EventArgs e)
    {
        if (IsPostBack)
        {
            return;
        }

        //if (Session["power"] == null) Response.Redirect("../Default.aspx");
        //if (!srrshPage.Level2(Session["power"].ToString())) Response.Redirect("../Err/powerNeed.aspx");//没权限
        //Added by Chunhui Chen 2014-04-29
        initUser();

        SqlConnect conn = new SqlConnect();
        string     sql  = "select * from JCI_generateTable where tablerdn=12 order by largeItemRdn ASC, SortId ASC";

        conn.gv_bind(sql, GridView1);

        sql = "select code,name from JCI_patient_dic where dicType='科室' order by orderNum ASC ";
        conn.DropDownListBind(sql, ddl_dept);

        sql = "select code,name from JCI_patient_dic where dicType='楼层' order by orderNum ASC ";
        conn.DropDownListBind(sql, ddl_floor);
        tbox_reportDate.Text = DateTime.Now.ToString("yyyy-MM-dd");
    }