<script language="javascript" src="/js/LodopFuncs.js"></script>
<object  id="LODOP_OB" classid="clsid:2105C259-1E0C-4534-8141-A753534CB4CA" width=0 height=0>
    <embed id="LODOP_EM" type="application/x-print-lodop" width=0 height=0></embed>
</object>
<table style="width:100%;">
    <tr>
        <td>
            <div>

                <div id="print_data">
                    <div style="margin:0 auto;width:750px; text-align: right;"><?=$params['order_id']?></div>
                    <table border="1" cellspacing="0" align="center" style="border-bottom:0px;text-align: left; width: 750px;margin:auto" cellpadding="2">
                        <tr>
                            <td colspan="6" align="center"><strong class="primarytitle">送单表</strong></td>
                        </tr>
                        <tr>
                            <td nowrap>车牌号</td>
                            <td><?=$params['car_no']?></td>
                            <td>厂牌型号</td>
                            <td><?=$params['car_model']?></td>
                            <td>保险公司</td>
                            <td><?=$params['insurer_company']?></td>
                        </tr>
                        <tr>
                            <td nowrap>联系人</td>
                            <td><?=$params['link_man']?></td>
                            <td>被保险人</td>
                            <td><?=$params['insurer_man']?></td>
                            <td>缴费方式</td>
                            <td><?=$params['pay_type']?></td>
                        </tr>
                        <tr>
                            <td nowrap>联系电话</td>
                            <td><?=$params['link_tel']?></td>
                            <td>保险起期</td>
                            <td><?=$params['insurer_date']?></td>
                            <td>出单日期</td>
                            <td><?=$params['upload_date']?></td>
                        </tr>
                        <tr>
                            <td nowrap>交强保费</td>
                            <td><?=$params['total2']?></td>
                            <td>商业保费</td>
                            <td><?=$params['total1']?></td>
                            <td>车船税</td>
                            <td><?=$params['total3']?></td>
                        </tr>
                        <tr>
                            <td nowrap>共计签单</td>
                            <td><?=$params['total_all']?></td>
                            <td>实收金额</td>
                            <td><?=$params['total_real']?></td>
                            <td>发票抬头</td>
                            <td><?=$params['piao_header']?></td>
                        </tr>
                        <tr>
                            <td nowrap>送单备注</td>
                            <td colspan="5"><?=$params['send_remark']?></td>
                        </tr>
                        <tr>
                            <td nowrap>缴费单号</td>
                            <td colspan="3"><?=$params['pay_no']?></td>
                            <td>送单日期</td>
                            <td><?=$params['send_date']?></td>
                        </tr>
                        <tr>
                            <td nowrap>投保单地址</td>
                            <td colspan="5">
                                <?=$params['address1']?>
                            </td>
                        </tr>
                        <tr>
                            <td nowrap>正本地址</td>
                            <td colspan="5">
                                <?=$params['address2']?>
                            </td>
                        </tr>
                        <tr>
                            <td>礼品</td>
                            <td colspan="5">
                                <table width="100%" border="1" align="center" cellpadding="3" cellspacing="1">
                                    <tr>
                                        <?php
                                        $index = 0;
                                        if(isset($params['gifts'])) foreach($params['gifts'] as $gift) {
                                            if($index > 0 && $index%4==0) {
                                                echo '</tr><tr>';
                                            }
                                            $index++;
                                            echo '<td class="td_bg">';
                                            echo $gift;
                                            echo '</td>';
                                        }
                                        while($index%4!=0) {
                                            $index++;
                                            echo '<td class="td_bg"></td>';
                                        }
                                        ?>
                                    </tr>
                                </table>
                            </td>
                        </tr>
                        <!--tr>
                            <td>礼品签字</td>
                            <td nowrap>&nbsp;</td>
                            <td>返现金额</td>
                            <td><?=$params['total1_dis']?></td>
                            <td>领款人签字</td>
                            <td nowrap>&nbsp;</td>
                        </tr-->
                        <tr>
                            <td>业务员</td>
                            <td nowrap><?=$params['sale_man']?></td>
                            <td>电话</td>
                            <td><?=$params['sale_tel']?></td>
                            <td>送单员</td>
                            <td nowrap>&nbsp;</td>
                        </tr>
                    </table>
                    <table border="1" cellspacing="0" align="center" style="text-align: left; width: 750px;margin:auto;" cellpadding="2">
                        <tr style="height:35px;">
                            <td width="10%">优惠金额</td>
                            <td width="9%"><?=$params['total1_dis']?></td>
                            <td width="7%">银行</td>
                            <td width="9%">&nbsp;</td>
                            <td width="6%">账号</td>
                            <td width="30%">&nbsp;</td>
                            <td width="7%">户名</td>
                            <td width="12%">&nbsp;</td>
                        </tr>
                    </table>
                    <div style="margin:0 auto;width:750px;text-align: right;padding-top:30px;">
                        <span>签字日期   ____________________</span>
                        &nbsp;
                        <span>客户签字   ____________________</span>
                    </div>
                </div>
            </div>
        </td>
    </tr>
</table>
<script language="javascript" type="text/javascript">
    function CheckIsInstall() {
        try{
            var LODOP=getLodop();
        }catch(err){
        }
    };
    CheckIsInstall();
    function CreateFullBill() {
        LODOP=getLodop();
        LODOP.PRINT_INIT("打印控件_Lodop功能_车务系统");
        LODOP.ADD_PRINT_HTML(40,-18,800,340,document.getElementById("print_data").innerHTML);
    };
    function Design1() {
        CreateFullBill();
//		LODOP.SET_SHOW_MODE("HIDE_ITEM_LIST",true);//设置对象列表默认处于关闭状态
//		LODOP.SET_SHOW_MODE("TEXT_SHOW_BORDER",1); //设置字符编辑框默认为single
        LODOP.PRINT_DESIGN();
    };
//    Design1();
</script>
