Rigs have failsafes, if no hydraulic or air as in a hose breaks, the e brake engages immediately locking up. Kind of scary and dangerous, but we all agree it is much better then a run away truck with no brakes, so lesser of two evils. Now if your brake line is damaged and not working, you have nothing to slow your truck to lessen impact. I'd get those fixed. Honestly I have no idea who we don't have redundant brakes as in two systems for each axle, that is how I would do it if I was building stuff, but ebrakes shouldnt be optional, if you need them and don't have them it could be a bad day for you and possibly someone else.
I bet your buddy just brushed against wheel sensor and popped it off the prongs. I'd try popping them off and putting them back.