move domain to model