
Odoo中文社区可以通过以下两个域名访问:shine-it.net , odoo.net.cn
由于系统升迁的原因,本论坛部分较早期的内容存在格式和链接损坏失效的问题,并非本论坛系统本身的缺陷,望谅解
本社区没有维护任何QQ群讨论组,任何与本社区同名的QQ群讨论组的言论与本社区无关!
开发人员可以登录gitter讨论组: http://gitter.im/odoo-china/Talk, 需要github账号
如果您登录系统碰到问题,请在微信公众号留言:
填写单行信息,如何避免弹出form试图,求解答!
-
就是在编辑明细行时,只要点击明细行就会弹出明细行form视图,不想在form视图上编辑,想直接在tree上编辑,怎么实现呢,求解答!
-
@小杜 加个这个就可以在tree视图上编辑了。
<tree editable="bottom"> </tree>
-
加过了,本地的可以,服务器上不行啊!很郁闷!!!
-
@小杜 在debug模式下看看服务器上的代码,检查下。如果没问题的话的就不知道了。
-
-
@小杜 你把相关的代码贴出来啊,要不谁也猜不到问题。
-
这是我写的代码:
<xpath expr="//field[@name='validity_date']" position="before"> <field name="d_date" string="订单日期 *"/> <field name="currency_id" string="币种"/> <field name="employee_id" string="业务员 *"/> <!--<field name="c_person_code" string="业务员编码"/>--> <field name="department_id" string="销售部门 *"/> <!--<field name="c_dep_code" string="销售部门编码 *"/>--> <!--<field name="tax_id"/>--> <!--<field name="i_tax_rate"/>--> <field name="i_exch_rate"/> </xpath> <xpath expr="//group[1]" position="inside"> <group> <field name="partner_type_id" string="客户类型 *"/> <field name="partner_level_id" string="客户级别 *"/> <field name="project_type_id"/> <field name="c_is_pass_box"/> <field name="c_maker" string="制单人 *"/> <!--<field name="c_verifier" string="审核人 *"/>--> <!--<field name="c_closer"/>--> </group> </xpath> <xpath expr="//field[@name='validity_date']" position="attributes"> <attribute name="invisible">1</attribute> </xpath> <xpath expr="//field[@name='confirmation_date']" position="attributes"> <attribute name="invisible">1</attribute> </xpath> <xpath expr="//field[@name='pricelist_id']" position="attributes"> <attribute name="invisible">1</attribute> </xpath> <xpath expr="//field[@name='payment_term_id']" position="attributes"> <attribute name="invisible">1</attribute> </xpath> <xpath expr="//notebook/page[last()]" position="attributes"> <attribute name="invisible">1</attribute> </xpath> <xpath expr="//page[1]" position="after"> <page string="其他信息"> <group> <!--<group>--> <!--<field name="project_type_id"/>--> <!--</group>--> <group> <field name="c_verifier" string="审核人 *"/> <field name="c_closer"/> </group> <group> <field name="c_pay_con"/> <field name="c_cost"/> </group> </group> </page> </xpath> <xpath expr="//page[1]" position="attributes"> <attribute name="invisible">1</attribute> </xpath> <xpath expr="//page[1]" position="before"> <page string="明细行"> <field name="U8_order_lines" attrs="{'readonly': [('state', 'in', ('done','cancel'))]}"> <tree> <!--<field name="c_inv_code"/>--> <field name="product_id"/> <field name="c_inv_code"/> <field name="i_quantity"/> <field name="tax_id"/> <field name="i_quoted_price"/> <field name="i_tax_unit_price"/> <field name="i_unit_price"/> <field name="i_tax_subtotal" sum="Total"/> <field name="i_unit_subtotal_price" sum="Total"/> <field name="i_tax_subtotal_price" sum="Total"/> <!--<field name="i_quantity"/>--> <!--<field name="i_quoted_price"/>--> <!--<field name="i_tax_unit_price"/>--> <!--<field name="i_unit_price"/>--> <!--<field name="i_tax_subtotal"/>--> <!--<field name="i_unit_subtotal_price"/>--> <!--<field name="i_tax_subtotal_price"/>--> </tree> <!--<tree editable="bottom">--> <!--<field name="c_inv_code"/>--> <!--<field name="product_id"/>--> <!--<field name="i_quantity"/>--> <!--<field name="i_quoted_price"/>--> <!--<field name="i_tax_unit_price"/>--> <!--<field name="i_unit_price"/>--> <!--<!–<field name="i_tax_subtotal"/>–>--> <!--<!–<field name="i_unit_subtotal_price"/>–>--> <!--<!–<field name="i_tax_subtotal_price"/>–>--> <!--</tree>--> <!--<kanban class="o_kanban_mobile">--> <!--<field name="c_inv_name"/>--> <!--<field name="i_quantity"/>--> <!--<!–<field name="product_uom" groups="product.group_uom"/>–>--> <!--<field name="i_tax_subtotal_price"/>--> <!--<field name="i_unit_subtotal_price"/>--> <!--<templates>--> <!--<t t-name="kanban-box">--> <!--<div t-attf-class="oe_kanban_card oe_kanban_global_click">--> <!--<div class="row">--> <!--<div class="col-xs-8">--> <!--<strong><span><t t-esc="record.c_inv_name.value"/></span></strong>--> <!--</div>--> <!--<div class="col-xs-4">--> <!--<strong><span class="pull-right text-right">--> <!--<t t-esc="record.i_tax_subtotal_price.value"/></span></strong>--> <!--</div>--> <!--</div>--> <!--<div class="row">--> <!--<div class="col-xs-12 text-muted">--> <!--<span>Quantity: <t t-esc="record.i_quantity.value"/> <t t-esc="record.product_uom.value"/></span>--> <!--</div>--> <!--</div>--> <!--<div class="row">--> <!--<div class="col-xs-12 text-muted">--> <!--<span>Unit Price: <t t-esc="record.i_unit_subtotal_price.value"/></span>--> <!--</div>--> <!--</div>--> <!--</div>--> <!--<hr/>--> <!--</t>--> <!--</templates>--> <!--</kanban>--> </field> </page> </xpath> </data>
-
@小杜 明细行里的tree没有加
editable="bottom"
呀 -
我去掉了,刚才是有的
-
应该看下服务器上的代码是否更新上去,本地可以的服务器肯定也是可以的。
-
@鲍永道 好的,谢谢!