Example #1
0
 /**
  * Set data description and main table name.
  *
  * @param DataDescription $dd Data description.
  */
 public function setDataDescription(DataDescription $dd)
 {
     parent::setDataDescription($dd);
     foreach ($dd as $fieldName => $fieldInfo) {
         if ($fieldInfo->getPropertyValue('key') === true) {
             $this->pk = $fieldName;
             $this->mainTableName = $fieldInfo->getPropertyValue('tableName');
             break;
         }
     }
 }