parent
b2c0272b18
commit
698b6d8f3e
@ -1,65 +1,80 @@ |
||||
<?php |
||||
use \common\libs\MyLib; |
||||
?> |
||||
<script type="text/javascript" language="javascript" src="/js/jquery-1.8.3.js"></script> |
||||
<script type="text/javascript" language="javascript" src="/js/datepicker/WdatePicker.js"></script> |
||||
<script type="text/javascript" language="javascript" src="/js/ajax.js"></script> |
||||
<script type="text/javascript" language="javascript" src="/js/func.js"></script> |
||||
<script type="text/javascript" language="javascript"> |
||||
$(function(){ |
||||
$("#back-btn").click(function(){ |
||||
window.location.href = "/statistics/work?date_begin=<?=$date_begin?>&date_end=<?=$date_end?>&date2_begin=<?=$date2_begin?>&date2_end=<?=$date2_end?>&username=<?=$username?>";
|
||||
<?php $this->beginBlock('header_css'); ?> |
||||
<link href="/assets/css/plugins/bootstrap-table/bootstrap-table.min.css" rel="stylesheet"> |
||||
<?php $this->endBlock(); ?> |
||||
|
||||
<div class="wrapper wrapper-content animated fadeInRight"> |
||||
<div class="ibox float-e-margins"> |
||||
<div class="ibox-content"> |
||||
<div class="row"> |
||||
<div class="col-md-12"> |
||||
<table id="listTable"> |
||||
<thead> |
||||
<tr> |
||||
<th data-field="id">ID</th> |
||||
<th data-field="car_man">车主</th> |
||||
<th data-field="car_no">车牌号</th> |
||||
<th data-field="total1_clear">商业总净保费</th> |
||||
<th data-field="total1_real">折扣后商业净保费</th> |
||||
<th data-field="total1_dis">减免金额</th> |
||||
<th data-field="total1_percent">商业折扣率</th> |
||||
<th data-field="status_name">状态</th> |
||||
<th data-formatter="opFormatter">操作</th> |
||||
</tr> |
||||
</thead> |
||||
</table> |
||||
</div> |
||||
</div> |
||||
</div> |
||||
</div> |
||||
</div> |
||||
|
||||
|
||||
<?php $this->beginBlock('footer_js'); ?> |
||||
<script src="/assets/js/plugins/bootstrap-table/bootstrap-table.min.js"></script> |
||||
<script src="/assets/js/plugins/bootstrap-table/bootstrap-table-mobile.min.js"></script> |
||||
<script src="/assets/js/plugins/bootstrap-table/locale/bootstrap-table-zh-CN.min.js"></script> |
||||
<script src="/assets/js/plugins/layer/laydate/laydate.js"></script> |
||||
<script> |
||||
var o = {}; |
||||
function opFormatter(value, row, index) { |
||||
var opStr = []; |
||||
if(row.op == 1) { |
||||
opStr.push('<a href="javascript:void(0);" onclick="view(' + row.id + ')">'); |
||||
opStr.push('<i class="fa fa-file-o" title="查看"></i>'); |
||||
opStr.push('</a>'); |
||||
} |
||||
|
||||
return opStr.join(' '); |
||||
} |
||||
function view(id) { |
||||
window.open('/insurer/info?id=' + id); |
||||
} |
||||
|
||||
function refreshList() { |
||||
$('#listTable').bootstrapTable('refresh'); |
||||
} |
||||
|
||||
function search() { |
||||
$('#listTable').bootstrapTable('destroy'); |
||||
$('#listTable').bootstrapTable({ |
||||
url: "/statistics/work-info-json", |
||||
pagination: true, |
||||
sidePagination: 'server', |
||||
queryParams: function(params) { |
||||
o['user_id'] = '<?=$user_id?>';
|
||||
o['offset'] = params['offset']; |
||||
o['limit'] = params['limit']; |
||||
return o; |
||||
} |
||||
}); |
||||
return false; |
||||
} |
||||
|
||||
$(function() { |
||||
search(); |
||||
}); |
||||
</script> |
||||
<table width="98%" border="0" align="center" cellpadding="2" cellspacing="1" class="table"> |
||||
<form id="searchForm"> |
||||
<tr> |
||||
<td class="td_bg"> |
||||
<input type="button" class="act_btn" id="back-btn" name="back-btn" value="返回"> |
||||
提单日期: <?=$date_begin?> 至 <?=$date_end?> |
||||
正本日期: <?=$date2_begin?> 至 <?=$date2_end?> |
||||
</td> |
||||
</tr> |
||||
</form> |
||||
</table> |
||||
<table width="98%" border="0" align="center" cellpadding="2" cellspacing="1" class="table"> |
||||
<tr> |
||||
<td width="50" align="center" class="bg_tr" nowrap>车主</td> |
||||
<td width="60" align="center" class="bg_tr" nowrap>车牌号</td> |
||||
<td align="center" class="bg_tr" nowrap>商业总净保费</td> |
||||
<td align="center" class="bg_tr" nowrap>折扣后商业净保费</td> |
||||
<td align="center" class="bg_tr" nowrap>减免金额</td> |
||||
<td align="center" class="bg_tr" nowrap>商业折扣率</td> |
||||
<td align="center" class="bg_tr" nowrap>状态</td> |
||||
<td align="center" class="bg_tr" nowrap>详情</td> |
||||
</tr> |
||||
<?php |
||||
foreach($items as $item) { |
||||
?> |
||||
<tr onMouseOver=overColor(this) onMouseOut=outColor(this)> |
||||
<td align="left" class="td_bg" nowrap><?=$item->car_man?></td>
|
||||
<td align="left" class="td_bg" nowrap><?=$item->car_no?></td>
|
||||
<td align="center" class="td_bg" nowrap><?='¥'.$item->total1_clear?></td>
|
||||
<td align="center" class="td_bg" nowrap><?='¥'.$item->total1_real?></td>
|
||||
<td align="center" class="td_bg" nowrap><?='¥'.$item->total1_dis?></td>
|
||||
<td align="center" class="td_bg" nowrap><?=$item->total1_percent?></td>
|
||||
<td align="center" class="td_bg" nowrap><?=$item->status->name?></td>
|
||||
<td align="center" class="td_bg" nowrap> |
||||
[<a href="/insurer/info?id=<?=$item->id?>" target="_blank">详情</a>]
|
||||
</td> |
||||
</tr> |
||||
<?php |
||||
} |
||||
?> |
||||
<tr> |
||||
<td width="50" align="center" class="bg_tr" nowrap>汇总</td> |
||||
<td width="60" align="center" class="bg_tr" nowrap></td> |
||||
<td align="center" class="bg_tr" nowrap><?=$total[2]?'¥'.number_format($total[2],2):''?></td>
|
||||
<td align="center" class="bg_tr" nowrap><?=$total[8]?'¥'.number_format($total[8],2):''?></td>
|
||||
<td align="center" class="bg_tr" nowrap><?=$total[9]?'¥'.number_format($total[9],2):''?></td>
|
||||
<td align="center" class="bg_tr" nowrap></td> |
||||
<td align="center" class="bg_tr" nowrap></td> |
||||
<td align="center" class="bg_tr" nowrap></td> |
||||
</tr> |
||||
</table> |
||||
<?php $this->endBlock(); ?> |
||||
|
@ -1,108 +1,161 @@ |
||||
<?php |
||||
use \common\libs\MyLib; |
||||
?> |
||||
<script type="text/javascript" language="javascript" src="/js/jquery-1.8.3.js"></script> |
||||
<script type="text/javascript" language="javascript" src="/js/datepicker/WdatePicker.js"></script> |
||||
<script type="text/javascript" language="javascript" src="/js/ajax.js"></script> |
||||
<script type="text/javascript" language="javascript" src="/js/func.js"></script> |
||||
<script type="text/javascript" language="javascript"> |
||||
$(function(){ |
||||
$("#search-btn").click(function(){ |
||||
$('#page').val(0); |
||||
var params = $('#searchForm').serialize(); |
||||
window.location.href = "/statistics/work?" + params; |
||||
<?php $this->beginBlock('header_css'); ?> |
||||
<link href="/assets/css/plugins/bootstrap-table/bootstrap-table.min.css" rel="stylesheet"> |
||||
<?php $this->endBlock(); ?> |
||||
|
||||
<div class="wrapper wrapper-content animated fadeInRight"> |
||||
<div class="ibox float-e-margins"> |
||||
<div class="ibox-title"> |
||||
<h5>工作量统计</h5> |
||||
<div class="ibox-tools"> |
||||
<a class="btn btn-primary btn-xs edit-btn" data-id="0" href="javascript:void(0);" onclick="$('#listTable').bootstrapTable('refresh');"> |
||||
<i class="fa fa-refresh"></i> 刷新 |
||||
</a> |
||||
</div> |
||||
</div> |
||||
<div class="ibox-content"> |
||||
<form role="form" id="searchFrm" class="form-inline" onsubmit="return search();"> |
||||
<div class="form-group" style="margin-bottom: 8px;"> |
||||
<label for="datepicker1">提单日期</label> |
||||
<div class="input-group" id="datepicker1"> |
||||
<input type="text" class="input-sm form-control" id="date_begin" name="date_begin" value="" autocomplete="off" /> |
||||
<span class="input-group-addon">到</span> |
||||
<input type="text" class="input-sm form-control" id="date_end" name="date_end" value="" autocomplete="off" /> |
||||
</div> |
||||
</div> |
||||
<div class="form-group" style="margin-bottom: 8px;"> |
||||
<label for="datepicker2">正本日期</label> |
||||
<div class="input-group" id="datepicker2"> |
||||
<input type="text" class="input-sm form-control" id="date2_begin" name="date2_begin" value="" autocomplete="off" /> |
||||
<span class="input-group-addon">到</span> |
||||
<input type="text" class="input-sm form-control" id="date2_end" name="date2_end" value="" autocomplete="off" /> |
||||
</div> |
||||
</div> |
||||
<div class="form-group" style="margin-bottom: 8px;"> |
||||
<label for="username">工号</label> |
||||
<input type="text" id="username" name="username" class="form-control"> |
||||
</div> |
||||
<div class="form-group" style="margin-bottom: 8px;"> |
||||
<label for="group_id">级别</label> |
||||
<select name="group_id" id="group_id" class="form-control"> |
||||
<option value="0">全部</option> |
||||
<?php |
||||
foreach($group_items as $item) { |
||||
echo '<option value="'.$item->id.'"'; |
||||
if($item->id == $group_id) |
||||
echo ' selected '; |
||||
echo '>'.$item->name.'</option>'; |
||||
} |
||||
?> |
||||
</select> |
||||
</div> |
||||
<div class="form-group" style="margin-bottom: 8px;"> |
||||
<label for="company_id">保险公司</label> |
||||
<select name="company_id" id="company_id" class="form-control"> |
||||
<option value="0">全部</option> |
||||
<?php |
||||
foreach($company_items as $item) { |
||||
echo '<option value="'.$item->id.'"'; |
||||
if($item->id == $company_id) |
||||
echo ' selected '; |
||||
echo '">'.$item->name.'</option>'; |
||||
} |
||||
?> |
||||
</select> |
||||
</div> |
||||
<button type="submit" class="btn btn-primary mb-8">搜索</button> |
||||
</form> |
||||
<div class="row"> |
||||
<div class="col-md-12"> |
||||
<table id="listTable"> |
||||
<thead> |
||||
<tr> |
||||
<th data-field="username">工号</th> |
||||
<th data-field="truename">真实姓名</th> |
||||
<th data-field="total_7">提车总数</th> |
||||
<th data-field="total_1">提单总数</th> |
||||
<th data-field="total_2">商业总净保费</th> |
||||
<th data-field="total_3">交强总净保费</th> |
||||
<th data-field="total_4">商业已收净保费</th> |
||||
<th data-field="total_5">交强已收净保费</th> |
||||
<th data-field="total_6">总签单净保费</th> |
||||
<th data-formatter="opFormatter">操作</th> |
||||
</tr> |
||||
</thead> |
||||
</table> |
||||
</div> |
||||
</div> |
||||
</div> |
||||
</div> |
||||
</div> |
||||
|
||||
|
||||
<?php $this->beginBlock('footer_js'); ?> |
||||
<script src="/assets/js/plugins/bootstrap-table/bootstrap-table.min.js"></script> |
||||
<script src="/assets/js/plugins/bootstrap-table/bootstrap-table-mobile.min.js"></script> |
||||
<script src="/assets/js/plugins/bootstrap-table/locale/bootstrap-table-zh-CN.min.js"></script> |
||||
<script src="/assets/js/plugins/layer/laydate/laydate.js"></script> |
||||
<script> |
||||
var o = {}; |
||||
function opFormatter(value, row, index) { |
||||
var opStr = []; |
||||
if(row.op == 1) { |
||||
opStr.push('<a href="javascript:void(0);" onclick="view(' + row.id + ')">'); |
||||
opStr.push('<i class="fa fa-file-o" title="查看"></i>'); |
||||
opStr.push('</a>'); |
||||
} |
||||
|
||||
return opStr.join(' '); |
||||
} |
||||
function view(id) { |
||||
var title = '查看详情'; |
||||
layer_show(title, '/statistics/work-info?user_id=' + id); |
||||
} |
||||
function refreshList() { |
||||
$('#listTable').bootstrapTable('refresh'); |
||||
} |
||||
|
||||
function search() { |
||||
o = {}; |
||||
var params = $("#searchFrm").serializeArray(); |
||||
$.each(params, function(index) { |
||||
o[this['name']] = this['value']; |
||||
}); |
||||
//导出 |
||||
$("#output-btn").click(function(){ |
||||
$('#page').val(0); |
||||
var params = $('#searchForm').serialize(); |
||||
window.location.href = "/statistics/work-output?" + params; |
||||
$('#listTable').bootstrapTable('destroy'); |
||||
$('#listTable').bootstrapTable({ |
||||
url: "/statistics/work-json", |
||||
pagination: true, |
||||
sidePagination: 'server', |
||||
queryParams: function(params) { |
||||
o['offset'] = params['offset']; |
||||
o['limit'] = params['limit']; |
||||
return o; |
||||
} |
||||
}); |
||||
return false; |
||||
} |
||||
|
||||
$(function() { |
||||
search(); |
||||
laydate({ |
||||
elem:'#date_begin', |
||||
format: 'YYYY-MM-DD' |
||||
}); |
||||
laydate({ |
||||
elem:'#date2_begin', |
||||
format: 'YYYY-MM-DD' |
||||
}); |
||||
laydate({ |
||||
elem:'#date_end', |
||||
format: 'YYYY-MM-DD' |
||||
}); |
||||
laydate({ |
||||
elem:'#date2_end', |
||||
format: 'YYYY-MM-DD', |
||||
istime: true |
||||
}); |
||||
}); |
||||
</script> |
||||
<table width="98%" border="0" align="center" cellpadding="2" cellspacing="1" class="table"> |
||||
<form id="searchForm"> |
||||
<tr> |
||||
<td class="td_bg"> |
||||
提单日期:从<input name="date_begin" type="text" value="<?=$date_begin?>" style="width:100px;" onclick="WdatePicker()">到<input name="date_end" type="text" value="<?=$date_end?>" style="width:100px;" onclick="WdatePicker()">截止
|
||||
正本日期:从<input name="date2_begin" type="text" value="<?=$date2_begin?>" style="width:100px;" onclick="WdatePicker()">到<input name="date2_end" type="text" value="<?=$date2_end?>" style="width:100px;" onclick="WdatePicker()">截止
|
||||
工号:<input name="username" type="text" value="<?=$username?>">
|
||||
级别:<select name="group_id"> |
||||
<option value="0">全部</option> |
||||
<?php |
||||
foreach($group_items as $item) { |
||||
echo '<option value="'.$item->id.'"'; |
||||
if($item->id == $group_id) |
||||
echo ' selected '; |
||||
echo '>'.$item->name.'</option>'; |
||||
} |
||||
?> |
||||
</select> |
||||
<select name="company_id"> |
||||
<option value="0">全部</option> |
||||
<?php |
||||
foreach($company_items as $item) { |
||||
echo '<option value="'.$item->id.'"'; |
||||
if($item->id == $company_id) |
||||
echo ' selected '; |
||||
echo '">'.$item->name.'</option>'; |
||||
} |
||||
?> |
||||
</select> |
||||
<input type="button" class="act_btn" id="search-btn" name="search-btn" value="搜索"> |
||||
<input type="button" class="act_btn" id="output-btn" name="output-btn" value="导出"> |
||||
<a href="/statistics/work?date_begin=<?=date('Y-m-d')?>&date_end=<?=date('Y-m-d')?>">当天</a>
|
||||
<a href="/statistics/work?date_begin=<?=date('Y-m-d',strtotime("-7 day"))?>&date_end=<?=date('Y-m-d')?>">7天</a>
|
||||
<a href="/statistics/work?date_begin=<?=date('Y-m-d',strtotime("-1 month"))?>&date_end=<?=date('Y-m-d')?>">1个月</a>
|
||||
<a href="/statistics/work?date_begin=<?=date('Y-m-d',strtotime("-3 month"))?>&date_end=<?=date('Y-m-d')?>">3个月</a>
|
||||
</td> |
||||
</tr> |
||||
</form> |
||||
</table> |
||||
<table width="98%" border="0" align="center" cellpadding="2" cellspacing="1" class="table"> |
||||
<tr> |
||||
<td width="50" align="center" class="bg_tr" nowrap>工号</td> |
||||
<td width="60" align="center" class="bg_tr" nowrap>真实姓名</td> |
||||
<td width="80" align="center" class="bg_tr" nowrap>通时</td> |
||||
<td align="center" class="bg_tr" nowrap>提车总数</td> |
||||
<td align="center" class="bg_tr" nowrap>提单总数</td> |
||||
<td align="center" class="bg_tr" nowrap>商业总净保费</td> |
||||
<td align="center" class="bg_tr" nowrap>交强总净保费</td> |
||||
<td align="center" class="bg_tr" nowrap>商业已收净保费</td> |
||||
<td align="center" class="bg_tr" nowrap>交强已收净保费</td> |
||||
<td align="center" class="bg_tr" nowrap>总签单净保费</td> |
||||
<td align="center" class="bg_tr" nowrap>详情</td> |
||||
</tr> |
||||
<?php |
||||
foreach($user_rows as $row) { |
||||
?> |
||||
<tr onMouseOver=overColor(this) onMouseOut=outColor(this)> |
||||
<td align="center" class="td_bg" nowrap><?=$row['username']?></td>
|
||||
<td align="center" class="td_bg" nowrap><?=$row['truename']?></td>
|
||||
<td align="center" class="td_bg" nowrap><?=$row['total'][0]!=''?$row['total'][0]:''?></td>
|
||||
<td align="center" class="td_bg" nowrap><?=$row['total'][7]>0?$row['total'][7]:''?></td>
|
||||
<td align="center" class="td_bg" nowrap><?=$row['total'][1]>0?$row['total'][1]:''?></td>
|
||||
<td align="center" class="td_bg" nowrap><?=$row['total'][2]>0?'¥'.number_format($row['total'][2],2):''?></td>
|
||||
<td align="center" class="td_bg" nowrap><?=$row['total'][3]>0?'¥'.number_format($row['total'][3],2):''?></td>
|
||||
<td align="center" class="td_bg" nowrap><?=$row['total'][4]>0?'¥'.number_format($row['total'][4],2):''?></td>
|
||||
<td align="center" class="td_bg" nowrap><?=$row['total'][5]>0?'¥'.number_format($row['total'][5],2):''?></td>
|
||||
<td align="center" class="td_bg" nowrap><?=$row['total'][6]>0?'¥'.number_format($row['total'][6],2):''?></td>
|
||||
<td align="center" class="td_bg" nowrap>[<a href="/statistics/work-info?user_id=<?=$row['id']?>&date_begin=<?=$date_begin?>&date_end=<?=$date_end?>&date2_begin=<?=$date2_begin?>&date2_end=<?=$date2_end?>&username=<?=$username?>">详情</a>]</td>
|
||||
</tr> |
||||
<?php |
||||
} |
||||
?> |
||||
<tr> |
||||
<td width="50" align="center" class="bg_tr" nowrap>汇总</td> |
||||
<td width="60" align="center" class="bg_tr" nowrap></td> |
||||
<td width="60" align="center" class="bg_tr" nowrap></td> |
||||
<td align="center" class="bg_tr" nowrap><?=$sum_total[7]?$sum_total[7]:''?></td>
|
||||
<td align="center" class="bg_tr" nowrap><?=$sum_total[1]?$sum_total[1]:''?></td>
|
||||
<td align="center" class="bg_tr" nowrap><?=$sum_total[2]?'¥'.number_format($sum_total[2],2):''?></td>
|
||||
<td align="center" class="bg_tr" nowrap><?=$sum_total[3]?'¥'.number_format($sum_total[3],2):''?></td>
|
||||
<td align="center" class="bg_tr" nowrap><?=$sum_total[4]?'¥'.number_format($sum_total[4],2):''?></td>
|
||||
<td align="center" class="bg_tr" nowrap><?=$sum_total[5]?'¥'.number_format($sum_total[5],2):''?></td>
|
||||
<td align="center" class="bg_tr" nowrap><?=$sum_total[6]?'¥'.number_format($sum_total[6],2):''?></td>
|
||||
<td align="center" class="bg_tr" nowrap></td> |
||||
</tr> |
||||
</table> |
||||
<?php $this->endBlock(); ?> |
||||
|
Loading…
Reference in new issue