Changeset 63 for trunk/Modules/Event/Event.php
- Timestamp:
- Aug 3, 2021, 11:20:41 AM (3 years ago)
- Location:
- trunk
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk
- Property svn:ignore
-
old new 1 nbproject2 Config.php3 1 .settings 4 2 .project 5 3 .buildpath 4 .htaccess
-
- Property svn:ignore
-
trunk/Modules/Event/Event.php
r61 r63 3 3 include_once(dirname(__FILE__).'/Import/JoeClub.php'); 4 4 5 function GetDefaultEventFilter( $Table = '')5 function GetDefaultEventFilter(string $Table = ''): string 6 6 { 7 7 global $Config; … … 9 9 if ($Table != '') $Table = $Table.'.'; 10 10 11 return '('.$Table.'Hidden=0) AND ('.$Table.'TimeFrom > "'.TimeToMysqlDateTime(time() - $Config['EventInterval']).'")';11 return '('.$Table.'Hidden=0) AND ('.$Table.'TimeFrom > "'.TimeToMysqlDateTime(time() - (int)$Config['EventInterval']).'")'; 12 12 } 13 13 14 function ReduceSpaces( $Content)14 function ReduceSpaces(string $Content): string 15 15 { 16 16 while (strpos($Content, ' ') !== false) $Content = str_replace(' ', ' ', $Content); … … 18 18 } 19 19 20 function RemoveLines( $Content)20 function RemoveLines(string $Content): string 21 21 { 22 22 while (strpos($Content, "\n") !== false) $Content = str_replace("\n", ' ', $Content); … … 24 24 } 25 25 26 function RemoveTabs( $Content)26 function RemoveTabs(string $Content): string 27 27 { 28 28 while (strpos($Content, "\t") !== false) $Content = str_replace("\t", '', $Content); … … 34 34 public $Database; 35 35 36 function Parse( $Id = null)36 function Parse(int $Id = null): string 37 37 { 38 38 $Output = ''; … … 73 73 } 74 74 75 function Import() 75 function Import(): string 76 76 { 77 77 $this->AddedCount = 0; … … 99 99 var $Price = 0; 100 100 101 function AddIfNotExist( $TimeInterval = 0, $CompareTime = true, $CompareRemoteId = false)101 function AddIfNotExist(int $TimeInterval = 0, bool $CompareTime = true, bool $CompareRemoteId = false): int 102 102 { 103 103 $Where = '(`Description` = "'.$this->Database->real_escape_string($this->Description).'") AND '.
Note:
See TracChangeset
for help on using the changeset viewer.