Browse Source

Merge branch 'raccount' into rchannel

xiaoyu 2 years ago
parent
commit
0c9ddac843
33 changed files with 429 additions and 100 deletions
  1. 1 0
      admin/config/config.ini.php
  2. 37 0
      admin/control/merchant.php
  3. 194 0
      admin/templates/default/merchant.goods.php
  4. 8 4
      admin/templates/default/merchant.index.php
  5. 38 38
      data/config/xyz/refill.ini.php
  6. 42 42
      data/config/yl/refill.ini.php
  7. 13 1
      data/model/thrid_refill.model.php
  8. 2 0
      helper/rbridge/fulu_ylyw/product.php
  9. 7 1
      helper/rbridge/fulu_ylyw/readme.txt
  10. 2 2
      helper/refill/RefillBase.php
  11. 9 0
      helper/refill/api/xyz/dazhanggui_high/api.txt
  12. 5 0
      helper/refill/api/xyz/dazhanggui_high/config.php
  13. BIN
      helper/refill/api/xyz/dezhi_fs/20221226广西移动调价函.jpg
  14. 2 1
      helper/refill/api/xyz/dezhi_fs/config.php
  15. BIN
      helper/refill/api/xyz/guochuang/20221221辽宁移动调价函.png
  16. BIN
      helper/refill/api/xyz/guochuang/20221222广东移动调价函.png
  17. BIN
      helper/refill/api/xyz/guochuang/20221223广东移动调价函.png
  18. 2 2
      helper/refill/api/xyz/guochuang/config.php
  19. BIN
      helper/refill/api/xyz/meixu_fs/20221226辽宁移动调价函.jpg
  20. 1 1
      helper/refill/api/xyz/meixu_fs/config.php
  21. 2 0
      helper/refill/api/xyz/ruixunda/config.php
  22. 4 1
      helper/refill/api/xyz/ruixunda/对接文档-yezi.txt
  23. BIN
      helper/refill/api/xyz/ruixunda_fs/20221219四川移动调价函.png
  24. 1 1
      helper/refill/api/xyz/ruixunda_fs/config.php
  25. 1 0
      helper/refill/api/xyz/yunchonggongfs/config.php
  26. 5 0
      helper/refill/api/yl/dazhanggui_high/config.php
  27. 2 1
      helper/refill/api/yl/dezhi_fs/config.php
  28. 2 2
      helper/refill/api/yl/guochuang/config.php
  29. 2 0
      helper/refill/api/yl/ruixunda/config.php
  30. 1 1
      helper/refill/api/yl/ruixunda_fs/config.php
  31. 1 0
      helper/refill/api/yl/yunchonggongfs/config.php
  32. 13 2
      mobile/control/refill.php
  33. 32 0
      test/TestThirdRefill.php

+ 1 - 0
admin/config/config.ini.php

@@ -26,6 +26,7 @@ $config['receive_bank'] = [
         '多益优平安',
         '多益优招行',
         '多益优交行',
+        '游来有旺招行',
     ],
     'LZKJ_COMPANY' => [
         '琳珠收款'

+ 37 - 0
admin/control/merchant.php

@@ -69,6 +69,43 @@ class merchantControl extends SystemControl
         Tpl::showpage('merchant.index');
     }
 
