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
a60fe1ad
Commit
a60fe1ad
authored
Aug 17, 2023
by
Yvon
1
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
try to show supercafoutch pertes
parent
ae4248ad
Pipeline
#2896
failed with stage
in 1 minute 7 seconds
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
7 additions
and
0 deletions
+7
-0
models.py
stock/models.py
+6
-0
stock_movements_view.html
templates/stock/stock_movements_view.html
+1
-0
No files found.
stock/models.py
View file @
a60fe1ad
...
...
@@ -18,6 +18,9 @@ class CagetteStock(models.Model):
location_dest_id
=
settings
.
MEALS_LOC_ID
elif
movement_type
==
'autoconso'
:
location_dest_id
=
settings
.
AUTOCONSO_LOC_ID
elif
movement_type
==
'caisse-invendus-supercafoutch'
:
location_dest_id
=
settings
.
CUSTOMERS_LOC_ID
picking_type_id
=
settings
.
LOSSES_PICKING_TYPE_ID
else
:
errors
.
append
(
'Type de mouvement incorrect'
)
return
{
'errors'
:
errors
}
...
...
@@ -28,6 +31,9 @@ class CagetteStock(models.Model):
[
'date_done'
,
"<="
,
date_to
],
[
'state'
,
"="
,
'done'
]]
if
movement_type
==
'caisse-invendus-supercafoutch'
:
c
.
append
([
'picking_type_id'
,
"="
,
picking_type_id
])
res
=
o_api
.
search_read
(
'stock.picking'
,
c
,
f
)
return
res
...
...
templates/stock/stock_movements_view.html
View file @
a60fe1ad
...
...
@@ -32,6 +32,7 @@
<option
value=
"losses"
>
Pertes
</option>
<option
value=
"meals"
>
Repas salariés
</option>
<option
value=
"autoconso"
>
Autoconsomation
</option>
<option
value=
"caisse-invendus-supercafoutch"
>
Caisse invendus Supercafoutch
</option>
</select>
<p
class=
"select_movement_element"
>
De :
<input
type=
"text"
id=
"from"
class=
"select_movement_input"
></p>
<p
class=
"select_movement_element"
>
À :
<input
type=
"text"
id=
"to"
class=
"select_movement_input"
></p>
...
...
Yvon Kerdoncuff
@Yvon
mentioned in commit
563e19fa
Aug 22, 2023
mentioned in commit
563e19fa
mentioned in commit 563e19fa93d40eebc54412731eee981ef1b06485
Toggle commit list
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