Changeset 5523
- Timestamp:
- 02/16/12 15:41:57 (13 years ago)
- Location:
- trunk
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/expressoMail1_2/templates/default/expressomail.css
r5497 r5523 9 9 overflow:hidden; 10 10 height:auto; 11 width:18px;12 resize: none; 11 /* width:18px; 12 resize: none;*/ 13 13 } 14 14 a.rich{ -
trunk/prototype/config/PostgreSQL.srv
r5399 r5523 4 4 port = 5432 5 5 dbname= expresso 6 7 ;conexão via socket unix 8 host= /tmp 6 user=postgres 7 host = /var/run/postgresql 9 8 ;conexão via tcp 10 9 ;host = 127.0.0.1 -
trunk/prototype/modules/calendar/interceptors/Notifications.php
r5514 r5523 153 153 $data['userRequest'] = Config::me('uid'); 154 154 155 $ical2 = $ical; 156 $ical2['type'] = 'text/calendar'; 157 $ical2['name'] = 'thunderbird.ics'; 158 $params['attachments'][] = $ical2; 155 159 $params['attachments'][] = $ical; 156 160 $params['isHtml'] = true; … … 179 183 if($params['status'] == 'DECLINECOUNTER') 180 184 $data['status'] = 'não pode ser aceito'; 181 185 $ical2 = $ical; 186 $ical2['type'] = 'text/calendar'; 187 $ical2['name'] = 'thunderbird.ics'; 188 $params['attachments'][] = $ical2; 182 189 $params['attachments'][] = $ical; 183 190 $params['isHtml'] = true; … … 271 278 $schedulable['URI']['concept'] = 'schedulable'; 272 279 $ical['source'] = Controller::format( array( 'service' => 'iCal' ) , array($schedulable) , array('method' => $method) ); 273 $ical['type'] = 'text/ calendar';274 $ical['name'] = 'calendar.ics';280 $ical['type'] = 'text/plain'; 281 $ical['name'] = 'outlook.ics'; 275 282 if($regSet) 276 283 Config::regSet('ical://'.$schedulable['id'].'/'.$method, $ical); … … 420 427 private static function sendMail(&$data , &$ical , $to , &$subject , $template ) 421 428 { 429 $ical2 = $ical; 430 $ical2['type'] = 'text/calendar'; 431 $ical2['name'] = 'thunderbird.ics'; 432 $mail['attachments'][] = $ical2; 422 433 $mail['attachments'][] = $ical; 423 434 $mail['isHtml'] = true; -
trunk/prototype/services/iCal.php
r5514 r5523 361 361 362 362 /* Helpers */ 363 private static function _getTzOffset($rTz, $oTz = null )363 private static function _getTzOffset($rTz, $oTz = null , $time = 'now') 364 364 { 365 365 if($oTz === null) { 366 366 if(!is_string($oTz = date_default_timezone_get())) { 367 return false; // A UTC timestamp was returned -- bail out!367 return false; // A UTC timestamp was returned -- bail out! 368 368 } 369 369 } 370 370 $origin_dtz = new DateTimeZone(self::nomalizeTZID($oTz)); 371 371 $remote_dtz = new DateTimeZone(self::nomalizeTZID($rTz)); 372 $origin_dt = new DateTime( "now", $origin_dtz);372 $origin_dt = new DateTime($time, $origin_dtz); 373 373 $remote_dt = new DateTime("now", $remote_dtz); 374 374 375 $offset = $origin_dtz->getOffset($origin_dt) - $remote_dtz->getOffset($remote_dt); 376 377 375 378 return $offset; 376 379 } … … 379 382 { 380 383 $a = array( 381 STATUS_CONFIRMED => ' CONFIRMED',384 STATUS_CONFIRMED => 'ACCEPTED', 382 385 STATUS_CANCELLED => 'CANCELLED', 383 386 STATUS_TENTATIVE => 'TENTATIVE', … … 445 448 { 446 449 $schedulable['allDay'] = 1; 447 $schedulable['startTime'] = self::date2timestamp($startTime['value']) - self::_getTzOffset('UTC',$schedulable['timezone'] ) . '000';450 $schedulable['startTime'] = self::date2timestamp($startTime['value']) - self::_getTzOffset('UTC',$schedulable['timezone'], '@'.self::date2timestamp($startTime['value'])) . '000'; 448 451 } 449 452 elseif(isset($startTime['params']['TZID']) && !isset($startTime['value']['tz'])){/* Caso não tenha um tz na data mais exista um parametro TZID deve ser aplicado o timezone do TZID a data */ 450 $schedulable['startTime'] = self::date2timestamp($startTime['value']) - self::_getTzOffset('UTC',$startTime['params']['TZID'] ) . '000';453 $schedulable['startTime'] = self::date2timestamp($startTime['value']) - self::_getTzOffset('UTC',$startTime['params']['TZID'],'@'.self::date2timestamp($startTime['value'])) . '000'; 451 454 $schedulable['allDay'] = 0; 452 455 } … … 469 472 470 473 if($endTime['params']['VALUE'] === 'DATE') 471 $schedulable['endTime'] = self::date2timestamp($endTime['value']) - self::_getTzOffset('UTC',$schedulable['timezone'] ) . '000';474 $schedulable['endTime'] = self::date2timestamp($endTime['value']) - self::_getTzOffset('UTC',$schedulable['timezone'],'@'.self::date2timestamp($endTime['value'])) . '000'; 472 475 else if(isset($endTime['params']['TZID']) && !isset($endTime['value']['tz'])) /* Caso não tenha um tz na data mais exista um parametro TZID deve ser aplicado o timezone do TZID a data */ 473 $schedulable['endTime'] = self::date2timestamp($endTime['value']) - self::_getTzOffset('UTC',$endTime['params']['TZID'] ) . '000';476 $schedulable['endTime'] = self::date2timestamp($endTime['value']) - self::_getTzOffset('UTC',$endTime['params']['TZID'],'@'.self::date2timestamp($endTime['value'])) . '000'; 474 477 else 475 478 { … … 511 514 { 512 515 $schedulable['allDay'] = 1; 513 $schedulable['startTime'] = self::date2timestamp($startTime['value']) - self::_getTzOffset('UTC',$schedulable['timezone'] ) . '000';516 $schedulable['startTime'] = self::date2timestamp($startTime['value']) - self::_getTzOffset('UTC',$schedulable['timezone'],'@'.self::date2timestamp($startTime['value'])) . '000'; 514 517 } 515 518 elseif(isset($startTime['params']['TZID']) && !isset($startTime['value']['tz'])){/* Caso não tenha um tz na data mais exista um parametro TZID deve ser aplicado o timezone do TZID a data */ 516 $schedulable['startTime'] = self::date2timestamp($startTime['value']) - self::_getTzOffset('UTC',$startTime['params']['TZID'] ) . '000';519 $schedulable['startTime'] = self::date2timestamp($startTime['value']) - self::_getTzOffset('UTC',$startTime['params']['TZID'],'@'.self::date2timestamp($startTime['value'])) . '000'; 517 520 $schedulable['allDay'] = 0; 518 521 } … … 535 538 536 539 if($endTime['params']['VALUE'] === 'DATE') 537 $schedulable['endTime'] = self::date2timestamp($endTime['value']) - self::_getTzOffset('UTC',$schedulable['timezone'] ) . '000';540 $schedulable['endTime'] = self::date2timestamp($endTime['value']) - self::_getTzOffset('UTC',$schedulable['timezone'],'@'.self::date2timestamp($endTime['value'])) . '000'; 538 541 else if(isset($endTime['params']['TZID']) && !isset($endTime['value']['tz'])) /* Caso não tenha um tz na data mais exista um parametro TZID deve ser aplicado o timezone do TZID a data */ 539 $schedulable['endTime'] = self::date2timestamp($endTime['value']) - self::_getTzOffset('UTC',$endTime['params']['TZID'] ) . '000';542 $schedulable['endTime'] = self::date2timestamp($endTime['value']) - self::_getTzOffset('UTC',$endTime['params']['TZID'],'@'.self::date2timestamp($endTime['value'])) . '000'; 540 543 else 541 544 { … … 763 766 { 764 767 if($date = $component->getProperty($property , false , true )) 765 return (isset($date['params']['TZID']) && !isset($date['value']['tz'])) ? (self::date2timestamp($date['value']) - self::_getTzOffset('UTC',$date['params']['TZID'] )) . '000' : self::date2timestamp($date['value']) . '000';768 return (isset($date['params']['TZID']) && !isset($date['value']['tz'])) ? (self::date2timestamp($date['value']) - self::_getTzOffset('UTC',$date['params']['TZID'],'@'.self::date2timestamp($date['value']))) . '000' : self::date2timestamp($date['value']) . '000'; 766 769 767 770 return false;
Note: See TracChangeset
for help on using the changeset viewer.