更新若干
This commit is contained in:
1 parent
54c90072fb
commit
5682069553
59 files changed
+3813
-1617
No files matched your search
@@ -92,6 +92,7 @@ type tenantPackagePayload struct {
|
||||
ExtraUserPrice *float64 `json:"extra_user_price"`
|
||||
IsDefault *int8 `json:"is_default"`
|
||||
AllowRepurchase *int8 `json:"allow_repurchase"`
|
||||
CanPurchase *int8 `json:"can_purchase"`
|
||||
Sort *int `json:"sort"`
|
||||
Status *int8 `json:"status"`
|
||||
Remark string `json:"remark"`
|
||||
@@ -182,6 +183,7 @@ func (c *PlatformTenantPackageController) GetPackageList() {
|
||||
"extra_user_price": r.ExtraUserPrice,
|
||||
"is_default": r.IsDefault,
|
||||
"allow_repurchase": r.AllowRepurchase,
|
||||
"can_purchase": r.CanPurchase,
|
||||
"sort": r.Sort,
|
||||
"status": r.Status,
|
||||
"remark": r.Remark,
|
||||
@@ -241,6 +243,7 @@ func (c *PlatformTenantPackageController) GetPackageSelectList() {
|
||||
"extra_user_price": r.ExtraUserPrice,
|
||||
"is_default": r.IsDefault,
|
||||
"allow_repurchase": r.AllowRepurchase,
|
||||
"can_purchase": r.CanPurchase,
|
||||
"modules": modules,
|
||||
"module_codes": moduleCodes(modules),
|
||||
})
|
||||
@@ -401,6 +404,7 @@ func (c *PlatformTenantPackageController) CreatePackage() {
|
||||
ExtraUserPrice: valueFloat(p.ExtraUserPrice, services.DefaultTenantExtraUserPrice),
|
||||
IsDefault: valueInt8(p.IsDefault, 0),
|
||||
AllowRepurchase: valueInt8(p.AllowRepurchase, 1),
|
||||
CanPurchase: valueInt8(p.CanPurchase, 1),
|
||||
Sort: valueInt(p.Sort, 0),
|
||||
Status: valueInt8(p.Status, 1),
|
||||
Remark: strings.TrimSpace(p.Remark),
|
||||
@@ -491,6 +495,9 @@ func (c *PlatformTenantPackageController) EditPackage() {
|
||||
if p.AllowRepurchase != nil {
|
||||
update["allow_repurchase"] = *p.AllowRepurchase
|
||||
}
|
||||
if p.CanPurchase != nil {
|
||||
update["can_purchase"] = *p.CanPurchase
|
||||
}
|
||||
|
||||
allowRepurchase := int8(1)
|
||||
if p.AllowRepurchase != nil {
|
||||
|
||||
Reference in new issue
Block a user