+    public function merchant_goodsOp()
+    {
+        global $config;
+        $mchid = $_GET['mchid'] ?? $_POST['mchid'];
+        $model_merchant = Model('merchant');
+        $merchant = $model_merchant->getMerchantInfo(['mchid' => $mchid], '*', true);
+        if (empty($merchant)) {
+            showMessage('机构信息有误');
+        }
+        if(chksubmit()){
+            $goods = $_POST['items'];
+            $data = [];
+            foreach ($goods as $card_type => $prices) {
+                foreach ($prices as $price) {
+                    $data[$card_type][] = intval($price);
+                }
+            }
+            wcache('merchant_goods', [$mchid => serialize($data)], 'refill-');
+            showMessage('操作成功');
+        }else{
+            $refill_specs = [
+                'chinamobile' =>  $config['refill_phone_specs'],
+                'chinaunicom' =>  $config['refill_phone_specs'],
+                'chinatelecom' => $config['refill_phone_specs']
+            ];
+
+            $merchant_goods = rcache('merchant_goods', 'refill-', $mchid);
+            $goods = $merchant_goods[$mchid] ?? serialize([]);
+            $goods = unserialize($goods);
+
+            Tpl::output('merchant', $merchant);
+            Tpl::output('goods', $goods);
+            Tpl::output('refill_specs', $refill_specs);
+            Tpl::showpage('merchant.goods');
+        }
+    }
+
     public function changeStateOp()
     {
         $mchid = intval($_GET['mchid']);

+ 194 - 0
admin/templates/default/merchant.goods.php

@@ -0,0 +1,194 @@
+<?php defined('InShopNC') or exit('Access Invalid!'); ?>
+<script src="https://cdnjs.cloudflare.com/ajax/libs/mathjs/3.16.0/math.min.js"></script>
+<script>
+    math.config({
+        number: 'BigNumber',
+        precision: 20
+    });
+</script>
+<style>
+    .disInput {
+        background: #ccc;
+        cursor: not-allowed;
+    }
+
+    .spec_table {
+        width: 420px;
+        border-right: 1px solid #CBE9F3;
+    }
+
+    .spec_table .batch {
+        vertical-align: middle;
+        display: inline-block;
+        *display: inline
+            /*IE7*/
+        ;
+        margin-left: 4px;
+        position: relative;
+        z-index: 1;
+        *zoom: 1
+            /*IE7*/
+        ;
+    }
+
+    .spec_table .batch i {
+        cursor: pointer;
+    }
+
+    .spec_table .batch-input {
+        background-color: #FFF;
+        white-space: nowrap;
+        padding: 4px 9px;
+        border: solid 1px #BCE8F1;
+        position: absolute;
+        z-index: 1;
+        top: -70px;
+        left: -75px;
+        box-shadow: 3px 3px 0 rgba(153, 153, 153, 0.25);
+    }
+
+    .spec_table .batch-input h6 {
+        font-size: 12px;
+        color: #555;
+    }
+
+    .spec_table .batch-input .text {
+        vertical-align: middle;
+        clear: both;
+        padding: 0 4px;
+        margin-right: 4px;
+    }
+
+    .spec_table .batch-input .arrow {
+        background: url(<?php echo SHOP_SITE_URL; ?>/templates/default/images/seller/ncsc_bg_img.png) no-repeat -240px -20px;
+        display: block;
+        width: 10px;
+        height: 5px;
+        margin-left: -5px;
+        bottom: -5px;
+        left: 50%;
+        position: absolute;
+        z-index: 2;
+    }
+
+    .spec_table .batch-input a.close {
+        font-size: 11px;
+        line-height: 12px;
+        color: #BCE8F1;
+        text-decoration: none;
+        background-color: #FFF;
+        text-align: center;
+        display: block;
+        width: 12px;
+        height: 12px;
+        border-radius: 7px;
+        border: solid 1px #BCE8F1;
+        top: -7px;
+        right: -7px;
+        position: absolute;
+        z-index: 2;
+    }
+
+    .spec_table .text.price {
+        width: 40px;
+    }
+</style>
+<div class="page">
+    <div class="fixed-bar">
+        <div class="item-title">
+            <h3><?php echo $lang['nc_merchant']; ?></h3>
+            <ul class="tab-base">
+                <li><a href="index.php?act=merchant&op=merchant"><span><?php echo $lang['nc_manage'] ?></span></a></li>
+                <li><a href="JavaScript:void(0);" class="current"><span>商品编辑</span></a></li>
+            </ul>
+        </div>
+    </div>
+    <div class="fixed-empty"></div>
+    <form id="price_form" enctype="multipart/form-data" method="post">
+        <input type="hidden" name="form_submit" value="ok" />
+        <input type="hidden" name="mchid" value="<?php echo $output['merchant']['mchid']; ?>" />
+        <table class="table tb-type2">
+            <tbody>
+                <tr class="noborder">
+                    <td colspan="2">
+                        <label>机构名称:</label>
+                        <label><?php echo $output['merchant']['company_name']; ?></label>
+                    </td>
+                </tr>
+
+                <tr>
+                    <td colspan="2" class="required"><label class="validation" for="password">商品:</label></td>
+                </tr>
+                <tr class="noborder" style="border-bottom: 1px solid #CBE9F3;">
+                    <?php foreach ($output['refill_specs'] as $card_type => $prices) { ?>
+                        <td>
+                            <table class="spec_table tb-type2 setTable">
+                                <tr class="w500">
+                                    <th class="w150 align-center">卡类型</th>
+                                    <th class="w150 align-center">面额</th>
+                                    <th class="w150 align-center">
+                                        开启/关闭
+                                        <div><input type="checkbox" name="chbox" value="" class="checkAllCol" data-index="<?php echo $card_type ?>"></div>
+                                    </th>
+                                </tr>
+
+                                <tbody class="tbody">
+                                    <?php foreach ($prices as $k => $price) { ?>
+                                        <tr class="w500 trFlex-<?php echo $card_type ?>">
+                                            <td class="w150 align-center">
+                                                <?php echo $card_type; ?>
+                                            </td>
+                                            <td class="w150 align-center">
+                                                <?php echo $price; ?>
+                                            </td>
+                                            <td class="w150 align-center tdVal">
+
+                                            <input type="checkbox" class="cellCheckBox-<?php echo $card_type ?>" id="checkBoxList" name="items[<?php echo $card_type;?>][]" value="<?php echo "{$price}"; ?>"
+                                                <?php if(array_key_exists($card_type, $output['goods'])) {
+                                                    if(in_array($price, $output['goods'][$card_type])) {
+                                                        echo 'checked';
+                                                    }
+                                                }?>
+                                            >
+                                            </td>
+                                        </tr>
+                                    <?php } ?>
+                                </tbody>
+                            </table>
+                        </td>
+                    <?php } ?>
+                </tr>
+            </tbody>
+            <tfoot>
+                <tr class="tfoot">
+                    <td colspan="15"><a href="JavaScript:void(0);" class="btn" id="submitBtn"><span><?php echo $lang['nc_submit']; ?></span></a></td>
+                </tr>
+            </tfoot>
+        </table>
+    </form>
+</div>
+<script type="text/javascript" src="<?php echo RESOURCE_SITE_URL; ?>/laydate/laydate.js"></script>
+<script type="text/javascript" src="<?php echo RESOURCE_SITE_URL; ?>/js/dialog/dialog.js" id="dialog_js" charset="utf-8"></script>
+<script type="text/javascript" src="<?php echo RESOURCE_SITE_URL; ?>/js/jquery-ui/jquery.ui.js"></script>
+<script type="text/javascript" src="<?php echo RESOURCE_SITE_URL; ?>/js/ajaxfileupload/ajaxfileupload.js"></script>
+<script type="text/javascript" src="<?php echo RESOURCE_SITE_URL; ?>/js/jquery.Jcrop/jquery.Jcrop.js"></script>
+<link href="<?php echo RESOURCE_SITE_URL; ?>/js/jquery.Jcrop/jquery.Jcrop.min.css" rel="stylesheet" type="text/css" id="cssfile2" />
+<script type="text/javascript">
+    $(function() {
+        //按钮先执行验证再提交表单
+        $("#submitBtn").click(function() {
+            $("#price_form").submit();
+        });
+
+        $('.checkAllCol').click(function() {
+            const card_type = $(this).attr('data-index');
+
+            if ($(this).is(':checked')) {
+                $('.trFlex-'+card_type).find("input[type='checkbox']").attr('checked', true)
+            } else {
+                $('.trFlex-'+card_type).find("input[type='checkbox']").attr('checked', false)
+            }
+
+        })
+    });
+</script>

+ 8 - 4
admin/templates/default/merchant.index.php

@@ -160,17 +160,21 @@ defined('InShopNC') or exit('Access Invalid!'); ?>
                                             <a href="index.php?act=merchant&op=changeState&state=1&mchid=<?php echo $v['mchid'] ?>" style="color: green">启用机构</a>
                                         <?php } ?>
                                     </td>
-                                    <td class="align-center">
+                                    <td class="align-center w200">
                                         <a href="index.php?act=merchant&op=merchant_ctl&mchid=<?php echo $v['mchid'] ?>">
                                             充值设置
                                         </a>
-                                        <!--                            <a href="index.php?act=merchant&op=merchant_retry_times&mchid=--><?php //echo $v['mchid'] 
+                                        |
+                                        <a href="index.php?act=merchant&op=merchant_goods&mchid=<?php echo $v['mchid'] ?>">
+                                            商品设置
+                                        </a>
+                                        <!--                            <a href="index.php?act=merchant&op=merchant_retry_times&mchid=--><?php //echo $v['mchid']
                                                                                                                                             ?>
                                         <!--">-->
                                         <!--                                质量设置-->
                                         <!--                            </a>-->
                                         <!--                            |-->
-                                        <!--                            <a href="index.php?act=merchant&op=merchant_intercept&mchid=--><?php //echo $v['mchid'] 
+                                        <!--                            <a href="index.php?act=merchant&op=merchant_intercept&mchid=--><?php //echo $v['mchid']
                                                                                                                                         ?>
                                         <!--">-->
                                         <!--                                拦截设置-->
@@ -234,4 +238,4 @@ defined('InShopNC') or exit('Access Invalid!'); ?>
             $(item).text(text)
         })
     });
-</script>
+</script>

+ 38 - 38
data/config/xyz/refill.ini.php

