Changeset 6 for branches/2/translation.php
- Timestamp:
- May 8, 2008, 8:48:00 PM (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/2/translation.php
r5 r6 41 41 } 42 42 43 function GetTextGroupList($GroupId, $UserId, $Language )43 function GetTextGroupList($GroupId, $UserId, $Language, $Page, $ItemPerPage) 44 44 { 45 45 $Result = array(); 46 $DbResult = $this->Database-> select('TextGroup', '*', '`Group`='.$GroupId.' AND `User`='.$UserId.' AND `Language`='.$Language);46 $DbResult = $this->Database->query('SELECT `TextGroup`.*, (SELECT `Text` FROM `Text` WHERE `Text`.`TranslationGroup` = `TextGroup`.`Id` LIMIT 1) as `Text` FROM `TextGroup` WHERE `TextGroup`.`Group`='.$GroupId.' AND `TextGroup`.`User`='.$UserId.' AND `TextGroup`.`Language`='.$Language.' LIMIT '.($Page * $ItemPerPage).','.$ItemPerPage); 47 47 //echo($this->Database->LastQuery); 48 48 if($DbResult->num_rows > 0) … … 54 54 } 55 55 56 function GetTextGroupListCount($GroupId, $UserId, $Language) 57 { 58 $Result = array(); 59 $DbResult = $this->Database->select('TextGroup', 'COUNT(*)', '`Group`='.$GroupId.' AND `User`='.$UserId.' AND `Language`='.$Language); 60 //echo($this->Database->LastQuery); 61 $DbRow = $DbResult->fetch_array(); 62 return($DbRow[0]); 63 } 56 64 } 57 65
Note:
See TracChangeset
for help on using the changeset viewer.