Did remove an organization from Litium, then tried to create one with the code.
Organization organization = new Organization(template.SystemId, userData.CustomerName)
{
Id = userData.CustomerNumber
};
using (IoC.Resolve<SecurityContextService>().ActAsSystem())
{
_organizationService.Create(organization);
}
And before we create a new, we look and check if it already exist
var organization = _organizationService.Get(userData.CustomerNumber);
and the function retun NULL so it dose not exist but still complane that is dose?!
Litium.Validations.ValidationException
HResult=0x80131500
Message=Validation error for Organization(SystemId: aee7dfde-6b60-4d8a-89a7-bfbe5cd7127a, Id: 21108), Id: ‘Värdet är inte unikt.’.
But if we look at the database the table is empty
Litium version: 7.0.2