Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
T
third-party
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
2
Merge Requests
2
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
cooperatic-foodcoops
third-party
Commits
76f40537
Commit
76f40537
authored
Jul 29, 2021
by
Damien Moulard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
remove useless code in reception update_orders
parent
011a4cc7
Pipeline
#1263
passed with stage
in 1 minute 22 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
0 additions
and
20 deletions
+0
-20
views.py
reception/views.py
+0
-20
No files found.
reception/views.py
View file @
76f40537
...
@@ -221,26 +221,6 @@ def update_orders(request):
...
@@ -221,26 +221,6 @@ def update_orders(request):
m
.
update_order_status
(
order_id
,
data
[
'update_type'
])
m
.
update_order_status
(
order_id
,
data
[
'update_type'
])
if
data
[
'update_type'
]
==
'br_valid'
:
if
data
[
'update_type'
]
==
'br_valid'
:
answer_data
[
order_id
][
'finalyze_result'
]
=
m
.
register_purchase_order_to_finalyze
()
answer_data
[
order_id
][
'finalyze_result'
]
=
m
.
register_purchase_order_to_finalyze
()
# Remove order's group
try
:
# TODO remove from couchdb orders & group (here?)
if
os
.
path
.
exists
(
'temp/grouped_order.json'
):
with
open
(
'temp/grouped_order.json'
,
'r'
)
as
json_file
:
saved_groups
=
json
.
load
(
json_file
)
for
oi
in
order_ids
:
for
i
,
group
in
enumerate
(
saved_groups
):
if
oi
in
group
:
saved_groups
.
pop
(
i
)
break
with
open
(
'temp/grouped_order.json'
,
'w'
)
as
json_file
:
json
.
dump
(
saved_groups
,
json_file
)
except
Exception
as
e
:
# no saved groups
print
(
str
(
e
))
# TODO else if first step, save first step data (here?)
else
:
else
:
coop_logger
.
error
(
"update_orders errors :
%
s"
,
str
(
errors
))
coop_logger
.
error
(
"update_orders errors :
%
s"
,
str
(
errors
))
rep
=
JsonResponse
(
answer_data
,
safe
=
False
)
rep
=
JsonResponse
(
answer_data
,
safe
=
False
)
...
...
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