Comment Upload needs Views 2.0 (beg pardon) integration. aclight wrote a lot of Views 1 code, which might be useful.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

Heine’s picture

Assigned: Unassigned » netaustin

Assigning

netaustin’s picture

This simple integration is probably all that's needed at the moment--this exposes the comment_upload table and its relationships to files, nodes, and comments to views2. The attached views file should be created in a directory named "views" and renamed to comment_upload.views.inc.

netaustin’s picture

Status: Active » Needs review
masood_mj’s picture

does anyone used this patch? I cannot find any change in views fields or relationships related to comment upload files

dummas_324324_32’s picture

anyone tested this patch?

Heine’s picture

Instead of asking if anyone did so, please test the patch and report back here.

dummas_324324_32’s picture

I´ll tried it, but it isn`t working :-((( anyone any idea?

there was an error while patching

.../sites/all/modules/comment_upload# patch < views_30.patch
patching file comment_upload.install
Hunk #1 FAILED at 164.
patch: **** replacement text or line numbers mangled in hunk at line 18

dummas_324324_32’s picture

it will be very nice if someone can fix this ;-)

yhahn’s picture

FileSize
2.97 KB

Here is a re-rolled patch. Works as expected.

RikiB’s picture

Im trying to use Views to display attached images and tried applying this patch. However in the fields there is only file description, nothing about displaying the actual images. Is there any way to do this?

MatthijsG’s picture

The "group files block" (template from Views or so) shows only the attachments attached to the node, not to comments. Does the patch add a option in views and is it working? I don't see anywhere anyone a positive result.

livewire1337’s picture

Has this been added to the alpha5 release? I am trying to use this with views but I don't see it as an available relationship.

askibinski’s picture

FileSize
62.63 KB

Looking at the code: the patch hasn't been committed to either alpha5 or -dev version.

However yhahn's patch in #5 applies cleanly to alpha5.

You will then be able to create a Views relationship and show the attaches files together with the ones attached to the parent node in a - for example - table view.

We used this in Open Atrium to get a better overview of uploaded files, but I dont' think it's currently possible to link the comment files (as you can see in the screenshot the .txt file is not linked while the other one (attached to the node) is.

Robberti’s picture

Hi, I'm having trouble with the patch in #9.

I editted my Comment_upload.module on line 94 where i added

/**
* Implementation of hook_views_api().
*/
function comment_upload_views_api() {
return array(
'api' => 2.0,
'path' => drupal_get_path('module', 'comment_upload') .'/views',
);
}

/**
* Alter the comment form to support AHAH uploads.
*
* Note; not a hook implementation.

and created a new file "comment_upload.views.inc" where i put the code from <?php till the end in.

But still i'm not able to show the comment_uploaded images in my view.

skizzo’s picture

subscribing

tinny’s picture

How does one apply this patch? I want to help out but dont know how.

soulfroys’s picture

Please, someone has already solved this?

Exploratus’s picture

Interested in this.

tezalsec’s picture

Subscribing to #14.

Tried patch #9, nothing becomes available in views options as described in #13

steeph’s picture

Status: Needs review » Needs work

The patch applied succesfully. But I don't see anything new in Views (2.16).

seanB’s picture

Manually applied the patch from nr 2. Adding relations to nodes/comments from a files view works perfectly! Thnx.