@@ -3941,45 +3941,45 @@ $cangbu_high_phone = ['name' => 'cangbu_high', 'store_id' => 168, 'qualitys' =>
 $ruixunda_phone = ['name' => 'ruixunda', 'store_id' => 169, 'qualitys' => '1',
     'amount' => [
         10 => [
-//            ['goods_id' => 7439, 'price' => 9.6, 'quality' => 1, 'card_type' => 'chinamobile'],
-            ['goods_id' => 7439, 'price' => 9.05, 'quality' => 1, 'card_type' => 'chinaunicom'],
+            ['goods_id' => 7439, 'price' => 9.55, 'quality' => 1, 'card_type' => 'chinamobile'],
+//            ['goods_id' => 7439, 'price' => 9.05, 'quality' => 1, 'card_type' => 'chinaunicom'],
 //            ['goods_id' => 7439, 'price' => 9.45, 'quality' => 1, 'card_type' => 'chinatelecom']
         ],
         20 => [
-//            ['goods_id' => 7440, 'price' => 19.2, 'quality' => 1, 'card_type' => 'chinamobile'],
-            ['goods_id' => 7440, 'price' => 18.1, 'quality' => 1, 'card_type' => 'chinaunicom'],
+            ['goods_id' => 7440, 'price' => 19.1, 'quality' => 1, 'card_type' => 'chinamobile'],
+//            ['goods_id' => 7440, 'price' => 18.1, 'quality' => 1, 'card_type' => 'chinaunicom'],
 //            ['goods_id' => 7440, 'price' => 18.9, 'quality' => 1, 'card_type' => 'chinatelecom']
         ],
         30 => [
             ['goods_id' => 7441, 'price' => 28.8, 'quality' => 1, 'card_type' => 'chinamobile'],
-            ['goods_id' => 7441, 'price' => 27.15, 'quality' => 1, 'card_type' => 'chinaunicom'],
+            ['goods_id' => 7441, 'price' => 27.51, 'quality' => 1, 'card_type' => 'chinaunicom'],
             ['goods_id' => 7441, 'price' => 28.44, 'quality' => 1, 'card_type' => 'chinatelecom']
         ],
         50 => [
             ['goods_id' => 7442, 'price' => 48, 'quality' => 1, 'card_type' => 'chinamobile'],
-            ['goods_id' => 7442, 'price' => 45.25, 'quality' => 1, 'card_type' => 'chinaunicom'],
-            ['goods_id' => 7442, 'price' => 47.4, 'quality' => 1, 'card_type' => 'chinatelecom']
+            ['goods_id' => 7442, 'price' => 45.85, 'quality' => 1, 'card_type' => 'chinaunicom'],
+            ['goods_id' => 7442, 'price' => 48.25, 'quality' => 1, 'card_type' => 'chinatelecom']
         ],
         100 => [
             ['goods_id' => 7443, 'price' => 96, 'quality' => 1, 'card_type' => 'chinamobile'],
-            ['goods_id' => 7443, 'price' => 90.5, 'quality' => 1, 'card_type' => 'chinaunicom'],
-            ['goods_id' => 7443, 'price' => 94.8, 'quality' => 1, 'card_type' => 'chinatelecom']
+            ['goods_id' => 7443, 'price' => 91.7, 'quality' => 1, 'card_type' => 'chinaunicom'],
+            ['goods_id' => 7443, 'price' => 96.5, 'quality' => 1, 'card_type' => 'chinatelecom']
         ],
         200 => [
             ['goods_id' => 7444, 'price' => 192, 'quality' => 1, 'card_type' => 'chinamobile'],
-            ['goods_id' => 7444, 'price' => 181, 'quality' => 1, 'card_type' => 'chinaunicom'],
-            ['goods_id' => 7444, 'price' => 189.6, 'quality' => 1, 'card_type' => 'chinatelecom']
+            ['goods_id' => 7444, 'price' => 183.4, 'quality' => 1, 'card_type' => 'chinaunicom'],
+            ['goods_id' => 7444, 'price' => 193, 'quality' => 1, 'card_type' => 'chinatelecom']
         ],
-        300 => [
+//        300 => [
 //            ['goods_id' => 7445, 'price' => 288, 'quality' => 1, 'card_type' => 'chinamobile'],
-            ['goods_id' => 7445, 'price' => 271.5, 'quality' => 1, 'card_type' => 'chinaunicom'],
+//            ['goods_id' => 7445, 'price' => 271.5, 'quality' => 1, 'card_type' => 'chinaunicom'],
 //            ['goods_id' => 7445, 'price' => 283.5, 'quality' => 1, 'card_type' => 'chinatelecom']
-        ],
-        500 => [
+//        ],
+//        500 => [
 //            ['goods_id' => 7446, 'price' => 480, 'quality' => 1, 'card_type' => 'chinamobile'],
-            ['goods_id' => 7446, 'price' => 452.5, 'quality' => 1, 'card_type' => 'chinaunicom'],
+//            ['goods_id' => 7446, 'price' => 452.5, 'quality' => 1, 'card_type' => 'chinaunicom'],
 //            ['goods_id' => 7446, 'price' => 472.5, 'quality' => 1, 'card_type' => 'chinatelecom']
-        ],
+//        ],
     ],
     'official_sn' => true, 'refill_type' => 'api'];
 
@@ -4277,35 +4277,35 @@ $baixuannew_normal_phone = ['name' => 'baixuannew_normal', 'store_id' => 178,'qu
 
 $youhenew_phone = ['name' => 'youhenew', 'store_id' => 179,'qualitys' => '1',
     'amount' => [
-//        10 => [
-//            ['goods_id' => 7512, 'price' => 9.58, 'quality' => 1, 'card_type' => 'chinamobile'],
+        10 => [
+            ['goods_id' => 7512, 'price' => 9.75, 'quality' => 1, 'card_type' => 'chinamobile'],
 //            ['goods_id' => 7512, 'price' => 9.53, 'quality' => 1, 'card_type' => 'chinaunicom'],
 //            ['goods_id' => 7512, 'price' => 9.53, 'quality' => 1, 'card_type' => 'chinatelecom']
-//        ],
-//        20 => [
-//            ['goods_id' => 7513, 'price' => 19.16, 'quality' => 1, 'card_type' => 'chinamobile'],
+        ],
+        20 => [
+            ['goods_id' => 7513, 'price' => 19.5, 'quality' => 1, 'card_type' => 'chinamobile'],
 //            ['goods_id' => 7513, 'price' => 19.06, 'quality' => 1, 'card_type' => 'chinaunicom'],
 //            ['goods_id' => 7513, 'price' => 19.06, 'quality' => 1, 'card_type' => 'chinatelecom']
-//        ],
+        ],
         30 => [
             ['goods_id' => 7514, 'price' => 28.86, 'quality' => 1, 'card_type' => 'chinamobile'],
-            ['goods_id' => 7514, 'price' => 28.5, 'quality' => 1, 'card_type' => 'chinaunicom'],
-            ['goods_id' => 7514, 'price' => 28.5, 'quality' => 1, 'card_type' => 'chinatelecom']
+            ['goods_id' => 7514, 'price' => 28.14, 'quality' => 1, 'card_type' => 'chinaunicom'],
+            ['goods_id' => 7514, 'price' => 28.71, 'quality' => 1, 'card_type' => 'chinatelecom']
         ],
         50 => [
             ['goods_id' => 7515, 'price' => 48.1, 'quality' => 1, 'card_type' => 'chinamobile'],
-            ['goods_id' => 7515, 'price' => 47.5, 'quality' => 1, 'card_type' => 'chinaunicom'],
-            ['goods_id' => 7515, 'price' => 47.5, 'quality' => 1, 'card_type' => 'chinatelecom']
+            ['goods_id' => 7515, 'price' => 46.9, 'quality' => 1, 'card_type' => 'chinaunicom'],
+            ['goods_id' => 7515, 'price' => 48.75, 'quality' => 1, 'card_type' => 'chinatelecom']
         ],
         100 => [
             ['goods_id' => 7516, 'price' => 96.2, 'quality' => 1, 'card_type' => 'chinamobile'],
-            ['goods_id' => 7516, 'price' => 95, 'quality' => 1, 'card_type' => 'chinaunicom'],
-            ['goods_id' => 7516, 'price' => 95, 'quality' => 1, 'card_type' => 'chinatelecom']
+            ['goods_id' => 7516, 'price' => 93.8, 'quality' => 1, 'card_type' => 'chinaunicom'],
+            ['goods_id' => 7516, 'price' => 97.5, 'quality' => 1, 'card_type' => 'chinatelecom']
         ],
         200 => [
             ['goods_id' => 7517, 'price' => 192.4, 'quality' => 1, 'card_type' => 'chinamobile'],
-            ['goods_id' => 7517, 'price' => 190, 'quality' => 1, 'card_type' => 'chinaunicom'],
-            ['goods_id' => 7517, 'price' => 190, 'quality' => 1, 'card_type' => 'chinatelecom']
+            ['goods_id' => 7517, 'price' => 187.6, 'quality' => 1, 'card_type' => 'chinaunicom'],
+            ['goods_id' => 7517, 'price' => 195, 'quality' => 1, 'card_type' => 'chinatelecom']
         ],
 //        300 => [
 //            ['goods_id' => 7518, 'price' => 287.4, 'quality' => 1, 'card_type' => 'chinamobile'],
@@ -6711,24 +6711,24 @@ $dazhanggui_high_phone = ['name' => 'dazhanggui_high', 'store_id' => 245, 'quali
 //            ['goods_id' => 8024, 'price' => 19, 'quality' => 1, 'card_type' => 'chinatelecom']
 //        ],
         30 => [
-            ['goods_id' => 8025, 'price' => 29.4, 'quality' => 1, 'card_type' => 'chinamobile'],
+            ['goods_id' => 8025, 'price' => 29.25, 'quality' => 1, 'card_type' => 'chinamobile'],
 //            ['goods_id' => 8025, 'price' => 28.5, 'quality' => 1, 'card_type' => 'chinaunicom'],
 //            ['goods_id' => 8025, 'price' => 28.5, 'quality' => 1, 'card_type' => 'chinatelecom']
         ],
         50 => [
-            ['goods_id' => 8026, 'price' => 49, 'quality' => 1, 'card_type' => 'chinamobile'],
+            ['goods_id' => 8026, 'price' => 48.75, 'quality' => 1, 'card_type' => 'chinamobile'],
 //            ['goods_id' => 8026, 'price' => 47.5, 'quality' => 1, 'card_type' => 'chinaunicom'],
-//            ['goods_id' => 8026, 'price' => 47.5, 'quality' => 1, 'card_type' => 'chinatelecom']
+            ['goods_id' => 8026, 'price' => 48.75, 'quality' => 1, 'card_type' => 'chinatelecom']
         ],
         100 => [
-            ['goods_id' => 8027, 'price' => 98, 'quality' => 1, 'card_type' => 'chinamobile'],
+            ['goods_id' => 8027, 'price' => 97.5, 'quality' => 1, 'card_type' => 'chinamobile'],
 //            ['goods_id' => 8027, 'price' => 95, 'quality' => 1, 'card_type' => 'chinaunicom'],
-//            ['goods_id' => 8027, 'price' => 95, 'quality' => 1, 'card_type' => 'chinatelecom']
+            ['goods_id' => 8027, 'price' => 97.5, 'quality' => 1, 'card_type' => 'chinatelecom']
         ],
         200 => [
-            ['goods_id' => 8028, 'price' => 196, 'quality' => 1, 'card_type' => 'chinamobile'],
+            ['goods_id' => 8028, 'price' => 195, 'quality' => 1, 'card_type' => 'chinamobile'],
 //            ['goods_id' => 8028, 'price' => 190, 'quality' => 1, 'card_type' => 'chinaunicom'],
-//            ['goods_id' => 8028, 'price' => 190, 'quality' => 1, 'card_type' => 'chinatelecom']
+            ['goods_id' => 8028, 'price' => 195, 'quality' => 1, 'card_type' => 'chinatelecom']
         ],
 //        300 => [
 //            ['goods_id' => 8029, 'price' => 288, 'quality' => 1, 'card_type' => 'chinamobile'],

+ 42 - 42
data/config/yl/refill.ini.php

@@ -3949,45 +3949,45 @@ $cangbu_high_phone = ['name' => 'cangbu_high', 'store_id' => 168, 'qualitys' =>
 $ruixunda_phone = ['name' => 'ruixunda', 'store_id' => 169, 'qualitys' => '1',
     'amount' => [
         10 => [
-//            ['goods_id' => 7439, 'price' => 9.6, 'quality' => 1, 'card_type' => 'chinamobile'],
-            ['goods_id' => 7439, 'price' => 9.05, 'quality' => 1, 'card_type' => 'chinaunicom'],
+            ['goods_id' => 7439, 'price' => 9.55, 'quality' => 1, 'card_type' => 'chinamobile'],
+//            ['goods_id' => 7439, 'price' => 9.05, 'quality' => 1, 'card_type' => 'chinaunicom'],
 //            ['goods_id' => 7439, 'price' => 9.45, 'quality' => 1, 'card_type' => 'chinatelecom']
         ],
         20 => [
-//            ['goods_id' => 7440, 'price' => 19.2, 'quality' => 1, 'card_type' => 'chinamobile'],
-            ['goods_id' => 7440, 'price' => 18.1, 'quality' => 1, 'card_type' => 'chinaunicom'],
+            ['goods_id' => 7440, 'price' => 19.1, 'quality' => 1, 'card_type' => 'chinamobile'],
+//            ['goods_id' => 7440, 'price' => 18.1, 'quality' => 1, 'card_type' => 'chinaunicom'],
 //            ['goods_id' => 7440, 'price' => 18.9, 'quality' => 1, 'card_type' => 'chinatelecom']
         ],
         30 => [
             ['goods_id' => 7441, 'price' => 28.8, 'quality' => 1, 'card_type' => 'chinamobile'],
-            ['goods_id' => 7441, 'price' => 27.15, 'quality' => 1, 'card_type' => 'chinaunicom'],
+            ['goods_id' => 7441, 'price' => 27.51, 'quality' => 1, 'card_type' => 'chinaunicom'],
             ['goods_id' => 7441, 'price' => 28.44, 'quality' => 1, 'card_type' => 'chinatelecom']
         ],
         50 => [
             ['goods_id' => 7442, 'price' => 48, 'quality' => 1, 'card_type' => 'chinamobile'],
-            ['goods_id' => 7442, 'price' => 45.25, 'quality' => 1, 'card_type' => 'chinaunicom'],
-            ['goods_id' => 7442, 'price' => 47.4, 'quality' => 1, 'card_type' => 'chinatelecom']
+            ['goods_id' => 7442, 'price' => 45.85, 'quality' => 1, 'card_type' => 'chinaunicom'],
+            ['goods_id' => 7442, 'price' => 48.25, 'quality' => 1, 'card_type' => 'chinatelecom']
         ],
         100 => [
             ['goods_id' => 7443, 'price' => 96, 'quality' => 1, 'card_type' => 'chinamobile'],
-            ['goods_id' => 7443, 'price' => 90.5, 'quality' => 1, 'card_type' => 'chinaunicom'],
-            ['goods_id' => 7443, 'price' => 94.8, 'quality' => 1, 'card_type' => 'chinatelecom']
+            ['goods_id' => 7443, 'price' => 91.7, 'quality' => 1, 'card_type' => 'chinaunicom'],
+            ['goods_id' => 7443, 'price' => 96.5, 'quality' => 1, 'card_type' => 'chinatelecom']
         ],
         200 => [
             ['goods_id' => 7444, 'price' => 192, 'quality' => 1, 'card_type' => 'chinamobile'],
-            ['goods_id' => 7444, 'price' => 181, 'quality' => 1, 'card_type' => 'chinaunicom'],
-            ['goods_id' => 7444, 'price' => 189.6, 'quality' => 1, 'card_type' => 'chinatelecom']
+            ['goods_id' => 7444, 'price' => 183.4, 'quality' => 1, 'card_type' => 'chinaunicom'],
+            ['goods_id' => 7444, 'price' => 193, 'quality' => 1, 'card_type' => 'chinatelecom']
         ],
-        300 => [
+//        300 => [
 //            ['goods_id' => 7445, 'price' => 288, 'quality' => 1, 'card_type' => 'chinamobile'],
-            ['goods_id' => 7445, 'price' => 271.5, 'quality' => 1, 'card_type' => 'chinaunicom'],
+//            ['goods_id' => 7445, 'price' => 271.5, 'quality' => 1, 'card_type' => 'chinaunicom'],
 //            ['goods_id' => 7445, 'price' => 283.5, 'quality' => 1, 'card_type' => 'chinatelecom']
-        ],
-        500 => [
+//        ],
+//        500 => [
 //            ['goods_id' => 7446, 'price' => 480, 'quality' => 1, 'card_type' => 'chinamobile'],
-            ['goods_id' => 7446, 'price' => 452.5, 'quality' => 1, 'card_type' => 'chinaunicom'],
+//            ['goods_id' => 7446, 'price' => 452.5, 'quality' => 1, 'card_type' => 'chinaunicom'],
 //            ['goods_id' => 7446, 'price' => 472.5, 'quality' => 1, 'card_type' => 'chinatelecom']
-        ],
+//        ],
     ],
     'official_sn' => true, 'refill_type' => 'api'];
 
@@ -4285,35 +4285,35 @@ $baixuannew_normal_phone = ['name' => 'baixuannew_normal', 'store_id' => 178,'qu
 
 $youhenew_phone = ['name' => 'youhenew', 'store_id' => 179,'qualitys' => '1',
     'amount' => [
-//        10 => [
-//            ['goods_id' => 7512, 'price' => 9.58, 'quality' => 1, 'card_type' => 'chinamobile'],
+        10 => [
+            ['goods_id' => 7512, 'price' => 9.75, 'quality' => 1, 'card_type' => 'chinamobile'],
 //            ['goods_id' => 7512, 'price' => 9.53, 'quality' => 1, 'card_type' => 'chinaunicom'],
 //            ['goods_id' => 7512, 'price' => 9.53, 'quality' => 1, 'card_type' => 'chinatelecom']
-//        ],
-//        20 => [
-//            ['goods_id' => 7513, 'price' => 19.16, 'quality' => 1, 'card_type' => 'chinamobile'],
+        ],
+        20 => [
+            ['goods_id' => 7513, 'price' => 19.5, 'quality' => 1, 'card_type' => 'chinamobile'],
 //            ['goods_id' => 7513, 'price' => 19.06, 'quality' => 1, 'card_type' => 'chinaunicom'],
 //            ['goods_id' => 7513, 'price' => 19.06, 'quality' => 1, 'card_type' => 'chinatelecom']
-//        ],
+        ],
         30 => [
-//            ['goods_id' => 7514, 'price' => 28.74, 'quality' => 1, 'card_type' => 'chinamobile'],
-            ['goods_id' => 7514, 'price' => 28.59, 'quality' => 1, 'card_type' => 'chinaunicom'],
-            ['goods_id' => 7514, 'price' => 28.59, 'quality' => 1, 'card_type' => 'chinatelecom']
+            ['goods_id' => 7514, 'price' => 28.86, 'quality' => 1, 'card_type' => 'chinamobile'],
+            ['goods_id' => 7514, 'price' => 28.14, 'quality' => 1, 'card_type' => 'chinaunicom'],
+            ['goods_id' => 7514, 'price' => 28.71, 'quality' => 1, 'card_type' => 'chinatelecom']
         ],
         50 => [
-            ['goods_id' => 7515, 'price' => 47.9, 'quality' => 1, 'card_type' => 'chinamobile'],
-            ['goods_id' => 7515, 'price' => 47.65, 'quality' => 1, 'card_type' => 'chinaunicom'],
-            ['goods_id' => 7515, 'price' => 47.65, 'quality' => 1, 'card_type' => 'chinatelecom']
+            ['goods_id' => 7515, 'price' => 48.1, 'quality' => 1, 'card_type' => 'chinamobile'],
+            ['goods_id' => 7515, 'price' => 46.9, 'quality' => 1, 'card_type' => 'chinaunicom'],
+            ['goods_id' => 7515, 'price' => 48.75, 'quality' => 1, 'card_type' => 'chinatelecom']
         ],
         100 => [
-            ['goods_id' => 7516, 'price' => 95.8, 'quality' => 1, 'card_type' => 'chinamobile'],
-            ['goods_id' => 7516, 'price' => 95.3, 'quality' => 1, 'card_type' => 'chinaunicom'],
-            ['goods_id' => 7516, 'price' => 95.3, 'quality' => 1, 'card_type' => 'chinatelecom']
+            ['goods_id' => 7516, 'price' => 96.2, 'quality' => 1, 'card_type' => 'chinamobile'],
+            ['goods_id' => 7516, 'price' => 93.8, 'quality' => 1, 'card_type' => 'chinaunicom'],
+            ['goods_id' => 7516, 'price' => 97.5, 'quality' => 1, 'card_type' => 'chinatelecom']
         ],
         200 => [
-            ['goods_id' => 7517, 'price' => 191.6, 'quality' => 1, 'card_type' => 'chinamobile'],
-            ['goods_id' => 7517, 'price' => 190.6, 'quality' => 1, 'card_type' => 'chinaunicom'],
-            ['goods_id' => 7517, 'price' => 190.6, 'quality' => 1, 'card_type' => 'chinatelecom']
+            ['goods_id' => 7517, 'price' => 192.4, 'quality' => 1, 'card_type' => 'chinamobile'],
+            ['goods_id' => 7517, 'price' => 187.6, 'quality' => 1, 'card_type' => 'chinaunicom'],
+            ['goods_id' => 7517, 'price' => 195, 'quality' => 1, 'card_type' => 'chinatelecom']
         ],
 //        300 => [
 //            ['goods_id' => 7518, 'price' => 287.4, 'quality' => 1, 'card_type' => 'chinamobile'],
@@ -6471,24 +6471,24 @@ $dazhanggui_high_phone = ['name' => 'dazhanggui_high', 'store_id' => 236, 'quali
 //            ['goods_id' => 7972, 'price' => 19, 'quality' => 1, 'card_type' => 'chinatelecom']
 //        ],
         30 => [
-            ['goods_id' => 7973, 'price' => 29.4, 'quality' => 1, 'card_type' => 'chinamobile'],
+            ['goods_id' => 7973, 'price' => 29.25, 'quality' => 1, 'card_type' => 'chinamobile'],
 //            ['goods_id' => 7973, 'price' => 28.5, 'quality' => 1, 'card_type' => 'chinaunicom'],
 //            ['goods_id' => 7973, 'price' => 28.5, 'quality' => 1, 'card_type' => 'chinatelecom']
         ],
         50 => [
-            ['goods_id' => 7974, 'price' => 49, 'quality' => 1, 'card_type' => 'chinamobile'],
+            ['goods_id' => 7974, 'price' => 48.75, 'quality' => 1, 'card_type' => 'chinamobile'],
 //            ['goods_id' => 7974, 'price' => 47.5, 'quality' => 1, 'card_type' => 'chinaunicom'],
-//            ['goods_id' => 7974, 'price' => 47.5, 'quality' => 1, 'card_type' => 'chinatelecom']
+            ['goods_id' => 7974, 'price' => 48.75, 'quality' => 1, 'card_type' => 'chinatelecom']
         ],
         100 => [
-            ['goods_id' => 7975, 'price' => 98, 'quality' => 1, 'card_type' => 'chinamobile'],
+            ['goods_id' => 7975, 'price' => 97.5, 'quality' => 1, 'card_type' => 'chinamobile'],
 //            ['goods_id' => 7975, 'price' => 95, 'quality' => 1, 'card_type' => 'chinaunicom'],
-//            ['goods_id' => 7975, 'price' => 95, 'quality' => 1, 'card_type' => 'chinatelecom']
+            ['goods_id' => 7975, 'price' => 97.5, 'quality' => 1, 'card_type' => 'chinatelecom']
         ],
         200 => [
-            ['goods_id' => 7976, 'price' => 196, 'quality' => 1, 'card_type' => 'chinamobile'],
+            ['goods_id' => 7976, 'price' => 195, 'quality' => 1, 'card_type' => 'chinamobile'],
 //            ['goods_id' => 7976, 'price' => 190, 'quality' => 1, 'card_type' => 'chinaunicom'],
-//            ['goods_id' => 7976, 'price' => 190, 'quality' => 1, 'card_type' => 'chinatelecom']
+            ['goods_id' => 7976, 'price' => 195, 'quality' => 1, 'card_type' => 'chinatelecom']
         ],
 //        300 => [
 //            ['goods_id' => 7977, 'price' => 288, 'quality' => 1, 'card_type' => 'chinamobile'],

+ 13 - 1
data/model/thrid_refill.model.php

@@ -39,6 +39,18 @@ class thrid_refillModel extends Model
         }
     }
 
+    public function getMerchantPcode($mchid)
+    {
+        $item = $this->table('merchant_price')
+            ->field('pcode')
+            ->where(['mchid' => $mchid, 'pcode' => ['neq','']])
+            ->select();
+        if(empty($item)) {
+            return [];
+        }
+        return array_column($item, 'pcode');
+    }
+
     public function addExt($data)
     {
         return $this->table('refill_third')->insert($data);
@@ -53,4 +65,4 @@ class thrid_refillModel extends Model
     {
         return $this->table('refill_third')->where(['order_id' => $order_id])->find();
     }
-}
+}

+ 2 - 0
helper/rbridge/fulu_ylyw/product.php

@@ -8,6 +8,8 @@ $fulu_ylyw_product = [
         //移动
         502540719 => [4, 5, 6],
         503196622 => [4, 5, 6],
+        508604768 => [4, 5, 6],
+        506875500 => [4, 5, 6],
     ],
 ];
 

+ 7 - 1
helper/rbridge/fulu_ylyw/readme.txt

@@ -25,4 +25,10 @@ https://www.xyzshops.cn/mobile/bridge/fulu_ylyw.php
 2022.12.12
 
 502540719  50
-503196622  100
+503196622  100
+
+2022.12.21
+508604768
+
+2022.12.27
+506875500

+ 2 - 2
helper/refill/RefillBase.php

@@ -94,7 +94,7 @@ class RefillBase
             return false;
         }
 
-        if ($org_official_sn !== false and count($org_official_sn) > 48) {
+        if ($org_official_sn !== false and strlen($org_official_sn) > 48) {
             return true;
         }
 
@@ -944,4 +944,4 @@ class RefillBase
     {
         $this->mPolicy->update_maxspeeds($params);
     }
-}
+}

+ 9 - 0
helper/refill/api/xyz/dazhanggui_high/api.txt

@@ -19,3 +19,12 @@
 高价移动50  1010
 高价移动100 1011
 高价移动200 1012
+
+2022.12.19
+大掌柜
+高价户全国电信 50-200面值 折扣975
+
+商品编码
+3000050
+3000100
+3000200

+ 5 - 0
helper/refill/api/xyz/dazhanggui_high/config.php

@@ -31,6 +31,11 @@ class config
             50  => 1010,
             100 => 1011,
             200 => 1012,
+        ],
+        mtopcard\ChinaTelecomCard => [
+            50  => 3000050,
+            100 => 3000100,
+            200 => 3000200,
         ]
     ];
 }

BIN
helper/refill/api/xyz/dezhi_fs/20221226广西移动调价函.jpg


+ 2 - 1
helper/refill/api/xyz/dezhi_fs/config.php

@@ -34,7 +34,8 @@ class config
         "4-30-25" => 28.44, "4-50-25" => 47.4, "4-100-25" => 94.8, "4-200-25" => 189.6,//云南 25
         "4-50-16" => 46.9, "4-100-16" => 93.8, "4-200-16" => 187.6,//河南 16
         "4-50-3" => 47.1, "4-100-3" => 94.2, "4-200-3" => 188.4,//河北 3
-        "4-30-20" => 28.26, "4-50-20" => 47.1, "4-100-20" => 94.2, "4-200-20" => 188.4,//广西 20
+        "4-50-20" => 46.6, "4-100-20" => 93.2, "4-200-20" => 186.4,//广西 20
+        "4-30-23" => 28.26, "4-50-23" => 47.1, "4-100-23" => 94.2, "4-200-23" => 188.4,//四川 23
 
         //电信
         "6-30-19" => 28.26, "6-50-19" => 47.1, "6-100-19" => 94.2, "6-200-19" => 188.4,//广东 19

BIN
helper/refill/api/xyz/guochuang/20221221辽宁移动调价函.png


BIN
helper/refill/api/xyz/guochuang/20221222广东移动调价函.png


BIN
helper/refill/api/xyz/guochuang/20221223广东移动调价函.png


+ 2 - 2
helper/refill/api/xyz/guochuang/config.php

@@ -64,7 +64,7 @@ class config
     const Price = [
         //移动
         "4-10-2" => 10.03, "4-20-2" => 20.06, "4-30-2" => 30.09, "4-50-2" => 50.15, "4-100-2" => 100.3, "4-200-2" => 200.6, "4-300-2" => 300.9, "4-500-2" => 501.5,//天津 2
-        "4-10-6" => 9.78, "4-20-6" => 19.56, "4-30-6" => 29.34, "4-50-6" => 48.9, "4-100-6" => 97.8, "4-200-6" => 195.6, "4-300-6" => 293.4, "4-500-6" => 489,//辽宁 6
+        "4-10-6" => 9.77, "4-20-6" => 19.54, "4-30-6" => 29.31, "4-50-6" => 48.85, "4-100-6" => 97.7, "4-200-6" => 195.4, "4-300-6" => 293.1, "4-500-6" => 488.5,//辽宁 6
         "4-10-9" => 9.94, "4-20-9" => 19.88, "4-30-9" => 29.82, "4-50-9" => 49.7, "4-100-9" => 99.4,//上海 9
         "4-10-8" => 10.02, "4-20-8" => 20.04, "4-30-8" => 30.06, "4-50-8" => 50.1, "4-100-8" => 100.2, "4-200-8" => 200.4, "4-300-8" => 300.15, "4-500-8" => 500.25,//黑龙江 8
         "4-10-29" => 9.81, "4-20-29" => 19.62, "4-30-29" => 29.43, "4-50-29" => 49.05, "4-100-29" => 98.1, "4-200-29" => 196.2, "4-300-29" => 294.3, "4-500-29" => 490.5,//青海 29
@@ -72,7 +72,7 @@ class config
         "4-10-13" => 10.01, "4-20-13" => 20.02, "4-30-13" => 30.03, "4-50-13" => 50.05, "4-100-13" => 100.1, "4-200-13" => 200.2, "4-300-13" => 300.3, "4-500-13" => 500.5,//福建 13
         "4-10-5" => 10.035, "4-20-5" => 20.07, "4-30-5" => 30.09, "4-50-5" => 50.15, "4-100-5" => 100.3, "4-200-5" => 200.4, "4-300-5" => 300.6, "4-500-5" => 501,//内蒙古 5
         "4-30-18" => 29.835, "4-50-18" => 49.725, "4-100-18" => 99.45, "4-200-18" => 198.3,//湖南 18
-        "4-10-19" => 10.18, "4-20-19" => 20.36, "4-30-19" => 30.03, "4-50-19" => 50.05, "4-100-19" => 100.1, "4-200-19" => 200.2, "4-300-19" => 300.3, "4-500-19" => 500.5,//广东 19
+        "4-10-19" => 10.03, "4-20-19" => 20.06, "4-30-19" => 29.97, "4-50-19" => 49.95, "4-100-19" => 99.9, "4-200-19" => 199.8, "4-300-19" => 299.7, "4-500-19" => 499.5,//广东 19
         "4-10-7" => 9.93, "4-20-7" => 19.86, "4-30-7" => 29.52, "4-50-7" => 49.2, "4-100-7" => 98.4, "4-200-7" => 196.8, "4-300-7" => 295.2, "4-500-7" => 492,//吉林 7
         "4-10-1" => 10.31, "4-20-1" => 20.32, "4-30-1" => 30.33, "4-50-1" => 50.35, "4-100-1" => 100.4, "4-200-1" => 200.3, "4-300-1" => 300.45, "4-500-1" => 500.75,//北京 1
         "4-10-22" => 10.015, "4-20-22" => 20.03, "4-30-22" => 30.045, "4-50-22" => 50.075, "4-100-22" => 100.15, "4-200-22" => 200.3, "4-300-22" => 300.45, "4-500-22" => 500.75,//重庆 22

BIN
helper/refill/api/xyz/meixu_fs/20221226辽宁移动调价函.jpg


+ 1 - 1
helper/refill/api/xyz/meixu_fs/config.php

@@ -56,7 +56,7 @@ class config
 
     const Price = [
         //移动
-        "4-10-6" => 9.778, "4-20-6" => 19.556, "4-30-6" => 29.334, "4-50-6" => 48.89, "4-100-6" => 97.78, "4-200-6" => 195.56, "4-300-6" => 293.34, "4-500-6" => 488.9,//辽宁 6
+        "4-10-6" => 9.75, "4-20-6" => 19.5, "4-30-6" => 29.25, "4-50-6" => 48.75, "4-100-6" => 97.5, "4-200-6" => 195, "4-300-6" => 292.5, "4-500-6" => 487.5,//辽宁 6
 
         //电信
         "4-10-23" => 10.21, "4-20-23" => 20.22, "4-30-23" => 30.24, "4-50-23" => 50.15, "4-100-23" => 100.3, "4-200-23" => 200.6, "4-300-23" => 300.9, "4-500-23" => 501.5,//四川 6

+ 2 - 0
helper/refill/api/xyz/ruixunda/config.php

@@ -27,6 +27,8 @@ class config
     const ProductIdS = [
         mtopcard\ChinaMobileCard =>
             [
+                10  => '101685',
+                20  => '101686',
                 30  => '101687',
                 50  => '101688',
                 100 => '101689',

+ 4 - 1
helper/refill/api/xyz/ruixunda/对接文档-yezi.txt

@@ -46,4 +46,7 @@ http://47.96.69.138:9086/searchbalance.do
 101710 全国联通话费500元
 
 
-
+2022.12.22
+云九一     全国移动10.20产品编码:
+101685 全国移动话费10元直充
+101686 全国移动话费20元直充

BIN
helper/refill/api/xyz/ruixunda_fs/20221219四川移动调价函.png


+ 1 - 1
helper/refill/api/xyz/ruixunda_fs/config.php

@@ -158,7 +158,7 @@ class config
         "4-50-19" => 47.35, "4-100-19" => 94.7, "4-200-19" => 189.4,//广东 19
         "4-50-3" => 46.5, "4-100-3" => 93, "4-200-3" => 186,//河北 3
         "4-50-20" => 46.65, "4-100-20" => 93.3, "4-200-20" => 186.6,//广西 20
-        "4-50-23" => 46.95, "4-100-23" => 93.9, "4-200-23" => 187.8,//四川 23
+        "4-50-23" => 46.7, "4-100-23" => 93.4, "4-200-23" => 186.8,//四川 23
         "4-50-22" => 47, "4-100-22" => 94, "4-200-22" => 188,//重庆 22
 
         //电信

+ 1 - 0
helper/refill/api/xyz/yunchonggongfs/config.php

@@ -36,6 +36,7 @@ class config
         "4-30-16" => 28.5, "4-50-16" => 47.5, "4-100-16" => 95, "4-200-16" => 190,//河南 16
         "4-50-3" => 47.25, "4-100-3" => 94.5, "4-200-3" => 189,//河北 3
         "4-30-20" => 28.35, "4-50-20" => 47.25, "4-100-20" => 94.5, "4-200-20" => 189,//广西 20
+        "4-50-23" => 47.25, "4-100-23" => 94.5, "4-200-23" => 189,//四川 23
 
         //电信
         "6-30-18" => 28.2, "6-50-18" => 47, "6-100-18" => 94, "6-200-18" => 188,//湖南 18

+ 5 - 0
helper/refill/api/yl/dazhanggui_high/config.php

@@ -31,6 +31,11 @@ class config
             50  => 1010,
             100 => 1011,
             200 => 1012,
+        ],
+        mtopcard\ChinaTelecomCard => [
+            50  => 3000050,
+            100 => 3000100,
+            200 => 3000200,
         ]
     ];
 }

+ 2 - 1
helper/refill/api/yl/dezhi_fs/config.php

@@ -34,7 +34,8 @@ class config
         "4-30-25" => 28.44, "4-50-25" => 47.4, "4-100-25" => 94.8, "4-200-25" => 189.6,//云南 25
         "4-50-16" => 46.9, "4-100-16" => 93.8, "4-200-16" => 187.6,//河南 16
         "4-50-3" => 47.1, "4-100-3" => 94.2, "4-200-3" => 188.4,//河北 3
-        "4-30-20" => 28.26, "4-50-20" => 47.1, "4-100-20" => 94.2, "4-200-20" => 188.4,//广西 20
+        "4-50-20" => 46.6, "4-100-20" => 93.2, "4-200-20" => 186.4,//广西 20
+        "4-30-23" => 28.26, "4-50-23" => 47.1, "4-100-23" => 94.2, "4-200-23" => 188.4,//四川 23
 
         //电信
         "6-30-19" => 28.26, "6-50-19" => 47.1, "6-100-19" => 94.2, "6-200-19" => 188.4,//广东 19

+ 2 - 2
helper/refill/api/yl/guochuang/config.php

@@ -64,7 +64,7 @@ class config
     const Price = [
         //移动
         "4-10-2" => 10.03, "4-20-2" => 20.06, "4-30-2" => 30.09, "4-50-2" => 50.15, "4-100-2" => 100.3, "4-200-2" => 200.6, "4-300-2" => 300.9, "4-500-2" => 501.5,//天津 2
-        "4-10-6" => 9.78, "4-20-6" => 19.56, "4-30-6" => 29.34, "4-50-6" => 48.9, "4-100-6" => 97.8, "4-200-6" => 195.6, "4-300-6" => 293.4, "4-500-6" => 489,//辽宁 6
+        "4-10-6" => 9.77, "4-20-6" => 19.54, "4-30-6" => 29.31, "4-50-6" => 48.85, "4-100-6" => 97.7, "4-200-6" => 195.4, "4-300-6" => 293.1, "4-500-6" => 488.5,//辽宁 6
         "4-10-9" => 9.94, "4-20-9" => 19.88, "4-30-9" => 29.82, "4-50-9" => 49.7, "4-100-9" => 99.4,//上海 9
         "4-10-8" => 10.02, "4-20-8" => 20.04, "4-30-8" => 30.06, "4-50-8" => 50.1, "4-100-8" => 100.2, "4-200-8" => 200.4, "4-300-8" => 300.15, "4-500-8" => 500.25,//黑龙江 8
         "4-10-29" => 9.81, "4-20-29" => 19.62, "4-30-29" => 29.43, "4-50-29" => 49.05, "4-100-29" => 98.1, "4-200-29" => 196.2, "4-300-29" => 294.3, "4-500-29" => 490.5,//青海 29
@@ -72,7 +72,7 @@ class config
         "4-10-13" => 10.01, "4-20-13" => 20.02, "4-30-13" => 30.03, "4-50-13" => 50.05, "4-100-13" => 100.1, "4-200-13" => 200.2, "4-300-13" => 300.3, "4-500-13" => 500.5,//福建 13
         "4-10-5" => 10.035, "4-20-5" => 20.07, "4-30-5" => 30.09, "4-50-5" => 50.15, "4-100-5" => 100.3, "4-200-5" => 200.4, "4-300-5" => 300.6, "4-500-5" => 501,//内蒙古 5
         "4-30-18" => 29.835, "4-50-18" => 49.725, "4-100-18" => 99.45, "4-200-18" => 198.3,//湖南 18
-        "4-10-19" => 10.18, "4-20-19" => 20.36, "4-30-19" => 30.03, "4-50-19" => 50.05, "4-100-19" => 100.1, "4-200-19" => 200.2, "4-300-19" => 300.3, "4-500-19" => 500.5,//广东 19
+        "4-10-19" => 10.03, "4-20-19" => 20.06, "4-30-19" => 29.97, "4-50-19" => 49.95, "4-100-19" => 99.9, "4-200-19" => 199.8, "4-300-19" => 299.7, "4-500-19" => 499.5,//广东 19
         "4-10-7" => 9.93, "4-20-7" => 19.86, "4-30-7" => 29.52, "4-50-7" => 49.2, "4-100-7" => 98.4, "4-200-7" => 196.8, "4-300-7" => 295.2, "4-500-7" => 492,//吉林 7
         "4-10-1" => 10.31, "4-20-1" => 20.32, "4-30-1" => 30.33, "4-50-1" => 50.35, "4-100-1" => 100.4, "4-200-1" => 200.3, "4-300-1" => 300.45, "4-500-1" => 500.75,//北京 1
         "4-10-22" => 10.015, "4-20-22" => 20.03, "4-30-22" => 30.045, "4-50-22" => 50.075, "4-100-22" => 100.15, "4-200-22" => 200.3, "4-300-22" => 300.45, "4-500-22" => 500.75,//重庆 22

+ 2 - 0
helper/refill/api/yl/ruixunda/config.php

@@ -27,6 +27,8 @@ class config
     const ProductIdS = [
         mtopcard\ChinaMobileCard =>
             [
+                10  => '101685',
+                20  => '101686',
                 30  => '101687',
                 50  => '101688',
                 100 => '101689',

+ 1 - 1
helper/refill/api/yl/ruixunda_fs/config.php

@@ -158,7 +158,7 @@ class config
         "4-50-19" => 47.35, "4-100-19" => 94.7, "4-200-19" => 189.4,//广东 19
         "4-50-3" => 46.5, "4-100-3" => 93, "4-200-3" => 186,//河北 3
         "4-50-20" => 46.65, "4-100-20" => 93.3, "4-200-20" => 186.6,//广西 20
-        "4-50-23" => 46.95, "4-100-23" => 93.9, "4-200-23" => 187.8,//四川 23
+        "4-50-23" => 46.7, "4-100-23" => 93.4, "4-200-23" => 186.8,//四川 23
         "4-50-22" => 47, "4-100-22" => 94, "4-200-22" => 188,//重庆 22
 
         //电信

+ 1 - 0
helper/refill/api/yl/yunchonggongfs/config.php

@@ -36,6 +36,7 @@ class config
         "4-30-16" => 28.5, "4-50-16" => 47.5, "4-100-16" => 95, "4-200-16" => 190,//河南 16
         "4-50-3" => 47.25, "4-100-3" => 94.5, "4-200-3" => 189,//河北 3
         "4-30-20" => 28.35, "4-50-20" => 47.25, "4-100-20" => 94.5, "4-200-20" => 189,//广西 20
+        "4-50-23" => 47.25, "4-100-23" => 94.5, "4-200-23" => 189,//四川 23
 
         //电信
         "6-30-18" => 28.2, "6-50-18" => 47, "6-100-18" => 94, "6-200-18" => 188,//湖南 18

+ 13 - 2
mobile/control/refill.php

@@ -31,10 +31,21 @@ class refillControl extends merchantControl
         $goods_list = $sorter($goods_list);
 
         $result = [];
+        $mchid = $this->mchid();
+        $merchant_goods = rcache('merchant_goods', 'refill-', $mchid);
+        $goods = $merchant_goods[$mchid] ?? serialize([]);
+        $goods = unserialize($goods);
         foreach ($goods_list as $card_type => $value) {
             $key = mtopcard\scard_type($card_type);
-            $result[$key] = $value;
+            if (array_key_exists($key, $goods)) {
+                $result[$key] = $goods[$key];
+            } else {
+                $result[$key] = $value;
+            }
         }
+        $thrid_refill = Model('thrid_refill');
+        $pcode = $thrid_refill->getMerchantPcode($mchid);
+        $result['third'] = $pcode;
 
         return self::outsuccess($result);
     }
@@ -526,4 +537,4 @@ class refillControl extends merchantControl
             }
         }
     }
-}
+}

