| Conditions | 1 |
| Paths | 1 |
| Total Lines | 20 |
| Code Lines | 17 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 16 | public function load(ObjectManager $manager) |
||
| 17 | { |
||
| 18 | $nextBcrm = new Event(); |
||
| 19 | $nextBcrm->setCapacity(400); |
||
| 20 | $startDate = Carbon::create()->addDays(30); |
||
| 21 | $endDate = Carbon::create()->addDays(31); |
||
| 22 | $registrationStart = Carbon::create(); |
||
| 23 | $nextBcrm->setName(sprintf( |
||
| 24 | 'BarCamp %s %s/%s', |
||
| 25 | $startDate->format('Y'), |
||
| 26 | $startDate->format('d.'), |
||
| 27 | $endDate->format('d.m.Y') |
||
| 28 | )); |
||
| 29 | $nextBcrm->setStart($startDate); |
||
| 30 | $nextBcrm->setRegistrationStart($registrationStart); |
||
| 31 | $nextBcrm->setRegistrationEnd($endDate); |
||
| 32 | $nextBcrm->setPrice(1000); |
||
| 33 | $manager->persist($nextBcrm); |
||
| 34 | $manager->flush(); |
||
| 35 | } |
||
| 36 | } |
||
| 37 |