Commit 78f60f2b706e3673cd0ccda90dd8ff11cf8db040

Authored by teemitop
1 parent 5fde22f5

制造商调整

@@ -497,6 +497,8 @@ class Seller extends Common @@ -497,6 +497,8 @@ class Seller extends Common
497 497
498 //商家设备列表 498 //商家设备列表
499 public function device_list(){ 499 public function device_list(){
  500 + //获取类型
  501 + $facturer = Db::query("SELECT * FROM `xt-member-two-LINE`.xt_dc_dz_facturer");
500 if(Request::isAjax()){ 502 if(Request::isAjax()){
501 $data = Request::except('file'); 503 $data = Request::except('file');
502 $channel = @$data['channel'] ? @$data['channel'] : 1; 504 $channel = @$data['channel'] ? @$data['channel'] : 1;
@@ -510,16 +512,16 @@ class Seller extends Common @@ -510,16 +512,16 @@ class Seller extends Common
510 foreach ($array['data']['list'] as $key => $value) { 512 foreach ($array['data']['list'] as $key => $value) {
511 switch ($value['type']) { 513 switch ($value['type']) {
512 case '1': 514 case '1':
513 - $array['data']['list'][$key]['type'] = '铱方'; 515 + $array['data']['list'][$key]['type'] = $facturer[0]['facturer'];
514 break; 516 break;
515 case '2': 517 case '2':
516 - $array['data']['list'][$key]['type'] = '极钛'; 518 + $array['data']['list'][$key]['type'] = $facturer[1]['facturer'];
517 break; 519 break;
518 case '3': 520 case '3':
519 - $array['data']['list'][$key]['type'] = '酷比'; 521 + $array['data']['list'][$key]['type'] = $facturer[2]['facturer'];
520 break; 522 break;
521 case '4': 523 case '4':
522 - $array['data']['list'][$key]['type'] = '华为'; 524 + $array['data']['list'][$key]['type'] = $facturer[3]['facturer'];
523 break; 525 break;
524 526
525 default: 527 default:
@@ -530,6 +532,7 @@ class Seller extends Common @@ -530,6 +532,7 @@ class Seller extends Common
530 } 532 }
531 return $result = ['code'=>0,'msg'=>'获取成功!','data'=>$array['data']['list'],'count'=>$array['data']['total'],'rel'=>1]; 533 return $result = ['code'=>0,'msg'=>'获取成功!','data'=>$array['data']['list'],'count'=>$array['data']['total'],'rel'=>1];
532 } 534 }
  535 + $this->assign ( 'facturer',$facturer);
533 $this->assign ( 'title','商家设备列表'); 536 $this->assign ( 'title','商家设备列表');
534 return $this->fetch(); 537 return $this->fetch();
535 } 538 }
@@ -554,6 +557,9 @@ class Seller extends Common @@ -554,6 +557,9 @@ class Seller extends Common
554 557
555 //灰度用户列表 558 //灰度用户列表
556 public function gray_user_list(){ 559 public function gray_user_list(){
  560 + //获取类型
  561 + $facturer = Db::query("SELECT * FROM `xt-member-two-LINE`.xt_dc_dz_facturer");
  562 + $this->assign ( 'facturer',$facturer);
557 if(Request::isAjax()){ 563 if(Request::isAjax()){
558 $data = Request::except('file'); 564 $data = Request::except('file');
559 $channel = @$data['channel'] ? @$data['channel'] : 1; 565 $channel = @$data['channel'] ? @$data['channel'] : 1;
@@ -566,16 +572,16 @@ class Seller extends Common @@ -566,16 +572,16 @@ class Seller extends Common
566 foreach ($array['data']['list'] as $key => $value) { 572 foreach ($array['data']['list'] as $key => $value) {
567 switch ($value['type']) { 573 switch ($value['type']) {
568 case '1': 574 case '1':
569 - $array['data']['list'][$key]['type'] = '铱方'; 575 + $array['data']['list'][$key]['type'] = $facturer[0]['facturer'];
570 break; 576 break;
571 case '2': 577 case '2':
572 - $array['data']['list'][$key]['type'] = '极钛'; 578 + $array['data']['list'][$key]['type'] = $facturer[1]['facturer'];
573 break; 579 break;
574 case '3': 580 case '3':
575 - $array['data']['list'][$key]['type'] = '酷比'; 581 + $array['data']['list'][$key]['type'] = $facturer[2]['facturer'];
576 break; 582 break;
577 case '4': 583 case '4':
578 - $array['data']['list'][$key]['type'] = '华为'; 584 + $array['data']['list'][$key]['type'] = $facturer[3]['facturer'];
579 break; 585 break;
580 586
581 default: 587 default:
@@ -585,6 +591,9 @@ class Seller extends Common @@ -585,6 +591,9 @@ class Seller extends Common
585 } 591 }
586 return $result = ['code'=>0,'msg'=>'获取成功!','data'=>$array['data']['list'],'count'=>$array['data']['total'],'rel'=>1]; 592 return $result = ['code'=>0,'msg'=>'获取成功!','data'=>$array['data']['list'],'count'=>$array['data']['total'],'rel'=>1];
587 } 593 }
  594 + //获取类型
  595 + $facturer = Db::query("SELECT * FROM `xt-member-two-LINE`.xt_dc_dz_facturer");
  596 + $this->assign ( 'facturer',$facturer);
588 $this->assign ( 'title','灰度用户列表'); 597 $this->assign ( 'title','灰度用户列表');
589 return $this->fetch(); 598 return $this->fetch();
590 } 599 }
@@ -610,6 +619,8 @@ class Seller extends Common @@ -610,6 +619,8 @@ class Seller extends Common
610 619
611 //获取在线设备情况 620 //获取在线设备情况
612 public function get_device_online_status(){ 621 public function get_device_online_status(){
  622 + //获取类型
  623 + $facturer = Db::query("SELECT * FROM `xt-member-two-LINE`.xt_dc_dz_facturer");
613 if(Request::isAjax()){ 624 if(Request::isAjax()){
614 $data = Request::except('file'); 625 $data = Request::except('file');
615 $channel = @$data['channel'] ? @$data['channel'] : 1; 626 $channel = @$data['channel'] ? @$data['channel'] : 1;
@@ -622,16 +633,16 @@ class Seller extends Common @@ -622,16 +633,16 @@ class Seller extends Common
622 foreach ($array['data']['list'] as $key => $value) { 633 foreach ($array['data']['list'] as $key => $value) {
623 switch ($value['type']) { 634 switch ($value['type']) {
624 case '1': 635 case '1':
625 - $array['data']['list'][$key]['type'] = '铱方'; 636 + $array['data']['list'][$key]['type'] = $facturer[0]['facturer'];
626 break; 637 break;
627 case '2': 638 case '2':
628 - $array['data']['list'][$key]['type'] = '极钛'; 639 + $array['data']['list'][$key]['type'] = $facturer[1]['facturer'];
629 break; 640 break;
630 case '3': 641 case '3':
631 - $array['data']['list'][$key]['type'] = '酷比'; 642 + $array['data']['list'][$key]['type'] = $facturer[2]['facturer'];
632 break; 643 break;
633 case '4': 644 case '4':
634 - $array['data']['list'][$key]['type'] = '华为'; 645 + $array['data']['list'][$key]['type'] = $facturer[3]['facturer'];
635 break; 646 break;
636 647
637 default: 648 default:
@@ -641,6 +652,7 @@ class Seller extends Common @@ -641,6 +652,7 @@ class Seller extends Common
641 } 652 }
642 return $result = ['code'=>0,'msg'=>'获取成功!','data'=>$array['data']['list'],'count'=>$array['data']['total'],'rel'=>1]; 653 return $result = ['code'=>0,'msg'=>'获取成功!','data'=>$array['data']['list'],'count'=>$array['data']['total'],'rel'=>1];
643 } 654 }
  655 + $this->assign ( 'facturer',$facturer);
644 $this->assign ( 'title','商家话机在线设备列表'); 656 $this->assign ( 'title','商家话机在线设备列表');
645 return $this->fetch(); 657 return $this->fetch();
646 } 658 }
@@ -649,6 +661,8 @@ class Seller extends Common @@ -649,6 +661,8 @@ class Seller extends Common
649 * 从商家维度统计:订单、短信等情况 661 * 从商家维度统计:订单、短信等情况
650 */ 662 */
651 public function GetReserveList(){ 663 public function GetReserveList(){
  664 + //获取类型
  665 + $facturer = Db::query("SELECT * FROM `xt-member-two-LINE`.xt_dc_dz_facturer");
652 if(Request::isAjax()){ 666 if(Request::isAjax()){
653 $data = Request::except('file'); 667 $data = Request::except('file');
654 $key= input('post.key') ? input('post.key') : ""; 668 $key= input('post.key') ? input('post.key') : "";
@@ -682,16 +696,16 @@ class Seller extends Common @@ -682,16 +696,16 @@ class Seller extends Common
682 if($value['is_tele']==1){ 696 if($value['is_tele']==1){
683 switch ($value['type']) { 697 switch ($value['type']) {
684 case '1': 698 case '1':
685 - $array['data']['list'][$key]['dv'] = '铱方电话机'; 699 + $array['data']['list'][$key]['dv'] = $facturer[0]['facturer'];
686 break; 700 break;
687 case '2': 701 case '2':
688 - $array['data']['list'][$key]['dv'] = '极钛电话机'; 702 + $array['data']['list'][$key]['dv'] = $facturer[1]['facturer'];
689 break; 703 break;
690 case '3': 704 case '3':
691 - $array['data']['list'][$key]['dv'] = '酷比平板'; 705 + $array['data']['list'][$key]['dv'] = $facturer[2]['facturer'];
692 break; 706 break;
693 case '4': 707 case '4':
694 - $array['data']['list'][$key]['dv'] = '华为平板'; 708 + $array['data']['list'][$key]['dv'] = $facturer[3]['facturer'];
695 break; 709 break;
696 default: 710 default:
697 $array['data']['list'][$key]['dv'] = '无'; 711 $array['data']['list'][$key]['dv'] = '无';
@@ -391,6 +391,8 @@ class Template extends Common{ @@ -391,6 +391,8 @@ class Template extends Common{
391 391
392 //安卓包管理 392 //安卓包管理
393 public function android(){ 393 public function android(){
  394 + //获取类型
  395 + $facturer = Db::query("SELECT * FROM `xt-member-two-LINE`.xt_dc_dz_facturer");
394 if(Request::isAjax()){ 396 if(Request::isAjax()){
395 $list = db('android')->select(); 397 $list = db('android')->select();
396 foreach ($list as $key => $value) { 398 foreach ($list as $key => $value) {
@@ -398,15 +400,15 @@ class Template extends Common{ @@ -398,15 +400,15 @@ class Template extends Common{
398 switch ($value['flag']) { 400 switch ($value['flag']) {
399 case '1': 401 case '1':
400 $list[$key]['flag'] = '一键订手机'; 402 $list[$key]['flag'] = '一键订手机';
401 - $list[$key]['make'] = $value['make']==1 ? "铱方" : "极钛"; 403 + $list[$key]['make'] = $value['make']==1 ? $facturer[0]['facturer'] : $facturer[1]['facturer'];
402 break; 404 break;
403 case '2': 405 case '2':
404 $list[$key]['flag'] = '一键订平板'; 406 $list[$key]['flag'] = '一键订平板';
405 - $list[$key]['make'] = $value['make']==1 ? "酷比" : "华为"; 407 + $list[$key]['make'] = $value['make']==1 ? $facturer[3]['facturer'] : $facturer[4]['facturer'];
406 break; 408 break;
407 case '3': 409 case '3':
408 $list[$key]['flag'] = '一键订电话机'; 410 $list[$key]['flag'] = '一键订电话机';
409 - $list[$key]['make'] = $value['make']==1 ? "铱方" : "极钛"; 411 + $list[$key]['make'] = $value['make']==1 ? $facturer[0]['facturer'] : $facturer[1]['facturer'];
410 break; 412 break;
411 default: 413 default:
412 $list[$key]['flag'] = 'error'; 414 $list[$key]['flag'] = 'error';
@@ -19,13 +19,13 @@ @@ -19,13 +19,13 @@
19 </select> 19 </select>
20 </div> 20 </div>
21 </div> 21 </div>
22 -  
23 厂商: 22 厂商:
24 <div class="layui-input-inline layui-form"> 23 <div class="layui-input-inline layui-form">
25 <div class="layui-input-8"> 24 <div class="layui-input-8">
26 <select name="class" id="manufacturer" lay-filter="manufacturer"> 25 <select name="class" id="manufacturer" lay-filter="manufacturer">
27 - <option value="1">铱方</option>  
28 - <option value="2">极钛</option> 26 + {foreach $facturer as $key=>$vo}
  27 + <option value="{$vo.id}">{$vo.facturer}</option>
  28 + {/foreach}
29 </select> 29 </select>
30 </div> 30 </div>
31 </div> 31 </div>
@@ -24,8 +24,9 @@ @@ -24,8 +24,9 @@
24 <div class="layui-input-inline layui-form"> 24 <div class="layui-input-inline layui-form">
25 <div class="layui-input-8"> 25 <div class="layui-input-8">
26 <select name="class" id="manufacturer" lay-filter="manufacturer"> 26 <select name="class" id="manufacturer" lay-filter="manufacturer">
27 - <option value="1">铱方</option>  
28 - <option value="2">极钛</option> 27 + {foreach $facturer as $key=>$vo}
  28 + <option value="{$vo.id}">{$vo.facturer}</option>
  29 + {/foreach}
29 </select> 30 </select>
30 </div> 31 </div>
31 </div> 32 </div>
@@ -24,8 +24,9 @@ @@ -24,8 +24,9 @@
24 <div class="layui-input-inline layui-form"> 24 <div class="layui-input-inline layui-form">
25 <div class="layui-input-8"> 25 <div class="layui-input-8">
26 <select name="class" id="manufacturer" lay-filter="manufacturer"> 26 <select name="class" id="manufacturer" lay-filter="manufacturer">
27 - <option value="1">铱方</option>  
28 - <option value="2">极钛</option> 27 + {foreach $facturer as $key=>$vo}
  28 + <option value="{$vo.id}">{$vo.facturer}</option>
  29 + {/foreach}
29 </select> 30 </select>
30 </div> 31 </div>
31 </div> 32 </div>