--- class.mailselect.php 2013-05-28 16:56:04.557351026 +0200 +++ class.mailselect.new.php 2013-05-28 16:56:28.100921916 +0200 @@ -47,6 +47,16 @@ var $allowedTables = array('tt_address','fe_users'); + /** Override instance variables for use with address groups + */ + public function init($name, $table, $fieldList = '') { + // add a special relation comparison for us + $this->lang['comparison']['74_'] = 'Address Group'; + $this->compSQL['74'] = 'uid IN (SELECT f.uid FROM tt_address f LEFT JOIN tt_address_group_mm tgm ON f.uid = tgm.uid_local WHERE tgm.uid_foreign = #VALUE#)'; + + parent::init($name, $table, $fieldList); + } + /** * build a dropdown box. override function from parent class. Limit only to 2 tables. *