根本原因:
Salesforce は、IsExternallyVisible フラグを介して外部 (コミュニティ) ユーザーの EmailMessage レコードの表示をコントロールします。
コミュニティフィードでアクセスできるようにするには、関連する EmailMessage レコードのIsExternallyVisible フラグを true に設定する必要があります。
これは、Developer Console の匿名 Apex 実行で、または Apex トリガーを作成して自動的に設定することで実行できます。
-----------------------------------------------------------------------------------------
オプション 1: 既存のレコードに対する匿名 Apex を介した修正
既存のメールを手動で表示する場合はこの方法を使用します。
List<EmailMessage> lstEmt = [
SELECT Id, IsExternallyVisible
FROM EmailMessage
WHERE RelatedToId = 'RECORD_ID_HERE'
];
for (EmailMessage emt : lstEmt) {
emt.IsExternallyVisible = true;
}
update lstEmt;
「RECORD_ID_HERE」を実際の連絡先またはオブジェクトレコード ID に置き換えます。
------------------------------------------------------------------------------------
オプション 2: 上記のコードスニペットを使用してトリガーを作成
004867920

We use three kinds of cookies on our websites: required, functional, and advertising. You can choose whether functional and advertising cookies apply. Click on the different cookie categories to find out more about each category and to change the default settings.
Privacy Statement
Required cookies are necessary for basic website functionality. Some examples include: session cookies needed to transmit the website, authentication cookies, and security cookies.
Functional cookies enhance functions, performance, and services on the website. Some examples include: cookies used to analyze site traffic, cookies used for market research, and cookies used to display advertising that is not directed to a particular individual.
Advertising cookies track activity across websites in order to understand a viewer’s interests, and direct them specific marketing. Some examples include: cookies used for remarketing, or interest-based advertising.