-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[17.0][ADD] stock_picking_state_to_process #162
base: 17.0
Are you sure you want to change the base?
Conversation
@ChristianSantamaria can you review it? |
Changes the state of the picking to 'To process (Stock Pending)' when is 'waiting' and 'To process' when is 'assigned' or 'confirmed'. The button in 'Delivery Orders' shows all 'To Process' pickings.
e2bb15c
to
db49da1
Compare
The second commit is very tailored for the client, I think it is better to move it to a private repository or to slv-reports and add it to reports_scl... how do you see it @dalonsod ? |
state = fields.Selection([ | ||
('draft', 'Draft'), | ||
('waiting', 'Waiting Another Operation'), | ||
('confirmed', 'Waiting'), | ||
('assigned', 'Ready'), | ||
('done', 'Done'), | ||
('cancel', 'Cancelled'), | ||
]) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I see, you've simply rewritten state selection definition (in the exactly same way than Odoo does), and it enables us to get and edit translations, doesn't it?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, that way we can manipulate the labels without compromising the logic
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some improvements
"author": "Solvos", | ||
"category": "stock", | ||
"license": "LGPL-3", | ||
"website": "https://github.com/solvosci/slv-sale", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
|
||
def get_action_picking_tree_very_late(self): | ||
return self._get_action('stock_picking_state_to_process.action_picking_tree_very_late') | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
EOF end line
@@ -0,0 +1,46 @@ | |||
# © 2025 Solvos Consultoría Informática (<http://www.solvos.es>) | |||
# License LGPL-3 - See http://www.gnu.org/licenses/lgpl-3.0.html | |||
import time |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this dependency necessary if we already have timedelta y date?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, it´s used in this domain:
'count_picking_very_late': [('scheduled_date_very_late', '<', time.strftime(DEFAULT_SERVER_DATETIME_FORMAT)), ('state', 'in', ('assigned', 'waiting', 'confirmed'))]
In the line 37
Improvements done |
Add a link to show orders in "assigned" or "confirmed" status in "to process".
Add a days field in stock.picking.type, so that when the delay is greater than that, it appears as "very late".
#HT00414
*Edited to change the description according to the functionalities