Пример #1
0
        public async Task <PhotoShoot> BookingNewShootAsync(PhotoShoot newShoot)
        {
            if (await this._photoShootRepository.InsertAsync(newShoot))
            {
                return(newShoot);
            }

            return(null);
        }
Пример #2
0
        public OutputPhotoShoot(PhotoShoot photoShoot, bool withReferences)
        {
            Id              = photoShoot.ResourceId;
            OrderId         = photoShoot.OrderId;
            Address         = photoShoot.Address;
            Start           = photoShoot.Start;
            DurationMinutes = (uint)photoShoot.Duration.TotalMinutes;

            Images = withReferences && photoShoot.Images != null
                ? photoShoot.Images.Select(image => new OutputPhotoShootImage(image, false))
                : null;
        }
Пример #3
0
 public EquipmentWithdraw ToModel(Employee employee, Equipment equipment, PhotoShoot photoShoot)
 {
     return(new EquipmentWithdraw
     {
         WithdrawDate = DateTime.UtcNow,
         ExpectedDevolutionDate = ExpectedDevolutionDate,
         EffectiveDevolutionDate = EffectiveDevolutionDate,
         Employee = employee,
         EmployeeCpf = employee.UserId,
         Equipment = equipment,
         EquipmentId = equipment.Id,
         PhotoShoot = photoShoot,
         PhotoShootId = photoShoot.Id
     });
 }