From: Vsevolod (S. I. <si...@cs...> - 2003-12-23 17:12:34
|
> Coincidentally, I made a change in 0.80 that allows you to do: > > SPOPS class: SPOPS_Books > Your class: MyBooks isa SPOPS_Books > SPOPS class: SPOPS_Publisher > Your class: MyPublisher isa SPOPS_Publisher > > Then declare in your publisher configuration: > > links_to => { MyBooks => 'link_table' } Chris, I may be doing something wrong, but I hit another snag. I am trying to use objects that refer to each other, and I use links_to in both configuration. (I call them Job and Task, but they are similar in their relationship to Publisher and Book). I attach the four class files and the script that tries to use them. I inherit Job from SPOPS_Job and Task from SPOPS_Task. The SPOPS configuration refers to Common.pm, which would be different in your case. There are four possible configurations: SPOPS_Job links to SPOPS_Task, SPOPS_Task links to SPOPS_Job SPOPS_Job links to Task, SPOPS_Task links to SPOPS_Job SPOPS_Job links to SPOPS_Task, SPOPS_Task links to Job SPOPS_Job links to Task, SPOPS_Task links to Job The first three work, but the last one, which is of greater interest, does not. Could you please look at this and tell me if I am doing anything wrong? The error message is: Cannot run behavior in [links_to] [SPOPS_Job]: Failed to retrieve configuration from Compilation failed in require at Job.pm line 5. The tables that the config files refer to are created thusly: CREATE TABLE `Job` (`job_id` int(11)); CREATE TABLE `Task` (`task_id` int(11)); CREATE TABLE `JobToTask` (`id` int(11), `job_id` int(11), `task_id` int(11)); Merry Christmas! Thanks, Simon -- Simon (Vsevolod ILyushchenko) si...@cs... http://www.simonf.com America's business leaders simply don't want to think about complex technology issues - they want to think about golf. Microsoft promises them that. Andrew Grygus, www.aaxnet.com |