Answer: You may have several problems at work simultaneously. The peas may be giving up because it is just too hot and possibly also a bit dry for their liking. This is a cool season crop (can be planted while there is still frost!) and resents heat. It shows it by dying off when the weather turns hot. The it's time to rip them out and plant something else in their place.
The beans may have some sort of fungal infection, these are very common. To avoid spreading it from plant to plant, stay away from the plants when they are wet with dew or from watering. Remove and destroy any plant debris (burn it or put it ion the trash, not the compost) and avoid wetting the leaves when you water, especially if you water in the evening.
A number of gardeners are reporting the same pumpkin problem this year. I suspect there is either a pollination problem or the plants are stressed (by drought) and aborting as a self protective mechanism. You might try watering them and also make sure they are well mulched.
It sounds like you have done very well for a first time out -- every year the weather is different and the plants never read the books, either -- enjoy your garden and take good field notes so you can refer back to them in future years!
Q&A Library Searching Tips