drupal sevilla: views 2 vs views3

15
Drupal Sevilla V2 vs V3

Upload: francisco-jose-seva-mora

Post on 16-Jul-2015

966 views

Category:

Technology


0 download

TRANSCRIPT

Page 1: Drupal sevilla: Views 2 vs Views3

Drupal Sevilla

V2 vs V3

Page 2: Drupal sevilla: Views 2 vs Views3

Index

V2 vs V3Differences

● frontend: basic schema● backend: functionals differences● backend: code differences

Similarities● #Queries

How to <whatever.x> in V3?whatever 1: exposed filters (Group by)whatever 2: Pager as a plugin whatever 3: Query pluginwhatever 4: Add fields from a new tablewhatever 5: Relationships 3 levelswhatever 6: Custom computed fields

Page 3: Drupal sevilla: Views 2 vs Views3

V2 vs V3:Differences:Frontend

Create view page pages and block could be pre-configure

Views panelNew format and order

Page 4: Drupal sevilla: Views 2 vs Views3

V2 vs V3:Differences:Frontend

And you, What do you think?

Page 5: Drupal sevilla: Views 2 vs Views3

V2 vs V3:Differences:Frontend

Page 6: Drupal sevilla: Views 2 vs Views3

V2 vs V3:Differences:backend:functionals

SQL backend: Make as much funcionality pluggable as possible- Pluggins for queries, the branch 3.x origin- Other data sources: Whatever restfull API- Views integration- Apache SolrMerlin of Chaos said: http://www.angrydonuts.com/views-3-x-roadmapOther sources: http://www.cuencodigital.com/articulos/views_3_a_fondo.html http://www.lullabot.com/articles/querying-slave-database-with-views

OR, HAVING, GROUP BY clauses, - No more "Views OR"- We have aggregation a.k.a Group by

Page 7: Drupal sevilla: Views 2 vs Views3

Pager, exposed & i18n- System more pluggable- Now we can change and specific funtionality, we are working with classes and inheritance (i.e exposed filters)- We'll see how to!!

Multiple footer and headers- Depends of the context- <IMHO>I think it's too limited, </IMHO>

V2 vs V3:Differences:backend:functionals

Page 8: Drupal sevilla: Views 2 vs Views3

V2 vs V3:Differences:backend:code- System more pluggable- More comments- Add new compatibilities (many settings differences between V2 and v3 - Introduce Group by- A lot of commented functions - Hooks

● V2 #hooks = 23 || V3 #hooks = 21● New hooks in V3

○ hook_views_ajax_data_alter: This hook allows to alter the commands which are used on a views ajax request.

○ hook_views_invalidate_cache: Allow modules to respond to the Views cache being invalidated.○ hook_views_ui_display_top_links_alter: This hooks allows to alter the links at the top of the view

edit form. Some modules might want to add links there.● Removed hooks in V3

○ hook_views_convert○ hook_views_handlers: How should we do it?○ hook_views_form_submit○ hook_views_form_validate○ hook_views_admin_links_alter

Page 9: Drupal sevilla: Views 2 vs Views3

How to <whatever.x> in V3?

whatever 1: exposed filters (Group by)whatever 2: Pager as a plugin whatever 3: Add filter from new tablewhatever 4: Add fields from a new tablewhatever 5: Relationships 3 levelswhatever 6: Custom computed fields

Page 10: Drupal sevilla: Views 2 vs Views3

How to <whatever.x> in V3?: whatever1

whatever 1: exposed filters

Let's start with Drupal!!!

Page 11: Drupal sevilla: Views 2 vs Views3

How to <whatever.x> in V3?:whatever2

whatever 2: Pager as a plugin

Let's see code and try to explain it!!!Infinite Scroll

http://drupalcode.org/project/views_infinite_scroll.git/tree

Page 12: Drupal sevilla: Views 2 vs Views3

How to <whatever.x> in V3?: whatever3

whatever 3: Add fields from a new table

Page 13: Drupal sevilla: Views 2 vs Views3

How to <whatever.x> in V3?: whatever4

whatever 4: Add filter from new table

Page 14: Drupal sevilla: Views 2 vs Views3

How to <whatever.x> in V3?: whatever5

whatever 5: Add pluging

Page 15: Drupal sevilla: Views 2 vs Views3

Thanks to all!!Any Question?