fu: Close-up of Fu, bringing a scoop of water to her mouth (Default)
fu ([personal profile] fu) wrote in [site community profile] changelog2010-10-30 04:06 am

[dw-free] Implement v-gifts

[commit: http://hg.dwscoalition.org/dw-free/rev/47b272e3265c]

http://bugs.dwscoalition.org/show_bug.cgi?id=215

Allow all users with the appropriate privs to view approved vgifts.

Patch by [personal profile] kareila.

Files modified:
  • htdocs/admin/vgifts/index.bml
--------------------------------------------------------------------------------
diff -r faff8936d27e -r 47b272e3265c htdocs/admin/vgifts/index.bml
--- a/htdocs/admin/vgifts/index.bml	Sat Oct 30 11:56:04 2010 +0800
+++ b/htdocs/admin/vgifts/index.bml	Sat Oct 30 12:06:19 2010 +0800
@@ -530,7 +530,9 @@
                 : DW::VirtualGift->list_queued();
         }
         foreach my $vg ( @vgifts ) {
-            next unless $vg && $vg->can_be_approved_by( $remote );
+            next unless $vg;
+            next unless $vg->is_approved && $siteadmin ||
+                        $vg->can_be_approved_by( $remote );
             $body .= $begin_reviewdiv_left->();
             $body .= $vg->display_basic;
             $body .= "<p>" . $vg->display_vieweditlinks . "</p>\n";
--------------------------------------------------------------------------------