rendre plus générique le fonction
This commit is contained in:
parent
e84e4e60ce
commit
1c0df71803
@ -8,10 +8,10 @@
|
|||||||
// \version $Revision$
|
// \version $Revision$
|
||||||
|
|
||||||
|
|
||||||
function dolibarr_type_reload(param)
|
function dolibarr_type_reload(param,formAction,elementName)
|
||||||
{
|
{
|
||||||
document.formsoc.action.value="create";
|
document.formsoc.action.value=formAction;
|
||||||
document.formsoc.private.value=param;
|
document.formsoc.elementName.value=param;
|
||||||
document.formsoc.cleartype.value=1;
|
document.formsoc.cleartype.value=1;
|
||||||
document.formsoc.submit();
|
document.formsoc.submit();
|
||||||
}
|
}
|
||||||
|
|||||||
@ -297,11 +297,11 @@ if ($_POST["getcustomercode"] || $_POST["getsuppliercode"] ||
|
|||||||
print "<br>\n";
|
print "<br>\n";
|
||||||
print $langs->trans("ThirdPartyType").': ';
|
print $langs->trans("ThirdPartyType").': ';
|
||||||
print '<input type="radio" class="flat" name="private" value="0"'.(! $_REQUEST["private"]?' checked="true"':'');
|
print '<input type="radio" class="flat" name="private" value="0"'.(! $_REQUEST["private"]?' checked="true"':'');
|
||||||
print 'onclick="dolibarr_type_reload(0)"';
|
print 'onclick="dolibarr_type_reload(0,\'create\',\'private\')"';
|
||||||
print '> '.$langs->trans("Company/Fundation");
|
print '> '.$langs->trans("Company/Fundation");
|
||||||
print ' ';
|
print ' ';
|
||||||
print '<input type="radio" class="flat" name="private" value="1"'.(! $_REQUEST["private"]?'':' checked="true"');
|
print '<input type="radio" class="flat" name="private" value="1"'.(! $_REQUEST["private"]?'':' checked="true"');
|
||||||
print 'onclick="dolibarr_type_reload(1)"';
|
print 'onclick="dolibarr_type_reload(1,\'create\',\'private\')"';
|
||||||
print '> '.$langs->trans("Individual");
|
print '> '.$langs->trans("Individual");
|
||||||
print ' ('.$langs->trans("ToCreateContactWithSameName").')';
|
print ' ('.$langs->trans("ToCreateContactWithSameName").')';
|
||||||
print "<br>\n";
|
print "<br>\n";
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user