Just saw this...looks like the reaction arm (fairly substantial aluminium plate with a slot in it) on the brake assembly hasn't been slotted over the boss on the inside face of the swingarm so when you've hit the brakes the drum has spun the internal mechanism pulling the hand brake cable apart and probably hitting the elbow fitting on the brake hose on the swing arm which has sheared the male-male fitting that connects it to the slave cylinder.
The slave cylinders are cheap and easily available, i wouldn't even bother trying to get the remnant of the fitting out of the old one, just fit a new one and make a point of greasing under the two cylinder boots when fitting it. A new cylinder is probably cheaper than a decent Easy-Out for getting the fitting out anyway.
It does look to me like you will need a complete new handbrake cable which means taking the wheel out, getting the brake mechanism out, cleaning everything, greasing the right bits of mechanism, removing the cable from the lever assembly in the transmission tunnel, attaching the new cable at the front, threading it through to the back then getting it through the brake back plate and attached to the brake shoe.. You'll want to take photos of the mechanism as you dismantle it and even then if you're not used to drum brakes then it can be a bit challenging getting everything assembled correctly. I've attached some photos of the mechanism but I don't have a clear step by step guide.
While doing all this, it would be worth fitting the adjustable pivot block for the the ends of the shoes away from the slave cylinder, it makes it easier to get the mechanism in and out of the drum and easier to set up just about right.
three photos of the shoe with the self adjusting mechanism on it.
Three photos of the handbrake cable attached to the lever on the other shoe.
Three pics of the shoe with the cable and lever on the mechanism showing the mechanism that attaches to it.