-
-
Save SlyDen/cd4ed4c2c86eae7abadc to your computer and use it in GitHub Desktop.
Revisions
-
koemeet revised this gist
Mar 24, 2016 . 1 changed file with 1 addition and 1 deletion.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -6,7 +6,7 @@ export default DS.Model.extend({ // app/models/product-variant.js export default DS.Model.extend({ product: DS.belongsTo('product', { inverse: null }), master: DS.attr('boolean') }); -
koemeet revised this gist
Mar 24, 2016 . No changes.There are no files selected for viewing
-
koemeet created this gist
Mar 24, 2016 .There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,12 @@ // app/models/product.js export default DS.Model.extend({ masterVariant: DS.belongsTo('product-variant'), variants: DS.hasMany('product-variant') // only contains the variants that are not master }); // app/models/product-variant.js export default DS.Model.extend({ product: DS.belongsTo('product'), master: DS.attr('boolean') });