/// <summary> /// 获取大厦详情 /// </summary> /// <param name="id"></param> /// <returns></returns> public string GetDetails(string id) { var info = new RoadFlow.Platform.BuildingsAndBuildingMonthInfoBLL().Get(Guid.Parse(id)); //大楼信息 DataTable ep = new RoadFlow.Platform.EnterpriseAndEnterpriseTaxBLL().GetAllByBuildingID(id); //入驻企业信息 if (info == null) { return(string.Empty); } else { var dictionarys = new RoadFlow.Platform.DictionaryBLL().GetListAll(); info.LYJBName = dictionarys.Find(p => p.ID == info.LYJB.Value) == null ? "" : dictionarys.Find(p => p.ID == info.LYJB.Value).Title; info.LYLXName = dictionarys.Find(p => p.ID == info.LYLX.Value) == null ? "" : dictionarys.Find(p => p.ID == info.LYLX.Value).Title; info.JSJDName = dictionarys.Find(p => p.ID == info.JSJD.Value) == null ? "" : dictionarys.Find(p => p.ID == info.JSJD.Value).Title; info.SSJDName = dictionarys.Find(p => p.ID == info.SSJD.Value) == null ? "" : dictionarys.Find(p => p.ID == info.SSJD.Value).Title; info.SY_ZJName = dictionarys.Find(p => p.ID == info.SY_ZJ.Value) == null ? "" : dictionarys.Find(p => p.ID == info.SY_ZJ.Value).Title; info.SW_ZJName = dictionarys.Find(p => p.ID == info.SW_ZJ.Value) == null ? "" : dictionarys.Find(p => p.ID == info.SW_ZJ.Value).Title; info.TCZSName = dictionarys.Find(p => p.ID == info.TCZS.Value) == null ? "" : dictionarys.Find(p => p.ID == info.TCZS.Value).Title; info.ZYKTName = dictionarys.Find(p => p.ID == info.ZYKT.Value) == null ? "" : dictionarys.Find(p => p.ID == info.ZYKT.Value).Title; info.LYCQQKName = dictionarys.Find(p => p.ID == info.LYCQQK.Value) == null ? "" : dictionarys.Find(p => p.ID == info.LYCQQK.Value).Title; //info = ConvertType(info); //ep = ConvertType(ep); Dictionary <string, string> columnName = new Dictionary <string, string>(); return(new { info, ep, columnName }.ToJson()); } }
public BuildingsController() { PageSize = 13; BuildingsAndBuildingMonthInfoBLL = new RoadFlow.Platform.BuildingsAndBuildingMonthInfoBLL(); TableAttribute = new RoadFlow.Platform.TableAttribute(); BLL = new RoadFlow.Platform.BuildingsDataBLL(); DictionaryBLL = new RoadFlow.Platform.DictionaryBLL(); }
/// <summary> /// 获取点 /// </summary> /// <param name="query">参数</param> /// <param name="perPage">每页显示条数</param> /// <param name="pageNumber">当前页</param> /// <returns></returns> public string GetPoint(string query, int perPage = 6, int pageNumber = 1) { int allPages = 0; //int count = 0; //DataTable dt = new RoadFlow.Platform.Enterprise().GetPagerData(out allPages, out count, query, pageNumber, perPage); DataTable dt = new RoadFlow.Platform.BuildingsAndBuildingMonthInfoBLL().OldGetAll(query); //dt = ConvertType(dt); if (dt == null || dt.Rows.Count < 1) { return(string.Empty); } else { return(new { Dt = dt, AllPages = allPages }.ToJson()); } }
public StatisticsController() { BuildingsStreetStatisticsBLL = new RoadFlow.Platform.BuildingsStreetStatisticsBLL(); BuildingsAndBuildingMonthInfoBLL = new RoadFlow.Platform.BuildingsAndBuildingMonthInfoBLL(); }