mirror of
https://github.com/Dolibarr/dolibarr.git
synced 2025-02-20 13:46:52 +01:00
Debug tooltip of import tool
This commit is contained in:
parent
a16755b5c1
commit
3e9e17c746
|
|
@ -724,7 +724,7 @@ class modSociete extends DolibarrModules
|
|||
$i++;
|
||||
}
|
||||
|
||||
// Import list of contacts/additional addresses and attributes
|
||||
// Import list of contacts/addresses of thirparties and attributes
|
||||
$r++;
|
||||
$this->import_code[$r] = $this->rights_class.'_'.$r;
|
||||
$this->import_label[$r] = 'ImportDataset_company_2';
|
||||
|
|
@ -767,7 +767,7 @@ class modSociete extends DolibarrModules
|
|||
}
|
||||
}
|
||||
// Add extra fields
|
||||
$sql = "SELECT name, label, fieldrequired FROM ".MAIN_DB_PREFIX."extrafields WHERE type != 'separate' AND elementtype = 'socpeople' AND entity IN (0, ".$conf->entity.")";
|
||||
$sql = "SELECT name, label, fieldrequired FROM ".MAIN_DB_PREFIX."extrafields WHERE type <> 'separate' AND elementtype = 'socpeople' AND entity IN (0, ".$conf->entity.")";
|
||||
$resql = $this->db->query($sql);
|
||||
if ($resql) { // This can fail when class is used on an old database (during a migration for example)
|
||||
while ($obj = $this->db->fetch_object($resql)) {
|
||||
|
|
@ -794,7 +794,7 @@ class modSociete extends DolibarrModules
|
|||
'classfile' => '/core/class/cstate.class.php',
|
||||
'class' => 'Cstate',
|
||||
'method' => 'fetch',
|
||||
'dict' => 'DictionaryStateCode'
|
||||
'dict' => 'DictionaryCanton'
|
||||
),
|
||||
's.fk_pays' => array(
|
||||
'rule' => 'fetchidfromcodeid',
|
||||
|
|
|
|||
|
|
@ -1110,7 +1110,7 @@ if ($step == 4 && $datatoimport) {
|
|||
$height = '32px'; //needs px for css height attribute below
|
||||
$i = 0;
|
||||
$mandatoryfieldshavesource = true;
|
||||
$more = "";
|
||||
|
||||
//var_dump($fieldstarget);
|
||||
//var_dump($optionsall);
|
||||
//exit;
|
||||
|
|
@ -1176,10 +1176,10 @@ if ($step == 4 && $datatoimport) {
|
|||
$filecolumntoshow = num2Alpha($i);
|
||||
} else {
|
||||
if ($objimport->array_import_convertvalue[0][$tmpcode]['rule'] == 'fetchidfromref') {
|
||||
$htmltext .= $langs->trans("DataComeFromIdFoundFromRef", $filecolumn, $langs->transnoentitiesnoconv($entitylang)).'<br>';
|
||||
$htmltext .= $langs->trans("DataComeFromIdFoundFromRef", $langs->transnoentitiesnoconv($entitylang)).'<br>';
|
||||
}
|
||||
if ($objimport->array_import_convertvalue[0][$tmpcode]['rule'] == 'fetchidfromcodeid') {
|
||||
$htmltext .= $langs->trans("DataComeFromIdFoundFromCodeId", $filecolumn, $langs->transnoentitiesnoconv($objimport->array_import_convertvalue[0][$code]['dict'])).'<br>';
|
||||
$htmltext .= $langs->trans("DataComeFromIdFoundFromCodeId", $langs->transnoentitiesnoconv($objimport->array_import_convertvalue[0][$tmpcode]['dict'])).'<br>';
|
||||
}
|
||||
}
|
||||
// Source required
|
||||
|
|
@ -1191,9 +1191,9 @@ if ($step == 4 && $datatoimport) {
|
|||
}
|
||||
} else {
|
||||
if ($objimport->array_import_convertvalue[0][$tmpcode]['rule'] == 'fetchidfromref') {
|
||||
$htmltext .= $langs->trans("SourceExample").': <b>'.$langs->transnoentitiesnoconv("ExampleAnyRefFoundIntoElement", $entitylang).($example ? ' ('.$langs->transnoentitiesnoconv("Example").': '.$example.')' : '').'</b><br>';
|
||||
$htmltext .= $langs->trans("SourceExample").': <b>'.$langs->transnoentitiesnoconv("ExampleAnyRefFoundIntoElement", $entitylang).($example ? ' ('.$langs->transnoentitiesnoconv("Example").': '.str_replace('"', '', $example).')' : '').'</b><br>';
|
||||
} elseif ($objimport->array_import_convertvalue[0][$tmpcode]['rule'] == 'fetchidfromcodeid') {
|
||||
$htmltext .= $langs->trans("SourceExample").': <b>'.$langs->trans("ExampleAnyCodeOrIdFoundIntoDictionary", $langs->transnoentitiesnoconv($objimport->array_import_convertvalue[0][$code]['dict'])).($example ? ' ('.$langs->transnoentitiesnoconv("Example").': '.$example.')' : '').'</b><br>';
|
||||
$htmltext .= $langs->trans("SourceExample").': <b>'.$langs->trans("ExampleAnyCodeOrIdFoundIntoDictionary", $langs->transnoentitiesnoconv($objimport->array_import_convertvalue[0][$tmpcode]['dict'])).($example ? ' ('.$langs->transnoentitiesnoconv("Example").': '.str_replace('"', '', $example).')' : '').'</b><br>';
|
||||
} elseif ($example) {
|
||||
$htmltext .= $langs->trans("SourceExample").': <b>'.str_replace('"', '', $example).'</b><br>';
|
||||
}
|
||||
|
|
@ -1203,7 +1203,8 @@ if ($step == 4 && $datatoimport) {
|
|||
$htmltext .= $langs->trans("FormatControlRule").': <b>'.str_replace('"', '', $objimport->array_import_regex[0][$tmpcode]).'</b><br>';
|
||||
}
|
||||
|
||||
$htmltext .= $langs->trans("Table")."->".$langs->trans("Field").': <b>'.$tablename."->".preg_replace('/^.*\./', '', $tmpcode)."</b>";
|
||||
//var_dump($htmltext);
|
||||
$htmltext .= $langs->trans("InformationOnTargetTables").': <b>'.$tablename."->".preg_replace('/^.*\./', '', $tmpcode)."</b>";
|
||||
|
||||
$labelhtml = $label.' '.$form->textwithpicto('', $htmltext, 1, 'help', '', 1);
|
||||
|
||||
|
|
|
|||
|
|
@ -95,8 +95,8 @@ NbOfLinesOK=Number of lines with no errors and no warnings: <b>%s</b>.
|
|||
NbOfLinesImported=Number of lines successfully imported: <b>%s</b>.
|
||||
DataComeFromNoWhere=Value to insert comes from nowhere in source file.
|
||||
DataComeFromFileFieldNb=Value to insert comes from column <b>%s</b> in source file.
|
||||
DataComeFromIdFoundFromRef=Value that comes from column <b>%s</b> of source file will be used to find the id of the parent object to use (so the object <b>%s</b> that has the ref. from source file must exist in the database).
|
||||
DataComeFromIdFoundFromCodeId=Code that comes from column <b>%s</b> of source file will be used to find the id of the parent object to use (so the code from source file must exist in the dictionary <b>%s</b>). Note that if you know the id, you can also use it in the source file instead of the code. Import should work in both cases.
|
||||
DataComeFromIdFoundFromRef=The value that comes from the source file will be used to find the id of the parent object to use (so the object <b>%s</b> that has the ref. from source file must exist in the database).
|
||||
DataComeFromIdFoundFromCodeId=The value of code that comes from source file will be used to find the id of the parent object to use (so the code from source file must exist in the dictionary <b>%s</b>). Note that if you know the id, you can also use it in the source file instead of the code. Import should work in both cases.
|
||||
DataIsInsertedInto=Data coming from source file will be inserted into the following field:
|
||||
DataIDSourceIsInsertedInto=The id of the parent object, that was found using the data in the source file, will be inserted into the following field:
|
||||
DataCodeIDSourceIsInsertedInto=The id of the parent line, that was found from code, will be inserted into the following field:
|
||||
|
|
|
|||
|
|
@ -95,8 +95,8 @@ NbOfLinesOK=Nombre de lignes sans erreur ni avertissement : <b>%s</b>.
|
|||
NbOfLinesImported=Nombre de lignes importées avec succès : <b>%s</b>.
|
||||
DataComeFromNoWhere=La valeur à insérer n'est issue d'aucun champ du fichier source.
|
||||
DataComeFromFileFieldNb=La valeur à insérer provient de la colonne <b>%s</b> dans le fichier source.
|
||||
DataComeFromIdFoundFromRef=La valeur provenant de la colonne <b>%s</b> du fichier source sera utilisée pour trouver l'identifiant de l'objet parent à utiliser (donc l'objet <b>%s</b> qui a la référence du fichier source doit exister dans la base de données).
|
||||
DataComeFromIdFoundFromCodeId=Le code provenant de la colonne <b>%s</b> du fichier source sera utilisé pour trouver l'id de l'objet parent à utiliser (donc le code du fichier source doit exister dans le dictionnaire <b>%s</b> ). Notez que si vous connaissez l'identifiant, vous pouvez également l'utiliser dans le fichier source à la place du code. L'importation devrait fonctionner dans les deux cas.
|
||||
DataComeFromIdFoundFromRef=La valeur provenant du fichier source sera utilisée pour trouver l'identifiant de l'objet parent à utiliser (donc l'objet <b>%s</b> qui a la référence du fichier source doit exister dans la base de données).
|
||||
DataComeFromIdFoundFromCodeId=Le valeur du code provenant du fichier source sera utilisé pour trouver l'id de l'objet parent à utiliser (donc le code du fichier source doit exister dans le dictionnaire <b>%s</b> ). Notez que si vous connaissez l'identifiant, vous pouvez également l'utiliser dans le fichier source à la place du code. L'importation devrait fonctionner dans les deux cas.
|
||||
DataIsInsertedInto=La donnée issue du fichier source sera insérée dans le champ suivant:
|
||||
DataIDSourceIsInsertedInto=L'identifiant de l'objet père, retrouvé à partir de la donnée dans le fichier source, sera inséré dans le champ suivant :
|
||||
DataCodeIDSourceIsInsertedInto=L'identifiant de la ligne père, retrouvé à partir du code, sera inséré dans le champ suivant :
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user