customer/edit/1
<?php echo $this->Form->create('Customer');?>
<fieldset>
<legend><?php __('Edit Customer'); ?></legend>
<?php
echo $this->Form->input('User.username', array('label' =>
__('Username', true)));
echo $this->Form->input('User.password', array('label' =>
__('Password', true), 'value'=>''));
echo $this->Form->input('User.password_confirm', array('type' =>
'password', 'label' => __('Password confirm', true),'value'=>''));
echo $this->Form->input('Customer.business_name', array('label'
=>
__('Business name', true)));
echo $this->Form->input('Customer.governamental_code',
array('label'
=> __('Governamental code', true)));
?>
</fieldset>
<?php echo $this->Form->end(__('Submit', true));?>
==> just show values for "Customer" table fields (business_name,
governamental_code). Why?
On 4 jul, 20:20, Davor Ilic <[email protected]> wrote:
> show your edit.ctp
>
> 2010/7/5 guvilla <[email protected]>
>
> > TABLE
> > Groups: id, nome
> > Users: id, username, password, group_id
> > Customers: id, governamental_code, business_name, user_id
> > Employee: id, name, user_id
>
> > MODEL
> > USER
> > var $belongsTo = array(
> > 'Group' => array(
> > 'className' => 'Group',
> > 'foreignKey' => 'group_id'
> > ),
> > 'Customer' => array(
> > 'className' => 'Customer',
> > 'foreignKey' => 'id'
> > )
> > );
>
> > CUSTOMER
> > var $hasOne = array(
> > 'User' => array(
> > 'className' => 'User',
> > 'foreignKey' => 'id',
> > )
> > );
>
> > MY PROBLEM:
> > when I access /customer/edit/1, only shows customer data, but not user
> > data. I don't know how to solve... Who knows?
>
> > Check out the new CakePHP Questions sitehttp://cakeqs.organd help others
> > with their CakePHP related questions.
>
> > You received this message because you are subscribed to the Google Groups
> > "CakePHP" group.
> > To post to this group, send email to [email protected]
> > To unsubscribe from this group, send email to
> > [email protected]<cake-php%[email protected]>For
> > more options, visit this group at
> >http://groups.google.com/group/cake-php?hl=en
>
>
Check out the new CakePHP Questions site http://cakeqs.org and help others with
their CakePHP related questions.
You received this message because you are subscribed to the Google Groups
"CakePHP" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected] For more options, visit this group at
http://groups.google.com/group/cake-php?hl=en