Révision ee46a8ed
Ajouté par Assos Assos il y a plus de 7 ans
drupal7/sites/all/modules/date/date.field.inc | ||
---|---|---|
28 | 28 |
'settings' => array( |
29 | 29 |
'interval' => 2, |
30 | 30 |
'interval_display' => 'time ago', |
31 |
'use_end_date' => false, |
|
31 | 32 |
), |
32 | 33 |
), |
33 | 34 |
'date_plain' => array( |
... | ... | |
207 | 208 |
$variables['item'] = $item; |
208 | 209 |
$variables['dates'] = date_formatter_process($formatter, $entity_type, $entity, $field, $instance, $langcode, $item, $display); |
209 | 210 |
$variables['attributes'] = !empty($rdf_mapping) ? rdf_rdfa_attributes($rdf_mapping, $item['value']) : array(); |
210 |
$variables['show_remaining_days'] = $display['settings']['show_remaining_days'];
|
|
211 |
$variables['show_remaining_days'] = isset($display['settings']['show_remaining_days']) ? $display['settings']['show_remaining_days'] : FALSE;
|
|
211 | 212 |
$output = theme('date_display_combination', $variables); |
212 | 213 |
if (!empty($output)) { |
213 | 214 |
$element[$delta] = array('#markup' => $output); |
... | ... | |
322 | 323 |
} |
323 | 324 |
|
324 | 325 |
// The date text widget should use an increment of 1. |
325 |
$info['date_text']['increment'] = 1; |
|
326 |
$info['date_text']['settings']['increment'] = 1;
|
|
326 | 327 |
|
327 | 328 |
return $info; |
328 | 329 |
} |
... | ... | |
462 | 463 |
return _date_field_instance_settings_form($field, $instance); |
463 | 464 |
} |
464 | 465 |
|
466 |
/** |
|
467 |
* Form validation handler for _date_field_instance_settings_form(). |
|
468 |
*/ |
|
469 |
function date_field_instance_settings_form_validate(&$form, &$form_state) { |
|
470 |
module_load_include('inc', 'date', 'date_admin'); |
|
471 |
return _date_field_instance_settings_form_validate($form, $form_state); |
|
472 |
} |
|
473 |
|
|
465 | 474 |
/** |
466 | 475 |
* Implements hook_field_widget_settings_form(). |
467 | 476 |
*/ |
... | ... | |
470 | 479 |
return _date_field_widget_settings_form($field, $instance); |
471 | 480 |
} |
472 | 481 |
|
482 |
/** |
|
483 |
* Form validation handler for _date_field_widget_settings_form(). |
|
484 |
*/ |
|
485 |
function date_field_widget_settings_form_validate(&$form, &$form_state) { |
|
486 |
module_load_include('inc', 'date', 'date_admin'); |
|
487 |
return _date_field_widget_settings_form_validate($form, $form_state); |
|
488 |
} |
|
489 |
|
|
473 | 490 |
/** |
474 | 491 |
* Implements hook_field_settings_form(). |
475 | 492 |
*/ |
... | ... | |
478 | 495 |
return _date_field_settings_form($field, $instance, $has_data); |
479 | 496 |
} |
480 | 497 |
|
498 |
/** |
|
499 |
* Form validation handler for _date_field_settings_form(). |
|
500 |
*/ |
|
501 |
function date_field_settings_validate(&$form, &$form_state) { |
|
502 |
module_load_include('inc', 'date', 'date_admin'); |
|
503 |
return _date_field_settings_validate($form, $form_state); |
|
504 |
} |
|
505 |
|
|
481 | 506 |
/** |
482 | 507 |
* Implements hook_content_migrate_field_alter(). |
483 | 508 |
* |
Formats disponibles : Unified diff
Update date 7.x-2.9 -> 7.x-2.10-rc1