function views_handler_filter_file_admin::query in File admin 7
Add this filter to the query.
Due to the nature of fapi, the value and the operator have an unintended level of indirection. You will find them in $this->operator and $this->value respectively.
Overrides views_handler_filter::query
File
- includes/
views_handler_filter_file_admin.inc, line 10
Class
- views_handler_filter_file_admin
- Filter by published status
Code
function query() {
$table = $this
->ensure_my_table();
$this->query
->add_where_expression($this->options['group'], "{$table}.published = 1 OR ({$table}.uid = ***CURRENT_USER*** AND ***CURRENT_USER*** <> 0 AND ***VIEW_OWN_UNPUBLISHED_FILES*** = 1) OR ***BYPASS_FILE_ACCESS*** = 1");
}