Looks like the Smart Lock has problems to keep a stable WIFI connection. Here is an FAQ with steps you can try: Smart Lock WiFi/Thread/MQTT connection troubleshooting / FAQ - #8 by Stefan_Reiterer
There were also some suggested settings for Unifi APs here in the forum. Search should help.
If the Smart Lock connects to the wrong AP, creating a separate network just for the Smart Lock on the AP you want it to connect to, might also be worth a try.
Finally you could also try the latest Smart Lock Beta and test if it makes a difference.