Commit 19ead170a96e6a6a18762c5bc7442c9f9915ecde

Authored by pengye
1 parent 3bf027eb

no message

@@ -107,6 +107,20 @@ class Area extends Common @@ -107,6 +107,20 @@ class Area extends Common
107 $this->assign ( 'title','代理商管理'); 107 $this->assign ( 'title','代理商管理');
108 return $this->fetch(); 108 return $this->fetch();
109 } 109 }
  110 +
  111 + /**
  112 + * 禁用运营
  113 + */
  114 + public function setAgentOperate(){
  115 + if(Request::isAjax()){
  116 + $data = Request::except('file');
  117 + $list= file_get_contents(ON_LINE.'App.Agent.getAgentOperate&id='.$data['id']);
  118 + $array = json_decode($list,TRUE);
  119 + return $result = ['code'=>0,'msg'=>'获取成功!','data'=>$array['data'],'rel'=>1];#'count'=>$array['data'][0]['total']
  120 + }
  121 + $this->assign ( 'title','代理商管理');
  122 + return $this->fetch();
  123 + }
110 124
111 /** 125 /**
112 * 停用商家 126 * 停用商家
@@ -23,7 +23,6 @@ @@ -23,7 +23,6 @@
23 ,{field:'sub_openid', title: '运营公众号ID', width:280,fixed: true} 23 ,{field:'sub_openid', title: '运营公众号ID', width:280,fixed: true}
24 ,{field:'openid', title: '一键订商户ID', width:270} 24 ,{field:'openid', title: '一键订商户ID', width:270}
25 ,{field:'account', title: '运营账号', width:120} 25 ,{field:'account', title: '运营账号', width:120}
26 - ,{field:'asname', title: '运营名称', width:120}  
27 ,{field:'cdate', title: '加入时间',width:180} 26 ,{field:'cdate', title: '加入时间',width:180}
28 ,{width:160,title: '操作', align:'center', toolbar: '#barDemo'} 27 ,{width:160,title: '操作', align:'center', toolbar: '#barDemo'}
29 ]] 28 ]]
@@ -32,8 +31,8 @@ @@ -32,8 +31,8 @@
32 table.on('tool(list)', function(obj){ 31 table.on('tool(list)', function(obj){
33 var data = obj.data; 32 var data = obj.data;
34 if(obj.event === 'del'){ 33 if(obj.event === 'del'){
35 - layer.confirm('{:lang("Are you sure you want to delete it")}', function(index){  
36 - $.post("{:url('operateDel')}",{id:data.id},function(res){ 34 + layer.confirm('{:lang("确认禁用?")}', function(index){
  35 + $.post("{:url('setAgentOperate')}",{id:data.id},function(res){
37 if(res.code==1){ 36 if(res.code==1){
38 layer.msg(res.msg,{time:1000,icon:1}); 37 layer.msg(res.msg,{time:1000,icon:1});
39 obj.del(); 38 obj.del();