appdb/include distribution.php

WineHQ wineowner at wine.codeweavers.com
Mon Jan 29 18:46:05 CST 2007


ChangeSet ID:	30916
CVSROOT:	/opt/cvs-commit
Module name:	appdb
Changes by:	wineowner at winehq.org	2007/01/29 18:46:05

Modified files:
	include        : distribution.php 

Log message:
	Alexander Nicolaysen Sørnes <alex at thehandofagony.com>
	Only display delete link for distributions without any associated test data

Patch: http://cvs.winehq.org/patch.py?id=30916

Old revision  New revision  Changes     Path
 1.7           1.8           +6 -4       appdb/include/distribution.php

Index: appdb/include/distribution.php
diff -u -p appdb/include/distribution.php:1.7 appdb/include/distribution.php:1.8
--- appdb/include/distribution.php:1.7	30 Jan 2007  0:46: 5 -0000
+++ appdb/include/distribution.php	30 Jan 2007  0:46: 5 -0000
@@ -474,12 +474,14 @@ class distribution {
 
         if($this->canEdit())
         {
+            if(!sizeof($this->aTestingIds))
+            {
+                $sDelete = " &nbsp; [<a href='".$_SERVER['PHP_SELF']."?sSub=delete&".
+                "iDistributionId=$this->iDistributionId'>delete</a>]";
+            }
             $aCells[3] = array(
                 "[<a href='".BASE."admin/editDistribution.php?iDistributionId=".
-                $this->iDistributionId."'>edit</a>]".
-                (!sizeof($this->aTestingIds)) ?
-                " &nbsp; [<a href='".$_SERVER['PHP_SELF']."?sSub=delete&".
-                "iDistributionId=$this->iDistributionId'>delete</a>]" : "",
+                $this->iDistributionId."'>edit</a>]$sDelete",
                 "align=\"center\"");
         }
 



More information about the wine-cvs mailing list