Exemplo n.º 1
0
        public bool DoesWVUEmployeeHavePermit(string wvuEmployeeID)
        {
            bool   hasPermit;
            Permit permit = database.Permits.Where(p => p.WVUEmployeeID == wvuEmployeeID).FirstOrDefault();

            if (permit == null)
            {
                hasPermit = false;
            }
            else
            {
                hasPermit = true;
            }
            return(hasPermit);
        }
Exemplo n.º 2
0
 public Task AddPermit(Permit permit)
 {
     database.Permits.AddAsync(permit);
     return(database.SaveChangesAsync());
 }