Open zaigham opened 9 years ago
Case matters for aliases: it must be "Children" -- use the graph function to help identify the aliases available.
I just fixed the case, and ran seed command. I got this error:
ERROR: build_attributes not set for modResource-->Children in composer.json. Make sure your definitions include "related_objects" and "related_object_attributes"
Would you please shed some light on this?
For each object, you need to describe its behavior when it comes to primary key, creates vs. updates, etc. This is done via the build_attributes. E.g. look at https://github.com/craftsmancoding/repoman/wiki/composer.json
So you could include something like the following in your "extra" --> "build_attributes" node in your composer.json:
"build_attributes":{
"modResource": {
"preserve_keys": true,
"update_object": true,
"unique_key": ["alias"],
"related_objects": true,
"related_object_attributes": {
"Children": {
"preserve_keys":
"update_object": true,
"unique_key": ["alias"]
}
}
}
}
I have tried this, still couldnt get the children docs in there. The data is same as above json.
This is my buid_attributes section:
"build_attributes":{
"modResource": {
"preserve_keys": true,
"update_object": true,
"unique_key": ["alias"],
"related_objects": true,
"related_object_attributes": {
"Children": {
"preserve_keys": true,
"update_object": true,
"unique_key": ["alias"]
}
}
}
}
Hmm... I'll have to troubleshoot and write up a tutorial.
As per twitter conversation: https://twitter.com/craftsmancoding/status/615949782897463296
The following dataset only created parent page. and thats it. Please see the data sample below: