Description:

Views fieldset style plugin module(drupal 7 only) adds ability to show views rows as fieldset. Basic idea/code for this project is taken from @dawehner's github views example module. It is different from views_fieldsets which offers completely different functionality of adding fieldset field where as this module shows output in fieldsets. More like views group by field functionality.

Similiar Project:

Dependencies (Drupal 7):

Project Page:

http://drupal.org/node/1867574

GIT Repository:

git clone --recursive --branch 7.x-1.x http://git.drupal.org/sandbox/jibran/1867574.git views_fieldset

Test Project

http://simplytest.me/project/1867574/7.x-1.x

PAReview.sh:

http://ventral.org/pareview/httpgitdrupalorgsandboxjibran1867574git

FILE: ...var/www/drupal-7-pareview/pareview_temp/views_plugin_style_fieldset.inc
--------------------------------------------------------------------------------
FOUND 6 ERROR(S) AFFECTING 3 LINE(S)
--------------------------------------------------------------------------------
 13 | ERROR | Class name must begin with a capital letter
 13 | ERROR | Class name must use UpperCamel naming without underscores
 18 | ERROR | Method name "views_plugin_style_fieldset::option_definition" is
    |       | not in lowerCamel format, it must not contain underscores
 18 | ERROR | No scope modifier specified for function "option_definition"
 32 | ERROR | Method name "views_plugin_style_fieldset::options_form" is not in
    |       | lowerCamel format, it must not contain underscores
 32 | ERROR | No scope modifier specified for function "options_form"
--------------------------------------------------------------------------------

These error's are regarding views coding standards which I can't really fix.

My Previous PAR attempt:

I have also created Views vertical tabs style plugin.

Output Screenshot:

http://drupal.org/files/project-images/Field%20Sets%20_%20d716_135560215...

CommentFileSizeAuthor
#8 views_fieldset_collapsible.png89.78 KBfederiko_

Comments

dawehner’s picture

$view->field[$field]->options['label']

Just for sanity, you should better escape that use input in the preprocess function.

The general code looks really clean and tidied up!

jibran’s picture

@dawehner thank you very much for the feedback.

Just for sanity, you should better escape that use input in the preprocess function.

For this $title = strip_tags(htmlspecialchars_decode($title)); is already there. I confirmed this with @dawehner on irc he said it is ok.
The code under discussion is at http://drupalcode.org/sandbox/jibran/1867574.git/blob/refs/heads/7.x-1.x....
And $title = strip_tags(htmlspecialchars_decode($title)); is at http://drupalcode.org/sandbox/jibran/1867574.git/blob/refs/heads/7.x-1.x....
Same example can be found at http://drupalcode.org/project/views.git/blob/HEAD:/plugins/views_plugin_...

lorenlang’s picture

Status: Needs review » Needs work

Not a major deal but there shouldn't be a closing PHP tag in views-view-fieldset.tpl.php, should there? I'm fairly new to module development so someone please correct me if I'm wrong.

jibran’s picture

Status: Needs work » Needs review

@llang tpl files can have html so everything outside the php tags will be treated as html. And yes tpl files can have a lot of php tags for more please see http://drupalcode.org/project/drupal.git/blob/refs/heads/7.x:/modules/sy...

klausi’s picture

We are currently quite busy with all the project applications and I can only review projects with a review bonus. Please help me reviewing and put yourself on the PAReview: review bonus high priority list. Then I'll take a look at your project right away :-)

Noe_’s picture

Status: Needs review » Needs work

I am seeing :

/**
 * @file
 * //Write Description
 */

Shouldn't you actually need to write a description before applying full project status?

jibran’s picture

Status: Needs work » Needs review

@Noe_ Thanks for pointing that out fixed in 353013d.

federiko_’s picture

StatusFileSize
new89.78 KB

I installed it and configured fieldset display.

Rows are displaying as expected in fieldsets.

When checking the collapsible option it seems I can't collapse the fieldset altough the markup seems correct (see attached file). Maybe I'm missing something in my drupal configuration. My test installation is the default one (default theme, default modules installed) with the latest version of drupal.

Everything looks good in your code.

jibran’s picture

Please attach the views export.

kscheirer’s picture

Status: Needs review » Reviewed & tested by the community

Nice little module, very clean. I found no major issues.

----
Top Shelf Modules - Enterprise modules from the community for the community.

jibran’s picture

Thank you @kscheirer. Let's hope PAR Team didn't find any other issue.

Baber Javed’s picture

Works Great, much needed views plugin!

RTBC+1

kscheirer’s picture

Title: Views fieldset style plugin » [D7] Views fieldset style plugin
Status: Reviewed & tested by the community » Fixed

Thanks for your contribution, jibran!

I updated your account to let you promote this to a full project and also create new projects as either a sandbox or a "full" project.

Here are some recommended readings to help with excellent maintainership:

You can find lots more contributors chatting on IRC in #drupal-contribute. So, come hang out and get involved!

Thanks, also, for your patience with the review process. Anyone is welcome to participate in the review process. Please consider reviewing other projects that are pending review. I encourage you to learn more about that process and join the group of reviewers.

Thanks to the dedicated reviewer(s) as well.

----
Top Shelf Modules - Crafted, Curated, Contributed.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.