modiZHPJ.aspx.cs 2.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647
  1. using System;
  2. using System.Collections.Generic;
  3. using System.Linq;
  4. using System.Web;
  5. using System.Web.UI;
  6. using System.Web.UI.WebControls;
  7. public partial class modiZHPJ : System.Web.UI.Page
  8. {
  9. LYS.UserData1 myud = new LYS.UserData1();
  10. protected void Page_Load(object sender, EventArgs e)
  11. {
  12. int ID = Convert.ToInt16(Request.QueryString["ID"].ToString());
  13. string myURL = myud.GetAddressUrl().ToString();
  14. if (myURL.LastIndexOf("ID") < 0)
  15. {
  16. Response.Write("<script>alert('错误!参数不正确!不能正常显示')</script>");
  17. Response.End();
  18. }
  19. if (!IsPostBack)
  20. {
  21. ZJ.Text = Convert.ToDateTime(myud.GetFieldValueFromFieldName("听课日期", ID, "TKJL").ToString()).ToShortDateString();
  22. TextBox1.Text=myud.GetFieldValueFromFieldName("督导姓名", ID, "TKJL").ToString();
  23. DD.Text = myud.GetFieldValueFromFieldName("上课地点", ID, "TKJL").ToString();
  24. JSXM.Text = myud.GetFieldValueFromFieldName("教师姓名", ID, "TKJL").ToString();
  25. XB.Text = myud.GetFieldValueFromFieldName("系部", ID, "TKJL").ToString();
  26. KM.Text = myud.GetFieldValueFromFieldName("课程名", ID, "TKJL").ToString();
  27. BJ.Text = myud.GetFieldValueFromFieldName("班级", ID, "TKJL").ToString();
  28. XQ.Text = myud.GetFieldValueFromFieldName("星期", ID, "TKJL").ToString();
  29. JC.Text = myud.GetFieldValueFromFieldName("节次", ID, "TKJL").ToString();
  30. PF.Text = myud.GetFieldValueFromFieldName("总评分", ID, "TKJL").ToString();
  31. PJ.Text = myud.GetFieldValueFromFieldName("点评评价", ID, "TKJL").ToString();
  32. ZHPJ.Text = myud.GetFieldValueFromFieldName("综合评价", ID, "TKJL").ToString();
  33. }
  34. }
  35. protected void Button1_Click(object sender, EventArgs e)
  36. {
  37. int ID = Convert.ToInt16(Request.QueryString["ID"].ToString());
  38. string sql1 = "select * from TKJL where id=" + Convert.ToInt16(Request.QueryString["ID"].ToString());
  39. myud.UpdateStringFieldValue("TKJL", "综合评价", ZHPJ.Text, ID);
  40. Response.Write("<script>alert('修改成功!!')</script>");
  41. }
  42. }