Hi All,
I face some technical issue and unable to get any reference.
Please give me some advice.
I am intend to get a list of "stock.move" with
"stock.shipment.in" state is "Receive" and "stock.move" state is "Draft".
When I create the query, I lost at where how to compare the origin. below is my query:
@staticmethod
def table_query():
pool = Pool()
Moves = pool.get('stock.move')
move = Moves.__table__()
query = move.select(
move.id.as_('id'),
Literal(0).as_('create_uid'),
Now().as_('create_date'),
Literal(None).as_('write_uid'),
Literal(None).as_('write_date'),
move.product,
move.quantity,
move.from_location,
move.to_location,
move.planned_date,
move.effective_date,
move.lot_no,
move.serial_no,
move.weight,
move.expiry_date,
where = (move.origin = {
stock.shipment.in} and state = 'draft') ----> What is the correct query?
Please help