Re: falsefalse

2010-03-01 Thread John Andersen
I am using 1.2.5 John On Mar 1, 6:18 pm, LunarDraco wrote: > Which vs of cake are you both using? > > Also you may want to read this post which talks a little bit about > containable and hasmany relations. Breaks down when it will work and > when it won't work. Maybe that will give you some id

Re: falsefalse

2010-03-01 Thread LunarDraco
Which vs of cake are you both using? Also you may want to read this post which talks a little bit about containable and hasmany relations. Breaks down when it will work and when it won't work. Maybe that will give you some ideas about what might be wrong with your setup or how your making the call

Re: falsefalse

2010-02-28 Thread Arak Tai'Roth
Okay, well, I'm still not sure, because everything you did is the same as me from what I can tell, except you didn't specify fields grabbed in your models. I removed that info in mine, but that didn't change anything. I'm not sure, but I have a feeling this all relates to the fact that contain doe

Re: falsefalse

2010-02-28 Thread John Andersen
Ok, have recreated your situation - and it just works! My result: [result] Array ( [Permit] => Array ( [id] => 1 [created] => 2010-02-28 10:55:16 [user_id] => 1 [leader_id] => 1 [registration_location_id] => 1 ) [U

Re: falsefalse

2010-02-28 Thread John Andersen
Could be! I am trying to recreate your situation here at my place, to confirm that I too can't retrieve the Country. Will be back shortly :) John On Feb 28, 10:40 am, "Arak Tai'Roth" wrote: > This is the only thing that is even remotely relevant in app_model: > > var $actsAs = array( >        

Re: falsefalse

2010-02-28 Thread Arak Tai'Roth
This is the only thing that is even remotely relevant in app_model: var $actsAs = array( 'Containable' ); Other then that, there are only 2 functions, one for validating phone numbers, and one for changing dates to a format I want. Like I have said previou

Re: falsefalse

2010-02-28 Thread John Andersen
Ok, if you don't use the Country model, then you are using the AppModel, how does it look like? Enjoy, John On Feb 28, 10:31 am, "Arak Tai'Roth" wrote: > They are all lowercase, I'm not that new at this. > > Exact code for the leader model for the relationships was already > posted above. > >

Re: falsefalse

2010-02-28 Thread Arak Tai'Roth
They are all lowercase, I'm not that new at this. Exact code for the leader model for the relationships was already posted above. And as I said, I tested it with a Country model and that did not help, and as such I removed it as I don't see a point in a file that doesn't add any value. On Feb 28

Re: falsefalse

2010-02-28 Thread John Andersen
Ok, that is fine, but can you tell me exactly what are the filenames of your models? They should all be lowercase! Also please show the exact code for the Leader model (leader.php) and the Country model (country.php) from the beginning to the end of the relationship/association definition. Enjoy,

Re: falsefalse

2010-02-27 Thread Arak Tai'Roth
I did indeed do that when you had first asked me if I had made the model. It didn't change anything. On Feb 26, 12:43 am, John Andersen wrote: > I would first try to create the Country model, with all the necessary > associations/relationships, and then try again. > Enjoy, >    John > > On Feb 25

Re: falsefalse

2010-02-25 Thread John Andersen
I would first try to create the Country model, with all the necessary associations/relationships, and then try again. Enjoy, John On Feb 25, 10:53 pm, "Arak Tai'Roth" wrote: > I tried with just something simple: > > $dbpermit = $this->Permit->find('first', array( >                            

Re: falsefalse

2010-02-25 Thread Arak Tai'Roth
I someone yet able to see where I am going wrong? On Feb 25, 2:53 pm, "Arak Tai'Roth" wrote: > I tried with just something simple: > > $dbpermit = $this->Permit->find('first', array( >                                 'conditions' => array( >                                         'Permit.id' =>

Re: falsefalse

2010-02-25 Thread Arak Tai'Roth
I tried with just something simple: $dbpermit = $this->Permit->find('first', array( 'conditions' => array( 'Permit.id' => $id ), 'contain' => array(

Re: falsefalse

2010-02-25 Thread John Andersen
Ok, understood :) Then maybe take it step by step - make a find from Permit with contain Leader and nothing more. If it works, expand the find with Country. If it still works, expand with ProvState. and so on. Then tell us your result of the step by step method :) John On Feb 25, 10:24 pm, "A

Re: falsefalse

2010-02-25 Thread Arak Tai'Roth
I had indeed read the same things as you had. I did try them, but I was leery to say the least. I have never defined the foreignKey in the fields array and I've never had a problem. Same with defining the models. I never work directly on those models ever, so I don't need them. Same goes for Regist

Re: falsefalse

2010-02-25 Thread John Andersen
To summarize your relationships/associations between your models, I got the following: Permit HABTM Activity Permit belongsTo RegistrationLocation Permit belongsTo User Permit belongsTo Leader Leader hasMany Permit Leader belongsTo User Leader belongsTo Country Leader belongsTo ProvState Not that

Re: falsefalse

2010-02-25 Thread Arak Tai'Roth
I'll post the important parts. My models are slightly bigger then this, but they only contain other associations not related to this, validation, or functions. This is Permit.php var $hasAndBelongsToMany = array( 'Activity' => array( 'classN