The "accept" button you're referring to grants the computer the right to access your iPhone via USB for the current session - which means until you pull the cable. For this, it does not matter if you actually view any photos or not. It does not give your employer or anyone else the ability to remotely access the data on your iPhone.
While in theory there might have been a yet-unknown silent program running in the background, waiting for an iPhone to be connected and then pulling data from it and uploading it to a remote server, I'd wager the probability of this to be near zero. This would take effort and intent to implement, put your employer in legal danger and they wouldn't gain anything from it. Depending on how fast you disconnected your phone, there might have not even been enough time to download files from it.
Some employers use monitoring software that'll let them look at their employees computer screens, depending on your jurisdiction this must be communicated or can be done without warning. If there is such a monitoring/recording software running and you were to connect your iPhone, open your photos on the laptop and start browsing through them, a third party could have access.
If you are anxious about attackers accessing your devices via USB, you could buy a pre-made "USB Condom" or build one yourself. This just involves severing or blocking the part of the USB cable that is responsible for data transfer and leaving the power lines intact.