Upgrading from 4.30. SearchModel.pf and .pt properties

3 weeks ago
Hello and thank you for looking.

I am new at this. I received a project to upgrade a NOP project that has some custom plugins that refer to a SearchModel.pf and .pt properties (Min and Max price)

Those have been removed in 4.40 and I was hoping for help with that. Has any of you folks had to update those and what would be the best approach?

Thank you!

Joe
3 weeks ago
jrogers_nop wrote:
some custom plugins that refer to a SearchModel.pf and .pt properties (Min and Max price)

There are no such files out of the box (and never were). What plugin do you mean?
3 weeks ago
Thanks for the reply,

I mean a plugin written by 3rd party developers. I was looking at the SearchModel as it was in 4.30 and there are pf and pt properties that don't exist in version 4.40. I was hoping that someone else had dealt with it and could share how they did it.

pf and pt mean price from and price to, not min and max.



3 weeks ago
The pricing filter is moved to CatalogProductsCommand model and at views, it is inside the _CatalogFilters.cshtml .

The implementation of the pricing filter is changed at the search so you may need to consider that.

For example, the price filter on the search page and the catalog pages is now(4.3 onwards) rendered from the catalogFilter section with this code.

@section CatalogFilters {
    @await Html.PartialAsync("_CatalogFilters", Model.CatalogProductsModel)
}



The price filter on 4.2 was directly inside the Search.cshtml

3 weeks ago
Thank you so much.  That did help me.

Have a great day :-)