Révision db9ffd17
Ajouté par Assos Assos il y a presque 10 ans
drupal7/sites/all/modules/date/date_views/theme/theme.inc | ||
---|---|---|
75 | 75 |
case 'week': |
76 | 76 |
$next_week = date_week(date_format($next_date, 'Y-m-d')); |
77 | 77 |
$prev_week = date_week(date_format($prev_date, 'Y-m-d')); |
78 |
$next_arg = date_format($next_date, 'Y-\W') . date_pad($next_week);
|
|
79 |
$prev_arg = date_format($prev_date, 'Y-\W') . date_pad($prev_week);
|
|
78 |
$next_arg = date_format($next_date, 'o-\W') . date_pad($next_week);
|
|
79 |
$prev_arg = date_format($prev_date, 'o-\W') . date_pad($prev_week);
|
|
80 | 80 |
break; |
81 | 81 |
default: |
82 | 82 |
$next_arg = date_format($next_date, $format[$granularity]); |
... | ... | |
165 | 165 |
$date_info = $view->date_info; |
166 | 166 |
$link = !empty($params['link']) ? $params['link'] : FALSE; |
167 | 167 |
$format = !empty($params['format']) ? $params['format'] : NULL; |
168 |
$format_with_year = variable_get('date_views_' . $granularity . 'format_with_year', 'l, F j, Y'); |
|
169 |
$format_without_year = variable_get('date_views_' . $granularity . 'format_without_year', 'l, F j'); |
|
168 | 170 |
switch ($granularity) { |
169 | 171 |
case 'year': |
170 | 172 |
$title = $date_info->year; |
171 | 173 |
$date_arg = $date_info->year; |
172 | 174 |
break; |
173 | 175 |
case 'month': |
174 |
$format = !empty($format) ? $format : (empty($date_info->mini) ? 'F Y' : 'F');
|
|
176 |
$format = !empty($format) ? $format : (empty($date_info->mini) ? $format_with_year : $format_without_year);
|
|
175 | 177 |
$title = date_format_date($date_info->min_date, 'custom', $format); |
176 | 178 |
$date_arg = $date_info->year . '-' . date_pad($date_info->month); |
177 | 179 |
break; |
178 | 180 |
case 'day': |
179 |
$format = !empty($format) ? $format : (empty($date_info->mini) ? 'l, F j, Y' : 'l, F j');
|
|
181 |
$format = !empty($format) ? $format : (empty($date_info->mini) ? $format_with_year : $format_without_year);
|
|
180 | 182 |
$title = date_format_date($date_info->min_date, 'custom', $format); |
181 | 183 |
$date_arg = $date_info->year . '-' . date_pad($date_info->month) . '-' . date_pad($date_info->day); |
182 | 184 |
break; |
183 | 185 |
case 'week': |
184 |
$format = !empty($format) ? $format : (empty($date_info->mini) ? 'F j, Y' : 'F j');
|
|
186 |
$format = !empty($format) ? $format : (empty($date_info->mini) ? $format_with_year : $format_without_year);
|
|
185 | 187 |
$title = t('Week of @date', array('@date' => date_format_date($date_info->min_date, 'custom', $format))); |
186 | 188 |
$date_arg = $date_info->year . '-W' . date_pad($date_info->week); |
187 | 189 |
break; |
Formats disponibles : Unified diff
Weekly update of contrib modules