Merge pull request #267 from expsa/dev_odex25_purchase_changes

Dev odex25 purchase changes
This commit is contained in:
eslam 2024-07-18 16:28:07 +03:00 committed by GitHub
commit 111d01e3a9
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 10 additions and 10 deletions

View File

@ -9,16 +9,16 @@ class PurchaseRequest(models.Model):
_inherit = 'purchase.request'
warehouse_id = fields.Many2one("stock.warehouse", string= "Warehouse" )
view_location_id = fields.Many2one(related="warehouse_id.view_location_id", string= "Warehouse" )
location_id = fields.Many2one("stock.location", string= "Location",domain="[('id', 'child_of', view_location_id),('usage', '=', 'internal')]" )
picking_id=fields.Many2one("stock.picking")
edit_locations=fields.Boolean(string="Edit Locations",compute='compute_edit_locations')
warehouse_id = fields.Many2one("stock.warehouse", string= "Warehouse" ,copy=False)
view_location_id = fields.Many2one(related="warehouse_id.view_location_id", string= "Warehouse",copy=False )
location_id = fields.Many2one("stock.location", string= "Location",domain="[('id', 'child_of', view_location_id),('usage', '=', 'internal')]",copy=False )
picking_id=fields.Many2one("stock.picking",copy=False)
edit_locations=fields.Boolean(string="Edit Locations",compute='compute_edit_locations',copy=False)
state = fields.Selection(
[('draft', 'Draft'), ('direct_manager', 'Direct Manager'),('warehouse', 'Warehouses Department'),
('waiting', 'In Purchase'),('employee', 'Employee Delivery'),('done', 'Done'), ('cancel', 'Cancel'), ('refuse', 'Refuse')], default="draft",
tracking=True, )
show_emp_button=fields.Boolean(compute='show_employee_button')
tracking=True,copy=False )
show_emp_button=fields.Boolean(compute='show_employee_button',copy=False)
def show_employee_button(self):
"""show only for the create employee"""
@ -199,9 +199,9 @@ class PurchaseRequestLine(models.Model):
_inherit = 'purchase.request.line'
_description = 'purchase request line'
qty_purchased = fields.Integer(string='Purchase Qty')
qty_purchased = fields.Integer(string='Purchase Qty',copy=False)
qty = fields.Integer(string='Demand Qty')
available_qty = fields.Integer(string='Available Qty')
available_qty = fields.Integer(string='Available Qty',copy=False)
@api.constrains('qty')

View File

@ -1471,7 +1471,7 @@ msgstr "مدير المشتريات"
#. module: purchase_requisition_custom
#: model:res.groups,name:purchase_requisition_custom.group_purchase_set_to_draft
msgid "Purchase set to Draft "
msgstr "اعادة الى مسودة"
msgstr " اعادة الى مسودة"
#. module: purchase_requisition_custom
#: model:ir.model.fields,field_description:purchase_requisition_custom.field_purchase_order__purpose