Patch level : 12.0 1072
Files correlati : batbtpe.msk f154.dir f154.trr li0400a.msk li0.exe Commento : Aggiunta la possibilità di definire diversi tipi di esenzione da esportare nelle fatture elettroniche con le modificehe consguenti sull fatturazione e la fatturazione elettronica Interno : aggiunta una nuov tabella da indicare nella letera di intento con tipo dato, descrizione per l'invio fatture e flag di stampa sulle fatture della dicitura di esenzione.
This commit is contained in:
parent
ddc1a6c605
commit
897ca44202
7
src/li/batbtpe.h
Normal file
7
src/li/batbtpe.h
Normal file
@ -0,0 +1,7 @@
|
||||
|
||||
#define F_CODTAB 101
|
||||
#define F_S0 102
|
||||
#define F_FLD 103
|
||||
#define F_PROMPT 104
|
||||
#define F_NO_PRINT 105
|
||||
|
58
src/li/batbtpe.uml
Normal file
58
src/li/batbtpe.uml
Normal file
@ -0,0 +1,58 @@
|
||||
#include "batbtpe.h"
|
||||
|
||||
TOOLBAR "topbar" 0 0 0 2
|
||||
#include <relapbar.h>
|
||||
ENDPAGE
|
||||
|
||||
PAGE "Tipologie di esenzione" -1 -1 78 19
|
||||
|
||||
STRING F_CODTAB 6
|
||||
BEGIN
|
||||
PROMPT 1 1 "Codice "
|
||||
KEY 1
|
||||
USE %TPE
|
||||
FLAGS "UZ"
|
||||
INPUT CODTAB F_CODTAB
|
||||
DISPLAY "Codice" CODTAB
|
||||
DISPLAY "Descrizione@50" S0
|
||||
OUTPUT F_CODTAB CODTAB
|
||||
OUTPUT F_S0 S0
|
||||
CHECKTYPE REQUIRED
|
||||
FIELD CODTAB
|
||||
END
|
||||
|
||||
STRING F_S0 50
|
||||
BEGIN
|
||||
PROMPT 1 3 "Descrizione "
|
||||
FIELD S0
|
||||
KEY 2
|
||||
USE %TPE KEY 2
|
||||
INPUT S0 102
|
||||
DISPLAY "Descrizione@50" S0
|
||||
DISPLAY "Codice" CODTAB
|
||||
COPY OUTPUT F_CODTAB
|
||||
CHECKTYPE REQUIRED
|
||||
END
|
||||
|
||||
STRING F_FLD 15
|
||||
BEGIN
|
||||
PROMPT 1 5 "Tipo dato Invio fatture "
|
||||
FIELD S4
|
||||
END
|
||||
|
||||
STRING F_PROMPT 70
|
||||
BEGIN
|
||||
PROMPT 1 7 "Descriz. invio fatture "
|
||||
FIELD S1
|
||||
END
|
||||
|
||||
BOOLEAN F_NO_PRINT
|
||||
BEGIN
|
||||
PROMPT 1 9 "Non stampare sulle fatture"
|
||||
FIELD B0
|
||||
END
|
||||
|
||||
ENDPAGE
|
||||
|
||||
ENDMASK
|
||||
|
@ -1,3 +1,3 @@
|
||||
154
|
||||
0
|
||||
$letint|0|0|132|0|Lettere d'intento|||
|
||||
$letint|0|0|135|0|Lettere d'intento|||
|
||||
|
@ -1,5 +1,5 @@
|
||||
154
|
||||
18
|
||||
19
|
||||
ANNO|2|4|0|Anno
|
||||
NUMPROT|3|6|0|Numero protocollo
|
||||
DATAREG|5|8|0|Data di registrazione
|
||||
@ -18,6 +18,7 @@ INVIATO|8|1|0|Inviato
|
||||
PROTINTF|1|17|0|Numero di protocollo passato dall agenzia delle entrate (prima parte)
|
||||
PROTINTS|1|6|0|Numero di protocollo passato dall agenzia delle entrate (seconda parte)
|
||||
CHIUSA|8|1|0|Indica se una lettera di intento è chiusa
|
||||
CODTPE|1|3|0|Tipo di esenzione
|
||||
2
|
||||
ANNO+NUMPROT|
|
||||
CODCLI+ANNO+NUMPROT|X
|
||||
|
@ -19,5 +19,6 @@
|
||||
#define LETINT_PROTINTF "PROTINTF"
|
||||
#define LETINT_PROTINTS "PROTINTS"
|
||||
#define LETINT_CHIUSA "CHIUSA"
|
||||
#define LETINT_CODTPE "CODTPE"
|
||||
|
||||
#endif
|
||||
|
@ -103,7 +103,7 @@ bool TLetint_mask::on_field_event(TOperable_field& o, TField_event e, long jolly
|
||||
break;
|
||||
case F_TIPOOP:
|
||||
// Controlli
|
||||
if(!keyforced && insert_mode() && get_int(F_TIPOOP) == 3 && get_date(F_DAL) > TDate(01,03,2017))
|
||||
/* if(!keyforced && insert_mode() && get_int(F_TIPOOP) == 3 && get_date(F_DAL) > TDate(01,03,2017))
|
||||
{
|
||||
error_box(TR("Non può esistere una dichiarazione di intento di tipo \"A Periodo\"\ncon data posteriore al 01/03/2017!"));
|
||||
disable(DLG_SAVEREC);
|
||||
@ -111,7 +111,7 @@ bool TLetint_mask::on_field_event(TOperable_field& o, TField_event e, long jolly
|
||||
else
|
||||
{
|
||||
enable(DLG_SAVEREC);
|
||||
}
|
||||
} */
|
||||
// Abilitazione date
|
||||
switch (get_int(F_TIPOOP))
|
||||
{
|
||||
|
@ -31,4 +31,6 @@
|
||||
#define F_NOTE 125
|
||||
#define B_CHIUSA 126
|
||||
#define F_UTILIZZATO 127
|
||||
#define F_DISPONIBILE 128
|
||||
#define F_DISPONIBILE 128
|
||||
#define F_TIPOES 129
|
||||
#define F_DESCTPE 130
|
@ -213,6 +213,31 @@ BEGIN
|
||||
//CHECKTYPE REQUIRED
|
||||
END
|
||||
|
||||
STRING F_TIPOES 6
|
||||
BEGIN
|
||||
PROMPT 1 13 "Codice "
|
||||
USE %TPE
|
||||
FLAGS "UZ"
|
||||
INPUT CODTAB F_TIPOES
|
||||
DISPLAY "Codice" CODTAB
|
||||
DISPLAY "Descrizione@50" S0
|
||||
OUTPUT F_TIPOES CODTAB
|
||||
OUTPUT F_DESCTPE S0
|
||||
CHECKTYPE NORMAL
|
||||
FIELD CODTPE
|
||||
END
|
||||
|
||||
STRING F_DESCTPE 50
|
||||
BEGIN
|
||||
PROMPT 20 13 ""
|
||||
USE %TPE KEY 2
|
||||
INPUT S0 F_DESCTPE
|
||||
DISPLAY "Descrizione@50" S0
|
||||
DISPLAY "Codice" CODTAB
|
||||
COPY OUTPUT F_TIPOES
|
||||
CHECKTYPE SEARCH
|
||||
END
|
||||
|
||||
GROUPBOX DLG_NULL 75 6
|
||||
BEGIN
|
||||
PROMPT 0 15 "@bOperazione"
|
||||
|
@ -410,6 +410,54 @@ bool TLi_manager::utilizza_plafond(const TDocumento & d, TToken_string & plafs,
|
||||
return ok;
|
||||
}
|
||||
|
||||
int TLi_manager::get_plafond_row(const TDocumento & d, TString & protinf, TString & protins, TDate & dataprot, real & utilizzo, TString & field, TString & descr, bool & to_print, int num) const
|
||||
{
|
||||
TToken_string plafs(d.get(DOC_PLAFOND), ',');
|
||||
const int plafsitems = plafs.items();
|
||||
|
||||
protinf.cut(0);
|
||||
protins.cut(0);
|
||||
dataprot = botime;
|
||||
field.cut(0);
|
||||
descr.cut(0);
|
||||
to_print = false;
|
||||
if (num >= 0 && num < plafsitems)
|
||||
{
|
||||
TToken_string plaf = plafs.get(num);
|
||||
TToken_string key = plaf.get(_planno);
|
||||
|
||||
utilizzo = plaf.get_real(_plimporto);
|
||||
key.add(plaf.get(_plnumprot));
|
||||
|
||||
const TRectype & reclint = cache().get(LF_LETINT, key);
|
||||
|
||||
if (reclint.full())
|
||||
{
|
||||
const TString & type = reclint.get(LETINT_CODTPE);
|
||||
const TRectype & rectype = cache().get("%TPE", type);
|
||||
|
||||
protinf = reclint.get(LETINT_PROTINTF);
|
||||
protins = reclint.get(LETINT_PROTINTS);
|
||||
dataprot = reclint.get_date(LETINT_VSDATA);
|
||||
if (type.full() && rectype.full())
|
||||
{
|
||||
field = rectype.get("S4");
|
||||
descr = rectype.get("S1");
|
||||
to_print = !rectype.get("B0");
|
||||
}
|
||||
else
|
||||
{
|
||||
field = "Dich.Inten";
|
||||
descr = "N.di protocollo di invio";
|
||||
to_print = true;
|
||||
}
|
||||
}
|
||||
return ++num;
|
||||
}
|
||||
else
|
||||
return -1;
|
||||
}
|
||||
|
||||
void TLi_manager::clear_letint()
|
||||
{
|
||||
const int rows = _plafonds.items();
|
||||
|
@ -90,6 +90,8 @@ public:
|
||||
const TArray & get_plafond_array() const { return _plafonds; }
|
||||
// Utilizza il plafond
|
||||
bool utilizza_plafond(const TDocumento & d, TToken_string & plafs, const real importo);
|
||||
// Ritorna il tipo di plafond dell'iesimo plafond del documento
|
||||
int get_plafond_row(const TDocumento & d, TString & protinf, TString & protins, TDate & dataprot, real & utilizzo, TString & field, TString & descr, bool & toprint, int num = 0) const;
|
||||
|
||||
// Functions
|
||||
// Aggiunge a una lettera d'intento
|
||||
@ -99,7 +101,7 @@ public:
|
||||
|
||||
// Funzione che aggiorna il residuo plafond dichiarazione dalla data alla data
|
||||
void TLi_manager::rebuild_plafond(bool update_docs = true, const int anno = 0);
|
||||
// Funzione che effettivamente effettua il calcolodalla data della dichiarazione alla data passata
|
||||
// Funzione che effettivamente effettua il calcolo dalla data della dichiarazione alla data passata
|
||||
const real elab_util(TDate ad = 0L);
|
||||
bool plafond_write(TDocumento& d);
|
||||
bool plafond_rewrite(TDocumento& d);
|
||||
|
@ -4,9 +4,9 @@ Picture = <cg01>
|
||||
Module = 16
|
||||
Flags = "F"
|
||||
Item_01 = "Dichiarazioni d'intento", "li0 -3", ""
|
||||
Item_02 = "Stampa dichiarazioni", "li0 -4", ""
|
||||
Item_03 = "Riepilogo dichiarazioni d'intento", "li0 -1", ""
|
||||
Item_04 = "Riepilogo Documenti/Lettere", "li0 -0", ""
|
||||
Item_05 = "Ricostruzione Plafond Lettere", "li0 -6", ""
|
||||
Item_06 = "Configurazione modulo", "li0 -2", ""
|
||||
|
||||
Item_02 = "Tabella Tipologie di esenzione", "ba3 -0 %TPE", ""
|
||||
Item_03 = "Stampa dichiarazioni", "li0 -4", ""
|
||||
Item_04 = "Riepilogo dichiarazioni d'intento", "li0 -1", ""
|
||||
Item_05 = "Riepilogo Documenti/Lettere", "li0 -0", ""
|
||||
Item_06 = "Ricostruzione Plafond Lettere", "li0 -6", ""
|
||||
Item_07 = "Configurazione modulo", "li0 -2", ""
|
||||
|
Loading…
x
Reference in New Issue
Block a user