<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Apply JSON Filter to own custom visual in Custom Visuals Development Discussion</title>
    <link>https://community.fabric.microsoft.com/t5/Custom-Visuals-Development/Apply-JSON-Filter-to-own-custom-visual/m-p/859826#M2783</link>
    <description>&lt;P&gt;Hey,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'm trying to build a new version of our custom visual because I saw other custom visuals (apparently) applying json filters to themself. How can I achive this behaviour and apply a json filter (advanced filter api) to the visual itself which created the filter?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;regards,&lt;/P&gt;&lt;P&gt;lucmax&lt;/P&gt;</description>
    <pubDate>Thu, 28 Nov 2019 15:21:03 GMT</pubDate>
    <dc:creator>lucmax</dc:creator>
    <dc:date>2019-11-28T15:21:03Z</dc:date>
    <item>
      <title>Apply JSON Filter to own custom visual</title>
      <link>https://community.fabric.microsoft.com/t5/Custom-Visuals-Development/Apply-JSON-Filter-to-own-custom-visual/m-p/859826#M2783</link>
      <description>&lt;P&gt;Hey,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'm trying to build a new version of our custom visual because I saw other custom visuals (apparently) applying json filters to themself. How can I achive this behaviour and apply a json filter (advanced filter api) to the visual itself which created the filter?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;regards,&lt;/P&gt;&lt;P&gt;lucmax&lt;/P&gt;</description>
      <pubDate>Thu, 28 Nov 2019 15:21:03 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Custom-Visuals-Development/Apply-JSON-Filter-to-own-custom-visual/m-p/859826#M2783</guid>
      <dc:creator>lucmax</dc:creator>
      <dc:date>2019-11-28T15:21:03Z</dc:date>
    </item>
    <item>
      <title>Re: Apply JSON Filter to own custom visual</title>
      <link>https://community.fabric.microsoft.com/t5/Custom-Visuals-Development/Apply-JSON-Filter-to-own-custom-visual/m-p/860451#M2789</link>
      <description>&lt;P&gt;With help of a fellow forum member I got it to work the way I want. You need to do the following to have your visual filter itself AND others visuals:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;capabilities.json (general)&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;            "properties": {
                "filter": {
                    "type": {
                        "filter": true
                    }
                },
                "selfFilter": {
                    "type": {
                       "filter": {
                          "selfFilter": true
                       }
                    }
                 }
            }&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;ApplyJsonFilter call(s)&lt;/STRONG&gt;&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;    this._visualHost.applyJsonFilter(
      filterList,
      "general",
      "selfFilter",
      powerbi.FilterAction.merge
    );
    this._visualHost.applyJsonFilter(
      filterList,
      "general",
      "filter",
      powerbi.FilterAction.merge
    );&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Hope this helps someone else!&lt;/P&gt;</description>
      <pubDate>Fri, 29 Nov 2019 07:52:46 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Custom-Visuals-Development/Apply-JSON-Filter-to-own-custom-visual/m-p/860451#M2789</guid>
      <dc:creator>lucmax</dc:creator>
      <dc:date>2019-11-29T07:52:46Z</dc:date>
    </item>
    <item>
      <title>Re: Apply JSON Filter to own custom visual</title>
      <link>https://community.fabric.microsoft.com/t5/Custom-Visuals-Development/Apply-JSON-Filter-to-own-custom-visual/m-p/2647065#M4699</link>
      <description>&lt;P&gt;Hi, I'm also looking for a way to filter my cutom visual and not just the other visuals.&lt;/P&gt;&lt;P&gt;This query seems to be the closest I can find to what I'm lookng for.&lt;/P&gt;&lt;P&gt;I have the capabilities setup as mentioned, but not sure how and where the applyJSONFilter call is implemented.&lt;/P&gt;&lt;P&gt;Can someone assist me with the steps in order to implement this or direct me to an example as to how this is done?&lt;/P&gt;</description>
      <pubDate>Tue, 19 Jul 2022 08:45:14 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Custom-Visuals-Development/Apply-JSON-Filter-to-own-custom-visual/m-p/2647065#M4699</guid>
      <dc:creator>Charlene</dc:creator>
      <dc:date>2022-07-19T08:45:14Z</dc:date>
    </item>
    <item>
      <title>Re: Apply JSON Filter to own custom visual</title>
      <link>https://community.fabric.microsoft.com/t5/Custom-Visuals-Development/Apply-JSON-Filter-to-own-custom-visual/m-p/2647091#M4700</link>
      <description>&lt;P&gt;Hi &lt;a href="https://community.fabric.microsoft.com/t5/user/viewprofilepage/user-id/414339"&gt;@Charlene&lt;/a&gt;,&lt;/P&gt;&lt;P&gt;we are calling the applyJsonFilter in our visual.ts code when the user clicks our filter button. The filter list contains the filters we want to apply in a format like this:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;{
  $schema: "http://powerbi.com/product/schema#basic",
  ...new BasicFilter(
    {
      table: tableName
      column: columnName,
    },
    "In",
    values
  ),
}&lt;/LI-CODE&gt;&lt;P&gt;Maybe this helps.&lt;/P&gt;</description>
      <pubDate>Tue, 19 Jul 2022 08:54:53 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Custom-Visuals-Development/Apply-JSON-Filter-to-own-custom-visual/m-p/2647091#M4700</guid>
      <dc:creator>lucmax</dc:creator>
      <dc:date>2022-07-19T08:54:53Z</dc:date>
    </item>
  </channel>
</rss>

