Revize 1941
Přidáno uživatelem Ondřej Fibich před více než 11 roky(ů)
freenetis/branches/1.1/application/models/member.php | ||
---|---|---|
break;
|
||
|
||
case Message_Model::DEBTOR_MESSAGE:
|
||
$where = "WHERE m.type <> " . intval(Member_Model::TYPE_APPLICANT)
|
||
$where = "WHERE mf.id IS NULL "
|
||
. " AND m.type <> " . intval(Member_Model::TYPE_APPLICANT)
|
||
. " AND a.balance < ".intval(Settings::get('debtor_boundary'))
|
||
." AND DATEDIFF(CURDATE(), m.entrance_date) >= ".intval(Settings::get('initial_debtor_immunity'));
|
||
$order_by = "whitelisted ASC, balance ASC";
|
||
break;
|
||
|
||
case Message_Model::PAYMENT_NOTICE_MESSAGE:
|
||
$where = "WHERE m.type <> " . intval(Member_Model::TYPE_APPLICANT)
|
||
$where = "WHERE mf.id IS NULL "
|
||
. " AND m.type <> " . intval(Member_Model::TYPE_APPLICANT)
|
||
. " AND a.balance < ".intval(Settings::get('payment_notice_boundary'))."
|
||
AND
|
||
(
|
||
DATEDIFF(CURDATE(), m.entrance_date) >= ".intval(Settings::get('initial_debtor_immunity'))."
|
||
AND a.balance >= ".intval(Settings::get('debtor_boundary'))."
|
||
OR DATEDIFF(CURDATE(), m.entrance_date) < ".intval(Settings::get('initial_debtor_immunity'))."
|
||
AND DATEDIFF(CURDATE(), m.entrance_date) >= ".intval(Settings::get('initial_immunity'))."
|
||
)";
|
||
AND
|
||
(
|
||
DATEDIFF(CURDATE(), m.entrance_date) >= ".intval(Settings::get('initial_debtor_immunity'))."
|
||
AND a.balance >= ".intval(Settings::get('debtor_boundary'))."
|
||
OR DATEDIFF(CURDATE(), m.entrance_date) < ".intval(Settings::get('initial_debtor_immunity'))."
|
||
AND DATEDIFF(CURDATE(), m.entrance_date) >= ".intval(Settings::get('initial_immunity'))."
|
||
)";
|
||
$order_by = "whitelisted ASC, balance ASC";
|
||
break;
|
||
|
||
... | ... | |
Message_Model::INTERRUPTED_MEMBERSHIP_MESSAGE
|
||
);
|
||
|
||
$connection_test_expired_id = $message_model
|
||
->get_message_id_by_type(
|
||
Message_Model::CONNECTION_TEST_EXPIRED
|
||
);
|
||
|
||
// deletes all redirections of member
|
||
foreach ($ip_addresses as $ip_address)
|
||
{
|
||
// deletes all system redirections of member
|
||
$messages_ip_addresses_model
|
||
->delete_all_system_redirections_of_ip_address ($ip_address->id);
|
||
->delete_all_system_redirections_of_ip_address($ip_address->id);
|
||
|
||
// only delete all if whitelisted
|
||
// only delete all if whitelisted or member is applicant
|
||
if ($is_whitelisted)
|
||
continue;
|
||
|
||
// applicant test connection
|
||
if ($member->type == Member_Model::TYPE_APPLICANT)
|
||
{
|
||
$actd = Settings::get('applicant_connection_test_duration');
|
||
$acf = $member->applicant_connected_from;
|
||
|
||
if (!$member->registration && $actd &&
|
||
!empty($acf) && $acf != '0000-00-00' &&
|
||
((time() - strtotime($acf)) / 86400 > $actd))
|
||
{
|
||
$messages_ip_addresses_model
|
||
->add_redirection_to_ip_address(
|
||
$connection_test_expired_id, $ip_address->id, ''
|
||
);
|
||
}
|
||
|
||
continue; // no other messages for applicants
|
||
}
|
||
|
||
// member is debtor
|
||
if ($balance < Settings::get('debtor_boundary'))
|
||
if (!$has_membership_interrupt &&
|
||
$balance < Settings::get('debtor_boundary'))
|
||
{
|
||
$messages_ip_addresses_model
|
||
->add_redirection_to_ip_address(
|
||
... | ... | |
}
|
||
|
||
// member is almost debtor
|
||
if ($balance >= Settings::get('debtor_boundary') &&
|
||
if (!$has_membership_interrupt &&
|
||
$balance >= Settings::get('debtor_boundary') &&
|
||
$balance < Settings::get('payment_notice_boundary'))
|
||
{
|
||
$messages_ip_addresses_model
|
freenetis/branches/1.1/application/controllers/transfers.php | ||
---|---|---|
$view->content->inbound = $inbound;
|
||
$view->content->outbound = $outbound;
|
||
$view->content->variable_symbols = $variable_symbols;
|
||
$view->content->expiration_date = Members_Controller::get_expiration_date($account);
|
||
|
||
if ($account->member->type != Member_Model::TYPE_APPLICANT &&
|
||
$account->member->type != Member_Model::TYPE_FORMER)
|
||
{
|
||
$view->content->expiration_date = Members_Controller::get_expiration_date($account);
|
||
}
|
||
|
||
$view->content->transfers_grid = $transfers_grid;
|
||
|
||
if ($this->acl_check_view('Members_Controller', 'comment', $account->member_id))
|
freenetis/branches/1.1/application/controllers/members.php | ||
---|---|---|
}
|
||
|
||
// finds date of expiration of member fee
|
||
$expiration_date = (isset($account)) ? self::get_expiration_date($account) : '';
|
||
$expiration_date = '';
|
||
|
||
if (isset($account) &&
|
||
$account->member->type != Member_Model::TYPE_APPLICANT &&
|
||
$account->member->type != Member_Model::TYPE_FORMER)
|
||
{
|
||
$expiration_date = self::get_expiration_date($account);
|
||
}
|
||
|
||
// finds total traffic of member
|
||
if (Settings::get('ulogd_enabled'))
|
freenetis/branches/1.1/version.php | ||
---|---|---|
* The current version of FreenetIS.
|
||
* This value must be changed by developers in a new release of FreenetIS.
|
||
*/
|
||
define('FREENETIS_VERSION', '1.1.0~alpha29');
|
||
define('FREENETIS_VERSION', '1.1.0~alpha30');
|
Také k dispozici: Unified diff
freenetis_1.1.0~alpha30
Opravy:
- oprava chybne reaktivace zprav u aplikantu na clenstvi
- reaktivace zpravy o vyprseni testovaciho pripojeni pri reaktivaci zprav
- fixes #580: Nezobrazovat u cekatelu na clenstvi pole "zaplaceno do"
- fixes #583: Presmerovanemu clenovi lze aktivovat upozorneni na placeni