Commit 438bc0bc90a591c50d18c08e21ffbe6cdb4ff816

Authored by michael
1 parent d1c07b89

updated @package


git-svn-id: https://kt-dms.svn.sourceforge.net/svnroot/kt-dms/trunk@388 c91229c3-7414-0410-bfa2-8a42b809f60b
control.php
... ... @@ -12,7 +12,7 @@
12 12 *
13 13 * @version $Revision$
14 14 * @author Michael Joseph <michael@jamwarehouse.com>, Jam Warehouse (Pty) Ltd, South Africa
15   - * @package control
  15 + * @package controller
16 16 */
17 17  
18 18 // main library routines and defaults
... ...
documentBrowser.php
... ... @@ -13,7 +13,7 @@
13 13 *
14 14 * @version $Revision$
15 15 * @author Michael Joseph <michael@jamwarehouse.com>, Jam Warehouse (Pty) Ltd, South Africa
16   - * @package dms
  16 + * @package presentation
17 17 *
18 18 * Querystring variables
19 19 * ---------------------
... ...
tests/administration/groupManTesting.php
... ... @@ -21,7 +21,7 @@
21 21 *
22 22 * @version $Revision$
23 23 * @author Mukhtar Dharsey
24   - * @package testing
  24 + * @package tests.administration
25 25 */
26 26 /*-----------------------------------------------------------------*/
27 27  
... ...
tests/administration/userManTesting.php
... ... @@ -21,7 +21,7 @@
21 21 *
22 22 * @version $Revision$
23 23 * @author Mukhtar Dharsey
24   - * @package testing
  24 + * @package tests.administration
