コード例 #1
0
 public FDIPostSaleOrderDetail GetFDIPostSaleOrderDetailById(string Id)
 {
     using (IFDIPostSaleOrderDetailBLL FDIPostSaleOrderDetailBLL = BLLContainer.Resolve <IFDIPostSaleOrderDetailBLL>())
     {
         FDIPostSaleOrderDetail model = FDIPostSaleOrderDetailBLL.GetFirstOrDefault(Id);
         return(model);
     }
 }
コード例 #2
0
        public int GetFDIPostSaleOrderDetailCount(string sWhere)
        {
            Expression <Func <FDIPostSaleOrderDetail, bool> > whereLamda = SerializerHelper.ConvertParamWhereToLinq <FDIPostSaleOrderDetail>(sWhere);

            using (IFDIPostSaleOrderDetailBLL FDIPostSaleOrderDetailBLL = BLLContainer.Resolve <IFDIPostSaleOrderDetailBLL>())
            {
                return(FDIPostSaleOrderDetailBLL.GetCount(whereLamda));
            }
        }
コード例 #3
0
        public List <FDIPostSaleOrderDetail> GetFDIPostSaleOrderDetails(string sWhere)
        {
            Expression <Func <FDIPostSaleOrderDetail, bool> > whereLamda = SerializerHelper.ConvertParamWhereToLinq <FDIPostSaleOrderDetail>(sWhere);

            using (IFDIPostSaleOrderDetailBLL FDIPostSaleOrderDetailBLL = BLLContainer.Resolve <IFDIPostSaleOrderDetailBLL>())
            {
                List <FDIPostSaleOrderDetail> models = FDIPostSaleOrderDetailBLL.GetModels(whereLamda);
                return(models);
            }
        }
コード例 #4
0
 public bool AddFDIPostSaleOrderDetail(FDIPostSaleOrderDetail mFDIPostSaleOrderDetail)
 {
     if (mFDIPostSaleOrderDetail == null)
     {
         return(false);
     }
     using (IFDIPostSaleOrderDetailBLL FDIPostSaleOrderDetailBLL = BLLContainer.Resolve <IFDIPostSaleOrderDetailBLL>())
     {
         return(FDIPostSaleOrderDetailBLL.Add(mFDIPostSaleOrderDetail));
     }
 }
コード例 #5
0
 public bool DelFDIPostSaleOrderDetail(string Id)
 {
     using (IFDIPostSaleOrderDetailBLL FDIPostSaleOrderDetailBLL = BLLContainer.Resolve <IFDIPostSaleOrderDetailBLL>())
     {
         try
         {
             FDIPostSaleOrderDetail item = FDIPostSaleOrderDetailBLL.GetFirstOrDefault(Id);
             return(FDIPostSaleOrderDetailBLL.Delete(item));
         }
         catch { return(false); }
     }
 }
コード例 #6
0
 public bool DelFDIPostSaleOrderDetails(string[] Ids)
 {
     using (IFDIPostSaleOrderDetailBLL FDIPostSaleOrderDetailBLL = BLLContainer.Resolve <IFDIPostSaleOrderDetailBLL>())
     {
         try
         {
             List <FDIPostSaleOrderDetail> entitys = new List <FDIPostSaleOrderDetail>();
             foreach (string id in Ids)
             {
                 FDIPostSaleOrderDetail item = FDIPostSaleOrderDetailBLL.GetFirstOrDefault(id);
                 entitys.Add(item);
             }
             return(FDIPostSaleOrderDetailBLL.Delete(entitys));
         }
         catch { return(false); }
     }
 }
コード例 #7
0
        public List <FDIPostSaleOrderDetail> GetFDIPostSaleOrderDetailByPage(int pageSize, int pageIndex, bool isAsc, string orderField, string sWhere)
        {
            string orderStr = "";

            if (string.IsNullOrEmpty(orderField))
            {
                orderStr = "CREATION_DATE";
            }
            else
            {
                orderStr = orderField;
            }
            Expression <Func <FDIPostSaleOrderDetail, bool> > whereLamda = SerializerHelper.ConvertParamWhereToLinq <FDIPostSaleOrderDetail>(sWhere);

            using (IFDIPostSaleOrderDetailBLL FDIPostSaleOrderDetailBLL = BLLContainer.Resolve <IFDIPostSaleOrderDetailBLL>())
            {
                List <FDIPostSaleOrderDetail> models = FDIPostSaleOrderDetailBLL.GetModelsByPage(pageSize, pageIndex, isAsc, orderStr, whereLamda);
                return(models);
            }
        }