From a1af6ac52f17d33cf80c75181a8aa8c181554cf7 Mon Sep 17 00:00:00 2001 From: smavros Date: Sun, 14 Apr 2019 21:03:34 +0200 Subject: [PATCH] Added comment --- common/database.go | 2 ++ 1 file changed, 2 insertions(+) diff --git a/common/database.go b/common/database.go index 3c9fae3..75bc55a 100644 --- a/common/database.go +++ b/common/database.go @@ -123,6 +123,8 @@ func DummyPopulateDB(test_db *gorm.DB) { checkErr(test_db.Create(&widg_B).Error) // Associations betweend models + // For `belongs to` use the model with id=1 + // For `has many` use the models with id=1 and id=2 test_db.Model(&smo_A).Association("Simulation").Append(&simn_A) test_db.Model(&smo_A).Association("Simulator").Append(&simr_A)