Пример #1
0
        /// <summary>
        /// 单个模版房间详情
        /// </summary>
        /// <param name="did"></param>
        /// <returns></returns>
        public string GetModelDetail(string did)
        {
            StringBuilder sb = new StringBuilder();
            string        s  = Commen.DataCache.GetCache(did).ToSafeString();

            // string s = "";
            if (!s.IsEmpty())
            {
                return(s.Replace("m&sup2;", "㎡").Replace("平米", "㎡").Replace("dm", "顶面").Replace("ld", "地面").Replace("qm", "墙面").Replace("a顶面in", "admin"));;
            }
            else
            {
                #region 详细查询
                sb.Append("{");
                string room = new BLL.ModelRoom().GetModelRoomSExt(did);
                sb.Append("\"modleroom\":");
                sb.Append(room);
                sb.Append(",");
                sb.Append("\"jiancai\":");
                string zcstr = new BLL.ZC().GetZcMx(did);
                sb.Append(zcstr);
                sb.Append(",");
                sb.Append("\"gongyi\":");
                string gystr = new GY().GetGyMx(did);
                sb.Append(gystr);
                sb.Append("}");
                #endregion


                Commen.DataCache.SetCache(did, sb, DateTime.Now.AddMonths(1), TimeSpan.Zero);

                //    cache.Insert("DD", "滑动过期测试", null, System.Web.Caching.Cache.NoAbsoluteExpiration, TimeSpan.FromSeconds(10));

                return(sb.ToSafeString().Replace("m&sup2;", "㎡").Replace("平米", "㎡").Replace("dm", "顶面").Replace("ld", "地面").Replace("qm", "墙面").Replace("a顶面in", "admin"));
            }
        }
Пример #2
0
        /// <summary>
        /// 得到主材明细
        /// </summary>
        /// <param name="did"></param>
        /// <returns></returns>
        public string GetZcMx(string did)
        {
            BLL.ZC bll = new BLL.ZC();

            return(bll.GetZcMx(did));
        }