diff --git a/sql/structure.sql b/sql/structure.sql index 016cf7215fef754980eed9c2d4504bc131e8242b..5a7245b8edfc7726664ad3a7e169b4a225b1db63 100755 --- a/sql/structure.sql +++ b/sql/structure.sql @@ -1108,6 +1108,7 @@ document_type character varying(255) NOT NULL, options json DEFAULT '{}', fee FLOAT NOT NULL, recipient_entity_id INTEGER NOT NULL, +recipients jsonb DEFAULT '[]', account_id character varying(64) NOT NULL, creation_date timestamp without time zone NOT NULL, CONSTRAINT shippings_pkey PRIMARY KEY (id) diff --git a/src/app/email/controllers/EmailController.php b/src/app/email/controllers/EmailController.php index 2989c2056ec7e693d8dda2f4c879d58e016ccbe1..b94571805d69c45ddf4b1be3dfd52dcfb1fdd968 100644 --- a/src/app/email/controllers/EmailController.php +++ b/src/app/email/controllers/EmailController.php @@ -313,7 +313,7 @@ class EmailController } elseif ($queryParams['type'] == 'm2m') { $where[] = 'message_exchange_id is not null'; } elseif ($queryParams['type'] == 'email') { - $where[] = "object NOT LIKE '[AR]%'"; + $where[] = "(object NOT LIKE '[AR]%' OR object is null)"; $where[] = 'message_exchange_id is null'; } } @@ -512,7 +512,7 @@ class EmailController 'label' => $rawNote['note_text'], 'typeLabel' => 'note', 'creator' => UserModel::getLabelledUserById(['id' => $rawNote['user_id']]), - 'format' => 'html', + 'format' => 'pdf', 'size' => null ]; } diff --git a/src/frontend/app/sendedResource/sended-resource-page/sended-resource-page.component.ts b/src/frontend/app/sendedResource/sended-resource-page/sended-resource-page.component.ts index 20592b35ab4f2d98da4e979693d36db722f364eb..78f371da5af64db54e5bf32c016609e93efb49e3 100644 --- a/src/frontend/app/sendedResource/sended-resource-page/sended-resource-page.component.ts +++ b/src/frontend/app/sendedResource/sended-resource-page/sended-resource-page.component.ts @@ -468,8 +468,11 @@ export class SendedResourcePageComponent implements OnInit { this.http.get(`../../rest/resources/${this.data.resId}/emailsInitialization`).pipe( tap((data: any) => { Object.keys(data).forEach(element => { - if (element === 'resource') { - this.emailAttachTool.document.list = [data[element]]; + if (element === 'resource') { + this.emailAttachTool.document.list = []; + if (!this.functions.empty(data[element])) { + this.emailAttachTool.document.list = [data[element]]; + } } else { this.emailAttachTool[element].list = data[element].map((item: any) => { return { diff --git a/src/frontend/lang/lang-fr.ts b/src/frontend/lang/lang-fr.ts index 7a00fae0fc587acb7947e7ac39aa809a3f44f44e..b20bab02a6f32b04b79d2034a4b1c171c8acc524 100755 --- a/src/frontend/lang/lang-fr.ts +++ b/src/frontend/lang/lang-fr.ts @@ -1540,8 +1540,8 @@ export const LANG_FR = { "reaffectContactRedirect" : "Réaffecter à un contact", "contactReplacement" : "Contact remplaçant", "deleteContactwithtoutReassign" : "Supprimer le contact sans le remplacer", - "deleteContactInformations" : "Les différents liens entre le contact et les courriers, pièce-jointes ou accusés de réceptions seront supprimés.", - "reaffectContactInformations" : "Les différents liens entre le contact et les courriers, pièce-jointes ou accusés de réceptions seront réaffecter au nouveau contact choisi.", + "deleteContactInformations" : "Les différents liens entre le contact et les courriers, pièce-jointes ou accusés de réception seront supprimés.", + "reaffectContactInformations" : "Les différents liens entre le contact et les courriers, pièce-jointes ou accusés de réception seront réaffectés au nouveau contact choisi.", "availableContacts" : "Contact(s) disponible(s)", "sent" : "Envoyé", "notSent" : "Non envoyé",