FetchHour() static private method

static private FetchHour ( HourData data ) : Hour
data Epiworx.Data.HourData
return Hour
Beispiel #1
0
        internal static void DeleteHour(HourCriteria criteria)
        {
            var hour = Hour.FetchHour(criteria);

            if (!Hour.CanDeleteObject(hour))
            {
                throw new SecurityException("Only users with full control can delete and archived hour");
            }

            Csla.DataPortal.Delete <Hour>(criteria);
        }
        public static Hour HourFetch(int hourId)
        {
            var result = Hour.FetchHour(
                new HourDataCriteria
            {
                HourId = hourId
            });

            result.Auditor = new HourAuditor(result.Clone());

            return(result);
        }