What type of work does it need? How many miles does it have?
If it's high mileage already, it would make sense to look for something new, but if it has life left in it, I could see why you'd want to fix it and keep it. Whether you put the work in it now or not really depends on how long you plan to keep it, and if you can justify investing that much in it to get some use out of it. That said, keep your receipts- if it is totaled in an accident after you put money in, you might be able to recoup a good amount of that cost from the insurance company if you can prove the work was done with receipts.
The brake controller can move over to a new vehicle no problem, so there would just be the cost to wire it in to something new.
Sentimental attachment is a hard one to overcome, and I'm more guilty than most on this.
2007 T-286SR Cherry/Granola, #6236, original owner, current mileage: 9467.8 (as of 5/26/19)
1997 T-2653 Blue Denim, #5471
1979 12 1/2' MC, Beige & Avocado, #4639
Past Sunlines: '97 T-2653 #5089, '94 T-2251, '86 T-1550, '94 T-2363, '98 T-270SR