@@ -5,6 +5,9 @@ |
||
| 5 | 5 | protected $isAdmin = null; |
| 6 | 6 | protected $isLead = null; |
| 7 | 7 | |
| 8 | + /** |
|
| 9 | + * @param string $dataTableName |
|
| 10 | + */ |
|
| 8 | 11 | public function __construct($dataTableName, $idField = '_id') |
| 9 | 12 | { |
| 10 | 13 | parent::__construct('fvs', $dataTableName, $idField); |
@@ -109,6 +109,9 @@ discard block |
||
| 109 | 109 | return $response->withJson($shifts); |
| 110 | 110 | } |
| 111 | 111 | |
| 112 | + /** |
|
| 113 | + * @param string $table |
|
| 114 | + */ |
|
| 112 | 115 | protected function createEntityForDepartment($request, $response, $args, $table) |
| 113 | 116 | { |
| 114 | 117 | $deptId = $args['dept']; |
@@ -212,6 +215,9 @@ discard block |
||
| 212 | 215 | return $response; |
| 213 | 216 | } |
| 214 | 217 | |
| 218 | + /** |
|
| 219 | + * @param string $type |
|
| 220 | + */ |
|
| 215 | 221 | public function generateGridSchedule($dept, $shifts, $response, $type) |
| 216 | 222 | { |
| 217 | 223 | $ss = new \Schedules\GridSchedule($dept, $shifts); |
@@ -1,6 +1,9 @@ discard block |
||
| 1 | 1 | <?php |
| 2 | 2 | trait Processor |
| 3 | 3 | { |
| 4 | + /** |
|
| 5 | + * @param string $certType |
|
| 6 | + */ |
|
| 4 | 7 | protected function certCheck($requirements, $certs, $certType) |
| 5 | 8 | { |
| 6 | 9 | if(isset($requirements[$certType]) && $requirements[$certType]) |
@@ -12,6 +15,9 @@ discard block |
||
| 12 | 15 | |
| 13 | 16 | protected abstract function isVolunteerAdmin($request); |
| 14 | 17 | |
| 18 | + /** |
|
| 19 | + * @param VolunteerProfile|null $user |
|
| 20 | + */ |
|
| 15 | 21 | public function canUserDoRole($user, $role) |
| 16 | 22 | { |
| 17 | 23 | if($role['publicly_visible'] === true) |
@@ -152,6 +158,9 @@ discard block |
||
| 152 | 158 | return !in_array($deptId, $privateDepts); |
| 153 | 159 | } |
| 154 | 160 | |
| 161 | + /** |
|
| 162 | + * @param VolunteerShift $shift |
|
| 163 | + */ |
|
| 155 | 164 | protected function doShiftTimeChecks($shift, $entry) |
| 156 | 165 | { |
| 157 | 166 | $now = new DateTime(); |
@@ -40,6 +40,11 @@ discard block |
||
| 40 | 40 | return ($hour - 12).'p'; |
| 41 | 41 | } |
| 42 | 42 | |
| 43 | + /** |
|
| 44 | + * @param integer $hourCount |
|
| 45 | + * @param integer $rowCount |
|
| 46 | + * @param \PhpOffice\PhpSpreadsheet\Worksheet\Worksheet $sheat |
|
| 47 | + */ |
|
| 43 | 48 | protected function grayOutUnused($hourCount, $rowCount, $sheat) |
| 44 | 49 | { |
| 45 | 50 | for($i = 0; $i < $hourCount; $i++) |
@@ -61,6 +66,11 @@ discard block |
||
| 61 | 66 | } |
| 62 | 67 | } |
| 63 | 68 | |
| 69 | + /** |
|
| 70 | + * @param \PhpOffice\PhpSpreadsheet\Worksheet\Worksheet $sheat |
|
| 71 | + * @param double $col |
|
| 72 | + * @param double $row |
|
| 73 | + */ |
|
| 64 | 74 | protected function setShiftNameInCell($sheat, $col, $row, $shift) |
| 65 | 75 | { |
| 66 | 76 | if(isset($shift['participant'])) |
@@ -3,7 +3,6 @@ |
||
| 3 | 3 | |
| 4 | 4 | use PhpOffice\PhpSpreadsheet\Spreadsheet; |
| 5 | 5 | use PhpOffice\PhpSpreadsheet\Writer\Xlsx; |
| 6 | -use PhpOffice\PhpSpreadsheet\Writer\Pdf\Mpdf; |
|
| 7 | 6 | |
| 8 | 7 | require_once('../../api/v1/class.Processor.php'); |
| 9 | 8 | |