# Version SVN: $Id: 01_tags_schema.yml 1927 2013-08-11 10:08:58Z sven.poeche $
propel:
  tag:
    _attributes:            { phpName: Tag, allowPkInsert: true }
    tid:                    { type: integer, size:  11, required: true, primaryKey: true, autoIncrement: true }
    status:                 { type: integer, size:  11, required: true, default: 0 } # 0=created, 1=verify, 2=illegal, 3=legal, 4=deleted
    culture:                { type: varchar, size:   7, required: true }
    name:                   { type: varchar, size: 255, required: true }
    created_at:             { type: timestamp, required: true }
    updated_at:             { type: timestamp, required: true }
    _indexes:
      t_i_name:             [name]
      t_i_name_culture:     [name, culture]


  tag_tag:
    _attributes:            { phpName: TagTag, allowPkInsert: true }
    tid:                    { type: integer, size:  11, required: true, primaryKey: true }
    tid_parent:             { type: integer, size:  11, required: true, primaryKey: true }
    _foreignKeys:
      tt_fk_tid:            { foreignTable: tag, references: [ {local: tid, foreign: tid} ] }
    _indexes:
      tt_i_tid:             [tid]
      tt_i_tid_parent:      [tid_parent]


  tag_title:
    _attributes:            { phpName: TagTitle, allowPkInsert: true }
    ttid:                   { type: integer, size:  11, required: true, primaryKey: true, autoIncrement: true }
    status:                 { type: integer, size:  11, required: true, default: 0 } # 0=created, 1=verify, 2=illegal, 3=legal, 4=deleted
    culture:                { type: varchar, size:   7, required: true }
    name:                   { type: varchar, size: 255, required: true }
    created_at:             { type: timestamp, required: true }
    updated_at:             { type: timestamp, required: true }
    _indexes:
      tti_i_name:           [name]
      tti_i_name_culture:   [name, culture]



