Changeset 656
- Timestamp:
- 02/02/09 08:07:49 (15 years ago)
- Location:
- trunk/expressoCalendar
- Files:
-
- 7 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/expressoCalendar/inc/class.bocalendar.inc.php
r632 r656 30 30 function requestDayCal ($dayTime) { 31 31 $day = getdate($dayTime); 32 $query = ("SELECT * FROM phpgw_cal where (owner = '".$this->user_id."') and ((datetime > ".mktime(0,0,0,$day['mon'],$day['mday'],$day['year'])." and datetime < ".(mktime(0,0,0,$day['mon'],($day['mday']+1),$day['year'])).") or (edatetime > ".mktime(0,0,0,$day['mon'],$day['mday'],$day['year'])." and edatetime < ".(mktime(0,0,0, ($day['mon']+1),$day['mday'],$day['year']))."))");32 $query = ("SELECT * FROM phpgw_cal where (owner = '".$this->user_id."') and ((datetime > ".mktime(0,0,0,$day['mon'],$day['mday'],$day['year'])." and datetime < ".(mktime(0,0,0,$day['mon'],($day['mday']+1),$day['year'])).") or (edatetime > ".mktime(0,0,0,$day['mon'],$day['mday'],$day['year'])." and edatetime < ".(mktime(0,0,0,$day['mon'],$day['mday']+1,$day['year']))."))"); 33 33 if (!$this->db->query($query)) 34 34 return false; -
trunk/expressoCalendar/inc/class.uicalendar.inc.php
r632 r656 94 94 function getViewDay () { 95 95 $dayViewTime = isset ($_REQUEST["time"]) ? strtotime(substr($_REQUEST["time"],0,4)."-".substr($_REQUEST["time"],6,2)."-".substr($_REQUEST["time"],4,2)) : strtotime(date('Y-m-d', time())); 96 if (isset ($_REQUEST["uid"])) 97 $this->db_obj->user_id = $_REQUEST["uid"]; 96 98 97 99 $retorno = "<today>".date('Ydm',$dayViewTime)."</today>"; … … 125 127 $dayViewTime -= (date('N', $dayViewTime)%7)*86400; 126 128 $retorno = "<today>".date('Ydm', $dayViewTime)."</today>"; 129 if (isset ($_REQUEST["uid"])) 130 $this->db_obj->user_id = $_REQUEST["uid"]; 131 127 132 128 133 $fromBo = $this->db_obj->requestWeekCal($dayViewTime); … … 169 174 function getViewMonth () { 170 175 $monthViewTime = isset ($_REQUEST["time"]) ? strtotime(substr($_REQUEST["time"],0,4)."-".substr($_REQUEST["time"],6,2)."-".substr($_REQUEST["time"],4,2)) : strtotime(date('Y-m-d', time())); 176 if (isset ($_REQUEST["uid"])) 177 $this->db_obj->user_id = $_REQUEST["uid"]; 171 178 172 179 $todayTime = strtotime(date('Y-m', $monthViewTime)."-01"); -
trunk/expressoCalendar/index.php
r632 r656 33 33 $GLOBALS['phpgw']->categories = CreateObject('phpgwapi.categories'); 34 34 $bo = CreateObject('calendar.bocalendar'); 35 $cat = $bo->cat; 35 $cat = &$bo->cat; 36 $cat->app_name = 'calendar'; // The categories still the same from egroupwareCalendar 36 37 $optionCategories = $cat->formated_list('select','all',$bo->cat_id,'True'); 37 38 foreach ($bo->list_cals() as $cal_) 38 $optionCals .= '<option value="' . $cal_['grantor'] . '">'.$cal_['name'].'</option>' . "\n";39 39 if (! strstr($cal_['value'],'g_')) 40 $optionCals .= '<option value="' . $cal_['grantor'] . '">'.$cal_['name'].'</option>' . "\n"; 40 41 } 41 42 -
trunk/expressoCalendar/js/calendar_functions.js
r632 r656 9 9 this.nextView; 10 10 this.previousView; 11 this.uid = calUid; 11 12 } 12 13 … … 121 122 viewType = type; 122 123 screenTable = new Array(); 123 XMLTools.request('$this.uicalendar.getView'+type+(data?data:'') , 'GET', handler_getView);124 XMLTools.request('$this.uicalendar.getView'+type+(data?data:'')+'&uid='+this.uid, 'GET', handler_getView); 124 125 }; 125 126 127 Calendar.prototype.resetView = function() 128 { 129 document.getElementById("div_main").innerHTML = ""; 130 } 126 131 127 132 Calendar.prototype.parseView = function(data,type) -
trunk/expressoCalendar/js/globals.js
r632 r656 10 10 document.getElementById('yearLinkView').alt = get_lang('Year View'); 11 11 } 12 12 var calUid = document.getElementById('cal_id').value; -
trunk/expressoCalendar/templates/default/index.tpl
r632 r656 4 4 <tr> 5 5 <td> 6 <select name="cat_id">6 <select id="cat_id"> 7 7 {cat_options} 8 8 </select> 9 9 </td> 10 10 <td> 11 <select name="cal_id">11 <select id="cal_id" onchange="calendar.uid=this.value; calendar.getView('div_main',viewType);"> 12 12 {cal_options} 13 13 </select> -
trunk/expressoCalendar/xsl/viewDay.xsl
r632 r656 7 7 </div> 8 8 <div width="100%" class="title" align="left" ><label id="l_date"></label><br/><br/> 9 <table class="table_common" height="50%" width="100%" cellpadding="0" cellspacing="0"> 9 <table class="table_common" width="100%" cellpadding="0" cellspacing="0" border="0"> 10 <tbody> 10 11 <xsl:for-each select="workday"> 11 12 <tr> … … 17 18 </tr> 18 19 </xsl:for-each> 20 </tbody> 19 21 </table> 20 22 </div>
Note: See TracChangeset
for help on using the changeset viewer.