示例#1
0
 /// <summary>
 /// 按照关键字段删除
 /// </summary>
 /// <param name="Id">关键字段</param>
 /// <returns>是否成功</returns>
 public bool DelFmsStateResultRecord(string Id)
 {
     using (IFmsStateResultRecordBLL FmsStateResultRecordBLL = BLLContainer.Resolve <IFmsStateResultRecordBLL>())
     {
         try
         {
             FmsStateResultRecord item = FmsStateResultRecordBLL.GetFirstOrDefault(Id);
             return(FmsStateResultRecordBLL.Delete(item));
         }
         catch { return(false); }
     }
 }
示例#2
0
 /// <summary>
 /// 按照关键字段删除
 /// </summary>
 /// <param name="Ids">关键字段数组</param>
 /// <returns>是否成功</returns>
 public bool DelFmsStateResultRecords(string[] Ids)
 {
     using (IFmsStateResultRecordBLL FmsStateResultRecordBLL = BLLContainer.Resolve <IFmsStateResultRecordBLL>())
     {
         try
         {
             List <FmsStateResultRecord> entitys = new List <FmsStateResultRecord>();
             foreach (string id in Ids)
             {
                 FmsStateResultRecord item = FmsStateResultRecordBLL.GetFirstOrDefault(id);
                 entitys.Add(item);
             }
             return(FmsStateResultRecordBLL.Delete(entitys));
         }
         catch { return(false); }
     }
 }