コード例 #1
0
ファイル: ServicePDCA.cs プロジェクト: hassench/FiveStars
 static public void addPDCA(PDCA PDCA)
 {
     using (PDCARepository PDCArepo = new PDCARepository())
     {
         PDCArepo.context.Entry(PDCA.resultat).State = EntityState.Unchanged;
         PDCArepo.Add(PDCA);
         PDCArepo.Save();
     }
 }
コード例 #2
0
ファイル: ServicePDCA.cs プロジェクト: hassench/FiveStars
        static public PDCA GetPDCA(int PDCAid)
        {
            PDCA PDCAtemp = null;

            using (PDCARepository PDCArepo = new PDCARepository())
            {
                PDCAtemp = PDCArepo.GetSingle(PDCAid);
            }

            return(PDCAtemp);
        }
コード例 #3
0
ファイル: ServicePDCA.cs プロジェクト: hassench/FiveStars
        static public IList <PDCA> GetPDCAByAudit(int auditId)
        {
            IList <PDCA> PDCAtemp = null;

            using (PDCARepository PDCArepo = new PDCARepository())
            {
                PDCAtemp = PDCArepo.GetByAudit(auditId);
            }

            return(PDCAtemp);
        }
コード例 #4
0
ファイル: ServicePDCA.cs プロジェクト: hassench/FiveStars
        static public List <PDCA> GetPDCAByZone(int id)
        {
            List <PDCA> temp;

            using (PDCARepository PdcaRepo = new PDCARepository())
            {
                temp = (List <PDCA>)PdcaRepo.GetByZone(id);
            }

            return(temp);
        }
コード例 #5
0
ファイル: ServicePDCA.cs プロジェクト: hassench/FiveStars
        static public List <PDCA> GetAllPDCAs()
        {
            List <PDCA> PDCAtemp = null;

            using (PDCARepository PDCArepo = new PDCARepository())
            {
                PDCAtemp = (List <PDCA>)PDCArepo.GetAll();
                foreach (PDCA PDCA in PDCAtemp)
                {
                    PDCArepo.context.Entry(PDCA).State = EntityState.Detached;
                }
            }

            return(PDCAtemp);
        }
コード例 #6
0
ファイル: ServicePDCA.cs プロジェクト: hassench/FiveStars
        static public List <PDCA> GetPDCAByPilote(string mail)
        {
            int auditeurid;

            using (UserRepository usertrepo = new UserRepository())
            {
                auditeurid = usertrepo.GetPiloteIDBymail(mail);
            }
            List <PDCA> temp;

            using (PDCARepository PdcaRepo = new PDCARepository())
            {
                temp = (List <PDCA>)PdcaRepo.GetByPilote(auditeurid);
            }

            return(temp);
        }