Skip to content
Snippets Groups Projects
Commit 37c60dc0 authored by Emanuel Petrinovic's avatar Emanuel Petrinovic
Browse files

add json mapping to modells

parent 2978693d
No related branches found
No related tags found
No related merge requests found
package model package model
type Account struct { type Account struct {
Name string Name string `json:name`
BankName string BankName string `json:bankname`
Number string Number string `json:number`
} }
package model package model
type Campaign struct { type Campaign struct {
ID uint ID uint `json:id`
Name string Name string `json:name`
OrganizerName string OrganizerName string `json:organizername`
TargetAmmount float64 TargetAmmount float64 `json:targetammount`
DonationMinimum float64 DonationMinimum float64 `json:donationminimum`
AmmountDonatedSoFar float64 AmmountDonatedSoFar float64 `json: ammountdonatedsofar`
Donations []Donation Donations []Donation `json: donations`
Account Account Account `account`
} }
package model package model
type Donation struct { type Donation struct {
Ammount float64 Ammount float64 `json:ammount`
DonorName string DonorName string `json:donorname`
ReceiptRequested bool ReceiptRequested bool `json:receiptrequested`
Status Status Status `json:status`
Account Account Account `json:account`
} }
type Status string type Status string
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment