I am not sure about the issue, but my advice would be to try and refactor this to use get_posts()
and template tags that can work without $post
global variable. Basically do not touch globals at all.
Loops in front-end are almost civilized nowadays, but internals of admin are still very wild. 🙂