Skip to content
This repository has been archived by the owner on Mar 11, 2020. It is now read-only.

[EntityBinder] Supporter les DataRow qui viennent de la recherche. #24

Open
drdeteck opened this issue Jun 12, 2014 · 2 comments
Open

Comments

@drdeteck
Copy link
Contributor

Lorsqu'on utilise un KeywordQuery dans un SearchExecutor, on nous retourne des DataTable qui contiennent des DataRow dont les clés sont des ManagedProperties. On doit supporter le mapping vers des entités sachant que nous n'avons pas le SPWeb d'origine, donc pas de SPFieldCollection.

@frederikpion
Copy link

Done, please review 6a6de19

@taoneill
Copy link
Contributor

This can't be done until we pimp out the PropertyAttribute so that we can encode the search managed property name (currently, the PropertyAttribute only allows us to map to site column InteralNames).

So, while an initial version the DataRow converters are somewhat ready (during Intact we boosted the SPEntityBinder's performance after CAML queries by relying on SPListItemCollection.ToDataTable()), DataRows that come from search results are not mapped with site column internal names (which will be what happens now). Who knows - maybe the actual DataCell values in CAML and search result contexts are completely different (in which case we may need to develop an entire new set of Search-only DataRow converters to complement the current maybe-CAML-only DataRow converter).

Also, the way you use the StraightConverter definitely isn't what we're aiming for. The correct converter should always be determined by the type of the property decorated with a PropertyAttribute (e.g. an UrlValue on an entity gets to use a UrlValueConverter, not a StraightConverter).

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants