Closed GeekOnCoffee closed 8 years ago
It should work for simple cases, where the association already exists in the DB, it can find the association based on a key and populate the loading model. See the examples, such as spec/fixtures/ProjectsSingleCategories.xls .. the loading Project can be populated with many Categories, being looked up by their reference.
In the Spree loader, we are not just finding associations but building them on the fly. I have started work on implementing support for a full definition of an association, within the column, in e.g json, enabling them to be built more generically and dynamically. this will form part of the major overhaul underway in the split_into_concerns branch
p.s the export of association in json, to a column should be in master already. See the column packer file
Is it possible to create a has_many record on import? Do i have to create a custom loader (like the Spree Product loader)?