Are you returning through the portal on the map? Or via the exit button?
You need to leave the location by going through the portal arch on the map — that way your rewards will be saved. When you exit via the button, there's a warning that you'll lose all your resources.