Hi all,
it's my first time writing here.
I came across a strange bug when using a Translated Doctrine_Record
that has a many-to-many relationship which is also translated. When
submitting a form the default cuture is added to the Translations
without being sent.
---- config/doctrine/schema.yml
Ad:
actAs:
I18n:
fields: [title, description]
columns:
title: { type: string(255) }
description: { type: string(4000) }
ref: { type: string(10) }
borough_id: { type: integer }
state_id: { type: integer }
price: { type: float }
area: { type: integer }
relations:
multimedias: { class: Multimedia, refClass: AdMultimedia,
foreignAlias: ads }
Multimedia:
actAs:
I18n:
fields: [title, description]
columns:
title: { type: string(255) }
description: { type: string(4000) }
files: { type: array }
type: { type: string(100), notnull: true }
AdMultimedia:
columns:
multimedia_id: { type: integer, primary: true }
ad_id: { type: integer, primary: true }
relations:
ad: { class: Ad, type: one, foreignType: many, cascade: [delete],
local: ad_id, foreign: id, foreignAlias: admultimedias }
multimedia: { class: Multimedia, type: one, foreignType: many,
cascade: [delete], local: multimedia_id, foreign: id, foreignAlias:
admultimedias }
I think i found the problem in the sfDoctrineRecordI18nFilter class
which does not check if the field is translated. I wrote a small patch
that gets the Doctrine_Template_I18n template and checks for the
fields option and now it seems to work as expected. Is there a better
way doing this or is this a bug?
thanks for the great framework!
Miguel
--
You received this message because you are subscribed to the Google Groups
"symfony users" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/symfony-users?hl=en.