OVT-8518: Fixed versioning to use created codesversion when inserting codeelements. getLatestKoodistoVersio() won't fetch version created in same transaction.