case 'topic': if (!$topics_list = AWS_APP::cache()->get('square_parent_topics_topic_list_' . intval($_GET['topic_id']) . '_' . intval($_GET['page']))) { $topic_ids = intval($_GET['topic_id']); if ($child_topic_ids = $this->model('topic')->get_child_topic_ids($_GET['topic_id'])) { $topic_ids = array_merge($child_topic_ids, $topic_ids); } if ($topics_list = $this->model('topic')->get_topic_list('topic_id IN(' . implode(',', $topic_ids) . ') AND merged_id = 0', 'discuss_count DESC', 20, $_GET['page'])) { $topics_list_total_rows = $this->model('topic')->found_rows(); AWS_APP::cache()->set('square_parent_topics_topic_list_' . intval($_GET['topic_id']) . '_total_rows', $topics_list_total_rows, get_setting('cache_level_low')); } AWS_APP::cache()->set('square_parent_topics_topic_list_' . intval($_GET['topic_id']) . '_' . intval($_GET['page']), $topics_list, get_setting('cache_level_low')); } else { $topics_list_total_rows = AWS_APP::cache()->get('square_parent_topics_topic_list_' . intval($_GET['topic_id']) . '_total_rows'); } TPL::assign('topics_list', $topics_list); break;改为
case 'topic': if (!$topics_list = AWS_APP::cache()->get('square_parent_topics_topic_list_' . intval($_GET['topic_id']) . '_' . intval($_GET['page']))) { $_GET['topic_id'] = intval($_GET['topic_id']); $_GET['page'] = intval($_GET['page']); $topics_list = $this->model('topic')->fetch_page('topic', 'merged_id = 0 AND parent_id = ' . intval($_GET['topic_id']), 'discuss_count DESC', $_GET['page'], 20); $topics_list_total_rows = $this->model('topic')->found_rows(); AWS_APP::cache()->set('square_parent_topics_topic_list_' . intval($_GET['topic_id']) . '_' . intval($_GET['page']), $topics_list, get_setting('cache_level_low')); AWS_APP::cache()->set('square_parent_topics_topic_list_' . intval($_GET['topic_id']) . '_total_rows', $topics_list_total_rows, get_setting('cache_level_low')); } else { $topics_list_total_rows = AWS_APP::cache()->get('square_parent_topics_topic_list_' . intval($_GET['topic_id']) . '_total_rows'); } TPL::assign('topics_list', $topics_list); break; }
这家伙很懒,还没有设置简介