+ 32 - 0
test/TestThirdRefill.php

@@ -44,5 +44,37 @@ class TestThirdRefill extends TestCase
         refill\RefillFactory::instance()->notify('sctongqian', $params);
     }
 
+    public function testMerchantGoods()
+    {
+        $goods_list = refill\RefillFactory::instance()->goods();
+
+        $sorter = function (array $items) {
+            $ret = [];
+            foreach ($items as $key => $val) {
+                sort($val);
+                $ret[$key] = $val;
+            }
+            return $ret;
+        };
+
+        $goods_list = $sorter($goods_list);
+
+        $result = [];
+        $mchid = 10254;
+        $merchant_goods = rcache('merchant_goods', 'refill-', $mchid);
+        $goods = $merchant_goods[$mchid] ?? serialize([]);
+        $goods = unserialize($goods);
+        foreach ($goods_list as $card_type => $value) {
+            $key = mtopcard\scard_type($card_type);
+            if (array_key_exists($key, $goods)) {
+                $result[$key] = $goods[$key];
+            } else {
+                $result[$key] = $value;
+            }
+        }
+        $thrid_refill = Model('thrid_refill');
+        $pcode = $thrid_refill->getMerchantPcode($mchid);
+        $result['third'] = $pcode;
+    }
 
 }