我对odoo 10.我努力想改变odoo和数据库下拉的标志在登录页面。与这个问题有关的答案不能解决问题。 我尝试: 1-创建mytheme的模块 2-创建清单和通过继承模板webclient_template.xmlodoo 10后台开发
我的视图初始化 3-写视图,如下所示:
<?xml version="1.0" encoding="UTF-8"?>
<openerp>
<data>
<template id="assets_backend" name="mytheme assets" inherit_id="web.assets_backend"><xpath expr="." position="inside"><link rel="stylesheet" href="/mytheme/static/src/css/base.css"/><script type="text/javascript" src="/mytheme/static/src/js/mytheme.js"></script></xpath>
</template><template id="mytheme.login_layout" inherit_id="web.login_layout" name="My Theme Login">
<xpath expr="//div[@class='oe_single_form_footer']" position="replace">
<div class="oe_single_form_footer">Here you can write your login footer</div>
</xpath>
<xpath expr="//div[@class='oe_single_form_logo']" position="replace">
<div class="oe_single_form_logo">
<img src="/mytheme/static/src/img/logo.png"
alt="My Theme Logo" title="My Theme Logo" />
</div>
</xpath>
</template>
</data>
</openerp>
我的清单如下所示清单 .py:
{
'name': 'mytheme',
'version': '0.1',
'depends': ['base','web'],
'external_dependencies': {},
'data': ['views/webclient_templates.xml'],
'js': ['static/src/js/mytheme.js'],
'css': ['static/src/css/base.css'],
'installable': True,
'auto_install':True,
'active':True,
}
另一个问题是我应该写的js文件? 如下图所示我的基本文件,以清除数据库的选择:
base.css:
<templates>
<!-- Templates modified at the web start, before loading of a database. -->
<!-- Remove the Manage database link, but keep the Powered by OpenERP-->
<
t t-extend="Login">
<t t-jquery="div.oe_login_footer" t-operation="replace">
<a href="http://www.openerp.com" target="_blank">Powered by <span>OpenERP</span></a>
</t>
</t>
</templates
Used links: https://www.odoo.com/forum/help-1/question/how-we-removing-link-that-appear-on-login-page-of-openerp-odoo-54623
如果你改变了公司的标志,然后它会在数据库的登录页自动改变以及数据库下拉菜单页面。 –
是否有任何方式来扩展现有的模板和定制它..如果有人知道请回复 –
添加屏幕短标志你想更改登录屏幕标志或数据库选择标志? –