Was wondering if there is a delay function i could use in my
controller , to force cake to wait for a find() function to execute...
This is the situation iam in....

 $temp=$this->Invno->find('all',array('conditions'=>''.
$conditions,'fields'=>array('id')));
 $this->data['invno_id']=0;
$this->data['invno_id']=$temp[0]['Invno']['id'];

Now i wish to execute this statement only after $this->data
['invno_id'] had been set
$this->Invoice->save($this->data)

but for some reason there is an observed delay and the program just
halts....

i did this to check if there is a delay--
$temp=$this->Invno->find('all',array('conditions'=>''.
$conditions,'fields'=>array('id')));
 $this->data['invno_id']=0;
$this->data['invno_id']=$temp[0]['Invno']['id'];

if($this->data['invno_id']!=0)
{
 $this->Invoice->save($this->data);
}
else
{
 $this->Session->setFlash('There is a delay in getting the invno_id');
 $this->redirect('/invoices',null,true);
}

I keep getting the message "There is a delay in getting the invno_id".
Can someone help me with a workaround?

Will appreciate any help...

forrestgump
--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---

Reply via email to