« Return to Thread: How can I use Flex to access foreign-keyed fields in Django?

Re: How can I use Flex to access foreign-keyed fields in Django?

by Joel Hooks :: Rate this Message:

Reply to Author | View in Thread

DjangoAMF doesn't handle it at all, you simply get the title_id:int back (as you do with PyAMF). It is also unsupported (for all practical purposes) and has some fairly crippling errors. Do not want.

Nick explained to me earlier this month how to override the Cache creation class to build your own custom cache. I would bet you could do this and attach the object cleanly to the returned object. I haven't tried this yet, but it is on my list of things to do. I will report back if I have success. Will probably test it out tonight.

On Mon, Jan 26, 2009 at 3:35 PM, Bryan Hughes <huuuze@...> wrote:
Thanks for the response.  From what I gather, adding the _cache fields to my VO seems a little dirty.

Does anyone know if DjangoAMF handles this dilemma in a cleaner manner?



On Mon, Jan 26, 2009 at 4:30 PM, Joel <imlowdown@...> wrote:
"I personally hate this and wish it was either cleaner or more controllable (in an easy way)."

I should add, but not so much that I get off my lazy butt and contribute to the project in a meaningful way. Thanks PyAmf dev team, you guys are awesome! I would like to turn off the caching globally though :>


On Mon, Jan 26, 2009 at 3:24 PM, Joel <imlowdown@...> wrote:
http://pastebin.com/m2ffcb77d

I use these methods to grab related models and whatnot.


ReferenceError: Error #1056: Cannot create property _title_cache on com.myproject.models.vo.BookVO

If you create a TitleVO object and then make a _title_cache:TitleVO property it will do some ORM bits. I personally hate this and wish it was either cleaner or more controllable (in an easy way).

-joel


On Mon, Jan 26, 2009 at 3:01 PM, Bryan Hughes <huuuze@...> wrote:
I need some help!  Please see the question I posted here:

http://stackoverflow.com/questions/481110/how-can-i-use-flex-to-access-foreign-keyed-fields-in-django

Does anyone know of a solution?  The one posted in the thread results in the following error:

ReferenceError: Error #1056: Cannot create property _title_cache on com.myproject.models.vo.BookVO

_______________________________________________
PyAMF users mailing list - users@...
http://lists.pyamf.org/mailman/listinfo/users




_______________________________________________
PyAMF users mailing list - users@...
http://lists.pyamf.org/mailman/listinfo/users



_______________________________________________
PyAMF users mailing list - users@...
http://lists.pyamf.org/mailman/listinfo/users



_______________________________________________
PyAMF users mailing list - users@...
http://lists.pyamf.org/mailman/listinfo/users

 « Return to Thread: How can I use Flex to access foreign-keyed fields in Django?