There is no law which prevents dogs having access to any business premises as long as there are measures in place to prevent them from accessing any food storage or preparation areas. Therefore it is basically down to the individual business owner’s personal choice whether to allow dogs in or not.
It’s slightly different for children and young persons though. There used to be such a thing as a Children’s certificate, however since the introduction of the Licensing (Scotland) Act 2005 that’s all changed. Previously for pubs which held a children’s certificate, under 14’s could enter a pub between 11am