mal wieder ganz anders
This commit is contained in:
parent
c3fec7dde7
commit
3480c9c1cb
|
|
@ -53,28 +53,11 @@ class NotificationPayloadFactory
|
|||
$previewSnippet = 'Bitte prüft, ob wir tägliche Snapshots brauchen.';
|
||||
$reasonText = 'Neue Antwort in beobachteter Diskussion';
|
||||
|
||||
// ✅ Teams AppCatalog ID (aus Get-TeamsApp)
|
||||
$teamsCatalogAppId = '61e3fb91-4b17-428f-856b-51a345e10f06';
|
||||
|
||||
// ✅ kompakte Unterseiten-ID (KEINE URL!)
|
||||
$subEntityId = 'discussion:34:2';
|
||||
|
||||
// ✅ Kontext für entityUrl
|
||||
$contextJson = json_encode([
|
||||
'subEntityId' => $subEntityId
|
||||
], JSON_UNESCAPED_SLASHES);
|
||||
|
||||
// ✅ entityUrl (KEIN webUrl, KEIN Deep Link)
|
||||
$entityUrl = sprintf(
|
||||
'https://graph.microsoft.com/v1.0/appCatalogs/teamsApps/%s?context=%s',
|
||||
rawurlencode($teamsCatalogAppId),
|
||||
rawurlencode($contextJson)
|
||||
);
|
||||
|
||||
$payload = [
|
||||
'topic' => [
|
||||
'source' => 'entityUrl',
|
||||
'value' => $entityUrl,
|
||||
'source' => 'text',
|
||||
'value' => $discussionTitle,
|
||||
'webUrl' => $discussionUrl, // ✅ DIREKT ins Forum
|
||||
],
|
||||
'activityType' => 'systemDefault',
|
||||
'previewText' => [
|
||||
|
|
@ -88,7 +71,6 @@ class NotificationPayloadFactory
|
|||
],
|
||||
];
|
||||
|
||||
|
||||
if ($iconId !== '') {
|
||||
$payload['iconId'] = $iconId;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue