瀏覽代碼

add city for electric refill

stanley-king 2 年之前
父節點
當前提交
b295d44864
共有 1 個文件被更改,包括 5 次插入0 次删除
  1. 5 0
      mobile/control/refill.php

+ 5 - 0
mobile/control/refill.php

@@ -240,6 +240,9 @@ class refillControl extends merchantControl
         if(empty($params['province']) || !array_key_exists($params['province'],mtopcard\ProvinceList)) {
             return [false,"请传入省份"];
         }
+        if(empty($params['city'])) {
+            return [false,"请传入城市名称"];
+        }
         //如果是南方电网需要带身份证后六位
         if($params['company_type'] === 'south')
         {
@@ -269,6 +272,7 @@ class refillControl extends merchantControl
         $company_type = $_GET['company_type'];
         $use_type = $_GET['use_type'];
         $province = intval($_GET['province']);
+        $city = $_GET['city'];
         $amount = intval($_GET['amount']);
 
         if($company_type == 'nation') {
@@ -306,6 +310,7 @@ class refillControl extends merchantControl
             'company_type' => $company_type,
             'use_type' => $use_type,
             'province' => $province,
+            'city' => $city,
             'card_id' => $card_id
         ];