1.在addons/report/views/layouts.xml中加入自定义的页码函数
<template id="foot_layout_footer">#定义页码函数名称
<div class="header">
</div>
<t t-raw="0" />
<div class="footer">
<div class="text-center" style="border-top: 1px solid black;">
<ul class="list-inline">
<li>Page:</li>
<li><span class="page"/></li>#当前页码
<li>/</li>
<li><span class="topage"/></li>#总页码
</ul>
</div>
</div>
</template>
2.在函数中引用
<?xml version="1.0" encoding="utf-8">
<openerp>
<data>
<template id="xxxxxx">
<t t-call="report.html_container">
<t t-call="report.foot_layout_footer">
<t t-foreach="docs" t-as="o">
<div class="page">
<div class="oe_structure"/>
<t t-if = "o.reissue_coordination_order">
<h4 style="center;">Linx Work Coordination Order Reissue</h4>
</t>
<t t-if = "not o.reissue_coordination_order">
<h4 style="center;">Linx Work Coordination Order</h4>
</t>
<h5>Coordination Order Number: <span t-field="o.name"/></h5>
<style>
.div-height{width:300px;height:25px}
</style>
<div class="row text-right">
<div class="col-xs=-1">
Manager:<span t-field="o.manager"/>
</div>
<div class="col-xs=-1">
<t t-if="o.agent">
Agent:<span t-field="o.agent"/>
</t>
</div>
</div>
<table class="gridtable table table-bordered table-condensed">
<tbody>
<tr>
<td rowspan="2" style="padding:1px 1; width:15%; text-align:center;">Task Propose Unit</td>
<td rowspan="2" style="padding:1px 1; width:35%;"><span t-field="o.task_propose_unit"/></td>
<td style="padding:1px 1; width:15%; text-align:center;">Propose Department Leader</td>
<td style="padding:1px 1; width:35%;"><span t-field="o.propose_department_leader_approval"/></td>
</tr>
<tr>
<td style="padding:1px 1; width:15%; text-align:center;">Propose Department Head</td>
<td style="padding:1px 1; width:35%;"><span t-field="o.propose_department_heads_endorsement"/></td>
</tr>
<tr>
<td style="padding:1px 1; width:15%; text-align:center;">Task Receive Unit</td>
<td style="padding:1px 1; width:35%;"><span t-field="o.task_receive_unit"/></td>
<td style="padding:1px 1; width:15%; text-align:center;">Receive Department Head</td>
<td style="padding:1px 1; width:35%;"><span t-field="o.receive_department_heads_endorsement"/></td>
</tr>
<tr>
<td style="padding:1px 1; width:15%; text-align:center;">Project</td>
<td style="padding:1px 1; width:85%;" colspan="3">
<t t-foreach="o.project" t-as="proj">
<span t-field="proj.name"/>;
</t>
</td>
</tr>
<tr>
<td style="padding:1px 1; width:15%; text-align:center;">Voucher</td>
<td style="padding:1px 1; width:35%;"><span t-field="o.voucher"/></td>
<td style="padding:1px 1; width:15%; text-align:center;">Voucher Number</td>
<td style="padding:1px 1; width:35%;"><span t-field="o.voucher_number"/></td>
</tr>
<tr>
<td style="padding:1px 1; width:15%; text-align:center;">The End User</td>
<td style="padding:1px 1; width:35%;">
<t t-foreach="o.end_user" t-as="end_user">
<span t-field="end_user.name"/>;
</t>
<td style="padding:1px 1; width:15%; text-align:center;">Contract Number</td>
<td style="padding:1px 1; width:35%;"><span t-field="o.contract_number"/></td>
</tr>
<tr>
<td style="padding:1px 1; width:15%; text-align:center;">Hardware Vendor</td>
<td style="padding:1px 1; width:35%;"><span t-field="o.hardware_vendor"/></td>
<td style="padding:1px 1; width:15%; text-align:center;">Integrators</td>
<td style="padding:1px 1; width:35%;"><span t-field="o.integrators"/></td>
</tr>
<tr>
<td style="padding:1px 1; width:15%; text-align:center;">Project Contact</td>
<td style="padding:1px 1; width:35%;">
<t t-foreach="o.project_contact" t-as="proc">
<span t-field="proc.name"/>;
</t>
</td>
<td style="padding:1px 1; width:15%; text-align:center;">Contact Telephone</td>
<td style="padding:1px 1; width:35%;"><span t-field="o.contact_telephone"/></td>
</tr>
<tr>
<td style="padding:1px 1; width:15%; text-align:center;">Propose Date</td>
<td style="padding:1px 1; width:35%;"><span t-field="o.propose_date"/></td>
<td style="padding:1px 1; width:15%; text-align:center;">Complete Date</td>
<td style="padding:1px 1; width:35%;"><span t-field="o.complete_date"/></td>
</tr>
<tr>
<td style="padding:1px 1; width:15%; text-align:center;">Comment</td>
<td style="padding:1px 1; width:85%;" colspan="3"><span t-field="o.comment"/></td>
</tr>
<tr>
<td style="padding:1px 1; width:15%; text-align:center;">Task Topic</td>
<td style="padding:1px 1; width:85%;" colspan="3"><span t-field="o.task_topic"/></td>
</tr>
<tr>
<td style="padding:1px 1; width:15%; text-align:center;">Task Type</td>
<td style="padding:1px 1; width:85%;" colspan="3">
<t t-foreach="o.task_type" t-as="ty">
[<span t-field="ty.name"/>].
</t>
</td>
</tr>
<tr>
<td style="padding:1px 1; width:15%; align:center;" rowspan="3">The specific requirements of the task</td>
<td style="padding:1px 1;" colspan="3">Task:<span t-field="o.task_content"/></td>
</tr>
<tr>
<td style="padding:1px 1;" colspan="3">Date:<span t-field="o.task_date"/></td>
</tr>
<tr>
<td style="padding:1px 1;" colspan="3">Address:<span t-field="o.task_address"/></td>
</tr>
<tr>
<td style="padding:1px 1; width:15%; text-align:center;">Receive Schedule</td>
<td style="padding:1px 1;" colspan="3"><span t-field="o.receive_schedule"/></td>
</tr>
<tr>
<td style="padding:1px 1;" colspan="4">
Current Results:
<p style="margin:1px 1;">1.The actual situation of the task:</p>
<t t-if="not o.task_actual_implementation">
<div class="div-height"/>
</t>
<p style="margin:1px 15;"><span t-field="o.task_actual_implementation"/></p>
<p style="margin:1px 1;">2.The task was not proformd:</p>
<t t-if="not o.task_not_performed">
<div class="div-height"/>
</t>
<p style="margin:1px 15;"><span t-field="o.task_not_performed"/></p>
<p style="margin:1px 1;">3.Additional tasks:</p>
<t t-if="not o.task_additional_situation">
<div class="div-height"/>
</t>
<p style="margin:1px 15;"><span t-field="o.task_additional_situation"/></p>
<p style="margin:1px 1;">Executant: <span t-field="o.task_executant"/></p>
</td>
</tr>
<tr>
<td style="padding:1px 1;" colspan="4">
Whether to complete this task:<span t-field="o.complete_this_task1"/>
<p style="margin:1px 1;">Remained Problem:</p>
<t t-if="not o.remained_problem">
<div class="div-height"/>
</t>
<p style="margin:1px 15;"><span t-field="o.remained_problem"/></p>
</td>
</tr>
</tbody>
</table>
</div>
</t>
</t>
</t>
</temmplate>
</data>
</openerp>