Преглед изворни кода

计算利润或者营业额

linhaohong пре 1 година
родитељ
комит
dff1257e4c
1 измењених фајлова са 1 додато и 2 уклоњено
  1. 1 2
      AdminController/CloudServiceManage/AgentDeviceController.py

+ 1 - 2
AdminController/CloudServiceManage/AgentDeviceController.py

@@ -165,8 +165,7 @@ class AgentDeviceView(View):
 
 
             # 根据利润类型计算利润或者直接使用营业额
             # 根据利润类型计算利润或者直接使用营业额
             if metric_type == 1:  # 利润
             if metric_type == 1:  # 利润
-                profit = package.profit if package.profit_type == 1 else order.profit_amount * package.profit / Decimal(
-                    '100.00')
+                profit = order.profit
             else:  # 营业额
             else:  # 营业额
                 profit = order.profit_amount
                 profit = order.profit_amount