problem with class_name

0 views
Skip to first unread message

sahliali

unread,
Dec 14, 2009, 6:36:51 AM12/14/09
to restfulx-framework
hello,
in rails application i have
class Account < ActiveRecord::Base
has_many :orders, :foreign_key => 'owner_id'
has_many :seller_orders, :foreign_key => 'seller_id', :class_name
=> 'Order'

...
end

in my controller :

render :fxml => user.to_fxml(:include => {:account => {:include =>
{:role => {},
:orders => {},
:seller_orders => {},
}})


in my model flex i have :

public class Account extends RxModel {

[HasMany]
public var orders:ModelsCollection;

[HasMany]
public var sellerOrders:ModelsCollection;
....
}


but i have this problem :
not not been unmarshalled. Error: Error: cannot unmarshall
seller_order no mapping exists or received a node with invalid id
Reply all
Reply to author
Forward
0 new messages