using System; using System.Collections.Generic; using System.Linq; using System.Web; using System.Web.UI; using System.Web.UI.WebControls; using CoreSavingLibrary; using System.Data; namespace Saving.Applications.shrlon.ws_sl_npl_tracking_ctrl { public partial class DsSuedetail : DataSourceRepeater { public DataSet2.LNLAWOBJDataTable DATA { get; set; } public void InitDsSuedetail(PageWeb pw) { css1.Visible = false; DataSet2 ds = new DataSet2(); this.DATA = ds.LNLAWOBJ; this.EventItemChanged = "OnDsSuedetailItemChanged"; this.EventClicked = "OnDsSuedetailClicked"; this.InitDataSource(pw, Repeater1, this.DATA, "dsSuedetail"); this.Button.Add("b_delobj"); this.Register(); } public void Retrieve(string tracking_no) { string sql = @"select * from LNLAWOBJ inner join lnucfloanobjective on LNLAWOBJ.loanobj_code = lnucfloanobjective.loanobjective_code where ( ( LNLAWOBJ.coop_id = {0} ) and ( LNLAWOBJ.loancontract_no like {1} ) )"; sql = WebUtil.SQLFormat(sql, state.SsCoopId, "%" + tracking_no); DataTable dt = WebUtil.Query(sql); this.ImportData(dt); } public void DdType() { string sql = @" SELECT loanobjective_code,(trim(loanobjective_code)||' '||loanobjective_desc) as loanobjective_desc ,1 as sorter FROM lnucfloanobjective union select '','',0 from dual order by sorter, loanobjective_desc "; DataTable dt = WebUtil.Query(sql); this.DropDownDataBind(dt, "LOANOBJ_CODE", "loanobjective_desc", "loanobjective_code"); } } }