picking_ids = self.env['stock.picking'].search(
[('sale_id.sample_id', '=', line.id)])
# for loop condition to check each line by line of the product lines
for pick in picking_ids.move_ids_without_package:
# check Condition if sample Qty returned less than means status will be partial returned
if pick.state != 'done':
print("half delivered")
picking_ids.write({'state': 'partially_delivered'})
else:
print("delivered")
# print(sample_qty, return_qty)
# active_id.write({'return_date': self.return_date, 'return_by': self.responsible_person,
# 'state': 'return'})
신고된 질문입니다
4190
화면
| 관련 게시물 | 답글 | 화면 | 활동 | |
|---|---|---|---|---|
|
|
1
6월 23
|
4725 | ||
|
|
1
6월 23
|
6503 | ||
|
|
1
1월 23
|
4753 | ||
|
|
0
9월 22
|
4529 | ||
|
|
1
8월 22
|
5111 |