Projet

Général

Profil

Révision 5e632cae

Ajouté par Assos Assos il y a plus de 3 ans

Weekly update of contrib modules

Voir les différences:

drupal7/sites/all/modules/field_collection/field_collection.api.php
113 113
    ->execute();
114 114
}
115 115

  
116
/**
117
 * Responds to field collection item archiving.
118
 *
119
 * This hook is invoked after the field collection item has been archived while
120
 * removing it from its host entity.
121
 *
122
 * @param FieldCollectionItemEntity $field_collection_item
123
 *   The field collection item that is being archived.
124
 */
125
function hook_field_collection_item_archive(FieldCollectionItemEntity $field_collection_item) {
126
  db_update('mytable')
127
    ->fields(array('archived' => 1))
128
    ->condition('id', entity_id('field_collection_item', $field_collection_item))
129
    ->execute();
130
}
131

  
116 132
/**
117 133
 * Act on a field collection item that is being assembled before rendering.
118 134
 *

Formats disponibles : Unified diff