Alexander Nicolaysen Sørnes : bug: Let objectManager delete bug links

Chris Morgan cmorgan at winehq.org
Mon Sep 17 20:32:41 CDT 2007


Module: appdb
Branch: master
Commit: 74cf6afeb286517a69084fb84b78519c38fa2574
URL:    http://source.winehq.org/git/appdb.git/?a=commit;h=74cf6afeb286517a69084fb84b78519c38fa2574

Author: Alexander Nicolaysen Sørnes <alexander at alex.alexstyrt>
Date:   Mon Sep 17 20:41:47 2007 +0200

bug: Let objectManager delete bug links

---

 appview.php      |   12 ------------
 include/bugs.php |    2 +-
 2 files changed, 1 insertions(+), 13 deletions(-)

diff --git a/appview.php b/appview.php
index 601fc11..ebf028b 100644
--- a/appview.php
+++ b/appview.php
@@ -80,18 +80,6 @@ if (isset($aClean['sSub']))
     if(isset($aClean['iVersionId']))
       $oVersion = new Version($aClean['iVersionId']);
 
-    if(($aClean['sSub'] == 'delete' ) && ($aClean['iBuglinkId']))
-    {
-        if(($_SESSION['current']->hasPriv("admin") ||
-            $_SESSION['current']->isMaintainer($oVersion->iVersionId) ||
-            $_SESSION['current']->isSuperMaintainer($oVersion->iAppId)))
-        {
-            $oBuglink = new Bug($aClean['iBuglinkId']);
-            $oBuglink->delete();
-            util_redirect_and_exit($oVersion->objectMakeUrl());
-        }
- 
-    }
     if(($aClean['sSub'] == 'unqueue' ) && ($aClean['iBuglinkId']))
     {
         if(($_SESSION['current']->hasPriv("admin") ||
diff --git a/include/bugs.php b/include/bugs.php
index 7b44519..a68129d 100644
--- a/include/bugs.php
+++ b/include/bugs.php
@@ -563,7 +563,7 @@ function view_version_bugs($iVersionId = null, $aBuglinkIds)
             
             if($bCanEdit == true)
             {
-                echo "<td align=center>[<a href='".$oVersion->objectMakeUrl()."&sSub=delete&iBuglinkId=".$oBuglink->iLinkId."'>delete</a>]</td>\n";
+                echo "<td align=center>[<a href='objectManager.php?sClass=bug&iId=".$oBuglink->iLinkId."&sAction=delete&sSubmit=Delete&sReturnTo=".$oVersion->objectMakeUrl()."'>delete</a>]</td>\n";
                 if ($oBuglink->bQueued)
                 {
                     echo "<td align=center>[<a href='".$oVersion->objectMakeUrl()."&sSub=unqueue&iBuglinkId=".$oBuglink->iLinkId."'>OK</a>]</td>\n";




More information about the wine-cvs mailing list