1
0
Fork 0
mirror of https://github.com/Luzifer/sii.git synced 2024-10-18 05:14:19 +00:00
sii/block_profit_log_entry.go
Knut Ahlers 8ab2291202
Add new blocks
Signed-off-by: Knut Ahlers <knut@ahlers.me>
2019-12-11 18:51:35 +01:00

31 lines
925 B
Go

package sii
func init() {
RegisterBlock(&ProfitLogEntry{})
}
type ProfitLogEntry struct {
Revenue int64 `sii:"revenue"`
Wage int64 `sii:"wage"`
Maintenance int64 `sii:"maintenance"`
Fuel int64 `sii:"fuel"`
Distance int64 `sii:"distance"`
DistanceOnJob bool `sii:"distance_on_job"`
CargoCount int64 `sii:"cargo_count"`
Cargo string `sii:"cargo"`
SourceCity string `sii:"source_city"`
SourceCompany string `sii:"source_company"`
DestinationCity string `sii:"destination_city"`
DestinationCompany string `sii:"destination_company"`
TimestampDay int64 `sii:"timestamp_day"`
blockName string
}
func (ProfitLogEntry) Class() string { return "profit_log_entry" }
func (p *ProfitLogEntry) Init(class, name string) {
p.blockName = name
}
func (p ProfitLogEntry) Name() string { return p.blockName }