提交 f948dcd4 authored 作者: chengye's avatar chengye

结算列表添加状态查询条件

上级 89e9d27b
......@@ -87,6 +87,10 @@ class Payment extends Base
$map[]=['pay.status','=',"$payment_status"];
$this->assign('payment_status',$payment_status);
break;
case '4':
$map[]=['pay.status','=',"$payment_status"];
$this->assign('payment_status',$payment_status);
break;
case '':
$this->assign('payment_status','');
break;
......
......@@ -35,6 +35,8 @@ class Settle extends Base
}
$search_text = Request::get('search_text');
$search_type = Request::get('search_type');
$settle_status = Request::get('settle_status');
if($search_text){
switch ($search_type) {
case '1':
......@@ -62,6 +64,29 @@ class Settle extends Base
$this->assign('search_type','');
$this->assign('search_text','');
}
//结算状态
if($settle_status !== ''){
switch ($settle_status) {
case '0':
$map[]=['settle.status','=',"$settle_status"];
$this->assign('payment_status',$settle_status);
break;
case '1':
$map[]=['settle.status','=',"$settle_status"];
$this->assign('payment_status',$settle_status);
break;
case '4':
$map[]=['settle.status','=',"$settle_status"];
$this->assign('settle_status',$settle_status);
break;
case '':
$this->assign('settle_status','');
break;
}
}else{
$this->assign('settle_status','');
}
//区域
$area_id = Request::get('area_id');
if($area_id){
......
......@@ -29,8 +29,7 @@ class EmPayment extends Base
->field('em.em_numb')
->field('r.region_name,station.station_name')
->join(['em_account'=>'ea'],'ea.account_id=pay.account_id')
->leftJoin(['em_payment_invoice'=>'epi'],'epi.payment_id = pay.payment_id')
->join(['em_payment_invoice'=>'epi'],'epi.payment_id = pay.payment_id')
->join(['em'],'em.id=ea.em_id')
->join(['station_info'=>'station'],'station.station_id=em.station_id')
->join(['region'=>'r'],'station.area_id = r.id')
......
......@@ -29,6 +29,8 @@
<option value="" {if $payment_status === '' } selected {/if}>缴费状态</option>
<option value="0" {if $payment_status === 0 } selected {/if}>未缴费</option>
<option value="1" {if $payment_status == 1 } selected {/if}>已缴费</option>
<option value="4" {if $payment_status == 4 } selected {/if}>已审核</option>
</select>
</div>
<div class="layui-input-inline layui-show-xs-block" style="width:100px;">
......
......@@ -24,6 +24,15 @@
<input type="text" name="search_text"
style="width:150px;" placeholder="搜索内容" autocomplete="off" id="search_text" class="layui-input" value="{$search_text}">
</div>
<div class="layui-input-inline" style="width:150px;">
<select name="settle_status" id="settle_status">
<option value="" {if $settle_status === '' } selected {/if}>结算状态</option>
<option value="0" {if $settle_status === 0 } selected {/if}>未结算</option>
<option value="1" {if $settle_status == 1 } selected {/if}>已结算</option>
<option value="4" {if $settle_status == 4 } selected {/if}>已审核</option>
</select>
</div>
<div class="layui-input-inline layui-show-xs-block" style="width:150px;">
<select name="area_id" id="area_id">
<option value="0"> 区域</option>
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论