emailadresses to pacdomain are not allowed

This commit is contained in:
Peter Hormanns 2012-01-04 16:14:37 +00:00
parent bcad5ea7c4
commit 145a79710c

View File

@ -133,9 +133,9 @@ public class DomainModuleImpl extends AbstractModuleImpl {
needsWriteAccessOn(newEntity, "add");
em.persist(dom);
if (dom.isPacDomain()) {
em.persist(new EMailAddress("owner", "", dom, dom.getUser().getPac().getCustomer().getContractualContact().getEmail()));
em.persist(new EMailAddress("admin", "", dom, admin.getName()));
em.persist(new EMailAddress(dom.getUser().getPac().getName(), "", dom, admin.getName()));
em.persist(new EMailAddress("owner", "", dom, dom.getUser().getPac().getCustomer().getName().substring(6) + "@hostsharing.net"));
em.persist(new EMailAddress("admin", "", dom, dom.getUser().getPac().getName() + "@hostsharing.net"));
em.persist(new EMailAddress(dom.getUser().getPac().getName(), "", dom, dom.getUser().getPac().getName() + "@hostsharing.net"));
} else {
em.persist(new EMailAddress("abuse", "", dom, admin.getName()));
em.persist(new EMailAddress("postmaster", "", dom, admin.getName()));