function forena_query_requirements in Forena Reports 7.5
Same name and namespace in other branches
- 8 forena_query/forena_query.module \forena_query_requirements()
- 7.4 forena_query.module \forena_query_requirements()
Implmentation of hook_requirements
Parameters
unknown $phase:
File
- ./
forena_query.module, line 96 - Provides the ability to create saved queries and to test sql data blocks.
Code
function forena_query_requirements($phase) {
$requirements = array();
switch ($phase) {
case 'runtime':
$writeable = is_writable(Frx::DataFile()->dir);
if (!$writeable) {
$requirements['fornea_writable'] = array(
'title' => 'Forena Query Data Directory',
'value' => Frx::DataFile()->dir,
'severity' => REQUIREMENT_ERROR,
'description' => t('The directory must be writable by the web user in order to create custom SQL data sources.') . t('Configure <a href="@private_path">private file system paths</a> or specificy a differnt <a href="@data_directory">data directory</a>."', array(
'@private_path' => url('admin/config/media/file-system'),
'@data_directory' => url('admin/config/content/forena'),
)),
);
}
}
return $requirements;
}