I absolutely disagree with anyone going into a restaurant or grocery store without being reasonably clean. Whether smelly from the barn, from pesticides, from labouring or whatever. I don't want dirty smelly stuff around food that I am paying for. That said, I understand how people that travel from the barn to home don't have the best opportunity to change. If it was me, I would plan all my shopping before I go to the barn, including bringing a cooler for temporary storage if necessary. Sometimes, that's not possible, so in that case, I would expect someone to at least wash their hands and face, comb or tie back their hair and brush off the worst of the mess from boots, pants, etc. That much can be done at a public washroom, certainly not too much to ask.
This is suitable for fast food restaurants and casual bar & grill type restaurants, but not, in my opinion, a formal dining establishment. In that case, go home and get changed first. A quick clean up is suitable for a quick stop at Wal-Mart, but not necessary for the hardware store, building supply or farm supply store.
To me, its about respect for other shoppers/diners according to the environment you are entering.