New: Add option to be able to select onto automatic event and manual
event (or both) into calendar view. Note: For backward compatibility reason, this will works only for new events. Qual: Disable old deprecated event code.
This commit is contained in:
parent
cbdcb50ce2
commit
caab5ac4e0
@ -1066,16 +1066,21 @@ if ($id)
|
||||
}
|
||||
}
|
||||
|
||||
print '<td align="center" nowrap="nowrap">';
|
||||
// Est-ce une entree du dictionnaire qui peut etre desactivee ?
|
||||
$iserasable=1; // Oui par defaut
|
||||
if (isset($obj->code) && ($obj->code == '0' || $obj->code == '' || preg_match('/unknown/i',$obj->code))) $iserasable=0;
|
||||
if (isset($obj->code) && $obj->code == 'RECEP') $iserasable=0;
|
||||
if (isset($obj->code) && $obj->code == 'EF0') $iserasable=0;
|
||||
if (isset($obj->type) && in_array($obj->type, array('system', 'systemauto'))) $iserasable=0;
|
||||
// Est-ce une entree du dictionnaire qui peut etre desactivee ?
|
||||
$iserasable=1; // Oui par defaut
|
||||
if (isset($obj->code) && ($obj->code == '0' || $obj->code == '' || preg_match('/unknown/i',$obj->code))) $iserasable=0;
|
||||
if (isset($obj->code) && $obj->code == 'RECEP') $iserasable=0;
|
||||
if (isset($obj->code) && $obj->code == 'EF0') $iserasable=0;
|
||||
if (isset($obj->type) && in_array($obj->type, array('system', 'systemauto'))) $iserasable=0;
|
||||
|
||||
// Active
|
||||
print '<td align="center" nowrap="nowrap">';
|
||||
if ($iserasable) print '<a href="'.$_SERVER["PHP_SELF"].'?'.($page?'page='.$page.'&':'').'sortfield='.$sortfield.'&sortorder='.$sortorder.'&rowid='.(! empty($obj->rowid)?$obj->rowid:(! empty($obj->code)?$obj->code:'')).'&code='.(! empty($obj->code)?$obj->code:'').'&id='.$id.'&action='.$acts[$obj->active].'">'.$actl[$obj->active].'</a>';
|
||||
else print $langs->trans("AlwaysActive");
|
||||
else
|
||||
{
|
||||
if (isset($obj->type) && in_array($obj->type, array('system', 'systemauto')) && empty($obj->active)) print $langs->trans("Deprecated");
|
||||
else print $langs->trans("AlwaysActive");
|
||||
}
|
||||
print "</td>";
|
||||
|
||||
// Modify link
|
||||
|
||||
@ -726,7 +726,10 @@ class ActionComm extends CommonObject
|
||||
|
||||
if ($withpicto)
|
||||
{
|
||||
$libelle.=(($this->type_code && $libelle!=$langs->trans("Action".$this->type_code) && $langs->trans("Action".$this->type_code)!="Action".$this->type_code)?' ('.$langs->trans("Action".$this->type_code).')':'');
|
||||
if (! empty($conf->global->AGENDA_USE_EVENT_TYPE))
|
||||
{
|
||||
$libelle.=(($this->type_code && $libelle!=$langs->trans("Action".$this->type_code) && $langs->trans("Action".$this->type_code)!="Action".$this->type_code)?' ('.$langs->trans("Action".$this->type_code).')':'');
|
||||
}
|
||||
$result.=$lien.img_object($langs->trans("ShowAction").': '.$libelle,($overwritepicto?$overwritepicto:'action')).$lienfin;
|
||||
}
|
||||
if ($withpicto==1) $result.=' ';
|
||||
|
||||
@ -100,9 +100,10 @@ class CActionComm
|
||||
* @param int $active 1 or 0 to filter on event state active or not ('' by default = no filter)
|
||||
* @param string $idorcode 'id' or 'code'
|
||||
* @param string $excludetype Type to exclude
|
||||
* @param string $onlyautoornot Group list by auto events or not
|
||||
* @return array Array of all event types if OK, <0 if KO
|
||||
*/
|
||||
function liste_array($active='',$idorcode='id',$excludetype='')
|
||||
function liste_array($active='',$idorcode='id',$excludetype='',$onlyautoornot=0)
|
||||
{
|
||||
global $langs,$conf;
|
||||
$langs->load("commercial");
|
||||
@ -110,7 +111,7 @@ class CActionComm
|
||||
$repid = array();
|
||||
$repcode = array();
|
||||
|
||||
$sql = "SELECT id, code, libelle, module";
|
||||
$sql = "SELECT id, code, libelle, module, type";
|
||||
$sql.= " FROM ".MAIN_DB_PREFIX."c_actioncomm";
|
||||
if ($active != '') $sql.=" WHERE active=".$active;
|
||||
if (! empty($excludetype)) $sql.=($active != ''?" AND":" WHERE")." type <> '".$excludetype."'";
|
||||
@ -127,20 +128,31 @@ class CActionComm
|
||||
while ($i < $nump)
|
||||
{
|
||||
$obj = $this->db->fetch_object($resql);
|
||||
|
||||
$qualified=1;
|
||||
if ($obj->module)
|
||||
|
||||
// $obj->type can be system, systemauto, module, moduleauto, xxx, xxxauto
|
||||
if ($qualified && $onlyautoornot && preg_match('/^system/',$obj->type) && ! preg_match('/^AC_OTH/',$obj->code)) $qualified=0; // We discard detailed system events. We keep only the 2 generic lines (AC_OTH and AC_OTHER)
|
||||
|
||||
if ($qualified && $obj->module)
|
||||
{
|
||||
if ($obj->module == 'invoice' && ! $conf->facture->enabled) $qualified=0;
|
||||
if ($obj->module == 'order' && ! $conf->commande->enabled) $qualified=0;
|
||||
if ($obj->module == 'propal' && ! $conf->propal->enabled) $qualified=0;
|
||||
if ($obj->module == 'invoice_supplier' && ! $conf->fournisseur->enabled) $qualified=0;
|
||||
if ($obj->module == 'order_supplier' && ! $conf->fournisseur->enabled) $qualified=0;
|
||||
if ($obj->module == 'shipping' && ! $conf->expedition->enabled) $qualified=0;
|
||||
}
|
||||
|
||||
if ($qualified)
|
||||
{
|
||||
$transcode=$langs->trans("Action".$obj->code);
|
||||
$repid[$obj->id] = ($transcode!="Action".$obj->code?$transcode:$langs->trans($obj->libelle));
|
||||
$repcode[$obj->code] = ($transcode!="Action".$obj->code?$transcode:$langs->trans($obj->libelle));
|
||||
$code=$obj->code;
|
||||
if ($onlyautoornot && $code == 'AC_OTH') $code='AC_MANUAL';
|
||||
if ($onlyautoornot && $code == 'AC_OTH_AUTO') $code='AC_AUTO';
|
||||
$transcode=$langs->trans("Action".$code);
|
||||
$repid[$obj->id] = ($transcode!="Action".$code?$transcode:$langs->trans($obj->libelle));
|
||||
$repcode[$obj->code] = ($transcode!="Action".$code?$transcode:$langs->trans($obj->libelle));
|
||||
if ($onlyautoornot && preg_match('/^module/',$obj->type) && $obj->module) $repcode[$obj->code].=' ('.$langs->trans("Module").': '.$obj->module.')';
|
||||
}
|
||||
$i++;
|
||||
}
|
||||
|
||||
@ -127,7 +127,10 @@ if ($objectid > 0)
|
||||
print '</td></tr>';
|
||||
|
||||
// Type
|
||||
print '<tr><td>'.$langs->trans("Type").'</td><td colspan="3">'.$act->type.'</td></tr>';
|
||||
if (! empty($conf->global->AGENDA_USE_EVENT_TYPE))
|
||||
{
|
||||
print '<tr><td>'.$langs->trans("Type").'</td><td colspan="3">'.$act->type.'</td></tr>';
|
||||
}
|
||||
|
||||
// Title
|
||||
print '<tr><td>'.$langs->trans("Title").'</td><td colspan="3">'.$act->label.'</td></tr>';
|
||||
|
||||
@ -107,6 +107,13 @@ if ($action == 'add_action')
|
||||
$mesg='<div class="error">'.$langs->trans("ErrorFieldRequired",$langs->trans("DateEnd")).'</div>';
|
||||
}
|
||||
|
||||
if (empty($conf->global->AGENDA_USE_EVENT_TYPE) && ! GETPOST('label'))
|
||||
{
|
||||
$error++;
|
||||
$action = 'create';
|
||||
$mesg='<div class="error">'.$langs->trans("ErrorFieldRequired",$langs->trans("Title")).'</div>';
|
||||
}
|
||||
|
||||
// Initialisation objet cactioncomm
|
||||
if (! GETPOST('actioncode'))
|
||||
{
|
||||
@ -122,13 +129,13 @@ if ($action == 'add_action')
|
||||
// Initialisation objet actioncomm
|
||||
$actioncomm->type_id = $cactioncomm->id;
|
||||
$actioncomm->type_code = $cactioncomm->code;
|
||||
$actioncomm->priority = isset($_POST["priority"])?$_POST["priority"]:0;
|
||||
$actioncomm->priority = GETPOST("priority")?GETPOST("priority"):0;
|
||||
$actioncomm->fulldayevent = (! empty($fulldayevent)?1:0);
|
||||
$actioncomm->location = isset($_POST["location"])?$_POST["location"]:'';
|
||||
$actioncomm->label = trim($_POST["label"]);
|
||||
if (! $_POST["label"])
|
||||
$actioncomm->location = GETPOST("location");
|
||||
$actioncomm->label = trim(GETPOST('label'));
|
||||
if (! GETPOST('label'))
|
||||
{
|
||||
if ($_POST["actioncode"] == 'AC_RDV' && $contact->getFullName($langs))
|
||||
if (GETPOST('actioncode') == 'AC_RDV' && $contact->getFullName($langs))
|
||||
{
|
||||
$actioncomm->label = $langs->transnoentitiesnoconv("TaskRDVWith",$contact->getFullName($langs));
|
||||
}
|
||||
@ -390,11 +397,13 @@ if ($action == 'create')
|
||||
$(".fulldaystartmin").removeAttr("disabled");
|
||||
$(".fulldayendhour").removeAttr("disabled");
|
||||
$(".fulldayendmin").removeAttr("disabled");
|
||||
$("#p2").removeAttr("disabled");
|
||||
} else {
|
||||
$(".fulldaystarthour").attr("disabled","disabled").val("00");
|
||||
$(".fulldaystartmin").attr("disabled","disabled").val("00");
|
||||
$(".fulldayendhour").attr("disabled","disabled").val("23");
|
||||
$(".fulldayendmin").attr("disabled","disabled").val("59");
|
||||
$("#p2").attr("disabled","disabled").val("");
|
||||
}
|
||||
}
|
||||
setdatefields();
|
||||
@ -432,21 +441,25 @@ if ($action == 'create')
|
||||
print '<table class="border" width="100%">';
|
||||
|
||||
// Type d'action actifs
|
||||
print '<tr><td width="30%"><span class="fieldrequired">'.$langs->trans("Type").'</span></b></td><td>';
|
||||
if (GETPOST("actioncode"))
|
||||
if (! empty($conf->global->AGENDA_USE_EVENT_TYPE))
|
||||
{
|
||||
print '<input type="hidden" name="actioncode" value="'.GETPOST("actioncode").'">'."\n";
|
||||
$cactioncomm->fetch(GETPOST("actioncode"));
|
||||
print $cactioncomm->getNomUrl();
|
||||
print '<tr><td width="30%"><span class="fieldrequired">'.$langs->trans("Type").'</span></b></td><td>';
|
||||
if (GETPOST("actioncode"))
|
||||
{
|
||||
print '<input type="hidden" name="actioncode" value="'.GETPOST("actioncode").'">'."\n";
|
||||
$cactioncomm->fetch(GETPOST("actioncode"));
|
||||
print $cactioncomm->getNomUrl();
|
||||
}
|
||||
else
|
||||
{
|
||||
$htmlactions->select_type_actions($actioncomm->type_code, "actioncode","systemauto");
|
||||
}
|
||||
print '</td></tr>';
|
||||
}
|
||||
else
|
||||
{
|
||||
$htmlactions->select_type_actions($actioncomm->type_code, "actioncode","systemauto");
|
||||
}
|
||||
print '</td></tr>';
|
||||
else print '<input type="hidden" name="actioncode" value="AC_OTH">';
|
||||
|
||||
// Title
|
||||
print '<tr><td>'.$langs->trans("Title").'</td><td><input type="text" name="label" size="60" value="'.GETPOST('label').'"></td></tr>';
|
||||
print '<tr><td'.(empty($conf->global->AGENDA_USE_EVENT_TYPE)?' class="fieldrequired"':'').'>'.$langs->trans("Title").'</td><td><input type="text" name="label" size="60" value="'.GETPOST('label').'"></td></tr>';
|
||||
|
||||
// Full day
|
||||
print '<tr><td class="fieldrequired">'.$langs->trans("EventOnFullDay").'</td><td><input type="checkbox" id="fullday" name="fullday" '.(GETPOST('fullday')?' checked="checked"':'').'></td></tr>';
|
||||
@ -678,10 +691,13 @@ if ($id)
|
||||
print '<tr><td width="30%">'.$langs->trans("Ref").'</td><td colspan="3">'.$act->id.'</td></tr>';
|
||||
|
||||
// Type
|
||||
print '<tr><td class="fieldrequired">'.$langs->trans("Type").'</td><td colspan="3">'.$act->type.'</td></tr>';
|
||||
if (! empty($conf->global->AGENDA_USE_EVENT_TYPE))
|
||||
{
|
||||
print '<tr><td class="fieldrequired">'.$langs->trans("Type").'</td><td colspan="3">'.$act->type.'</td></tr>';
|
||||
}
|
||||
|
||||
// Title
|
||||
print '<tr><td>'.$langs->trans("Title").'</td><td colspan="3"><input type="text" name="label" size="50" value="'.$act->label.'"></td></tr>';
|
||||
print '<tr><td'.(empty($conf->global->AGENDA_USE_EVENT_TYPE)?' class="fieldrequired"':'').'>'.$langs->trans("Title").'</td><td colspan="3"><input type="text" name="label" size="50" value="'.$act->label.'"></td></tr>';
|
||||
|
||||
// Full day event
|
||||
print '<tr><td class="fieldrequired">'.$langs->trans("EventOnFullDay").'</td><td colspan="3"><input type="checkbox" id="fullday" name="fullday" '.($act->fulldayevent?' checked="checked"':'').'></td></tr>';
|
||||
@ -797,7 +813,10 @@ if ($id)
|
||||
print '</td></tr>';
|
||||
|
||||
// Type
|
||||
print '<tr><td>'.$langs->trans("Type").'</td><td colspan="3">'.$act->type.'</td></tr>';
|
||||
if (! empty($conf->global->AGENDA_USE_EVENT_TYPE))
|
||||
{
|
||||
print '<tr><td>'.$langs->trans("Type").'</td><td colspan="3">'.$act->type.'</td></tr>';
|
||||
}
|
||||
|
||||
// Title
|
||||
print '<tr><td>'.$langs->trans("Title").'</td><td colspan="3">'.$act->label.'</td></tr>';
|
||||
|
||||
@ -194,9 +194,10 @@ class FormActions
|
||||
* @param string $selected Type pre-selectionne
|
||||
* @param string $htmlname Nom champ formulaire
|
||||
* @param string $excludetype Type to exclude
|
||||
* @param string $onlyautoornot Group list by auto events or not
|
||||
* @return void
|
||||
*/
|
||||
function select_type_actions($selected='',$htmlname='actioncode',$excludetype='')
|
||||
function select_type_actions($selected='',$htmlname='actioncode',$excludetype='',$onlyautoornot=0)
|
||||
{
|
||||
global $langs,$user;
|
||||
|
||||
@ -205,12 +206,13 @@ class FormActions
|
||||
$caction=new CActionComm($this->db);
|
||||
$form=new Form($this->db);
|
||||
|
||||
$arraylist=$caction->liste_array(1, 'code', $excludetype);
|
||||
array_unshift($arraylist,' '); // Add empty line at start
|
||||
//asort($arraylist);
|
||||
// Suggest a list with manual event or all auto events
|
||||
$arraylist=$caction->liste_array(1, 'code', $excludetype, $onlyautoornot);
|
||||
array_unshift($arraylist,' '); // Add empty line at start
|
||||
//asort($arraylist);
|
||||
|
||||
print $form->selectarray($htmlname, $arraylist, $selected);
|
||||
if ($user->admin) print info_admin($langs->trans("YouCanChangeValuesForThisListFromDictionnarySetup"),1);
|
||||
if ($user->admin && empty($onlyautoornot)) print info_admin($langs->trans("YouCanChangeValuesForThisListFromDictionnarySetup"),1);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@ -93,7 +93,10 @@ function print_actions_filter($form,$canedit,$status,$year,$month,$day,$showbirt
|
||||
print '<td nowrap="nowrap">';
|
||||
print $langs->trans("Type");
|
||||
print ' </td><td nowrap="nowrap">';
|
||||
print $formactions->select_type_actions(GETPOST('actioncode'), "actioncode");
|
||||
|
||||
// print $formactions->select_type_actions(GETPOST('actioncode'), "actioncode");
|
||||
print $formactions->select_type_actions(GETPOST('actioncode')?GETPOST('actioncode'):'manual', "actioncode", '', (empty($conf->global->AGENDA_USE_EVENT_TYPE)?1:0));
|
||||
|
||||
print '</td></tr>';
|
||||
}
|
||||
|
||||
|
||||
@ -127,7 +127,7 @@ class InterfaceActionsAuto
|
||||
$langs->load("other");
|
||||
$langs->load("agenda");
|
||||
|
||||
$object->actiontypecode='AC_OTH';
|
||||
$object->actiontypecode='AC_OTH_AUTO';
|
||||
if (empty($object->actionmsg2)) $object->actionmsg2=$langs->transnoentities("NewCompanyToDolibarr",$object->nom);
|
||||
$object->actionmsg=$langs->transnoentities("NewCompanyToDolibarr",$object->nom);
|
||||
if ($object->prefix) $object->actionmsg.=" (".$object->prefix.")";
|
||||
@ -146,7 +146,7 @@ class InterfaceActionsAuto
|
||||
$langs->load("contracts");
|
||||
$langs->load("agenda");
|
||||
|
||||
$object->actiontypecode='AC_OTH';
|
||||
$object->actiontypecode='AC_OTH_AUTO';
|
||||
if (empty($object->actionmsg2)) $object->actionmsg2=$langs->transnoentities("ContractValidatedInDolibarr",$object->ref);
|
||||
$object->actionmsg=$langs->transnoentities("ContractValidatedInDolibarr",$object->ref);
|
||||
$object->actionmsg.="\n".$langs->transnoentities("Author").': '.$user->login;
|
||||
@ -160,7 +160,7 @@ class InterfaceActionsAuto
|
||||
$langs->load("propal");
|
||||
$langs->load("agenda");
|
||||
|
||||
$object->actiontypecode='AC_OTH';
|
||||
$object->actiontypecode='AC_OTH_AUTO';
|
||||
if (empty($object->actionmsg2)) $object->actionmsg2=$langs->transnoentities("PropalValidatedInDolibarr",$object->ref);
|
||||
$object->actionmsg=$langs->transnoentities("PropalValidatedInDolibarr",$object->ref);
|
||||
$object->actionmsg.="\n".$langs->transnoentities("Author").': '.$user->login;
|
||||
@ -174,7 +174,7 @@ class InterfaceActionsAuto
|
||||
$langs->load("propal");
|
||||
$langs->load("agenda");
|
||||
|
||||
$object->actiontypecode='AC_EMAIL';
|
||||
$object->actiontypecode='AC_OTH_AUTO';
|
||||
if (empty($object->actionmsg2)) $object->actionmsg2=$langs->transnoentities("ProposalSentByEMail",$object->ref);
|
||||
if (empty($object->actionmsg))
|
||||
{
|
||||
@ -192,7 +192,7 @@ class InterfaceActionsAuto
|
||||
$langs->load("propal");
|
||||
$langs->load("agenda");
|
||||
|
||||
$object->actiontypecode='AC_OTH';
|
||||
$object->actiontypecode='AC_OTH_AUTO';
|
||||
if (empty($object->actionmsg2)) $object->actionmsg2=$langs->transnoentities("PropalClosedSignedInDolibarr",$object->ref);
|
||||
$object->actionmsg=$langs->transnoentities("PropalClosedSignedInDolibarr",$object->ref);
|
||||
$object->actionmsg.="\n".$langs->transnoentities("Author").': '.$user->login;
|
||||
@ -206,7 +206,7 @@ class InterfaceActionsAuto
|
||||
$langs->load("propal");
|
||||
$langs->load("agenda");
|
||||
|
||||
$object->actiontypecode='AC_OTH';
|
||||
$object->actiontypecode='AC_OTH_AUTO';
|
||||
if (empty($object->actionmsg2)) $object->actionmsg2=$langs->transnoentities("PropalClosedRefusedInDolibarr",$object->ref);
|
||||
$object->actionmsg=$langs->transnoentities("PropalClosedRefusedInDolibarr",$object->ref);
|
||||
$object->actionmsg.="\n".$langs->transnoentities("Author").': '.$user->login;
|
||||
@ -220,7 +220,7 @@ class InterfaceActionsAuto
|
||||
$langs->load("orders");
|
||||
$langs->load("agenda");
|
||||
|
||||
$object->actiontypecode='AC_OTH';
|
||||
$object->actiontypecode='AC_OTH_AUTO';
|
||||
if (empty($object->actionmsg2)) $object->actionmsg2=$langs->transnoentities("OrderValidatedInDolibarr",$object->ref);
|
||||
$object->actionmsg=$langs->transnoentities("OrderValidatedInDolibarr",$object->ref);
|
||||
$object->actionmsg.="\n".$langs->transnoentities("Author").': '.$user->login;
|
||||
@ -234,7 +234,7 @@ class InterfaceActionsAuto
|
||||
$langs->load("orders");
|
||||
$langs->load("agenda");
|
||||
|
||||
$object->actiontypecode='AC_EMAIL';
|
||||
$object->actiontypecode='AC_OTH_AUTO';
|
||||
if (empty($object->actionmsg2)) $object->actionmsg2=$langs->transnoentities("OrderSentByEMail",$object->ref);
|
||||
if (empty($object->actionmsg))
|
||||
{
|
||||
@ -253,7 +253,7 @@ class InterfaceActionsAuto
|
||||
$langs->load("bills");
|
||||
$langs->load("agenda");
|
||||
|
||||
$object->actiontypecode='AC_OTH';
|
||||
$object->actiontypecode='AC_OTH_AUTO';
|
||||
if (empty($object->actionmsg2)) $object->actionmsg2=$langs->transnoentities("InvoiceValidatedInDolibarr",$object->ref);
|
||||
$object->actionmsg=$langs->transnoentities("InvoiceValidatedInDolibarr",$object->ref);
|
||||
$object->actionmsg.="\n".$langs->transnoentities("Author").': '.$user->login;
|
||||
@ -268,7 +268,7 @@ class InterfaceActionsAuto
|
||||
$langs->load("bills");
|
||||
$langs->load("agenda");
|
||||
|
||||
$object->actiontypecode='AC_EMAIL';
|
||||
$object->actiontypecode='AC_OTH_AUTO';
|
||||
if (empty($object->actionmsg2)) $object->actionmsg2=$langs->transnoentities("InvoiceSentByEMail",$object->ref);
|
||||
if (empty($object->actionmsg))
|
||||
{
|
||||
@ -288,7 +288,7 @@ class InterfaceActionsAuto
|
||||
$langs->load("agenda");
|
||||
|
||||
// Values for this action can't be defined by caller.
|
||||
$object->actiontypecode='AC_OTH';
|
||||
$object->actiontypecode='AC_OTH_AUTO';
|
||||
$object->actionmsg2=$langs->transnoentities("InvoicePaidInDolibarr",$object->ref);
|
||||
$object->actionmsg=$langs->transnoentities("InvoicePaidInDolibarr",$object->ref);
|
||||
$object->actionmsg.="\n".$langs->transnoentities("Author").': '.$user->login;
|
||||
@ -303,7 +303,7 @@ class InterfaceActionsAuto
|
||||
$langs->load("bills");
|
||||
$langs->load("agenda");
|
||||
|
||||
$object->actiontypecode='AC_OTH';
|
||||
$object->actiontypecode='AC_OTH_AUTO';
|
||||
if (empty($object->actionmsg2)) $object->actionmsg2=$langs->transnoentities("InvoiceCanceledInDolibarr",$object->ref);
|
||||
$object->actionmsg=$langs->transnoentities("InvoiceCanceledInDolibarr",$object->ref);
|
||||
$object->actionmsg.="\n".$langs->transnoentities("Author").': '.$user->login;
|
||||
@ -318,7 +318,7 @@ class InterfaceActionsAuto
|
||||
$langs->load("interventions");
|
||||
$langs->load("agenda");
|
||||
|
||||
$object->actiontypecode='AC_OTH';
|
||||
$object->actiontypecode='AC_OTH_AUTO';
|
||||
if (empty($object->actionmsg2)) $object->actionmsg2=$langs->transnoentities("InterventionValidatedInDolibarr",$object->ref);
|
||||
$object->actionmsg=$langs->transnoentities("InterventionValidatedInDolibarr",$object->ref);
|
||||
$object->actionmsg.="\n".$langs->transnoentities("Author").': '.$user->login;
|
||||
@ -335,7 +335,7 @@ class InterfaceActionsAuto
|
||||
$langs->load("interventions");
|
||||
$langs->load("agenda");
|
||||
|
||||
$object->actiontypecode='AC_EMAIL';
|
||||
$object->actiontypecode='AC_OTH_AUTO';
|
||||
if (empty($object->actionmsg2)) $object->actionmsg2=$langs->transnoentities("InterventionSentByEMail",$object->ref);
|
||||
$object->actionmsg=$langs->transnoentities("InterventionSentByEMail",$object->ref);
|
||||
$object->actionmsg.="\n".$langs->transnoentities("Author").': '.$user->login;
|
||||
@ -351,7 +351,7 @@ class InterfaceActionsAuto
|
||||
$langs->load("sendings");
|
||||
$langs->load("agenda");
|
||||
|
||||
$object->actiontypecode='AC_SHIP';
|
||||
$object->actiontypecode='AC_OTH_AUTO';
|
||||
if (empty($object->actionmsg2)) $object->actionmsg2=$langs->transnoentities("ShippingSentByEMail",$object->ref);
|
||||
if (empty($object->actionmsg))
|
||||
{
|
||||
@ -369,7 +369,7 @@ class InterfaceActionsAuto
|
||||
$langs->load("orders");
|
||||
$langs->load("agenda");
|
||||
|
||||
$object->actiontypecode='AC_OTH';
|
||||
$object->actiontypecode='AC_OTH_AUTO';
|
||||
if (empty($object->actionmsg2)) $object->actionmsg2=$langs->transnoentities("OrderValidatedInDolibarr",$object->ref);
|
||||
$object->actionmsg=$langs->transnoentities("OrderValidatedInDolibarr",$object->ref);
|
||||
$object->actionmsg.="\n".$langs->transnoentities("Author").': '.$user->login;
|
||||
@ -385,7 +385,7 @@ class InterfaceActionsAuto
|
||||
$langs->load("agenda");
|
||||
$langs->load("orders");
|
||||
|
||||
$object->actiontypecode='AC_EMAIL';
|
||||
$object->actiontypecode='AC_OTH_AUTO';
|
||||
if (empty($object->actionmsg2)) $object->actionmsg2=$langs->transnoentities("SupplierOrderSentByEMail",$object->ref);
|
||||
if (empty($object->actionmsg))
|
||||
{
|
||||
@ -404,7 +404,7 @@ class InterfaceActionsAuto
|
||||
$langs->load("bills");
|
||||
$langs->load("agenda");
|
||||
|
||||
$object->actiontypecode='AC_OTH';
|
||||
$object->actiontypecode='AC_OTH_AUTO';
|
||||
if (empty($object->actionmsg2)) $object->actionmsg2=$langs->transnoentities("InvoiceValidatedInDolibarr",$object->ref);
|
||||
$object->actionmsg=$langs->transnoentities("InvoiceValidatedInDolibarr",$object->ref);
|
||||
$object->actionmsg.="\n".$langs->transnoentities("Author").': '.$user->login;
|
||||
@ -420,7 +420,7 @@ class InterfaceActionsAuto
|
||||
$langs->load("agenda");
|
||||
$langs->load("orders");
|
||||
|
||||
$object->actiontypecode='AC_EMAIL';
|
||||
$object->actiontypecode='AC_OTH_AUTO';
|
||||
if (empty($object->actionmsg2)) $object->actionmsg2=$langs->transnoentities("SupplierInvoiceSentByEMail",$object->ref);
|
||||
if (empty($object->actionmsg))
|
||||
{
|
||||
@ -439,7 +439,7 @@ class InterfaceActionsAuto
|
||||
$langs->load("bills");
|
||||
$langs->load("agenda");
|
||||
|
||||
$object->actiontypecode='AC_OTH';
|
||||
$object->actiontypecode='AC_OTH_AUTO';
|
||||
if (empty($object->actionmsg2)) $object->actionmsg2=$langs->transnoentities("InvoicePaidInDolibarr",$object->ref);
|
||||
$object->actionmsg=$langs->transnoentities("InvoicePaidInDolibarr",$object->ref);
|
||||
$object->actionmsg.="\n".$langs->transnoentities("Author").': '.$user->login;
|
||||
@ -454,7 +454,7 @@ class InterfaceActionsAuto
|
||||
$langs->load("bills");
|
||||
$langs->load("agenda");
|
||||
|
||||
$object->actiontypecode='AC_OTH';
|
||||
$object->actiontypecode='AC_OTH_AUTO';
|
||||
if (empty($object->actionmsg2)) $object->actionmsg2=$langs->transnoentities("InvoiceCanceledInDolibarr",$object->ref);
|
||||
$object->actionmsg=$langs->transnoentities("InvoiceCanceledInDolibarr",$object->ref);
|
||||
$object->actionmsg.="\n".$langs->transnoentities("Author").': '.$user->login;
|
||||
@ -471,7 +471,7 @@ class InterfaceActionsAuto
|
||||
$langs->load("members");
|
||||
$langs->load("agenda");
|
||||
|
||||
$object->actiontypecode='AC_OTH';
|
||||
$object->actiontypecode='AC_OTH_AUTO';
|
||||
if (empty($object->actionmsg2)) $object->actionmsg2=$langs->transnoentities("MemberValidatedInDolibarr",$object->ref);
|
||||
$object->actionmsg=$langs->transnoentities("MemberValidatedInDolibarr",$object->ref);
|
||||
$object->actionmsg.="\n".$langs->transnoentities("Member").': '.$object->getFullName($langs);
|
||||
@ -488,7 +488,7 @@ class InterfaceActionsAuto
|
||||
$langs->load("members");
|
||||
$langs->load("agenda");
|
||||
|
||||
$object->actiontypecode='AC_OTH';
|
||||
$object->actiontypecode='AC_OTH_AUTO';
|
||||
if (empty($object->actionmsg2)) $object->actionmsg2=$langs->transnoentities("MemberSubscriptionAddedInDolibarr",$object->ref);
|
||||
$object->actionmsg=$langs->transnoentities("MemberSubscriptionAddedInDolibarr",$object->ref);
|
||||
$object->actionmsg.="\n".$langs->transnoentities("Member").': '.$object->getFullName($langs);
|
||||
@ -511,7 +511,7 @@ class InterfaceActionsAuto
|
||||
$langs->load("members");
|
||||
$langs->load("agenda");
|
||||
|
||||
$object->actiontypecode='AC_OTH';
|
||||
$object->actiontypecode='AC_OTH_AUTO';
|
||||
if (empty($object->actionmsg2)) $object->actionmsg2=$langs->transnoentities("MemberResiliatedInDolibarr",$object->ref);
|
||||
$object->actionmsg=$langs->transnoentities("MemberResiliatedInDolibarr",$object->ref);
|
||||
$object->actionmsg.="\n".$langs->transnoentities("Member").': '.$object->getFullName($langs);
|
||||
@ -528,7 +528,7 @@ class InterfaceActionsAuto
|
||||
$langs->load("members");
|
||||
$langs->load("agenda");
|
||||
|
||||
$object->actiontypecode='AC_OTH';
|
||||
$object->actiontypecode='AC_OTH_AUTO';
|
||||
if (empty($object->actionmsg2)) $object->actionmsg2=$langs->transnoentities("MemberDeletedInDolibarr",$object->ref);
|
||||
$object->actionmsg=$langs->transnoentities("MemberDeletedInDolibarr",$object->ref);
|
||||
$object->actionmsg.="\n".$langs->transnoentities("Member").': '.$object->getFullName($langs);
|
||||
|
||||
@ -30,15 +30,16 @@
|
||||
-- Types action comm
|
||||
--
|
||||
|
||||
delete from llx_c_actioncomm where id in (1,2,3,4,5,8,9,10,30,31,50);
|
||||
insert into llx_c_actioncomm (id, code, type, libelle, module, position) values ( 1, 'AC_TEL', 'system', 'Phone call' ,NULL, 2);
|
||||
insert into llx_c_actioncomm (id, code, type, libelle, module, position) values ( 2, 'AC_FAX', 'system', 'Send Fax' ,NULL, 3);
|
||||
insert into llx_c_actioncomm (id, code, type, libelle, module, position) values ( 3, 'AC_PROP', 'systemauto', 'Send commercial proposal by email' ,'propal', 10);
|
||||
insert into llx_c_actioncomm (id, code, type, libelle, module, position) values ( 4, 'AC_EMAIL', 'system', 'Send Email' ,NULL, 4);
|
||||
insert into llx_c_actioncomm (id, code, type, libelle, module, position) values ( 5, 'AC_RDV', 'system', 'Rendez-vous' ,NULL, 1);
|
||||
insert into llx_c_actioncomm (id, code, type, libelle, module, position) values ( 8, 'AC_COM', 'systemauto', 'Send customer order by email' ,'order', 8);
|
||||
insert into llx_c_actioncomm (id, code, type, libelle, module, position) values ( 9, 'AC_FAC', 'systemauto', 'Send customer invoice by email' ,'invoice', 6);
|
||||
insert into llx_c_actioncomm (id, code, type, libelle, module, position) values ( 10, 'AC_SHIP', 'systemauto', 'Send shipping by email' ,'shipping', 11);
|
||||
insert into llx_c_actioncomm (id, code, type, libelle, module, position) values ( 30, 'AC_SUP_ORD', 'systemauto', 'Send supplier order by email' ,'order_supplier', 9);
|
||||
insert into llx_c_actioncomm (id, code, type, libelle, module, position) values (31, 'AC_SUP_INV', 'systemauto', 'Send supplier invoice by email' ,'invoice_supplier', 7);
|
||||
insert into llx_c_actioncomm (id, code, type, libelle, module, position) values ( 50, 'AC_OTH', 'system', 'Other' ,NULL, 5);
|
||||
delete from llx_c_actioncomm where id in (1,2,3,4,5,8,9,10,30,31,40,50);
|
||||
insert into llx_c_actioncomm (id, code, type, libelle, module, active, position) values ( 1, 'AC_TEL', 'system', 'Phone call' ,NULL, 1, 2);
|
||||
insert into llx_c_actioncomm (id, code, type, libelle, module, active, position) values ( 2, 'AC_FAX', 'system', 'Send Fax' ,NULL, 1, 3);
|
||||
insert into llx_c_actioncomm (id, code, type, libelle, module, active, position) values ( 3, 'AC_PROP', 'systemauto', 'Send commercial proposal by email' ,'propal',0, 10);
|
||||
insert into llx_c_actioncomm (id, code, type, libelle, module, active, position) values ( 4, 'AC_EMAIL', 'system', 'Send Email' ,NULL, 1, 4);
|
||||
insert into llx_c_actioncomm (id, code, type, libelle, module, active, position) values ( 5, 'AC_RDV', 'system', 'Rendez-vous' ,NULL, ,1 1);
|
||||
insert into llx_c_actioncomm (id, code, type, libelle, module, active, position) values ( 8, 'AC_COM', 'systemauto', 'Send customer order by email' ,'order', 0, 8);
|
||||
insert into llx_c_actioncomm (id, code, type, libelle, module, active, position) values ( 9, 'AC_FAC', 'systemauto', 'Send customer invoice by email' ,'invoice',0, 6);
|
||||
insert into llx_c_actioncomm (id, code, type, libelle, module, active, position) values ( 10, 'AC_SHIP', 'systemauto', 'Send shipping by email' ,'shipping',0, 11);
|
||||
insert into llx_c_actioncomm (id, code, type, libelle, module, active, position) values ( 30, 'AC_SUP_ORD', 'systemauto', 'Send supplier order by email' ,'order_supplier',0, 9);
|
||||
insert into llx_c_actioncomm (id, code, type, libelle, module, active, position) values ( 31, 'AC_SUP_INV', 'systemauto', 'Send supplier invoice by email' ,'invoice_supplier',0, 7);
|
||||
insert into llx_c_actioncomm (id, code, type, libelle, module, active, position) values ( 40, 'AC_OTH_AUTO','systemauto', 'Other (automatically inserted events)' ,NULL, 1, 20);
|
||||
insert into llx_c_actioncomm (id, code, type, libelle, module, active, position) values ( 50, 'AC_OTH', 'system', 'Other (manually inserted events)' ,NULL, 1, 5);
|
||||
|
||||
@ -805,6 +805,12 @@ ALTER TABLE llx_c_effectif DROP INDEX code, ADD UNIQUE uk_c_effectif (code);
|
||||
ALTER TABLE llx_c_paiement DROP INDEX code, ADD UNIQUE uk_c_paiement (code);
|
||||
|
||||
|
||||
delete from llx_c_actioncomm where id = 40;
|
||||
INSERT INTO llx_c_actioncomm (id, code, type, libelle, module, position) values ( 40, 'AC_OTH_AUTO','systemauto', 'Other (automatically inserted events)' ,NULL, 20);
|
||||
UPDATE llx_c_actioncomm SET libelle = 'Other (manually inserted events)' WHERE code = 'AC_OTH';
|
||||
UPDATE llx_c_actioncomm SET active = 0 WHERE code in ('AC_PROP', 'AC_COM', 'AC_FAC', 'AC_SHIP', 'AC_SUP_ORD', 'AC_SUP_INV');
|
||||
|
||||
|
||||
-- Update dictionnary of table llx_c_paper_format
|
||||
DELETE FROM llx_c_paper_format;
|
||||
|
||||
|
||||
@ -81,6 +81,8 @@ ActionAC_SHIP=Send shipping by mail
|
||||
ActionAC_SUP_ORD=Send supplier order by mail
|
||||
ActionAC_SUP_INV=Send supplier invoice by mail
|
||||
ActionAC_OTH=Other
|
||||
ActionAC_MANUAL=Manually inserted events
|
||||
ActionAC_AUTO=Automatically inserted events
|
||||
Stats=Sales statistics
|
||||
CAOrder=Sales volume (validated orders)
|
||||
FromTo=from %s to %s
|
||||
|
||||
@ -81,6 +81,8 @@ ActionAC_SHIP=Envoi bon d'expédition par mail
|
||||
ActionAC_SUP_ORD=Envoi commande fournisseur par mail
|
||||
ActionAC_SUP_INV=Envoi facture fournisseur par mail
|
||||
ActionAC_OTH=Autre
|
||||
ActionAC_MANUAL=Evênements insérés manuellement
|
||||
ActionAC_AUTO=Evênements insérés automatiquement
|
||||
Stats=Statistiques de vente
|
||||
CAOrder=Chiffre d'affaires (Commandes validées)
|
||||
FromTo=du %s au %s
|
||||
|
||||
Loading…
Reference in New Issue
Block a user