This depends on the material your greenhouse is made off. A glass greenhouse cover will block UV light, however the more common polycarbonate covers don’t always block UV. Some growers will choose a material that will allow UV light into the greenhouse, because this way it resembles the natural growing conditions. When you allow UV light to enter your greenhouse, you can benefit from the protected environment as well as the UV light similar to outside growing plants.
When you want to allow UV light during winter but not during summer, you can use shade cloths to block UV light in summer and make sure your plants aren’t harmed by a high amount of UV rays.