/**
  * Create a new newsletter type
  */
 private function newNewsletterType()
 {
     // create the new type
     $newsletterType = new NewsletterType();
     $newsletterType->Title = _t('NewsletterAdmin.NEWNEWSLTYPE', 'New newsletter type');
     $newsletterType->write();
     // BUGFIX: Return only the ID of the new newsletter type
     return $newsletterType->ID;
 }
Exemplo n.º 2
0
 /**
  * Create a new newsletter type
  */
 private function newNewsletterType()
 {
     // create a new group for the newsletter
     $newGroup = new Group();
     $newGroup->Title = _t('NewsletterAdmin.NEWLIST', 'New mailing list');
     $newGroup->Code = "new-mailing-list";
     $newGroup->write();
     // create the new type
     $newsletterType = new NewsletterType();
     $newsletterType->Title = _t('NewsletterAdmin.NEWNEWSLTYPE', 'New newsletter type');
     $newsletterType->GroupID = $newGroup->ID;
     $newsletterType->write();
     // BUGFIX: Return only the ID of the new newsletter type
     return $newsletterType->ID;
 }