Tip #1220: Accessibility in portals

Have you ever tried navigating your portal without a mouse? Or switched the monitor off (yes, all of them) and try to figure out where you are using nothing but a screen reader? If you have successfully done that, my hat is off to you. It’s called accessibility.

Those of you working on the projects for the governments and, to a lesser extent, large enterprises, are probably familiar with the item on a tender checklist.

Good news is that the out-of-the-box start portals (Custom portal, Community portal, Partner portal, Customer portal, Employee self-service portal) are accessible. What does it mean and how do you measure it? There are standards, of course, and there are reports on how portals (and Dynamics 365 product line up in general) are compliant with those.

You can retrieve specific Dynamics 365 Portals conformance reports by searching for “Dynamics 365 Customer Engagement” at Microsoft Accessibility Conformance Reports. These reports cover the following standards:

  • EN 301 549 – the European standard that sets out accessibility requirements for information and communication technology procured by the public sector.
  • Section 508. Under Section 508 of the Rehabilitation Act, US Government agencies must give employees with disabilities and members of the public access to information that is comparable to the access available to others.
  • WCAG. Web Content Accessibility Guidelines published and maintained by W3C.

Of course, these reports cover only out-of-the-box portals. When you customize and extend any of those, you should ensure that the portal remains accessible after any customization or changes.

(Cover photo by Yomex Owo on Unsplash)

Tip #1219: Root and content pages will make you unemployed

You crafted a new page in your beloved portal. It’s a work of art. Apple will hire you as a chief designer when they see the page. You change Publishing State from Draft to Published and… Nothing. You wait 5 seconds, F5, still nothing. Ctrl-F5. Nope. Sign in as admin, navigate to /_services/about, Clear Cache, sign out. Refresh. Not there. Sign in into admin center, restart the portal. Still bupkis. Turn the portal off then turn it back on. Slowly it comes back to life. Page? Nowhere to be seen. Somebody please put me out of this misery.

Now that you’ve missed that job opportunity, let’s take a look at what’s going on.

When you create a web page, at least two records get created: an information (or root) page and a content page (information page has Is Root property set to Yes).

Content page is pretty much a copy of the information page but now it has its own life. When you modify properties on the information page, they are not in sync with the content page except for a Partial URL and Page Template properties. The rest of the properties , including Publishing State are independent.

Guess which page is rendered when you access the portal? Yep, the content one. Now you see what happened?

SNAGHTML1a76c9b

Lesson: always modify the properties of the content page not the information (root) one.

Why all these pain? Parlez-vous francais, anyone? That’s right, multi-lingual stuff. That’s why I said “at least 2 records”. In fact it will be number of languages + 1. Your content pages will be in different languages, with different content, published at different times, if at all. So that you can have fun. Like this:

image

(Cover photo by Mohit Tomar on Unsplash)

Tip #1218: Suppress headers and footers in portals

Dynamics 365 Portals, based on Bootstrap, are very flexible when it comes to the web site and individual page layout. To create consistent look and feel the Website record defines header and footer templates.

image

And the footer looks like this:

image

I was working on a site where I didn’t need a footer at all so I cleared Footer Template field. And I got this:

SNAGHTML1daeb057

What the?!

Yes, folks, a default template is rendered, whatever that is. To suppress header and/or footer, create a blank Web Template, something like

{% comment %}
  This template has been deliberately left blank
{% endcomment %}

and select that template on your Website record. The results are stunning. I don’t even have a screenshot because it’s, well, blank.

Note: if you disable header, it’ll be up to you to render the search box, sign-in/out control, and a language selector elsewhere, because that’s what the default header renders.

(Cover photo by Jeffrey Lin on Unsplash)

Tip #1216: New form designer preview is now available in North America

At the end of 2018, Microsoft announced a preview of the new WYSIWYG form designer. This new maker experience looks like the Unified Interface, making form configuration look and feel like it does to end users.

Unfortunately for those of us in North America, the preview was not available in our environments. Now it is.

To try the new form designer preview, go to powerapps.com.

  1. Verify that you are in the right environment.
  2. Click data
  3. Select the desired entity
  4. Click the forms tab
  5. Click the (…) next to the form name
  6. Select “Edit Form (Preview)”

You can now enjoy the new form designer experience.

(Cover Photo by rawpixel on Unsplash )

Tip #1215: Automatically manage folder tracking

Public service announcement: we are back from the Merry Year hiatus and straight to tipping.

Tracking folders is a cool feature where you can configure an Exchange folder to be a tracked folder and optionally link it to a Dynamics 365 record so that any email landing in that folder will be automatically tracked and Regarding will be set to that record.

This is great if I want to follow specific records, for example, a large opportunity.

image

Create a subfolder in the Inbox

SNAGHTMLb783c16

Open Personal Options > Email tab > Configure Folders Tracking Rules

image

So now I would shove any correspondence that may be related into that folder and let the system do the work.

This is all nice and emails are, indeed, tracked. But what happens when the opportunity is closed? Well, nothing. Wouldn’t it be nice if we can “untrack” the folder? If for nothing else then for the 25 tracked folders limit – I want to have some space for the new opportunities (and no, I didn’t win the one above).

Enter Flow. Why not workflow? Because Flow has two distinctive advantages:

  1. It can actually delete records
  2. It can access tracking folders configuration records  – Mailbox Auto Tracking Folders (mailboxtrackingfolders) entity

The flow logic is as following. Just one screenshot, people, as it fits on one screen!

