daily pastebin goal
25%
SHARE
TWEET

Untitled

a guest Mar 8th, 2018 51 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. Place:
  2.   columns:
  3.     version:      {type: integer, length: 4}
  4.     informations: {type: string, length: 4000}
  5.     created_at:
  6.   actAs:
  7.     Versionable: # no options
  8.     I18n:
  9.       fields:     [ 'informations' ]
  10.      
  11. ----
  12.  
  13. Expected generated code :
  14.  
  15. /**
  16.  * This class has been auto-generated by the Doctrine ORM Framework
  17.  */
  18. abstract class BasePlace extends sfDoctrineRecord
  19. {
  20.  
  21.     public function setTableDefinition()
  22.     {
  23.         $this->setTableName('place');
  24.         $this->hasColumn('version', 'integer', 4);
  25.  
  26.         $this->hasColumn('informations', 'string', 4000);
  27.         $this->hasColumn('created_at', '', null);
  28.  
  29.  
  30.  
  31.  
  32.         $this->actAs('Versionable');
  33.         $this->actAs('I18n', array(array('fields' => 'informations')));
  34.  
  35.     }
  36.  
  37.     public function setUp()
  38.     {
  39.         $this->hasMany('Vote', array('local' => 'id',
  40.                                'foreign' => 'place_id'));
  41.  
  42.     }
  43.  
  44. }
  45.  
  46. ----
  47.  
  48. What I get :
  49.  
  50. /**
  51.  * This class has been auto-generated by the Doctrine ORM Framework
  52.  */
  53. abstract class BasePlace extends sfDoctrineRecord
  54. {
  55.  
  56.     public function setTableDefinition()
  57.     {
  58.         $this->setTableName('place');
  59.         $this->hasColumn('version', 'integer', 4);
  60.  
  61.         $this->hasColumn('informations', 'string', 4000);
  62.         $this->hasColumn('created_at', '', null);
  63.  
  64.  
  65.  
  66.  
  67.         $this->actAs('Versionable', arra));
  68.         $this->actAs('I18n', array(array('0' => ''informations'));
  69.  
  70.     }
  71.  
  72.     public function setUp()
  73.     {
  74.         $this->hasMany('Vote', array('local' => 'id',
  75.                                'foreign' => 'place_id'));
  76.  
  77.     }
  78.  
  79. }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top