This sort of thing is not allowed according to the CEC and should also not be tolerated by inspectors either.

A panel enclosure shal not be use as a wireway or raceway. something to that effect is in the CEC.