管理后台>推广员>结算管理>推广提现--部分功能优化

master
chenxiaojun 5 years ago
parent 51d2d91671
commit a7891d6b57

@ -1194,11 +1194,10 @@ class QueryController extends ThinkController
$this->ajaxReturn(['msg' => $msg]);
}
public function set_withdraw_status()
public function set_withdraw_status($status = 1)
{
$withdraw = M('withdraw', "tab_");
$ids = I('ids', 0);
$status = 1;
if (empty($ids)) {
$this->error('参数异常');
}
@ -1207,14 +1206,21 @@ class QueryController extends ThinkController
} else {
$map['id'] = $ids;
}
$map['status'] = 0;
switch ($status) {
case 1:
$map['status'] = 0;
break;
case 2:
$map['status'] = 1;
break;
}
$save['audit_time'] = time();
$save['status'] = $status;
$res = $withdraw->where($map)->save($save);
if ($res === false) {
$this->error('审核失败');
$this->error('操作失败');
} else {
$this->success('审核成功', U('withdraw'));
$this->success('操作成功', U('withdraw'));
}
}

@ -219,9 +219,7 @@
<td>{$record.status_text}</td>
<td>{$record.respond}</td>
<td>
<if condition="$record['status'] eq 2">
<a href="{:U('downloadProve', ['id'=>$record['id']])}">汇款证明</a>
<elseif condition="$record['status'] eq -1"/>
<if condition="$record['status'] eq -1">
<span class="renew-review" data-id="{$record['id']}" style="color: #0bb20c;cursor: pointer;">重新审核</span>
</if>
<if condition="$record['status'] eq -1 or $record['status'] eq 0">

@ -59,6 +59,7 @@
<a class="ajax-post" target-form="ids" url="{:U('set_withdraw_status')}"><span class="button_icon button_icon12"></span>通 过</a>
<a class="agree" data-id="ids"><span class="button_icon button_icon13"></span>驳 回</a>
<a href="{:U('autoReview')}"><span class="button_icon button_icon9 "></span>自动审核管理</a>
<a class="ajax-post" target-form="ids" url="{:U('set_withdraw_status', array('status' => 2))}" style="border: 1px solid #3C95C8;background-color: #3C95C8;background-image: initial"><span style="margin-left: 10px;float: initial;color: #fff;">确认汇款</span></a>
</div>
</div>
</empty>
@ -187,7 +188,7 @@
<a class="ajax-get" url="{:U('set_withdraw_status',array('ids'=>$data['id']))}">通过</a>
<a class="agree" data-id="{$data['id']}">驳回</a>
<elseif condition="$data.status eq 1"/>
<a class="upload-transfer-proof" data-id="{$data['id']}">上传汇款证明</a>
<a class="ajax-get" url="{:U('set_withdraw_status',array('ids'=>$data['id'], 'status' => 2))}">确认汇款</a>
</if>
</div>
</td>

Loading…
Cancel
Save