New: Support property "required" for extra fields.
This commit is contained in:
parent
a60516ae0d
commit
cbff238cbd
@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/* Copyright (C) 2001-2002 Rodolphe Quiedeville <rodolphe@quiedeville.org>
|
||||
* Copyright (C) 2003 Jean-Louis Bergamo <jlb@j1b.org>
|
||||
* Copyright (C) 2004-2011 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
* Copyright (C) 2004-2012 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
* Copyright (C) 2012 Regis Houssin <regis@dolibarr.fr>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
@ -88,7 +88,8 @@ print '<td>'.$langs->trans("Label").'</td>';
|
||||
print '<td>'.$langs->trans("AttributeCode").'</td>';
|
||||
print '<td>'.$langs->trans("Type").'</td>';
|
||||
print '<td align="right">'.$langs->trans("Size").'</td>';
|
||||
print '<td align="right">'.$langs->trans("Unique").'</td>';
|
||||
print '<td align="center">'.$langs->trans("Unique").'</td>';
|
||||
print '<td align="center">'.$langs->trans("Required").'</td>';
|
||||
print '<td width="80"> </td>';
|
||||
print "</tr>\n";
|
||||
|
||||
@ -101,7 +102,8 @@ foreach($extrafields->attribute_type as $key => $value)
|
||||
print "<td>".$key."</td>\n";
|
||||
print "<td>".$type2label[$extrafields->attribute_type[$key]]."</td>\n";
|
||||
print '<td align="right">'.$extrafields->attribute_size[$key]."</td>\n";
|
||||
print '<td align="right">'.yn($extrafields->attribute_unique[$key])."</td>\n";
|
||||
print '<td align="center">'.yn($extrafields->attribute_unique[$key])."</td>\n";
|
||||
print '<td align="center">'.yn($extrafields->attribute_required[$key])."</td>\n";
|
||||
print '<td align="right"><a href="'.$_SERVER["PHP_SELF"].'?action=edit&attrname='.$key.'">'.img_edit().'</a>';
|
||||
print " <a href=\"".$_SERVER["PHP_SELF"]."?action=delete&attrname=".$key."\">".img_delete()."</a></td>\n";
|
||||
print "</tr>";
|
||||
@ -149,7 +151,7 @@ if ($action == 'edit' && ! empty($attrname))
|
||||
require DOL_DOCUMENT_ROOT.'/core/tpl/admin_extrafields_edit.tpl.php';
|
||||
}
|
||||
|
||||
$db->close();
|
||||
|
||||
llxFooter();
|
||||
|
||||
$db->close();
|
||||
?>
|
||||
|
||||
@ -906,7 +906,9 @@ else
|
||||
foreach($extrafields->attribute_label as $key=>$label)
|
||||
{
|
||||
$value=(isset($_POST["options_".$key])?GETPOST('options_'.$key,'alpha'):$object->array_options["options_".$key]);
|
||||
print '<tr><td>'.$label.'</td><td>';
|
||||
print '<tr><td';
|
||||
if (! empty($extrafields->attribute_required[$key])) print ' class="fieldrequired"';
|
||||
print '>'.$label.'</td><td>';
|
||||
print $extrafields->showInputField($key,$value);
|
||||
print '</td></tr>'."\n";
|
||||
}
|
||||
@ -1150,7 +1152,9 @@ else
|
||||
foreach($extrafields->attribute_label as $key=>$label)
|
||||
{
|
||||
$value=(isset($_POST["options_".$key])?$_POST["options_".$key]:$object->array_options["options_".$key]);
|
||||
print '<tr><td>'.$label.'</td><td>';
|
||||
print '<tr><td';
|
||||
if (! empty($extrafields->attribute_required[$key])) print ' class="fieldrequired"';
|
||||
print '>'.$label.'</td><td>';
|
||||
print $extrafields->showInputField($key,$value);
|
||||
print '</td></tr>'."\n";
|
||||
}
|
||||
|
||||
@ -237,7 +237,9 @@ if ($action == 'create')
|
||||
foreach($extrafields->attribute_label as $key=>$label)
|
||||
{
|
||||
$value=(isset($_POST["options_".$key])?$_POST["options_".$key]:$object->array_options["options_".$key]);
|
||||
print "<tr><td>".$label.'</td><td colspan="3">';
|
||||
print '<tr><td';
|
||||
if (! empty($extrafields->attribute_required[$key])) print ' class="fieldrequired"';
|
||||
print '>'.$label.'</td><td colspan="3">';
|
||||
print $extrafields->showInputField($key,$value);
|
||||
print '</td></tr>'."\n";
|
||||
}
|
||||
|
||||
@ -650,7 +650,9 @@ if ($action == 'create')
|
||||
foreach($extrafields->attribute_label as $key=>$label)
|
||||
{
|
||||
$value=(isset($_POST["options_".$key])?$_POST["options_".$key]:$object->array_options["options_".$key]);
|
||||
print '<tr><td>'.$label.'</td><td colspan="3">';
|
||||
print '<tr><td';
|
||||
if (! empty($extrafields->attribute_required[$key])) print ' class="fieldrequired"';
|
||||
print '>'.$label.'</td><td colspan="3">';
|
||||
print $extrafields->showInputField($key,$value);
|
||||
print '</td></tr>'."\n";
|
||||
}
|
||||
@ -810,7 +812,9 @@ else
|
||||
foreach($extrafields->attribute_label as $key=>$label)
|
||||
{
|
||||
$value=(isset($_POST["options_".$key])?$_POST["options_".$key]:$object->array_options["options_".$key]);
|
||||
print '<tr><td>'.$label.'</td><td colspan="3">';
|
||||
print '<tr><td';
|
||||
if (! empty($extrafields->attribute_required[$key])) print ' class="fieldrequired"';
|
||||
print '>'.$label.'</td><td colspan="3">';
|
||||
print $extrafields->showInputField($key,$value);
|
||||
print "</td></tr>\n";
|
||||
}
|
||||
@ -1044,7 +1048,9 @@ else
|
||||
foreach($extrafields->attribute_label as $key=>$label)
|
||||
{
|
||||
$value=(isset($_POST["options_".$key])?$_POST["options_".$key]:$object->array_options["options_".$key]);
|
||||
print '<tr><td>'.$label.'</td><td colspan="3">';
|
||||
print '<tr><td';
|
||||
if (! empty($extrafields->attribute_required[$key])) print ' class="fieldrequired"';
|
||||
print '>'.$label.'</td><td colspan="3">';
|
||||
print $extrafields->showInputField($key,$value);
|
||||
print "</td></tr>\n";
|
||||
}
|
||||
|
||||
@ -1538,7 +1538,9 @@ if (empty($reshook) && ! empty($extrafields->attribute_label))
|
||||
foreach($extrafields->attribute_label as $key=>$label)
|
||||
{
|
||||
$value=(isset($_POST["options_".$key])?$_POST["options_".$key]:$object->array_options["options_".$key]);
|
||||
print "<tr><td>".$label.'</td><td colspan="3">';
|
||||
print '<tr><td';
|
||||
if (! empty($extrafields->attribute_required[$key])) print ' class="fieldrequired"';
|
||||
print '>'.$label.'</td><td colspan="3">';
|
||||
print $extrafields->showInputField($key,$value);
|
||||
print '</td></tr>'."\n";
|
||||
}
|
||||
|
||||
@ -1517,7 +1517,9 @@ if ($action == 'send' && ! GETPOST('addfile') && ! GETPOST('removedfile') && ! G
|
||||
foreach($extrafields->attribute_label as $key=>$label)
|
||||
{
|
||||
$value=(isset($_POST["options_".$key])?$_POST["options_".$key]:$object->array_options["options_".$key]);
|
||||
print "<tr><td>".$label.'</td><td colspan="3">';
|
||||
print '<tr><td';
|
||||
if (! empty($extrafields->attribute_required[$key])) print ' class="fieldrequired"';
|
||||
print '>'.$label.'</td><td colspan="3">';
|
||||
print $extrafields->showInputField($key,$value);
|
||||
print '</td></tr>'."\n";
|
||||
}
|
||||
@ -2047,7 +2049,9 @@ if ($action == 'send' && ! GETPOST('addfile') && ! GETPOST('removedfile') && ! G
|
||||
foreach($extrafields->attribute_label as $key=>$label)
|
||||
{
|
||||
$value=(isset($_POST["options_".$key])?$_POST["options_".$key]:$object->array_options["options_".$key]);
|
||||
print '<tr><td>'.$label.'</td><td colspan="3">';
|
||||
print '<tr><td';
|
||||
if (! empty($extrafields->attribute_required[$key])) print ' class="fieldrequired"';
|
||||
print '>'.$label.'</td><td colspan="3">';
|
||||
print $extrafields->showInputField($key,$value);
|
||||
print '</td></tr>'."\n";
|
||||
}
|
||||
|
||||
@ -2003,7 +2003,9 @@ if ($action == 'create')
|
||||
foreach($extrafields->attribute_label as $key=>$label)
|
||||
{
|
||||
$value=(isset($_POST["options_".$key])?$_POST["options_".$key]:$object->array_options["options_".$key]);
|
||||
print '<tr><td>'.$label.'</td><td colspan="3">';
|
||||
print '<tr><td';
|
||||
if (! empty($extrafields->attribute_required[$key])) print ' class="fieldrequired"';
|
||||
print '>'.$label.'</td><td colspan="3">';
|
||||
print $extrafields->showInputField($key,$value);
|
||||
print '</td></tr>'."\n";
|
||||
}
|
||||
@ -2970,7 +2972,9 @@ else if ($id > 0 || ! empty($ref))
|
||||
foreach($extrafields->attribute_label as $key=>$label)
|
||||
{
|
||||
$value=(isset($_POST["options_".$key])?$_POST["options_".$key]:$object->array_options["options_".$key]);
|
||||
print '<tr><td>'.$label.'</td><td colspan="3">';
|
||||
print '<tr><td';
|
||||
if (! empty($extrafields->attribute_required[$key])) print ' class="fieldrequired"';
|
||||
print '>'.$label.'</td><td colspan="3">';
|
||||
print $extrafields->showInputField($key,$value);
|
||||
print '</td></tr>'."\n";
|
||||
}
|
||||
|
||||
@ -432,30 +432,36 @@ else
|
||||
|
||||
print '<tr><td>'.$langs->trans("PostOrFunction").'</td><td colspan="3"><input name="poste" type="text" size="50" maxlength="80" value="'.(isset($_POST["poste"])?$_POST["poste"]:$object->poste).'"></td>';
|
||||
|
||||
$colspan=3;
|
||||
if ($conf->use_javascript_ajax && $socid > 0) $colspan=2;
|
||||
|
||||
// Address
|
||||
if (($objsoc->typent_code == 'TE_PRIVATE' || ! empty($conf->global->CONTACT_USE_COMPANY_ADDRESS)) && dol_strlen(trim($object->address)) == 0) $object->address = $objsoc->address; // Predefined with third party
|
||||
print '<tr><td>'.$langs->trans("Address");
|
||||
print '</td><td colspan="2"><textarea class="flat" name="address" cols="70">'.(isset($_POST["address"])?$_POST["address"]:$object->address).'</textarea></td>';
|
||||
print '</td><td colspan="'.$colspan.'"><textarea class="flat" name="address" cols="70">'.(isset($_POST["address"])?$_POST["address"]:$object->address).'</textarea></td>';
|
||||
|
||||
$rowspan=3;
|
||||
if (empty($conf->global->SOCIETE_DISABLE_STATE)) $rowspan++;
|
||||
|
||||
print '<td valign="middle" align="center" rowspan="'.$rowspan.'">';
|
||||
if ($conf->use_javascript_ajax && $socid) print '<a href="#" id="copyaddressfromsoc">'.$langs->trans('CopyAddressFromSoc').'</a>';
|
||||
print '</td>';
|
||||
if ($conf->use_javascript_ajax && $socid > 0)
|
||||
{
|
||||
$rowspan=3;
|
||||
if (empty($conf->global->SOCIETE_DISABLE_STATE)) $rowspan++;
|
||||
|
||||
print '<td valign="middle" align="center" rowspan="'.$rowspan.'">';
|
||||
print '<a href="#" id="copyaddressfromsoc">'.$langs->trans('CopyAddressFromSoc').'</a>';
|
||||
print '</td>';
|
||||
}
|
||||
print '</tr>';
|
||||
|
||||
// Zip / Town
|
||||
if (($objsoc->typent_code == 'TE_PRIVATE' || ! empty($conf->global->CONTACT_USE_COMPANY_ADDRESS)) && dol_strlen(trim($object->zip)) == 0) $object->zip = $objsoc->zip; // Predefined with third party
|
||||
if (($objsoc->typent_code == 'TE_PRIVATE' || ! empty($conf->global->CONTACT_USE_COMPANY_ADDRESS)) && dol_strlen(trim($object->town)) == 0) $object->town = $objsoc->town; // Predefined with third party
|
||||
print '<tr><td>'.$langs->trans("Zip").' / '.$langs->trans("Town").'</td><td colspan="2">';
|
||||
print '<tr><td>'.$langs->trans("Zip").' / '.$langs->trans("Town").'</td><td colspan="'.$colspan.'">';
|
||||
print $formcompany->select_ziptown((isset($_POST["zipcode"])?$_POST["zipcode"]:$object->zip),'zipcode',array('town','selectcountry_id','state_id'),6).' ';
|
||||
print $formcompany->select_ziptown((isset($_POST["town"])?$_POST["town"]:$object->town),'town',array('zipcode','selectcountry_id','state_id'));
|
||||
print '</td></tr>';
|
||||
|
||||
// Country
|
||||
if (dol_strlen(trim($object->fk_pays)) == 0) $object->fk_pays = $objsoc->country_id; // Predefined with third party
|
||||
print '<tr><td>'.$langs->trans("Country").'</td><td colspan="2">';
|
||||
print '<tr><td>'.$langs->trans("Country").'</td><td colspan="'.$colspan.'">';
|
||||
print $form->select_country((isset($_POST["country_id"])?$_POST["country_id"]:$object->country_id),'country_id');
|
||||
if ($user->admin) print info_admin($langs->trans("YouCanChangeValuesForThisListFromDictionnarySetup"),1);
|
||||
print '</td></tr>';
|
||||
@ -463,7 +469,7 @@ else
|
||||
// State
|
||||
if (empty($conf->global->SOCIETE_DISABLE_STATE))
|
||||
{
|
||||
print '<tr><td>'.$langs->trans('State').'</td><td colspan="2">';
|
||||
print '<tr><td>'.$langs->trans('State').'</td><td colspan="'.$colspan.'">';
|
||||
if ($object->country_id)
|
||||
{
|
||||
print $formcompany->select_state(isset($_POST["state_id"])?$_POST["state_id"]:$object->state_id,$object->country_code,'state_id');
|
||||
@ -517,7 +523,9 @@ else
|
||||
foreach($extrafields->attribute_label as $key=>$label)
|
||||
{
|
||||
$value=(isset($_POST["options_".$key])?$_POST["options_".$key]:(isset($object->array_options["options_".$key])?$object->array_options["options_".$key]:''));
|
||||
print '<tr><td>'.$label.'</td><td colspan="3">';
|
||||
print '<tr><td';
|
||||
if (! empty($extrafields->attribute_required[$key])) print ' class="fieldrequired"';
|
||||
print '>'.$label.'</td><td colspan="3">';
|
||||
print $extrafields->showInputField($key,$value);
|
||||
print '</td></tr>'."\n";
|
||||
}
|
||||
@ -732,7 +740,9 @@ else
|
||||
foreach($extrafields->attribute_label as $key=>$label)
|
||||
{
|
||||
$value=(isset($_POST["options_".$key])?$_POST["options_".$key]:$object->array_options["options_".$key]);
|
||||
print '<tr><td>'.$label.'</td><td colspan="3">';
|
||||
print '<tr><td';
|
||||
if (! empty($extrafields->attribute_required[$key])) print ' class="fieldrequired"';
|
||||
print '>'.$label.'</td><td colspan="3">';
|
||||
print $extrafields->showInputField($key,$value);
|
||||
print "</td></tr>\n";
|
||||
}
|
||||
|
||||
@ -64,7 +64,7 @@ if ($action == 'add')
|
||||
// Type et taille non encore pris en compte => varchar(255)
|
||||
if (isset($_POST["attrname"]) && preg_match("/^\w[a-zA-Z0-9-_]*$/",$_POST['attrname']))
|
||||
{
|
||||
$result=$extrafields->addExtraField($_POST['attrname'],$_POST['label'],$_POST['type'],$_POST['pos'],$extrasize,$elementtype,(GETPOST('unique')?1:0));
|
||||
$result=$extrafields->addExtraField($_POST['attrname'],$_POST['label'],$_POST['type'],$_POST['pos'],$extrasize,$elementtype,(GETPOST('unique')?1:0),(GETPOST('required')?1:0));
|
||||
if ($result > 0)
|
||||
{
|
||||
header("Location: ".$_SERVER["PHP_SELF"]);
|
||||
@ -119,7 +119,7 @@ if ($action == 'update')
|
||||
{
|
||||
if (isset($_POST["attrname"]) && preg_match("/^\w[a-zA-Z0-9-_]*$/",$_POST['attrname']))
|
||||
{
|
||||
$result=$extrafields->update($_POST['attrname'],$_POST['label'],$_POST['type'],$extrasize,$elementtype,(GETPOST('unique')?1:0));
|
||||
$result=$extrafields->update($_POST['attrname'],$_POST['label'],$_POST['type'],$extrasize,$elementtype,(GETPOST('unique')?1:0),(GETPOST('required')?1:0));
|
||||
if ($result > 0)
|
||||
{
|
||||
header("Location: ".$_SERVER["PHP_SELF"]);
|
||||
|
||||
@ -91,7 +91,7 @@ class ExtraFields
|
||||
if (empty($label)) return -1;
|
||||
|
||||
// Create field into database
|
||||
$result=$this->create($attrname,$type,$size,$elementtype, $unique);
|
||||
$result=$this->create($attrname,$type,$size,$elementtype, $unique, $required);
|
||||
$err1=$this->errno;
|
||||
if ($result > 0 || $err1 == 'DB_ERROR_COLUMN_ALREADY_EXISTS')
|
||||
{
|
||||
@ -361,7 +361,7 @@ class ExtraFields
|
||||
private function update_label($attrname,$label,$type,$size,$elementtype,$unique=0,$required=0)
|
||||
{
|
||||
global $conf;
|
||||
dol_syslog(get_class($this)."::update_label $attrname,$label,$type,$size");
|
||||
dol_syslog(get_class($this)."::update_label ".$attrname.", ".$label.", ".$type.", ".$size.", ".$elementtype.", ".$unique.", ".$required);
|
||||
|
||||
if (isset($attrname) && $attrname != '' && preg_match("/^\w[a-zA-Z0-9-_]*$/",$attrname))
|
||||
{
|
||||
|
||||
@ -1011,7 +1011,8 @@ class DoliDBMysql
|
||||
$sql = "ALTER TABLE ".$table;
|
||||
$sql .= " MODIFY COLUMN ".$field_name." ".$field_desc['type'];
|
||||
if ($field_desc['type'] == 'int' || $field_desc['type'] == 'varchar') $sql.="(".$field_desc['value'].")";
|
||||
|
||||
if ($field_desc['null'] == 'not null' || $field_desc['null'] == 'NOT NULL') $sql.=" NOT NULL";
|
||||
|
||||
dol_syslog(get_class($this)."::DDLUpdateField ".$sql,LOG_DEBUG);
|
||||
if (! $this->query($sql))
|
||||
return -1;
|
||||
|
||||
@ -1005,7 +1005,8 @@ class DoliDBMysqli
|
||||
$sql = "ALTER TABLE ".$table;
|
||||
$sql .= " MODIFY COLUMN ".$field_name." ".$field_desc['type'];
|
||||
if ($field_desc['type'] == 'int' || $field_desc['type'] == 'varchar') $sql.="(".$field_desc['value'].")";
|
||||
|
||||
if ($field_desc['null'] == 'not null' || $field_desc['null'] == 'NOT NULL') $sql.=" NOT NULL";
|
||||
|
||||
dol_syslog(get_class($this)."::DDLUpdateField ".$sql,LOG_DEBUG);
|
||||
if (! $this->query($sql))
|
||||
return -1;
|
||||
|
||||
@ -1221,6 +1221,9 @@ class DoliDBPgsql
|
||||
$sql .= " MODIFY COLUMN ".$field_name." ".$field_desc['type'];
|
||||
if ($field_desc['type'] == 'int' || $field_desc['type'] == 'varchar') $sql.="(".$field_desc['value'].")";
|
||||
|
||||
// FIXME May not work with pgsql. May need to run a second request. If it works, just remove the FIXME tag
|
||||
if ($field_desc['null'] == 'not null' || $field_desc['null'] == 'NOT NULL') $sql.=" NOT NULL";
|
||||
|
||||
dol_syslog($sql,LOG_DEBUG);
|
||||
if (! $this->query($sql))
|
||||
return -1;
|
||||
|
||||
@ -23,12 +23,14 @@
|
||||
function init_typeoffields(type)
|
||||
{
|
||||
var size = jQuery("#size");
|
||||
if (type == 'date') { size.val('').attr('disabled','disabled'); }
|
||||
else if (type == 'datetime') { size.val('').attr('disabled','disabled'); }
|
||||
else if (type == 'double') { size.val('24,8').removeAttr('disabled'); }
|
||||
else if (type == 'int') { size.val('10').removeAttr('disabled'); }
|
||||
else if (type == 'text') { size.val('2000').removeAttr('disabled'); }
|
||||
else if (type == 'varchar') { size.val('255').removeAttr('disabled'); }
|
||||
var unique = jQuery("#unique");
|
||||
var required = jQuery("#required");
|
||||
if (type == 'date') { size.val('').attr('disabled','disabled'); unique.removeAttr('disabled','disabled'); }
|
||||
else if (type == 'datetime') { size.val('').attr('disabled','disabled'); unique.removeAttr('disabled','disabled'); }
|
||||
else if (type == 'double') { size.val('24,8').removeAttr('disabled'); unique.removeAttr('disabled','disabled'); }
|
||||
else if (type == 'int') { size.val('10').removeAttr('disabled'); unique.removeAttr('disabled','disabled'); }
|
||||
else if (type == 'text') { size.val('2000').removeAttr('disabled'); unique.attr('disabled','disabled').removeAttr('checked'); }
|
||||
else if (type == 'varchar') { size.val('255').removeAttr('disabled'); unique.removeAttr('disabled','disabled'); }
|
||||
else size.val('').attr('disabled','disabled');
|
||||
}
|
||||
init_typeoffields('');
|
||||
@ -55,7 +57,9 @@
|
||||
<!-- Size -->
|
||||
<tr><td class="fieldrequired"><?php echo $langs->trans("Size"); ?></td><td class="valeur"><input id="size" type="text" name="size" size="5" value="<?php echo (GETPOST('size')?GETPOST('size'):''); ?>"></td></tr>
|
||||
<!-- Unique -->
|
||||
<tr><td><?php echo $langs->trans("Unique"); ?></td><td class="valeur"><input type="checkbox" name="unique" <?php echo (GETPOST('unique')?' checked="true"':''); ?>"></td></tr>
|
||||
<tr><td><?php echo $langs->trans("Unique"); ?></td><td class="valeur"><input id="unique" type="checkbox" name="unique" <?php echo (GETPOST('unique')?' checked="true"':''); ?>></td></tr>
|
||||
<!-- Required -->
|
||||
<tr><td><?php echo $langs->trans("Required"); ?></td><td class="valeur"><input id="required" type="checkbox" name="required" <?php echo (GETPOST('required')?' checked="true"':''); ?>></td></tr>
|
||||
</table>
|
||||
|
||||
<div align="center"><br><input type="submit" name="button" class="button" value="<?php echo $langs->trans("Save"); ?>">
|
||||
|
||||
@ -23,11 +23,13 @@
|
||||
function init_typeoffields(type)
|
||||
{
|
||||
var size = jQuery("#size");
|
||||
var unique = jQuery("#unique");
|
||||
var required = jQuery("#required");
|
||||
if (type == 'date') { size.attr('disabled','disabled'); }
|
||||
else if (type == 'datetime') { size.attr('disabled','disabled'); }
|
||||
else if (type == 'double') { size.removeAttr('disabled'); }
|
||||
else if (type == 'int') { size.removeAttr('disabled'); }
|
||||
else if (type == 'text') { size.removeAttr('disabled'); }
|
||||
else if (type == 'text') { size.removeAttr('disabled'); unique.attr('disabled','disabled').removeAttr('checked'); }
|
||||
else if (type == 'varchar') { size.removeAttr('disabled'); }
|
||||
else size.val('').attr('disabled','disabled');
|
||||
}
|
||||
@ -52,6 +54,7 @@
|
||||
$type=$extrafields->attribute_type[$attrname];
|
||||
$size=$extrafields->attribute_size[$attrname];
|
||||
$unique=$extrafields->attribute_unique[$attrname];
|
||||
$required=$extrafields->attribute_required[$attrname];
|
||||
?>
|
||||
<tr><td class="fieldrequired"><?php echo $langs->trans("Type"); ?></td><td class="valeur">
|
||||
<?php print $type2label[$type]; ?>
|
||||
@ -60,7 +63,9 @@ $unique=$extrafields->attribute_unique[$attrname];
|
||||
<!-- Size -->
|
||||
<tr><td class="fieldrequired"><?php echo $langs->trans("Size"); ?></td><td><input id="size" type="text" name="size" size="5" value="<?php echo $size; ?>"></td></tr>
|
||||
<!-- Unique -->
|
||||
<tr><td><?php echo $langs->trans("Unique"); ?></td><td class="valeur"><input type="checkbox" name="unique" <?php echo ($unique?' checked="true"':''); ?>"></td></tr>
|
||||
<tr><td><?php echo $langs->trans("Unique"); ?></td><td class="valeur"><input id="unique" type="checkbox" name="unique" <?php echo ($unique?' checked="true"':''); ?>></td></tr>
|
||||
<!-- Required -->
|
||||
<tr><td><?php echo $langs->trans("Required"); ?></td><td class="valeur"><input id="required" type="checkbox" name="required" <?php echo ($required?' checked="true"':''); ?>></td></tr>
|
||||
|
||||
</table>
|
||||
|
||||
|
||||
@ -101,7 +101,8 @@ print '<td>'.$langs->trans("Label").'</td>';
|
||||
print '<td>'.$langs->trans("AttributeCode").'</td>';
|
||||
print '<td>'.$langs->trans("Type").'</td>';
|
||||
print '<td align="right">'.$langs->trans("Size").'</td>';
|
||||
print '<td align="right">'.$langs->trans("Unique").'</td>';
|
||||
print '<td align="center">'.$langs->trans("Unique").'</td>';
|
||||
print '<td align="center">'.$langs->trans("Required").'</td>';
|
||||
print '<td width="80"> </td>';
|
||||
print "</tr>\n";
|
||||
|
||||
@ -114,7 +115,8 @@ foreach($extrafields->attribute_type as $key => $value)
|
||||
print "<td>".$key."</td>\n";
|
||||
print "<td>".$type2label[$extrafields->attribute_type[$key]]."</td>\n";
|
||||
print '<td align="right">'.$extrafields->attribute_size[$key]."</td>\n";
|
||||
print '<td align="right">'.yn($extrafields->attribute_unique[$key])."</td>\n";
|
||||
print '<td align="center">'.yn($extrafields->attribute_unique[$key])."</td>\n";
|
||||
print '<td align="center">'.yn($extrafields->attribute_required[$key])."</td>\n";
|
||||
print '<td align="right"><a href="'.$_SERVER["PHP_SELF"].'?action=edit&attrname='.$key.'">'.img_edit().'</a>';
|
||||
print " <a href=\"".$_SERVER["PHP_SELF"]."?action=delete&attrname=$key\">".img_delete()."</a></td>\n";
|
||||
print "</tr>";
|
||||
@ -159,42 +161,7 @@ if ($action == 'edit' && ! empty($attrname))
|
||||
print "<br>";
|
||||
print_titre($langs->trans("FieldEdition", $attrname));
|
||||
|
||||
/*
|
||||
* formulaire d'edition
|
||||
*/
|
||||
print '<form method="post" action="'.$_SERVER["PHP_SELF"].'?attrname='.$attrname.'">';
|
||||
print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';
|
||||
print '<input type="hidden" name="attrname" value="'.$attrname.'">';
|
||||
print '<input type="hidden" name="action" value="update">';
|
||||
print '<table summary="listofattributes" class="border" width="100%">';
|
||||
|
||||
// Label
|
||||
print '<tr>';
|
||||
print '<td class="fieldrequired" required>'.$langs->trans("Label").'</td><td class="valeur"><input type="text" name="label" size="40" value="'.$extrafields->attribute_label[$attrname].'"></td>';
|
||||
print '</tr>';
|
||||
// Code
|
||||
print '<tr>';
|
||||
print '<td class="fieldrequired" required>'.$langs->trans("AttributeCode").'</td>';
|
||||
print '<td class="valeur">'.$attrname.' </td>';
|
||||
print '</tr>';
|
||||
// Type
|
||||
$type=$extrafields->attribute_type[$attrname];
|
||||
$size=$extrafields->attribute_size[$attrname];
|
||||
print '<tr><td class="fieldrequired" required>'.$langs->trans("Type").'</td>';
|
||||
print '<td class="valeur">';
|
||||
print $type2label[$type];
|
||||
print '<input type="hidden" name="type" value="'.$type.'">';
|
||||
print '</td></tr>';
|
||||
// Size
|
||||
print '<tr><td class="fieldrequired" required>'.$langs->trans("Size").'</td><td class="valeur"><input type="text" name="size" size="5" value="'.$size.'"></td></tr>';
|
||||
|
||||
print '</table>';
|
||||
|
||||
print '<center><br><input type="submit" name="button" class="button" value="'.$langs->trans("Save").'"> ';
|
||||
print '<input type="submit" name="button" class="button" value="'.$langs->trans("Cancel").'"></center>';
|
||||
|
||||
print "</form>";
|
||||
|
||||
require DOL_DOCUMENT_ROOT.'/core/tpl/admin_extrafields_edit.tpl.php';
|
||||
}
|
||||
|
||||
llxFooter();
|
||||
|
||||
@ -828,7 +828,9 @@ else
|
||||
foreach($extrafields->attribute_label as $key=>$label)
|
||||
{
|
||||
$value=(GETPOST('options_'.$key)?GETPOST('options_'.$key):$object->array_options["options_".$key]);
|
||||
print '<tr><td>'.$label.'</td><td colspan="3">';
|
||||
print '<tr><td';
|
||||
if (! empty($extrafields->attribute_required[$key])) print ' class="fieldrequired"';
|
||||
print '>'.$label.'</td><td colspan="3">';
|
||||
print $extrafields->showInputField($key,$value);
|
||||
print '</td></tr>'."\n";
|
||||
}
|
||||
@ -1037,7 +1039,9 @@ else
|
||||
foreach($extrafields->attribute_label as $key=>$label)
|
||||
{
|
||||
$value=(isset($_POST["options_".$key])?$_POST["options_".$key]:$object->array_options["options_".$key]);
|
||||
print '<tr><td>'.$label.'</td><td colspan="3">';
|
||||
print '<tr><td';
|
||||
if (! empty($extrafields->attribute_required[$key])) print ' class="fieldrequired"';
|
||||
print '>'.$label.'</td><td colspan="3">';
|
||||
print $extrafields->showInputField($key,$value);
|
||||
print '</td></tr>'."\n";
|
||||
}
|
||||
|
||||
@ -88,7 +88,8 @@ print '<td>'.$langs->trans("Label").'</td>';
|
||||
print '<td>'.$langs->trans("AttributeCode").'</td>';
|
||||
print '<td>'.$langs->trans("Type").'</td>';
|
||||
print '<td align="right">'.$langs->trans("Size").'</td>';
|
||||
print '<td align="right">'.$langs->trans("Unique").'</td>';
|
||||
print '<td align="center">'.$langs->trans("Unique").'</td>';
|
||||
print '<td align="center">'.$langs->trans("Required").'</td>';
|
||||
print '<td width="80"> </td>';
|
||||
print "</tr>\n";
|
||||
|
||||
@ -101,7 +102,8 @@ foreach($extrafields->attribute_type as $key => $value)
|
||||
print "<td>".$key."</td>\n";
|
||||
print "<td>".$type2label[$extrafields->attribute_type[$key]]."</td>\n";
|
||||
print '<td align="right">'.$extrafields->attribute_size[$key]."</td>\n";
|
||||
print '<td align="right">'.yn($extrafields->attribute_unique[$key])."</td>\n";
|
||||
print '<td align="center">'.yn($extrafields->attribute_unique[$key])."</td>\n";
|
||||
print '<td align="center">'.yn($extrafields->attribute_required[$key])."</td>\n";
|
||||
print '<td align="right"><a href="'.$_SERVER["PHP_SELF"].'?action=edit&attrname='.$key.'">'.img_edit().'</a>';
|
||||
print " <a href=\"".$_SERVER["PHP_SELF"]."?action=delete&attrname=$key\">".img_delete()."</a></td>\n";
|
||||
print "</tr>";
|
||||
@ -146,42 +148,7 @@ if ($action == 'edit' && ! empty($attrname))
|
||||
print "<br>";
|
||||
print_titre($langs->trans("FieldEdition", $attrname));
|
||||
|
||||
/*
|
||||
* formulaire d'edition
|
||||
*/
|
||||
print '<form method="post" action="'.$_SERVER["PHP_SELF"].'?attrname='.$attrname.'">';
|
||||
print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';
|
||||
print '<input type="hidden" name="attrname" value="'.$attrname.'">';
|
||||
print '<input type="hidden" name="action" value="update">';
|
||||
print '<table summary="listofattributes" class="border" width="100%">';
|
||||
|
||||
// Label
|
||||
print '<tr>';
|
||||
print '<td class="fieldrequired" required>'.$langs->trans("Label").'</td><td class="valeur"><input type="text" name="label" size="40" value="'.$extrafields->attribute_label[$attrname].'"></td>';
|
||||
print '</tr>';
|
||||
// Code
|
||||
print '<tr>';
|
||||
print '<td class="fieldrequired" required>'.$langs->trans("AttributeCode").'</td>';
|
||||
print '<td class="valeur">'.$attrname.' </td>';
|
||||
print '</tr>';
|
||||
// Type
|
||||
$type=$extrafields->attribute_type[$attrname];
|
||||
$size=$extrafields->attribute_size[$attrname];
|
||||
print '<tr><td class="fieldrequired" required>'.$langs->trans("Type").'</td>';
|
||||
print '<td class="valeur">';
|
||||
print $type2label[$type];
|
||||
print '<input type="hidden" name="type" value="'.$type.'">';
|
||||
print '</td></tr>';
|
||||
// Size
|
||||
print '<tr><td class="fieldrequired" required>'.$langs->trans("Size").'</td><td class="valeur"><input type="text" name="size" size="5" value="'.$size.'"></td></tr>';
|
||||
|
||||
print '</table>';
|
||||
|
||||
print '<center><br><input type="submit" name="button" class="button" value="'.$langs->trans("Save").'"> ';
|
||||
print '<input type="submit" name="button" class="button" value="'.$langs->trans("Cancel").'"></center>';
|
||||
|
||||
print "</form>";
|
||||
|
||||
require DOL_DOCUMENT_ROOT.'/core/tpl/admin_extrafields_edit.tpl.php';
|
||||
}
|
||||
|
||||
llxFooter();
|
||||
|
||||
@ -88,7 +88,8 @@ print '<td>'.$langs->trans("Label").'</td>';
|
||||
print '<td>'.$langs->trans("AttributeCode").'</td>';
|
||||
print '<td>'.$langs->trans("Type").'</td>';
|
||||
print '<td align="right">'.$langs->trans("Size").'</td>';
|
||||
print '<td align="right">'.$langs->trans("Unique").'</td>';
|
||||
print '<td align="center">'.$langs->trans("Unique").'</td>';
|
||||
print '<td align="center">'.$langs->trans("Required").'</td>';
|
||||
print '<td width="80"> </td>';
|
||||
print "</tr>\n";
|
||||
|
||||
@ -101,7 +102,8 @@ foreach($extrafields->attribute_type as $key => $value)
|
||||
print "<td>".$key."</td>\n";
|
||||
print "<td>".$type2label[$extrafields->attribute_type[$key]]."</td>\n";
|
||||
print '<td align="right">'.$extrafields->attribute_size[$key]."</td>\n";
|
||||
print '<td align="right">'.yn($extrafields->attribute_unique[$key])."</td>\n";
|
||||
print '<td align="center">'.yn($extrafields->attribute_unique[$key])."</td>\n";
|
||||
print '<td align="center">'.yn($extrafields->attribute_required[$key])."</td>\n";
|
||||
print '<td align="right"><a href="'.$_SERVER["PHP_SELF"].'?action=edit&attrname='.$key.'">'.img_edit().'</a>';
|
||||
print " <a href=\"".$_SERVER["PHP_SELF"]."?action=delete&attrname=$key\">".img_delete()."</a></td>\n";
|
||||
print "</tr>";
|
||||
|
||||
@ -957,7 +957,9 @@ else
|
||||
foreach($extrafields->attribute_label as $key=>$label)
|
||||
{
|
||||
$value=(isset($_POST["options_".$key])?$_POST["options_".$key]:(isset($object->array_options["options_".$key])?$object->array_options["options_".$key]:''));
|
||||
print '<tr><td>'.$label.'</td><td colspan="3">';
|
||||
print '<tr><td';
|
||||
if (! empty($extrafields->attribute_required[$key])) print ' class="fieldrequired"';
|
||||
print '>'.$label.'</td><td colspan="3">';
|
||||
print $extrafields->showInputField($key,$value);
|
||||
print '</td></tr>'."\n";
|
||||
}
|
||||
@ -1379,7 +1381,9 @@ else
|
||||
foreach($extrafields->attribute_label as $key=>$label)
|
||||
{
|
||||
$value=(isset($_POST["options_".$key])?$_POST["options_".$key]:$object->array_options["options_".$key]);
|
||||
print '<tr><td>'.$label.'</td><td colspan="3">';
|
||||
print '<tr><td';
|
||||
if (! empty($extrafields->attribute_required[$key])) print ' class="fieldrequired"';
|
||||
print '>'.$label.'</td><td colspan="3">';
|
||||
print $extrafields->showInputField($key,$value);
|
||||
print "</td></tr>\n";
|
||||
}
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<con:soapui-project name="Dolibarr" soapui-version="3.6.1" abortOnError="false" runType="SEQUENTIAL" resourceRoot="" xmlns:con="http://eviware.com/soapui/config"><con:settings/><con:interface xsi:type="con:WsdlInterface" wsaVersion="NONE" name="WebServicesDolibarrOtherBinding" type="wsdl" bindingName="{http://www.dolibarr.org/ns/}WebServicesDolibarrOtherBinding" soapVersion="1_1" anonymous="optional" definition="http://localhostdolibarr/dolibarrnew/webservices/server_other.php?wsdl" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><con:settings/><con:definitionCache type="TEXT" rootPart="http://localhostdolibarr/dolibarrnew/webservices/server_other.php?wsdl"><con:part><con:url>http://localhostdolibarr/dolibarrnew/webservices/server_other.php?wsdl</con:url><con:content><![CDATA[<definitions targetNamespace="http://www.dolibarr.org/ns/" xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/" xmlns:tns="http://www.dolibarr.org/ns/" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns="http://schemas.xmlsoap.org/wsdl/">
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<con:soapui-project name="Dolibarr" soapui-version="4.0.1" abortOnError="false" runType="SEQUENTIAL" resourceRoot="" xmlns:con="http://eviware.com/soapui/config"><con:settings/><con:interface xsi:type="con:WsdlInterface" wsaVersion="NONE" name="WebServicesDolibarrOtherBinding" type="wsdl" bindingName="{http://www.dolibarr.org/ns/}WebServicesDolibarrOtherBinding" soapVersion="1_1" anonymous="optional" definition="http://localhostdolibarr/dolibarrnew/webservices/server_other.php?wsdl" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><con:settings/><con:definitionCache type="TEXT" rootPart="http://localhostdolibarr/dolibarrnew/webservices/server_other.php?wsdl"><con:part><con:url>http://localhostdolibarr/dolibarrnew/webservices/server_other.php?wsdl</con:url><con:content><![CDATA[<definitions targetNamespace="http://www.dolibarr.org/ns/" xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/" xmlns:tns="http://www.dolibarr.org/ns/" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns="http://schemas.xmlsoap.org/wsdl/">
|
||||
<types>
|
||||
<xsd:schema targetNamespace="http://www.dolibarr.org/ns/">
|
||||
<xsd:import namespace="http://schemas.xmlsoap.org/soap/encoding/"/>
|
||||
@ -522,7 +522,7 @@
|
||||
<dolibarrkey xsi:type="xsd:string">dolibarrkey</dolibarrkey>
|
||||
<sourceapplication xsi:type="xsd:string">aaa</sourceapplication>
|
||||
<login xsi:type="xsd:string">admin</login>
|
||||
<password xsi:type="xsd:string">admin</password>
|
||||
<password xsi:type="xsd:string">changeme</password>
|
||||
<entity xsi:type="xsd:string"></entity>
|
||||
</authentication>
|
||||
<id xsi:type="xsd:string">1</id>
|
||||
@ -536,7 +536,7 @@
|
||||
<ns:getSupplierInvoicesForThirdParty soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/">
|
||||
<authentication xsi:type="ns:authentication">
|
||||
<!--You may enter the following 5 items in any order-->
|
||||
<dolibarrkey xsi:type="xsd:string">dolibarrkey</dolibarrkey>
|
||||
<dolibarrkey xsi:type="xsd:string">?</dolibarrkey>
|
||||
<sourceapplication xsi:type="xsd:string">?</sourceapplication>
|
||||
<login xsi:type="xsd:string">admin</login>
|
||||
<password xsi:type="xsd:string">admin</password>
|
||||
@ -692,7 +692,7 @@
|
||||
<soap:address location="http://localhostdolibarr/dolibarrnew/webservices/server_productorservice.php"/>
|
||||
</port>
|
||||
</service>
|
||||
</definitions>]]></con:content><con:type>http://schemas.xmlsoap.org/wsdl/</con:type></con:part></con:definitionCache><con:endpoints><con:endpoint>http://localhostdolibarr/dolibarrnew/webservices/server_productorservice.php</con:endpoint></con:endpoints><con:operation isOneWay="false" action="http://www.dolibarr.org/ns/#createProductOrService" name="createProductOrService" bindingOperationName="createProductOrService" type="Request-Response" inputName="" receivesAttachments="false" sendsAttachments="false" anonymous="optional"><con:settings/><con:call name="Request 1"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:encoding>UTF-8</con:encoding><con:endpoint>http://localhostdolibarr/dolibarrnew/webservices/server_productorservice.php</con:endpoint><con:request><![CDATA[<soapenv:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns="http://www.dolibarr.org/ns/">
|
||||
</definitions>]]></con:content><con:type>http://schemas.xmlsoap.org/wsdl/</con:type></con:part></con:definitionCache><con:endpoints><con:endpoint>http://localhost/dolibarr/htdocs/webservices/server_productorservice.php</con:endpoint></con:endpoints><con:operation isOneWay="false" action="http://www.dolibarr.org/ns/#createProductOrService" name="createProductOrService" bindingOperationName="createProductOrService" type="Request-Response" inputName="" receivesAttachments="false" sendsAttachments="false" anonymous="optional"><con:settings/><con:call name="Request 1"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:encoding>UTF-8</con:encoding><con:endpoint>http://localhost/dolibarr/htdocs/webservices/server_productorservice.php</con:endpoint><con:request><![CDATA[<soapenv:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns="http://www.dolibarr.org/ns/">
|
||||
<soapenv:Header/>
|
||||
<soapenv:Body>
|
||||
<ns:createProductOrService soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/">
|
||||
@ -733,14 +733,14 @@
|
||||
</product>
|
||||
</ns:createProductOrService>
|
||||
</soapenv:Body>
|
||||
</soapenv:Envelope>]]></con:request><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:wsaConfig mustUnderstand="NONE" version="200508" action="http://www.dolibarr.org/ns/#createProductOrService"/><con:wsrmConfig version="1.2"/></con:call></con:operation><con:operation isOneWay="false" action="http://www.dolibarr.org/ns/#getProductOrService" name="getProductOrService" bindingOperationName="getProductOrService" type="Request-Response" inputName="" receivesAttachments="false" sendsAttachments="false" anonymous="optional"><con:settings/><con:call name="Request 1"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:encoding>UTF-8</con:encoding><con:endpoint>http://localhostdolibarr/dolibarrnew/webservices/server_productorservice.php</con:endpoint><con:request><![CDATA[<soapenv:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns="http://www.dolibarr.org/ns/">
|
||||
</soapenv:Envelope>]]></con:request><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:wsaConfig mustUnderstand="NONE" version="200508" action="http://www.dolibarr.org/ns/#createProductOrService"/><con:wsrmConfig version="1.2"/></con:call></con:operation><con:operation isOneWay="false" action="http://www.dolibarr.org/ns/#getProductOrService" name="getProductOrService" bindingOperationName="getProductOrService" type="Request-Response" inputName="" receivesAttachments="false" sendsAttachments="false" anonymous="optional"><con:settings/><con:call name="Request 1"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:encoding>UTF-8</con:encoding><con:endpoint>http://localhost/dolibarr/htdocs/webservices/server_productorservice.php</con:endpoint><con:request><![CDATA[<soapenv:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns="http://www.dolibarr.org/ns/">
|
||||
<soapenv:Header/>
|
||||
<soapenv:Body>
|
||||
<ns:getProductOrService soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/">
|
||||
<authentication xsi:type="ns:authentication">
|
||||
<!--You may enter the following 5 items in any order-->
|
||||
<dolibarrkey xsi:type="xsd:string">dolibarrkey</dolibarrkey>
|
||||
<sourceapplication xsi:type="xsd:string"></sourceapplication>
|
||||
<sourceapplication xsi:type="xsd:string">?</sourceapplication>
|
||||
<login xsi:type="xsd:string">admin</login>
|
||||
<password xsi:type="xsd:string">admin</password>
|
||||
<entity xsi:type="xsd:string"></entity>
|
||||
@ -750,27 +750,27 @@
|
||||
<ref_ext xsi:type="xsd:string"></ref_ext>
|
||||
</ns:getProductOrService>
|
||||
</soapenv:Body>
|
||||
</soapenv:Envelope>]]></con:request><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:wsaConfig mustUnderstand="NONE" version="200508" action="http://www.dolibarr.org/ns/#getProductOrService"/><con:wsrmConfig version="1.2"/></con:call></con:operation><con:operation isOneWay="false" action="http://www.dolibarr.org/ns/#getListOfProductsOrServices" name="getListOfProductsOrServices" bindingOperationName="getListOfProductsOrServices" type="Request-Response" inputName="" receivesAttachments="false" sendsAttachments="false" anonymous="optional"><con:settings/><con:call name="Request 1"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:encoding>UTF-8</con:encoding><con:endpoint>http://localhostdolibarr/dolibarrnew/webservices/server_productorservice.php</con:endpoint><con:request><![CDATA[<soapenv:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns="http://www.dolibarr.org/ns/">
|
||||
</soapenv:Envelope>]]></con:request><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:wsaConfig mustUnderstand="NONE" version="200508" action="http://www.dolibarr.org/ns/#getProductOrService"/><con:wsrmConfig version="1.2"/></con:call></con:operation><con:operation isOneWay="false" action="http://www.dolibarr.org/ns/#getListOfProductsOrServices" name="getListOfProductsOrServices" bindingOperationName="getListOfProductsOrServices" type="Request-Response" inputName="" receivesAttachments="false" sendsAttachments="false" anonymous="optional"><con:settings/><con:call name="Request 1"><con:settings/><con:encoding>UTF-8</con:encoding><con:endpoint>http://localhost/dolibarr/htdocs/webservices/server_productorservice.php</con:endpoint><con:request><![CDATA[<soapenv:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns="http://www.dolibarr.org/ns/">
|
||||
<soapenv:Header/>
|
||||
<soapenv:Body>
|
||||
<ns:getListOfProductsOrServices soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/">
|
||||
<authentication xsi:type="ns:authentication">
|
||||
<!--You may enter the following 5 items in any order-->
|
||||
<dolibarrkey xsi:type="xsd:string">dolibarrkey</dolibarrkey>
|
||||
<dolibarrkey xsi:type="xsd:string">?</dolibarrkey>
|
||||
<sourceapplication xsi:type="xsd:string">?</sourceapplication>
|
||||
<login xsi:type="xsd:string">admin</login>
|
||||
<password xsi:type="xsd:string">admin</password>
|
||||
<entity xsi:type="xsd:string"></entity>
|
||||
<login xsi:type="xsd:string">?</login>
|
||||
<password xsi:type="xsd:string">?</password>
|
||||
<entity xsi:type="xsd:string">?</entity>
|
||||
</authentication>
|
||||
<filterproduct xsi:type="ns:filterproduct">
|
||||
<!--You may enter the following 3 items in any order-->
|
||||
<type xsi:type="xsd:string">0</type>
|
||||
<status_tobuy xsi:type="xsd:string"></status_tobuy>
|
||||
<status_tosell xsi:type="xsd:string"></status_tosell>
|
||||
<type xsi:type="xsd:string">?</type>
|
||||
<status_tobuy xsi:type="xsd:string">?</status_tobuy>
|
||||
<status_tosell xsi:type="xsd:string">?</status_tosell>
|
||||
</filterproduct>
|
||||
</ns:getListOfProductsOrServices>
|
||||
</soapenv:Body>
|
||||
</soapenv:Envelope>]]></con:request><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:wsaConfig mustUnderstand="NONE" version="200508" action="http://www.dolibarr.org/ns/#getListOfProductsOrServices"/><con:wsrmConfig version="1.2"/></con:call></con:operation></con:interface><con:interface xsi:type="con:WsdlInterface" wsaVersion="NONE" name="WebServicesDolibarrUserBinding" type="wsdl" bindingName="{http://www.dolibarr.org/ns/}WebServicesDolibarrUserBinding" soapVersion="1_1" anonymous="optional" definition="http://localhostdolibarr/webservices/server_user.php?wsdl" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><con:settings/><con:definitionCache type="TEXT" rootPart="http://localhostdolibarr/webservices/server_user.php?wsdl"><con:part><con:url>http://localhostdolibarr/webservices/server_user.php?wsdl</con:url><con:content><![CDATA[<definitions targetNamespace="http://www.dolibarr.org/ns/" xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/" xmlns:tns="http://www.dolibarr.org/ns/" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns="http://schemas.xmlsoap.org/wsdl/">
|
||||
</soapenv:Envelope>]]></con:request><con:wsaConfig mustUnderstand="NONE" version="200508" action="http://www.dolibarr.org/ns/#getListOfProductsOrServices"/></con:call></con:operation></con:interface><con:interface xsi:type="con:WsdlInterface" wsaVersion="NONE" name="WebServicesDolibarrUserBinding" type="wsdl" bindingName="{http://www.dolibarr.org/ns/}WebServicesDolibarrUserBinding" soapVersion="1_1" anonymous="optional" definition="http://localhostdolibarr/webservices/server_user.php?wsdl" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><con:settings/><con:definitionCache type="TEXT" rootPart="http://localhostdolibarr/webservices/server_user.php?wsdl"><con:part><con:url>http://localhostdolibarr/webservices/server_user.php?wsdl</con:url><con:content><![CDATA[<definitions targetNamespace="http://www.dolibarr.org/ns/" xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/" xmlns:tns="http://www.dolibarr.org/ns/" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns="http://schemas.xmlsoap.org/wsdl/">
|
||||
<types>
|
||||
<xsd:schema targetNamespace="http://www.dolibarr.org/ns/">
|
||||
<xsd:import namespace="http://schemas.xmlsoap.org/soap/encoding/"/>
|
||||
@ -1028,21 +1028,24 @@
|
||||
<soap:address location="http://localhostdolibarr/webservices/server_thirdparty.php"/>
|
||||
</port>
|
||||
</service>
|
||||
</definitions>]]></con:content><con:type>http://schemas.xmlsoap.org/wsdl/</con:type></con:part></con:definitionCache><con:endpoints><con:endpoint>http://localhostdolibarr/webservices/server_thirdparty.php</con:endpoint></con:endpoints><con:operation isOneWay="false" action="http://www.dolibarr.org/ns/#getThirdParty" name="getThirdParty" bindingOperationName="getThirdParty" type="Request-Response" inputName="" receivesAttachments="false" sendsAttachments="false" anonymous="optional"><con:settings/><con:call name="Request 1"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:encoding>UTF-8</con:encoding><con:endpoint>http://localhostdolibarr/webservices/server_thirdparty.php</con:endpoint><con:request><![CDATA[<SOAP-ENV:Envelope SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/">
|
||||
<SOAP-ENV:Body>
|
||||
<ns9290:getVersions xmlns:ns9290="http://www.Dolibarr.org/ns/">
|
||||
<authentication>
|
||||
</definitions>]]></con:content><con:type>http://schemas.xmlsoap.org/wsdl/</con:type></con:part></con:definitionCache><con:endpoints><con:endpoint>http://localhostdolibarr/webservices/server_thirdparty.php</con:endpoint></con:endpoints><con:operation isOneWay="false" action="http://www.dolibarr.org/ns/#getThirdParty" name="getThirdParty" bindingOperationName="getThirdParty" type="Request-Response" inputName="" receivesAttachments="false" sendsAttachments="false" anonymous="optional"><con:settings/><con:call name="Request 1"><con:settings><con:setting id="com.eviware.soapui.impl.wsdl.WsdlRequest@request-headers"><xml-fragment/></con:setting></con:settings><con:encoding>UTF-8</con:encoding><con:endpoint>http://localhostdolibarr/webservices/server_thirdparty.php</con:endpoint><con:request><![CDATA[<soapenv:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns="http://www.dolibarr.org/ns/">
|
||||
<soapenv:Header/>
|
||||
<soapenv:Body>
|
||||
<ns:getThirdParty soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/">
|
||||
<authentication xsi:type="ns:authentication">
|
||||
<!--You may enter the following 5 items in any order-->
|
||||
<dolibarrkey xsi:type="xsd:string">dolibarrkey</dolibarrkey>
|
||||
<sourceapplication xsi:type="xsd:string">PRESTASHOP</sourceapplication>
|
||||
<sourceapplication xsi:type="xsd:string">aaa</sourceapplication>
|
||||
<login xsi:type="xsd:string">admin</login>
|
||||
<password xsi:type="xsd:string">admin</password>
|
||||
<entity xsi:type="xsd:string"/>
|
||||
<entity xsi:type="xsd:string"></entity>
|
||||
</authentication>
|
||||
</ns9290:getVersions>
|
||||
</SOAP-ENV:Body>
|
||||
</SOAP-ENV:Envelope>
|
||||
|
||||
]]></con:request><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:wsaConfig mustUnderstand="NONE" version="200508" action="http://www.dolibarr.org/ns/#getVersions"/><con:wsrmConfig version="1.2"/></con:call></con:operation><con:operation isOneWay="false" action="http://www.dolibarr.org/ns/#createThirdParty" name="createThirdParty" bindingOperationName="createThirdParty" type="Request-Response" inputName="" receivesAttachments="false" sendsAttachments="false" anonymous="optional"><con:settings/><con:call name="Request 1"><con:settings/><con:encoding>UTF-8</con:encoding><con:endpoint>http://localhostdolibarr/webservices/server_thirdparty.php</con:endpoint><con:request><![CDATA[<soapenv:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns="http://www.dolibarr.org/ns/">
|
||||
<id xsi:type="xsd:string">1</id>
|
||||
<ref xsi:type="xsd:string"></ref>
|
||||
<ref_ext xsi:type="xsd:string"></ref_ext>
|
||||
</ns:getThirdParty>
|
||||
</soapenv:Body>
|
||||
</soapenv:Envelope>]]></con:request><con:jmsConfig JMSDeliveryMode="PERSISTENT"/><con:jmsPropertyConfig/><con:wsaConfig mustUnderstand="NONE" version="200508" action="http://www.dolibarr.org/ns/#getVersions"/><con:wsrmConfig version="1.2"/></con:call></con:operation><con:operation isOneWay="false" action="http://www.dolibarr.org/ns/#createThirdParty" name="createThirdParty" bindingOperationName="createThirdParty" type="Request-Response" inputName="" receivesAttachments="false" sendsAttachments="false" anonymous="optional"><con:settings/><con:call name="Request 1"><con:settings/><con:encoding>UTF-8</con:encoding><con:endpoint>http://localhostdolibarr/webservices/server_thirdparty.php</con:endpoint><con:request><![CDATA[<soapenv:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns="http://www.dolibarr.org/ns/">
|
||||
<soapenv:Header/>
|
||||
<soapenv:Body>
|
||||
<ns:createThirdParty soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/">
|
||||
|
||||
Loading…
Reference in New Issue
Block a user