Pass controller to modal window

Hi, I am using a modal to create/edit items and it has a lot of logic that I want to reuse. Right now I have all the logic in the addItemCtrl and I want to use that same logic in my editItemCtrl, but without duplicating all the code. Can I pass a controller to the model? If so, I can put all my login in like modalCtrl and pass that.

Similar question: Passing the controller to a modal

Thanks!