public static List <ExhibitCompany> Exhibit_Companies_Get(this Req_Exhibit_Dtl e) { var companies = DataAccess.Exhibit_Companies_Get(new DatabaseSearchModel().SetWhere($" ee_namemd = '{e.e_md}'").SetWhere(" len(ee_company) > 6").SetOrder(" ee_id ").SetPageIndex(e.pg_index).SetPageSize(e.pg_size)); var model = new DatabaseSearchModel().SetPageSize(e.pg_size).SetOrder(" oc_id "); foreach (var c in companies) { model.SetOrWhere($" oc_code='{c.oc_code}'"); } var list = DataAccess.OrgCompanyList_Page_Select(model); foreach (var l in list) { for (int i = 0; i < companies.Count; i++) { if (companies[i].oc_code == l.oc_code) { companies[i].oc_area = l.oc_area; break; } } } return(companies); }
public static string Exhibit_Companies() => Compose(Req_Exhibit_Dtl.Default().ToJson());