58 'data_type' =>
'integer',
60 'autocomplete' =>
true,
62 'CAMPAIGN_ID' => array(
63 'data_type' =>
'integer',
65 'column_name' =>
'MAILING_ID',
68 'data_type' =>
'integer',
70 'column_name' =>
'MAILING_CHAIN_ID',
72 'DATE_CREATE' => array(
73 'data_type' =>
'datetime',
77 'DATE_UPDATE' => array(
78 'data_type' =>
'datetime',
83 'data_type' =>
'string',
85 'default_value' => self::STATUS_NEW,
88 'data_type' =>
'datetime',
90 'DATE_PAUSE' => array(
91 'data_type' =>
'datetime',
94 'data_type' =>
'datetime',
96 'COUNT_READ' => array(
97 'data_type' =>
'integer',
100 'COUNT_CLICK' => array(
101 'data_type' =>
'integer',
104 'COUNT_UNSUB' => array(
105 'data_type' =>
'integer',
108 'COUNT_SEND_ALL' => array(
109 'data_type' =>
'integer',
112 'COUNT_SEND_NONE' => array(
113 'data_type' =>
'integer',
116 'COUNT_SEND_ERROR' => array(
117 'data_type' =>
'integer',
120 'COUNT_SEND_SUCCESS' => array(
121 'data_type' =>
'integer',
124 'COUNT_SEND_DENY' => array(
125 'data_type' =>
'integer',
129 'data_type' => LetterTable::class,
130 'reference' => array(
'=this.LETTER_ID' =>
'ref.ID'),
133 'data_type' => Sender\MailingTable::class,
134 'reference' => array(
'=this.CAMPAIGN_ID' =>
'ref.ID'),
136 'MAILING_CHAIN' => array(
137 'data_type' => Sender\MailingChainTable::class,
138 'reference' => array(
'=this.LETTER_ID' =>
'ref.ID'),
140 'POSTING_RECIPIENT' => array(
141 'data_type' => Posting\RecipientTable::class,
142 'reference' => array(
'=this.ID' =>
'ref.POSTING_ID'),
144 'POSTING_READ' => array(
145 'data_type' => Posting\ReadTable::class,
146 'reference' => array(
'=this.ID' =>
'ref.POSTING_ID'),
148 'POSTING_CLICK' => array(
149 'data_type' => Posting\ClickTable::class,
150 'reference' => array(
'=this.ID' =>
'ref.POSTING_ID'),
152 'POSTING_UNSUB' => array(
153 'data_type' => Posting\UnsubTable::class,
154 'reference' => array(
'=this.ID' =>
'ref.POSTING_ID'),
168 $result =
new Main\Entity\EventResult;
169 $data = $event->getParameters();
173 if(array_key_exists(
'ID', $data[
'primary']))
175 $listId[] = $data[
'primary'][
'ID'];
180 foreach($data[
'primary'] as $primKey => $primVal)
182 $filter[$primKey] = $primVal;
185 $tableDataList = static::getList(array(
186 'select' => array(
'ID'),
189 while($tableData = $tableDataList->fetch())
191 $listId[] = $tableData[
'ID'];
196 foreach($listId as $primaryId)
198 $primary = array(
'POSTING_ID' => $primaryId);
199 Sender\PostingReadTable::deleteList($primary);
200 Sender\PostingClickTable::deleteList($primary);
201 Sender\PostingUnsubTable::deleteList($primary);
202 Sender\PostingRecipientTable::deleteList($primary);