|
@@ -12,23 +12,23 @@ type Cost interface {
|
|
type Deduction interface {
|
|
type Deduction interface {
|
|
}
|
|
}
|
|
|
|
|
|
-type LeftNumUserCost struct {
|
|
|
|
|
|
+type LeftNumCost struct {
|
|
AppID string
|
|
AppID string
|
|
ProductID int
|
|
ProductID int
|
|
LeftNum int
|
|
LeftNum int
|
|
ProductType int
|
|
ProductType int
|
|
DataNumLimitOneTimes int
|
|
DataNumLimitOneTimes int
|
|
}
|
|
}
|
|
-type AccountBalanceUserCost struct {
|
|
|
|
|
|
+type AccountBalanceCost struct {
|
|
AppID string
|
|
AppID string
|
|
ProductID int
|
|
ProductID int
|
|
AccountBalance int
|
|
AccountBalance int
|
|
}
|
|
}
|
|
|
|
|
|
-func (l *LeftNumUserCost) deduction() {
|
|
|
|
|
|
+func (l *LeftNumCost) deduction() {
|
|
}
|
|
}
|
|
|
|
|
|
-func (l *LeftNumUserCost) before() bool {
|
|
|
|
|
|
+func (l *LeftNumCost) before() bool {
|
|
switch l.ProductType {
|
|
switch l.ProductType {
|
|
case 0:
|
|
case 0:
|
|
//按次扣费的产品-判断left_num
|
|
//按次扣费的产品-判断left_num
|
|
@@ -44,13 +44,13 @@ func (l *LeftNumUserCost) before() bool {
|
|
return true
|
|
return true
|
|
}
|
|
}
|
|
|
|
|
|
-func (l *LeftNumUserCost) after() {
|
|
|
|
|
|
+func (l *LeftNumCost) after() {
|
|
switch l.ProductType {
|
|
switch l.ProductType {
|
|
case 0:
|
|
case 0:
|
|
case 1:
|
|
case 1:
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
|
|
-func (a *AccountBalanceUserCost) deduction() {
|
|
|
|
|
|
+func (a *AccountBalanceCost) deduction() {
|
|
|
|
|
|
}
|
|
}
|