I updated this to Panels 3. It brings up the relationship in the UI and allows me to add the node content so I think it's all ok. I need to convert the CCK panels content types before I can test it thoroughly, though. Should get to that this weekend.

Michelle

Comments

socialnicheguru’s picture

Thanks for the heads up on this.

Where do I place this file?

thanks!

michelle’s picture

@activelyOUT: This was meant for fago. If you want to help out by testing, you replace the existing file with this updated one.

@fago: I have completed the CCK changes and confirmed this updated file works fine with Panels 3. Merlinofchaos will be deprecating Panels 2 and unpublishing it when Panels 3 beta is out so I suggest timing with that for the changeover.

Michelle

socialnicheguru’s picture

Michelle,

I am interested in helping to test.

can you give me the path in which to place the file?

Thanks

michelle’s picture

Assuming you use the standard location, sites/all/modules/content_profile.

Michelle

fago’s picture

>so I suggest timing with that for the changeover.

Yep, that sounds fine! However I'm no panels user (yet) so I have to rely on the community's/your tests for that - so testers please give feedback.. :)

socialnicheguru’s picture

I tried it and it worked just fine.

michelle’s picture

Title: Panels 3 integration » Content Profile - Panels 3 relationship
StatusFileSize
new993 bytes
new1.77 KB

Here's an update based on what I learned while working on the field/fieldgroup integration. The patch file only changes the .module. Making a patch to move files around is beyond me. My pseudopatch:

-content_profile.panels.inc
+content_profile/panels/relationships/node_from_user.inc

Hopefully this can be committed soon. Now that Panels 3 is in beta and CCK has committed the field/fieldgroup patches, this is the last bit I need before I can release a P3 based Alpha of APK.

Thanks,

Michelle

WorldFallz’s picture

I'd like to help out with the testing on this so let me see if I understand correctly which modules to use:

content_profile dev + #7
panels3 - beta 1
ctools - beta 1
apk dev
author_pane dev
cck - dev

Is that correct?

michelle’s picture

Yes except skip apk/ap. They aren't stable enough and will just confuse your testing. Just make a new page to override the user page and check that you get the relationship to show up and that you are then able to add things from the node context.

Thanks!

Michelle

WorldFallz’s picture

Ok, lets see if I got this right (sorry I'm being such a n00b-- i'm totally lost in the panels3 ui, lol):

1. goto admin/build/panels
2. select 'user view' from the drop down
3. add a 'panel' handler
4. continue past the criteria (didn't add any)
5. choose a layout (i selected 2 col stacked)
6. save and go back to add the relationship on the context tab

After all that-- I don't have any content areas showing up on the panel content tab.

Did I miss a step somewhere?

EDIT: not sure what happened, but clearing the cache a few times fixed the problem. I was able to add fields and content from content profile nodes no problem.

Not related but just an fyi-- I noticed you can only add the 'user profile' (from the core profile module) as a whole (not the individual fields) and also the location info from location module was not available (probably an issue for that module).

michelle’s picture

Status: Needs review » Reviewed & tested by the community

Glad you figured it out because I was baffled. I was going to step thru it all once I got here to the Y. :)

As for core profile, I don't believe you've ever been able to add individual fields from that. Someone would need to write content types to handle it. Since I don't use core profile, it's going to have to be someone else. ;)

I'm going to be so bold as to mark this RTBC. My mission for my 2 hours of childcare here at the Y is to finish porting APK over to P3 and this relationship is vital for it to be useful.

Thanks,

Michelle

WorldFallz’s picture

I haven't had the need for advanced user profiles, so these are just random thoughts from a curious novice. With fields in core in d7, and probably the demise of the profile module, it's probably not even worth pursuing at this point.

i played around with content_profile and panels some more and didn't manage to break anything, so it should be good to go.

There was one potentially confusing thing (at least it confused me)-- on the "Content" vertical tab in the add content popup on the panel content screen I had the ability to add any fields from any content type to the user view panel. I couldn't get it to break anything, but it threw me off because I only expected to see fields from the content_profile designated content types there. Not sure if that's related to this issue or panels in general though.

michelle’s picture

@WorldFallz: That means the restriction code isn't working. That's something I haven't had a chance to test, yet. Will copy this over to the other issue.

Thanks,

Michelle

summit’s picture

subscribing, greetings, Martijn

michelle’s picture

Status: Reviewed & tested by the community » Needs work

Ok, according to http://drupal.org/node/414298#comment-1568174 the fields/fieldsets not being restricted is coming from here. So that's something I need to fix in this patch.

For anyone wanting to use this, the existing patch does work. It just doesn't provide the needed information to restrict what field/fieldsets show up in add content.

Michelle

prdsp’s picture

This patch works well when I create my own task handler, however, when I add a content profile cck field to the task handler created by APK it doesn't show on the user profile page.

Also, I'm not sure where I should post this but is there any chance Michelle, Merlin & Alex.K can get together and take a look at the integration of panels 3, the content profile patch here, and the new UR field Perms module...for more details please see my post #10 located here http://drupal.org/node/304317

If all 3 of these could work together it would be very powerful.

michelle’s picture

@prdsp: Strange since, obviously, APK uses this. As for the UR thing, that wouldn't have anything to do with this patch. That needs to be made to work with the CCK field integration. It's something I'm interested in but I'm pretty swamped so don't know when I'll have time to look at it.

