protected void Page_Load(object sender, EventArgs e) { if (Session["UserID"] == null || string.IsNullOrWhiteSpace(Session["UserID"].ToString())) { Response.Redirect("~/Account/Login.aspx"); } mc = new ManageClass(); ////t = new Core.Tools(); wc = new WorkClass(); uc = new UserClass(); sc = new ScheduleClass(); if (uc.GetUserType(int.Parse(Session["UserID"].ToString())) != 1) { Response.Redirect("~/Account/Login.aspx"); } if (!IsPostBack) { SqlDataSource1.SelectParameters["年份"].DefaultValue = DateTime.Now.Year.ToString(); DropDownListWork.DataBind(); //TextBoxSchedule.Text = @"3月:沟通台商和青房意见,加快启动筹备; // 4月 - 5月:台方进入青岛,项目开办公司成立。 //6月:确定业态、主题定位、设计方案,招商签约发包。 //7 - 8月:青房完成综合验收,具备交付条件。双方就租赁面积等合作细节、装修等达成一致。 //9 - 10月:签订合同,启动装修,研究税收扶持政策。 //11月:落实燃气管道、扶梯、货梯等物业条件。 //12月:围绕文创、休闲、旅游、美食、购物等招商。 //"; } }
//protected Core.Tools t; protected void Page_Load(object sender, EventArgs e) { if (Session["UserID"] == null || string.IsNullOrWhiteSpace(Session["UserID"].ToString())) { Response.Redirect("~/Account/Login.aspx"); } mc = new ManageClass(); //t = new Core.Tools(); uc = new UserClass(); wc = new WorkClass(); if (uc.GetUserType(int.Parse(Session["UserID"].ToString())) != 1) { Response.Redirect("~/Account/Login.aspx"); } if (!IsPostBack) { SqlDataSource1.SelectParameters["年份"].DefaultValue = DateTime.Now.Year.ToString(); DropDownListWork.DataBind(); } //protected void Button1_Click(object sender, EventArgs e) //{ // //Response.Write("yy"); //} }
protected void Delete_Click(object sender, EventArgs e) { bool result = mc.DeleteWork(Guid.Parse(DropDownListWork.SelectedValue)); if (result) { LabelResult.Text = "第" + (DropDownListWork.SelectedIndex + 1) + "项工作已删除"; } else { LabelResult.Text = "删除失败"; } DropDownListWork.DataBind(); }