不要怂,就是干,撸起袖子干!

Commit b9ec63bd by Igor Nawrocki

small fix, and prittified indentation a bit

1 parent 6f43acd4
Showing with 7 additions and 13 deletions
...@@ -236,23 +236,17 @@ describe(Support.getTestDialectTeaser("Include"), function () { ...@@ -236,23 +236,17 @@ describe(Support.getTestDialectTeaser("Include"), function () {
} }
}); });
it('should work on pretty complicated case', function () { it('should work on pretty complicated case', function () {
var User = this.sequelize.define('User', { var User = this.sequelize.define('User', {})
}) , SubscriptionForm = this.sequelize.define('SubscriptionForm', {})
, SubscriptionForm = this.sequelize.define('SubscriptionForm', { , Collection = this.sequelize.define('Collection', {})
}) , Category= this.sequelize.define('Category', {})
, Collection = this.sequelize.define('Collection', { , SubCategory = this.sequelize.define('SubCategory', {})
}) , Capital = this.sequelize.define('Capital', {});
, Category= this.sequelize.define('Category', {
})
, SubCategory = this.sequelize.define('SubCategory', {
})
, Capital = this.sequelize.define('Capital', {
});
Capital.hasMany(Category, { foreignKey: 'boundCapital'}) Capital.hasMany(Category, { foreignKey: 'boundCapital'})
SubCategory.belongsTo(Category, {foreignKey: 'boundCategory'}) SubCategory.belongsTo(Category, {foreignKey: 'boundCategory'})
Category.belongsTo(Capital, {foreignKey:'boundCapital'}) Category.belongsTo(Capital, {foreignKey:'boundCapital'})
Category.hasMany(SubCategory, {foreignKey:'boundCapital'}) Category.hasMany(SubCategory, {foreignKey:'boundCategory'})
Category.hasMany(SubscriptionForm, {foreignKey:'boundCategory'}) Category.hasMany(SubscriptionForm, {foreignKey:'boundCategory'})
Collection.belongsTo(SubscriptionForm, {foreignKey:'boundDesigner'}) Collection.belongsTo(SubscriptionForm, {foreignKey:'boundDesigner'})
SubscriptionForm.belongsTo(User, {foreignKey:'boundUser'}) SubscriptionForm.belongsTo(User, {foreignKey:'boundUser'})
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!