Filter Sitefinity CMS content

To apply a filter to items that come from Sitefinity CMS to SharePoint, perform the following:

  1. Click Administration » Settings » Advanced » SharepointConnector » <your site name> » List mappings » <your list mapping name> » Sitefinity CMS filter.
    Under Sitefinity CMS filter, you can create as many filter conditions, as needed, and connect them with a logical operator. The logical operator must be AND or OR. For example, you can create one filter condition – Country equals USA, and another logical condition Country equals UK. These filter conditions are linked with the logical operation that you enter in Sitefinity CMS filter.
  2. To create a filter condition, under Sitefinity CMS filter, click Filter conditions » Create new.
    Fill out the following properties:
    • In Field name, enter the field name of a Sitefinity CMS content type.
      For example, field Country.
      To check the field name click Administration » Module builder » <your module> » <your content type>.
    • In Comparison operator, enter == for equal or != for not equal.
    • In Field value, enter the filter value.
      For example, enter Canada.
    • In Default filter field value, enter one of the following:
      • If your comparison operator is ==, enter the same value that you have entered in Field value field.
      • If your logical operator is !=, enter a value that is different from the value, you have entered in Field value field.
      • This field is required, in cases of two-way synchronizations. 

        For example, if you have set a Sitefinity CMS filter Country == Canada, all items in Sitefinity CMS that have their Country equal to Canada are synchronized in SharePoint. However, if you create an item in SharePoint and leave its country field empty, this item will be automatically assigned the default value Canada. This way, when the item is synced from SharePoint to Sitefinity CMS, it will be again synced back to SharePoint. If the item is not assigned a default value and its country field remains empty, it will be synched to Sitefinity CMS with empty Country field and when it is modified in Sitefinity CMS, it cannot be synced back to SharePoint, because it does not meet the filter conditions – Country == Canada.

  3. In Field type full name, enter the full name of the Sitefinity CMS field’s type:
    • System.String for Short text, Long text, Choices.
    • System.Boolean for Yes/No.
    • System.DateTime for Date and Time.
    • System.Decimal for Number.
  4. Click Save changes.

Want to learn more?

Sign up for our free beginner training. Boost your credentials through advanced courses and certification.
Register for Sitefinity training and certification.

Was this article helpful?