[FIX] mrp: perform location chaining for kit exploded moves
This rev. 73072272 ensured to not (re-)set the state 'confirmed' to exploded moves with a more advanced state (for instance, 'assigned') Nevertheless, the location chaining is performed on the move confirmation, through the action_confirm method of the stock.move model. Besides, the resulting moves of the _action_explode method had the state 'confirmed' on creation, the 'confirmed' state wasn't set by the method 'action_confirm', meaning that the moves were confirmed without having the location chaining done. Allowing moves to go through the action_confirm method even if the state was 'confirmed' or further triggered the location chaining. Preventing already confirmed moves to go through the action_confirm method prevented the location chaining, thus. We now create the resulting moves with the 'draft' state, and then confirm them through the procurement workflow signal 'button_confirm'. Thus, the resulting moves are confirmed by going through the action_confirm method, writing the confirmed state and triggering the location chaining at the same time. We then write the 'assigned' state if necessary. opw-617235
Please register or sign in to comment