Welcome back! I'd have paid money to see the reunion.
Wow, those are some changes. Lucky you -- you have a brand new Yorkie to get to meet.

I've tried different things with barking and finally realized that all barking is not bad. I want them to bark when there's a strange noise at night. And I want them to bark when I accidently lock them in the bathroom.

Or they want to go outside and pee.
It's the persistent barking that I try to nip in the bud. I usually check it out when they first start barking. Often, that's all it takes to quiet them down. They had something they wanted to alert me to, and I checked it out and gave them an OK.
Mine started barking at neighbor dogs on both sides, and I don't allow that. I go out at the first hint of a bark and tell them no barking. If they persist, they come in the house. That's worked pretty well. I've noticed lately that the neighbor dogs bark their heads off, and mine just sit there and stare at them.
If they keep barking at the front window, I tell them no and close the drapes. When Eddie barks for an extra meal, I tell him no and ignore him. He learns he doesn't get what he wants by persisting.
When I first started addressing it, I used to shake a can with pennies. It worked. But now that they've learned what no bark means, I don't have to do it anymore.
As for outside peeing, if you don't have a yard, I'd go back to Potty Training 101. Limit her freedom and retrain on a pee pad. She'll get it.
Good luck!