- 01
- 02
- 03
- 04
- 05
- 06
- 07
- 08
- 09
- 10
- 11
- 12
- 13
- 14
- 15
- 16
- 17
- 18
- 19
- 20
- 21
- 22
- 23
- 24
- 25
- 26
- 27
- 28
- 29
- 30
- 31
- 32
- 33
- 34
- 35
- 36
private static function recalcReplyRate($contact, $flags)
{
try
{
if (!ANKETA_REPLY_RATE)
throw new Exception_Base('', -1);
if (empty($contact))
throw new Exception_Base('', -2);
if ($flags == 0 &&
$contact->getProperty('msg_count_from') == 0 &&
$contact->getProperty('msg_count_to') == 0)
{
$delta = 1;
$user_id = $contact->getProperty('anketa_id');
}
elseif ($flags == 1 &&
$contact->getProperty('msg_count_from') > 0 &&
$contact->getProperty('msg_count_to') == 0)
{
$delta = -1;
$user_id = $contact->getProperty('contact_anketa_id');
}
else
{
throw new Exception_Base('', -3);
}
Data_Helper::recalcReplyRate($delta, $user_id);
}
catch (Exception_Base $e)
{
return;
}
}
tr00_gr1m_doomster 31.03.2011 17:11 # −1
guest 01.04.2011 07:34 # 0
Lure Of Chaos 31.03.2011 18:15 # 0
)))))))))))))))))))))
> Exception_Base
)))
guest 01.04.2011 10:55 # +1
guest 01.04.2011 10:56 # +1
AlexT 01.04.2011 11:31 # −7
SIGSEGV 01.04.2011 17:37 # +1
bugmenot 01.04.2011 18:52 # +2
striker 02.04.2011 03:05 # +1
guest 01.04.2011 15:23 # 0