Merge pull request #879 from neemzy/development
[-] FO : OPC hide VAT fields fail if there are no company fields
This commit is contained in:
commit
1cc0134ec3
1 file changed
+2
-2
@@ -74,14 +74,14 @@
|
|||||||
{literal}
|
{literal}
|
||||||
function vat_number()
|
function vat_number()
|
||||||
{
|
{
|
||||||
if ($('#company').val() != '')
|
if (($('#company').length) && ($('#company').val() != ''))
|
||||||
$('#vat_number_block').show();
|
$('#vat_number_block').show();
|
||||||
else
|
else
|
||||||
$('#vat_number_block').hide();
|
$('#vat_number_block').hide();
|
||||||
}
|
}
|
||||||
function vat_number_invoice()
|
function vat_number_invoice()
|
||||||
{
|
{
|
||||||
if ($('#company_invoice').val() != '')
|
if (($('#company_invoice').length) && ($('#company_invoice').val() != ''))
|
||||||
$('#vat_number_block_invoice').show();
|
$('#vat_number_block_invoice').show();
|
||||||
else
|
else
|
||||||
$('#vat_number_block_invoice').hide();
|
$('#vat_number_block_invoice').hide();
|
||||||
|
|||||||
Reference in new issue
Block a user