I am trying to essentially create a split screen view, one grid of a remote repository full of products, and another alongside it showing the local repository in a grid.
I think that essentially sums it up, I’ll give partial credit if you can tell me how to simply incorporate the remote source into the grid… I think I could handle it from there even. Please be thoughtful, I don’t really want to hear how to configure my resources in the config.xml, I already can do that with a remote database, i just can’t get the objects/collections to load from it.
Thanks guys.
OK– So for those of us who’ve tried something like this, the first thing you realize is that when you want more than one database as a source in your module… you actually need 2 modules to do so (someone chime in and correct me if i’m wrong).
Step 1: Create a “dummy” module to connect with your remote database. This module should pretty much just contain etc/ and Model/ — there’s no real need for anything else. My config.xml looks as follows:
Now you’ll need the following model and resource files:
In Product.php:
In Mysql4/Product.php
And In Mysql4/Product/Collection.php
Just barebones type stuff, like you’d do for any basic model in Magento. Now from another module, that’s rigged to any other database, probably/possibly your local instance, you can access this remote data store by invoking your dummy object, if you wanted to test this just do something simple like:
…and this model should function just like your typical product model for the most part, except you’re using a remote database, happy coding!