浏览代码

Merge branch 'rprofit' of 39.97.239.116:gyfl/xyzshop into rprofit

stanley-king 2 年之前
父节点
当前提交
b3849b6a7d
共有 1 个文件被更改,包括 23 次插入18 次删除
  1. 23 18
      admin/templates/default/analysis.new_version.provider.php

+ 23 - 18
admin/templates/default/analysis.new_version.provider.php

@@ -73,7 +73,7 @@
                 <th><label>通道质量</label></th>
                 <td>
                     <select name="quality" class="querySelect">
-                        <!-- <option value=""><?php echo $lang['nc_please_choose']; ?></option> -->
+                        <option value=""><?php echo $lang['nc_please_choose']; ?></option>
                         <option value="<?php echo refill\Quality::Normal; ?>">普充(无流水)
                         </option>
                         <option value="<?php echo refill\Quality::Quick; ?>">快充
@@ -179,6 +179,8 @@
 
         var provider = <?php echo json_encode($output['providers']) ?>
 
+        let ratios;
+
         const defaultChannelType = <?php echo refill\Quality::Normal; ?>;
 
         function formatChannelTable(tableData) {
@@ -283,10 +285,12 @@
                 src += '&filter_wave=' + filter_wave;
             }
             $.get(src, function(data) {
-                if (!data) {
-                    return
+                if (data.state == 'success') {
+                    $('#echart').html(`<img src='data:image/png;base64,${data.img}'/>`)
+                    ratios = data.ratios;
                 }
-                $('#echart').html(data)
+
+
             });
         });
 
@@ -295,20 +299,21 @@
             console.log('querySelect', $(this).val());
             $('#checkChannelContent').children().remove();
             $('#echart').children().remove();
-            if ($(this).val()) {
-                const qualityType = $(this).val();
-                $.get(`index.php?act=refill_analysis&op=provider_data&quality=${qualityType}`, function(data) {
-                    console.log('querySelect', data);
-                    data = JSON.parse(data)
-                    if (data.length > 0) {
-                        formatChannelTable(data);
-                    } else {
-                        $('#checkChannelContent').children().remove();
-                    }
-                })
-            } else {
-                $('#checkChannelContent').children().remove();
-            }
+            // if ($(this).val()) {
+            const qualityType = $(this).val();
+            $.get(`index.php?act=refill_analysis&op=provider_data&quality=${qualityType}`, function(data) {
+                console.log('querySelect', data);
+                data = JSON.parse(data)
+                if (data.length > 0) {
+                    formatChannelTable(data);
+                } else {
+                    $('#checkChannelContent').children().remove();
+                }
+            })
+            // } 
+            // else {
+            //     $('#checkChannelContent').children().remove();
+            // }
         })