Hey Brandon,
at the moment, locations stored via the locations_cck.module's CCK field, are stored in the resp. CCK-table as well as in the /locationlocation_instance tables - but there (in the location_instance table) they are *not* associated with the node's nid/vid.
Therefore, such nodes with location cck data are not showing in location-based/proximity-filtered views and other places.
I think this is the cause of some other issues, too (http://drupal.org/node/327381, http://drupal.org/node/333651).
The attached patch fixes this with a very small change to location_cck.module - please commit this to HEAD.
Perhaps this is meant to be by design (compare http://drupal.org/node/339459) but is nevertheless a problem in many cases. If the association of location_cck field data and the resp. node should not happen automatically in every case, then this should be made an option for the resp. cck-field.
| Comment | File | Size | Author |
|---|---|---|---|
| location_cck.module.SAVE_NID_NID.patch | 496 bytes | danielnolde |
Comments
Comment #1
droople commentedThis patch failed for http://drupal.org/node/327381 and http://drupal.org/node/333651
"Hunk #1 FAILED at 160.
1 out if 1 hunk FAILED -- Saving rejects to file location_cck_module.rej"
Thank you
Comment #2
danielnolde commentedthe patch was built against the location 6.x-3.x-dev version from 2008-12-05.
Maybe the resp. location-cck.module's file is slightly in the D5 version.
Then simply try to find manually the one line to alter, just look in the patch file and in the resp. code file, it's not too hard to patch in manually (since it is really just an extension to one single line).
Comment #3
asak commentedLooking in location_cck.module for D5 - I can't find such line...
Comment #4
socialnicheguru commentedi am having this problem too. it is frustrating i am on D5.10 and location 3.0. this patch is not working :(
Comment #5
socialnicheguru commentedthis worked to fix the proximity filters. It should be put into Head for 5.x.3. I include it because it might also work for location 6.
http://drupal.org/node/326749#comment-1155243
Comment #6
danielnolde commentedHey Brandon,
what about this small proposal & patch to "sync" the location_cck field values with location_instance table (one-line patch)?
By now, this is - intentionally - missing in the location_cck.module, rendering it useless for all kinds of location processing/search etc.!
Other people keep reporting this lack-by-design as bug, and need the functionality provided by above one-line patch (like http://drupal.org/node/327381 / http://drupal.org/node/333651 / http://drupal.org/node/382778 / http://drupal.org/node/63952 / http://drupal.org/node/363698 / http://drupal.org/node/386848 / http://drupal.org/node/391160 / http://drupal.org/node/366880 / http://drupal.org/node/346605 ).
This one-line patch is *really* simple to apply (like in one minute).
If you desperately want to stick to the lack-by-intention of not associating cck-locations with the location_instance-table, then would you at least be willing to commit a solution where the admin, when creating a location_cck field instance, can choose whether or not to associate a particular location_cck-field with the location_instance-table?
I would code this flexible version, if you are willing to commit this into location_cck.module, Brandon (just send me a private message, and i'll start).
cheers,
daniel
Comment #7
yesct commentedTagging.
I think there is also an attempt to fix this using a views relation
here #391160: CCK/Views: location_instance fix
and here #347030: location_cck needs a views relation
Comment #8
yesct commentedmarked #333651: CCK locations not appearing on google map as a duplicate of this issue.
Comment #9
yesct commentedmarked #344397: Location form using markup instead of fieldset as a duplicate of this issue [edit: opps fixed color coding of issue reference]
Comment #10
phillamb168 commentedHiya,
So, I'm thankful I ran across this post. My current version of CCK_Location (v 1.5.2.9 2009/02/25 17:42:14) on a D6 (latest version) is now fully functional within views once I run this patch. What do I need to do to confirm that this fixes the problem?
Comment #11
q0rban commentedSo, I ran into this same thing, but from what I can tell, this is not the proper fix (See this comment). Marking as duplicate of #383244: location_cck back compat and views support
Comment #12
pursuitofliberty commentedsub