fix: submitAnnotations server action missing directive and invalid mail options
This commit is contained in:
@@ -1,3 +1,5 @@
|
|||||||
|
'use server';
|
||||||
|
|
||||||
import { sendEmail } from '@/lib/mail/mailer';
|
import { sendEmail } from '@/lib/mail/mailer';
|
||||||
import { getServerAppServices } from '@/lib/services/create-services.server';
|
import { getServerAppServices } from '@/lib/services/create-services.server';
|
||||||
|
|
||||||
@@ -23,20 +25,16 @@ export async function submitAnnotations(annotations: any[]) {
|
|||||||
</li>
|
</li>
|
||||||
`).join('')}
|
`).join('')}
|
||||||
</ul>
|
</ul>
|
||||||
<p><i>Die genauen Daten (inkl. Scroll-Positionen, Viewport und Zeitstempel) befinden sich im JSON-Anhang.</i></p>
|
<p><i>Die genauen Daten (inkl. Scroll-Positionen, Viewport und Zeitstempel) befinden sich hier:</i></p>
|
||||||
|
<pre style="background: #f4f4f4; padding: 10px; border-radius: 5px; font-size: 12px; overflow-x: auto;">
|
||||||
|
${jsonContent}
|
||||||
|
</pre>
|
||||||
`;
|
`;
|
||||||
|
|
||||||
const notificationResult = await sendEmail({
|
const notificationResult = await sendEmail({
|
||||||
replyTo: 'info@e-tib.com', // Falls Rückfragen nötig
|
replyTo: 'info@e-tib.com', // Falls Rückfragen nötig
|
||||||
subject: `[Korrekturen] ${annotations.length} neue Anmerkungen für E-TIB`,
|
subject: `[Korrekturen] ${annotations.length} neue Anmerkungen für E-TIB`,
|
||||||
html: htmlContent,
|
html: htmlContent
|
||||||
attachments: [
|
|
||||||
{
|
|
||||||
filename: 'corrections.json',
|
|
||||||
content: jsonContent,
|
|
||||||
contentType: 'application/json',
|
|
||||||
}
|
|
||||||
]
|
|
||||||
});
|
});
|
||||||
|
|
||||||
if (!notificationResult.success) {
|
if (!notificationResult.success) {
|
||||||
|
|||||||
BIN
mintel-annotator-1.0.7.tgz
Normal file
BIN
mintel-annotator-1.0.7.tgz
Normal file
Binary file not shown.
12
pnpm-lock.yaml
generated
12
pnpm-lock.yaml
generated
@@ -13,8 +13,8 @@ importers:
|
|||||||
.:
|
.:
|
||||||
dependencies:
|
dependencies:
|
||||||
'@mintel/annotator':
|
'@mintel/annotator':
|
||||||
specifier: file:./mintel-annotator-1.0.6.tgz
|
specifier: file:./mintel-annotator-1.0.7.tgz
|
||||||
version: file:mintel-annotator-1.0.6.tgz(react-dom@19.2.4(react@19.2.4))(react@19.2.4)
|
version: file:mintel-annotator-1.0.7.tgz(react-dom@19.2.4(react@19.2.4))(react@19.2.4)
|
||||||
'@mintel/mail':
|
'@mintel/mail':
|
||||||
specifier: 1.9.5
|
specifier: 1.9.5
|
||||||
version: 1.9.5(react-dom@19.2.4(react@19.2.4))(react@19.2.4)
|
version: 1.9.5(react-dom@19.2.4(react@19.2.4))(react@19.2.4)
|
||||||
@@ -1407,9 +1407,9 @@ packages:
|
|||||||
'@medv/finder@4.0.2':
|
'@medv/finder@4.0.2':
|
||||||
resolution: {integrity: sha512-RraNY9SCcx4KZV0Dh6BEW6XEW2swkqYca74pkFFRw6hHItSHiy+O/xMnpbofjYbzXj0tSpBGthUF1hHTsr3vIQ==}
|
resolution: {integrity: sha512-RraNY9SCcx4KZV0Dh6BEW6XEW2swkqYca74pkFFRw6hHItSHiy+O/xMnpbofjYbzXj0tSpBGthUF1hHTsr3vIQ==}
|
||||||
|
|
||||||
'@mintel/annotator@file:mintel-annotator-1.0.6.tgz':
|
'@mintel/annotator@file:mintel-annotator-1.0.7.tgz':
|
||||||
resolution: {integrity: sha512-QkIiEShJexvzaQ9zANPi1zRIiBiBHEEsUu91AbtL3cpvMT/ApT31PFqu4cyho3QhzWOBhsdzNBbL0cQcFhR6nA==, tarball: file:mintel-annotator-1.0.6.tgz}
|
resolution: {integrity: sha512-At2+o4CxJBBK82Cl0xC/acAbs5RrNxnwDbuAGhmxMHGjL5Qero3TKxIvqI56FOgdZpdALfA2CT8aUpTsB0Vt+w==, tarball: file:mintel-annotator-1.0.7.tgz}
|
||||||
version: 1.0.6
|
version: 1.0.7
|
||||||
peerDependencies:
|
peerDependencies:
|
||||||
react: ^18.0.0 || ^19.0.0
|
react: ^18.0.0 || ^19.0.0
|
||||||
react-dom: ^18.0.0 || ^19.0.0
|
react-dom: ^18.0.0 || ^19.0.0
|
||||||
@@ -9358,7 +9358,7 @@ snapshots:
|
|||||||
|
|
||||||
'@medv/finder@4.0.2': {}
|
'@medv/finder@4.0.2': {}
|
||||||
|
|
||||||
'@mintel/annotator@file:mintel-annotator-1.0.6.tgz(react-dom@19.2.4(react@19.2.4))(react@19.2.4)':
|
'@mintel/annotator@file:mintel-annotator-1.0.7.tgz(react-dom@19.2.4(react@19.2.4))(react@19.2.4)':
|
||||||
dependencies:
|
dependencies:
|
||||||
'@medv/finder': 4.0.2
|
'@medv/finder': 4.0.2
|
||||||
clsx: 2.1.1
|
clsx: 2.1.1
|
||||||
|
|||||||
Reference in New Issue
Block a user