1-888-365-2779
+1-888-365-2779
Try Now
More in this section

Forums / Developing with Sitefinity / Module Builder Front-end control Filtering

Module Builder Front-end control Filtering

2 posts, 0 answered
  1. Bernstein-Rein
    Bernstein-Rein avatar
    30 posts
    Registered:
    12 Mar 2010
    09 Apr 2012
    Link to this post
    I have a module that I created with the module builder.  I have a custom classification, products, that I need to use to limit the list.  I have found the field "AdditionalFilter" in the dynamiccontentmasterview settings.  I see that it takes some json when filtering by categories or tags.  I want to know how I can use this with my custom classification.  

    This is what the field is set to when I use a category:
    {
       "__msdisposeindex":180,
       "Title":null,
       "Id":"00000000-0000-0000-0000-000000000000",
       "QueryItems":[
          {
             "IsGroup":true,
             "Ordinal":0,
             "Join":"AND",
             "ItemPath":"_0",
             "Value":null,
             "Condition":null,
             "Name":"Categories",
             "_itemPathSeparator":"_",
             "__msdisposeindex":267
          },
          {
             "IsGroup":false,
             "Ordinal":0,
             "Join":"OR",
             "ItemPath":"_0_0",
             "Value":"967a19b4-4579-4e22-b3fb-669be270fc37",
             "Condition":{
                "FieldName":"Products",
                "FieldType":"System.Guid",
                "Operator":"Contains",
                "__msdisposeindex":268
             },
             "Name":"twinkies",
             "_itemPathSeparator":"_",
             "__msdisposeindex":269
          }
       ],
       "TypeProperties":[


       ],
       "_itemPathSeparator":"_"
    }


    I tried this and it excepted the query as valid, but it didn't filter:
    {
       "__msdisposeindex":180,
       "Title":null,
       "Id":"00000000-0000-0000-0000-000000000000",
       "QueryItems":[
          {
             "IsGroup":true,
             "Ordinal":0,
             "Join":"AND",
             "ItemPath":"_0",
             "Value":null,
             "Condition":null,
             "Name":"products",
             "_itemPathSeparator":"_",
             "__msdisposeindex":267
          },
          {
             "IsGroup":false,
             "Ordinal":0,
             "Join":"OR",
             "ItemPath":"_0_0",
             "Value":"BDDA2BD6-2139-4329-8308-B98AF9968B0B",
             "Condition":{
                "FieldName":"products",
                "FieldType":"System.Guid",
                "Operator":"Contains",
                "__msdisposeindex":268
             },
             "Name":"twinkies",
             "_itemPathSeparator":"_",
             "__msdisposeindex":269
          }
       ],
       "TypeProperties":[


       ],
       "_itemPathSeparator":"_"
    }

    I basically just changed the names and GUID.  Any thoughts would be appreciated.
  2. Bernstein-Rein
    Bernstein-Rein avatar
    30 posts
    Registered:
    12 Mar 2010
    12 Apr 2012
    Link to this post
    I wasn't ever able to get this to work.  I ended up moving the classifications to a standard category.
2 posts, 0 answered