Openbravo Issue Tracking System - Localization Pack: Spain
View Issue Details
0026091Localization Pack: SpainInvoice Register Bookpublic2014-03-26 13:552014-08-28 18:15
psanjuan 
Sandrahuguet 
urgentmajoralways
closedfixed 
20Ubuntu 8.04.1
 
 
0026091: The invoice register book must set the key "Z" for every single line of a purchase/sales invoice under CASH VAT regime.
The invoice register book must set the key "Z" for every single line of a purchase/sales invoice under CASH VAT regime, regardless if that invoice includes a line with an exempt tax rate or a line of an "Arrendamientos" tax rate which normally are set with the key "R".

Otherwise payment information will not be taken after launching the 340 tax form.
Create a sales invoice with below listed tax rates:
Servicios prestados nacional 21% IVA de Caja
Arrendamientos 21% -21%R (cobros) IVA de Caja
Servicios prestados exentos

Complete and Post the invoice.

Launch the book for the period when the invoice is posted, let's say February. See image attached.

Realize that the key R is shown linked to the invoice line related to the tax Arrendamientos 21% -21%R (cobros) IVA de Caja, and that should not be the case.
The correct key to show is "Z".

Same applies to purchase invoice and therefore the Received Invoice Book.

Create a purchase invoice with below listed tax rates:
Arrendamientos 21%-21%R (pagos) IVA de Caja
PrestaciĆ³n servicios nacional 21% IVA de Caja
Producto Exento
Servicio Exento


Complete and Post the invoice.

Launch the book for the period when the invoice is posted, let's say March. See image attached.

Realize that the key R is shown linked to the invoice line related to the tax Arrendamientos 21% -21%R (pagos) IVA de Caja, and that should not be the case.
The correct key to show is "Z".



The invoice register book must set the key "Z" for every single line of a purchase/sales invoice under CASH VAT regime.
No tags attached.
related to defect 0027500 new jonalegriaesarte Modules Error on Oracle installation ORA-00911: invalid character 
png 26091_sales.png (121,719) 2014-03-26 14:46
https://issues.openbravo.com/file_download.php?file_id=6780&type=bug
png

png 26091_purchase.png (142,408) 2014-03-26 14:46
https://issues.openbravo.com/file_download.php?file_id=6781&type=bug
png
Issue History
2014-03-26 13:55psanjuanNew Issue
2014-03-26 13:55psanjuanAssigned To => jonalegriaesarte
2014-03-26 14:35psanjuanSteps to Reproduce Updatedbug_revision_view_page.php?rev_id=5623#r5623
2014-03-26 14:36psanjuanSteps to Reproduce Updatedbug_revision_view_page.php?rev_id=5624#r5624
2014-03-26 14:46psanjuanFile Added: 26091_sales.png
2014-03-26 14:46psanjuanFile Added: 26091_purchase.png
2014-04-04 13:47psanjuanDescription Updatedbug_revision_view_page.php?rev_id=5664#r5664
2014-04-14 17:40SandrahuguetStatusnew => scheduled
2014-04-14 17:40SandrahuguetAssigned Tojonalegriaesarte => Sandrahuguet
2014-04-14 17:40Sandrahuguetfix_in_branch => pi
2014-04-16 09:40hgbotCheckin
2014-04-16 09:40hgbotNote Added: 0066479
2014-04-16 09:40hgbotStatusscheduled => resolved
2014-04-16 09:40hgbotResolutionopen => fixed
2014-04-16 09:40hgbotFixed in SCM revision => http://code.openbravo.com/erp/pmods/org.openbravo.module.invoicesregisterbook/rev/e6ba707148483759ff41ad2be11ac9289c7c784a [^]
2014-04-16 15:03psanjuanNote Added: 0066499
2014-04-16 15:03psanjuanStatusresolved => closed
2014-04-16 15:03psanjuanfix_in_branchpi =>
2014-08-27 16:51rafarodaNote Added: 0069810
2014-08-28 18:12rafarodaRelationship addedrelated to 0027500
2014-08-28 18:15rafarodaNote Added: 0069840
2014-08-28 18:19rafarodaRelationship addeddepends on 0027502
2014-08-28 18:19rafarodaRelationship deleteddepends on 0027502

Notes
(0066479)
hgbot   
2014-04-16 09:40   
Repository: erp/pmods/org.openbravo.module.invoicesregisterbook
Changeset: e6ba707148483759ff41ad2be11ac9289c7c784a
Author: Sandra Huguet <sandra.huguet <at> openbravo.com>
Date: Wed Apr 16 09:18:41 2014 +0200
URL: http://code.openbravo.com/erp/pmods/org.openbravo.module.invoicesregisterbook/rev/e6ba707148483759ff41ad2be11ac9289c7c784a [^]

Fixed bug 26091 Invoice register book must set "Z" for every invoice line under CASH VAT

---
M src-db/database/model/functions/OBIRB_GENERATE_CODE.xml
A build/classes/org/openbravo/module/invoicesregisterbook/modulescript/Issue26091UpdateOperationCode.class
A build/classes/org/openbravo/module/invoicesregisterbook/modulescript/Issue26091UpdateOperationCodeData.class
A src-util/modulescript/src/org/openbravo/module/invoicesregisterbook/modulescript/Issue26091UpdateOperationCode.java
A src-util/modulescript/src/org/openbravo/module/invoicesregisterbook/modulescript/Issue26091UpdateOperationCode_data.xsql
---
(0066499)
psanjuan   
2014-04-16 15:03   
fixed and working
(0069810)
rafaroda   
2014-08-27 16:51   
I had the following error when this modulescript was executed in Oracle 10: [java] 173967 ERROR - SQL error in query: UPDATE C_Invoice SET PROCESSED='N' WHERE C_Invoice_ID in (select ci.c_invoice_id from c_invoice ci left join C_InvoiceTax ct on ci.c_invoice_id=ct.c_invoice_id where ci.iscashvat='Y'); UPDATE C_InvoiceTax SET EM_OBIRB_OperationCode='Z' WHERE C_INVOICE_ID in (select ci.c_invoice_id from c_invoice ci left join C_InvoiceTax ct on ci.c_invoice_id=ct.c_invoice_id where ci.iscashvat='Y'); UPDATE C_Invoice SET PROCESSED='Y' WHERE C_Invoice_ID in (select ci.c_invoice_id from c_invoice ci left join C_InvoiceTax ct on ci.c_invoice_id=ct.c_invoice_id where ci.iscashvat='Y');Exception:java.sql.SQLSyntaxErrorException: ORA-00911: invalid character
(0069840)
rafaroda   
2014-08-28 18:15   
Reported the error of the previous comment in a new related issue 0027500 Error on Oracle installation ORA-00911: invalid character https://issues.openbravo.com/view.php?id=27500 [^]