Transmit shipment ids from "transition_step_A_to_B" to "do_C" in wizard

Hi,
I update some shipments in a transition (from step A to step B) and when closing step B, I want to use ids in “do_C” for an action (in action[‘res_id’]
I’ve tried

  • Transaction().set_context(shipment_ids = action_ids)
  • self.records = records
    but I can’t recover action_ids or records in “do_C”

This is context manager so context is restored on exit.

records is a property it can not be modified.

Why not preform all the action in do_C?

Because in step B, I give an abstract of actions (done in “transition_step_A_to_B”)

With no “standard” solution for this need, I’ve done a “out of the box” solution.
For those who are interested:

  1. in model view of step B, I’ve added a “shipment_ids = fields.Text(‘Shipment ids’, readonly=True)”
  2. in “transition_step_A_to_B” I’ve added “self.result.shipment_ids = str(action_ids)” (action_ids is a list)
  3. in “do_C” I’ve added “action[‘res_id’] = eval(self.result.shipment_ids)”
    This is ugly, but it works