1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-08-08 01:36:57 +02:00

[feature/soft-delete] Add new fields for topic/post counts for softdelete

We can not use the replies vs replies_real anymore, as we need to be able to
determinate whether the posts are unapproved or softdeleted. So we need to add
a new field and there by change the second one for consistency.
We also add the posts_* fields for forums, which are a missing feature.

PHPBB3-9567
This commit is contained in:
Joas Schilling
2012-10-21 22:33:28 +02:00
parent e7a137820b
commit 9c5482317e
8 changed files with 58 additions and 26 deletions

View File

@@ -243,8 +243,11 @@ CREATE TABLE phpbb_forums (
forum_type tinyint(4) NOT NULL DEFAULT '0',
forum_status tinyint(4) NOT NULL DEFAULT '0',
forum_posts INTEGER UNSIGNED NOT NULL DEFAULT '0',
forum_posts_unapproved INTEGER UNSIGNED NOT NULL DEFAULT '0',
forum_posts_softdeleted INTEGER UNSIGNED NOT NULL DEFAULT '0',
forum_topics INTEGER UNSIGNED NOT NULL DEFAULT '0',
forum_topics_real INTEGER UNSIGNED NOT NULL DEFAULT '0',
forum_topics_unapproved INTEGER UNSIGNED NOT NULL DEFAULT '0',
forum_topics_softdeleted INTEGER UNSIGNED NOT NULL DEFAULT '0',
forum_last_post_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
forum_last_poster_id INTEGER UNSIGNED NOT NULL DEFAULT '0',
forum_last_post_subject text(65535) NOT NULL DEFAULT '',
@@ -762,8 +765,9 @@ CREATE TABLE phpbb_topics (
topic_time INTEGER UNSIGNED NOT NULL DEFAULT '0',
topic_time_limit INTEGER UNSIGNED NOT NULL DEFAULT '0',
topic_views INTEGER UNSIGNED NOT NULL DEFAULT '0',
topic_replies INTEGER UNSIGNED NOT NULL DEFAULT '0',
topic_replies_real INTEGER UNSIGNED NOT NULL DEFAULT '0',
topic_posts INTEGER UNSIGNED NOT NULL DEFAULT '0',
topic_posts_unapproved INTEGER UNSIGNED NOT NULL DEFAULT '0',
topic_posts_softdeleted INTEGER UNSIGNED NOT NULL DEFAULT '0',
topic_status tinyint(3) NOT NULL DEFAULT '0',
topic_type tinyint(3) NOT NULL DEFAULT '0',
topic_first_post_id INTEGER UNSIGNED NOT NULL DEFAULT '0',