Lucas:
It may appear to be the previous cost because at the time the invoice was created what is now the previous cost was then the current cost.
If you sell something before receiving it then it is possible for the item sold to have a zero cost. This can be avaoided by making sure that all new items have a Recent Cost assigned.
Without seeing the data it is really difficult to advise you on what is wrong and how to fix it. This would be a good opportunity for your Adagio dealer to assist you.