Révision ee46a8ed
Ajouté par Assos Assos il y a plus de 7 ans
drupal7/sites/all/modules/date/date_views/includes/date_views_filter_handler.inc | ||
---|---|---|
42 | 42 |
$this->date_combine_conditions('op_contains'); |
43 | 43 |
} |
44 | 44 |
|
45 |
function op_empty($field) { |
|
46 |
$this->get_query_fields(); |
|
47 |
if (empty($this->query_fields)) { |
|
48 |
return; |
|
49 |
} |
|
50 |
|
|
51 |
// Add each condition to the custom filter group. |
|
52 |
foreach ((array) $this->query_fields as $query_field) { |
|
53 |
$field = $query_field['field']; |
|
54 |
$this->date_handler = $query_field['date_handler']; |
|
55 |
|
|
56 |
// Respect relationships when determining the table alias. |
|
57 |
if ($field['table_name'] != $this->table || !empty($this->relationship)) { |
|
58 |
$this->related_table_alias = $this->query->ensure_table($field['table_name'], $this->relationship); |
|
59 |
} |
|
60 |
else { |
|
61 |
$this->related_table_alias = NULL; |
|
62 |
} |
|
63 |
|
|
64 |
$table_alias = !empty($this->related_table_alias) ? $this->related_table_alias : $field['table_name']; |
|
65 |
$field_name = $table_alias . '.' . $field['field_name']; |
|
66 |
|
|
67 |
parent::op_empty($field_name); |
|
68 |
} |
|
69 |
} |
|
70 |
|
|
45 | 71 |
/** |
46 | 72 |
* Combines multiple date WHERE expressions into a single WHERE expression. |
47 | 73 |
* |
Formats disponibles : Unified diff
Update date 7.x-2.9 -> 7.x-2.10-rc1