The base class sync method expects to work on an @result variable that is in "Generic Results" form. Specifically this is a HASH OF HASHES where the hash key of the outer hash is the ID of each object. Each hash key in the inner hash represents an attribute of an individual object. Note that ALL DATATYPES MUST BE OF TYPE STRING (so the hash values need to all be strings not integers). For example:
@result={"1"=>{"name"=>"Acme","industry"=>"Electronics"},"2"=>{"name"=>"Best","industry"=>"Software"}}
But it appears from looking at the code that the result format is expected to be an array. Sure enough if I do the following experiment, I can see results in the RhoSync app:
def sync
@result = [{"id"=>"1", "name"=>"Acme","industry"=>"Electronics"},{"id"=>"2", "name"=>"Best","industry"=>"Software"}]
super
end
I assume that is just some old cruft in the wiki, but let me know if I'm missing something.
The tutorial also references a lighthouse app which looks like it used to be in git:
but has since been removed.
Please let me know if I'm looking in the right places or if there are some other docs I should be digging into while exploring Rhodes.
Thanks,
Sarah