I think there has been a similar topic before - or at least this is not the first time I deal with this issue. This is why I remember that confuse can happen.
Try the following steps to get what I mean:
-Open Plantations Overview.
Then, by using the Currently Improved column link (which will open infrastructure):
-Open a new tab at Plantation of Port A.
-Open a new tab at Plantation of Port B.
So, you should have 3 tabs open: Plantations Overview, Plantation Port A and Plantation Port B.
Assuming that you followed the steps correctly, the last plantation you opened is Port B. So you "character" is now at Port B. You can verify this by clicking Headquarters at first tab.
Now you verified that you are at Port B, go to the tab that still has Plantation A open. Put 50 gold bars to improve. Notice the result: You have selected port A but you actually improved Port B. Now, several chances will take place depending your actual status to other port (ie no gold bars) but you get the idea of what has probably happened.
This is what I had in mind when I said we need to improve interface there. The issues that can be created if you use multiple tabs (something I do all the time - but I also know the implications
). Actually, the only implication is to keep in mind that you switched port. The game even produces a warning for this but we are all blind to it already.
Anyway, I have the way to generate new warning across tabs when you change a port. Still, it won't work flawlessly 100% and perhaps many won't like it.