A have two models with a Many2one relation. In a form view for model 1, I want an action button that opens a list with the records in model 2, that are related to the current record in model 1. (Just like when you view a customer and has a button to show the customer's orders).
I have found a lot of examples, they all say just about the same: Put a context attribute on the button definition like this:
<button ... context="{'search_default_model1_id': active_id, 'default_model1_id': active_id}">
But it doesn't work. I still get ALL the records from model 2 in the list...
I guess this should be quite basic standard behaviour, so what have I missed?