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
4e0f7224
Commit
4e0f7224
authored
Nov 22, 2024
by
夏超
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[fix] 修改问题
parent
d817bec7
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
4 deletions
+2
-4
jzjx_project/models/inherit_roke_work_order.py
+2
-4
No files found.
jzjx_project/models/inherit_roke_work_order.py
View file @
4e0f7224
...
...
@@ -104,15 +104,13 @@ class InheritRokeWorkRecordModel(models.Model):
撤回报工
:return:
"""
del_work_order_ids
=
[]
for
v
in
self
:
for
repair
in
v
.
repair_line_ids
:
if
repair
.
repair_work_order_id
.
record_ids
:
raise
ValidationError
(
"返修明细中的返修工单已报工,无法撤销报工!"
)
del_work_order_ids
+=
repair
.
repair_work_order_id
.
ids
repair
.
repair_work_order_id
.
unlink
()
for
scrap
in
v
.
scrap_line_ids
:
if
scrap
.
scrap_work_order_ids
.
record_ids
:
raise
ValidationError
(
"返修明细中的返修工单已报工,无法撤销报工!"
)
del_work_order_ids
+=
scrap
.
scrap_work_order_ids
.
ids
scrap
.
scrap_work_order_ids
.
unlink
()
super
(
InheritRokeWorkRecordModel
,
self
)
.
withdraw
()
self
.
env
[
"roke.work.order"
]
.
search
([(
"id"
,
"in"
,
del_work_order_ids
)])
.
unlink
()
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