5 * Install, update and uninstall functions for the draggableviews module.
8 use Drupal\views\Views;
11 * Implements hook_schema().
13 function draggableviews_schema() {
14 $schema['draggableviews_structure'] = [
15 'description' => 'Saves the order settings of a draggableview view.',
21 'description' => 'The primary identifier.',
28 'description' => 'Makes the order unique for each view.',
35 'description' => 'Makes the order unique for each view display.',
42 'description' => 'Makes the order unique for a given set of arguments',
48 'description' => 'Id of the entity that we are sorting (node, user, etc.).',
55 'description' => 'The order weight.',
62 'description' => 'The id of the parent.',
66 'view' => ['view_name', 'view_display', 'args', 'entity_id'],
67 'weight' => ['weight'],
68 'entity_id' => ['entity_id'],
70 'primary key' => ['dvid'],
77 * Implements hook_update().
79 function draggableviews_update_8104(&$sandbox) {
80 // the update hook here accidentally cropped in into 1.1 but it shouldn't be
81 // there, I belivee that removing it should be harmless.