Do the dirty work

Meaning: To perform an unpleasant or difficult task, often on behalf of someone else.

Example: The senior managers made the junior staff do the dirty work.