Exemple #1
0
 /// <summary>
 /// 把查询的数据添加到仓储数据库
 /// </summary>
 /// <param name="masterds"></param>
 /// <param name="detailds"></param>
 public void Insert(DataSet masterds, DataSet detailds, DataSet middleds)
 {
     try
     {
         using (PersistentManager pm = new PersistentManager())
         {
             DownDecidePlanDao dao = new DownDecidePlanDao();
             if (masterds.Tables["WMS_IN_BILLMASTER"].Rows.Count > 0)
             {
                 dao.InsertInBillMaster(masterds);
             }
             if (detailds.Tables["WMS_IN_BILLDETAIL"].Rows.Count > 0)
             {
                 dao.InsertInBillDetail(detailds);
             }
             if (middleds.Tables["WMS_MIDDLE_IN_BILLDETAIL"].Rows.Count > 0)
             {
                 dao.InsertMiddle(middleds);
             }
         }
     }
     catch (Exception e)
     {
         throw new Exception(e.Message);
     }
 }