优化货位颜色及启用货位
This commit is contained in:
@@ -291,6 +291,10 @@ class ShelfLocation(models.Model):
|
|||||||
def action_location_status_disable(self):
|
def action_location_status_disable(self):
|
||||||
self.location_status = '禁用'
|
self.location_status = '禁用'
|
||||||
|
|
||||||
|
# 修改货位状态为空闲
|
||||||
|
def action_location_status_enable(self):
|
||||||
|
self.location_status = '空闲'
|
||||||
|
|
||||||
@api.onchange('shelf_location_id')
|
@api.onchange('shelf_location_id')
|
||||||
def _onchange_shelf_location_id(self):
|
def _onchange_shelf_location_id(self):
|
||||||
"""
|
"""
|
||||||
|
|||||||
@@ -52,7 +52,7 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
.green {
|
.green {
|
||||||
background-color: #27FEA9 !important;
|
background-color: #fff !important;
|
||||||
border: 1px solid #ccc;
|
border: 1px solid #ccc;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -60,6 +60,8 @@
|
|||||||
attrs="{'invisible': [('hide_shelf', '=', False)]}"/>
|
attrs="{'invisible': [('hide_shelf', '=', False)]}"/>
|
||||||
<button string="禁用货位" name="action_location_status_disable" type="object" class="oe_highlight"
|
<button string="禁用货位" name="action_location_status_disable" type="object" class="oe_highlight"
|
||||||
attrs="{'invisible': ['|', ('hide_shelf', '=', True), ('location_status', '!=', '空闲')]}"/>
|
attrs="{'invisible': ['|', ('hide_shelf', '=', True), ('location_status', '!=', '空闲')]}"/>
|
||||||
|
<button string="启用货位" name="action_location_status_enable" type="object" class="oe_highlight"
|
||||||
|
attrs="{'invisible': ['|', ('hide_shelf', '=', True), ('location_status', '!=', '禁用')]}"/>
|
||||||
|
|
||||||
<!-- <button name="%(shelf_location_kanban_action_id)d"-->
|
<!-- <button name="%(shelf_location_kanban_action_id)d"-->
|
||||||
<!-- type="action"-->
|
<!-- type="action"-->
|
||||||
|
|||||||
Reference in New Issue
Block a user