Merge branch 'develop' of https://e.coding.net/jikimo-hn/jikimo_sfs/jikimo_sf into feature/新增工件装夹预调工单任务

# Conflicts:
#	sf_manufacturing/views/mrp_production_addional_change.xml
This commit is contained in:
jinling.yang
2024-01-24 14:39:47 +08:00
7 changed files with 147 additions and 11 deletions

View File

@@ -85,7 +85,7 @@
<xpath expr="(//header//button[@name='button_mark_done'])[2]" position="replace">
<button name="button_mark_done"
attrs="{'invisible': ['|', '|', ('state', 'in', ('draft', 'cancel', 'done', 'to_close')), ('qty_producing', '=', 0), ('move_raw_ids', '=', [])]}"
string="Validate" type="object" class="oe_highlight" data-hotkey="g"
string="验证" type="object" class="oe_highlight" data-hotkey="g"
groups="sf_base.group_sf_mrp_user"/>
</xpath>
<xpath expr="(//header//button[@name='button_mark_done'])[3]" position="replace">
@@ -96,7 +96,7 @@
'|',
('state', 'not in', ('confirmed', 'progress')),
('qty_producing', '!=', 0),
('state', '!=', 'to_close')]}" string="Mark as Done" type="object" class="oe_highlight"
('state', '!=', 'to_close')]}" string="标记完成" type="object" class="oe_highlight"
data-hotkey="g" groups="sf_base.group_sf_mrp_user"/>
</xpath>
<xpath expr="(//header//button[@name='button_mark_done'])[4]" position="replace">
@@ -107,7 +107,7 @@
'|',
('state', 'not in', ('confirmed', 'progress')),
('qty_producing', '!=', 0),
('state', '!=', 'to_close')]}" string="Mark as Done" type="object" class="oe_highlight"
('state', '!=', 'to_close')]}" string="标记完成" type="object" class="oe_highlight"
data-hotkey="g"
confirm="There are no components to consume. Are you still sure you want to continue?"
groups="sf_base.group_sf_mrp_user"/>
@@ -125,7 +125,7 @@
<xpath expr="//header//button[@name='action_confirm']" position="replace">
<button name="action_confirm" attrs="{'invisible': [('state', '!=', 'draft')]}" string="Confirm"
<button name="action_confirm" attrs="{'invisible': [('state', '!=', 'draft')]}" string="确认"
type="object" class="oe_highlight" data-hotkey="v" groups="sf_base.group_sf_mrp_user"/>
</xpath>
@@ -179,12 +179,59 @@
</xpath>
<xpath expr="//header//button[@name='button_unbuild']" position="replace">
<button name="button_unbuild" type="object" string="Unbuild"
<button name="button_unbuild" type="object" string="拆单"
attrs="{'invisible': [('state', '!=', 'done')]}" data-hotkey="shift+v"
groups="sf_base.group_sf_mrp_user"/>
</xpath>
<xpath expr="//header//button[@name='button_plan']" position="replace">
<!-- <button name="button_plan" attrs="{'invisible': ['|', '|', ('state', 'not in', ('confirmed', 'progress', 'to_close')), ('workorder_ids', '=', []), ('is_planned', '=', True)]}" type="object" string="Plan" class="oe_highlight" data-hotkey="x" groups="sf_base.group_sf_mrp_user"/> -->
</xpath>
<xpath expr="//header//button[@name='action_assign']" position="replace">
<button name="action_assign"
attrs="{'invisible': ['|', ('state', 'in', ('draft', 'done', 'cancel')), ('reserve_visible', '=', False)]}"
string="检查可用量" type="object" data-hotkey="q" groups="sf_base.group_sf_mrp_user"/>
</xpath>
<xpath expr="//header//button[@name='do_unreserve']" position="replace">
<button name="do_unreserve" type="object" string="取消保留"
attrs="{'invisible': [('unreserve_visible', '=', False)]}" data-hotkey="w"
groups="sf_base.group_sf_mrp_user"/>
</xpath>
<xpath expr="//header//button[@name='action_toggle_is_locked']" position="replace">
<button name="action_toggle_is_locked"
attrs="{'invisible': ['|', ('show_lock', '=', False), ('is_locked', '=', False)]}"
string="取消阻塞" groups="sf_base.group_sf_mrp_user" type="object"
help="Unlock the manufacturing order to adjust what has been consumed or produced."
data-hotkey="l"/>
</xpath>
<xpath expr="//header//button[@name='action_toggle_is_locked']" position="replace">
<button name="action_toggle_is_locked"
attrs="{'invisible': ['|', ('show_lock', '=', False), ('is_locked', '=', True)]}"
string="阻塞" groups="sf_base.group_sf_mrp_user" type="object"
help="Lock the manufacturing order to prevent changes to what has been consumed or produced."
data-hotkey="l"/>
</xpath>
<xpath expr="//header//button[@name='action_serial_mass_produce_wizard']" position="replace">
<button name="action_serial_mass_produce_wizard"
attrs="{'invisible': [('show_serial_mass_produce', '=', False)]}" string="批量生产"
type="object" groups="sf_base.group_sf_mrp_user"/>
</xpath>
<xpath expr="//header//button[@name='action_cancel']" position="replace">
<button name="action_cancel" type="object" string="取消" data-hotkey="z"
attrs="{'invisible': ['|', '|', ('id', '=', False), ('state', 'in', ('done', 'cancel')), ('confirm_cancel', '=', False)]}"
confirm="Some product moves have already been confirmed, this manufacturing order can't be completely cancelled. Are you still sure you want to process ?"
groups="sf_base.group_sf_mrp_user"/>
</xpath>
<xpath expr="//header//button[@name='button_unbuild']" position="replace">
<button name="button_unbuild" type="object" string="拆单"
attrs="{'invisible': [('state', '!=', 'done')]}" data-hotkey="shift+v"
groups="sf_base.group_sf_mrp_user"/>
</xpath>
</field>
</record>
@@ -195,7 +242,7 @@
<field name="inherit_id" ref="mrp.mrp_production_workorder_tree_editable_view"/>
<field name="arch" type="xml">
<xpath expr="//tree//button[@name='button_start']" position="replace">
<button name="button_start" type="object" string="Start" class="btn-success"
<button name="button_start" type="object" string="开始" class="btn-success"
attrs="{'invisible': ['|', '|', '|', ('production_state','in', ('draft', 'done', 'cancel')), ('working_state', '=', 'blocked'), ('state', 'in', ('done', 'cancel')), ('is_user_working', '!=', False)]}"
groups="sf_base.group_sf_mrp_user"/>
</xpath>
@@ -225,8 +272,38 @@
<button name="action_open_wizard" type="object" icon="fa-external-link" class="oe_edit_only"
title="Open Work Order"
context="{'default_workcenter_id': workcenter_id}" groups="sf_base.group_sf_mrp_user"/>
=======
<button name="button_start" type="object" string="开始" class="btn-success"
attrs="{'invisible': ['|', '|', '|', ('production_state','in', ('draft', 'done', 'cancel')), ('working_state', '=', 'blocked'), ('state', 'in', ('done', 'cancel')), ('is_user_working', '!=', False)]}"
groups="sf_base.group_sf_mrp_user"/>
</xpath>
<xpath expr="//tree//button[@name='button_pending']" position="replace">
<button name="button_pending" type="object" string="暂停" class="btn-warning"
attrs="{'invisible': ['|', '|', ('production_state', 'in', ('draft', 'done', 'cancel')), ('working_state', '=', 'blocked'), ('is_user_working', '=', False)]}"
groups="sf_base.group_sf_mrp_user"/>
</xpath>
<xpath expr="//tree//button[@name='button_finish']" position="replace">
<button name="button_finish" type="object" string="完成" class="btn-success"
attrs="{'invisible': ['|', '|', ('production_state', 'in', ('draft', 'done', 'cancel')), ('working_state', '=', 'blocked'), ('is_user_working', '=', False)]}"
groups="sf_base.group_sf_mrp_user"/>
</xpath>
<xpath expr="//tree//button[@name='%(mrp.act_mrp_block_workcenter_wo)d']" position="replace">
<button name="%(mrp.act_mrp_block_workcenter_wo)d" type="action" string="阻塞"
context="{'default_workcenter_id': workcenter_id}" class="btn-danger"
attrs="{'invisible': ['|', ('production_state', 'in', ('draft', 'done', 'cancel')), ('working_state', '=', 'blocked')]}"
groups="sf_base.group_sf_mrp_user"/>
</xpath>
<xpath expr="//tree//button[@name='button_unblock']" position="replace">
<button name="button_unblock" type="object" string="取消阻塞"
context="{'default_workcenter_id': workcenter_id}" class="btn-danger"
attrs="{'invisible': ['|', ('production_state', 'in', ('draft', 'done', 'cancel')), ('working_state', '!=', 'blocked')]}"
groups="sf_base.group_sf_mrp_user"/>
</xpath>
<xpath expr="//tree//button[@name='action_open_wizard']" position="replace">
<button name="action_open_wizard" type="object" icon="fa-external-link" class="oe_edit_only"
title="未完成工单"
context="{'default_workcenter_id': workcenter_id}" groups="sf_base.group_sf_mrp_user"/>
</xpath>
</field>
</record>