On the menu towards the top of the country page (just underneath the ticker ribbon thing), use the "Trade" menu and pick "Order Strategy and Quality".
You then get some very detailed controls that let you set up your country's auto-buying. If you've changed things here before then I suggest you set everything back to :
Low water mark = 3
Order quantity = 14
Request quality = 120
.. before making further changes. Take note of the difference between ordering in months and ordering in units. For instance if your country uses 20k of cheese each month, you either want to be ordering 14 (in months) or 280,000 (in units). It's easier to stick with months because as your country grows, you'll be using more and more cheese every game month and ordering in months means the growth is covered.
The auto-buying system can cause a clash with garrisons if you're not careful