Kirin před 2 roky
rodič
revize
b61a13feaa
1 změnil soubory, kde provedl 1 přidání a 1 odebrání
  1. 1 1
      app/controller/api/v1/PublicController.php

+ 1 - 1
app/controller/api/v1/PublicController.php

@@ -70,7 +70,7 @@ class PublicController extends BaseController
             ->where('is_system_del', 0)
             ->where('refund_status', 0)
             ->whereIn('status', [2, 3])
-            ->sum('(total_price-cost)');
+            ->field('sum(total_price-cost) as total_price_sum')->find();
         var_dump($order_price);
     }