for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
/**
* This file is part of the HRis Software package.
*
* HRis - Human Resource and Payroll System
* @link http://github.com/HB-Co/HRis
*/
namespace HRis\Api\Requests\Admin\Job;
use HRis\Http\Requests\Request;
class JobTitleRequest extends Request
{
* Get the validation rules that apply to the request.
* @return array
* @author Bertrand Kintanar <[email protected]>
public function rules()
if ($this->isMethod('post')) {
return ['name' => 'required|unique:job_titles'];
}
return [];
* Determine if the user is authorized to make this request.
* @return bool
public function authorize()
return $this->hasAccess('admin.job.titles');