If kept in a water tight container up to a year.
germination pinto bean plant
I have never seen pinto beans spoil in less than a period of about two hours however in my years of cooking you would have to leave them out of the refrigerator for several hours before they would began to spoil. Beans are a staple food in the South and they would have to stay out all night in some cases before spoilage would sat in however If I intended on selling the beans to the public I would follow the 2 HOUR RULE and just cook a fresh pot.
Cooked beans should be used within 2-3 days.
A
Soaking them too long, probably.
Cooked pinto beans are considered potentially hazardous. They should not be left unrefrigerated for more than 2 hours.
After quick internet search I found cooked beans will last up to a week, refrigerated.
vegtables
uncooked hams that have been frozen last 6 months or longer.
Baked beans can last in a fridge for about five days. Baked beans can last in a freezer for about a year.
Soaking pinto beans before you cook them speeds up cookign time and allows some of the gas to escape. When soaking beans the water should be change the water several time, or when it begins to turn dark.