Commit bd9890a89e6dd149ae800021b5196539cad80539

Authored by Michael Joseph
1 parent 36b2f36c

refactored display integration with the document details page


git-svn-id: https://kt-dms.svn.sourceforge.net/svnroot/kt-dms/trunk@2211 c91229c3-7414-0410-bfa2-8a42b809f60b
presentation/lookAndFeel/knowledgeTree/documentmanagement/checkInDocumentUI.inc
... ... @@ -58,6 +58,7 @@ function renderCheckInPage($oDocument) {
58 58  
59 59 $sToRender .= "<table>\n";
60 60 $sToRender .= "<tr>\n";
  61 + // FIXME: if the document name contains an apostrophe this js doesn't work
61 62 $sToRender .= "<td><input type=\"image\" border=\"0\" src =\"$default->graphicsUrl/widgets/checkin.gif\" value=\"Submit\" onClick=\"if (validRequired(document.MainForm.fFile, 'Check-In File') && validRequired(document.MainForm.fCheckInComment, 'Check-In Comment')) { return confirm('Are you sure you want to overwrite " . $oDocument->getName() . " with ' + document.MainForm.fFile.value + '?'); } else return false;\"/>\n";
62 63 $sToRender .= "<a href=\"$default->rootUrl/control.php?action=viewDocument&fDocumentID=" . $oDocument->getID() . "\"><img src=\"$default->graphicsUrl/widgets/cancel.gif\" border=\"0\"></a></td>\n";
63 64 $sToRender .= "</tr>\n";
... ... @@ -95,6 +96,10 @@ function renderCheckInPage($oDocument) {
95 96 * @param object the document to view and check out
96 97 */
97 98 function getCheckInPage($oDocument) {
98   - return getPage($oDocument, false, renderCheckInPage($oDocument));
  99 + $sToRender .= renderHeading("Document Detail");
  100 + $sToRender .= renderDocumentPath($oDocument, false) . "\n\n";
  101 + $sToRender .= renderCheckInPage($oDocument);
  102 + $sToRender .= renderDocumentData($oDocument, $bEdit);
  103 + return $sToRender;
99 104 }
100 105 ?>
101 106 \ No newline at end of file
... ...