Mise a jour du statut envoy quand un mailing a t envoy.
This commit is contained in:
parent
9d7e6ff332
commit
edb2044633
@ -141,7 +141,7 @@ if ($mil->fetch($_GET["id"]) == 0)
|
||||
$head[$h][1] = $langs->trans("MailRecipients");
|
||||
$hselected = $h;
|
||||
$h++;
|
||||
|
||||
|
||||
/*
|
||||
$head[$h][0] = DOL_URL_ROOT."/comm/mailing/history.php?id=".$mil->id;
|
||||
$head[$h][1] = $langs->trans("MailHistory");
|
||||
@ -250,7 +250,7 @@ if ($mil->fetch($_GET["id"]) == 0)
|
||||
|
||||
|
||||
// Liste des destinataires sélectionnés
|
||||
$sql = "SELECT mc.rowid, mc.nom, mc.prenom, mc.email";
|
||||
$sql = "SELECT mc.rowid, mc.nom, mc.prenom, mc.email, mc.statut, mc.date_envoi";
|
||||
$sql .= " FROM ".MAIN_DB_PREFIX."mailing_cibles as mc";
|
||||
$sql .= " WHERE mc.fk_mailing=".$mil->id;
|
||||
if ($sortfield) { $sql .= " ORDER BY $sortfield $sortorder"; }
|
||||
@ -268,7 +268,15 @@ if ($mil->fetch($_GET["id"]) == 0)
|
||||
print_liste_field_titre($langs->trans("Lastname"),"cibles.php","mc.nom",$addu,"","",$sortfield);
|
||||
print_liste_field_titre($langs->trans("Firstname"),"cibles.php","mc.prenom",$addu,"","",$sortfield);
|
||||
print_liste_field_titre($langs->trans("EMail"),"cibles.php","mc.email",$addu,"","",$sortfield);
|
||||
print '<td> </td>';
|
||||
print '<td>'.$langs->trans("Status").'</td>';
|
||||
if ($mil->statut == 0)
|
||||
{
|
||||
print '<td> </td>';
|
||||
}
|
||||
if ($mil->statut != 0)
|
||||
{
|
||||
print '<td>'.$langs->trans("Date").'</td>';
|
||||
}
|
||||
print '</tr>';
|
||||
$var = true;
|
||||
$i = 0;
|
||||
@ -282,7 +290,21 @@ if ($mil->fetch($_GET["id"]) == 0)
|
||||
print '<td>'.stripslashes($obj->nom).'</a></td>';
|
||||
print '<td>'.stripslashes($obj->prenom).'</a></td>';
|
||||
print '<td>'.$obj->email.'</td>';
|
||||
print '<td><a href="cibles.php?action=delete&id='.$mil->id.'&rowid='.$obj->rowid.'">'.img_delete().'</td>';
|
||||
if ($mil->statut == 0)
|
||||
{
|
||||
print '<td>'.$langs->trans("MailingStatusNotSent").'</td>';
|
||||
print '<td><a href="cibles.php?action=delete&id='.$mil->id.'&rowid='.$obj->rowid.'">'.img_delete($langs->trans("RemoveRecipient")).'</td>';
|
||||
}
|
||||
if ($mil->statut != 0)
|
||||
{
|
||||
print '<td>';
|
||||
if ($obj->statut==-1) print $langs->trans("MailingStatusError");
|
||||
if ($obj->statut==1) print $langs->trans("MailingStatusSent");
|
||||
print '</td>';
|
||||
print '<td>'.$obj->date_envoi.'</td>';
|
||||
}
|
||||
print '</tr>';
|
||||
|
||||
$i++;
|
||||
}
|
||||
|
||||
|
||||
@ -298,7 +298,7 @@ else
|
||||
$uc = new User($db, $mil->user_creat);
|
||||
$uc->fetch();
|
||||
print '<tr><td>'.$langs->trans("CreatedBy").'</td><td>'.$uc->fullname.'</td>';
|
||||
print '<td>'.$langs->trans("DateCreation").'</td>';
|
||||
print '<td>'.$langs->trans("Date").'</td>';
|
||||
print '<td>'.strftime("%d %b %Y %H:%M", $mil->date_creat).'</td></tr>';
|
||||
|
||||
if ($mil->statut > 0)
|
||||
@ -314,7 +314,7 @@ else
|
||||
{
|
||||
$ua = new User($db, $mil->user_appro);
|
||||
$ua->fetch();
|
||||
print '<tr><td>'.$langs->trans("ApprovedBy").'</td><td>'.$ua->fullname.'</td>';
|
||||
print '<tr><td>'.$langs->trans("SentBy").'</td><td>'.$ua->fullname.'</td>';
|
||||
print '<td>'.$langs->trans("Date").'</td>';
|
||||
print '<td>'.strftime("%d %b %Y %H:%M", $mil->date_appro).'</td></tr>';
|
||||
}
|
||||
|
||||
@ -190,7 +190,7 @@ if (! is_readable($htmlfile)) {
|
||||
$htmlfile="../../langs/fr_FR/html/spam.html";
|
||||
}
|
||||
if (is_readable($htmlfile)) {
|
||||
print "<br>".$langs->trans("Note").":<br><hr>";
|
||||
print "<br><br><br><br><br>".$langs->trans("Note").":<br><hr>";
|
||||
include($htmlfile);
|
||||
}
|
||||
|
||||
|
||||
@ -68,8 +68,7 @@ class Mailing
|
||||
|
||||
$this->statuts[0] = $langs->trans("MailingStatusDraft");
|
||||
$this->statuts[1] = $langs->trans("MailingStatusValidated");
|
||||
$this->statuts[2] = $langs->trans("MailingStatusApproved");
|
||||
$this->statuts[3] = $langs->trans("MailingStatusSent");
|
||||
$this->statuts[2] = $langs->trans("MailingStatusSent");
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@ -31,6 +31,8 @@ MailingStatusDraft=Draft
|
||||
MailingStatusValidated=Validated
|
||||
MailingStatusApproved=Approved
|
||||
MailingStatusSent=Sent
|
||||
MailingStatusError=Error
|
||||
MailingStatusNotSent=Not sent
|
||||
MailSuccessfulySent=Email successfuly sent (from %s to %s)
|
||||
ErrorMailRecipientIsEmpty=Email recipient is empty
|
||||
WarningNoEMailsAdded=No new Email to add to recipient's list.
|
||||
@ -41,6 +43,7 @@ NbOfUniqueEMails=Nb of unique emails
|
||||
TotalNbOfDistinctRecipients=Total number of distinct recipients
|
||||
NoTargetYet=No recipients defined yet
|
||||
AddRecipients=Add recipients
|
||||
RemoveRecipient=Remove recipient
|
||||
# Libelle des modules de liste de destinataires mailing
|
||||
MailingModuleDescContactProspects=All unique contact emails for all prospect companies
|
||||
MailingModuleDescContactCustomers=All unique contact emails for all customer companies
|
||||
@ -55,4 +58,5 @@ NbOfProspectsContacts=Unique contacts for all prospects
|
||||
NbOfCustomersContacts=Unique contacts for all customers
|
||||
MailNoChangePossible=Recipients for validated emailing can't be changed
|
||||
SendMailing=Send emailing
|
||||
SentBy=Sent by
|
||||
MailingNeedCommand=For securities reason, sending an emailing can only be performed from command line. Ask your administrator to launch the following command to send the emailing to all recipients:
|
||||
@ -31,6 +31,8 @@ MailingStatusDraft=Brouillon
|
||||
MailingStatusValidated=Validé
|
||||
MailingStatusApproved=Approuvé
|
||||
MailingStatusSent=Envoyé
|
||||
MailingStatusError=Erreur
|
||||
MailingStatusNotSent=Non envoyé
|
||||
MailSuccessfulySent=Mail correctement envoyé (de %s à %s)
|
||||
ErrorMailRecipientIsEmpty=L'adresse du destinataire est vide
|
||||
WarningNoEMailsAdded=Aucun nouvel e-mail à ajouter à la liste des destinataires.
|
||||
@ -41,6 +43,7 @@ NbOfUniqueEMails=Nb d'e-mails uniques
|
||||
TotalNbOfDistinctRecipients=Nombre total de destinataires uniques
|
||||
NoTargetYet=Pas de destinataire définis
|
||||
AddRecipients=Ajout de destinataires
|
||||
RemoveRecipient=Supprime destinataire
|
||||
# Libelle des modules de liste de destinataires mailing
|
||||
MailingModuleDescContactProspects=Tous les contacts de toutes les sociétés en prospection
|
||||
MailingModuleDescContactCustomers=Tous les contacts de toutes les sociétés clientes
|
||||
@ -55,4 +58,5 @@ NbOfProspectsContacts=Contacts uniques tous prospects
|
||||
NbOfCustomersContacts=Contacts uniques tous clients
|
||||
MailNoChangePossible=Destinataires d'un mailing validé non modifiables
|
||||
SendMailing=Envoi mailing
|
||||
SentBy=Envoyé par
|
||||
MailingNeedCommand=Pour des raisons de sécurité, l'envoi d'un mailing de masse ne peut être réalisé qu'en ligne de commande. Demander à votre administrateur de lancer la commande suivante pour envoyer le mailing à tous les destinataires :
|
||||
|
||||
Loading…
Reference in New Issue
Block a user