有需求是
编辑条件,进行对条件的路由拼接,进行展示对应报表
在原生的 domain widget 效果不是很理想,并想展示只是编辑条件以及展示条件,并不能满足。所以继承开发并另命名widget
代码如下:
js 修改
在原有代码基础上复制进行修改
export class XCDomainField extends Component {static template = "iframe_manage.XCDomainField";xxxx...}
export const xcdomainField = {component: XCDomainField,xxxx...}
registry.category("fields").add("xcdomain", xcdomainField);
xml 修改
在原有代码基础上复制进行修改
<?xml version="1.0" encoding="UTF-8" ?>
<templates xml:space="preserve"><t t-name="iframe_manage.XCDomainField"><div t-att-class="{ o_inline_mode: !props.editInDialog }"><t t-set="resModel" t-value="getResModel()"/><t t-if="resModel"><t t-if