function pmpapi_query_tools_get_queries in Public Media Platform API Integration 7
Gets data for all queries.
Return value
array The query parameters for all the queries, or NULL, if there are are no queries.
2 calls to pmpapi_query_tools_get_queries()
- pmpapi_query_tools_execute_queries in pmpapi_query_tools/
pmpapi_query_tools.module - Executes all saved queries.
- pmpapi_query_tools_list_queries in pmpapi_query_tools/
pmpapi_query_tools.admin.inc - Page callback: Displays a table of saved queries.
File
- pmpapi_query_tools/
pmpapi_query_tools.module, line 89 - Allows admins to build, save, and execute PMP queries
Code
function pmpapi_query_tools_get_queries() {
$queries = array();
$results = db_select('pmpapi_query_tools_queries', 'pqtq')
->fields('pqtq', array(
'name',
'options',
))
->execute()
->fetchAllKeyed();
if ($results) {
$queries = array_map('unserialize', $results);
}
return $queries;
}