Trying to categorize aggregated items: when using checkbox method the checkboxes are not displayed. When using multiple-select, they are displayed, but clicking "Save Categories" does not add selected items to the category.

CommentFileSizeAuthor
#2 aggregator-categorization.patch1.43 KBjoshk

Comments

mgifford’s picture

Version: 4.7.0-beta4 » x.y.z

Verified this with a cvs version (original bug report was against the last beta release).

Went here:
aggregator/sources/2/categorize

Categorized a couple of items, hit Save Category and then there is an error message that says:

warning: Invalid argument supplied for foreach() in /var/www/wlp_play/modules/aggregator.module on line 1007.
The categories have been saved.

I created a patch to check to see that $form_values['categories'] was an array in:
foreach ($form_values['categories'] as $iid => $selection) {

But that didn't actually save the changes, so it's not worth contributing as a patch.

I think there's a problem with $form_values in 4.7, but don't know it enough to track it down any further.

This is set up with the Category module, but don't think that this is throwing things off here.

Mike

joshk’s picture

Status: Active » Needs review
StatusFileSize
new1.43 KB

Here's a patch. It does two things:

1) Changes the settings so that the variable stored if checkboxes are selected is 'checkboxes' rather than 'check.'

2) Changes the form_submit handler for categorization to correctly implement the new Form API

With these changes, categorization-per-item is back in action.

dries’s picture

Status: Needs review » Fixed

Committed to HEAD. Thanks.

Anonymous’s picture

Status: Fixed » Closed (fixed)