@all: I haven't forgotten this issue. Just juggling too much.

Michelle

foodbo’s picture

subscribing

uprojects’s picture

Thanks Michelle !

arcane’s picture

I had some problems getting this to work. I'm using:

Content Profile 6.x-1.x-dev from April 22
Chaos Tools 6.x-1.0-beta3 from May 20th
Panels 6.x-3.0-beta2 from May 20th

I applied step #7:
- Moved node_from_user.inc to content_profile/panels/relationships/node_from_user.inc
- Applied patch cp_ctools_beta3.patch

I am able to see my profile CCK fields in the Panels interface. However they do not display in the APK panel (btw I am using APK-alpha3)

michelle’s picture

@arcane: APK has a lot of moving parts at this point and getting the whole thing to work is out of scope for this patch. If you were able to add the relationship and get a node context, then the patch is working. Aside from the type restriction that needs to be added, of course.

Michelle

arcane’s picture

Thanks Michelle, that's good to know. I can help test when it's ready.

waddles’s picture

I am seeing very strange behaviour with this issue. The patches all seem to work okay though.

I have users with a role 'artist' and content_profile content called 'Profile' with CCK fields. On a direct copy of a site I've had running for about 9 months, I cannot get any user data to display when I override the default user page. I kept going over and over the comments here thinking I had missed something then finally decided I had done everything right.

I then made a fresh drupal install and symlinked the sites/all/ directory to the original sites/all and enabled content_profile, ctools and panels (not cck); created a user with the role 'artist' and edited the user's 'Profile' page with lipsum. Then I followed the directions exactly as before and voila! the user's Profile content shows in panels.

But wait. I'm using the same code with the same content type and roles so if I export the panels definition from the working site and import it into the original site it should work, right? Wrong. I get all the other panel content, but not the user's Profile content. wtf?

The original site is multi-lingual so I tried to break the test site by enabling Content translation and Profile translation too but still Profile content shows up. So I can't make the original site work but I can't make the test site break either.

Any other suggestions?

summit’s picture

Hi,

I had maybe the same issues with views. Maybe after some update of panels or ctools, somewhere the connection is lost between the added-content and the panels/ctools data.
What I had to do with views is clone the view to a exact copy and then the view-panes of this "new" view popped up inside my panels/ctools add-content little-screen :)
I hope this is valuable information for this thread. Because the "old" views content is still not shown somehow.
greetings, Martijn

waddles’s picture

I worked out the problem I had with cp content not showing up. When the cp profile content type (admin/content/node-type/profile) had Multilingual support Enabled, with translation there was a bug in content_profile_load() that prevented it from loading profiles with no language set. See #461262: Content profile can't handle translated profiles for more.

dddave’s picture

I want to check this out and have downloaded the required modules in their latest stages. So now I have to apply the patch in #7 but where do I have to put node_from_user.inc_.txt?

#20 mentioned a location but I don't see content_profile/panels/relationships/ . I only have content_profile.panels.inc and don't have a panels folder.
Do I have to create it?

Could please somebody clarify the process. Thanks in advance!

michelle’s picture

dddave: #7 is the comment you want to look at. You need to delete the line with the - and add the line with the +.

Michelle

dddave’s picture

Oh my gosh. I cannot believe that I spent all the time on this "problem" and then it boils down to not reading the most important post correctly.

Sorry! Sorry! Sorry!

michelle’s picture

@dddave: It's ok. This topic has wandered a bit. My fault for not making time to get the last remaining piece on this finished so it can get committed.

Actually, I wish fago would at least commit what we have. It's not broken in the sense that it's unusuable. It's just not quite finished because it doesn't have the code to limit the field/fieldgroups you see to just what is availbable to the context. Instead, you get all of them on the site. But, since that's how it worked in Panels 2 anyway, I don't think it's that big of a deal for the moment.

Michelle

fago’s picture

Title: Content Profile - Panels 3 relationship » improve Panels 3 relationship

ok, I've done so -> committed..! I'm going to release beta4 now, so it's in there.

Anway, I noted

    'settings form validate' => 'content_profile_node_from_user_ctools_settings_form_validate',

But there is no such function? Probably this should be fixed too.

michelle’s picture

Thanks, fago. I'm still deep in forum stuff but will get back to this ASAP.

Michelle

fei’s picture

subscribing

Daniel A. Beilinson’s picture

So, is there the way to expose content profile fields in apk's panel? Not whole node, I mean fields and groups.

michelle’s picture

Status: Needs work » Fixed

@La_ntegral: Yes, just pick the field/fieldgroup when you are adding content.

Also, marking this one fixed since merlinofchaos started a new issue for the last remaining issue in #523078: Have content profile relationships limit CCK field availability in Panels

Michelle

Daniel A. Beilinson’s picture

Status: Fixed » Active

@Michelle: I saw this ability, but that's not work. I can add fields and fieldgroups, but can't see them in profile node.
Those Merlin's patch kills this ability of adding content.

I also see this with clean acquia installation.

michelle’s picture

Status: Active » Fixed

The relationship works, this issue is fixed. If you are having problems using the CCK/Ctools integration, please file a new support request.

Michelle

esmerel’s picture

deriene thinks http://drupal.org/node/484694 is a dup of this and I am inclined to agree.

Status: Fixed » Closed (fixed)

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