css - Odoo 8 qweb 报表样式修改
问题描述
我正在尝试在 Oddo 8 中修改我的 qweb 报告内容,我正在使用 div 位置。我想在打印视图上隐藏传真字段。我能怎么做?它不工作。我正在尝试像显示没有一样的 css。
下面是我的代码这是我的最终代码
<openerp>
<data>
<template id="report_picking_inherit_demo" inherit_id="stock.report_picking">
<xpath expr="//div[hasclass('page')]/div[hasclass('row')]" position="replace">
<div class="col-xs-6">
<div t-if="o.picking_type_id.code=='incoming' and o.partner_id">
<span>
<strong>Supplier Address:</strong>
</span>
</div>
<div t-if="o.picking_type_id.code=='internal' and o.partner_id">
<span>
<strong>Warehouse Address:</strong>
</span>
</div>
<div t-if="o.picking_type_id.code=='outgoing' and o.partner_id">
<span>
<strong>Customer Addresswww:</strong>
</span>
</div>
<div t-if="o.partner_id" name="partner_header">
<div t-field="o.partner_id"
t-field-options='{"widget": "contact", "fields": ["address", "name", "phone"], "no_marker": true}'/>
</div>
</div>
<div class="col-xs-5 col-xs-offset-1">
<div t-if="o.move_lines and o.move_lines[0].partner_id and o.move_lines[0].partner_id.id != o.partner_id.id">
<span>
<strong>Delivery Address:</strong>
</span>
<div t-field="o.move_lines[0].partner_id"
t-field-options='{"widget": "contact", "fields": ["address", "name", "phone","fax"], "no_marker": true}'/>
</div>
<div t-if="o.picking_type_id.code != 'internal' and (not o.move_lines or not o.move_lines[0].partner_id) and o.picking_type_id.warehouse_id.partner_id">
<span>
<strong>Warehouse Address:</strong>
</span>
<div t-field="o.picking_type_id.warehouse_id.partner_id"
t-field-options='{"widget": "contact", "fields": ["address", "name", "phone","fax"], "no_marker": true}'/>
</div>
</div>
</xpath>
</template>
</data>
在这里我输入了传真示例 https://i.stack.imgur.com/iIUCo.png
之后这个结果
解决方案
从列表中删除字段“传真”,
*.xml
<div t-field="o.partner_id"
t-field-options='{"widget": "contact", "fields": ["address", "name", "phone"], "no_marker": true}'/>
推荐阅读
- javascript - getUserMedia 无视三星浏览器的大小限制
- python - 不明白这个 PdfReadError: EOF marker not found
- tensorflow - Tensorboard:为什么在梯度图上有锯齿形图案?
- javascript - 如何根据子数组的第二个值对数组数组进行排序
- javascript - ReactJS:更新受控输入字段问题
- mysql - 选择时间戳 x 和时间戳 y 之间的数据,以 z 行数返回(按比例缩小的结果集)
- c# - 使用基于服务的数据库分发 .NET 表单应用程序
- c# - 为 TFS 版本设置“KeepForever”
- jquery - 如何在单击时引用一个对象而不是所有具有相同名称的对象
- centos - Julia + Centos - 无法构建 Arpack