/// <summary> /// 获取首页设备数(仪表数) /// </summary> /// <returns></returns> public APIRst GetHomeModule() { APIRst rst = new APIRst(); try { DataTable dtSource = bll.GetHomeModule(); object obj = new { Total = dtSource.Rows.Count }; rst.data = obj; } catch (Exception ex) { rst.rst = false; rst.err.code = (int)ResultCodeDefine.Error; rst.err.msg = ex.Message; FileLog.WriteLog("获取首页设备数(仪表数)错误:" + ex.Message + ex.StackTrace); } return(rst); }