dever 3 years ago
parent
commit
72c1dda34c
1 changed files with 3 additions and 2 deletions
  1. 3 2
      app/mshop/lib/Out.php

+ 3 - 2
app/mshop/lib/Out.php

@@ -343,7 +343,8 @@ class Out
                 unset($d[1]);
             }
             $body[] = $d;
-            $body_total['price'] += $v['price'];
+            $price = $v['price']*$v['num'];
+            $body_total['price'] += $price;
             $body_total['num'] += $v['num'];
         }
 
@@ -354,7 +355,7 @@ class Out
             $d = array
             (
                 '合计',
-                $body_total['price'],
+                round($body_total['price'], 2),
                 $body_total['num'],
             );