jazzband / django-smart-selects

chained and grouped selects for django forms
https://django-smart-selects.readthedocs.io/
BSD 3-Clause "New" or "Revised" License
1.11k stars 348 forks source link

Add change trigger on raw_id_fields for m2m #246

Closed leibowitz closed 6 years ago

leibowitz commented 6 years ago

Looks like the change function is not triggered if the field value is changed when using the raw_id_fields (popup). Adding the trigger by overwriting dismissRelatedLookupPopup is necessary until django admin fixes this.

Similar to how dismissAddAnotherPopup is changed as well.

Open to feedback on how to do this better

coveralls commented 6 years ago

Coverage Status

Coverage remained the same at 89.588% when pulling 7b3cc335c22bc5b22010569c05b6641ed6fdf73f on leibowitz:add_change_trigger into e7fe61b3edc6c81a2da5343a1fad7c7bdacea1cf on digi604:master.

blag commented 6 years ago

Thanks!