changes
This commit is contained in:
@@ -5,7 +5,7 @@
|
||||
|
||||
{
|
||||
'name': 'Fusion Plating — Logistics',
|
||||
'version': '19.0.3.0.0',
|
||||
'version': '19.0.3.1.0',
|
||||
'category': 'Manufacturing/Plating',
|
||||
'summary': (
|
||||
'Pickup & delivery for plating shops: vehicle master, driver '
|
||||
|
||||
@@ -251,17 +251,16 @@ class FpDelivery(models.Model):
|
||||
self.ensure_one()
|
||||
if not self.x_fc_box_count_out:
|
||||
return
|
||||
Receiving = self.env.get('fp.receiving')
|
||||
if Receiving is None:
|
||||
if 'fp.receiving' not in self.env:
|
||||
return
|
||||
# Resolve SO via job_ref → MO.origin → SO.name
|
||||
# Sub 11 — resolve SO via job_ref → fp.job.origin → SO.name.
|
||||
so_name = False
|
||||
if self.job_ref:
|
||||
mo = self.env['mrp.production'].search(
|
||||
if self.job_ref and 'fp.job' in self.env:
|
||||
job = self.env['fp.job'].sudo().search(
|
||||
[('name', '=', self.job_ref)], limit=1,
|
||||
)
|
||||
if mo and mo.origin:
|
||||
so_name = mo.origin
|
||||
if job and job.origin:
|
||||
so_name = job.origin
|
||||
if not so_name:
|
||||
return
|
||||
so = self.env['sale.order'].search(
|
||||
|
||||
Reference in New Issue
Block a user