2
0
forked from Wavyzz/dolibarr

New: task #7560 : Droit et definition d'un filtre d'export des interventions

This commit is contained in:
Laurent Destailleur
2008-10-13 16:39:53 +00:00
parent c71ecc5577
commit 8104948dce
13 changed files with 121 additions and 104 deletions

View File

@@ -7,9 +7,10 @@ For users:
- Support bookmark add of product cards. - Support bookmark add of product cards.
- New view in ecm module. - New view in ecm module.
- Look enhancements for graphics (add transparency). - Look enhancements for graphics (add transparency).
- Added statistics report for supplier invoices - Added statistics report for supplier invoices.
- Added average amount in invoices statistics reports. - Added average amount in invoices statistics reports.
- Can move a contract line to another contract of same third party. - Can move a contract line to another contract of same third party.
- Add an export definition to export interventions.
For translators: For translators:
- The errors language file contains only error or warning messages with - The errors language file contains only error or warning messages with

View File

@@ -38,6 +38,7 @@ if (! $user->societe_id == 0)
$entitytoicon=array( $entitytoicon=array(
'invoice'=>'bill','invoice_line'=>'bill', 'invoice'=>'bill','invoice_line'=>'bill',
'order'=>'order' ,'order_line'=>'order', 'order'=>'order' ,'order_line'=>'order',
'intervention'=>'intervention' ,'inter_line'=>'intervention',
'member'=>'user' ,'member_type'=>'group','subscription'=>'payment', 'member'=>'user' ,'member_type'=>'group','subscription'=>'payment',
'tax'=>'generic' ,'tax_type'=>'generic', 'tax'=>'generic' ,'tax_type'=>'generic',
'account'=>'account', 'account'=>'account',
@@ -50,6 +51,7 @@ $entitytolang=array( // Translation code
'company'=>'Company','contact'=>'Contact', 'company'=>'Company','contact'=>'Contact',
'invoice'=>'Bill','invoice_line'=>'InvoiceLine', 'invoice'=>'Bill','invoice_line'=>'InvoiceLine',
'order'=>'Order','order_line'=>'OrderLine', 'order'=>'Order','order_line'=>'OrderLine',
'intervention'=>'Intervention' ,'inter_line'=>'InterLine',
'member'=>'Member','member_type'=>'MemberType','subscription'=>'Subscription', 'member'=>'Member','member_type'=>'MemberType','subscription'=>'Subscription',
'tax'=>'SocialContribution','tax_type'=>'DictionnarySocialContributions', 'tax'=>'SocialContribution','tax_type'=>'DictionnarySocialContributions',
'account'=>'BankTransactions', 'account'=>'BankTransactions',

View File

@@ -19,10 +19,10 @@
*/ */
/** /**
\file htdocs/fichinter/fiche.php * \file htdocs/fichinter/fiche.php
\brief Fichier fiche intervention * \brief Fichier fiche intervention
\ingroup ficheinter * \ingroup ficheinter
\version $Id$ * \version $Id$
*/ */
require("./pre.inc.php"); require("./pre.inc.php");
@@ -96,7 +96,6 @@ if ($_POST["action"] == 'add')
{ {
$fichinter = new Fichinter($db); $fichinter = new Fichinter($db);
$fichinter->date = dolibarr_mktime($_POST["phour"], $_POST["pmin"] , $_POST["psec"], $_POST["pmonth"], $_POST["pday"], $_POST["pyear"]);
$fichinter->socid = $_POST["socid"]; $fichinter->socid = $_POST["socid"];
$fichinter->duree = $_POST["duree"]; $fichinter->duree = $_POST["duree"];
$fichinter->projet_id = $_POST["projetidp"]; $fichinter->projet_id = $_POST["projetidp"];
@@ -130,7 +129,6 @@ if ($_POST["action"] == 'update')
{ {
$fichinter = new Fichinter($db); $fichinter = new Fichinter($db);
$fichinter->date = dolibarr_mktime($_POST["phour"], $_POST["pmin"] , $_POST["psec"], $_POST["remonth"], $_POST["reday"], $_POST["reyear"]);
$fichinter->socid = $_POST["socid"]; $fichinter->socid = $_POST["socid"];
$fichinter->projet_id = $_POST["projetidp"]; $fichinter->projet_id = $_POST["projetidp"];
$fichinter->author = $user->id; $fichinter->author = $user->id;
@@ -142,7 +140,7 @@ if ($_POST["action"] == 'update')
} }
/* /*
* G<EFBFBD>n<EFBFBD>rer ou reg<65>n<EFBFBD>rer le document PDF * Build doc
*/ */
if ($_REQUEST['action'] == 'builddoc') // En get ou en post if ($_REQUEST['action'] == 'builddoc') // En get ou en post
{ {
@@ -164,14 +162,13 @@ if ($_REQUEST['action'] == 'builddoc') // En get ou en post
} }
} }
/* // Set into a project
* Classer dans un projet
*/
if ($_POST['action'] == 'classin') if ($_POST['action'] == 'classin')
{ {
$fichinter = new Fichinter($db); $fichinter = new Fichinter($db);
$fichinter->fetch($_GET['id']); $fichinter->fetch($_GET['id']);
$fichinter->set_project($user, $_POST['projetidp']); $result=$fichinter->set_project($user, $_POST['projetidp']);
if ($result < 0) dolibarr_print_error($db,$fichinter->error);
} }
if ($_REQUEST['action'] == 'confirm_delete' && $_REQUEST['confirm'] == 'yes') if ($_REQUEST['action'] == 'confirm_delete' && $_REQUEST['confirm'] == 'yes')
@@ -186,14 +183,6 @@ if ($_REQUEST['action'] == 'confirm_delete' && $_REQUEST['confirm'] == 'yes')
exit; exit;
} }
if ($_POST['action'] == 'setdate_delivery')
{
$fichinter = new Fichinter($db);
$fichinter->fetch($_GET['id']);
$result=$fichinter->set_date_delivery($user,dolibarr_mktime(12, 0, 0, $_POST['liv_month'], $_POST['liv_day'], $_POST['liv_year']));
if ($result < 0) dolibarr_print_error($db,$fichinter->error);
}
if ($_POST['action'] == 'setdescription') if ($_POST['action'] == 'setdescription')
{ {
$fichinter = new Fichinter($db); $fichinter = new Fichinter($db);
@@ -202,6 +191,8 @@ if ($_POST['action'] == 'setdescription')
if ($result < 0) dolibarr_print_error($db,$fichinter->error); if ($result < 0) dolibarr_print_error($db,$fichinter->error);
} }
/* /*
* Ajout d'une ligne d'intervention * Ajout d'une ligne d'intervention
*/ */
@@ -254,7 +245,6 @@ if ($_POST['action'] == 'updateligne' && $user->rights->ficheinter->creer && $_P
$duration = ConvertTime2Seconds($_POST['durationhour'],$_POST['durationmin']); $duration = ConvertTime2Seconds($_POST['durationhour'],$_POST['durationmin']);
$fichinterline->desc=$desc; $fichinterline->desc=$desc;
$fichinterline->datei=$date_intervention;
$fichinterline->duration=$duration; $fichinterline->duration=$duration;
$result = $fichinterline->update(); $result = $fichinterline->update();
@@ -409,10 +399,6 @@ if ($_GET["action"] == 'create')
print '<input type="hidden" name="socid" value='.$_GET["socid"].'>'; print '<input type="hidden" name="socid" value='.$_GET["socid"].'>';
print "<tr><td>".$langs->trans("Company")."</td><td>".$societe->getNomUrl(1)."</td></tr>"; print "<tr><td>".$langs->trans("Company")."</td><td>".$societe->getNomUrl(1)."</td></tr>";
print "<tr><td>".$langs->trans("Date")."</td><td>";
$html->select_date(time(),"p",'','','','fichinter');
print "</td></tr>";
print "<input type=\"hidden\" name=\"action\" value=\"add\">"; print "<input type=\"hidden\" name=\"action\" value=\"add\">";
print "<tr><td>".$langs->trans("Ref")."</td>"; print "<tr><td>".$langs->trans("Ref")."</td>";
@@ -549,29 +535,6 @@ elseif ($_GET["id"] > 0)
// Societe // Societe
print "<tr><td>".$langs->trans("Company")."</td><td>".$fichinter->client->getNomUrl(1)."</td></tr>"; print "<tr><td>".$langs->trans("Company")."</td><td>".$fichinter->client->getNomUrl(1)."</td></tr>";
// Date
print '<tr><td>';
print '<table class="nobordernopadding" width="100%"><tr><td>';
print $langs->trans('Date');
print '</td>';
if ($_GET['action'] != 'editdate_delivery' && $fichinter->brouillon) print '<td align="right"><a href="'.$_SERVER["PHP_SELF"].'?action=editdate_delivery&amp;id='.$fichinter->id.'">'.img_edit($langs->trans('SetDateCreate'),1).'</a></td>';
print '</tr></table>';
print '</td><td colspan="3">';
if ($_GET['action'] == 'editdate_delivery')
{
print '<form name="editdate_delivery" action="'.$_SERVER["PHP_SELF"].'?id='.$fichinter->id.'" method="post">';
print '<input type="hidden" name="action" value="setdate_delivery">';
$html->select_date($fichinter->date,'liv_','','','',"editdate_delivery");
print '<input type="submit" class="button" value="'.$langs->trans('Modify').'">';
print '</form>';
}
else
{
print dolibarr_print_date($fichinter->date,'%a %d %B %Y');
}
print '</td>';
print '</tr>';
// Projet // Projet
if ($conf->projet->enabled) if ($conf->projet->enabled)
{ {
@@ -905,13 +868,13 @@ elseif ($_GET["id"] > 0)
} }
// Delete // Delete
if ($fichinter->statut == 0 && $user->rights->ficheinter->supprimer) if (($fichinter->statut == 0 && $user->rights->ficheinter->creer) || $user->rights->ficheinter->supprimer)
{ {
print '<a class="butActionDelete" '; print '<a class="butActionDelete" ';
if ($conf->use_javascript_ajax && $conf->global->MAIN_CONFIRM_AJAX) if ($conf->use_javascript_ajax && $conf->global->MAIN_CONFIRM_AJAX)
{ {
$url = $_SERVER["PHP_SELF"].'?id='.$fichinter->id.'&action=confirm_delete&confirm=yes'; $url = $_SERVER["PHP_SELF"].'?id='.$fichinter->id.'&action=confirm_delete&confirm=yes';
print 'href="#" onClick="dialogConfirm(\''.$url.'\',\''.$langs->trans("ConfirmDeleteIntervention").'\',\''.$langs->trans("Yes").'\',\''.$langs->trans("No").'\',\'delete\')"'; print 'href="#" onClick="dialogConfirm(\''.$url.'\',\''.dol_escape_js($langs->trans("ConfirmDeleteIntervention",$fichinter->ref)).'\',\''.$langs->trans("Yes").'\',\''.$langs->trans("No").'\',\'delete\')"';
} }
else else
{ {

View File

@@ -102,11 +102,10 @@ class Fichinter extends CommonObject
$result=$soc->fetch($this->socid); $result=$soc->fetch($this->socid);
$this->verifyNumRef($soc); $this->verifyNumRef($soc);
$sql = "INSERT INTO ".MAIN_DB_PREFIX."fichinter (fk_soc, datei, datec, ref, fk_user_author, description, model_pdf"; $sql = "INSERT INTO ".MAIN_DB_PREFIX."fichinter (fk_soc, datec, ref, fk_user_author, description, model_pdf";
if ($this->projet_id) $sql.= ", fk_projet"; if ($this->projet_id) $sql.= ", fk_projet";
$sql.= ") "; $sql.= ") ";
$sql.= " VALUES (".$this->socid.","; $sql.= " VALUES (".$this->socid.",";
$sql.= " ".$this->db->idate($this->date).",";
$sql.= " ".$this->db->idate(mktime()).", '".$this->ref."', ".$this->author; $sql.= " ".$this->db->idate(mktime()).", '".$this->ref."', ".$this->author;
$sql.= ", '".addslashes($this->description)."', '".$this->modelpdf."'"; $sql.= ", '".addslashes($this->description)."', '".$this->modelpdf."'";
if ($this->projet_id) $sql .= ", ".$this->projet_id; if ($this->projet_id) $sql .= ", ".$this->projet_id;
@@ -420,26 +419,26 @@ class Fichinter extends CommonObject
{ {
if ($user->rights->ficheinter->creer) if ($user->rights->ficheinter->creer)
{ {
//verif que le projet et la societe concordent $sql = 'UPDATE '.MAIN_DB_PREFIX.'fichinter';
$sql = 'SELECT p.rowid, p.title FROM '.MAIN_DB_PREFIX.'projet as p WHERE p.fk_soc ='.$this->socid.' AND p.rowid='.$project_id; $sql.= ' SET fk_projet = '.($project_id <= 0?'NULL':$project_id);
$sqlres = $this->db->query($sql); $sql.= ' WHERE rowid = '.$this->id;
if ($sqlres)
dolibarr_syslog("Fichinter::set_project sql=".$sql);
$resql=$this->db->query($sql);
if ($resql)
{ {
$numprojet = $this->db->num_rows($sqlres); $this->projetidp=$project_id;
if ($numprojet > 0)
{
$this->projetidp=$project_id;
$sql = 'UPDATE '.MAIN_DB_PREFIX.'fichinter SET fk_projet = '.$project_id;
$sql .= ' WHERE rowid = '.$this->id.' AND fk_statut = 0 ;';
$this->db->query($sql);
}
} }
else else
{ {
$this->error=$this->db->error();
dolibarr_syslog("Fichinter::set_project Erreur SQL"); dolibarr_syslog("Fichinter::set_project Error ".$this->error);
} }
} }
else
{
dolibarr_syslog("Fichinter::set_project Error Permission refused");
}
} }
/** /**

View File

@@ -52,6 +52,7 @@ $offset = $limit * $page ;
$pageprev = $page - 1; $pageprev = $page - 1;
$pagenext = $page + 1; $pagenext = $page + 1;
/* /*
* View * View
*/ */
@@ -59,10 +60,13 @@ $pagenext = $page + 1;
llxHeader(); llxHeader();
$sql = "SELECT s.nom,s.rowid as socid, f.ref,".$db->pdate("f.datei")." as dp, f.rowid as fichid, f.fk_statut, f.description, f.duree"; $sql = "SELECT s.nom,s.rowid as socid, f.ref, f.rowid as fichid, f.fk_statut,";
$sql.= " fd.description, ".$db->pdate("fd.date")." as dp, fd.duree";
if (!$user->rights->societe->client->voir && !$socid) $sql .= ", sc.fk_soc, sc.fk_user"; if (!$user->rights->societe->client->voir && !$socid) $sql .= ", sc.fk_soc, sc.fk_user";
$sql.= " FROM ".MAIN_DB_PREFIX."societe as s, ".MAIN_DB_PREFIX."fichinter as f "; $sql.= " FROM ".MAIN_DB_PREFIX."societe as s";
if (!$user->rights->societe->client->voir && !$socid) $sql .= ", ".MAIN_DB_PREFIX."societe_commerciaux as sc"; if (!$user->rights->societe->client->voir && !$socid) $sql .= ", ".MAIN_DB_PREFIX."societe_commerciaux as sc";
$sql.= ", ".MAIN_DB_PREFIX."fichinter as f ";
$sql.= " LEFT JOIN ".MAIN_DB_PREFIX."fichinterdet as fd ON fd.fk_fichinter = f.rowid";
$sql.= " WHERE f.fk_soc = s.rowid "; $sql.= " WHERE f.fk_soc = s.rowid ";
if (!$user->rights->societe->client->voir && !$socid) $sql .= " AND s.rowid = sc.fk_soc AND sc.fk_user = " .$user->id; if (!$user->rights->societe->client->voir && !$socid) $sql .= " AND s.rowid = sc.fk_soc AND sc.fk_user = " .$user->id;
if ($socid > 0) if ($socid > 0)

View File

@@ -385,9 +385,10 @@ class FormFile
* \param relativepath Relative path of docs (autodefined if not provided) * \param relativepath Relative path of docs (autodefined if not provided)
* \param permtodelete Permission to delete * \param permtodelete Permission to delete
* \param useinecm Change output for use in ecm module * \param useinecm Change output for use in ecm module
* \param textifempty Text to show if filearray is empty
* \return int <0 if KO, nb of files shown if OK * \return int <0 if KO, nb of files shown if OK
*/ */
function list_of_documents($filearray,$object,$modulepart,$param,$forcedownload=0,$relativepath='',$permtodelete=1,$useinecm=0) function list_of_documents($filearray,$object,$modulepart,$param,$forcedownload=0,$relativepath='',$permtodelete=1,$useinecm=0,$textifempty='')
{ {
global $user, $conf, $langs; global $user, $conf, $langs;
global $bc; global $bc;
@@ -441,7 +442,13 @@ class FormFile
print "</td></tr>\n"; print "</td></tr>\n";
} }
} }
if (sizeof($filearray) == 0) print '<tr '.$bc[$var].'><td colspan="4">'.$langs->trans("NoFileFound").'</td></tr>'; if (sizeof($filearray) == 0)
{
print '<tr '.$bc[$var].'><td colspan="4">';
if (empty($textifempty)) print $langs->trans("NoFileFound");
else print $textifempty;
print '</td></tr>';
}
print "</table>"; print "</table>";
// Fin de zone // Fin de zone

View File

@@ -161,6 +161,7 @@ class ExportCsv extends ModeleExports
foreach($array_selected_sorted as $code => $value) foreach($array_selected_sorted as $code => $value)
{ {
$alias=$array_alias[$code]; $alias=$array_alias[$code];
if (empty($alias)) dolibarr_print_error('','Bad value for field with code='.$code.'. Try to redefine export.');
$newvalue=$objp->$alias; $newvalue=$objp->$alias;
// Translation newvalue // Translation newvalue

View File

@@ -153,6 +153,7 @@ class ExportExcel extends ModeleExports
{ {
$alias=$array_export_fields_label[$code]; $alias=$array_export_fields_label[$code];
//print "dd".$alias; //print "dd".$alias;
if (empty($alias)) dolibarr_print_error('','Bad value for field with code='.$code.'. Try to redefine export.');
$this->worksheet->write($this->row, $this->col, $langs->transnoentities($alias), $formatheader); $this->worksheet->write($this->row, $this->col, $langs->transnoentities($alias), $formatheader);
$this->col++; $this->col++;
} }

View File

@@ -161,7 +161,8 @@ class ExportTsv extends ModeleExports
foreach($array_selected_sorted as $code => $value) foreach($array_selected_sorted as $code => $value)
{ {
$alias=$array_alias[$code]; $alias=$array_alias[$code];
$newvalue=$objp->$alias; if (empty($alias)) dolibarr_print_error('','Bad value for field with code='.$code.'. Try to redefine export.');
$newvalue=$objp->$alias;
// Translation newvalue // Translation newvalue
if (eregi('^\((.*)\)$',$newvalue,$reg)) if (eregi('^\((.*)\)$',$newvalue,$reg))

View File

@@ -238,9 +238,8 @@ class pdf_soleil extends ModelePDFFicheinter
$pdf->rect(100, 40, 100, 40); $pdf->rect(100, 40, 100, 40);
$pdf->SetTextColor(200,0,0); $pdf->SetTextColor(0,0,100);
$pdf->SetFont('Arial','B',14); $pdf->SetFont('Arial','B',14);
$pdf->Text(11, 88, "Date : " . dolibarr_print_date($fichinter->date,'day'));
$pdf->Text(11, 94, $langs->trans("InterventionCard")." : ".$fichinter->ref); $pdf->Text(11, 94, $langs->trans("InterventionCard")." : ".$fichinter->ref);
$pdf->SetFillColor(220,220,220); $pdf->SetFillColor(220,220,220);

View File

@@ -65,7 +65,7 @@ class modFacture extends DolibarrModules
// Dir // Dir
$this->dirs = array(); $this->dirs = array();
// D<EFBFBD>pendances // Dependencies
$this->depends = array("modSociete"); $this->depends = array("modSociete");
$this->requiredby = array("modComptabilite","modComptabiliteExpert"); $this->requiredby = array("modComptabilite","modComptabiliteExpert");
$this->conflictwith = array(); $this->conflictwith = array();

View File

@@ -20,31 +20,30 @@
*/ */
/** /**
\defgroup ficheinter Module intervention cards * \defgroup ficheinter Module intervention cards
\brief Module to manage intervention cards * \brief Module to manage intervention cards
\version $Id$ * \version $Id$
*/ */
/** /**
\file htdocs/includes/modules/modFicheinter.class.php * \file htdocs/includes/modules/modFicheinter.class.php
\ingroup ficheinter * \ingroup ficheinter
\brief Fichier de description et activation du module Ficheinter * \brief Fichier de description et activation du module Ficheinter
*/ */
include_once(DOL_DOCUMENT_ROOT ."/includes/modules/DolibarrModules.class.php"); include_once(DOL_DOCUMENT_ROOT ."/includes/modules/DolibarrModules.class.php");
/** /**
\class modFicheinter * \class modFicheinter
\brief Classe de description et activation du module Ficheinter * \brief Classe de description et activation du module Ficheinter
*/ */
class modFicheinter extends DolibarrModules class modFicheinter extends DolibarrModules
{ {
/** /**
* \brief Constructeur. Definit les noms, constantes et boites * \brief Constructeur. Definit les noms, constantes et boites
* \param DB handler d'acc<63>s base * \param DB Database access handler
*/ */
function modFicheinter($DB) function modFicheinter($DB)
{ {
@@ -66,12 +65,14 @@ class modFicheinter extends DolibarrModules
// Dir // Dir
$this->dirs = array(); $this->dirs = array();
// Config pages // Dependencies
$this->config_page_url = array("fichinter.php");
// D<>pendances
$this->depends = array("modSociete","modCommercial"); $this->depends = array("modSociete","modCommercial");
$this->requiredby = array(); $this->requiredby = array();
$this->conflictwith = array();
$this->langfiles = array("bills","companies","interventions");
// Config pages
$this->config_page_url = array("fichinter.php");
// Constantes // Constantes
$this->const = array(); $this->const = array();
@@ -93,25 +94,51 @@ class modFicheinter extends DolibarrModules
// Permissions // Permissions
$this->rights = array(); $this->rights = array();
$this->rights_class = 'ficheinter'; $this->rights_class = 'ficheinter';
$r=0;
$r++;
$this->rights[$r][0] = 61;
$this->rights[$r][1] = 'Lire les fiches d\'intervention';
$this->rights[$r][2] = 'r';
$this->rights[$r][3] = 1;
$this->rights[$r][4] = 'lire';
$this->rights[1][0] = 61; $r++;
$this->rights[1][1] = 'Lire les fiches d\'intervention'; $this->rights[$r][0] = 62;
$this->rights[1][2] = 'r'; $this->rights[$r][1] = 'Creer/modifier les fiches d\'intervention';
$this->rights[1][3] = 1; $this->rights[$r][2] = 'w';
$this->rights[1][4] = 'lire'; $this->rights[$r][3] = 0;
$this->rights[$r][4] = 'creer';
$this->rights[2][0] = 62; $r++;
$this->rights[2][1] = 'Creer/modifier les fiches d\'intervention'; $this->rights[$r][0] = 64;
$this->rights[2][2] = 'w'; $this->rights[$r][1] = 'Supprimer les fiches d\'intervention';
$this->rights[2][3] = 0; $this->rights[$r][2] = 'd';
$this->rights[2][4] = 'creer'; $this->rights[$r][3] = 0;
$this->rights[$r][4] = 'supprimer';
$this->rights[3][0] = 64;
$this->rights[3][1] = 'Supprimer les fiches d\'intervention';
$this->rights[3][2] = 'd';
$this->rights[3][3] = 0;
$this->rights[3][4] = 'supprimer';
$r++;
$this->rights[$r][0] = 67;
$this->rights[$r][1] = 'Exporter les fiches interventions';
$this->rights[$r][2] = 'r';
$this->rights[$r][3] = 0;
$this->rights[$r][4] = 'export';
//Exports
//--------
$r=1;
$this->export_code[$r]=$this->rights_class.'_'.$r;
$this->export_label[$r]='InterventionCardsAndInterventionLines'; // Translation key (used only if key ExportDataset_xxx_z not found)
$this->export_permission[$r]=array(array("ficheinter","export"));
$this->export_fields_array[$r]=array('s.rowid'=>"IdCompany",'s.nom'=>'CompanyName','s.address'=>'Address','s.cp'=>'Zip','s.ville'=>'Town','s.fk_pays'=>'Country','s.tel'=>'Phone','s.siren'=>'ProfId1','s.siret'=>'ProfId2','s.ape'=>'ProfId3','s.idprof4'=>'ProfId4','s.code_compta'=>'CustomerAccountancyCode','s.code_compta_fournisseur'=>'SupplierAccountancyCode','f.rowid'=>"InterId",'f.ref'=>"InterRef",'f.datec'=>"InterDateCreation",'f.duree'=>"InterDuration",'f.fk_statut'=>'InterStatus','f.description'=>"InterNote",'fd.rowid'=>'InterLineId','fd.date'=>"InterLineDate",'fd.duree'=>"InterLineDuration",'fd.description'=>"InterLineDesc");
$this->export_entities_array[$r]=array('s.rowid'=>"company",'s.nom'=>'company','s.address'=>'company','s.cp'=>'company','s.ville'=>'company','s.fk_pays'=>'company','s.tel'=>'company','s.siren'=>'company','s.siret'=>'company','s.ape'=>'company','s.idprof4'=>'company','s.code_compta'=>'company','s.code_compta_fournisseur'=>'company','f.rowid'=>"intervention",'f.ref'=>"intervention",'f.datec'=>"intervention",'f.duree'=>"intervention",'f.fk_statut'=>"intervention",'f.description'=>"intervention",'fd.rowid'=>"intervention",'fd.date'=>"inter_line",'fd.duree'=>'inter_line','fd.description'=>'inter_line');
$this->export_alias_array[$r]=array('s.rowid'=>"socid",'s.nom'=>'soc_name','s.address'=>'soc_adres','s.cp'=>'soc_zip','s.ville'=>'soc_ville','s.fk_pays'=>'soc_pays','s.tel'=>'soc_tel','s.siren'=>'soc_siren','s.siret'=>'soc_siret','s.ape'=>'soc_ape','s.idprof4'=>'soc_idprof4','s.code_compta'=>'soc_customer_accountancy','s.code_compta_fournisseur'=>'soc_supplier_accountancy','f.rowid'=>"interid",'f.ref'=>"ref",'f.datec'=>"datecreation",'f.duree'=>"duration",'f.fk_statut'=>'status','f.description'=>"note",'fd.rowid'=>'lineid','fd.date'=>"linedate",'fd.duree'=>'lineduration','fd.description'=>"linedescription");
$this->export_sql_start[$r]='SELECT DISTINCT ';
$this->export_sql_end[$r] =' FROM ('.MAIN_DB_PREFIX.'fichinter as f, '.MAIN_DB_PREFIX.'fichinterdet as fd, '.MAIN_DB_PREFIX.'societe as s)';
$this->export_sql_end[$r] .=' WHERE f.fk_soc = s.rowid AND f.rowid = fd.fk_fichinter';
$r++;
} }

View File

@@ -19,6 +19,18 @@ ConfirmValidateIntervention=
ConfirmDeleteInterventionLine=<3D>tes-vous s<>r de vouloir effacer cette ligne ? ConfirmDeleteInterventionLine=<3D>tes-vous s<>r de vouloir effacer cette ligne ?
NameAndSignatureOfInternalContact=Nom et signature de l'intervenant : NameAndSignatureOfInternalContact=Nom et signature de l'intervenant :
NameAndSignatureOfExternalContact=Nom et signature du client : NameAndSignatureOfExternalContact=Nom et signature du client :
InterventionCardsAndInterventionLines=Fiches interventions et lignes d'interventions
InterId=Id intervention
InterRef=R<>f. intervention
InterDateCreation=Date cr<63>ation
InterDuration=Dur<75>e totale
InterStatus=Statut
InterNote=Description
InterLine=Ligne intervention
InterLineId=Id ligne d<>tail
InterLineDate=Date ligne
InterLineDuration=Dur<75>e ligne
InterLineDesc=Description ligne
##### Types de contacts ##### ##### Types de contacts #####
TypeContact_fichinter_internal_INTERREPFOLL=Responsable suivi de l'intervention TypeContact_fichinter_internal_INTERREPFOLL=Responsable suivi de l'intervention
TypeContact_fichinter_internal_INTERVENING=Intervenant TypeContact_fichinter_internal_INTERVENING=Intervenant