Don't put betta back in the tank for at least six months.
Whatever ate them up can still lurk inside ornaments, plants and other fish.
I ended up losing fourteen girls in rapid succession to an infection much like what you described and have come out of it with some tidbits to keep in mind:
Control the hardness of the water... the higher it is the faster bacteria can reproduce.
Use a scoop or knife to feed food.
Throw out food after a month, even if you still have most of it.
(you can store food carefully using cleansed pill bottles in the fridge, but remember to let them warm up completely to room temp before opening or they'll suck moisture from the air)
Treat new arrivals for a community tank. It came from somewhere!
Keep other fish you're going to have join the sorority in isolation/medical for about a month.
Play with the girls as you select them in the store, make sure they're feeling well in their cups!
The bacteria I fought ended up responding to KanaPlex (kanamycin) after I zeroed the water mineral content so hard that the water started dissolving bacteria in my canister. I ran a UV sterilizer, added back in a controlled pH material and still lost my remaining six girls within a couple months. I put the tank, plants, gravel, equipment and all out in the shed for a year then baked the gravel and gave the tank away to a guy who Herps. The heavy filtration equipment I soaked in pool shock mix for about a week then stored until I used it again.
Betta can get infections in their labyrinth gland, its important to play with each girl every day to see when they start feeling ill.
Sadly its also important to carefully treat the whole tank. I keep MetroPlex, NeoPlex, KanaPlex, SulfaPlex, Furan-2, Tetracycline and Tripple-Sulfa on hand for treatment. Each one of those costs about $10.00 to get.
I recently saw this kind of infection obliterate all the fish in a 65g tropical tank. Keep the antibiotics ON HAND or they're worthless.