diff --git a/src/myaktion/model/account.go b/src/myaktion/model/account.go index d2e74b4cdd30b686069fcdf3bb5de02e6c677189..8628334be9a6880bc3d3e8d6c3e793b41a6f70ea 100644 --- a/src/myaktion/model/account.go +++ b/src/myaktion/model/account.go @@ -1,7 +1,7 @@ package model type Account struct { - Name string - BankName string - Number string + Name string `json:"name"` + BankName string `json:"bankName"` + Number string `json:"number"` } diff --git a/src/myaktion/model/campaign.go b/src/myaktion/model/campaign.go index 2fb5dcf3c64d8a9f79a089117b6e4fe30f2a8b18..d7e04b66de67186ed7dbb460b2635422eb1cd442 100644 --- a/src/myaktion/model/campaign.go +++ b/src/myaktion/model/campaign.go @@ -1,11 +1,11 @@ package model type Campaign struct { - Name string - OrganizerName string - TargetAmount float64 - DonationMinimum float64 - AmountDonatedSoFar float64 - Account Account - Donations []Donation + Name string `json:"name"` + OrganizerName string `json:"organizerName"` + TargetAmount float64 `json:"targetAmount"` + DonationMinimum float64 `json:"donationMinimum"` + AmountDonatedSoFar float64 `json:"amountDonatedSoFar"` + Account Account `json:"account"` + Donations []Donation `json:"donations"` } diff --git a/src/myaktion/model/donation.go b/src/myaktion/model/donation.go index 4c80e6d8a6a16b0f76ec78d1180a28f103372f05..972e21981c776041f99c089d2047947b2d6e2558 100644 --- a/src/myaktion/model/donation.go +++ b/src/myaktion/model/donation.go @@ -6,11 +6,11 @@ const ( ) type Donation struct { - Amount float64 - DonorName string - ReceiptRequested bool - Account Account - Status Status + Amount float64 `json:"amount"` + DonorName string `json:"donorName"` + ReceiptRequested bool `json:"receiptRequested"` + Account Account `json:"account"` + Status Status `json:"status"` } type Status string