Use objectMakeUrl()/Link() in more places
This commit is contained in:
committed by
WineHQ
parent
9de4e9b63b
commit
169d7ca493
@@ -19,7 +19,8 @@ if(!empty($aClean['sSubmit']))
|
||||
{
|
||||
process_app_version_changes(false);
|
||||
url::processForm($aClean);
|
||||
util_redirect_and_exit(apidb_fullurl("appview.php?iAppId={$aClean['iAppId']}"));
|
||||
$oApp = new application($aClean['iAppId']);
|
||||
util_redirect_and_exit($oApp->objectMakeUrl());
|
||||
}
|
||||
else
|
||||
// Show the form for editing the Application Family
|
||||
@@ -52,7 +53,7 @@ else
|
||||
// URL editor
|
||||
echo url::outputEditor("editAppFamily.php", NULL, $oApp);
|
||||
|
||||
echo html_back_link(1,BASE."appview.php?iAppId=$oApp->iAppId");
|
||||
echo html_back_link(1,$oApp->objectMakeUrl());
|
||||
}
|
||||
|
||||
apidb_footer();
|
||||
|
||||
@@ -12,6 +12,7 @@ if(!is_numeric($aClean['iNoteId']))
|
||||
|
||||
/* Get note data */
|
||||
$oNote = new Note($aClean['iNoteId']);
|
||||
$oVersion = new version($oNote->iVersionId);
|
||||
|
||||
/* Check for privs */
|
||||
if(!$_SESSION['current']->hasPriv("admin") && !$_SESSION['current']->isMaintainer($oNote->iVersionId) && !$_SESSION['current']->isSuperMaintainer($oNote->iAppId))
|
||||
@@ -29,7 +30,7 @@ if(!empty($aClean['sSub']))
|
||||
{
|
||||
$oNote->update();
|
||||
}
|
||||
util_redirect_and_exit(apidb_fullurl("appview.php?iVersionId={$oNote->iVersionId}"));
|
||||
util_redirect_and_exit($oVersion->objectMakeUrl());
|
||||
} else /* display note */
|
||||
{
|
||||
// show form
|
||||
@@ -53,7 +54,7 @@ if(!empty($aClean['sSub']))
|
||||
echo '<input type="submit" name=sSub value="Delete"></td></tr>',"\n";
|
||||
echo '</center>';
|
||||
|
||||
echo html_back_link(1,BASE."appview.php?iVersionId=".$oNote->iVersionId);
|
||||
echo html_back_link(1,$oVersion->objectMakeUrl());
|
||||
}
|
||||
|
||||
apidb_footer();
|
||||
|
||||
@@ -18,7 +18,8 @@ if(!empty($aClean['sSubmit']))
|
||||
process_app_version_changes(true);
|
||||
downloadurl::processForm($aClean);
|
||||
url::processForm($aClean);
|
||||
util_redirect_and_exit(apidb_fullurl("appview.php?iVersionId=".$aClean['iVersionId']));
|
||||
$oVersion = new version($aClean['iVersionId']);
|
||||
util_redirect_and_exit($oVersion->objectMakeUrl());
|
||||
} else /* or display the webform for making changes */
|
||||
{
|
||||
|
||||
@@ -59,7 +60,7 @@ if(!empty($aClean['sSubmit']))
|
||||
echo html_frame_end();
|
||||
}
|
||||
|
||||
echo html_back_link(1,BASE."appview.php?iVersionId=".$oVersion->iVersionId);
|
||||
echo html_back_link(1,$oVersion->objectMakeUrl());
|
||||
apidb_footer();
|
||||
}
|
||||
?>
|
||||
|
||||
@@ -18,9 +18,10 @@ if(!empty($aClean['sAction']))
|
||||
$oVersion = new Version($aClean['iVersionId']);
|
||||
$oVersion->iAppId = $aClean['iAppId'];
|
||||
$oVersion->update();
|
||||
$oApp = new application($aClean['iAppId']);
|
||||
|
||||
/* redirect to the application we just moved this version to */
|
||||
util_redirect_and_exit(apidb_fullurl("appview.php?iAppId=".$aClean['iAppId']));
|
||||
util_redirect_and_exit($oApp->objectMakeUrl());
|
||||
} else /* or display the webform for making changes */
|
||||
{
|
||||
?>
|
||||
@@ -50,12 +51,13 @@ if(!empty($aClean['sAction']))
|
||||
{
|
||||
/* if the version ids differ then we should start a row with a new application */
|
||||
/* and the version that matches with it */
|
||||
if($currentAppId != $oRow->appId)
|
||||
if($iCurrentAppId != $oRow->appId)
|
||||
{
|
||||
$currentAppId = $oRow->appId;
|
||||
$oApp = new application($oRow->appId);
|
||||
$iCurrentAppId = $oRow->appId;
|
||||
echo '<tr style="background: #CCDDFF; border: thin solid; font-weight:bold;"><td align="left" style="padding-left:20px;">';
|
||||
$url = BASE."appview.php?iAppId=".$oRow->appId;
|
||||
echo '<a href="'.$url.'">'.substr($oRow->appName, 0, 30).'</a></td><td> - '.$oRow->appId.'</td>';
|
||||
$sUrl = $oApp->objectMakeUrl();
|
||||
echo '<a href="'.$sUrl.'">'.substr($oRow->appName, 0, 30).'</a></td><td> - '.$oRow->appId.'</td>';
|
||||
echo "<td style='padding-left:20px;'><a href='moveAppVersion.php?sAction=move&iVersionId=$oVersion->iVersionId&iAppId=$oRow->appId'>Move here</a></td></tr>";
|
||||
echo '<tr style="border-left: thin solid; border-right:thin solid; background: #FAFBE2;"><td style="padding-left:40px;" colspan="3" align="left">'.$oRow->versionName.'</td></tr>';
|
||||
} else /* just add another version */
|
||||
@@ -68,7 +70,7 @@ if(!empty($aClean['sAction']))
|
||||
echo html_table_end();
|
||||
echo html_frame_end();
|
||||
echo "</form>";
|
||||
echo html_back_link(1, BASE."appview.php?iVersionId=".$oVersion->iVersionId);
|
||||
echo html_back_link(1, $oVersion->objectMakeUrl());
|
||||
apidb_footer();
|
||||
}
|
||||
?>
|
||||
|
||||
Reference in New Issue
Block a user