In my experience, it's always best to paint first before you assemble. For me, I take it all the way through the painting stage before I start assembling (minus touch up, applying clear coats, etc). Depending on the piece, you can assemble it and paint it afterwards but I find that to be prone to errors so I just paint, paint, add panel lines and major details, then assemble.