forked from free-lancers/electricity_bill_calc_service
feat(charge):基本完成所有用户服务延期记录部分的功能,待测。
This commit is contained in:
@@ -7,16 +7,19 @@ import (
|
||||
)
|
||||
|
||||
type UserCharge struct {
|
||||
Created `xorm:"extends"`
|
||||
Seq int64 `xorm:"bigint pk not null " json:"seq"`
|
||||
UserId string `xorm:"varchar(120) not null" json:"userId"`
|
||||
Fee decimal.Decimal `xorm:"numeric(12,2) not null" json:"fee"`
|
||||
Discount decimal.Decimal `xorm:"numeric(5,4) not null" json:"discount"`
|
||||
Amount decimal.Decimal `xorm:"numeric(12,2) not null" json:"amount"`
|
||||
Settled bool `xorm:"bool not null default false" json:"settled"`
|
||||
SettledAt *time.Time `xorm:"timestampz" json:"settledAt" time_format:"simple_datetime" time_location:"shanghai"`
|
||||
Refunded bool `xorm:"bool not null default false" json:"refunded"`
|
||||
RefundedAt *time.Time `xorm:"timestampz" json:"refundedAt" time_format:"simple_datetime" time_location:"shanghai"`
|
||||
Created `xorm:"extends"`
|
||||
Seq int64 `xorm:"bigint pk not null autoincr" json:"seq"`
|
||||
UserId string `xorm:"varchar(120) not null" json:"userId"`
|
||||
Fee decimal.NullDecimal `xorm:"numeric(12,2)" json:"fee"`
|
||||
Discount decimal.NullDecimal `xorm:"numeric(5,4)" json:"discount"`
|
||||
Amount decimal.NullDecimal `xorm:"numeric(12,2)" json:"amount"`
|
||||
ChargeTo time.Time `xorm:"date not null" json:"chargeTo" time_format:"simple_date" time_location:"shanghai"`
|
||||
Settled bool `xorm:"bool not null default false" json:"settled"`
|
||||
SettledAt *time.Time `xorm:"timestampz" json:"settledAt" time_format:"simple_datetime" time_location:"shanghai"`
|
||||
Cancelled bool `xorm:"bool not null default false" json:"cancelled"`
|
||||
CancelledAt *time.Time `xorm:"timestampz" json:"cancelledAt" time_format:"simple_datetime" time_location:"shanghai"`
|
||||
Refunded bool `xorm:"bool not null default false" json:"refunded"`
|
||||
RefundedAt *time.Time `xorm:"timestampz" json:"refundedAt" time_format:"simple_datetime" time_location:"shanghai"`
|
||||
}
|
||||
|
||||
func (UserCharge) TableName() string {
|
||||
|
Reference in New Issue
Block a user