MTrackWeb/Projects.php
[web.mtrack] / MTrackWeb / Projects.php
1 <?php
2
3 /**
4  *
5  * public facing.. listing projects..
6  * and selecting active project..
7  *
8  * GET -> list of projects
9  * POST -> set active project..
10  * 
11  * 
12  */
13
14 require_once 'MTrackWeb.php';
15
16 class MTrackWeb_Projects extends MTrackWeb
17 {
18     
19     //function getAuth-- inherit
20     
21     function get() {
22         
23         
24         $kv = $this->userProjects();
25         $ret = array();
26         foreach($kv as $k=>$v) {
27             $ret[] = array('id'=>$k, 'name' => $v);
28         }
29         $this->jdata($ret); 
30         
31     }
32      
33     /**
34      *
35      * Things that can change...
36      * - permission updates 
37      *
38      */
39     function post()
40     {
41          
42         
43         
44     }
45      
46     
47     
48     
49 }