Commit d165e26bdcf7dc5cc76b6a9e019ec6ca9b874931

Authored by michael
1 parent 4f3d851a

added generateControllerLink usage and corrected template document browse bug


git-svn-id: https://kt-dms.svn.sourceforge.net/svnroot/kt-dms/trunk@2220 c91229c3-7414-0410-bfa2-8a42b809f60b
presentation/lookAndFeel/knowledgeTree/foldermanagement/viewDependantDocumentsUI.inc
@@ -18,7 +18,7 @@ function getDocumentLinkFolderCollaborationData($iFolderCollaborationID) { @@ -18,7 +18,7 @@ function getDocumentLinkFolderCollaborationData($iFolderCollaborationID) {
18 "WHERE DDT.group_folder_approval_link_id = $iFolderCollaborationID"; 18 "WHERE DDT.group_folder_approval_link_id = $iFolderCollaborationID";
19 19
20 //echo $sQuery; 20 //echo $sQuery;
21 - $aColumns = array("document_title", "username", "template_document_name","edit", "del"); 21 + $aColumns = array("document_title", "username", "template_document_name", "edit", "del");
22 $aColumnHeaders = array("Document title", "Default creator", "Template document"); 22 $aColumnHeaders = array("Document title", "Default creator", "Template document");
23 $aColumnTypes = array(1,1,3,3,3); 23 $aColumnTypes = array(1,1,3,3,3);
24 //$aDBColumnArray = array("id","group_folder_approval_link_id","template_document_id"); 24 //$aDBColumnArray = array("id","group_folder_approval_link_id","template_document_id");
@@ -46,7 +46,7 @@ function getViewPage($iFolderCollaborationID, $iFolderID) { @@ -46,7 +46,7 @@ function getViewPage($iFolderCollaborationID, $iFolderID) {
46 $sToRender .= "<td>" . getDocumentLinkFolderCollaborationData($iFolderCollaborationID) . "</td>\n"; 46 $sToRender .= "<td>" . getDocumentLinkFolderCollaborationData($iFolderCollaborationID) . "</td>\n";
47 $sToRender .= "</tr>\n"; 47 $sToRender .= "</tr>\n";
48 $sToRender .= "<tr>\n"; 48 $sToRender .= "<tr>\n";
49 - $sToRender .= "<td><table><tr><td><input type=\"image\" src=\"$default->graphicsUrl/widgets/add.gif\" border=\"0\"/></td><td></td></tr></table>\n"; 49 + $sToRender .= "<td><table><tr><td><input type=\"image\" src=\"$default->graphicsUrl/widgets/add.gif\" border=\"0\"/></td><td>" . generateControllerLink("editFolder", "fFolderID=$iFolderID&fShowSection=folderRouting", "<img src=\"$default->graphicsUrl/widgets/cancel.gif\" border=\"0\"/>") . "</td></tr></table>\n";
50 $sToRender .= "</tr>\n"; 50 $sToRender .= "</tr>\n";
51 $sToRender .= "</table>\n"; 51 $sToRender .= "</table>\n";
52 52
@@ -76,7 +76,7 @@ function getEditPage($iFolderID, $iDependantDocumentID, $iFolderCollaborationID, @@ -76,7 +76,7 @@ function getEditPage($iFolderID, $iDependantDocumentID, $iFolderCollaborationID,
76 $bAddNetscapeScript = false; 76 $bAddNetscapeScript = false;
77 if (! (($default->phpSniff->property("browser") == "moz") && ($default->phpSniff->property("version") <= "4.79")) ) { 77 if (! (($default->phpSniff->property("browser") == "moz") && ($default->phpSniff->property("version") <= "4.79")) ) {
78 //for any other browser but netscape 4.7 do this 78 //for any other browser but netscape 4.7 do this
79 - $sToRender .= "<td>Template document</td><td><input type=\"text\" DISABLED name=\"fTargetDocument\" value=\"$sTemplateDocumentName\" /><input type=\"button\" value=\"Browse\" onClick=\"newWindow('http://ktdev/control.php?action=templateBrowse','window2')\"></td>\n"; 79 + $sToRender .= "<td>Template document</td><td><input type=\"text\" DISABLED name=\"fTargetDocument\" value=\"$sTemplateDocumentName\" /><input type=\"button\" value=\"Browse\" onClick=\"newWindow('" . generateControllerLink("templateBrowse", "") . "','window2')\"></td>\n";
80 }else { 80 }else {
81 //for netscape 4.7 do this 81 //for netscape 4.7 do this
82 $sToRender .= "<td>Template document</td><td><input type=\"text\" value=\"$sTemplateDocumentName\" name=\"fTargetDocument\" onblur=\"disable(document.MainForm.fTargetDocument);\" /><input type=\"button\" value=\"Browse\" onClick=\"disable(document.MainForm.fTargetDocument);newWindow('http://ktdev/control.php?action=templateBrowse','window2')\"></td>\n"; 82 $sToRender .= "<td>Template document</td><td><input type=\"text\" value=\"$sTemplateDocumentName\" name=\"fTargetDocument\" onblur=\"disable(document.MainForm.fTargetDocument);\" /><input type=\"button\" value=\"Browse\" onClick=\"disable(document.MainForm.fTargetDocument);newWindow('http://ktdev/control.php?action=templateBrowse','window2')\"></td>\n";