[Plone-conference] Porting Products to Plone 5: reference from custom AT Type to Document breaks
keeshink at gmail.com
Tue Oct 8 20:34:55 UTC 2013
On 10/08/2013 10:27 PM, David Glick (Plone) wrote:
> On 10/5/13 2:48 PM, Kees Hink wrote:
>> Products.Archetypes' ReferenceEngine.py has a _uidFor() method that,
>> when passed a string, tries to get the UID from the uid_catalog. 
>> Problem: In Plone 5, when creating a reference from a custom content
>> type object to a Document, the target UID isn't in uid_catalog. It's
>> in portal_catalog. The custom types' UIDs are in uid_catalog. This
>> surfaced while trying out Products.Doormat on Plone 5 
>> Links between default Plone content type objects work fine.
>> What did i miss?
>>  https://github.com/collective/Products.Doormat/tree/plone5
> I see that Doormat uses Archetypes content. To be referenceable from
> Archetypes content, Dexterity content must have the referenceable
> behavior from plone.app.referenceablebehavior enabled. But we don't want
> Plone 5 to depend on Archetypes, so the types in plone.app.contenttypes
> do not use this behavior out of the box. If you don't convert Doormat
> to be Dexterity-based and you require that Dexterity content items be
> referenceable from your custom content types, I suppose you'll need to
> make sure that you enable this behavior for the core content types when
> the product is installed.
"Watch out where the huskies go,
and don't you eat that yellow snow."
More information about the Plone-conference