Merge pull request #20033 from hregis/fix_broken_feature_wrong_div_name

FIX broken feature, wrong div name
This commit is contained in:
Laurent Destailleur 2022-02-10 09:58:26 +01:00 committed by GitHub
commit 9ec7b204c1
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -326,7 +326,7 @@ if ($action == 'create') {
if ($conf->use_javascript_ajax) {
print "\n".'<script type="text/javascript" language="javascript">';
print 'jQuery(document).ready(function () {
jQuery("#selecttype").change(function() {
jQuery("#type").change(function() {
document.formsoc.action.value="create";
document.formsoc.submit();
});
@ -349,7 +349,7 @@ if ($action == 'create') {
// Ref
print '<tr><td class="fieldrequired titlefieldcreate">'.$langs->trans("Ref").'</td>';
print '<td><input size="8" type="text" class="flat" name="ref" value="'.dol_escape_htmltag(GETPOST("ref") ?GETPOST("ref", 'alpha') : $object->ref).'" maxlength="12" autofocus></td></tr>';
print '<td><input size="8" type="text" class="flat" name="ref" value="'.dol_escape_htmltag(GETPOSTISSET("ref") ? GETPOST("ref", 'alpha') : $object->ref).'" maxlength="12" autofocus></td></tr>';
// Label
print '<tr><td class="fieldrequired">'.$langs->trans("LabelBankCashAccount").'</td>';
@ -358,7 +358,7 @@ if ($action == 'create') {
// Type
print '<tr><td class="fieldrequired">'.$langs->trans("AccountType").'</td>';
print '<td>';
$formbank->selectTypeOfBankAccount(GETPOSTISSET("type") ? GETPOST("type") : Account::TYPE_CURRENT, "type");
$formbank->selectTypeOfBankAccount(GETPOSTISSET("type") ? GETPOST("type", 'alpha') : Account::TYPE_CURRENT, "type");
print '</td></tr>';
// Currency