Browse Source

Merge branch 'lang' into dev

lang 3 years ago
parent
commit
f7ec959269
1 changed files with 3 additions and 4 deletions
  1. 3 4
      Controller/CloudStorage.py

+ 3 - 4
Controller/CloudStorage.py

@@ -1181,13 +1181,12 @@ class CloudStorageView(View):
                 return response.json(10049)
             price = Decimal(price)
             coupon_discount = Decimal(couponQuery[0]['coupon_discount'])
-            if couponQuery[0]['type'] == 1:  #折
+            if couponQuery[0]['type'] == 1:  #
                 price = coupon_discount/10 * price
             elif couponQuery[0]['type'] == 2:  #抵扣
                 price = price - coupon_discount
-            if price < 0:
-                return response.json(10049)
-
+            if price < 0 or price == 0:
+                price = 0.01
         price = round(float(price), 2)
         if pay_type == 1:
             # 订阅周期扣款