计算机毕业设计订单模块介绍:
(三)订单信息列表
此模块可以查看定购鲜花的用户信息,及该用户定购鲜花的详细信息,并对订单中的鲜花同意预定。此时关联用户信息表和鲜花信息表。如图:
以下是引用片段:
相关代码如下: if (Session["User"].ToString() != "admin") { GridView1.DataSource = DataControl.GetDataTable("select * from XHDD where kh ='"+ Session["User"].ToString() +"'"); GridView1.DataBind(); this.GridView1.Columns[9].Visible = false; } else { GridView1.DataSource = DataControl.GetDataTable("select * from XHDD "); GridView1.DataBind(); } protected void Page_Load(object sender, EventArgs e) { if (!Page.IsPostBack) { //根据接收到的订单编号 查询 显示订单主表内容 DataTable tmpda = new DataTable(); tmpda = DataControl.GetDataTable("select * from XHDD where Ddbh='" + Session["bh"].ToString() + "'"); if (tmpda.Rows.Count > 0) { this.TextBox1.Text = tmpda.Rows[0]["Ddbh"].ToString(); this.TextBox2.Text = tmpda.Rows[0]["Kh"].ToString(); this.TextBox3.Text = tmpda.Rows[0]["Sl"].ToString(); this.TextBox4.Text = tmpda.Rows[0]["Je"].ToString(); this.TextBox5.Text = tmpda.Rows[0]["Fkzh"].ToString(); this.TextBox6.Text = tmpda.Rows[0]["Ddrq"].ToString(); if (tmpda.Rows[0]["Jkfs"].ToString() == "当面交款") { this.DropDownList1.SelectedIndex = 0; } else { this.DropDownList1.SelectedIndex = 1; } } //显示订单明细表内容 tmpda = DataControl.GetDataTable("select * from DDnr,Xhxx,Xhlx where ddnr.xhbh=xhxx.xhbh and xhxx.lxbh=xhlx.lxbh and Ddbh='" + Session["bh"].ToString() + "'"); this.GridView1.DataSource = tmpda; this.GridView1.DataBind(); //屏蔽相应按钮 if (Session["User"].ToString() != "admin") { this.Button1.Visible = false; } } }
|
〖资料来源:计算机毕业论文 www.xiaoniu168.com〗
第9页为计算机毕业论文用户注册功能介绍......