Those kind of laws are very difficult to enforce, however in countries were similar laws are in place if for example you want to stay at a hotel with a person of the opposite sex you will need to stay in different rooms, so this could raise the costs for couples which are not married or for friends, which could indeed reduce tourism, however it would be interesting to see what has been the effect in other countries which have passed similar laws before.
Actually this is not too difficult to uphold in my opinion, especially when talking about Indonesia where most of the population has the same belief and of course the majority of Indonesian citizens have a religion which clearly prohibits this. I don't think this is difficult.
As for the actual impact, it doesn't really affect me in my opinion because it depends on the intentions of the tourists whether they are only visiting for sex or indeed for other business purposes because when they say business and sex are two different things. We live where we have rules and when we are in this case we cannot rule out rules that are prohibited either by law or religion unless you really don't have both in you.
The law could be created to suppress sexual tourism, but it's not the case. They are criminalizing every sexual activity outside marriage, what is a clear violation of individual rights.
Let's say a couple visits your country, but they aren't married. So can't they have sex while there? Will they be punished accordingly to your local laws?
And let's say a foreigner visits your country, fall in love for a local woman (no prostitution) and they want to have sex. Should this person go to jail for commiting the crime of loving someone?
That is insane! I wouldn't go to a territory with such tyranical laws. It must affect tourism, indeed.