25 25 */
26 26 /*-----------------------------------------------------------------*/
27 27  
... ...
tests/documentmanagement/DocumentBrowser.php
... ... @@ -16,88 +16,85 @@ require_once (&quot;$default-&gt;owl_fs_root/lib/documentmanagement/DocumentBrowser.inc&quot;
16 16 *
17 17 * @version $Revision$
18 18 * @author Michael Joseph <michael@jamwarehouse.com>, Jam Warehouse (Pty) Ltd, South Africa
19   - * @package tests/documentmanagement
  19 + * @package tests.documentmanagement
20 20 */
21 21  
22 22 // -------------------------------
23 23 // page start
24 24 // -------------------------------
25   -if (checkSession()) {
26 25  
  26 +if (checkSession()) {
27 27 $default->log->debug("DocumentBrowser.php:: authorised flag:" . $_SESSION["authorised"]);
28   - // check if this page is authorised, ie. has come from control.php
29   - if ($_SESSION["authorised"]) {
30   -
31   - echo "<pre>";
32 28  
33   - $db = new DocumentBrowser();
  29 + echo "<pre>";
  30 +
  31 + $db = new DocumentBrowser();
34 32  
35   - // default browse- should resolve to root folder
36   - echo "default browse- starts at this users root folder<br>";
37   - $artifacts = $db->browseByFolder();
38   - if (!is_null($_SESSION["errorMessage"])) {
39   - echo "error: " . $_SESSION["errorMessage"] . "<br>";
40   - $_SESSION["errorMessage"] = NULL;
41   - }
42   - print_r($artifacts);
43   -
44   - // now supply a folderid
45   - $folderID = 3;
46   - echo "browse- starting at folder (folderID=$folderID)<br>";
47   - $artifacts = $db->browseByFolder($folderID);
48   - if (!is_null($_SESSION["errorMessage"])) {
49   - echo "error: " . $_SESSION["errorMessage"] . "<br>";
50   - $_SESSION["errorMessage"] = NULL;
51   - }
52   - print_r($artifacts);
  33 + // default browse- should resolve to root folder
  34 + echo "default browse- starts at this users root folder<br>";
  35 + $artifacts = $db->browseByFolder();
  36 + if (!is_null($_SESSION["errorMessage"])) {
  37 + echo "error: " . $_SESSION["errorMessage"] . "<br>";
  38 + $_SESSION["errorMessage"] = NULL;
  39 + }
  40 + print_r($artifacts);
  41 +
  42 + // now supply a folderid
  43 + $folderID = 3;
  44 + echo "browse- starting at folder (folderID=$folderID)<br>";
  45 + $artifacts = $db->browseByFolder($folderID);
  46 + if (!is_null($_SESSION["errorMessage"])) {
  47 + echo "error: " . $_SESSION["errorMessage"] . "<br>";
  48 + $_SESSION["errorMessage"] = NULL;
  49 + }
  50 + print_r($artifacts);
53 51  
54   - // browse by category
55   - echo "category browse- return a list of categories:<br>";
56   - $categories = $db->browseByCategory();
57   - if (!is_null($_SESSION["errorMessage"])) {
58   - echo "error: " . $_SESSION["errorMessage"] . "<br>";
59   - $_SESSION["errorMessage"] = NULL;
60   - }
61   - print_r($categories);
62   -
63   - // pick a random category
64   - srand ((float) microtime() * 10000000);
65   - $rand_keys = array_rand ($categories, 1);
66   - $category = $categories[$rand_keys];
67   - echo "browsing by category = $category<br>";
68   - $artifacts = $db->browseByCategory($category);
69   - if (!is_null($_SESSION["errorMessage"])) {
70   - echo "error: " . $_SESSION["errorMessage"] . "<br>";
71   - $_SESSION["errorMessage"] = NULL;
72   - }
73   - print_r($artifacts);
  52 + // browse by category
  53 + echo "category browse- return a list of categories:<br>";
  54 + $categories = $db->browseByCategory();
  55 + if (!is_null($_SESSION["errorMessage"])) {
  56 + echo "error: " . $_SESSION["errorMessage"] . "<br>";
  57 + $_SESSION["errorMessage"] = NULL;
  58 + }
  59 + print_r($categories);
  60 +
  61 + // pick a random category
  62 + srand ((float) microtime() * 10000000);
  63 + $rand_keys = array_rand ($categories, 1);
  64 + $category = $categories[$rand_keys];
  65 + echo "browsing by category = $category<br>";
  66 + $artifacts = $db->browseByCategory($category);
  67 + if (!is_null($_SESSION["errorMessage"])) {
  68 + echo "error: " . $_SESSION["errorMessage"] . "<br>";
  69 + $_SESSION["errorMessage"] = NULL;
  70 + }
  71 + print_r($artifacts);
74 72  
75   - // document type browsing
76   - echo "document type browse- get list of doc types<br>";
77   - $documentTypes = $db->browseByDocumentType();
78   - if (!is_null($_SESSION["errorMessage"])) {
79   - echo "error: " . $_SESSION["errorMessage"] . "<br>";
80   - $_SESSION["errorMessage"] = NULL;
81   - }
82   - print_r($documentTypes);
83   -
84   - // pick a random document type
85   - srand ((float) microtime() * 10000000);
86   - $documentTypeID = array_rand ($documentTypes, 1);
87   -
88   - echo "browsing by document type = " . $documentTypeID . "<br>";
89   - $artifacts = $db->browseByDocumentType($documentTypeID);
90   - if (!is_null($_SESSION["errorMessage"])) {
91   - echo "error: " . $_SESSION["errorMessage"] . "<br>";
92   - $_SESSION["errorMessage"] = NULL;
93   - }
94   - print_r($artifacts);
  73 + // document type browsing
  74 + echo "document type browse- get list of doc types<br>";
  75 + $documentTypes = $db->browseByDocumentType();
  76 + if (!is_null($_SESSION["errorMessage"])) {
  77 + echo "error: " . $_SESSION["errorMessage"] . "<br>";
  78 + $_SESSION["errorMessage"] = NULL;
  79 + }
  80 + print_r($documentTypes);
  81 +
  82 + // pick a random document type
  83 + srand ((float) microtime() * 10000000);
  84 + $documentTypeID = array_rand ($documentTypes, 1);
  85 +
  86 + echo "browsing by document type = " . $documentTypeID . "<br>";
  87 + $artifacts = $db->browseByDocumentType($documentTypeID);
  88 + if (!is_null($_SESSION["errorMessage"])) {
  89 + echo "error: " . $_SESSION["errorMessage"] . "<br>";
  90 + $_SESSION["errorMessage"] = NULL;
  91 + }
  92 + print_r($artifacts);
95 93  
96   - echo "</pre>";
97   - } else {
98   - // FIXME: redirect to no permission page
99   - print "you do not have access to view this page! please go away, and come back when you do.<br>";
100   - echo generateLink("logout") . "logout</a>";
101   - }
  94 + echo "</pre>";
  95 +} else {
  96 + // FIXME: redirect to no permission page
  97 + print "you do not have access to view this page! please go away, and come back when you do.<br>";
  98 + echo generateLink("logout") . "logout</a>";
102 99 }
103 100 ?>
... ...