Ignore:
Timestamp:
07/16/12 14:34:56 (12 years ago)
Author:
acoutinho
Message:

Ticket #2951 - Correcoes de bugs e melhorias e finalizacao de codificacao

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sandbox/2.4.2-expresso1/prototype/modules/calendar/interceptors/DBMapping.php

    r6533 r6788  
    6666        if (isset($params['type'])) 
    6767            $params['type'] = self::codeAlarmType($params['type']); 
     68        else{ 
     69            $alarm = Controller::read( array('concept' => 'alarm' , 'id' => $params['id'] )); 
     70 
     71            $params['unit'] = $alarm['unit']; 
     72        } 
     73        $params['offset'] = $params['time'] * 1000; 
     74 
     75 
     76        switch( strtolower($params['unit']) ) 
     77        { 
     78            case 'd': $params['offset'] *= 24; 
     79            case 'h': $params['offset'] *= 60; 
     80            case 'm': $params['offset'] *= 60; 
     81        } 
     82         
    6883    } 
    6984 
Note: See TracChangeset for help on using the changeset viewer.