Hiding manufacturers from advanced search?
Hiding manufacturers from advanced search?
Is it possible to hide some manufacturers from advanced search? I've still got Sanasonic and Bell on my site for reference (but all products are hidden)... they show up in the drop-down list of manufacturers on the advanced search page. Results are null, but it looks like the site isn't working properly if nothing comes up.
Re: Hiding manufacturers from advanced search?
Edit your ConLib/AdvanceSearchPage.ascx file and locate following code block
and then update is as below
Note if you want to exclude more manufacturers then just add an entry in following code
('Sanasonic','Bell')
for example there is another manufacturer having name Manufacturer1 then it would be
('Sanasonic','Bell','Manufacturer1')
Code: Select all
<asp:ObjectDataSource ID="ManufacturerDs" runat="server" OldValuesParameterFormatString="original_{0}"
SelectMethod="LoadForStore" TypeName="CommerceBuilder.Products.ManufacturerDataSource">
<SelectParameters>
<asp:Parameter Name="sortExpression" DefaultValue="Name" />
</SelectParameters>
</asp:ObjectDataSource>
Code: Select all
<asp:ObjectDataSource ID="ManufacturerDs" runat="server" OldValuesParameterFormatString="original_{0}"
SelectMethod="LoadForCriteria" TypeName="CommerceBuilder.Products.ManufacturerDataSource">
<SelectParameters>
<asp:Parameter Name="sqlCriteria" DefaultValue=" Name NOT IN ('Sanasonic','Bell') " />
<asp:Parameter Name="sortExpression" DefaultValue="Name" />
</SelectParameters>
</asp:ObjectDataSource>
('Sanasonic','Bell')
for example there is another manufacturer having name Manufacturer1 then it would be
('Sanasonic','Bell','Manufacturer1')
Re: Hiding manufacturers from advanced search?
Thanks.
For future releases... this should be a control in admin. Manufacturers come and go and it can take weeks to complete a supplier's products for display. Hiding/exposing these should be much simpler.
For future releases... this should be a control in admin. Manufacturers come and go and it can take weeks to complete a supplier's products for display. Hiding/exposing these should be much simpler.
Re: Hiding manufacturers from advanced search?
It seems that this edit excludes the manufacturer from the drop down option, but doesn't exclude it from the search itself. We have a store where a number of items are not assigned a manufacturer. We want to include those in the search but exclude a certain manufacturer/manufacturerid. Do you, by chance, know the best way to approach that exclusion?
Thank you,
Marc
Thank you,
Marc
Re: Hiding manufacturers from advanced search?
Yes you can do this by simply looking into object data source code of advance search and then pass 0 for manufacturer id to remove manufacturer filter. Right now search is inconclusive not exclusive so with this out of box component you can't make it ignore a single manufacturer.