Bugs item #1415402, was opened at 2006-01-26 05:17
Message generated for change (Tracker Item Submitted) made by Item Submitter
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=540672&aid=1415402&group_id=74338
Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: None
Group: None
Status: Open
Resolution: None
Priority: 5
Submitted By: Nobody/Anonymous (nobody)
Assigned to: Nobody/Anonymous (nobody)
Summary: sqlmeta's addJoin ignores joinMethodName
Initial Comment:
1. Started with a dbase .py with something like this;
---
class <existing_table>( SQLObject ):
.. bla ..
.. bla ..
.. bla ..
---
2. then I added:
---
class <new_relation>( SQLObject ):
.. bla ..
.. bla ..
---
3. Then I did:
python
from my_dbase import existing_table, new_relation
existing_table.sqlmeta.addJoin( RelatedJoin(
'new_relation', joinMethodName='lookatmynewclass' ) )
4. Then I changed my initial setup to:
---
class <existing_table>( SQLObject ):
.. bla ..
.. bla ..
.. bla ..
lookatmynewclass = RelatedJoin( 'new_relation' )
---
5. Now when I do:
---
my_object = existing_table.selectBy(
mywhatever='something' )
print dir( my_object )
---
There is a attribute "new_relations" (new class + 's')
instead of (what I expected) "lookatmynewclass".
6. I have worked around this by changing my class
definition to:
---
class <existing_table>( SQLObject ):
.. bla ..
.. bla ..
.. bla ..
lookatmynewclass = RelatedJoin( 'new_relation',
joinMethodName='lookatmynewclass' )
---
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=540672&aid=1415402&group_id=74338
|