Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
D
dwsproject
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
dws
dwsproject
Commits
c7813fe2
Commit
c7813fe2
authored
Jan 21, 2025
by
夏超
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[fix] 领料单数据
parent
336c14d5
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
0 deletions
+4
-0
sdddl_project/models/inherit_production_task.py
+4
-0
No files found.
sdddl_project/models/inherit_production_task.py
View file @
c7813fe2
...
@@ -141,6 +141,9 @@ class InheritProductionTask(models.Model):
...
@@ -141,6 +141,9 @@ class InheritProductionTask(models.Model):
:return:
:return:
"""
"""
self
.
ensure_one
()
self
.
ensure_one
()
picking_type
=
self
.
_get_default_picking_type
()
if
not
picking_type
:
raise
ValidationError
(
"未找到默认的调拨类型,请创建业务标识为生产领料单的库存作业类型"
)
system_id
=
self
.
env
.
ref
(
"roke_workstation_sync_ps.roke_workstation_sync_ps_integrate_system"
)
system_id
=
self
.
env
.
ref
(
"roke_workstation_sync_ps.roke_workstation_sync_ps_integrate_system"
)
sync_address
=
system_id
.
sync_address
sync_address
=
system_id
.
sync_address
sync_port
=
system_id
.
sync_port
sync_port
=
system_id
.
sync_port
...
@@ -174,6 +177,7 @@ class InheritProductionTask(models.Model):
...
@@ -174,6 +177,7 @@ class InheritProductionTask(models.Model):
for
v
in
rows_data
:
for
v
in
rows_data
:
product
=
self
.
env
[
"roke.product"
]
.
sudo
()
.
search
([(
"code"
,
"="
,
v
.
get
(
"wlbh"
,
""
))],
limit
=
1
)
product
=
self
.
env
[
"roke.product"
]
.
sudo
()
.
search
([(
"code"
,
"="
,
v
.
get
(
"wlbh"
,
""
))],
limit
=
1
)
bom_res
.
append
((
0
,
0
,
{
bom_res
.
append
((
0
,
0
,
{
"picking_type_id"
:
picking_type
.
id
,
"material_id"
:
product
.
id
,
"material_id"
:
product
.
id
,
"demand_qty"
:
self
.
plan_qty
*
v
.
get
(
"compare"
,
1
),
"demand_qty"
:
self
.
plan_qty
*
v
.
get
(
"compare"
,
1
),
"qty"
:
self
.
plan_qty
*
v
.
get
(
"compare"
,
1
)
"qty"
:
self
.
plan_qty
*
v
.
get
(
"compare"
,
1
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment