private void BindGrid10() { string connectionString = ConfigurationManager.ConnectionStrings["ERPconnectionstring"].ToString(); Ede.Uof.Utility.Data.DatabaseHelper m_db = new Ede.Uof.Utility.Data.DatabaseHelper(connectionString); StringBuilder cmdTxt = new StringBuilder(); StringBuilder QUERYS = new StringBuilder(); cmdTxt.AppendFormat(@" SELECT [ID] ,[KINDS] ,[NAMES] ,[MOQS] ,[INDAYS] ,[COMMENTS] FROM [TKBUSINESS].[dbo].[TBPURMOQ] WHERE [KINDS]=@KINDS ORDER BY [ID] "); m_db.AddParameter("@KINDS", "OEM"); //m_db.AddParameter("@EDATE", EDATE); DataTable dt = new DataTable(); dt.Load(m_db.ExecuteReader(cmdTxt.ToString())); Grid10.DataSource = dt; Grid10.DataBind(); }
protected void Grid2_RowCommand(object sender, GridCommandEventArgs e) { if (e.CommandName == "Action1") { object[] keys = Grid2.DataKeys[e.RowIndex]; int ID = Convert.ToInt32(keys[0].ToString());//获取ID if (ID > 0 && ID != 9999) { List <School盘点人员进度> pdry = bll.查询盘点人员进度(ID); Grid10.DataSource = pdry;//DataTable Grid10.DataBind(); Window7.Hidden = false; } } else { } }
private void BindGrid10(string SDATE, string EDATE) { string connectionString = ConfigurationManager.ConnectionStrings["connectionstring"].ToString(); Ede.Uof.Utility.Data.DatabaseHelper m_db = new Ede.Uof.Utility.Data.DatabaseHelper(connectionString); string cmdTxt = @" SELECT [ORDERS],[USER_ID],[USER_NAME],[USER_ACCOUNT],[COMPANY_ID],[COMPANY_NAME],[ERPNO],NOTES FROM ( SELECT [ORDERS],[USER_ID],[USER_NAME],[USER_ACCOUNT],[COMPANY_ID],[COMPANY_NAME],[ERPNO] ,(SELECT COUNT([tb_NOTE].[COMPANY_ID]) FROM [HJ_BM_DB].[dbo].[tb_NOTE] WHERE [tb_NOTE].COMPANY_ID=[tb_COMPANY].COMPANY_ID AND [OWNER_ID]=[USER_ID] AND CONVERT(nvarchar,[tb_NOTE].[CREATE_DATETIME],111)>=@SDATE AND CONVERT(nvarchar,[tb_NOTE].[CREATE_DATETIME],111)<=@EDATE) AS 'NOTES' FROM [HJ_BM_DB].[dbo].[COPSALES] LEFT JOIN [HJ_BM_DB].[dbo].[tb_COMPANY] ON [STATUS]='1' AND OWNER_ID=USER_ID ) AS TEMP WHERE NOTES<=0 ORDER BY [ORDERS],NOTES DESC,[COMPANY_NAME] "; //DateTime SD = Convert.ToDateTime(SDATE); //SD = SD.AddDays(7); //DateTime ED = Convert.ToDateTime(EDATE); //ED = ED.AddDays(7); DateTime FirstDay = DateTime.Now.AddDays(-DateTime.Now.Day + 1); DateTime LastDay = DateTime.Now.AddMonths(1).AddDays(-DateTime.Now.AddMonths(1).Day); string SSDATE = FirstDay.ToString("yyyy/MM/dd"); string EEDATE = LastDay.ToString("yyyy/MM/dd"); m_db.AddParameter("@SDATE", SSDATE); m_db.AddParameter("@EDATE", EEDATE); DataTable dt = new DataTable(); dt.Load(m_db.ExecuteReader(cmdTxt)); Grid10.DataSource = dt; Grid10.DataBind(); }
//Show Events ......................................................................................................................................... protected void BtnEvents_Click(object sender, EventArgs e) { SqlConnection con = new SqlConnection(); SqlDataAdapter sda = new SqlDataAdapter(); DataSet ds = new DataSet(); try { con.ConnectionString = WebConfigurationManager.ConnectionStrings["constr"].ConnectionString; con.Open(); SqlCommand cmd = new SqlCommand("Show_Event", con); cmd.CommandType = System.Data.CommandType.StoredProcedure; cmd.Parameters.Add(new SqlParameter("@event_id", Events1.Text)); if (Events1.Text == "" | Convert.ToInt32(Events1.Text) > 2) { HttpContext.Current.Response.Write("<SCRIPT LANGUAGE=''JavaScript''> alert('Enter A Valid Event')</SCRIPT>"); } else { cmd.ExecuteNonQuery(); //cnn.ConnectionString = "Data Source=(localdb)\\ProjectsV13;Initial Catalog=IEgypt_64;Integrated Security=True;Connect Timeout=30;Encrypt=False;TrustServerCertificate=False;ApplicationIntent=ReadWrite;MultiSubnetFailover=False"; //cnn.Open(); try { SqlCommand cmd1 = new SqlCommand("Show_Event", con); cmd1.CommandType = System.Data.CommandType.StoredProcedure; cmd1.Parameters.Add(new SqlParameter("@event_id", Events1.Text)); SqlDataAdapter sda1 = new SqlDataAdapter(cmd1); cmd1.ExecuteNonQuery(); DataTable dt1 = new DataTable(); sda1.Fill(dt1); Grid10.DataSource = dt1; Grid10.DataBind(); } catch (Exception e1) { HttpContext.Current.Response.Write("<SCRIPT LANGUAGE=''JavaScript''> alert('SQl Query Fail')</SCRIPT>"); } try { } catch (Exception e1) { HttpContext.Current.Response.Write("<SCRIPT LANGUAGE=''JavaScript''> alert('Table creation Failed')</SCRIPT>"); } //cnn.Close(); HttpContext.Current.Response.Write("<SCRIPT LANGUAGE=''JavaScript''> alert('Events are here!!')</SCRIPT>"); } } catch (Exception e1) { HttpContext.Current.Response.Write("<SCRIPT LANGUAGE=''JavaScript''> alert('OOps an Error Has Occured Try Again Later :)')</SCRIPT>"); } con.Close(); }
private void LoadDataList() { try { DataSet _DataList = null; _DataList = DatabaseManager.Data.DBAccessManager.RetrieveDashBoardDataByEmpID(Int32.Parse(Page.User.Identity.Name.ToString()), Int32.Parse(businessUnitDDList.SelectedValue), Int32.Parse(DivisionLocationList.SelectedValue)); if (_DataList.Tables.Count > 0) { if (_DataList.Tables[0].Rows.Count > 0) // Employee Divisional Chart { DataTable _DataTable = _DataList.Tables[0]; Division_EmpListChart(_DataTable); } else { EmpListChart1.Items.Clear(); } if (_DataList.Tables[1].Rows.Count > 0) // Employee Location Chart { DataTable _DataTable = _DataList.Tables[1]; Location_EmpListChart(_DataTable); } else { EmpListChart2.Items.Clear(); } if (_DataList.Tables[2].Rows.Count > 0) // Employee Age Profile Chart { DataTable _DataTable = _DataList.Tables[2]; AgeProfile_EmpListChart(_DataTable); } else { EmpListChart3.Items.Clear(); } if (_DataList.Tables[3].Rows.Count > 0) // Employee Service Profile Chart { DataTable _DataTable = _DataList.Tables[3]; ServiceProfile_EmpListChart(_DataTable); } else { EmpListChart4.Items.Clear(); } if (_DataList.Tables[4].Rows.Count > 0) // Expiring Labor Cards in the next 6 months. { DataTable _DataTable = _DataList.Tables[4]; Grid3.DataSource = _DataTable; Grid3.DataBind(); } else { Grid3.DataSource = null; Grid3.DataBind(); } if (_DataList.Tables[5].Rows.Count > 0) // Expiring Visa in the next 6 months. { DataTable _DataTable = _DataList.Tables[5]; Grid4.DataSource = _DataTable; Grid4.DataBind(); } else { Grid4.DataSource = null; Grid4.DataBind(); } if (_DataList.Tables[6].Rows.Count > 0) // Expiring Passports in the next 6 months. { DataTable _DataTable = _DataList.Tables[6]; Grid5.DataSource = _DataTable; Grid5.DataBind(); } else { Grid5.DataSource = null; Grid5.DataBind(); } if (_DataList.Tables[7].Rows.Count > 0) // Pending Leave in the current week. { DataTable _DataTable = _DataList.Tables[7]; Grid1.DataSource = _DataTable; Grid1.DataBind(); } else { Grid1.DataSource = null; Grid1.DataBind(); } if (_DataList.Tables[8].Rows.Count > 0) // Upcoming Holidays { DataTable _DataTable = _DataList.Tables[8]; Grid2.DataSource = _DataTable; Grid2.DataBind(); } else { Grid2.DataSource = null; Grid2.DataBind(); } if (_DataList.Tables[10].Rows.Count > 0) // Upcoming Probation endings { DataTable _DataTable = _DataList.Tables[10]; Grid7.DataSource = _DataTable; Grid7.DataBind(); } else { Grid7.DataSource = null; Grid7.DataBind(); } if (_DataList.Tables[11].Rows.Count > 0) // Business Visa Expiry { DataTable _DataTable = _DataList.Tables[11]; Grid10.DataSource = _DataTable; Grid10.DataBind(); } else { Grid10.DataSource = null; Grid10.DataBind(); } } } catch (Exception exception) { ErrorLogging.LogError(exception, "Unknown Exception Occured. Please contact support."); } }
private void LoadDataList() { try { DataSet _DataList = null; _DataList = DatabaseManager.Data.DBAccessManager.RetrieveDashBoardDataByEmpID(Int32.Parse(Page.User.Identity.Name.ToString()), Int32.Parse(businessUnitDDList.SelectedValue), Int32.Parse(DivisionLocationList.SelectedValue)); if (_DataList.Tables.Count > 0) { if (_DataList.Tables[0].Rows.Count > 0) // Employee Divisional PieChart { PieXML = ""; DataTable _DataTable = _DataList.Tables[0]; PieXML = CreatePieGraph1(_DataTable, "Employee Count Breakdown By Business Unit/Dept", "", "Count", "Division/Dept"); FCLiteral1.Text = FusionCharts.RenderChartHTML("../FusionCharts/FCF_Pie3D.swf", "", PieXML, "DivisionDeptChart", PieWidth, PieHeight, false); } else { FCLiteral1.Visible = false; } if (_DataList.Tables[1].Rows.Count > 0) // Employee Location PieChart { PieXML = ""; DataTable _DataTable = _DataList.Tables[1]; PieXML = CreatePieGraph1(_DataTable, "Employee Count Breakdown By Country", "", "Country", "Count"); FCLiteral2.Text = FusionCharts.RenderChartHTML("../FusionCharts/FCF_Pie3D.swf", "", PieXML, "CountryChart", PieWidth, PieHeight, false); } else { FCLiteral2.Visible = false; } if (_DataList.Tables[2].Rows.Count > 0) // Employee Age Profile PieChart { DataTable _DataTable = _DataList.Tables[2]; CreateBarGraph1(_DataTable); } else { FCLiteral3.Visible = false; } if (_DataList.Tables[3].Rows.Count > 0) // Employee Service Profile PieChart { PieXML = ""; DataTable _DataTable = _DataList.Tables[3]; PieXML = CreatePieGraph1(_DataTable, "Employee Service Year Profile", "", "Count", "Division/Dept"); FCLiteral4.Text = FusionCharts.RenderChartHTML("../FusionCharts/FCF_Pie3D.swf", "", PieXML, "ServiceChart", PieWidth, PieHeight, false); } else { FCLiteral4.Visible = false; } if (_DataList.Tables[4].Rows.Count > 0) // Expiring Labor Cards in the next 6 months. { DataTable _DataTable = _DataList.Tables[4]; Grid3.DataSource = _DataTable; Grid3.DataBind(); } else { Grid3.DataSource = null; Grid3.DataBind(); } if (_DataList.Tables[5].Rows.Count > 0) // Expiring Visa in the next 6 months. { DataTable _DataTable = _DataList.Tables[5]; Grid4.DataSource = _DataTable; Grid4.DataBind(); } else { Grid4.DataSource = null; Grid4.DataBind(); } if (_DataList.Tables[6].Rows.Count > 0) // Expiring Passports in the next 6 months. { DataTable _DataTable = _DataList.Tables[6]; Grid5.DataSource = _DataTable; Grid5.DataBind(); } else { Grid5.DataSource = null; Grid5.DataBind(); } if (_DataList.Tables[7].Rows.Count > 0) // Pending Leave in the current week. { DataTable _DataTable = _DataList.Tables[7]; Grid1.DataSource = _DataTable; Grid1.DataBind(); } else { Grid1.DataSource = null; Grid1.DataBind(); } if (_DataList.Tables[8].Rows.Count > 0) // Upcoming Holidays { DataTable _DataTable = _DataList.Tables[8]; Grid2.DataSource = _DataTable; Grid2.DataBind(); } else { Grid2.DataSource = null; Grid2.DataBind(); } if (_DataList.Tables[10].Rows.Count > 0) // Upcoming Probation endings { DataTable _DataTable = _DataList.Tables[10]; Grid7.DataSource = _DataTable; Grid7.DataBind(); } else { Grid7.DataSource = null; Grid7.DataBind(); } if (_DataList.Tables[11].Rows.Count > 0) // Business Visa Expiry { DataTable _DataTable = _DataList.Tables[11]; Grid10.DataSource = _DataTable; Grid10.DataBind(); } else { Grid10.DataSource = null; Grid10.DataBind(); } } } catch (Exception exception) { ErrorLogging.LogError(exception, "Unknown Exception Occured. Please contact support."); } }
protected void gridCallBack_Callback(object sender, CallBackEventArgs e) { hfMessage.Value = ""; int n = OrgList.SelectedIndex; try { if (e.Parameters[0] != "") { if (e.Parameters[1] == "Up") { UpData(e.Parameters[0]); } else if (e.Parameters[1] == "Down") { DownData(e.Parameters[0]); } else { DeleteData(e.Parameters[0]); } } else if (e.Parameters[0] == "") { BindGrid(n); } if (n == 0) { Grid1.RenderControl(e.Output); } else if (n == 1) { Grid2.RenderControl(e.Output); } else if (n == 2) { Grid3.RenderControl(e.Output); } else if (n == 3) { Grid4.RenderControl(e.Output); } else if (n == 4) { Grid5.RenderControl(e.Output); } else if (n == 5) { Grid6.RenderControl(e.Output); } else if (n == 6) { Grid7.RenderControl(e.Output); } else if (n == 7) { Grid8.RenderControl(e.Output); } else if (n == 8) { Grid9.RenderControl(e.Output); } else if (n == 9) { Grid10.RenderControl(e.Output); } else if (n == 10) { Grid11.RenderControl(e.Output); } else if (n == 11) { Grid12.RenderControl(e.Output); } else if (n == 12) { Grid13.RenderControl(e.Output); } else if (n == 13) { Grid14.RenderControl(e.Output); } } catch { BindGrid(n); } hfMessage.RenderControl(e.Output); }
private void BindGrid(int n) { if (n == 0) { EducationLevelBLL objBLL = new EducationLevelBLL(); IList <EducationLevel> objList = objBLL.GetAllEducationLevel(); Grid1.DataSource = objList; Grid1.DataBind(); Grid1.Visible = true; Grid2.Visible = false; Grid3.Visible = false; Grid4.Visible = false; Grid5.Visible = false; Grid6.Visible = false; Grid7.Visible = false; Grid8.Visible = false; Grid9.Visible = false; } if (n == 1) { PoliticalStatusBLL objBLL = new PoliticalStatusBLL(); IList <PoliticalStatus> objList = objBLL.GetAllPoliticalStatus(); Grid2.DataSource = objList; Grid2.DataBind(); Grid1.Visible = false; Grid2.Visible = true; Grid3.Visible = false; Grid4.Visible = false; Grid5.Visible = false; Grid6.Visible = false; Grid7.Visible = false; Grid8.Visible = false; Grid9.Visible = false; } if (n == 2) { WorkGroupLeaderLevelBLL objBLL = new WorkGroupLeaderLevelBLL(); IList <WorkGroupLeaderLevel> objList = objBLL.GetAllWorkGroupLeaderLevel(); Grid3.DataSource = objList; Grid3.DataBind(); Grid1.Visible = false; Grid2.Visible = false; Grid3.Visible = true; Grid4.Visible = false; Grid5.Visible = false; Grid6.Visible = false; Grid7.Visible = false; Grid8.Visible = false; Grid9.Visible = false; } if (n == 3) { TechnicianTypeBLL objBLL = new TechnicianTypeBLL(); IList <TechnicianType> objList = objBLL.GetAllTechnicianType(); Grid4.DataSource = objList; Grid4.DataBind(); Grid1.Visible = false; Grid2.Visible = false; Grid3.Visible = false; Grid4.Visible = true; Grid5.Visible = false; Grid6.Visible = false; Grid7.Visible = false; Grid8.Visible = false; Grid9.Visible = false; } if (n == 4) { TechnicianTitleTypeBLL objBLL = new TechnicianTitleTypeBLL(); IList <TechnicianTitleType> objList = objBLL.GetAllTechnicianTitleType(); Grid5.DataSource = objList; Grid5.DataBind(); Grid1.Visible = false; Grid2.Visible = false; Grid3.Visible = false; Grid4.Visible = false; Grid5.Visible = true; Grid6.Visible = false; Grid7.Visible = false; Grid8.Visible = false; Grid9.Visible = false; } if (n == 5) { EducationEmployeeTypeBLL objBLL = new EducationEmployeeTypeBLL(); IList <EducationEmployeeType> objList = objBLL.GetAllEducationEmployeeType(); Grid6.DataSource = objList; Grid6.DataBind(); Grid1.Visible = false; Grid2.Visible = false; Grid3.Visible = false; Grid4.Visible = false; Grid5.Visible = false; Grid6.Visible = true; Grid7.Visible = false; Grid8.Visible = false; Grid9.Visible = false; } if (n == 6) { CommitteeHeadShipBLL objBLL = new CommitteeHeadShipBLL(); IList <CommitteeHeadShip> objList = objBLL.GetAllCommitteeHeadShip(); Grid7.DataSource = objList; Grid7.DataBind(); Grid1.Visible = false; Grid2.Visible = false; Grid3.Visible = false; Grid4.Visible = false; Grid5.Visible = false; Grid6.Visible = false; Grid7.Visible = true; Grid8.Visible = false; Grid9.Visible = false; } if (n == 7) { RandomExamModularTypeBLL objBLL = new RandomExamModularTypeBLL(); IList <RandomExamModularType> objList = objBLL.GetAllRandomExamModularType(); Grid8.DataSource = objList; Grid8.DataBind(); Grid1.Visible = false; Grid2.Visible = false; Grid3.Visible = false; Grid4.Visible = false; Grid5.Visible = false; Grid6.Visible = false; Grid7.Visible = false; Grid8.Visible = true; Grid9.Visible = false; } if (n == 8) { OracleAccess oracle = new OracleAccess(); DataTable dt = oracle.RunSqlDataSet("select * from zj_trainplan_type order by trainplan_type_id").Tables[0]; Grid9.DataSource = dt; Grid9.DataBind(); Grid1.Visible = false; Grid2.Visible = false; Grid3.Visible = false; Grid4.Visible = false; Grid5.Visible = false; Grid6.Visible = false; Grid7.Visible = false; Grid8.Visible = false; Grid9.Visible = true; } if (n == 9) { OracleAccess oracle = new OracleAccess(); DataTable dt = oracle.RunSqlDataSet("select * from zj_safe_level order by order_index").Tables[0]; Grid10.DataSource = dt; Grid10.DataBind(); Grid1.Visible = false; Grid2.Visible = false; Grid3.Visible = false; Grid4.Visible = false; Grid5.Visible = false; Grid6.Visible = false; Grid7.Visible = false; Grid8.Visible = false; Grid9.Visible = false; Grid10.Visible = true; } if (n == 10) { OracleAccess oracle = new OracleAccess(); DataTable dt = oracle.RunSqlDataSet("select * from zj_certificate order by order_index").Tables[0]; Grid11.DataSource = dt; Grid11.DataBind(); Grid1.Visible = false; Grid2.Visible = false; Grid3.Visible = false; Grid4.Visible = false; Grid5.Visible = false; Grid6.Visible = false; Grid7.Visible = false; Grid8.Visible = false; Grid9.Visible = false; Grid10.Visible = false; Grid11.Visible = true; } if (n == 11) { OracleAccess oracle = new OracleAccess(); DataTable dt = oracle.RunSqlDataSet(@"select a.*,b.certificate_name from zj_certificate_level a left join zj_certificate b on a.certificate_id=b.certificate_id order by a.order_index").Tables[0]; Grid12.DataSource = dt; Grid12.DataBind(); Grid1.Visible = false; Grid2.Visible = false; Grid3.Visible = false; Grid4.Visible = false; Grid5.Visible = false; Grid6.Visible = false; Grid7.Visible = false; Grid8.Visible = false; Grid9.Visible = false; Grid10.Visible = false; Grid11.Visible = false; Grid12.Visible = true; } if (n == 12) { OracleAccess oracle = new OracleAccess(); DataTable dt = oracle.RunSqlDataSet(" select * from zj_certificate_unit order by order_index").Tables[0]; Grid13.DataSource = dt; Grid13.DataBind(); Grid1.Visible = false; Grid2.Visible = false; Grid3.Visible = false; Grid4.Visible = false; Grid5.Visible = false; Grid6.Visible = false; Grid7.Visible = false; Grid8.Visible = false; Grid9.Visible = false; Grid10.Visible = false; Grid11.Visible = false; Grid12.Visible = false; Grid13.Visible = true; } if (n == 13) { OracleAccess oracle = new OracleAccess(); DataTable dt = oracle.RunSqlDataSet(" select * from zj_train_unit order by order_index").Tables[0]; Grid14.DataSource = dt; Grid14.DataBind(); Grid1.Visible = false; Grid2.Visible = false; Grid3.Visible = false; Grid4.Visible = false; Grid5.Visible = false; Grid6.Visible = false; Grid7.Visible = false; Grid8.Visible = false; Grid9.Visible = false; Grid10.Visible = false; Grid11.Visible = false; Grid12.Visible = false; Grid13.Visible = false; Grid14.Visible = true; } }
protected void Grid1_RowCommand(object sender, GridCommandEventArgs e) { if (e.CommandName == "Action1") { OffSession(); string username = Session["姓名"].ToString(); object[] keys = Grid1.DataKeys[e.RowIndex]; string 职务 = Session["职务"].ToString(); int ID = Convert.ToInt32(keys[0].ToString());//获取ID FlowID.Text = ID.ToString(); School申报审批BLL sbspbll = new School申报审批BLL(); string xa = ""; string SID = keys[1].ToString(); //获取SID 资产ID.Text = SID; string Mark = keys[5].ToString(); //获取FlowName FlowName.Text = Mark; Sort.Text = keys[2].ToString(); #region 报废判断 if (Mark == "资产处置-报废") { int sort = Convert.ToInt32(keys[2]); Sort.Text = sort.ToString(); if (sort == 2) { //Button14.Hidden = true; //Button6.Hidden = false; } else { Button2.Hidden = true; } if (keys[11] == null) { 原因说明_bfckxq.Text = ""; } else { 原因说明_bfckxq.Text = keys[11].ToString(); } 分管领导_bfckxq.Text = keys[25].ToString(); 分管领导处理意见_bfckxq.Text = keys[24].ToString(); 分管领导操作时间_bfckxq.Text = keys[26].ToString(); 电话_bfckxq.Text = keys[13].ToString(); 职务_bfckxq.Text = keys[13].ToString(); 事项名称_bfckxq.Text = keys[17].ToString(); 主管部门_bfckxq.Text = keys[29].ToString(); 主管部门处理意见_bfckxq.Text = keys[27].ToString(); 主管部门操作时间_bfckxq.Text = keys[28].ToString(); 财政部门意见_bfckxq.Text = keys[30].ToString(); 财政部门_bfckxq.Text = keys[31].ToString(); 财政部门操作时间_bfckxq.Text = keys[32].ToString(); if (职务 == "分管领导" && sort == 1) { Button15.Hidden = false; } else if (职务 == "主管部门" && sort == 2) { Button15.Hidden = false; } else if (职务 == "财务人员" && sort == 3) { Button15.Hidden = false; } else if (sort == 0) { Button15.Hidden = true; } else { Button15.Hidden = false; } 流程状态_abfckxq.Text = keys[3].ToString(); 单据编号_bfckxq.Text = keys[4].ToString(); float 总数 = 0.0f; float 总价 = 0.0f; 总数 = float.Parse(keys[6].ToString()); 总价 = float.Parse(keys[7].ToString()); 申报日期_ckxq.Text = keys[8].ToString(); 申报单位_bfckxq.Text = keys[9].ToString(); 申请人_bfckxq.Text = keys[10].ToString(); List <School办公设备信息表> listdata = bll.处置申报查询(SID, keys[5].ToString()); Grid7.DataSource = listdata; Grid7.DataBind(); Grid8.DataSource = listdata; Grid8.DataBind(); JObject summary = new JObject(); summary.Add("major", "全部合计"); summary.Add("数量_bfckxq", 总数.ToString("F2")); summary.Add("价格_bfckxq", 总价.ToString("F2")); Grid7.SummaryData = summary; Grid8.SummaryData = summary; Window4.Hidden = false; string zcid = keys[1].ToString(); 资产ID.Text = zcid; } #endregion #region 调拨 else if (Mark == "资产处置-调拨") { /* * ID(0),SID(1),Sort(2),流程状态(3),单据编号(4),FlowName(5),总数(6),总价(7),申报日期(8),申报单位(9),申请人(10) * ,原因说明(11),职务(12),电话(13),验收日期(14),调入单位(15),调出单位(16),事项名称(17) * ,调出单位分管领导意见(18),调出单位分管领导(19),调出单位分管领导处理时间(20),调入单位管理员意见(21),调入单位管理员(22) * ,调入单位管理员处理时间(23),调入单位分管领导意见(24),调入单位分管领导(25),调入单位分管领导处理时间(26),主管部门意见(27) * ,主管部门处理时间(28),主管部门(29),财政部门意见(30),财政部门(31),财政部门处理时间(32) */ Window5.Hidden = false; int sort = Convert.ToInt32(keys[2]); btntanchuang.Text = "处理"; btntanchuang.Enabled = false; if (sort == 1) { //分管领导处理 if (职务 == "分管领导") { btntanchuang.Text = "分管领导处理"; btntanchuang.Enabled = true; } } else if (sort == 2) { //资产管理员处理 if (职务 == "资产管理员") { btntanchuang.Text = "资产管理员处理"; btntanchuang.Enabled = true; } } //调入单位分管领导 else if (sort == 3) { if (职务 == "分管领导") { btntanchuang.Text = "分管领导处理"; btntanchuang.Enabled = true; } } else if (sort == 4) { if (职务 == "主管部门") { btntanchuang.Text = "主管部门处理"; btntanchuang.Enabled = true; } } else if (sort == 5) { if (职务 == "财务人员") { btntanchuang.Text = "财政部门处理"; btntanchuang.Enabled = true; } } else if (sort == 6) { //string aID = Session["ID"].ToString(); //int zcczID = Convert.ToInt32(Session["UserID"].ToString()); //string fname = sbspbll.资产处置调出单位(zcczID); if (职务 == "资产管理员" && keys[10].ToString() == username) { btntanchuang.Text = "资产管理员处理"; btntanchuang.Enabled = true; } } else if (sort == 7) { //string aID = Session["ID"].ToString(); //int zcczID = Convert.ToInt32(Session["UserID"].ToString()); //string fname = sbspbll.资产处置调入单位(zcczID); if (职务 == "资产管理员" && keys[22].ToString() == username) { btntanchuang.Text = "资产管理员处理"; btntanchuang.Enabled = true; } } else if (sort == 0) { btntanchuang.Hidden = true; } else { Button2.Hidden = true; } /* * ID(0),SID(1),Sort(2),流程状态(3),单据编号(4),FlowName(5),总数(6),总价(7),申报日期(8),申报单位(9),申请人(10) * ,原因说明(11),职务(12),电话(13),验收日期(14),调入单位(15),调出单位(16),事项名称(17) * ,调出单位分管领导意见(18),调出单位分管领导(19),调出单位分管领导处理时间(20),调入单位管理员意见(21),调入单位管理员(22) * ,调入单位管理员处理时间(23),调入单位分管领导意见(24),调入单位分管领导(25),调入单位分管领导处理时间(26),主管部门意见(27) * ,主管部门处理时间(28),主管部门(29),财政部门意见(30),财政部门(31),财政部门处理时间(32) */ 流程状态_dbckxq.Text = keys[3].ToString(); 单据编号_dbckxq.Text = keys[4].ToString(); int 总数 = 0; int 总价 = 0; 总数 = Convert.ToInt32(keys[6].ToString()); 总价 = Convert.ToInt32(keys[7].ToString()); 申报日期_dbckxq.Text = keys[8].ToString(); 申请人_dbckxq.Text = keys[10].ToString(); 调拨原因说明.Text = keys[11].ToString(); 职务_dbckxq.Text = keys[12].ToString(); 电话_dbckxq.Text = keys[13].ToString(); 验收日期_dbckxq.Text = keys[14].ToString(); 调入单位_dbckxq.Text = keys[15].ToString(); 调出单位_dbckxq.Text = keys[16].ToString(); 事项名称_dbckxq.Text = keys[17].ToString(); 调出单位分管领导意见.Text = keys[18].ToString(); 调出单位分管领导.Text = keys[19].ToString(); 调出单位分管领导处理时间.Text = keys[20].ToString(); 调入单位管理员意见.Text = keys[21].ToString(); 调入单位管理员.Text = keys[22].ToString(); 调入单位管理员处理时间.Text = keys[23].ToString(); 调入单位分管领导意见.Text = keys[24].ToString(); 调入单位分管领导.Text = keys[25].ToString(); 调入单位分管领导处理时间.Text = keys[26].ToString(); 调拨主管部门意见.Text = keys[27].ToString(); 主管部门处理时间.Text = keys[28].ToString(); 主管部门.Text = keys[29].ToString(); 调拨财政部门意见.Text = keys[30].ToString(); 财政部门.Text = keys[31].ToString(); 财政部门处理时间.Text = keys[32].ToString(); List <School办公设备信息表> listdata = bll.处置申报查询(SID, keys[5].ToString()); Grid9.DataSource = listdata; Grid9.DataBind(); Grid10.DataSource = listdata; Grid10.DataBind(); JObject summary = new JObject(); summary.Add("major", "全部合计"); summary.Add("数量_db", 总数.ToString("F2")); summary.Add("价格_db", 总价.ToString("F2")); Grid9.SummaryData = summary; Grid10.SummaryData = summary; } #endregion } }
protected void 查看详情_Click(object sender, EventArgs e) { string FlowID = Request.QueryString["FlowID"]; if (FlowID != "" && FlowID != null) { ID = FlowID; } else { ID = Request.QueryString["ID"]; } // //string SID = Request.QueryString["SID"]; Window1.Hidden = false; string SID = bll.资产处置SID(Convert.ToInt32(ID)); List <流程进度查看详情表> listdatas = bll.资产处置待报废查看详情(ID, SID); 流程状态_dbckxq.Text = listdatas[0].流程状态.ToString(); 单据编号_dbckxq.Text = listdatas[0].单据编号.ToString(); float 总数 = 0.0f; float 总价 = 0.0f; 总数 = float.Parse(listdatas[0].总数.ToString()); 总价 = float.Parse(listdatas[0].总价.ToString()); 调出单位分管领导.Text = listdatas[0].调出单位分管领导.ToString(); 调出单位分管领导意见.Text = listdatas[0].调出单位分管领导意见.ToString(); 调出单位分管领导处理时间.Text = listdatas[0].调出单位分管领导处理时间.ToString(); 调入单位分管领导意见.Text = listdatas[0].调入单位分管领导意见.ToString(); 调入单位分管领导.Text = listdatas[0].调入单位分管领导.ToString(); 调入单位分管领导处理时间.Text = listdatas[0].调入单位分管领导处理时间.ToString(); 调入单位管理员意见.Text = listdatas[0].调入单位管理员意见.ToString(); 调入单位管理员.Text = listdatas[0].调入单位管理员.ToString(); 调入单位管理员处理时间.Text = listdatas[0].调入单位管理员处理时间.ToString(); 电话_dbckxq.Text = listdatas[0].电话.ToString(); 职务_dbckxq.Text = listdatas[0].职务.ToString(); 事项名称_dbckxq.Text = listdatas[0].事项名称.ToString(); 主管部门.Text = listdatas[0].主管部门.ToString(); 调拨主管部门意见.Text = listdatas[0].主管部门意见.ToString(); 主管部门处理时间.Text = listdatas[0].主管部门处理时间.ToString(); 调拨财政部门意见.Text = listdatas[0].财政部门意见.ToString(); 财政部门.Text = listdatas[0].财政部门.ToString(); 财政部门处理时间.Text = listdatas[0].财政部门处理时间.ToString(); //原因说明_bfckxq.Text = listdatas[0].原因说明.ToString(); 申请人_dbckxq.Text = listdatas[0].申请人.ToString(); //申报单位_bfckxq.Text = listdatas[0].申报单位.ToString(); 调出单位_dbckxq.Text = listdatas[0].调出单位.ToString(); 调入单位_dbckxq.Text = listdatas[0].调入单位.ToString(); 申报日期_dbckxq.Text = listdatas[0].申报日期.ToString(); 验收日期_dbckxq.Text = listdatas[0].验收日期.ToString(); string FlowName = listdatas[0].FlowName.ToString(); School申报审批BLL sbspbll = new School申报审批BLL(); List <School办公设备信息表> listdata = sbspbll.处置申报查询(SID, FlowName); Grid9.DataSource = listdata; Grid9.DataBind(); Grid10.DataSource = listdata; Grid10.DataBind(); JObject summary = new JObject(); summary.Add("major", "全部合计"); summary.Add("数量_dbckxq", 总数.ToString("F2")); summary.Add("价格_dbckxq", 总价.ToString("F2")); Grid9.SummaryData = summary; Grid10.SummaryData = summary; }