Hi Tom,

I have eventually sorted the problem by simply adding the fields to
the table, thus removing the need for embedded field, the abstraction
of the contact details wasn't actually necessary when I reviewed it
BUT
I think the issue was to do with where the FK was.

With sfGuardUSerProfile the FK is in the profile table whereas in my
setup the FK was on the parent table pointing at the contact profile
whcih I think is what was making a difference.

I haven't time to look into this now as pressing deadline but thought
I would update as to where I 'think' the problem was.

Thanks for your help, much appreciated.

TW

On May 27, 9:04 am, Tom Ptacnik <to...@tomor.cz> wrote:
> Ok, I think the problem might be in the actions.... I think you should
> realy move the embedForm function to the configure method of the form
> class - the form class will be more compact.
>
> And the thing that the rendering of the form is ok, and after the
> clicking on the save button the problem appers.... it indicate that
> something is wrong with executeNew,Create, Update and Edit actions.
>
> ... when rendering form .. executeNew and executeEdit is proccesed,
> and after the submit executeCreate and executeUpdate is processed.
> This might be a pointer.
>
> On 25 kvě, 15:27,Tofuwarrior<p...@clearintent.co.uk> wrote:
>
> > HI Tom,
>
> > Thanks for sticking with me on this, much appreciated.
> > I think I may have tried that before because when I do, 2 familar
> > things happen.
>
> > 1 Saem problem with the id being 1.
> > 2 is that when I try to view the edit action I get the following form
> > rendering error which dissappears when I comment out the embedForm
> > call.
>
> > Any other ideas?
>
> > I'm totally stuck.
>
> > Paul
>
> > You must pass an array of values to render a widget schema
> > stack trace
>
> >     * at ()
> >       in SF_ROOT_DIR/lib/vendor/symfony/lib/widget/
> > sfWidgetFormSchema.class.php line 536 ...
> >              533.
> >              534.     if (!is_array($values) && !$values instanceof
> > ArrayAccess)
> >              535.     {
> >              536.       throw new InvalidArgumentException('You must
> > pass an array of values to render a widget schema');
> >              537.     }
> >              538.
> >              539.     $formFormat = $this->getFormFormatter();
> >     * at 
> > sfWidgetFormSchema->render('mscdb_storyteller[contact_details_id]', 1, 
> > array(), null)
>
> >       in SF_ROOT_DIR/lib/vendor/symfony/lib/widget/
> > sfWidgetFormSchemaDecorator.class.php line 61 ...
> >               58.    */
> >               59.   public function render($name, $values = array(),
> > $attributes = array(), $errors = array())
> >               60.   {
> >               61.     return strtr($this->decorator, array('%content%'
> > => $this->widget->render($name, $values, $attributes, $errors)));
> >               62.   }
> >               63.
> >               64.   /**
> >     * at 
> > sfWidgetFormSchemaDecorator->render('mscdb_storyteller[contact_details_id]',
> >  1, array(), null)
>
> >       in SF_ROOT_DIR/lib/vendor/symfony/lib/widget/
> > sfWidgetFormSchema.class.php line 512 ...
> >              509.     $clone = clone $widget;
> >              510.     $clone->setIdFormat($this->options['id_format']);
>
> >              511.
> >              512.     return $clone->render($this->generateName($name), 
> > $value, array_merge($clone->getAttributes(),
>
> > $attributes), $errors);
> >              513.   }
> >              514.
> >              515.   /**
> >     * at sfWidgetFormSchema->renderField('contact_details_id', 1,
> > array(), null)
>
> > ..... ETC
>
> > --
> > If you want to report a vulnerability issue on symfony, please send it to 
> > security at symfony-project.com
>
> > You received this message because you are subscribed to the Google
> > Groups "symfony users" group.
> > To post to this group, send email to symfony-users@googlegroups.com
> > To unsubscribe from this group, send email to
> > symfony-users+unsubscr...@googlegroups.com
> > For more options, visit this group 
> > athttp://groups.google.com/group/symfony-users?hl=en

-- 
If you want to report a vulnerability issue on symfony, please send it to 
security at symfony-project.com

You received this message because you are subscribed to the Google
Groups "symfony users" group.
To post to this group, send email to symfony-users@googlegroups.com
To unsubscribe from this group, send email to
symfony-users+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/symfony-users?hl=en

Reply via email to