Admin CP: Displaying Only Relevant Fields

4 posts by 2 authors in: Forums > CMS Builder
Last Post: April 14, 2020   (RSS)

By mark99 - April 8, 2020

Is there any way in the admin interface to display only required fields when inputting data for a product? Ideally based around a category selection within the product.

So let's say I have 50 or fields for the type of products on my site and these are based around two different categories, but the categories may vary by product. For example:

Product 1:

Field Name: Category (Yes/No check mark choices for "Category 1" and "Category 2") - In this case Category 1 and 2 both needed and both selected with a radio check box.

Fields for Cat1 (all of these show)

Fields for Cat2 (all of these show)

Now I have a second Product 2 with all the same fields, but in my second product I really only need to input data for Category 1 (i.e. Category 2 is unchecked = No). Despite this CMSB will still output all the fields for both Cat1 and 2, even though I don't need to see those for Cat2. So is there any way I can tell CMSB to only show the fields that I actually need to see for a specific product?

Product 2: (Ideal solution):

Field Name: Category - In this case only "Category 1" is needed, while "Category 2" is not check marked.

Fields for Cat1 (all of these show)

Fields for Cat2 (all of these are hidden)

The reason I ask is because I have some products with c.150 fields and all the scrolling can be laborious and disorientating. So the ability to hide fields that I don't need to see would be very handy. Is this possible? Maybe some sort of logic exists that allows me to make field data entry a little cleaner?

By daniel - April 10, 2020

Hi mark99,

CMSB does not natively have this sort of functionality, though I think that something that may help is the "Tab Group" field which was added in CMSB 3.52. You could use this field to group the fields into tabs per category, which is a simple way to help organize the edit page and reduce scrolling.

Alternatively, there is a user-submitted plugin that I think would fit your need: https://www.interactivetools.com/plugins/showhide-dependent-fields-plus/. As a user-submitted plugin it's not actively maintained, but it does look like it's been updated to be compatible with recent CMSB versions.

Let me know if you have any further questions!

Thanks

Daniel
Technical Lead
interactivetools.com

By mark99 - April 14, 2020

Is there a guide for how to use the new Tab Group field. I can see how to create one, but don't quite see how to assign existing fields to it?