You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
simple-yewu/frontend/views/finance/chuna-gongzi-info.php

769 lines
48 KiB

<?php
use \common\libs\MyLib;
?>
<link href="/css/tabs.css" rel="stylesheet" type="text/css">
<form id="theFrm">
<input type="hidden" name="id" value="<?=$pay_info->id?>">
<input type="hidden" name="pay_chexian" value="<?=$pay_chexian?>">
<input type="hidden" name="pay_nochexian" value="<?=$pay_nochexian?>">
<input type="hidden" name="pay_dz" value="<?=$pay_dz?>">
<input type="hidden" name="pay_date" value="<?=$pay_date?>">
<input type="hidden" name="user_id" value="<?=$user_info->id?>">
<p>&nbsp;</p>
<h2 align="center"><?=date("Y年m月",strtotime($pay_date.'-01'))?>提成工资部分</h2>
<h3 align="center">应提成工资:<span><?=number_format($pay_info->ticheng_should_pay,2)?></span> 元 <span style="color:#ff0000;">实提成工资:<span><?=number_format($pay_info->ticheng_real_pay,2)?></span> 元</span></h3>
<br>
<h3>提成工资</h3>
<table width="98%" border="0" align="center" cellpadding="3" cellspacing="1" class="table">
<!-- <tr>-->
<!-- <td align="center" colspan="9" height="25" class="bg_tr">财务统计</td>-->
<!-- </tr>-->
<tr>
<td height="25" align="center" class="bg_tr">保单提成</td>
<td height="25" align="center" class="bg_tr">团队长提成</td>
<td height="25" align="center" class="bg_tr">非车险提成</td>
<td height="25" align="center" class="bg_tr">维修提成</td>
<td height="25" align="center" class="bg_tr">合计</td>
</tr>
<tr>
<td height="25" align="center" class="td_bg"><?=$pay_chexian?></td>
<td height="25" align="center" class="td_bg"><?=$pay_dz?></td>
<td height="25" align="center" class="td_bg"><?=$pay_nochexian?></td>
<td height="25" align="center" class="td_bg"></td>
<td height="25" align="center" class="td_bg"><?=$pay_chexian + $pay_nochexian + $pay_dz?></td>
</tr>
</table>
<br>
<div align="center">
<?php if($pay_info->status_id < 4 || $pay_info->status_id == 8): ?>
<input id="submit-btn" type=button class="ACT_btn" name=Submit2 value=" 提交 "/>
&nbsp;&nbsp;
<?php endif;?>
<input id="back-btn" type="button" class="ACT_btn" name="Submit3" value=" 返回 ">
</div>
<br>
<table>
<tbody>
<tr>
<TD height="30" align="center" class=tab-off id=navcell onclick=open_up(1) name="navcell">▼详情</TD>
</tr>
</tbody>
</table>
<TABLE id=tb1 cellSpacing=1 cellPadding=0 width="100%" border=0 name="tb">
<TR>
<TD vAlign=top>
<h3>保单提成</h3>
<?php if($my_type1_query->count() > 0) { ?>
<table width="98%" border="0" align="center" cellpadding="3" cellspacing="1" class="table">
<tr>
<td align="center" colspan="13" height="25" class="bg_tr">我的新保</td>
</tr>
<tr>
<td width="50" height="25" align="center" class="bg_tr">序号</td>
<td height="25" align="center" class="bg_tr">车牌号</td>
<td height="25" align="center" class="bg_tr">正本日期</td>
<td height="25" align="center" class="bg_tr">商业净保费</td>
<td height="25" align="center" class="bg_tr">加点比例</td>
<td height="25" align="center" class="bg_tr">基本比例</td>
<td height="25" align="center" class="bg_tr">应提金额</td>
<!-- <td height="25" align="center" class="bg_tr">原新保提成</td>-->
<td height="25" align="center" class="bg_tr">减免金额</td>
<td height="25" align="center" class="bg_tr">自费礼品</td>
<td height="25" align="center" class="bg_tr">自费礼券</td>
<td height="25" align="center" class="bg_tr">业务自付</td>
<td height="25" align="center" class="bg_tr">实提金额</td>
<td height="25" align="center" class="bg_tr">详情</td>
</tr>
<?php
$should_pay = 0;
$real_pay = 0;
$total1_clear = 0;
$total1_dis = 0;
$ticket_all = 0;
$gift_all = 0;
$zifu_all = 0;
foreach($my_type1_query->each() as $index=>$pay_order) {
$order_info = $pay_order->order;
$caiwu_info = $order_info->caiwu;//carwuordert
$money = $caiwu_info->money1;
$ticket = $order_info->getGiftPrice(1,1);
$gift = $order_info->getGiftPrice(1,0);
$should_pay += $pay_order->should_pay;
$real_pay += $pay_order->real_pay;
$total1_clear += $order_info->total1_clear;
$total1_dis += $order_info->total1_dis;
$ticket_all += $ticket;
$gift_all += $gift;
if($order_info->yuangong_money > 0){
$zifu_all += $order_info->yuangong_money;
}
?>
<tr>
<td width="50" height="25" align="center" class="td_bg">
<input type="hidden" name="tc_my_payids_1[]" value="<?=$pay_order->id?>">
<?=$index+1?>
</td>
<td height="25" align="center" class="td_bg"><?=$order_info->car_no?></td>
<td height="25" align="center" class="td_bg"><?=$order_info->print_date?></td>
<td height="25" align="center" class="td_bg"><?=$order_info->total1_clear?></td>
<td height="25" align="center" class="td_bg"><?=$caiwu_info->ticheng_zong_rate?></td>
<td height="25" align="center" class="td_bg"><?=$caiwu_info->yeji_rate?></td>
<td height="25" align="center" class="td_bg"><?=$pay_order->should_pay?></td>
<!-- <td height="25" align="center" class="td_bg">--//=$pay_order->first_xinbao_ticheng?><!--</td>-->
<td height="25" align="center" class="td_bg"><?=$order_info->total1_dis?></td>
<td height="25" align="center" class="td_bg"><a href="javascript:void(0);" onclick="open_gift_dlg(<?=$order_info->id?>,1,1)"><?=$ticket?></a></td>
<td height="25" align="center" class="td_bg"><a href="javascript:void(0);" onclick="open_gift_dlg(<?=$order_info->id?>,1,0)"><?=$gift?></a></td>
<td height="25" align="center" class="td_bg"><?=$order_info->yuangong_money?></td>
<td height="25" align="center" class="td_bg"><?=$pay_order->real_pay?></td>
<td height="25" align="center" class="td_bg">[<a href="/insurer/info?id=<?=$order_info->id?>" target="_blank">详情</a>]</td>
</tr>
<?php
}
?>
<tr>
<td width="50" height="25" align="center" class="bg_tr"></td>
<td height="25" align="center" class="bg_tr"></td>
<td height="25" align="center" class="bg_tr"></td>
<td height="25" align="center" class="bg_tr"><?=number_format($total1_clear,2)?></td>
<td height="25" align="center" class="bg_tr"></td>
<td height="25" align="center" class="bg_tr"></td>
<td height="25" align="center" class="bg_tr"><?=number_format($should_pay,2)?></td>
<td height="25" align="center" class="bg_tr"><?=number_format($total1_dis,2)?></td>
<td height="25" align="center" class="bg_tr"><?=number_format($ticket_all,2)?></td>
<td height="25" align="center" class="bg_tr"><?=number_format($gift_all,2)?></td>
<td height="25" align="center" class="bg_tr"><?=number_format($zifu_all,2)?></td>
<td height="25" align="center" class="bg_tr"><?=number_format($real_pay,2)?></td>
<td height="25" align="center" class="bg_tr"></td>
</tr>
</table>
<?php } ?>
<?php if($my_type3_query->count() > 0) { ?>
<table width="98%" border="0" align="center" cellpadding="3" cellspacing="1" class="table">
<tr>
<td align="center" colspan="13" height="25" class="bg_tr">我的续保</td>
</tr>
<tr>
<td width="50" height="25" align="center" class="bg_tr">序号</td>
<td height="25" align="center" class="bg_tr">车牌号</td>
<td height="25" align="center" class="bg_tr">正本日期</td>
<td height="25" align="center" class="bg_tr">商业净保费</td>
<td height="25" align="center" class="bg_tr">加点比例</td>
<td height="25" align="center" class="bg_tr">基本比例</td>
<td height="25" align="center" class="bg_tr">应提金额</td>
<td height="25" align="center" class="bg_tr">优惠金额</td>
<td height="25" align="center" class="bg_tr">自费礼品</td>
<td height="25" align="center" class="bg_tr">自费礼券</td>
<td height="25" align="center" class="bg_tr">自付减免</td>
<td height="25" align="center" class="bg_tr">实提金额</td>
<td height="25" align="center" class="bg_tr">详情</td>
</tr>
<?php
$should_pay = 0;
$real_pay = 0;
$total1_clear = 0;
$total1_dis = 0;
$ticket_all = 0;
$gift_all = 0;
$zifu_all = 0;
foreach($my_type3_query->each() as $index=>$pay_order) {
$order_info = $pay_order->order;
$caiwu_info = $order_info->caiwu;//carwuordert
$money = $caiwu_info->money1;
$ticket = $order_info->getGiftPrice(1,1);
$gift = $order_info->getGiftPrice(1,0);
$should_pay += $pay_order->should_pay;
$real_pay += $pay_order->real_pay;
$total1_clear += $order_info->total1_clear;
$total1_dis += $order_info->total1_dis;
$ticket_all += $ticket;
$gift_all += $gift;
if($order_info->yuangong_money > 0){
$zifu_all += $order_info->yuangong_money;
}
?>
<tr>
<td width="50" height="25" align="center" class="td_bg">
<input type="hidden" name="tc_my_payids_1[]" value="<?=$pay_order->id?>">
<?=$index+1?>
</td>
<td height="25" align="center" class="td_bg"><?=$order_info->car_no?></td>
<td height="25" align="center" class="td_bg"><?=$order_info->print_date?></td>
<td height="25" align="center" class="td_bg"><?=$order_info->total1_clear?></td>
<td height="25" align="center" class="td_bg"><?=$caiwu_info->ticheng_zong_rate?></td>
<td height="25" align="center" class="td_bg"><?=$caiwu_info->yeji_rate?></td>
<td height="25" align="center" class="td_bg"><?=$pay_order->should_pay?></td>
<td height="25" align="center" class="td_bg"><?=$order_info->total1_dis?></td>
<td height="25" align="center" class="td_bg"><a href="javascript:void(0);" onclick="open_gift_dlg(<?=$order_info->id?>,1,1)"><?=$order_info->getGiftPrice(1,1)?></a></td>
<td height="25" align="center" class="td_bg"><a href="javascript:void(0);" onclick="open_gift_dlg(<?=$order_info->id?>,1,0)"><?=$order_info->getGiftPrice(1,0)?></a></td>
<td height="25" align="center" class="td_bg"><?=$order_info->yuangong_money?></td>
<td height="25" align="center" class="td_bg"><?=$pay_order->real_pay?></td>
<td height="25" align="center" class="td_bg">[<a href="/insurer/info?id=<?=$order_info->id?>" target="_blank">详情</a>]</td>
</tr>
<?php
}
?>
<tr>
<td width="50" height="25" align="center" class="bg_tr"></td>
<td height="25" align="center" class="bg_tr"></td>
<td height="25" align="center" class="bg_tr"></td>
<td height="25" align="center" class="bg_tr"><?=number_format($total1_clear,2)?></td>
<td height="25" align="center" class="bg_tr"></td>
<td height="25" align="center" class="bg_tr"></td>
<td height="25" align="center" class="bg_tr"><?=number_format($should_pay,2)?></td>
<td height="25" align="center" class="bg_tr"><?=number_format($total1_dis,2)?></td>
<td height="25" align="center" class="bg_tr"><?=number_format($ticket_all,2)?></td>
<td height="25" align="center" class="bg_tr"><?=number_format($gift_all,2)?></td>
<td height="25" align="center" class="bg_tr"><?=number_format($zifu_all,2)?></td>
<td height="25" align="center" class="bg_tr"><?=number_format($real_pay,2)?></td>
<td height="25" align="center" class="bg_tr"></td>
</tr>
</table>
<?php } ?>
<?php if($my_type0_query->count() > 0) { ?>
<table width="98%" border="0" align="center" cellpadding="3" cellspacing="1" class="table">
<tr>
<td align="center" colspan="13" height="25" class="bg_tr">我的原新保</td>
</tr>
<tr>
<td width="50" height="25" align="center" class="bg_tr">序号</td>
<td height="25" align="center" class="bg_tr">车牌号</td>
<td height="25" align="center" class="bg_tr">正本日期</td>
<td height="25" align="center" class="bg_tr">商业净保费</td>
<td height="25" align="center" class="bg_tr">基本比例</td>
<td height="25" align="center" class="bg_tr">应提金额</td>
<td height="25" align="center" class="bg_tr">原新保提成</td>
<td height="25" align="center" class="bg_tr">实提金额</td>
<td height="25" align="center" class="bg_tr">详情</td>
</tr>
<?php
$should_pay = 0;
$real_pay = 0;
$total1_clear = 0;
$total1_dis = 0;
foreach($my_type0_query->each() as $index=>$pay_order) {
$order_info = $pay_order->order;
$caiwu_info = $order_info->caiwu;//carwuordert
// $money = $caiwu_info->money1;
$should_pay += $pay_order->should_pay;
$real_pay += $pay_order->real_pay;
$total1_clear += $order_info->total1_clear;
// $total1_dis += $order_info->total1_dis;
?>
<tr>
<td width="50" height="25" align="center" class="td_bg">
<input type="hidden" name="tc_my_payids_1[]" value="<?=$pay_order->id?>">
<?=$index+1?>
</td>
<td height="25" align="center" class="td_bg"><?=$order_info->car_no?></td>
<td height="25" align="center" class="td_bg"><?=$order_info->print_date?></td>
<td height="25" align="center" class="td_bg"><?=$order_info->total1_clear?></td>
<td height="25" align="center" class="td_bg"><?=$caiwu_info->first_xinbao_rate?></td>
<td height="25" align="center" class="td_bg"><?=$pay_order->should_pay?></td>
<td height="25" align="center" class="td_bg"><?=$pay_order->first_xinbao_ticheng?></td>
<td height="25" align="center" class="td_bg"><?=$pay_order->real_pay?></td>
<td height="25" align="center" class="td_bg">[<a href="/insurer/info?id=<?=$order_info->id?>" target="_blank">详情</a>]</td>
</tr>
<?php
}
?>
<tr>
<td width="50" height="25" align="center" class="bg_tr"></td>
<td height="25" align="center" class="bg_tr"></td>
<td height="25" align="center" class="bg_tr"></td>
<td height="25" align="center" class="bg_tr"><?=number_format($total1_clear,2)?></td>
<td height="25" align="center" class="bg_tr"></td>
<td height="25" align="center" class="bg_tr"><?=number_format($should_pay,2)?></td>
<td height="25" align="center" class="bg_tr"></td>
<td height="25" align="center" class="bg_tr"><?=number_format($real_pay,2)?></td>
<td height="25" align="center" class="bg_tr"></td>
</tr>
</table>
<?php } ?>
<?php if($type3_query->count() > 0) { ?>
<input type="button" class="act_btn" id="output-send-btn" name="output-btn" value="导出">
<table width="98%" border="0" align="center" cellpadding="3" cellspacing="1" class="table">
<tr>
<td align="center" colspan="7" height="25" class="bg_tr">送单统计</td>
</tr>
<tr>
<td width="50" height="25" align="center" class="bg_tr">序号</td>
<td height="25" align="center" class="bg_tr">车牌号</td>
<td height="25" align="center" class="bg_tr">被保险人</td>
<td height="25" align="center" class="bg_tr">送单地址</td>
<td height="25" align="center" class="bg_tr">时间</td>
<td height="25" align="center" class="bg_tr">送单提成</td>
<td height="25" align="center" class="bg_tr">详情</td>
</tr>
<?php
$real_pay = 0;
foreach($type3_query->each() as $index=>$pay_order) {
$order_info = $pay_order->order;
$caiwu_info = $order_info->caiwu;
$send_info = $order_info->sendLog;
$real_pay += $pay_order->real_pay;
?>
<tr>
<td width="50" height="25" align="center" class="td_bg">
<input type="hidden" name="tc_send_payids[]" value="<?=$pay_order->id?>">
<?=$index+1?>
</td>
<td height="25" align="center" class="td_bg"><?=$order_info->car_no?></td>
<td height="25" align="center" class="td_bg"><?=MyLib::substr_cut($order_info->id_man,15)?></td>
<td height="25" align="left" class="td_bg">
<?=$order_info->direction1?$order_info->direction1->name:''?>
<?=$order_info->range1?$order_info->range1->name:''?>
<?=$order_info->city1?$order_info->city1->name:''?>
<?=$order_info->district1?$order_info->district1->name:''?>
<?=$order_info->send_address1?>
</td>
<td height="25" align="center" class="td_bg"><?=date('Y-m-d H:i:s',$send_info->send_time)?></td>
<td height="25" align="center" nowrap class="td_bg"><input name="send_moneys[]" type="text" value="<?=$caiwu_info->songdan_ticheng?>" style="width:60px;"/></td>
<td height="25" align="center" class="td_bg">[<a href="/insurer/info?id=<?=$order_info->id?>" target="_blank">详情</a>]</td>
</tr>
<?php
}
?>
<tr>
<td width="50" height="25" align="center" class="bg_tr"></td>
<td height="25" align="center" class="bg_tr"></td>
<td height="25" align="center" class="bg_tr"></td>
<td height="25" align="center" class="bg_tr"></td>
<td height="25" align="center" class="bg_tr"></td>
<td height="25" align="center" class="bg_tr"><?=number_format($real_pay,2)?></td>
<td height="25" align="center" class="bg_tr"></td>
</tr>
</table>
<?php } ?>
<!-- 内勤核保-->
<?php if($my_type5_query->count() > 0) { ?>
<input type="button" class="act_btn" id="output-hebao-btn" name="output-btn" value="导出">
<table width="98%" border="0" align="center" cellpadding="3" cellspacing="1" class="table">
<tr>
<td align="center" colspan="7" height="25" class="bg_tr">核保统计</td>
</tr>
<tr>
<td width="50" height="25" align="center" class="bg_tr">序号</td>
<td height="25" align="center" class="bg_tr">车牌号</td>
<td height="25" align="center" class="bg_tr">正本日期</td>
<td height="25" align="center" class="bg_tr">被保险人</td>
<td height="25" align="center" class="bg_tr">核保比例</td>
<td height="25" align="center" class="bg_tr">核保提成</td>
<td height="25" align="center" class="bg_tr">详情</td>
</tr>
<?php
$real_pay = 0;
foreach($my_type5_query->each() as $index=>$pay_order) {
$order_info = $pay_order->order;
$caiwu_info = $order_info->caiwu;
$rate = $caiwu_info->hebao_ticheng;
// $money = $caiwu_info->money4;
$send_info = $order_info->sendLog;
$real_pay += $pay_order->real_pay;
?>
<tr>
<td width="50" height="25" align="center" class="td_bg">
<input type="hidden" name="neqi_payids[]" value="<?=$pay_order->id?>">
<?=$index+1?>
</td>
<td height="25" align="center" class="td_bg"><?=$order_info->car_no?></td>
<td height="25" align="center" class="td_bg"><?=$order_info->print_date?></td>
<td height="25" align="center" class="td_bg"><?=MyLib::substr_cut($order_info->id_man,15)?></td>
<td height="25" align="center" class="td_bg"><?=$rate?>元</td>
<td height="25" align="center" class="td_bg"><?=$pay_order->real_pay?>元</td>
<td height="25" align="center" class="td_bg">[<a href="/insurer/info?id=<?=$order_info->id?>" target="_blank">详情</a>]</td>
</tr>
<?php
}
?>
<tr>
<td width="50" height="25" align="center" class="bg_tr"></td>
<td height="25" align="center" class="bg_tr"></td>
<td height="25" align="center" class="bg_tr"></td>
<td height="25" align="center" class="bg_tr"></td>
<td height="25" align="center" class="bg_tr"></td>
<td height="25" align="center" class="bg_tr"><?=number_format($real_pay,2)?></td>
<td height="25" align="center" class="bg_tr"></td>
</tr>
</table>
<?php } ?>
<!-- 内勤正本-->
<?php if($my_type6_query->count() > 0) { ?>
<table width="98%" border="0" align="center" cellpadding="3" cellspacing="1" class="table">
<tr>
<td align="center" colspan="7" height="25" class="bg_tr">正本统计</td>
</tr>
<tr>
<td width="50" height="25" align="center" class="bg_tr">序号</td>
<td height="25" align="center" class="bg_tr">车牌号</td>
<td height="25" align="center" class="bg_tr">正本时间</td>
<td height="25" align="center" class="bg_tr">被保险人</td>
<td height="25" align="center" class="bg_tr">正本比例</td>
<td height="25" align="center" class="bg_tr">正本提成</td>
<td height="25" align="center" class="bg_tr">详情</td>
</tr>
<?php
$real_pay = 0;
foreach($my_type6_query->each() as $index=>$pay_order) {
$order_info = $pay_order->order;
$caiwu_info = $order_info->caiwu;
$rate = $caiwu_info->zhengben_ticheng;
$send_info = $order_info->sendLog;
$real_pay += $pay_order->real_pay;
?>
<tr>
<td width="50" height="25" align="center" class="td_bg">
<input type="hidden" name="zhengben[]" value="<?=$pay_order->id?>">
<?=$index+1?>
</td>
<td height="25" align="center" class="td_bg"><?=$order_info->car_no?></td>
<td height="25" align="center" class="td_bg"><?=$order_info->print_date?></td>
<td height="25" align="center" class="td_bg"><?=MyLib::substr_cut($order_info->id_man,15)?></td>
<td height="25" align="center" class="td_bg"><?=$rate?>元</td>
<td height="25" align="center" class="td_bg"><?=$pay_order->real_pay?></td>
<td height="25" align="center" class="td_bg">[<a href="/insurer/info?id=<?=$order_info->id?>" target="_blank">详情</a>]</td>
</tr>
<?php
}
?>
<tr>
<td width="50" height="25" align="center" class="bg_tr"></td>
<td height="25" align="center" class="bg_tr"></td>
<td height="25" align="center" class="bg_tr"></td>
<td height="25" align="center" class="bg_tr"></td>
<td height="25" align="center" class="bg_tr"></td>
<td height="25" align="center" class="bg_tr"><?=number_format($real_pay,2)?></td>
<td height="25" align="center" class="bg_tr"></td>
</tr>
</table>
<?php } ?>
<br>
<h3>非车险提成</h3>
<!-- 非车险销售-->
<?php if($my_type1_query_non->count() > 0) { ?>
<table width="98%" border="0" align="center" cellpadding="3" cellspacing="1" class="table">
<tr>
<td align="center" colspan="9" height="25" class="bg_tr">非车险销售统计</td>
</tr>
<tr>
<td width="50" height="25" align="center" class="bg_tr">序号</td>
<td height="25" align="center" class="bg_tr">车牌号</td>
<td height="25" align="center" class="bg_tr">正本时间</td>
<td height="25" align="center" class="bg_tr">被保险人</td>
<td height="25" align="center" class="bg_tr">险种</td>
<td height="25" align="center" class="bg_tr">保费</td>
<td height="25" align="center" class="bg_tr">提成比例</td>
<td height="25" align="center" class="bg_tr">提成</td>
<td height="25" align="center" class="bg_tr">详情</td>
</tr>
<?php
$real_pay = 0;
foreach($my_type1_query_non->each() as $index=>$pay_order) {
$order_info = $pay_order->nonOrder;
$non_info = $order_info->nonInsurance;
$caiwu_info = $order_info->caiwu1;//ordercarwut
$real_pay += $pay_order->real_pay;
?>
<tr>
<td width="50" height="25" align="center" class="td_bg">
<input type="hidden" name="non_hebao[]" value="<?=$pay_order->id?>">
<?=$index+1?>
</td>
<td height="25" align="center" class="td_bg"><?=$order_info->car_no?></td>
<td height="25" align="center" class="td_bg"><?=$order_info->print_date?></td>
<td height="25" align="center" class="td_bg"><?=MyLib::substr_cut($non_info->insurant_name,15)?></td>
<td height="25" align="center" class="td_bg"><?=$order_info->sche->name?></td>
<td height="25" align="center" class="td_bg"><?=$order_info->payer1_money?></td>
<td height="25" align="center" class="td_bg"><?=$caiwu_info->jiben_rate?></td>
<td height="25" align="center" class="td_bg"><?=$pay_order->real_pay?></td>
<td height="25" align="center" class="td_bg">[<a href="/non-auto-insurance/bd-info-search?non_id= <?=$order_info->non_id?> &order_id=<?=$order_info->id?>" target="_blank">详情</a>]</td>
</tr>
<?php
}
?>
<tr>
<td width="50" height="25" align="center" class="bg_tr"></td>
<td height="25" align="center" class="bg_tr"></td>
<td height="25" align="center" class="bg_tr"></td>
<td height="25" align="center" class="bg_tr"></td>
<td height="25" align="center" class="bg_tr"></td>
<td height="25" align="center" class="bg_tr"></td>
<td height="25" align="center" class="bg_tr"></td>
<td height="25" align="center" class="bg_tr"><?=number_format($real_pay,2)?></td>
<td height="25" align="center" class="bg_tr"></td>
</tr>
</table>
<?php } ?>
<!-- 非车险核保-->
<?php if($my_type1_query_hebao->count() > 0) { ?>
<table width="98%" border="0" align="center" cellpadding="3" cellspacing="1" class="table">
<tr>
<td align="center" colspan="9" height="25" class="bg_tr">非车险核保统计</td>
</tr>
<tr>
<td width="50" height="25" align="center" class="bg_tr">序号</td>
<td height="25" align="center" class="bg_tr">车牌号</td>
<td height="25" align="center" class="bg_tr">正本时间</td>
<td height="25" align="center" class="bg_tr">被保险人</td>
<td height="25" align="center" class="bg_tr">险种</td>
<td height="25" align="center" class="bg_tr">保费</td>
<td height="25" align="center" class="bg_tr">提成比例</td>
<td height="25" align="center" class="bg_tr">提成</td>
<td height="25" align="center" class="bg_tr">详情</td>
</tr>
<?php
$real_pay = 0;
foreach($my_type1_query_hebao->each() as $index=>$pay_order) {
$order_info = $pay_order->nonOrder;
$non_info = $order_info->nonInsurance;
$caiwu_info = $order_info->caiwu1;//ordercarwut
$rate = $caiwu_info->rate4;
$real_pay += $pay_order->real_pay;
?>
<tr>
<td width="50" height="25" align="center" class="td_bg">
<input type="hidden" name="non_hebao[]" value="<?=$pay_order->id?>">
<?=$index+1?>
</td>
<td height="25" align="center" class="td_bg"><?=$order_info->car_no?></td>
<td height="25" align="center" class="td_bg"><?=$order_info->print_date?></td>
<td height="25" align="center" class="td_bg"><?=MyLib::substr_cut($non_info->insurant_name,15)?></td>
<td height="25" align="center" class="td_bg"><?=$order_info->sche->name?></td>
<td height="25" align="center" class="td_bg"><?=$order_info->payer1_money?></td>
<td height="25" align="center" class="td_bg"><?=$order_info->hebao_ticheng?></td>
<td height="25" align="center" class="td_bg"><?=$caiwu_info->hebao_ticheng?></td>
<td height="25" align="center" class="td_bg">[<a href="/non-auto-insurance/bd-info-search?non_id= <?=$order_info->non_id?> &order_id=<?=$order_info->id?>" target="_blank">详情</a>]</td>
</tr>
<?php
}
?>
<tr>
<td width="50" height="25" align="center" class="bg_tr"></td>
<td height="25" align="center" class="bg_tr"></td>
<td height="25" align="center" class="bg_tr"></td>
<td height="25" align="center" class="bg_tr"></td>
<td height="25" align="center" class="bg_tr"></td>
<td height="25" align="center" class="bg_tr"></td>
<td height="25" align="center" class="bg_tr"></td>
<td height="25" align="center" class="bg_tr"><?=number_format($real_pay,2)?></td>
<td height="25" align="center" class="bg_tr"></td>
</tr>
</table>
<?php } ?>
<!--外区--><br>
<h3>外区车险提成</h3>
<?php if($my_out_query->count() > 0) { ?>
<table width="98%" border="0" align="center" cellpadding="3" cellspacing="1" class="table">
<tr>
<td align="center" colspan="13" height="25" class="bg_tr">外区车险</td>
</tr>
<tr>
<td width="50" height="25" align="center" class="bg_tr">序号</td>
<td height="25" align="center" class="bg_tr">车牌号</td>
<td height="25" align="center" class="bg_tr">正本日期</td>
<td height="25" align="center" class="bg_tr">商业总保费</td>
<td height="25" align="center" class="bg_tr">交强总保费</td>
<td height="25" align="center" class="bg_tr">商业净保费</td>
<td height="25" align="center" class="bg_tr">交强净保费</td>
<td height="25" align="center" class="bg_tr">总保费比例</td>
<td height="25" align="center" class="bg_tr">净保费比例</td>
<td height="25" align="center" class="bg_tr">应提金额</td>
<td height="25" align="center" class="bg_tr">实提金额</td>
<td height="25" align="center" class="bg_tr">详情</td>
</tr>
<?php
$should_pay = 0;
$real_pay = 0;
$total1_clear = 0;
$total1_dis = 0;
$ticket_all = 0;
$gift_all = 0;
$zifu_all = 0;
foreach($my_out_query->each() as $index=>$pay_order) {
$order_info = $pay_order->order;
$caiwu_info = $order_info->caiwu;//carwuordert
$money = $caiwu_info->money1;
$ticket = $order_info->getGiftPrice(1,1);
$gift = $order_info->getGiftPrice(1,0);
$should_pay += $pay_order->should_pay;
$real_pay += $pay_order->real_pay;
$total1_clear += $order_info->total1_clear;
$total1_dis += $order_info->total1_dis;
$ticket_all += $ticket;
$gift_all += $gift;
if($order_info->yuangong_money > 0){
$zifu_all += $order_info->yuangong_money;
}
?>
<tr>
<td width="50" height="25" align="center" class="td_bg">
<input type="hidden" name="tc_my_payids_1[]" value="<?=$pay_order->id?>">
<?=$index+1?>
</td>
<td height="25" align="center" class="td_bg"><?=$order_info->car_no?></td>
<td height="25" align="center" class="td_bg"><?=$order_info->print_date?></td>
<td height="25" align="center" class="td_bg"><?=$order_info->total1?></td>
<td height="25" align="center" class="td_bg"><?=$order_info->total2?></td>
<td height="25" align="center" class="td_bg"><?=$order_info->total1_clear?></td>
<td height="25" align="center" class="td_bg"><?=$order_info->total2_clear?></td>
<td height="25" align="center" class="td_bg"><?=$caiwu_info->zong_bf_rate?></td>
<td height="25" align="center" class="td_bg"><?=$caiwu_info->jing_bf_rate?></td>
<td height="25" align="center" class="td_bg"><?=$pay_order->should_pay?></td>
<td height="25" align="center" class="td_bg"><?=$pay_order->real_pay?></td>
<td height="25" align="center" class="td_bg">[<a href="/insurer/info?id=<?=$order_info->id?>" target="_blank">详情</a>]</td>
</tr>
<?php
}
?>
<tr>
<td width="50" height="25" align="center" class="bg_tr"></td>
<td height="25" align="center" class="bg_tr"></td>
<td height="25" align="center" class="bg_tr"></td>
<td height="25" align="center" class="bg_tr"><?=number_format($total1_clear,2)?></td>
<td height="25" align="center" class="bg_tr"></td>
<td height="25" align="center" class="bg_tr"></td>
<td height="25" align="center" class="bg_tr"><?=number_format($should_pay,2)?></td>
<td height="25" align="center" class="bg_tr"><?=number_format($real_pay,2)?></td>
<td height="25" align="center" class="bg_tr"></td>
</tr>
</table>
<?php } ?>
</TD>
</TR>
</TABLE>
<table>
<tbody>
<tr>
<TD height="30" align="center" class=tab-off id=navcell onclick=open_up(2) name="navcell">▲操作记录</TD>
</tr>
</tbody>
</table>
<TABLE id=tb2 cellSpacing=1 cellPadding=0 width="100%" border=0 name="tb" class="hide-table">
<TR>
<TD vAlign=top>
<div id="car_history_list"></div>
</TD>
</TR>
</TABLE>
</form>
<script type="text/javascript" language="javascript" src="/js/jquery-1.8.3.js"></script>
<link rel="stylesheet" href="../Myfile/css/font.css?v=20190611">
<link rel="stylesheet" href="../Myfile/css/xadmin.css?v=20190605">
<link rel="stylesheet" href="../Myfile/css/theme274.min.css?v=20190605">
<script type="text/javascript" language="javascript" src="/js/jquery-1.8.3.js"></script>
<script src="../Myfile/lib/layui/layui.js?v=20190611" charset="utf-8"></script>
<script type="text/javascript" src="../Myfile/js/xadmin.js?v=20190612"></script>
<script type="text/javascript" language="javascript" src="/js/ajax.js?v=2019"></script><script type="text/javascript" language="javascript" src="/js/func.js"></script>
<script type="text/javascript" src="/js/artDialog/jquery.artDialog.js?skin=default"></script>
<script type="text/javascript" src="/js/artDialog/plugins/iframeTools.source.js"></script>
<script type="text/javascript" language="javascript" src="/js/common2.js"></script>
<script type="text/javascript" language="javascript">
function cal_pay(obj1,total,dis,price1,price2,price3,price4,obj2,obj3) {
var total1 = Number($('#' + obj1).val())/100 * Number(total);
var total2 = total1 - Number(dis) - Number(price1) - Number(price2) - Number(price3) - Number(price4);
$('#' + obj2).val(total1.toFixed(2));
$('#' + obj3).val(total2.toFixed(2));
}
function cal_money(obj1,val,obj2) {
var total = Number($('#' + obj1).val())/100 * Number(val);
$('#' + obj2).val(total.toFixed(2));
}
function cal_rate(obj1,val,obj3,dis) {
if(Number(val) == 0) {
$('#' + obj3).val('0.00');
return;
}
var rate = (Number($('#' + obj1).val()))/Number(val) * 100 ;
$('#' + obj3).val(rate.toFixed(2));
}
function open_gift_dlg(order_id,is_free,type) {
$.dialog.open('/finance/pay2-gift-info?user_id=<?=$user_info->id?>&pay_date=<?=$pay_date?>&order_id=' + order_id + '&is_free=' + is_free + '&type=' + type,{
left: '40%',
top: '0%',
fixed: true
});
}
//操作历史
gotoPage('/personnel/ajax-history-index?pay_id=<?=$pay_info->id?>&page=1','car_history_list');
$(function () {
//提交按钮
$("#submit-btn").click(function(){
if(confirm('是否确认提交?')) {
var params = $("#theFrm").serialize();
$.post('/finance/chuna-gongzi-save',params,function(obj){
alert(obj.msg);
if(obj.success) {
$('#back-btn').click();
}
},'json');
}
});
//返回按钮
$('#back-btn').click(function(){
window.location.href='/finance/chuna-gongzi-list?<?=$back_params?>';
});
$("#output-hebao-btn").click(function () {
$('#page').val(0);
var params = $("#theFrm").serialize();
//window.location.href = "/finance/receipt-output?" + params;
var url = "/finance/receipt-hebao-output";
$.post(url, params, function (obj) {
alert(obj.msg);
if (obj.success) {
window.location.href = obj.files[0].src;
}
}, 'json');
});
$("#output-send-btn").click(function () {
$('#page').val(0);
var params = $("#theFrm").serialize();
//window.location.href = "/finance/receipt-output?" + params;
var url = "/finance/receipt-send-output";
$.post(url, params, function (obj) {
alert(obj.msg);
if (obj.success) {
window.location.href = obj.files[0].src;
}
}, 'json');
});
});
</script>