Brilliant module! But at the moment I'm in need of a way to include an edit-form in panels, so that the user can change his data. (The edit form is a Content_Profile node.)

Is there a way to include an existing node as an editable form with FormBlock and not just an empty form?

Comments

Bilmar’s picture

subscribing - I'm interested if this is possible as well.
thanks

robby.smith’s picture

Category: task » support

+1 subscribing

mikey_p’s picture

gewillson’s picture

Subscribing to this, the active one of the duplicates.
I too want to add or edit a Content Profile node in a block.

bkno’s picture

Subscribing. Would be great to have edit forms added to this module!

Currently I'm using my own solution in a block (PHP input format) that utilises Drupal functions:

<?php
  global $user;
  $type = 'preferences';
  module_load_include('inc', 'node', 'node.pages');
  $node = node_load(array("type" => $type, "uid" => $user->uid));
  if ($node) {
    $form = drupal_get_form($type .'_node_form',  $node);
    print_r($form);
  }
?>

I can't think of another way of doing this. Would have thought it would be a good way to approach the problem, however this block seems to have terrible performance implications for me when an authenticated user lands on the page (30 seconds load time). If you don't have +100k nodes though maybe it's fine for most sites. Thoughts/improvements?

MM10’s picture

Subscribing.

nedjo’s picture

The question would be, how to provide the block with contextual information on which node is to be edited?

Because we're putting forms in a block, we can't assume any particular context from the path.

Probably the most likely way would be providing a context-aware Panels plugin?

Maybe Panels already does this?

smira’s picture

panels does provide the possibility of adding node edit forms within it (or inside a minipanel <-- basically the same as a block)
the problem i have had is with adding multiple node edit minipanels in the same panel.
for this problem the above example code is perfect!
I'm not sure what you would enhance in this module other than maybe the possibility to make it a node-edit block instead of a node-add block with the click of a button?
then it would simply be generalizing the code posted above by bkno so that it takes the argument from the block edit panel or the current node it's put in?
anyway, thank you for your help here, and the cool module!

tchopshop’s picture

Wouldn't the editable fields module work better for you in this case? Each field you set would be edited right there on the node, not in a block.

mtconto’s picture

I'm a newbie, so a little confused. I am building a website where my users enter their athletic activities on a given day (a run, for example... with the distance, duration, time of day, etc etc etc as details). People should should be able to comment on the run ("Good Job") the run should be able to be posted on Activity or Heartbeat, you should be able to subscribe to the person's "logs" so you are notified when he updates.

Lots of cool functionality. I'm trying to figure out what is the best way to create a form for this type of data entry.

The data needs to be editable... and it also needs to be able to be pulled into different views throughout the site.

I created a "logs" page that will, in theory, contain views of my latest workouts, upcoming races, favorite running routes, etc, but most importantly, a calendar where I can click on a "add" button on a given date to get the aforementioned logging form to popup for entry.

Been adding content on the page through panels...

Is this the right block for me? If not, what is?

smira’s picture

i can see where this block would work for you.
i would simply create a content type with the fields that are necessary (run time in your example), and add this block on the page somewhere appropriate for the athlete to create a new node of that type and track his improvement.
as far as commenting goes you could use the core commenting functionality and track all of it with Activity or Heartbeat.

cgdrupalkwk’s picture

To do this there's a new module called Editable Views. The only view type that works is one that comes with the module called "Editable Table" which displays the info in a typical views table format. Using some very simple CSS I was able to make it look just like a form display by Form Block. Contextual info is handled like you would in any View Block. Hope this helps!

Triumphent’s picture

@smiro
I have been struggling for weeks to add a node edit/create form within a panel. Do you know if there is a tutorial somewhere explaining or showing how to do this?
Any pointer would be greatly appreciated.
Thanks.
:)

milos.kroulik’s picture

Issue summary: View changes

Yeah, I'm wondering about this too.

mikey_p’s picture

Status: Active » Closed (outdated)

I haven't see any updates on this issue in while, and it's filed against 6.x which is now unsupported, so I'm closing this for now.