Files
jikimo_sf/sf_plan/views/change_manufactuing.xml

185 lines
14 KiB
XML

<?xml version="1.0" encoding="utf-8"?>
<odoo>
<data>
<!-- 增加权限相关的按钮 -->
<record id="custom_mrp_unbuild_form_view" model="ir.ui.view">
<field name="name">custom.mrp.unbuild.form</field>
<field name="model">mrp.unbuild</field>
<field name="inherit_id" ref="mrp.mrp_unbuild_form_view"/>
<field name="arch" type="xml">
<xpath expr="//form//header//button[@name='action_validate']" position="after">
<field name="active" invisible="1"/>
<field name="check_status" invisible="1"/>
<!-- <button name="archive" type="object" string="归档" icon="fa-archive" class="oe_highlight" attrs="{'invisible': [('active', '=', False)]}"/> -->
<!-- <button name="unarchive" type="object" string="取消归档" icon="fa-archive" class="oe_highlight" attrs="{'invisible': [('active', '=', True)]}"/> -->
<button name="action_check" string="审核" type="object" class="oe_highlight"
attrs="{'invisible': [('check_status', '=', True)]}" groups="sf_base.group_plan_director"/>
<!-- <button name="action_uncheck" string="禁用" type="object" class="oe_highlight" attrs="{'invisible': [('check_status', '=', False)]}" groups="sf_base.group_plan_director"/> -->
</xpath>
</field>
</record>
<!-- 增加权限相关的按钮 -->
<record id="custom_stock_scrap_form_view" model="ir.ui.view">
<field name="name">custom.stock.scrap.form</field>
<field name="model">stock.scrap</field>
<field name="inherit_id" ref="stock.stock_scrap_form_view"/>
<field name="arch" type="xml">
<xpath expr="//form//header//button[@name='action_validate']" position="after">
<field name="active" invisible="1"/>
<field name="check_status" invisible="1"/>
<!-- <button name="archive" type="object" string="归档" icon="fa-archive" class="oe_highlight" attrs="{'invisible': [('active', '=', False)]}"/> -->
<!-- <button name="unarchive" type="object" string="取消归档" icon="fa-archive" class="oe_highlight" attrs="{'invisible': [('active', '=', True)]}"/> -->
<button name="action_check" string="审核" type="object" class="oe_highlight"
attrs="{'invisible': [('check_status', '=', True)]}" groups="sf_base.group_plan_director"/>
<!-- <button name="action_uncheck" string="禁用" type="object" class="oe_highlight" attrs="{'invisible': [('check_status', '=', False)]}" groups="sf_base.group_plan_director"/> -->
</xpath>
</field>
</record>
<!-- 增加权限相关的按钮 -->
<!-- <record id="custom_product_template_form_view" model="ir.ui.view"> -->
<!-- <field name="name">custom.product.template.form</field> -->
<!-- <field name="model">product.template</field> -->
<!-- <field name="inherit_id" ref="product.product_template_form_view"/> -->
<!-- <field name="arch" type="xml"> -->
<!-- <xpath expr="//form//header" position="inside"> -->
<!-- <field name="active" invisible="1"/> -->
<!-- <field name="check_status" invisible="1"/> -->
<!-- <button name="archive" type="object" string="归档" icon="fa-archive" class="oe_highlight" attrs="{'invisible': [('active', '=', False)]}"/> -->
<!-- <button name="unarchive" type="object" string="取消归档" icon="fa-archive" class="oe_highlight" attrs="{'invisible': [('active', '=', True)]}"/> -->
<!-- <button name="action_check" string="审核" type="object" class="oe_highlight" attrs="{'invisible': [('check_status', '=', True)]}" groups="sf_base.group_plan_director"/> -->
<!-- <button name="action_uncheck" string="禁用" type="object" class="oe_highlight" attrs="{'invisible': [('check_status', '=', False)]}" groups="sf_base.group_plan_director"/> -->
<!-- </xpath> -->
<!-- </field> -->
<!-- </record> -->
<!-- 增加权限相关的按钮 -->
<record id="custom_mrp_bom_form_view" model="ir.ui.view">
<field name="name">custom.mrp.bom.form</field>
<field name="model">mrp.bom</field>
<field name="inherit_id" ref="mrp.mrp_bom_form_view"/>
<field name="arch" type="xml">
<xpath expr="//form//sheet" position="before">
<header>
<field name="active" invisible="1"/>
<field name="check_status" invisible="1"/>
<!-- <button name="archive" type="object" string="归档" icon="fa-archive" class="oe_highlight" attrs="{'invisible': [('active', '=', False)]}"/> -->
<!-- <button name="unarchive" type="object" string="取消归档" icon="fa-archive" class="oe_highlight" attrs="{'invisible': [('active', '=', True)]}"/> -->
<button name="action_check" string="审核" type="object" class="oe_highlight"
attrs="{'invisible': [('check_status', '=', True)]}"
groups="sf_base.group_plan_director"/>
<!-- <button name="action_uncheck" string="禁用" type="object" class="oe_highlight" attrs="{'invisible': [('check_status', '=', False)]}" groups="sf_base.group_plan_director"/> -->
</header>
</xpath>
</field>
</record>
<!-- 增加权限相关的按钮 -->
<record id="custom_view_production_lot_form" model="ir.ui.view">
<field name="name">custom.view.production.lot.form</field>
<field name="model">stock.lot</field>
<field name="inherit_id" ref="stock.view_production_lot_form"/>
<field name="arch" type="xml">
<xpath expr="//form//sheet" position="before">
<header>
<field name="active" invisible="1"/>
<field name="check_status" invisible="1"/>
<!-- <button name="archive" type="object" string="归档" icon="fa-archive" class="oe_highlight" attrs="{'invisible': [('active', '=', False)]}"/> -->
<!-- <button name="unarchive" type="object" string="取消归档" icon="fa-archive" class="oe_highlight" attrs="{'invisible': [('active', '=', True)]}"/> -->
<button name="action_check" string="审核" type="object" class="oe_highlight"
attrs="{'invisible': [('check_status', '=', True)]}"
groups="sf_base.group_plan_director"/>
<!-- <button name="action_uncheck" string="禁用" type="object" class="oe_highlight" attrs="{'invisible': [('check_status', '=', False)]}" groups="sf_base.group_plan_director"/> -->
</header>
</xpath>
</field>
</record>
<!-- 增加权限相关的按钮 -->
<record id="custom_sf_production_line_form" model="ir.ui.view">
<field name="name">custom.sf.production.line.form</field>
<field name="model">sf.production.line</field>
<field name="inherit_id" ref="sf_manufacturing.sf_production_line_form"/>
<field name="arch" type="xml">
<xpath expr="//form//sheet" position="before">
<header>
<field name="active" invisible="1"/>
<field name="check_status" invisible="1"/>
<!-- <button name="archive" type="object" string="归档" icon="fa-archive" class="oe_highlight" attrs="{'invisible': [('active', '=', False)]}"/> -->
<!-- <button name="unarchive" type="object" string="取消归档" icon="fa-archive" class="oe_highlight" attrs="{'invisible': [('active', '=', True)]}"/> -->
<button name="action_check" string="审核" type="object" class="oe_highlight"
attrs="{'invisible': [('check_status', '=', True)]}"
groups="sf_base.group_plan_director"/>
<!-- <button name="action_uncheck" string="禁用" type="object" class="oe_highlight" attrs="{'invisible': [('check_status', '=', False)]}" groups="sf_base.group_plan_director"/> -->
</header>
</xpath>
</field>
</record>
<!-- 增加权限相关的按钮 -->
<record id="custom_form_sf_model_type" model="ir.ui.view">
<field name="name">custom.form.sf.model.type</field>
<field name="model">sf.model.type</field>
<field name="inherit_id" ref="sf_manufacturing.form_sf_model_type"/>
<field name="arch" type="xml">
<xpath expr="//form//group" position="before">
<header>
<field name="active" invisible="1"/>
<field name="check_status" invisible="1"/>
<!-- <button name="archive" type="object" string="归档" icon="fa-archive" class="oe_highlight" attrs="{'invisible': [('active', '=', False)]}"/> -->
<!-- <button name="unarchive" type="object" string="取消归档" icon="fa-archive" class="oe_highlight" attrs="{'invisible': [('active', '=', True)]}"/> -->
<button name="action_check" string="审核" type="object" class="oe_highlight"
attrs="{'invisible': [('check_status', '=', True)]}"
groups="sf_base.group_plan_director"/>
<!-- <button name="action_uncheck" string="禁用" type="object" class="oe_highlight" attrs="{'invisible': [('check_status', '=', False)]}" groups="sf_base.group_plan_director"/> -->
</header>
</xpath>
</field>
</record>
<!-- 增加权限相关的按钮 -->
<record id="custom_mrp_workcenter_view_form" model="ir.ui.view">
<field name="name">custom.mrp.workcenter.view.form</field>
<field name="model">mrp.workcenter</field>
<field name="inherit_id" ref="mrp.mrp_workcenter_view"/>
<field name="arch" type="xml">
<xpath expr="//form//sheet" position="before">
<header>
<field name="active" invisible="1"/>
<field name="check_status" invisible="1"/>
<!-- <button name="archive" type="object" string="归档" icon="fa-archive" class="oe_highlight" attrs="{'invisible': [('active', '=', False)]}"/> -->
<!-- <button name="unarchive" type="object" string="取消归档" icon="fa-archive" class="oe_highlight" attrs="{'invisible': [('active', '=', True)]}"/> -->
<button name="action_check" string="审核" type="object" class="oe_highlight"
attrs="{'invisible': [('check_status', '=', True)]}"
groups="sf_base.group_plan_director"/>
<!-- <button name="action_uncheck" string="禁用" type="object" class="oe_highlight" attrs="{'invisible': [('check_status', '=', False)]}" groups="sf_base.group_plan_director"/> -->
</header>
</xpath>
</field>
</record>
<!-- 增加权限相关的按钮 -->
<record id="custom_mrp_routing_workcenter_form_view" model="ir.ui.view">
<field name="name">custom.mrp.routing.workcenter.form.view</field>
<field name="model">mrp.routing.workcenter</field>
<field name="inherit_id" ref="mrp.mrp_routing_workcenter_form_view"/>
<field name="arch" type="xml">
<xpath expr="//form//sheet" position="before">
<header>
<field name="active" invisible="1"/>
<field name="check_status" invisible="1"/>
<!-- <button name="archive" type="object" string="归档" icon="fa-archive" class="oe_highlight" attrs="{'invisible': [('active', '=', False)]}"/> -->
<!-- <button name="unarchive" type="object" string="取消归档" icon="fa-archive" class="oe_highlight" attrs="{'invisible': [('active', '=', True)]}"/> -->
<button name="action_check" string="审核" type="object" class="oe_highlight"
attrs="{'invisible': [('check_status', '=', True)]}"
groups="sf_base.group_plan_director"/>
<!-- <button name="action_uncheck" string="禁用" type="object" class="oe_highlight" attrs="{'invisible': [('check_status', '=', False)]}" groups="sf_base.group_plan_director"/> -->
</header>
</xpath>
</field>
</record>
</data>
</odoo>