Ejemplo n.º 1
0
        /// <summary>
        /// 获取公众号信息
        /// </summary>
        /// <param name="type"></param>
        /// <param name="expression1"></param>
        /// <param name="bgNo"></param>
        /// <returns></returns>
        public WctPaMstr GetPaInfo(int type, Expression <Func <WctPaMstr, bool> > expression1, string bgNo = "")
        {
            var paInfo = _wctPaMstrRepository.FirstOrDefault(expression1);

            if (paInfo == null && !string.IsNullOrEmpty(bgNo))
            {
                paInfo = _wctPaMstrRepository.FirstOrDefault(c => c.PA_TYPE_ID == type && c.DEL_FLAG == 1 && c.BG_NO == bgNo);
            }

            return(paInfo);
        }
Ejemplo n.º 2
0
 public ActionResult GetPaMstrInfo(string paId)
 {
     try
     {
         if (string.IsNullOrEmpty(paId))
         {
             return(Fail("数据传输异常"));
         }
         var result = _wctPaMstrRepository.FirstOrDefault(c => c.Id == paId && c.DEL_FLAG == 1).ToDto();
         return(Success("获取成功", result));
     }
     catch (Exception ex)
     {
         return(Fail(ex.Message));
     }
 }