Update the number of threads in the CS when a thread is archived. Fixes bug #11341.
This commit is contained in:
parent
b5f5f8f6e8
commit
6e0983a67b
4 changed files with 39 additions and 21 deletions
|
|
@ -41,7 +41,7 @@ sub addRevision {
|
|||
|
||||
=head2 archive
|
||||
|
||||
Archives all posts under this thread.
|
||||
Archives all posts under this thread. Update the thread count in the parent CS.
|
||||
|
||||
=cut
|
||||
|
||||
|
|
@ -50,6 +50,8 @@ sub archive {
|
|||
foreach my $post (@{$self->getPosts}) {
|
||||
$post->setStatusArchived;
|
||||
}
|
||||
my $cs = $self->getParent;
|
||||
$cs->incrementThreads($cs->get("lastPostId"), $cs->get("lastPostDate"));
|
||||
}
|
||||
|
||||
#-------------------------------------------------------------------
|
||||
|
|
|
|||
|
|
@ -93,8 +93,8 @@ our $I18N = {
|
|||
},
|
||||
|
||||
'forum.threads' => {
|
||||
message => q|The total number of threads in this forum.|,
|
||||
lastUpdated => 1149632734,
|
||||
message => q|The total number of threads in this forum. This does not include those that have been archived.|,
|
||||
lastUpdated => 1263239637,
|
||||
},
|
||||
|
||||
'forum.url' => {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue