rabin %!s(int64=3) %!d(string=hai) anos
pai
achega
bc148db09a

+ 18 - 0
app/cash/lib/Cron.php

@@ -175,4 +175,22 @@ class Cron
         }
         return $id;
     }
+
+    # 修正礼品卡结算单金额,之前是九折,现在不是了
+    public function up_cash_api()
+    {
+        $order = Dever::db('shop/order')->select();
+        if ($order) {
+            foreach ($order as $k => $v) {
+                if ($v['card_code_cash'] > 0) {
+                    # 礼品卡订单
+                    $info = Dever::db('cash/order')->select(array('pay_type' => 2, 'source_order_num' => $v['order_num']));
+                    if ($info) {
+                        
+                    }
+                }
+            }
+        }
+    }
+
 }

+ 2 - 1
app/shop/lib/Refund.php

@@ -465,7 +465,8 @@ class Refund
                         } else {
                             $zhe = $card_info['price']/$card_info['value'];
                         }
-                        $price = round($card_cash*$zhe, 2);
+                        //$price = round($card_cash*$zhe, 2);
+                        $price = $card_cash;
                         $rorder = $order;
                         $rinfo = $info;
                         $rorder['type'] = 1;

+ 6 - 3
app/shop/lib/Sell.php

@@ -396,7 +396,8 @@ class Sell
                             } else {
                                 $zhe = $card_info['price']/$card_info['value'];
                             }
-                            $price = round($data['card_code_cash']*$zhe, 2);
+                            //$price = round($data['card_code_cash']*$zhe, 2);
+                            $price = $data['card_code_cash'];
                             $data['type'] = 1;
                             $data['type_id'] = $data['shop_id'];
                             $data['source_type'] = 4;
@@ -1190,7 +1191,8 @@ class Sell
                     } else {
                         $zhe = $card_info['price']/$card_info['value'];
                     }
-                    $price = round($card['cash']*$zhe, 2);
+                    //$price = round($card['cash']*$zhe, 2);
+                    $price = $card['cash'];
                     $order_data['type'] = 1;
                     $order_data['type_id'] = $order_data['shop_id'];
                     $order_data['source_type'] = 4;
@@ -1453,7 +1455,8 @@ class Sell
                         } else {
                             $zhe = $card_info['price']/$card_info['value'];
                         }
-                        $price = round($info['card_code_cash']*$zhe, 2);
+                        //$price = round($info['card_code_cash']*$zhe, 2);
+                        $price = $info['card_code_cash'];
                         $info['type'] = 1;
                         $info['type_id'] = $info['shop_id'];
                         $info['source_type'] = 4;

+ 1 - 0
service/agent/src/Address.php

@@ -48,6 +48,7 @@ class Address extends Core
 
     private function getInfo($data)
     {
+        $data['address'] = str_replace('undefined', '', $data['address']);
         $data['address_info'] = $data['add_string'] = $data['address'] . $data['house_number'];
         $data['province_name'] = $data['city_name'] = $data['county_name'] = '';
         if ($data['county']) {

+ 2 - 2
service/mail/database/area_entry.php

@@ -10,7 +10,7 @@ return array
     'menu' => 'agent',
     'end' => array
     (
-        'insert' => 'mail/lib/manage.updateArea_entry', 
+        //'insert' => 'mail/lib/manage.updateArea_entry', 
     ),
     # 数据结构
     'struct' => array
@@ -35,7 +35,7 @@ return array
             'match'     => 'is_numeric',
             'desc'      => '',
             'update'    => 'month',
-            'search'    => 'month',
+            'search'    => 'month_eq',
             'callback'  => 'maketime',
             'list'      => 'date("Y-m", {month})',
         ),