| 1 | <?php |
||
| 9 | class PushNotificationDeviceController extends BaseApiController |
||
| 10 | { |
||
| 11 | /** |
||
| 12 | * Path of the sotre form request. |
||
| 13 | * |
||
| 14 | * @var string |
||
| 15 | */ |
||
| 16 | protected $storeFormRequest = 'App\Modules\Users\Http\PushNotificationDevices\StorePushNotificationDevice'; |
||
| 17 | |||
| 18 | /** |
||
| 19 | * Path of the model resource |
||
| 20 | * |
||
| 21 | * @var string |
||
| 22 | */ |
||
| 23 | protected $modelResource = 'App\Modules\PushNotificationDevices\Http\Resources\PushNotificationDevice'; |
||
| 24 | |||
| 25 | /** |
||
| 26 | * List of all route actions that the base api controller |
||
| 27 | * will skip permissions check for them. |
||
| 28 | * @var array |
||
| 29 | */ |
||
| 30 | protected $skipPermissionCheck = ['registerDevice']; |
||
| 31 | |||
| 32 | /** |
||
| 33 | * Init new object. |
||
| 34 | * |
||
| 35 | * @param PushNotificationDeviceService $service |
||
| 36 | * @return void |
||
|
|
|||
| 37 | */ |
||
| 38 | public function __construct(PushNotificationDeviceService $service) |
||
| 42 | |||
| 43 | /** |
||
| 44 | * Register the given device to the logged in user. |
||
| 45 | * |
||
| 46 | * @param RegisterDevice $request |
||
| 47 | * @return \Illuminate\Http\Response |
||
| 48 | */ |
||
| 49 | public function registerDevice(RegisterDevice $request) |
||
| 53 | } |
||
| 54 |
Adding a
@returnannotation to a constructor is not recommended, since a constructor does not have a meaningful return value.Please refer to the PHP core documentation on constructors.