2012-02-27 20 views
0

我使用管理生成器,有表有i18n字段,我有問題,在視圖/顯示不打印字段與i18n,但我編輯顯示i18n正確,但在show/view中不繪製這些字段。Symfony 1.4管理生成器如何我可以在視圖中顯示i18n字段

如何配置顯示i18n視野?

的模式是:

Coleccio: 
    actAs: 
    I18n: 
     fields: [descripcio] 
    columns: 
    nom:  { type: string(50), notnull: true, unique: true } 
    descripcio: { type: text, notnull: true } 
    is_historic: { type: boolean, notnull: true, default: 0 } 

Article: 
    columns: 
    coleccio_id:  { type: integer, notnull: true } 
    nom_foto: { type: string(50), notnull: true} 
    foto: { type: string(255), notnull: true }  
    relations: 
    Coleccio: { onDelete: CASCADE, local: coleccio_id, foreign: id, foreignAlias: Article_FK } 

Provincia: 
    columns: 
    nom: { type: string(50), notnull: true, unique: true } 

Punts_Venda: 
    columns: 
    provincia_id: { type: integer, notnull: true } 
    nom: { type: string(50), notnull: true } 
    direccio: { type: string(100), notnull: true } 
    ciutat: { type: string(50), notnull: true } 
    relations: 
    Provincia: { onDelete: CASCADE, local: provincia_id, foreign: id, foreignAlias: Punts_Venda_FK } 

Primera_Persona: 
    actAs:  
    I18n: 
     fields: [nom, descripcio]  
    columns: 
    name: { type: string(80), notnull: true } 
    nom: { type: string(80), notnull: true } 
    descripcio: { type: text, notnull: true } 


Imatges_Primera_Persona: 
    columns: 
    primera_persona_id: { type: integer, notnull: true } 
    nom: { type: string(50), notnull: true } 
    foto: { type: string(255), notnull: true } 
    codi: { type: string(100), notnull: false} 
    relations: 
    Primera_Persona: { onDelete: CASCADE, local: primera_persona_id, foreign: id, foreignAlias: Imatges_Primera_Persona_FK } 

Elements_Singulars: 
    actAs:  
    I18n: 
     fields: [nom, descripcio] 
    columns: 
    name: { type: string(80), notnull: true } 
    nom: { type: string(80), notnull: true } 
    descripcio: { type: text, notnull: true } 
    foto: { type: string(255), notnull: true } 

感謝問候

+0

你可以展示你的控制器,視圖和模型嗎? – denys281 2012-02-27 21:31:46

+0

我引用了schema.yml – 2012-02-29 18:17:23

回答

0

清潔symfony的緩存(symfony的CC),清理瀏覽器緩存,並在settings.yml中爲您的應用程序,試試這個:

i18n:     on 
相關問題