image

  1. Trigger on when opportunity record Updated, filter on statecode. Technically, should add an extra step validating that opportunity has been indeed closed.
  2. Get all mailbox tracking folders where Regarding is equal to that opportunity. Folder tracking is a per-user feature so multiple users can be tracking the same opportunity.
  3. Loop through returned records and nuke them.

Tested and tracked folder is as good as gone!

Wouldn’t it be nice if we could also create tracking folder configuration if certain conditions are met, like opportunity value > $1,000,000? Unfortunately, configuring tracking folder requires knowledge of Exchange folder id and I’m yet to figure out how to find that easily. Drop me a line if you figured that out!

(Cover photo by Omid Kashmari on Unsplash)

Tip #1214: Add “what’s new” to unified interface

We use activity feeds and the “what’s new” dashboard in D365 classic UI to see a feed of posts in the system. This doesn’t show up in unified interface–how can we use the activity feed wall in unified interface?

Keep me posted

Dear posted,

The activity feed wall is replaced in unified interface by the timeline control. On a dashboard (like the Sales Activity Social Dashboard) add the timeline control. If you want it to only display posts and not other types of activities, change show these modules to “show selected” and select “Posts”.

You will now see the activity feed wall on your dashboard.

(Cover photo by Waldemar Brandt on Unsplash)

Tip #1213: When you pushed that button simplified

In tip #1213 we walked you through a long winded way finding out where and when the Flow button was pushed. It involved using lattitude and longitude of the user’s location and calling Bing Maps API.

As it turns out, if you are only after the local time, there is a much simpler method. When a flow is invoked using manual button, trigger tokens contain, among other values, local date and time at the location where the button was invoked. These values are accessible using the following expressions:

  • Date as triggerBody()['key-button-date']
  • Timestamp as triggerBody()['key-button-timestamp']

The entire brouhaha can now be reduced to:

Flow telling the local time

The only gotcha is that the property key-button-timestamp does not exist when the flow is run from the browser, it is only available on a mobile device. When testing, do at least a single run using a mobile device and then re-use this test run data in subsequent testing.

(Cover photo by Luke Chesser on Unsplash)

Tip #1212: Where are my apps?

I attended your webinar about model driven apps.
Our sandbox has been upgraded to V 9.1 and our production environment will be upgraded tomorrow.  In preparation for this, I have created and published an app .  I have added the appropriate security roles to the app, but it is still not showing up for selection for them on their mobile app. It says “we can’t find any apps for your role. To check for recently added apps, select refresh.”

Laura M

When Microsoft releases new versions of Dynamics 365, sometimes they introduce new security role permissions. If you are using custom security roles created prior to version 8.2, they likely do not have the required permission to see model driven apps.

Update the users’ security roles, ensuring that they have read privilege for model driven apps on the security role Customization tab. 

(Cover photo by Daniel Jensen on Unsplash)

Tip #1211: Mixing entities to build complex views

The trick to get developers to get your job done for free is to challenge them. Which is exactly what Steve “Mr SMB” Mordue has done.

Challenge

I am trying to create a view of activities, that will show all activities performed by anyone on my team. I know I can create specific view that filters that way, but I don’t want to create one for each of the 9 teams. I want to recognize the team I am on and show it.

Accepted

A bunch of linked entities later, Andrii “Granny’s Moonshine” Butenko had a solution:

image

And that would have been the end of it but then the discussion went something like this:

– I need me, my team, and all members of that team

– So records can belong to Team as well?

– Yes

– Aah, crap

So the challenge now was to combine the expression above with the condition “Owner Equals Current User’s Team” using OR operator. Except that visual view builder would have none of it. At some point Jonas “FXB” Rapp was summoned and solved the problem between brushing his incisors and molars. Readers digest:

  1. Build a view with the columns that you need and the condition above.
  2. Fire up XrmToolBox, load that view into View Designer then start editing query in FetchXML Builder.
  3. Mix conditions on attributes from different entities in the builder.
  4. Test your fetchxml then update your view.
  5. Done! (Note: the view will work but you won’t be able to edit that view in Advanced Find).

Winning FetchXML:

<fetch mapping="logical" output-format="xml-platform" 
        version="1.0" distinct="true" >
  <entity name="activitypointer" >
    <attribute name="activitytypecode" />
    <attribute name="subject" />
    <attribute name="statecode" />
    <attribute name="prioritycode" />
    <attribute name="modifiedon" />
    <attribute name="activityid" />
    <attribute name="instancetypecode" />
    <attribute name="community" />
    <attribute name="ownerid" />
    <attribute name="owneridname" />
    <filter type="or" >
      <condition attribute="ownerid" 
                 operator="eq-useroruserteams" />
      <condition attribute="systemuserid" 
                 entityname="tm" 
                 operator="eq-useroruserteams" />
    </filter>
    <link-entity name="systemuser" to="owninguser" 
              from="systemuserid" link-type="outer" >
      <link-entity name="teammembership" 
                 to="systemuserid" from="systemuserid" 
                 link-type="outer" >
        <link-entity name="team" 
                   to="teamid" from="teamid" 
                   link-type="outer" >
          <link-entity name="teammembership" 
                       to="teamid" from="teamid" 
                       alias="tm" link-type="outer" />
        </link-entity>
      </link-entity>
    </link-entity>
  </entity>
</fetch>

I was dead last in this contest – my own version wouldn’t even work. As it turns out, link-type="outer" is important, don’t leave home without it.

(Cover photo by Bernard Tuck on Unsplash)