I've been pulling my hair out trying to get them to work together. The biggest problem seems to be that the flag weight doesn't show up on the list of fields when I select FieldAPI. When I save a new ordering, the information seems to get lost and I assume it's because it can't see the Flag Weight.

The documentation on integrating the two, btw, has a number of minor incompatibilities because it was written for Drupal 6. I would update it but I can't seem to get it to work.

CommentFileSizeAuthor
#3 1545968-3.patch4.27 KBistryker
#2 1545968-2.patch3.94 KBistryker

Comments

henrijs.seso’s picture

Title: DraggableViews and Flag Weights don't seem to work with Drupal 7 » Add compability with DraggableViews 2.x
Category: bug » feature

I think this best describes issue. It seems that DraggableViews 2.x has developed little further and Flag Weights needs to catch up.

istryker’s picture

Status: Active » Needs review
StatusFileSize
new3.94 KB

I've upgraded flag_weight to support draggableviews 2.x. I needed this for my new module - User Priority Ranking

FYI - Draggableviews 2.x now uses Ctools, this patch supports this.

istryker’s picture

StatusFileSize
new4.27 KB

Ignore last patch. There was a syntax error in the flag_weights.module in 1545968-2.patch. There was also a bug I found. To fix this I've extended/added a 'get' class function.

Attached is the new patch applied against master

Andre-B’s picture

Status: Needs review » Reviewed & tested by the community

thank you very much. this patch works. had some trouble to apply this patch in my local environment.

instructions to apply this easily:

1. open a terminal
2. navigate in the parent folder where you want to store the flag_weights module (can be inside the drupal sites/all/modules but does not have to)

git clone --recursive --branch master http://git.drupal.org/project/flag_weights.git
cd flag_weights
curl -O http://drupal.org/files/1545968-3.patch
git apply 1545968-3.patch

4. if you already cloned the module in sites/all/modules your good to go, elsewise copy the content (maybe exclude the .git folder) of the flag_weights folder in your current flag_weights module to patch it. (select overwrite files)

dandaman’s picture

I have tried this on my site and it works as well. Thanks for the patch! It'd be nice if this or something similar gets added soon.

lyricnz’s picture

Tested and committed. Creating a new release.

lyricnz’s picture

Status: Reviewed & tested by the community » Fixed

Applied in 84ff325. Thanks!

Status: Fixed » Closed (fixed)

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

robin van emden’s picture

Issue summary: View changes

For this to work with the latest version of Flag with patch from #1877304: Support Flag 7.x-3.x we had to make a change to the patch by replacing $row->flag_content_node_weight with $row->flagging_node_weight in row 25.