Esempio n. 1
0
 protected function setupColumnAttributes(ColumnDefinitionInterface $column, $xmlColumn)
 {
     $xmlColumn['name'] = Tools::camelcase2Underscore($column->getName());
     $type = $column->getSqlDataType();
     $size = null;
     if (false !== ($pos = strpos($type, '('))) {
         $size = trim(str_replace(['(', ')'], '', substr($type, $pos)));
         $type = substr($type, 0, $pos);
     }
     $propelType = $this->getPropelColumnType($type);
     $xmlColumn['type'] = strtoupper($propelType);
     if ($size) {
         $xmlColumn['size'] = $size;
     }
 }