Skip to content

Commit

Permalink
Фикс ограничения рейтинга для создания тем
Browse files Browse the repository at this point in the history
  • Loading branch information
Chiffa committed Aug 30, 2012
1 parent 4d65993 commit a617dd6
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 8 deletions.
3 changes: 0 additions & 3 deletions classes/modules/acl/ACL.class.php
Expand Up @@ -30,9 +30,6 @@ public function CanAddForumTopic($oForum, $oUser=null) {
if ($oUser->getRating() >= $oForum->getLimitRatingTopic()) {
return true;
}
if ($oUser->getRating() >= Config::Get('plugin.forum.acl.create.topic.rating')) {
return true;
}
}
return false;
}
Expand Down
5 changes: 2 additions & 3 deletions config/config.php
Expand Up @@ -45,10 +45,9 @@
/**
* ACL
*/
$config['acl']['create']['topic']['rating'] = -5; // порог рейтинга при котором юзер может создавать топики
$config['acl']['create']['topic']['time'] = 240; // время в секундах между созданием топиков, если 0 то ограничение по времени не будет работать
$config['acl']['create']['topic']['time_rating'] = 5; // рейтинг, выше которого перестаёт действовать ограничение по времени на создание записей
$config['acl']['create']['post']['rating'] = -10; // порог рейтинга при котором юзер может создавать топики
$config['acl']['create']['post']['rating'] = -10; // порог рейтинга при котором юзер может оставлять ответы
$config['acl']['create']['post']['time'] = 60; // время в секундах между созданием ответов, если 0 то ограничение по времени не будет работать
$config['acl']['create']['post']['time_rating'] = 5; // рейтинг, выше которого перестаёт действовать ограничение по времени на создание записей
$config['acl']['edit']['post']['time'] = 60*60*15; // время в секундах для возможности редактирования ответа, если 0 то ограничение по времени не будет работать
Expand Down Expand Up @@ -76,7 +75,7 @@
*/
$config['deactivate'] = array(
/* Удаление таблиц при деактивации */
'delete' => true
'delete' => false
);

/**
Expand Down
2 changes: 1 addition & 1 deletion templates/language/english.php
Expand Up @@ -133,7 +133,7 @@
'topic_move_error_self' => 'This theme is so chosen forum!',
'topic_move_error_category' => 'You can not move the topic into the category of',
'topic_post_count' => 'Posts in topic',
'topic_acl' => 'You may not post new threads',
'topic_acl' => 'You lack the ratings to create topics in this forum',
'topic_time_limit' => 'You may not post new threads too often',

'new_topic' => 'New topic',
Expand Down
2 changes: 1 addition & 1 deletion templates/language/russian.php
Expand Up @@ -133,7 +133,7 @@
'topic_move_error_self' => 'Эта тема итак находится в выбранном форуме!',
'topic_move_error_category' => 'Вы не можете перенести тему в категорию',
'topic_post_count' => 'Сообщений в теме',
'topic_acl' => 'Вам нельзя создавать темы',
'topic_acl' => 'Вам не хватает рейтинга для создания темы в этом форуме',
'topic_time_limit' => 'Вам нельзя создавать темы слишком часто',

'new_topic' => 'Новая тема',
Expand Down

0 comments on commit a617dd6

Please sign in to comment.