From ab6b660d8964a34fac711555c8dbc8b8e81ad241 Mon Sep 17 00:00:00 2001 From: Thomas Prouvot <35368290+tprouvot@users.noreply.github.com> Date: Thu, 9 Nov 2023 09:48:24 +0100 Subject: [PATCH] 1.20.1 (#213) Bugfix #211 --- CHANGES.md | 4 ++++ addon/manifest.json | 2 +- addon/popup.js | 8 +++++++- 3 files changed, 12 insertions(+), 2 deletions(-) diff --git a/CHANGES.md b/CHANGES.md index f9d7660e..09ec914d 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -1,5 +1,9 @@ # Release Notes +## Version 1.20.1 + +- Bugfix User selection not displaying information (for orgs without community enabled) [issue 211](https://github.com/tprouvot/Salesforce-Inspector-reloaded/issues/211) + ## Version 1.20 - Move popup arrow icon in Flow Builder because of Winter 24 UI changes [feature 200](https://github.com/tprouvot/Salesforce-Inspector-reloaded/issues/200) diff --git a/addon/manifest.json b/addon/manifest.json index 1737080c..dd895a25 100644 --- a/addon/manifest.json +++ b/addon/manifest.json @@ -1,7 +1,7 @@ { "name": "Salesforce Inspector reloaded", "description": "Productivity tools for Salesforce administrators and developers to inspect data and metadata directly from the Salesforce UI.", - "version": "1.20", + "version": "1.20.1", "icons": { "128": "icon128.png" }, diff --git a/addon/popup.js b/addon/popup.js index 535ffead..17e8f3c3 100644 --- a/addon/popup.js +++ b/addon/popup.js @@ -552,7 +552,9 @@ class AllDataBoxUsers extends React.PureComponent { } //Optimistically attempt broad query (fullQuery) and fall back to minimalQuery to ensure some data is returned in most cases (e.g. profile cannot be queried by community users) const fullQuerySelect = "SELECT Id, Name, Email, Username, UserRole.Name, Alias, LocaleSidKey, LanguageLocaleKey, IsActive, FederationIdentifier, ProfileId, Profile.Name, ContactId, IsPortalEnabled"; - const minimalQuerySelect = "SELECT Id, Name, Email, Username, UserRole.Name, Alias, LocaleSidKey, LanguageLocaleKey, IsActive, FederationIdentifier, ContactId, IsPortalEnabled"; + //TODO implement a try catch to remove non existing fields ProfileId or IsPortalEnabled (experience is not enabled) + const mediumQuerySelect = "SELECT Id, Name, Email, Username, UserRole.Name, Alias, LocaleSidKey, LanguageLocaleKey, IsActive, FederationIdentifier, ProfileId, Profile.Name, ContactId"; + const minimalQuerySelect = "SELECT Id, Name, Email, Username, UserRole.Name, Alias, LocaleSidKey, LanguageLocaleKey, IsActive, FederationIdentifier, ContactId"; const queryFrom = "FROM User WHERE Id='" + selectedUserId + "' LIMIT 1"; const compositeQuery = { "compositeRequest": [ @@ -560,6 +562,10 @@ class AllDataBoxUsers extends React.PureComponent { "method": "GET", "url": "/services/data/v" + apiVersion + "/query/?q=" + encodeURIComponent(fullQuerySelect + " " + queryFrom), "referenceId": "fullData" + }, { + "method": "GET", + "url": "/services/data/v" + apiVersion + "/query/?q=" + encodeURIComponent(mediumQuerySelect + " " + queryFrom), + "referenceId": "mediumData" }, { "method": "GET", "url": "/services/data/v" + apiVersion + "/query/?q=" + encodeURIComponent(minimalQuerySelect + " " + queryFrom),