protected void ASPxListBox1_Callback(object sender, CallbackEventArgsBase e) { string[] param = e.Parameter.Split(','); string type = param[0]; string pline1 = ASPxComboBoxPline.SelectedItem.Value.ToString(); //string pline1 = param[1]; //string begindate1 = param[1] ; string begindate1 = ASPxDateEdit1.Date.ToString("yyyy-MM-dd"); ASPxListBox location = sender as ASPxListBox; if (type == "ALL") { //大线和改制返修如何区分,根据计划制定人员? string sql = "select plan_code||'; '||plan_so||'; '||plan_qty||'; '||pline_code ID1 from data_plan where pline_code='" + pline1 + "' and (plan_type='C' or plan_type='D') and begin_date=to_date('" + begindate1 + "','yyyy-mm-dd') and confirm_flag='Y' and bom_flag='N' and item_flag='N' and third_flag='N' and run_flag='N' order by plan_code"; DataTable dt = dc.GetTable(sql); location.DataSource = dt; location.DataBind(); } if (type == "ALLW") { string sql = "select plan_code||'; '||plan_so||'; '||plan_qty||'; '||pline_code ID1 from data_plan where pline_code='" + pline1 + "' and (plan_type='C' or plan_type='D') and confirm_flag='Y' and bom_flag='N' and item_flag='N' and third_flag='N' and run_flag='N' order by plan_code"; DataTable dt = dc.GetTable(sql); location.DataSource = dt; location.DataBind(); } string sql1 = "select rmes_id,plan_code,plan_so,plan_qty,pline_code from data_plan where pline_code='" + pline1 + "' and (plan_type='C' or plan_type='D') and begin_date=to_date('" + begindate1 + "','yyyy-mm-dd') and confirm_flag='Y' and bom_flag='N' and item_flag='N' and third_flag='N' and run_flag='N' order by plan_code"; ASPxListBoxLocation.DataSource = dc.GetTable(sql1); ASPxListBoxLocation.DataBind(); }
protected void ASPxListBoxLocation_Callback(object sender, CallbackEventArgsBase e) { string pline = e.Parameter; string sql = "select distinct location_code from ms_location_time where gzdd ='" + pline + "'" + "and location_code not in (select location_code from code_location ) order by location_code"; SqlLocation.SelectCommand = sql; SqlLocation.DataBind(); ASPxListBoxLocation.DataBind(); }