forked from Wavyzz/dolibarr
Amlioration de la gestion des actions pour grer date de planification differente de date de realisation.
This commit is contained in:
@@ -42,8 +42,9 @@ class ActionComm
|
||||
var $type;
|
||||
var $label;
|
||||
var $datec; // Date creation enregistrement
|
||||
var $datep; // Date action 0%
|
||||
var $date; // Date action 100% (datea)
|
||||
var $datep; // Date action planifie debut
|
||||
var $datef; // Date action planifie fin
|
||||
var $date; // Date action realise completement (datea)
|
||||
var $datem; // Date modif (tms)
|
||||
var $priority;
|
||||
var $user;
|
||||
@@ -85,13 +86,13 @@ class ActionComm
|
||||
|
||||
$sql = "INSERT INTO ".MAIN_DB_PREFIX."actioncomm";
|
||||
$sql.= "(datec,";
|
||||
if ($this->percent < 100) $sql.= "datep,";
|
||||
if ($this->percent == 100) $sql.= "datea,";
|
||||
if ($this->date_p) $sql.= "datep,";
|
||||
if ($this->date_a) $sql.= "datea,";
|
||||
$sql.= "fk_action,fk_soc,note,fk_contact,fk_user_author,fk_user_action,label,percent,priority,";
|
||||
$sql.= "fk_facture,propalrowid,fk_commande)";
|
||||
$sql.= " VALUES (now(),";
|
||||
if ($this->percent < 100) $sql.= "'".$this->db->idate($this->date)."',";
|
||||
if ($this->percent == 100) $sql.= "'".$this->db->idate($this->date)."',";
|
||||
if ($this->date_p) $sql.= "'".$this->db->idate($this->date_p)."',";
|
||||
if ($this->date_a) $sql.= "'".$this->db->idate($this->date_a)."',";
|
||||
$sql.= "'".$this->type_id."', '".$this->societe->id."' ,'".addslashes($this->note)."',";
|
||||
$sql.= ($this->contact->id?$this->contact->id:"null").",";
|
||||
$sql.= "'$author->id', '".$this->user->id ."', '".addslashes($this->label)."','".$this->percent."','".$this->priority."',";
|
||||
|
||||
@@ -105,32 +105,40 @@ class CActioncomm {
|
||||
*/
|
||||
function liste_array($active='')
|
||||
{
|
||||
global $langs;
|
||||
global $langs,$conf;
|
||||
$langs->load("commercial");
|
||||
|
||||
$ga = array();
|
||||
|
||||
$sql = "SELECT id, code, libelle";
|
||||
$sql = "SELECT id, code, libelle, module";
|
||||
$sql.= " FROM ".MAIN_DB_PREFIX."c_actioncomm";
|
||||
if ($active != '') {
|
||||
$sql.=" WHERE active=$active";
|
||||
if ($active != '')
|
||||
{
|
||||
$sql.=" WHERE active=".$active;
|
||||
}
|
||||
$sql .= " ORDER BY id";
|
||||
|
||||
$resql=$this->db->query($sql);
|
||||
if ($resql)
|
||||
{
|
||||
$nump = $this->db->num_rows($resql);
|
||||
|
||||
if ($nump)
|
||||
{
|
||||
$i = 0;
|
||||
while ($i < $nump)
|
||||
{
|
||||
$obj = $this->db->fetch_object($resql);
|
||||
|
||||
$qualified=1;
|
||||
if ($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 ($qualified)
|
||||
{
|
||||
$transcode=$langs->trans("Action".$obj->code);
|
||||
$ga[$obj->id] = ($transcode!="Action".$obj->code?$transcode:$obj->libelle);
|
||||
}
|
||||
$i++;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -78,7 +78,7 @@ if ($_POST["action"] == 'add_action')
|
||||
$actioncomm->type_id = $_POST["actionid"];
|
||||
$actioncomm->type_code = $cactioncomm->code;
|
||||
$actioncomm->priority = isset($_POST["priority"])?$_POST["priority"]:0;
|
||||
$actioncomm->label = $_POST["label"];
|
||||
$actioncomm->label = trim($_POST["label"]);
|
||||
if (! $_POST["label"])
|
||||
{
|
||||
if ($_POST["actionid"] == 5 && $contact->fullname)
|
||||
@@ -93,16 +93,28 @@ if ($_POST["action"] == 'add_action')
|
||||
}
|
||||
}
|
||||
}
|
||||
$actioncomm->date = mktime($_POST["heurehour"],
|
||||
$_POST["heuremin"],
|
||||
0,
|
||||
$_POST["acmonth"],
|
||||
$_POST["acday"],
|
||||
$_POST["acyear"]);
|
||||
$actioncomm->duree=(($_POST["dureehour"] * 60) + $_POST["dureemin"]) * 60;
|
||||
$actioncomm->percent = isset($_POST["percentage"])?$_POST["percentage"]:0;
|
||||
if ($actioncomm->percent < 100)
|
||||
{
|
||||
$actioncomm->date_p = @mktime($_POST["heurephour"],
|
||||
$_POST["heurepmin"],
|
||||
0,
|
||||
$_POST["apmonth"],
|
||||
$_POST["apday"],
|
||||
$_POST["apyear"]);
|
||||
}
|
||||
if ($actioncomm->percent == 100)
|
||||
{
|
||||
$actioncomm->date_a = @mktime($_POST["heuredhour"],
|
||||
$_POST["heuredmin"],
|
||||
0,
|
||||
$_POST["admonth"],
|
||||
$_POST["adday"],
|
||||
$_POST["adyear"]);
|
||||
}
|
||||
$actioncomm->duree=(($_POST["dureehour"] * 60) + $_POST["dureemin"]) * 60;
|
||||
$actioncomm->user = $user;
|
||||
$actioncomm->note = $_POST["note"];
|
||||
$actioncomm->note = trim($_POST["note"]);
|
||||
if (isset($_POST["contactid"])) $actioncomm->contact = $contact;
|
||||
if (isset($_POST["socid"])) $actioncomm->societe = $societe;
|
||||
if ($_POST["todo_webcal"] == 'on') $actioncomm->use_webcal=1;
|
||||
@@ -115,7 +127,8 @@ if ($_POST["action"] == 'add_action')
|
||||
if (! $actioncomm->error)
|
||||
{
|
||||
$db->commit();
|
||||
Header("Location: ".$_POST["from"]);
|
||||
if ($_POST["from"]) Header("Location: ".$_POST["from"]);
|
||||
else Header("Location: ".DOL_URL_ROOT.'/comm/action/fiche.php?id='.$idaction);
|
||||
exit;
|
||||
}
|
||||
else
|
||||
@@ -129,12 +142,13 @@ if ($_POST["action"] == 'add_action')
|
||||
else
|
||||
{
|
||||
$db->rollback();
|
||||
dolibarr_print_error($db);
|
||||
$error=$actioncomm->error;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
dolibarr_print_error('',"Le type d'action n'a pas <20>t<EFBFBD> choisi");
|
||||
$_GET["action"] = 'create';
|
||||
$mesg='<div class="error">'.$langs->trans("ErrorFieldRequired",$langs->trans("Type")).'</div>';
|
||||
}
|
||||
|
||||
}
|
||||
@@ -208,6 +222,8 @@ if ($_GET["action"] == 'create')
|
||||
print_titre ($langs->trans("AddActionRendezVous"));
|
||||
print "<br>";
|
||||
|
||||
if ($mesg) print $mesg.'<br>';
|
||||
|
||||
print '<input type="hidden" name="date" value="'.$db->idate(time()).'">'."\n";
|
||||
|
||||
print '<table class="border" width="100%">';
|
||||
@@ -233,25 +249,75 @@ if ($_GET["action"] == 'create')
|
||||
// Si la societe est impos<6F>e, on propose ces contacts
|
||||
if ($_GET["socid"])
|
||||
{
|
||||
print '<tr><td>'.$langs->trans("ActionOnContact").'</td><td width="40%">';
|
||||
print '<tr><td>'.$langs->trans("ActionOnContact").'</td><td>';
|
||||
$html->select_contacts($_GET["socid"],'','contactid',1,1);
|
||||
print '</td></tr>';
|
||||
}
|
||||
|
||||
print '<tr><td>'.$langs->trans("Date").'</td><td>';
|
||||
$html->select_date('','ac','','','',"action");
|
||||
// Affecte a
|
||||
print '<tr><td nowrap>'.$langs->trans("ActionAffectedTo").'</td><td>';
|
||||
print $langs->trans("FeatureNotYetSupported");
|
||||
print '</td></tr>';
|
||||
print '<tr><td>'.$langs->trans("Hour").'</td><td>';
|
||||
print_heure_select("heure",8,20);
|
||||
|
||||
// Realise par
|
||||
print '<tr><td nowrap>'.$langs->trans("ActionDoneBy").'</td><td>';
|
||||
print $langs->trans("FeatureNotYetSupported");
|
||||
print '</td></tr>';
|
||||
|
||||
// Date planification
|
||||
print '<tr><td>'.$langs->trans("DatePlanned").'</td><td>';
|
||||
if ($_GET["afaire"] == 1 || $_GET["afaire"] == 2)
|
||||
{
|
||||
$html->select_date(-1,'ap','','','',"action");
|
||||
print ' ';
|
||||
print_heure_select("heurep",8,20);
|
||||
}
|
||||
else
|
||||
{
|
||||
$html->select_date(-1,'ap','','','',"action");
|
||||
print ' ';
|
||||
print_heure_select("heurep",8,20);
|
||||
}
|
||||
print '</td></tr>';
|
||||
|
||||
// Date done
|
||||
print '<tr><td>'.$langs->trans("DateDone").'</td><td>';
|
||||
if ($_GET["afaire"] == 1 || $_GET["afaire"] == 2)
|
||||
{
|
||||
$html->select_date(-1,'ad','','','',"action");
|
||||
print ' ';
|
||||
print_heure_select("heured",8,20);
|
||||
}
|
||||
else
|
||||
{
|
||||
$html->select_date(-1,'ad','','','',"action");
|
||||
print ' ';
|
||||
print_heure_select("heured",8,20);
|
||||
}
|
||||
print '</td></tr>';
|
||||
|
||||
// Duration
|
||||
print '<tr><td>'.$langs->trans("Duration").'</td><td>';
|
||||
print_duree_select("duree");
|
||||
print '</td></tr>';
|
||||
|
||||
add_row_for_webcal_link();
|
||||
|
||||
// Note
|
||||
print '<tr><td valign="top">'.$langs->trans("Note").'</td><td>';
|
||||
print '<textarea cols="60" rows="6" name="note"></textarea></td></tr>';
|
||||
if ($conf->fckeditor->enabled)
|
||||
{
|
||||
// Editeur wysiwyg
|
||||
require_once(DOL_DOCUMENT_ROOT."/lib/doleditor.class.php");
|
||||
$doleditor=new DolEditor('note','',280,'dolibarr_notes','In',true);
|
||||
$doleditor->Create();
|
||||
}
|
||||
else
|
||||
{
|
||||
print '<textarea name="note" cols="90" rows="'.ROWS_8.'">'.$societe->note.'</textarea>';
|
||||
}
|
||||
print '</td></tr>';
|
||||
|
||||
print '<tr><td colspan="2" align="center"><input type="submit" class="button" value="'.$langs->trans("Add").'"></td></tr>';
|
||||
print '</table>';
|
||||
}
|
||||
@@ -290,10 +356,12 @@ if ($_GET["action"] == 'create')
|
||||
print_titre ($langs->trans("AddAnAction"));
|
||||
print "<br>";
|
||||
|
||||
if ($mesg) print $mesg.'<br>';
|
||||
|
||||
print '<table class="border" width="100%">';
|
||||
|
||||
// Type d'action actifs
|
||||
print '<tr><td>'.$langs->trans("Action").'</td><td>';
|
||||
print '<tr><td>'.$langs->trans("Type").'</td><td>';
|
||||
if ($_GET["actionid"])
|
||||
{
|
||||
print '<input type="hidden" name="actionid" value="'.$_GET["actionid"].'">'."\n";
|
||||
@@ -301,7 +369,10 @@ if ($_GET["action"] == 'create')
|
||||
}
|
||||
else
|
||||
{
|
||||
$html->select_array("actionid", $caction->liste_array(1), 0);
|
||||
$arraylist=$caction->liste_array(1);
|
||||
$arraylist[0]=' ';
|
||||
sort($arraylist);
|
||||
$html->select_array("actionid", $arraylist, 0);
|
||||
}
|
||||
print '</td></tr>';
|
||||
|
||||
@@ -322,6 +393,16 @@ if ($_GET["action"] == 'create')
|
||||
}
|
||||
print '</td></tr>';
|
||||
|
||||
// Affecte a
|
||||
print '<tr><td nowrap>'.$langs->trans("ActionAffectedTo").'</td><td>';
|
||||
print $langs->trans("FeatureNotYetSupported");
|
||||
print '</td></tr>';
|
||||
|
||||
// Realise par
|
||||
print '<tr><td nowrap>'.$langs->trans("ActionDoneBy").'</td><td>';
|
||||
print $langs->trans("FeatureNotYetSupported");
|
||||
print '</td></tr>';
|
||||
|
||||
// Si la societe est impos<6F>e, on propose ces contacts
|
||||
if ($_GET["socid"])
|
||||
{
|
||||
@@ -343,28 +424,38 @@ if ($_GET["action"] == 'create')
|
||||
print '<tr><td>'.$langs->trans("Status").' / '.$langs->trans("Percentage").'</td><td>'.$langs->trans("StatusActionDone").' / 100%</td></tr>';
|
||||
} else
|
||||
{
|
||||
print '<tr><td>'.$langs->trans("Status").' / '.$langs->trans("Percentage").'</td><td><input type="text" name="percentage" value="0%"></td></tr>';
|
||||
print '<tr><td>'.$langs->trans("Status").' / '.$langs->trans("Percentage").'</td><td><input type="text" name="percentage" value="0" size="4">%</td></tr>';
|
||||
}
|
||||
|
||||
// Date
|
||||
print '<tr><td>'.$langs->trans("Date").'</td><td>';
|
||||
if ($_GET["afaire"] == 1)
|
||||
// Date planification
|
||||
print '<tr><td>'.$langs->trans("DatePlanned").'</td><td>';
|
||||
if ($_GET["afaire"] == 1 || $_GET["afaire"] == 2)
|
||||
{
|
||||
$html->select_date('','ac','','','',"action");
|
||||
print '</tr><tr><td>'.$langs->trans("Hour").'</td><td>';
|
||||
print_heure_select("heure",8,20);
|
||||
}
|
||||
else if ($_GET["afaire"] == 2)
|
||||
{
|
||||
$html->select_date('','ac','','','',"action");
|
||||
print '</tr><tr><td>'.$langs->trans("Hour").'</td><td>';
|
||||
print_heure_select("heure",8,20);
|
||||
$html->select_date(-1,'ap','','','',"action");
|
||||
print ' ';
|
||||
print_heure_select("heurep",8,20);
|
||||
}
|
||||
else
|
||||
{
|
||||
$html->select_date('','ac','','','',"action");
|
||||
print '</tr><tr><td>'.$langs->trans("Hour").'</td><td>';
|
||||
print_heure_select("heure",8,20);
|
||||
$html->select_date(-1,'ap','','','',"action");
|
||||
print ' ';
|
||||
print_heure_select("heurep",8,20);
|
||||
}
|
||||
print '</td></tr>';
|
||||
|
||||
// Date done
|
||||
print '<tr><td>'.$langs->trans("DateDone").'</td><td>';
|
||||
if ($_GET["afaire"] == 1 || $_GET["afaire"] == 2)
|
||||
{
|
||||
$html->select_date(-1,'ad','','','',"action");
|
||||
print ' ';
|
||||
print_heure_select("heured",8,20);
|
||||
}
|
||||
else
|
||||
{
|
||||
$html->select_date(-1,'ad','','','',"action");
|
||||
print ' ';
|
||||
print_heure_select("heured",8,20);
|
||||
}
|
||||
print '</td></tr>';
|
||||
|
||||
@@ -372,7 +463,18 @@ if ($_GET["action"] == 'create')
|
||||
|
||||
// Note
|
||||
print '<tr><td valign="top">'.$langs->trans("Note").'</td><td>';
|
||||
print '<textarea cols="60" rows="6" name="note"></textarea></td></tr>';
|
||||
if ($conf->fckeditor->enabled)
|
||||
{
|
||||
// Editeur wysiwyg
|
||||
require_once(DOL_DOCUMENT_ROOT."/lib/doleditor.class.php");
|
||||
$doleditor=new DolEditor('note','',280,'dolibarr_notes','In',true);
|
||||
$doleditor->Create();
|
||||
}
|
||||
else
|
||||
{
|
||||
print '<textarea name="note" cols="90" rows="'.ROWS_8.'"></textarea>';
|
||||
}
|
||||
print '</td></tr>';
|
||||
|
||||
print '<tr><td align="center" colspan="2"><input type="submit" class="button" value="'.$langs->trans("Add").'"></td></tr>';
|
||||
|
||||
@@ -448,9 +550,15 @@ if ($_GET["id"])
|
||||
$html->select_array("contactid", $act->societe->contact_array(), $act->contact->id, 1);
|
||||
print '</td></tr>';
|
||||
|
||||
// Auteur
|
||||
print '<tr><td>'.$langs->trans("Author").'</td>';
|
||||
print '<td colspan="3"><a href="'.DOL_URL_ROOT.'/user/fiche.php?id='.$act->author->id.'">'.img_object($langs->trans("ShowUser"),'user').' '.$act->author->fullname.'</a></td></tr>';
|
||||
// Affecte a
|
||||
print '<tr><td nowrap>'.$langs->trans("ActionAffectedTo").'</td><td colspan="3">';
|
||||
print $langs->trans("FeatureNotYetSupported");
|
||||
print '</td></tr>';
|
||||
|
||||
// Realise par
|
||||
print '<tr><td nowrap>'.$langs->trans("ActionDoneBy").'</td><td colspan="3">';
|
||||
print $langs->trans("FeatureNotYetSupported");
|
||||
print '</td></tr>';
|
||||
|
||||
// Date debut
|
||||
print '<tr><td>'.$langs->trans("DateActionPlanned").'</td><td colspan="3">'.dolibarr_print_date($act->datep,'%d %B %Y %H:%M').'</td></tr>';
|
||||
@@ -458,7 +566,10 @@ if ($_GET["id"])
|
||||
// Date fin real
|
||||
print '<tr><td>'.$langs->trans("DateActionDone").'</td><td colspan="3">'.dolibarr_print_date($act->date,'%d %B %Y %H:%M').'</td></tr>';
|
||||
|
||||
// Etat
|
||||
print '<tr><td nowrap>'.$langs->trans("Status").' / '.$langs->trans("Percentage").'</td><td colspan="3"><input name="percent" value="'.$act->percent.'" size="4">%</td></tr>';
|
||||
|
||||
// Objet li<6C>
|
||||
if ($act->objet_url)
|
||||
{
|
||||
print '<tr><td>'.$langs->trans("LinkedObject").'</td>';
|
||||
@@ -467,7 +578,19 @@ if ($_GET["id"])
|
||||
|
||||
// Note
|
||||
print '<tr><td valign="top">'.$langs->trans("Note").'</td><td colspan="3">';
|
||||
print '<textarea cols="60" rows="6" name="note">'.$act->note.'</textarea></td></tr>';
|
||||
if ($conf->fckeditor->enabled)
|
||||
{
|
||||
// Editeur wysiwyg
|
||||
require_once(DOL_DOCUMENT_ROOT."/lib/doleditor.class.php");
|
||||
$doleditor=new DolEditor('note','',280,'dolibarr_notes','In',true);
|
||||
$doleditor->Create();
|
||||
}
|
||||
else
|
||||
{
|
||||
print '<textarea name="note" cols="90" rows="'.ROWS_8.'">'.$act->note.'</textarea>';
|
||||
}
|
||||
|
||||
print '</td></tr>';
|
||||
|
||||
print '<tr><td align="center" colspan="4"><input type="submit" class="button" name="edit" value="'.$langs->trans("Save").'">';
|
||||
print ' <input type="submit" class="button" name="cancel" value="'.$langs->trans("Cancel").'">';
|
||||
@@ -497,9 +620,15 @@ if ($_GET["id"])
|
||||
|
||||
print '</td></tr>';
|
||||
|
||||
// Auteur
|
||||
print '<tr><td>'.$langs->trans("Author").'</td>';
|
||||
print '<td colspan="3"><a href="'.DOL_URL_ROOT.'/user/fiche.php?id='.$act->author->id.'">'.img_object($langs->trans("ShowUser"),'user').' '.$act->author->fullname.'</a></td></tr>';
|
||||
// Affecte a
|
||||
print '<tr><td nowrap>'.$langs->trans("ActionAffectedTo").'</td><td colspan="3">';
|
||||
print $langs->trans("FeatureNotYetSupported");
|
||||
print '</td></tr>';
|
||||
|
||||
// Realise par
|
||||
print '<tr><td nowrap>'.$langs->trans("ActionDoneBy").'</td><td colspan="3">';
|
||||
print $langs->trans("FeatureNotYetSupported");
|
||||
print '</td></tr>';
|
||||
|
||||
// Date debut
|
||||
print '<tr><td>'.$langs->trans("DateActionPlanned").'</td><td colspan="3">'.dolibarr_print_date($act->datep,'%d %B %Y %H:%M').'</td></tr>';
|
||||
@@ -521,7 +650,8 @@ if ($_GET["id"])
|
||||
|
||||
// Note
|
||||
print '<tr><td valign="top">'.$langs->trans("Note").'</td><td colspan="3">';
|
||||
print nl2br($act->note).'</td></tr>';
|
||||
print nl2br($act->note);
|
||||
print '</td></tr>';
|
||||
|
||||
print '</table>';
|
||||
}
|
||||
|
||||
@@ -55,6 +55,8 @@ LastProspectContactInProcess=Contact in process
|
||||
LastProspectContactDone=Contact done
|
||||
DateActionPlanned=Date planned
|
||||
DateActionDone=Date done
|
||||
ActionAffectedTo=Action affected to
|
||||
ActionDoneBy=Action done by
|
||||
ActionAC_TEL=Phone call
|
||||
ActionAC_FAX=Send fax
|
||||
ActionAC_PROP=Send proposal
|
||||
|
||||
@@ -332,6 +332,7 @@ Redo=Redo
|
||||
ExpandAll=Expand all
|
||||
UndoExpandAll=Undo expand
|
||||
Reason=Raison
|
||||
FeatureNotYetSupported=Feature not yet supported
|
||||
# Countries
|
||||
CountryFR=France
|
||||
CountryBE=Belgium
|
||||
|
||||
@@ -55,6 +55,8 @@ LastProspectContactInProcess=Contact en cours
|
||||
LastProspectContactDone=Prospects contact<63>s
|
||||
DateActionPlanned=Date planification
|
||||
DateActionDone=Date r<>alisation
|
||||
ActionAffectedTo=Action affect<63>e <20>
|
||||
ActionDoneBy=Action faite par
|
||||
ActionAC_TEL=Appel t<>l<EFBFBD>phonique
|
||||
ActionAC_FAX=Envoi fax
|
||||
ActionAC_PROP=Envoi proposition par mail
|
||||
|
||||
@@ -332,6 +332,7 @@ Redo=Refaire
|
||||
ExpandAll=Tout d<>rouler
|
||||
UndoExpandAll=Annuler d<>roulement
|
||||
Reason=Raison
|
||||
FeatureNotYetSupported=Fonctionnalit<69> pas encore support<72>e
|
||||
# Countries
|
||||
CountryFR=France
|
||||
CountryBE=Belgique
|
||||
|
||||
@@ -1692,14 +1692,14 @@ function print_fleche_navigation($page,$file,$options='',$nextpage)
|
||||
\param begin (1 par defaut)
|
||||
\param end (23 par defaut)
|
||||
*/
|
||||
function print_heure_select($prefix,$begin=1,$end=23) {
|
||||
|
||||
print '<select name="'.$prefix.'hour">';
|
||||
function print_heure_select($prefix,$begin=1,$end=23)
|
||||
{
|
||||
print '<select class="flat" name="'.$prefix.'hour">';
|
||||
for ($hour = $begin ; $hour <= $end ; $hour++) {
|
||||
print "<option value=\"$hour\">$hour";
|
||||
}
|
||||
print "</select> H ";
|
||||
print '<select name="'.$prefix.'min">';
|
||||
print '<select class="flat" name="'.$prefix.'min">';
|
||||
for ($min = 0 ; $min < 60 ; $min=$min+5) {
|
||||
if ($min < 10) {
|
||||
$min = "0" . $min;
|
||||
|
||||
@@ -315,15 +315,14 @@ insert into llx_accountingaccount (rowid, fk_pcg_version, pcg_type, pcg_subtype,
|
||||
--
|
||||
|
||||
delete from llx_c_actioncomm;
|
||||
insert into llx_c_actioncomm (id, code, type, libelle) values ( 1, 'AC_TEL', 'system', 'Appel T<>l<EFBFBD>phonique');
|
||||
insert into llx_c_actioncomm (id, code, type, libelle) values ( 2, 'AC_FAX', 'system', 'Envoi Fax');
|
||||
insert into llx_c_actioncomm (id, code, type, libelle) values ( 3, 'AC_PROP', 'system', 'Envoi Proposition');
|
||||
insert into llx_c_actioncomm (id, code, type, libelle) values ( 4, 'AC_EMAIL','system', 'Envoi Email');
|
||||
insert into llx_c_actioncomm (id, code, type, libelle) values ( 5, 'AC_RDV', 'system', 'Prendre rendez-vous');
|
||||
insert into llx_c_actioncomm (id, code, type, libelle) values ( 8, 'AC_COM', 'system', 'Envoi Commande');
|
||||
insert into llx_c_actioncomm (id, code, type, libelle) values ( 9, 'AC_FAC', 'system', 'Envoi Facture');
|
||||
insert into llx_c_actioncomm (id, code, type, libelle) values (10, 'AC_REL', 'system', 'Relance effectu<74>e');
|
||||
insert into llx_c_actioncomm (id, code, type, libelle) values (11, 'AC_CLO', 'system', 'Cl<EFBFBD>ture');
|
||||
insert into llx_c_actioncomm (id, code, type, libelle, module) values ( 1, 'AC_TEL', 'system', 'Appel T<>l<EFBFBD>phonique' ,NULL);
|
||||
insert into llx_c_actioncomm (id, code, type, libelle, module) values ( 2, 'AC_FAX', 'system', 'Envoi Fax' ,NULL);
|
||||
insert into llx_c_actioncomm (id, code, type, libelle, module) values ( 3, 'AC_PROP', 'system', 'Envoi Proposition' ,'propal');
|
||||
insert into llx_c_actioncomm (id, code, type, libelle, module) values ( 4, 'AC_EMAIL','system', 'Envoi Email' ,NULL);
|
||||
insert into llx_c_actioncomm (id, code, type, libelle, module) values ( 5, 'AC_RDV', 'system', 'Rendez-vous' ,NULL);
|
||||
insert into llx_c_actioncomm (id, code, type, libelle, module) values ( 8, 'AC_COM', 'system', 'Envoi Commande' ,'order');
|
||||
insert into llx_c_actioncomm (id, code, type, libelle, module) values ( 9, 'AC_FAC', 'system', 'Envoi Facture' ,'invoice');
|
||||
insert into llx_c_actioncomm (id, code, type, libelle, module) values (50, 'AC_OTH', 'system', 'Autre' ,NULL);
|
||||
|
||||
--
|
||||
-- Ape
|
||||
|
||||
@@ -82,12 +82,28 @@ alter table llx_categorie drop column fk_statut;
|
||||
alter table llx_categorie add visible tinyint DEFAULT 1 NOT NULL;
|
||||
|
||||
|
||||
alter table llx_c_actioncomm add module varchar(16) DEFAULT NULL after libelle;
|
||||
|
||||
delete from llx_c_actioncomm;
|
||||
insert into llx_c_actioncomm (id, code, type, libelle, module) values ( 1, 'AC_TEL', 'system', 'Appel T<>l<EFBFBD>phonique' ,NULL);
|
||||
insert into llx_c_actioncomm (id, code, type, libelle, module) values ( 2, 'AC_FAX', 'system', 'Envoi Fax' ,NULL);
|
||||
insert into llx_c_actioncomm (id, code, type, libelle, module) values ( 3, 'AC_PROP', 'system', 'Envoi Proposition' ,'propal');
|
||||
insert into llx_c_actioncomm (id, code, type, libelle, module) values ( 4, 'AC_EMAIL','system', 'Envoi Email' ,NULL);
|
||||
insert into llx_c_actioncomm (id, code, type, libelle, module) values ( 5, 'AC_RDV', 'system', 'Rendez-vous' ,NULL);
|
||||
insert into llx_c_actioncomm (id, code, type, libelle, module) values ( 8, 'AC_COM', 'system', 'Envoi Commande' ,'order');
|
||||
insert into llx_c_actioncomm (id, code, type, libelle, module) values ( 9, 'AC_FAC', 'system', 'Envoi Facture' ,'invoice');
|
||||
insert into llx_c_actioncomm (id, code, type, libelle, module) values (50, 'AC_OTH', 'system', 'Autre' ,NULL);
|
||||
|
||||
alter table llx_actioncomm modify datea datetime;
|
||||
alter table llx_actioncomm add column datec datetime after id;
|
||||
alter table llx_actioncomm add column datep datetime after datec;
|
||||
alter table llx_actioncomm add column tms timestamp after datea;
|
||||
alter table llx_actioncomm add column fk_commande integer after propalrowid;
|
||||
|
||||
update llx_actioncomm set datec = datea where datec is null;
|
||||
update llx_actioncomm set datep = datea where datep is null;
|
||||
update llx_actioncomm set fk_action = '8' where fk_action = '3' and label = 'Envoi commande par mail';
|
||||
|
||||
|
||||
|
||||
drop table if exists llx_expedition_model_pdf;
|
||||
@@ -237,7 +253,6 @@ delete from llx_document_model where nom='transporteur' and type='shipping';
|
||||
delete from llx_document_model where nom='dorade' and type='shipping';
|
||||
|
||||
|
||||
alter table llx_actioncomm add column fk_commande integer after propalrowid;
|
||||
|
||||
|
||||
ALTER TABLE llx_facture ADD UNIQUE INDEX idx_facture_uk_facnumber (facnumber);
|
||||
@@ -365,9 +380,6 @@ ALTER TABLE llx_societe_remise_except ADD CONSTRAINT fk_societe_remise_fk_factur
|
||||
update llx_societe_remise_except set description='Remise sans description' where description is NULL or description ='';
|
||||
alter table llx_societe_remise_except modify description varchar(255) NOT NULL;
|
||||
|
||||
insert into llx_c_actioncomm (id, code, type, libelle) values ( 8, 'AC_COM', 'system', 'Envoi Commande');
|
||||
update llx_actioncomm set fk_action = '8' where fk_action = '3' and label = 'Envoi commande par mail';
|
||||
|
||||
insert into llx_const (name, value, type, visible, note) VALUES ('PROPALE_VALIDITY_DURATION', '15', 'chaine', 0, 'Dur<EFBFBD>e de validit<EFBFBD>e des propales');
|
||||
|
||||
alter table llx_propal add column ref_client varchar(30) after ref;
|
||||
|
||||
@@ -27,6 +27,7 @@ create table llx_c_actioncomm
|
||||
code varchar(12) UNIQUE NOT NULL,
|
||||
type varchar(10) DEFAULT 'system' NOT NULL,
|
||||
libelle varchar(30) NOT NULL,
|
||||
module varchar(16) DEFAULT NULL,
|
||||
active tinyint DEFAULT 1 NOT NULL,
|
||||
todo tinyint
|
||||
)type=innodb;
|
||||
|
||||
Reference in New Issue
Block a user