Tag Archives: adx

How to show ratings on PowerApps portals/ Dynamics 365 portals. All you need to know

Follow my blog for more interesting topics on Dynamics 365, Portals and Power Platform. For training and consulting, write to us at info@xrmforyou.com

Recently we had this scenario where my customer was trying to configure ratings for a web page in PowerApps portal. Basically it’s a page where customers could login and rate the page content.

So here was the developer who created the web-page and also checked the box “Enable ratings”

image
image

As it occurred, everything should work fine. After all the documentation also mentions that all we need to do is to enable the ratings for the webpage. However the rating control was not visible on the web-page. Seemed like a cache issue and even after restarting the portal, it didn’t show up.

Advertisements

So if you wondering why this happens and kind of stuck, this blog will help you out. To basically show the rating on the page, you need to perform two steps:

Step 1: Enable rating on the content page

For every language a content child page is created for web page in the portal. You would find it in the localized content section of the portal.

image

You would need to open up the page for the specific language and enable ratings for the same.

image
image

Step 2 – Choose the right page template

Advertisements

Now this one can be really hard. Here we have used the Page template provided by the portal which “Page” template. It is to be noted that to show up the ratings control on the web-page, the Page template should be of type Re-write and it should point to ~/Pages/Page.aspx.

image

This can be hard to understand for consultants starting with online portal offering. But for consultants who have past experience of working with ADX controls, there used to be a UserControl called “MultiRatingControl” which we could included in any custom page we develop during those days. The Page.aspx still contains the user control and hence when we use re-write to the specified Page, the rating control shows up.

Advertisements

Old ADX documentation for reference – https://community.adxstudio.com/products/adxstudio-portals/documentation/developers-guide/web-controls/ratings-control/

Hope this helps and save you some time.

Debajit Dutta

(Dynamics MVP)

For consultation/ corporate training visit www.xrmforyou.com or reach out to us at info@xrmforyou.com

Our product offerings:

Role based views for Dynamics 365 (http://www.xrmforyou.com/role-based-views.html)

CRM-Sharepoint Attachment uploader and metadata manager (http://www.xrmforyou.com/sharepoint-integrator.html)

Record Cloner for Dynamics 365 (http://www.xrmforyou.com/record-cloner.html)

Configure redirects in Dynamics 365/ Powerapps portals.

Follow my blog for more interesting topics on Dynamics 365, Portals and Power Platform. For training and consulting, write to us at info@xrmforyou.com

Recently I was working in some portal customizations for my client and one of the requirements that came in was to place a re-direct for a portal url. If you are unware of redirects in Portals, this docs link is the perfect place to get started.

To put it short, you can create a redirect URL for an request so that when an incoming request is received for the URL, the user is redirected to a new URL/ page that you have configured.

Advertisements

So the portal developer went ahead and created a redirect url similar to the below one.

image

So basically when the user tries to navigate to the Left Nav Page, the user should be redirected to the Maintenance page. If you want the user to be redirected to an external URL, just fill in the value for Redirect URL field and you should be good. All fields are explained in docs link I shared at the start of this blog.

Advertisements

I have designed a kind of mock here for this blog post. The home page was kind of like below.

image

As it was expected, when the user clicks on the “Left Navigation Page” now, the user should be redirected to the Maintenance page as redirected as per the redirect rule.

Advertisements

However surprisingly enough, the redirection didn’t happen and the user was taken to the usual page configured for that link.

The first impression as it comes along is the redirection is not happening and if this is the first time you are working with redirects, you are bound to get confused.

To understand whether it is happening or not, here is the thumb rule to remember which I could understand purely based on my experience and not something explicitly written – “If the inbound url configured for redirect is already existing, and a web link is referring to the url, the redirect URL for that incoming URL would never fire when the link is clicked and the original page shall still be displayed”.

Advertisements

In this example – the left-nav-page url was still pointing to a valid webpage and hence the redirection never took effect.

So when does redirection really happen. If you are browsing a legacy URL which no longer exist or a webpage link which customer have saved as bookmark but the page url has been modified, redirect URL comes into the picture. If the inbound URL could not be matched with any existing URL’s, redirect rule would start taking effect if a rule is being configured for that inbound request. The Microsoft docs link infact says so – “Customers frequently want to have a simple URL that redirects to a page deeper in the site, or they want to allow for a legacy URL to be used with the site and automatically redirect to a new URL in the site.” But trust me, interpreting this and understanding can be a tough one to start with.

Advertisements

So for this example here, we just changed the URL of the page from “left-nav-page” to “left-nav-page-bak”. Now when we browse the URL – <a href=”https:///left-nav-page”>/left-nav-page”>https://<portalurl>/left-nav-page, we are redirected to the maintenance page as configured in the redirect URL.

Simple one yet tricky. Hope this helps!

Debajit Dutta

(Dynamics MVP)

For consultation/ corporate training visit www.xrmforyou.com or reach out to us at info@xrmforyou.com

Our product offerings:

Role based views for Dynamics 365 (http://www.xrmforyou.com/role-based-views.html)

CRM-Sharepoint Attachment uploader and metadata manager (http://www.xrmforyou.com/sharepoint-integrator.html)

Record Cloner for Dynamics 365 (http://www.xrmforyou.com/record-cloner.html)