RESTfulAPI::api_access_control
Checks a class or model api access depending on access_control_policy and the provided model.
- 1st config check - 2nd permission check if config access passes
Signature
public function api_access_control(string|DataObject
$model,
[string
$httpMethod = 'GET'] )
Parameters
$model
— object- Model's classname or DataObject
$httpMethod
— string- API request HTTP method
Returns
- boolean
- true if access is granted, false otherwise