As a nethserver package, Nextcloud 12.0.3 would be nethserver-nextcloud-1.1.8-1 from October 2017 (we are talking about a release from NethServer 7.4 timeline).
Here are the nethserver packages.
At that time (on nethserver) nextcloud was using PHP 7.1, while version 18.0.3.0 used PHP 7.2. Something to have into account regarding dependencies for installing one version or another. As far as I’ve seen, the NS 7.7.1908 repos contains both php versions, so that should help and be no problem. The same repos also contain nextcloud version going from 16 to 18.
Bear in mind that it’s common to update/upgrade to a higher version but not to downgrade to many past releases (theoretically, nextcloud could have introduced database changes that could have made downgrade troublesome).
NethServer wiki still has some relevant info on upgrade/downgrade examples.
May I ask if v18.0.3.0 has data and what’s the purpose of such downgrade?
Is it the case that you did upgrade NethServer from 7.4 to 7.7 and Nextcloud is not working?
Or you kept Nextcloud from NS7.4 without updating it, upgraded to NS7.7 and now you want to do step by step all the chain of updates from Nextcloud 12 to 18?