Changeset 16


Ignore:
Timestamp:
Oct 17, 2007, 8:26:10 PM (17 years ago)
Author:
george
Message:

Upraveno: Zvýšení max a min rozsahu pro použití databázového 64bit typu BIGINT.

Files:
2 edited

Legend:

Unmodified
Added
Removed
  • graph.php

    r14 r16  
    3636
    3737// Calculate total max, avg, min value
    38 $MaxValue = -1000000000;
     38$MaxValue = -1000000000000000000;
    3939$AvgValue = 0;
    40 $MinValue = 1000000000;
     40$MinValue = 1000000000000000000;
    4141foreach($Points as $Index => $Item)
    4242{
     
    181181  imagettftext($Image, $FontSize, 0, $Width-194, 14, $Green, $FontFile, "Avg.  ".AddPrefixMultipliers($AvgValue, $Measure['Unit']));
    182182  imagettftext($Image, $FontSize, 0, $Width-294, 14, $Blue, $FontFile, "Min.  ".AddPrefixMultipliers($MinValue, $Measure['Unit']));
    183   imagestring($Image, 2, 70, 20, 'Vygenerováno za '.$GenerationTime.' sekund', $Black);
     183  //imagestring($Image, 2, 70, 20, 'Vygenerováno za '.$GenerationTime.' sekund', $Black);
    184184  //imagestring($Image, 2, 50, 30, 'Level: '.$Level, $Black);
    185185
  • stat_functions.php

    r15 r16  
    123123        ($LastValue['continuity'] == 1) and ($Continuity == 1))
    124124      {
    125         echo('s');
     125        //echo('s');
    126126        $Database->update($Measure['DataTable'], 'time="'.$LastValue['time'].'" AND level=0 AND measure='.$Measure['Id'], array('time' => 'NOW()'));
    127127      } else
     
    184184  global $ValueTypes;
    185185 
    186   $NewValue = array('min' => +10000000000, 'avg' => 0, 'max' => -10000000000);
     186  $NewValue = array('min' => +1000000000000000000, 'avg' => 0, 'max' => -1000000000000000000);
    187187 
    188188  // Trim outside parts
Note: See TracChangeset for help on using the changeset viewer.