Tweaking JSON field naming convention for emberjs

This commit is contained in:
Matthew Dillon 2014-11-26 17:18:22 -09:00
parent aadb24bf33
commit 4bbd67dd4f
12 changed files with 41 additions and 41 deletions

View file

@ -12,10 +12,10 @@ import (
// A User is a person that has administrative access to bactdb.
type User struct {
Id int64 `json:"id,omitempty"`
UserName string `json:"user_name"`
CreatedAt time.Time `db:"created_at" json:"created_at"`
UpdatedAt time.Time `db:"updated_at" json:"updated_at"`
DeletedAt time.Time `db:"deleted_at" json:"deleted_at"`
UserName string `json:"userName"`
CreatedAt time.Time `db:"created_at" json:"createdAt"`
UpdatedAt time.Time `db:"updated_at" json:"updatedAt"`
DeletedAt time.Time `db:"deleted_at" json:"deletedAt"`
}
func NewUser() *User {