30 lines
729 B
Go
30 lines
729 B
Go
package main
|
|
|
|
import "time"
|
|
|
|
type User struct {
|
|
Id int64 `db:"id"`
|
|
Name string `db:"name"`
|
|
Username string `db:"username"`
|
|
MessageCount int `db:"message_count"`
|
|
Karma int `db:"karma_history"`
|
|
KarmaSent int `db:"karma_sent_history"`
|
|
KarmaReceived int `db:"karma_received_history"`
|
|
Created time.Time `db:"created"`
|
|
}
|
|
|
|
type Karma struct {
|
|
Id int `db:"id"`
|
|
From int `db:"from_user"`
|
|
To int `db:"to_user"`
|
|
Change int `db:"change"`
|
|
Message string `db:"message"`
|
|
Created time.Time `db:"created"`
|
|
}
|
|
|
|
type TotalKarma struct {
|
|
Id int64 `db:"id"`
|
|
Name string `db:"name"`
|
|
Total int `db:"total"`
|
|
}
|