Bỏ qua để đến Nội dung
Menu
Câu hỏi này đã bị gắn cờ
1 Trả lời
4320 Lượt xem

Hey i have customized stock.picking to force back date entry in stock move and stock move line while product receipt. But when i successfully post an entry in back date it do get posted but shows no effect on stock.valuation.layer. Is there something i am missing in the workflow? Kindly help

This is how i am overriding action_done()

def action_done(self):
for pick in self:
for ops in pick.move_line_ids.filtered(lambda x: not x.move_id):
new_move = self.env['stock.move'].create({
'date': pick.force_date,
})
self.write({'date_done': self.force_date})
res = super(Picking,self).action_done()
return res
Thanks in advance
Ảnh đại diện
Huỷ bỏ
Câu trả lời hay nhất

There are no field date in stock.valuation.layer model, stock.valuation.layer is working with create_date

Ảnh đại diện
Huỷ bỏ
Bài viết liên quan Trả lời Lượt xem Hoạt động
1
thg 4 17
3021
1
thg 8 24
2246
0
thg 1 23
1883
3
thg 11 15
5579
1
thg 12 17
6998