private ActivityStreams(long activityId)
        {
            _unitOfWork       = new Data.UnitOfWork();
            _containedStreams = new List <Models.Stream>();

            ActivityId = activityId;
        }
        protected async Task <ValidationResult> Commit(Interfaces.IUnitOfWork uow, string message)
        {
            if (!await uow.Commit())
            {
                AddError(message);
            }

            return(ValidationResult);
        }
 private void tbSerialNumber_Validating(object sender, CancelEventArgs e)
 {
     using (Interfaces.IUnitOfWork uow = UnitOfWorkFactory.CreateUnitOfWork())
     {
         var module = uow.ModuleRepository.FindSingle(x => x.Name == tbSerialNumber.Text);
         if (module == null)
         {
             hasError = true;
             formErrorProvider.SetError(tbSerialNumber, "Serial number not found.");
         }
     }
 }
 private ActivityStreams(long activityId, IEnumerable <Stream> stream)
 {
     _unitOfWork       = new Data.UnitOfWork();
     _containedStreams = stream.OrderBy(s => s.Time).ToList();
     ActivityId        = activityId;
 }
Beispiel #5
0
 public StudentsController(Interfaces.IUnitOfWork unitOfWork)
 {
     _unitOfWork = unitOfWork;
 }
Beispiel #6
0
 public SuppliersController(Interfaces.IUnitOfWork unitOfWork)
 {
     _unitOfWork = unitOfWork;
 }
Beispiel #7
0
 public RegionsController(Interfaces.IUnitOfWork unitOfWork)
 {
     _unitOfWork = unitOfWork;
 }
 public ActivityPeakDetails(IEnumerable <ActivityPeakDetail> peaks)
 {
     _unitOfWork     = new Data.UnitOfWork();
     _containedPeaks = peaks.ToList();
 }
Beispiel #9
0
 public CategoriesController(Interfaces.IUnitOfWork unitOfWork)
 {
     _unitOfWork = unitOfWork;
 }
 protected async Task <ValidationResult> Commit(Interfaces.IUnitOfWork uow)
 {
     return(await Commit(uow, "There was an error saving data").ConfigureAwait(false));
 }
Beispiel #11
0
 public AnimalsController(Interfaces.IUnitOfWork unitOfWork)
 {
     _unitOfWork = unitOfWork;
 }
 public AddressesController(Interfaces.IUnitOfWork unitOfWork)
 {
     _unitOfWork = unitOfWork;
 }
 public ProcessQueueJob(int jobId)
 {
     _uow   = new Data.UnitOfWork();
     _jobId = jobId;
 }
Beispiel #14
0
 public PetController(Interfaces.IUnitOfWork unitOfWork)
 {
     _unitOfWork = unitOfWork;
 }
 public ProductsController(Interfaces.IUnitOfWork unitOfWork)
 {
     _unitOfWork = unitOfWork;
 }
 public EmployeeTerritoriesController(Interfaces.IUnitOfWork unitOfWork)
 {
     _unitOfWork = unitOfWork;
 }
 public OrderDetailsController(Interfaces.IUnitOfWork unitOfWork)
 {
     _unitOfWork = unitOfWork;
 }
 public CustomersController(Interfaces.IUnitOfWork unitOfWork)
 {
     _unitOfWork = unitOfWork;
 }
 public CustomerDemographicsController(Interfaces.IUnitOfWork unitOfWork)
 {
     _unitOfWork = unitOfWork;
 }