Csla 3.8->4.5 Migration and SingleCriteria

Csla 3.8->4.5 Migration and SingleCriteria

Old forum URL: forums.lhotka.net/forums/t/12789.aspx


amselem posted on Thursday, October 30, 2014

Hello

I'm upgrading some big Csla projects from 3.8 to 4.5. I'm also testing the new MobileProxy portal for 3-layer deployment.

 I've found that those projects use the SingleCriteria as the fetch parameter, where the parameter is another BusinessObject as a Filter, something like:   SingleCriteria<CustomerList, CustomerFilter>

When using this SingleCriteria parameter with a MobileProxy dataportal it fails with a "Serialization of type object is not supported" (it works OK with LocalPortal). I though it failed because the value property of SingleCriteria is not a managed property, however it still fails after changing to a managed property.

I know SingleCriteria is deprecated and that I can pass the CustomerFilter directly without the SingleCriteria, but I'd like to ask if I anyone know how can I modify this class temporaly so it works ok with serialization so I don't have to change the code when migrating to 4.5

Thank you
Jacobo

JonnyBee replied on Monday, November 03, 2014

Hi,

Do you have a small sample project to demonstrate the issue? 

BlueScreenISU replied on Thursday, January 29, 2015

I have the exact same problem.

I cant use SingleCriteria because the value does not seem to serialize correctly: "Serialization of type object is not supported"

Passing the Value to the DataPortal_Fetch of the SingleCriteira works fine, but I DO want to use the SingleCriteria here instead the mobile object itself as a parameter.

Blue

Copyright (c) Marimer LLC