ChangeSet ID: 31142
CVSROOT: /opt/cvs-commit
Module name: appdb
Changes by: wineowner(a)winehq.org 2007/05/26 12:55:10
Modified files:
. : screenshots.php
Log message:
Ben Hodgetts <ben(a)atomnet.co.uk>
Add cropping notice to the screenshot submission page to encourage users to submit screenshots
focused on the application running under wine and not their entire desktop
Patch: http://cvs.winehq.org/patch.py?id=31142
Old revision New revision Changes Path
1.44 1.45 +3 -0 appdb/screenshots.php
Index: appdb/screenshots.php
diff -u -p appdb/screenshots.php:1.44 appdb/screenshots.php:1.45
--- appdb/screenshots.php:1.44 26 May 2007 17:55:10 -0000
+++ appdb/screenshots.php 26 May 2007 17:55:10 -0000
@@ -113,6 +113,9 @@ if($hResult && mysql_num_rows($hResult))
// let's show the screenshot uploading box
if($aClean['iVersionId'])
{
+ echo "<p align=\"center\">When submitting screenshots please ensure that the focus is on the application running inside Wine.";
+ echo "<br />This means if the application is running in a window then please crop the image so that only the application is shown and not your desktop.</p>";
+
echo '<form enctype="multipart/form-data" action="screenshots.php" name="sImageForm" method="post">',"\n";
echo html_frame_start("Upload Screenshot","400","",0);
echo '<table border=0 cellpadding=6 cellspacing=0 width="100%">',"\n";
ChangeSet ID: 31141
CVSROOT: /opt/cvs-commit
Module name: appdb
Changes by: wineowner(a)winehq.org 2007/05/26 12:01:11
Modified files:
include : testData.php
Log message:
Ben Hodgetts <ben(a)atomnet.co.uk>
Add more detail to the test data submission page
Patch: http://cvs.winehq.org/patch.py?id=31141
Old revision New revision Changes Path
1.52 1.53 +6 -2 appdb/include/testData.php
Index: appdb/include/testData.php
diff -u -p appdb/include/testData.php:1.52 appdb/include/testData.php:1.53
--- appdb/include/testData.php:1.52 26 May 2007 17: 1:11 -0000
+++ appdb/include/testData.php 26 May 2007 17: 1:11 -0000
@@ -978,8 +978,12 @@ class testData{
{
echo "<p>This is the screen for inputing test information so that others ";
echo "looking at the database will know \n";
- echo "what was working on a particular release of Wine.</p>\n";
- echo "<p>Please be as detailed as you can.</p>\n";
+ echo "what was working on a particular release of Wine. Although be \n";
+ echo "aware that this is not the bug-tracker and that \n";
+ echo "this is not where the developers check for bugs.</p>\n";
+ echo "<p>Please be as detailed as you can but do not paste large \n";
+ echo "chunks of output from the terminal. Type out your report \n";
+ echo "clearly and in proper English so that it is easily readable.</p>\n";
echo "<p>If you cannot find your distribution in the list of existing ";
echo "distributions, please add it in the \n";
echo "provided field.</p>\n\n";
ChangeSet ID: 31140
CVSROOT: /opt/cvs-commit
Module name: appdb
Changes by: wineowner(a)winehq.org 2007/05/26 11:32:45
Modified files:
. : README
include : config.php.sample
Log message:
Chris Morgan <cmorgan(a)alum.wpi.edu>
Clarify README to specify that you must update APPDB_ROOT to point to your own address. Update
the config.php.sample to not refer to the actuall appdb site. Users may forget to update this
field and end up on the live site without realizing it and do some unintended damage.
Patch: http://cvs.winehq.org/patch.py?id=31140
Old revision New revision Changes Path
1.10 1.11 +9 -5 appdb/README
1.15 1.16 +1 -1 appdb/include/config.php.sample
Index: appdb/README
diff -u -p appdb/README:1.10 appdb/README:1.11
--- appdb/README:1.10 26 May 2007 16:32:45 -0000
+++ appdb/README 26 May 2007 16:32:45 -0000
@@ -20,12 +20,16 @@ To install locally for testing/hacking:
# Edit include/config.php as you see fit, the default name of the database
used in the table creation step below is "apidb", you'll have to modify
these files if you change this in config.php
+
+ # NOTE: You must update the APPDB_ROOT entry to be YOUR url to the application database
+ If this the APPDB_ROOT isn't correct your urls will point to the wrong pages.
+
+ # NOTE: if you've changed the name of the database by changing the define of
+ 'APPS_DB' in include/config.php you'll have to modify the 'create database' and 'use'
+ entries in pretty much every file in the /tables/ directory. The recommendation is to
+ leave the default value of APPS_DB to keep things simple
-# NOTE: if you've changed the name of the database by changing the define of
- 'APPS_DB' in include/config.php you'll have to modify the 'create database' and 'use'
- entries in pretty much every file in the /tables/ directory. The recommendation is to
- leave the default value of APPS_DB to keep things simple
-# cd tables, run ./create_tables to create the database tables
+# 'cd tables', run './create_tables' to create the database tables
# Look in include/config.php at the 'APPS_DBUSER' and 'APPS_DBPASS' defines.
Ensure that this user and password exist in your mysql users list and that this user
Index: appdb/include/config.php.sample
diff -u -p appdb/include/config.php.sample:1.15 appdb/include/config.php.sample:1.16
--- appdb/include/config.php.sample:1.15 26 May 2007 16:32:45 -0000
+++ appdb/include/config.php.sample 26 May 2007 16:32:45 -0000
@@ -13,7 +13,7 @@ define("APPDB_THUMBNAIL_WIDTH","128"); /
define("APPDB_THUMBNAIL_HEIGHT","128"); // height of the screenshot's thumbnails
define("APPDB_SCREENSHOT_MAXWIDTH","1024"); // width of the screenshot's thumbnails
define("APPDB_SCREENSHOT_MAXHEIGHT","768"); // height of the screenshot's thumbnails
-define("APPDB_ROOT", "http://appdb.winehq.org/"); // path to AppDB
+define("APPDB_ROOT", "http://localhost/appdb/"); // path to AppDB
define("APPDB_OWNER","WineHQ"); // with what product/company is this AppDB related ?
define("APPDB_OWNER_URL","http://www.winehq.org/"); // website of this product/company
define("APPDB_OWNER_EMAIL","appdb(a)winehq.org"); // e-mail of this product/company
ChangeSet ID: 31137
CVSROOT: /opt/cvs-commit
Module name: appdb
Changes by: wineowner(a)winehq.org 2007/05/25 23:02:24
Modified files:
cron : cleanup.php
Log message:
Chris Morgan <cmorgan(a)alum.wpi.edu>
Refactor some code into a function to clean up the cleanup script
Patch: http://cvs.winehq.org/patch.py?id=31137
Old revision New revision Changes Path
1.33 1.34 +64 -57 appdb/cron/cleanup.php
Index: appdb/cron/cleanup.php
diff -u -p appdb/cron/cleanup.php:1.33 appdb/cron/cleanup.php:1.34
--- appdb/cron/cleanup.php:1.33 26 May 2007 4: 2:24 -0000
+++ appdb/cron/cleanup.php 26 May 2007 4: 2:24 -0000
@@ -9,80 +9,87 @@ require("path.php");
require(BASE."include/incl.php");
require_once(BASE."include/mail.php");
+inactiveUserCheck();
+
+/* check to see if there are orphaned versions in the database */
+orphanVersionCheck();
+
+/* check and purge any orphaned messages stuck in sessionMessages table */
+orphanSessionMessagesCheck();
+
+/* check and purge any expired sessions from the session_list table */
+orphanSessionListCheck();
+
+/* report error log entries to admins and flush the error log after doing so */
+reportErrorLogEntries();
+
+/* remove screenshots that are missing their screenshot and thumbnail files */
+removeScreenshotsWithMissingFiles();
+
+
+
+
/*
* Warn users that have been inactive for some number of months
* If it has been some period of time since the user was warned
* the user is deleted if they don't have any pending appdb data
*/
-
-$usersWarned = 0;
-$usersUnwarnedWithData = 0; /* users we would normally warn but who have data */
-$usersDeleted = 0;
-$usersWithData = 0; /* users marked for deletion that have data */
-
-notifyAdminsOfCleanupStart();
-
-/* users inactive for 6 months that haven't been warned already */
-$hUsersToWarn = unwarnedAndInactiveSince(6);
-if($hUsersToWarn)
+function inactiveUserCheck()
{
+ $usersWarned = 0;
+ $usersUnwarnedWithData = 0; /* users we would normally warn but who have data */
+ $usersDeleted = 0;
+ $usersWithData = 0; /* users marked for deletion that have data */
+
+ notifyAdminsOfCleanupStart();
+
+ /* users inactive for 6 months that haven't been warned already */
+ $hUsersToWarn = unwarnedAndInactiveSince(6);
+ if($hUsersToWarn)
+ {
while($oRow = mysql_fetch_object($hUsersToWarn))
{
- $oUser = new User($oRow->userid);
+ $oUser = new User($oRow->userid);
- /* if we get back true the user was warned and flagged as being warned */
- /* if we get back false we didn't warn the user and didn't flag the user as warned */
- /* because they have data associated with their account */
- if($oUser->warnForInactivity())
- {
- $usersWarned++;
- } else
- {
- $usersUnwarnedWithData++;
- }
+ /* if we get back true the user was warned and flagged as being warned */
+ /* if we get back false we didn't warn the user and didn't flag the user as warned */
+ /* because they have data associated with their account */
+ if($oUser->warnForInactivity())
+ {
+ $usersWarned++;
+ } else
+ {
+ $usersUnwarnedWithData++;
+ }
}
-}
+ }
-/* warned >= 1 month ago */
-$hUsersToDelete = warnedSince(1);
-if($hUsersToDelete)
-{
+ /* warned >= 1 month ago */
+ $hUsersToDelete = warnedSince(1);
+ if($hUsersToDelete)
+ {
while($oRow = mysql_fetch_object($hUsersToDelete))
{
- $oUser = new User($oRow->userid);
- if(!$oUser->hasDataAssociated())
+ $oUser = new User($oRow->userid);
+ if(!$oUser->hasDataAssociated())
+ {
+ $usersDeleted++;
+ deleteUser($oRow->userid);
+ } else
+ {
+ /* is the user a maintainer? if so remove their maintainer privileges */
+ if($oUser->isMaintainer())
{
- $usersDeleted++;
- deleteUser($oRow->userid);
- } else
- {
- /* is the user a maintainer? if so remove their maintainer privileges */
- if($oUser->isMaintainer())
- {
- Maintainer::deleteMaintainer($oUser);
- }
-
- $usersWithData++;
+ Maintainer::deleteMaintainer($oUser);
}
- }
-}
-
-notifyAdminsOfCleanupExecution($usersWarned, $usersUnwarnedWithData, $usersDeleted, $usersWithData);
-
-/* check to see if there are orphaned versions in the database */
-orphanVersionCheck();
-
-/* check and purge any orphaned messages stuck in sessionMessages table */
-orphanSessionMessagesCheck();
-
-/* check and purge any expired sessions from the session_list table */
-orphanSessionListCheck();
-/* report error log entries to admins and flush the error log after doing so */
-reportErrorLogEntries();
+ $usersWithData++;
+ }
+ }
+ }
-/* remove screenshots that are missing their screenshot and thumbnail files */
-removeScreenshotsWithMissingFiles();
+ notifyAdminsOfCleanupExecution($usersWarned, $usersUnwarnedWithData, $usersDeleted, $usersWithData);
+}
/* Users that are unwarned and inactive since $iMonths */
function unwarnedAndInactiveSince($iMonths)
ChangeSet ID: 31135
CVSROOT: /opt/cvs-commit
Module name: appdb
Changes by: wineowner(a)winehq.org 2007/05/25 20:39:46
Modified files:
include : bugs.php
Log message:
Alexander Nicolaysen Sørnes <alex(a)thehandofagony.com>
Include bug id in more buglink mails
Patch: http://cvs.winehq.org/patch.py?id=31135
Old revision New revision Changes Path
1.24 1.25 +4 -2 appdb/include/bugs.php
Index: appdb/include/bugs.php
diff -u -p appdb/include/bugs.php:1.24 appdb/include/bugs.php:1.25
--- appdb/include/bugs.php:1.24 26 May 2007 1:39:46 -0000
+++ appdb/include/bugs.php 26 May 2007 1:39:46 -0000
@@ -197,11 +197,13 @@ class Bug {
if(!$bRejected)
{
$sSubject = "Submitted Bug Link accepted";
- $sMsg = "The Bug Link you submitted for ".$sAppName." has been accepted.";
+ $sMsg = "The bug link you submitted between Bug ".$this->iBug_id." and ".
+ $sAppName." has been accepted.";
} else
{
$sSubject = "Submitted Bug Link rejected";
- $sMsg = "The Bug Link you submitted for ".$sAppName." has been rejected.";
+ $sMsg = "The bug link you submitted between Bug ".$this->iBug_id." and ".
+ $sAppName." has been deleted.";
}
$sMsg .= $aClean['sReplyText']."\n";
$sMsg .= "We appreciate your help in making the Application Database better for all users.";
ChangeSet ID: 31133
CVSROOT: /opt/cvs-commit
Module name: appdb
Changes by: wineowner(a)winehq.org 2007/05/25 20:37:25
Modified files:
include : distribution.php
Log message:
Alexander Nicolaysen Sørnes <alex(a)thehandofagony.com>
Return true when creating duplicate distributions
Patch: http://cvs.winehq.org/patch.py?id=31133
Old revision New revision Changes Path
1.30 1.31 +15 -8 appdb/include/distribution.php
Index: appdb/include/distribution.php
diff -u -p appdb/include/distribution.php:1.30 appdb/include/distribution.php:1.31
--- appdb/include/distribution.php:1.30 26 May 2007 1:37:25 -0000
+++ appdb/include/distribution.php 26 May 2007 1:37:25 -0000
@@ -82,14 +82,21 @@ class distribution {
//Let's not create a duplicate
$sQuery = "SELECT *
FROM distributions
- WHERE name LIKE '?'";
- $hDuplicate = query_parameters($sQuery, $this->sName);
- if(!mysql_num_rows($hDuplicate) == 0)
- {
- addmsg("There was an existing Distribution called ".$this->sName.".", "red");
- $oRow = mysql_fetch_object($hDuplicate);
- $this->iDistributionId = $oRow->distributionId;
- return false;
+ WHERE name = '?'";
+ $hResult = query_parameters($sQuery, $this->sName);
+
+ if($hResult && $oRow = mysql_fetch_object($hResult))
+ {
+ if(mysql_num_rows($hResult))
+ {
+ addmsg("There was an existing distribution called ".$this->sName.".", "red");
+ $this->distribution($oRow->distributionId);
+
+ /* Even though we did not create a new distribution, the caller is provided
+ with a valid distribution object. Thus no special handling is necessary,
+ so we return TRUE */
+ return TRUE;
+ }
}
$hResult = query_parameters("INSERT INTO distributions (name, url, submitterId, queued) ".