Skip to content

Commit 391e426

Browse files
authored
Merge pull request #252 from SalesforceLabs/Lithium_hotfix
Lithium hotfix
2 parents 5aa0421 + fed7d46 commit 391e426

File tree

15 files changed

+60
-36
lines changed

15 files changed

+60
-36
lines changed

build/bin/OrgCheck_SR.zip

180 Bytes
Binary file not shown.

build/src/javascript/orgcheck/OrgCheck.Datasets.js

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -723,6 +723,12 @@ OrgCheck.Datasets = {
723723
const records = MAP_HANDLER.newMap();
724724
if (policies) {
725725
policies.forEach(r => {
726+
if (typeof r.profile !== 'string') {
727+
// Metadata could return profile pwd policy for deleted profile
728+
// In this case, r.profile will be equal to { $: {xsi:nil: 'true'} }
729+
// And we expect r.profile to be the name of the profile so....
730+
return;
731+
}
726732
const item = {
727733
forgotPasswordRedirect: (r.forgotPasswordRedirect === 'true'),
728734
lockoutInterval: parseInt(r.lockoutInterval),

build/src/javascript/orgcheck/OrgCheck.Salesforce.js

Lines changed: 10 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,11 @@
33
*/
44
OrgCheck.Salesforce = {
55

6-
AbstractProcess: function() {
6+
AbstractProcess: function(connection) {
7+
if (connection && connection.cache) {
8+
// Org Check has its own cache
9+
connection.cache.clear();
10+
}
711
const private_events = {
812
'error': (error) => { console.error(error); }
913
};
@@ -19,7 +23,7 @@ OrgCheck.Salesforce = {
1923
},
2024

2125
SoqlProcess: function(connection, queries, returnAsMap, casesafeid) {
22-
OrgCheck.Salesforce.AbstractProcess.call(this);
26+
OrgCheck.Salesforce.AbstractProcess.call(this, connection);
2327
const that = this;
2428
this.run = () => {
2529
try {
@@ -82,7 +86,7 @@ OrgCheck.Salesforce = {
8286
},
8387

8488
GlobalDescribeProcess: function(connection) {
85-
OrgCheck.Salesforce.AbstractProcess.call(this);
89+
OrgCheck.Salesforce.AbstractProcess.call(this, connection);
8690
const that = this;
8791
this.run = () => {
8892
try {
@@ -105,7 +109,7 @@ OrgCheck.Salesforce = {
105109
},
106110

107111
DescribeProcess: function(connection, secureBindingVariable, casesafeid, dapi, sobjectPackage, sobjectDevName) {
108-
OrgCheck.Salesforce.AbstractProcess.call(this);
112+
OrgCheck.Salesforce.AbstractProcess.call(this, connection);
109113
const that = this;
110114
const sobjectDevNameNoExt = sobjectDevName.split('__')[(sobjectPackage && sobjectPackage !== '') ? 1 : 0];
111115
this.run = () => {
@@ -284,7 +288,7 @@ OrgCheck.Salesforce = {
284288
},
285289

286290
MetadataProcess: function(connection, metadatas) {
287-
OrgCheck.Salesforce.AbstractProcess.call(this);
291+
OrgCheck.Salesforce.AbstractProcess.call(this, connection);
288292
const that = this;
289293
this.run = () => {
290294
try {
@@ -347,7 +351,7 @@ OrgCheck.Salesforce = {
347351
},
348352

349353
MetadataAtScaleProcess: function(connection, type, ids, byPasses) {
350-
OrgCheck.Salesforce.AbstractProcess.call(this);
354+
OrgCheck.Salesforce.AbstractProcess.call(this, connection);
351355
const that = this;
352356
this.run = () => {
353357
try {

build/src/javascript/orgcheck/OrgCheck.VisualComponents.js

Lines changed: 27 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -367,7 +367,7 @@ OrgCheck.VisualComponents = {
367367

368368
/**
369369
* Message
370-
* @param configuration Object must contain 'modalContentId', 'modalId', 'warningMessagesId'
370+
* @param configuration Object must contain 'modalContentId', 'modalImageId', 'modalId', 'warningMessagesId'
371371
*/
372372
MessageHandler: function (configuration) {
373373

@@ -378,14 +378,16 @@ OrgCheck.VisualComponents = {
378378
* @param error
379379
* @param displayIssueInformation
380380
* @param salesforceInfo
381+
* @param imageTitle
382+
* @param textTitle
381383
*/
382-
this.showError = function (error, displayIssueInformation, salesforceInfo) {
384+
this.showError = function (error, displayIssueInformation, salesforceInfo, imageTitle, textTitle) {
383385
if (error) {
384386
try {
385387
private_errors.push(error);
386388
let commonHTML = '<h1 class="slds-text-heading--small"></h1><br /><br />';
387389
if (displayIssueInformation === true) {
388-
commonHTML += 'Please go <a href="https://github.com/VinceFINET/OrgCheck/issues" '+
390+
commonHTML += 'Please go <a href="https://github.com/SalesforceLabs/OrgCheck/issues" '+
389391
'target="_blank" rel="external noopener noreferrer">here</a> and log an issue with the following information. <br /'+
390392
'><br />';
391393
}
@@ -425,8 +427,9 @@ OrgCheck.VisualComponents = {
425427
informationHTML += '<br />';
426428
});
427429
private_show_modal(
428-
'Oh no, Org Check had an error!',
429-
commonHTML + informationHTML.replace(/https:\/\/[^\/]*/g, '')
430+
textTitle || 'Oh no, Org Check had an error!',
431+
commonHTML + informationHTML.replace(/https:\/\/[^\/]*/g, ''),
432+
imageTitle || '/img/msg_icons/error32.png'
430433
);
431434
} catch (e) {
432435
// Just in case we have an error during the showError!!
@@ -439,9 +442,10 @@ OrgCheck.VisualComponents = {
439442
* Show dialog box with a title and content
440443
* @param title String title
441444
* @param content String html or NodeElement representing the content of the box
445+
* @param image the icon or image to show on this modal (optional)
442446
*/
443-
this.showModal = function (title, element) {
444-
private_show_modal(title, element);
447+
this.showModal = function (title, element, image) {
448+
private_show_modal(title, element, image);
445449
};
446450

447451
/**
@@ -477,9 +481,11 @@ OrgCheck.VisualComponents = {
477481

478482
/**
479483
* Show the modal dialog box
484+
* @param title
480485
* @param element Html element to show in the modal box
486+
* @param image Optional image to show in the modal box on the left
481487
*/
482-
function private_show_modal(title, element) {
488+
function private_show_modal(title, element, image) {
483489
const header = document.getElementById(configuration.modalTitleId);
484490
const content = document.getElementById(configuration.modalContentId);
485491
header.textContent = title;
@@ -493,6 +499,19 @@ OrgCheck.VisualComponents = {
493499
} else {
494500
content.appendChild(element);
495501
}
502+
if (image) {
503+
const imagediv = document.getElementById(configuration.modalImageId);
504+
if (imagediv.firstElementChild) {
505+
imagediv.removeChild(imagediv.firstElementChild);
506+
}
507+
if (typeof image == 'string') {
508+
const img = document.createElement('img');
509+
img.src = image;
510+
imagediv.appendChild(img);
511+
} else {
512+
imagediv.appendChild(image);
513+
}
514+
}
496515
document.getElementById(configuration.modalId).style.display = 'block';
497516
}
498517
},

build/src/javascript/orgcheck/OrgCheck.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,7 @@
6767
modalContentId: setup.htmlModalContentTagId,
6868
modalId: setup.htmlModalTagId,
6969
modalTitleId: setup.htmlModalTitleTagId,
70+
modalImageId: setup.htmlModalImageTagId,
7071
warningMessagesId: setup.htmlWarningMessagesTagId
7172
});
7273

@@ -92,7 +93,7 @@
9293
data: d.data
9394
}
9495
};
95-
MSG_HANDLER.showError(error, false);
96+
MSG_HANDLER.showError(error, false, SALESFORCE_HANDLER, '/img/icon/profile32.png', 'WatchDog stopped you here... Waouf!');
9697
}
9798
}
9899
switch (d.type) {

build/src/labels/Translation-FR-copyandpasted.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
"<customLabels><name>OrgCheck_Automations_Description_CL</name><label>Cette page vous donne un aperçu de vos &lt;b&gt;Automations&lt;&#x2F;b&gt; en trois onglets:&lt;br &#x2F;&gt;&lt;ul class&#x3D;&quot;slds-list_dotted&quot;&gt;&lt;li&gt;Le premier onglet appelé &lt;b&gt;workflows&lt;&#x2F;b&gt; est une liste tabulaire des workflows (actif ou non) t&lt;&#x2F;li&gt;&lt;li&gt;Le deuxième onglet appelé &lt;b&gt;Builders de processus&lt;&#x2F;b&gt; est une liste tabulaire des constructeurs de processus (actifs ou non)&lt;&#x2F;li&gt;&lt;li&gt;Le troisième onglet appelé &lt;b&gt;flux&lt;&#x2F;b&gt; est une liste tabulaire des flux (quel que soit leur type)&lt;&#x2F;li&gt;&lt;&#x2F;ul&gt;&lt;br &#x2F;&gt; </label></customLabels>
44
<customLabels><name>OrgCheck_Batches_Description_CL</name><label>Cette page vous donne un aperçu de vos &lt;b&gt;lots&lt;&#x2F;b&gt; en trois onglets:&lt;br &#x2F;&gt;&lt;ul class&#x3D;&quot;slds-list_dotted&quot;&gt;&lt;li&gt;Le premier onglet appelé &lt;b&gt;Classes de planification non encore planifiées&lt;&#x2F;b&gt; vous donne la liste des classes qui pourraient être supprimées car non planifiée dans cet org&lt;&#x2F;li&gt;&lt;li&gt;Le deuxième onglet appelé &lt;b&gt;Jobs Apex&lt;&#x2F;b&gt; est une liste tabulaire des travaux Apex d&#39;hier qui a réellement terminé ou échoué (pas les en attente).&lt;&#x2F;li&gt;&lt;li&gt;Le troisième onglet appelé &lt;b&gt;Jobs programmés&lt;&#x2F;b&gt; est une liste tabulaire des tâches croisées&lt;&#x2F;li&gt;&lt;&#x2F;ul&gt;&lt;br &#x2F;&gt; </label></customLabels>
55
<customLabels><name>OrgCheck_Home_Section1_Text2_CL</name><label> &lt;b&gt;Problèmes ou nouvelles idées?&lt;&#x2F;b&gt;&lt;br &#x2F;&gt; Suivez-les sur&lt;br &#x2F;&gt; &lt;a href&#x3D;&quot;https:&#x2F;&#x2F;sfdc.co&#x2F;OrgCheck-Backlog&quot; target&#x3D;&quot;_blank&quot; rel&#x3D;&quot;external noopener noreferrer&quot;&gt;sfdc.co&#x2F;OrgCheck-Backlog&lt;&#x2F;a&gt; &lt;br &#x2F;&gt; &lt;br &#x2F;&gt; &lt;b&gt;Vous voulez discuter avec d&#39;autres utilisateurs?&lt;&#x2F;b&gt;&lt;br &#x2F;&gt; Rejoignez-nous sur notre Slack à &lt;a href&#x3D;&quot;https:&#x2F;&#x2F;sfdc.co&#x2F;OrgCheck-Community&quot; target&#x3D;&quot;_blank&quot; rel&#x3D;&quot;external noopener noreferrer&quot;&gt;invitation&lt;&#x2F;a&gt; &lt;br &#x2F;&gt; &lt;br &#x2F;&gt; &lt;b&gt;Médias sociaux&lt;&#x2F;b&gt;&lt;br &#x2F;&gt; Réagissez à nos messages sur &lt;a href&#x3D;&quot;https:&#x2F;&#x2F;www.linkedin.com&#x2F;company&#x2F;OrgChecksfdc&quot; target&#x3D;&quot;_blank&quot; rel&#x3D;&quot;external noopener noreferrer&quot;&gt;LinkedIn&lt;&#x2F;a&gt; et sur &lt;a href&#x3D;&quot;https:&#x2F;&#x2F;Twitter.com&#x2F;OrgChecksfdf&quot; target&#x3D;&quot;_blank&quot; rel&#x3D;&quot;external noopener noreferrer&quot;&gt;Twitter&lt;&#x2F;a&gt; !&lt;br &#x2F;&gt; </label></customLabels>
6-
<customLabels><name>OrgCheck_Home_Section2_Text3_CL</name><label> &lt;b&gt;Org Check est gratuit, mais n&#39;est pas un produit officiel Salesforce.&lt;&#x2F;b&gt; Org Check n&#39;a pas été officiellementtesté ou documenté. Le support Salesforce n&#39;est pas disponible pour Org Check. Demandes d&#39;assistance pour Org Checkdevrait être dirigé vers GitHub sur &lt;a href&#x3D;&quot;https:&#x2F;&#x2F;github.com&#x2F;vincefinet&#x2F;OrgCheck&#x2F;issues&quot; target&#x3D;&quot;_blank&quot; rel&#x3D;&quot;external noopener noreferrer&quot;&gt;https:&#x2F;&#x2F;github.com&#x2F;vincefinet&#x2F;OrgCheck&#x2F;issues&lt;&#x2F;a&gt; .Le code source pour Org Check peut être trouvé sur &lt;a href&#x3D;&quot;https:&#x2F;&#x2F;github.com&#x2F;vincefinet&#x2F;OrgCheck&quot; target&#x3D;&quot;_blank&quot; rel&#x3D;&quot;external noopener noreferrer&quot;&gt;https:&#x2F;&#x2F;github.com&#x2F;vincefinet&#x2F;OrgCheck&lt;&#x2F;a&gt; Selon des conditions de licence distinctes et différentes.</label></customLabels>
6+
<customLabels><name>OrgCheck_Home_Section2_Text3_CL</name><label> &lt;b&gt;Org Check est gratuit, mais n&#39;est pas un produit officiel Salesforce.&lt;&#x2F;b&gt; Org Check n&#39;a pas été officiellementtesté ou documenté. Le support Salesforce n&#39;est pas disponible pour Org Check. Demandes d&#39;assistance pour Org Checkdevrait être dirigé vers GitHub sur &lt;a href&#x3D;&quot;https:&#x2F;&#x2F;github.com&#x2F;SalesforceLabs&#x2F;OrgCheck&#x2F;issues&quot; target&#x3D;&quot;_blank&quot; rel&#x3D;&quot;external noopener noreferrer&quot;&gt;https:&#x2F;&#x2F;github.com&#x2F;SalesforceLabs&#x2F;OrgCheck&#x2F;issues&lt;&#x2F;a&gt; .Le code source pour Org Check peut être trouvé sur &lt;a href&#x3D;&quot;https:&#x2F;&#x2F;github.com&#x2F;SalesforceLabs&#x2F;OrgCheck&quot; target&#x3D;&quot;_blank&quot; rel&#x3D;&quot;external noopener noreferrer&quot;&gt;https:&#x2F;&#x2F;github.com&#x2F;SalesforceLabs&#x2F;OrgCheck&lt;&#x2F;a&gt; Selon des conditions de licence distinctes et différentes.</label></customLabels>
77
<customLabels><name>OrgCheck_XActiveMembers_CL</name><label>{0} membres actifs</label></customLabels>
88
<customLabels><name>OrgCheck_XInactiveMembers_CL</name><label>{0} membres inactifs</label></customLabels>
99
<customLabels><name>OrgCheck_XtoY_CL</name><label>{0} à {1}</label></customLabels>

build/src/labels/Translation-JP-copyandpasted.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
"<customLabels><name>OrgCheck_Automations_Description_CL</name><label>このページでは、3つのタブで &lt;b&gt;自動化&lt;&#x2F;b&gt; の概要を示します。&lt;br &#x2F;&gt;&lt;ul class&#x3D;&quot;slds-list_dotted&quot;&gt;&lt;li&gt;&lt;b&gt;ワークフロー&lt;&#x2F;b&gt; と呼ばれる最初のタブは、ワークフロー(アクティブかどうか)の表のリストです。&lt;li&gt;&lt;b&gt;Process Builders&lt;&#x2F;b&gt; という2番目のタブは、プロセスビルダー(アクティブかどうか)の表形式リストです&lt;&#x2F;li&gt;&lt;li&gt;&lt;b&gt;flows&lt;&#x2F;b&gt; と呼ばれる3番目のタブは、フローの表形式リストです(タイプに関係なく)&lt;&#x2F;li&gt;&lt;&#x2F;ul&gt;&lt;br &#x2F;&gt; </label></customLabels>
44
<customLabels><name>OrgCheck_Batches_Description_CL</name><label>このページでは、3つのタブで &lt;b&gt;バッチ&lt;&#x2F;b&gt; の概要を示します。&lt;br &#x2F;&gt;&lt;ul class&#x3D;&quot;slds-list_dotted&quot;&gt;&lt;li&gt;まだスケジュールされていない &lt;b&gt;スケジュール可能なクラスと呼ばれる最初のタブ&lt;&#x2F;b&gt; は、この組織でスケジュールされていないため削除できるクラスのリストを提供しています&lt;&#x2F;li&gt;&lt;li&gt;&lt;b&gt;apex jobs&lt;&#x2F;b&gt; という2番目のタブは、昨日から実際に完了または故障したapexジョブの表のリストです(保留中のものではありません)。&lt;&#x2F;li&gt;&lt;li&gt;&lt;b&gt;スケジュールされたジョブ&lt;&#x2F;b&gt; と呼ばれる3番目のタブは、クローニングされたタスクの表のリストです&lt;&#x2F;li&gt;&lt;&#x2F;ul&gt;&lt;br &#x2F;&gt; </label></customLabels>
55
<customLabels><name>OrgCheck_Home_Section1_Text2_CL</name><label>&quot; &lt;b&gt;問題や新しいアイデア?&lt;&#x2F;b&gt;&lt;br &#x2F;&gt; でそれらを追跡します&lt;br &#x2F;&gt; &lt;a href&#x3D;&quot;https:&#x2F;&#x2F;sfdc.co&#x2F;OrgCheck-Backlog&quot; target&#x3D;&quot;_blank&quot; rel&#x3D;&quot;external noopener noreferrer&quot;&gt;sfdc.co&#x2F;OrgCheck-Backlog&lt;&#x2F;a&gt; &lt;br &#x2F;&gt; &lt;br &#x2F;&gt; &lt;b&gt;他のユーザーとチャットしたいですか?&lt;&#x2F;b&gt;&lt;br &#x2F;&gt; これでSlackにご参加ください &lt;a href&#x3D;&quot;https:&#x2F;&#x2F;sfdc.co&#x2F;OrgCheck-Community&quot; target&#x3D;&quot;_blank&quot; rel&#x3D;&quot;external noopener noreferrer&quot;&gt;Invitation&lt;&#x2F;a&gt; &lt;br &#x2F;&gt; &lt;br &#x2F;&gt; &lt;b&gt;ソーシャルメディア&lt;&#x2F;b&gt;&lt;br &#x2F;&gt; 好きな投稿を共有します &lt;a href&#x3D;&quot;https:&#x2F;&#x2F;www.linkedin.com&#x2F;company&#x2F;OrgChecksfdc&quot; target&#x3D;&quot;_blank&quot; rel&#x3D;&quot;external noopener noreferrer&quot;&gt;linkedin&lt;&#x2F;a&gt; そしてオン &lt;a href&#x3D;&quot;https:&#x2F;&#x2F;twitter.com&#x2F;OrgChecksfdf&quot; target&#x3D;&quot;_blank&quot; rel&#x3D;&quot;external noopener noreferrer&quot;&gt;twitter&lt;&#x2F;a&gt; !&lt;br &#x2F;&gt; &quot;</label></customLabels>
6-
<customLabels><name>OrgCheck_Home_Section2_Text3_CL</name><label> &lt;b&gt;Org Check は自由に使用できますが、公式のSalesforce製品ではありません。&lt;&#x2F;b&gt; Org Checkは正式にはありませんテストまたは文書化。 SalesforceサポートはOrg Checkでは利用できません。 Org Check のリクエストをサポートします &lt;a href&#x3D;&quot;https:&#x2F;&#x2F;github.com&#x2F;vincefinet&#x2F;OrgCheck&#x2F;issues&quot; target&#x3D;&quot;_blank&quot; rel&#x3D;&quot;external noopener noreferrer&quot;&gt;https:&#x2F;&#x2F;github.com&#x2F;vincefinet&#x2F;OrgCheck&#x2F;issues&lt;&#x2F;a&gt; でgithubに指示する必要があります。Org Check のソースコードは、 &lt;a href&#x3D;&quot;https:&#x2F;&#x2F;github.com&#x2F;vincefinet&#x2F;OrgCheck&quot; target&#x3D;&quot;_blank&quot; rel&#x3D;&quot;external noopener noreferrer&quot;&gt;https:&#x2F;&#x2F;github.com&#x2F;vincefinet&#x2F;OrgCheck&lt;&#x2F;a&gt; にあります。別々のライセンス条件の下で。</label></customLabels>
6+
<customLabels><name>OrgCheck_Home_Section2_Text3_CL</name><label> &lt;b&gt;Org Check は自由に使用できますが、公式のSalesforce製品ではありません。&lt;&#x2F;b&gt; Org Checkは正式にはありませんテストまたは文書化。 SalesforceサポートはOrg Checkでは利用できません。 Org Check のリクエストをサポートします &lt;a href&#x3D;&quot;https:&#x2F;&#x2F;github.com&#x2F;SalesforceLabs&#x2F;OrgCheck&#x2F;issues&quot; target&#x3D;&quot;_blank&quot; rel&#x3D;&quot;external noopener noreferrer&quot;&gt;https:&#x2F;&#x2F;github.com&#x2F;SalesforceLabs&#x2F;OrgCheck&#x2F;issues&lt;&#x2F;a&gt; でgithubに指示する必要があります。Org Check のソースコードは、 &lt;a href&#x3D;&quot;https:&#x2F;&#x2F;github.com&#x2F;SalesforceLabs&#x2F;OrgCheck&quot; target&#x3D;&quot;_blank&quot; rel&#x3D;&quot;external noopener noreferrer&quot;&gt;https:&#x2F;&#x2F;github.com&#x2F;SalesforceLabs&#x2F;OrgCheck&lt;&#x2F;a&gt; にあります。別々のライセンス条件の下で。</label></customLabels>
77
<customLabels><name>OrgCheck_XActiveMembers_CL</name><label>{0} 有効メンバー</label></customLabels>
88
<customLabels><name>OrgCheck_XInactiveMembers_CL</name><label>{0} 無効メンバー</label></customLabels>
99
<customLabels><name>OrgCheck_XtoY_CL</name><label>{0} to {1}</label></customLabels>

build/tmp/js/orgcheck.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

docs/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ The app is free of use: open sourced, available on the AppExchange for free and
3535

3636
Please use [this deck](http://sfdc.co/OrgCheck-Presentation) with your colleagues, company or customers to present the application before installing it and using it for your org.
3737

38-
Keep in mind that Org Check is not a Salesforce product. It has not been officially tested or documented by Salesforce. Also Salesforce support is not available for Org Check. Support is based on open source participation and requests are managed (as we can) via GitHub at https://github.com/VinceFINET/OrgCheck/issues.
38+
Keep in mind that Org Check is not a Salesforce product. It has not been officially tested or documented by Salesforce. Also Salesforce support is not available for Org Check. Support is based on open source participation and requests are managed (as we can) via GitHub at https://github.com/SalesforceLabs/OrgCheck/issues.
3939

4040
## How do I install this application?
4141

0 commit comments

Comments
 (0)