Changeset 5761
- Timestamp:
- 10/30/07 12:00:05 (2 years ago)
- Files:
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/lib/plugins/sfPropelPlugin/lib/propel/builder/SfPeerBuilder.php
r3663 r5761 46 46 { 47 47 $this->addDoSelectWithI18n($script); 48 } 48 $this->addI18nMethods($script); 49 } 50 } 51 52 protected function addI18nMethods(&$script) 53 { 54 $table = $this->getTable(); 55 foreach ($table->getReferrers() as $fk) 56 { 57 $tblFK = $fk->getTable(); 58 if ($tblFK->getName() == $table->getAttribute('i18nTable')) 59 { 60 $i18nClassName = $tblFK->getPhpName(); 61 break; 62 } 63 } 64 65 $script .= " 66 67 /** 68 * Returns the i18n model class name. 69 * 70 * @return string The i18n model class name 71 */ 72 public static function getI18nModel() 73 { 74 return '$i18nClassName'; 75 } 76 "; 49 77 } 50 78

