AndyButland / UmbracoMapper

Mapper for Umbraco using convention based methods for mapping from Umbraco and other sources to custom view models
MIT License
41 stars 8 forks source link

Any plans to support latest Umbraco 8.8? #27

Closed john-mckillip closed 4 years ago

john-mckillip commented 4 years ago

Hi Andy. I have been playing around with the latest versions of UmbracoMapper (4.2.2) and Umbraco (8.8) and noticing some things are broken. Things I am seeing so far are mapping to BaseNodeViewModel properties is not working and also properties in a view model that are IPublishedElements are not working. IPublishedContent looks to be somewhat different now (I am comparing 8.8 with a site using Umbraco 8.6.4, which works with the latest version of UmbracoMapper).

Wondering if you have looked at 8.8 yet or if you have any plans to support future versions of Umbraco? Please let me know when you get a chance.

Thanks! -John

AndyButland commented 4 years ago

Hi John - no, I haven't tried it with 8.8 but wouldn't have expected anything to have broken (given this was a minor Umbraco release that should be backward compatible). I'll take a look though when I get a bit of time to see what needs doing.

AndyButland commented 4 years ago

Do you have some more detail about what you've found breaking please @john-mckillip?

I've got a sample V8 website that uses quite a few of the mapper features, that I've just upgraded to 8.8 and it seems to be working as expected. Maybe you could share a brief sample code of something that previously worked and now doesn't so I can replicate similar locally?

john-mckillip commented 4 years ago

Hi Andy, So, first thing is that I have 8.8 installed on a branch of my fork of UmbracoMapper and 10 of the unit tests are failing. Here are some images of what I am seeing. I have a viewmodel that has an IList of objects that are NestedContent (CarouselItems). For some reason now, IPublishedContent has properties for each of the properties of my type now in addition to the Properties collection. The same thing is happening for an IList of BaseNodeViewModel that is a content picker. ipublishedcontent error

AndyButland commented 4 years ago

There may be something else if the unit tests are failing, but can I just check you don't have models builder enabled please (the error message suggests you may have)? That could well interfere with Umbraco Mapper (and it doesn't really make sense to have it enabled if you are using the package as the means of getting strongly typed models for your views).

john-mckillip commented 4 years ago

Crap, so, I just realized that this is happening because I had ModelsBuilder, PureLive mode enabled. Once I turned that off, it is working as expected. Sorry for the false alarm.

AndyButland commented 4 years ago

Ah, that's a relief! Thanks for checking and letting me know.