*** empty log message ***

git-svn-id: svn://10.65.10.50/trunk@4 c028cbd2-c16b-5b4b-a496-9718f37d4682
This commit is contained in:
guy 1994-08-16 07:07:09 +00:00
parent ed742ea403
commit b0ab13f0fc
3 changed files with 1956 additions and 1922 deletions

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -23,118 +23,119 @@
class TPrimanota_application : public TRelation_application class TPrimanota_application : public TRelation_application
{ {
TMovimentoPN* _rel; TMovimentoPN* _rel;
TLocalisamfile* _tabcom; TLocalisamfile* _tabcom;
TLocalisamfile* _tab; TLocalisamfile* _tab;
TLocalisamfile* _caus; TLocalisamfile* _caus;
TLocalisamfile* _rcaus; TLocalisamfile* _rcaus;
TLocalisamfile* _clifo; TLocalisamfile* _clifo;
TLocalisamfile* _pcon; TLocalisamfile* _pcon;
TLocalisamfile* _attiv; TLocalisamfile* _attiv;
TLocalisamfile* _saldo; TLocalisamfile* _saldo;
TLocalisamfile* _comuni; TLocalisamfile* _comuni;
TLocalisamfile* _occas; TLocalisamfile* _occas;
TLocalisamfile* _nditte; TLocalisamfile* _nditte;
TCausale _causale; // Causale corrente TCausale _causale; // Causale corrente
TLibro_giornale _giornale; // Libro giornale corrente TLibro_giornale _giornale; // Libro giornale corrente
TipoIVA _iva; // Tipo di IVA corrente TipoIVA _iva; // Tipo di IVA corrente
TSaldo_agg _saldi; // Saldi da aggiornare TSaldo_agg _saldi; // Saldi da aggiornare
TMask* _msk[4]; // Maschere di query, cg, iva TMask* _msk[4]; // Maschere di query, cg, iva
long _lastreg; // Numero ultima registrazione long _lastreg; // Numero ultima registrazione
int _mode; // Modo maschera corrente int _mode; // Modo maschera corrente
static bool suspended_handler(TMask_field& f, KEY k); static bool suspended_handler(TMask_field& f, KEY k);
static bool num_handler(TMask_field& f, KEY key); static bool num_handler(TMask_field& f, KEY key);
static bool caus_query_handler(TMask_field& f, KEY key); static bool caus_query_handler(TMask_field& f, KEY key);
static bool caus_modify_handler(TMask_field& f, KEY key); static bool caus_modify_handler(TMask_field& f, KEY key);
static bool datareg_handler(TMask_field& f, KEY key); static bool datareg_handler(TMask_field& f, KEY key);
static bool datacomp_handler(TMask_field& f, KEY key); static bool datacomp_handler(TMask_field& f, KEY key);
static bool data74ter_handler(TMask_field& f, KEY key); static bool data74ter_handler(TMask_field& f, KEY key);
static bool reg_handler(TMask_field& f, KEY key); static bool reg_handler(TMask_field& f, KEY key);
static bool clifo_handler(TMask_field& f, KEY key); static bool clifo_handler(TMask_field& f, KEY key);
static bool totale_handler(TMask_field& f, KEY key); static bool totale_handler(TMask_field& f, KEY key);
static bool ritfis_handler(TMask_field& f, KEY key); static bool ritfis_handler(TMask_field& f, KEY key);
static bool ritsoc_handler(TMask_field& f, KEY key); static bool ritsoc_handler(TMask_field& f, KEY key);
static bool visval_handler(TMask_field& f, KEY key); static bool visval_handler(TMask_field& f, KEY key);
static bool occas_code_handler(TMask_field& f, KEY key); static bool occas_code_handler(TMask_field& f, KEY key);
static bool occas_handler(TMask_field& f, KEY key); static bool occas_handler(TMask_field& f, KEY key);
static bool solaiva_handler(TMask_field& f, KEY key); static bool solaiva_handler(TMask_field& f, KEY key);
static bool descr_handler(TMask_field& f, KEY k); static bool descr_handler(TMask_field& f, KEY k);
static bool imponibile_handler(TMask_field& f, KEY key); static bool imponibile_handler(TMask_field& f, KEY key);
static bool codiva_handler(TMask_field& f, KEY key); static bool codiva_handler(TMask_field& f, KEY key);
static bool imposta_handler(TMask_field& f, KEY key); static bool imposta_handler(TMask_field& f, KEY key);
static bool dareavere_handler(TMask_field& f, KEY k); static bool dareavere_handler(TMask_field& f, KEY k);
static bool conto_handler(TMask_field& f, KEY key); static bool conto_handler(TMask_field& f, KEY key);
static bool iva_notify(int r, KEY key); static bool iva_notify(int r, KEY key);
static bool cg_notify(int r, KEY key); static bool iva_handler(TMask_field& f, KEY key);
static bool cg_handler(TMask_field& f, KEY key); static bool cg_notify(int r, KEY key);
static bool cg_handler(TMask_field& f, KEY key);
protected: protected:
virtual bool user_create(); virtual bool user_create();
virtual bool user_destroy(); virtual bool user_destroy();
virtual bool changing_mask(int mode); virtual bool changing_mask(int mode);
virtual TMask* get_mask(int mode); virtual TMask* get_mask(int mode);
virtual TRelation* get_relation() const { return _rel; } virtual TRelation* get_relation() const { return _rel; }
virtual void init_query_mode(TMask& m); virtual void init_query_mode(TMask& m);
virtual void init_insert_mode(TMask& m); virtual void init_insert_mode(TMask& m);
virtual void init_modify_mode(TMask& m); virtual void init_modify_mode(TMask& m);
virtual const char* get_next_key(); virtual const char* get_next_key();
virtual int read(TMask& m); virtual int read(TMask& m);
virtual int write(const TMask& m); virtual int write(const TMask& m);
virtual int rewrite(const TMask& m); virtual int rewrite(const TMask& m);
virtual bool remove(); virtual bool remove();
void genera_incasso(const char* causimm); void genera_incasso(const char* causimm);
TMask* load_mask(int n); TMask* load_mask(int n);
TMask& occas_mask() { return *load_mask(3); } TMask& occas_mask() { return *load_mask(3); }
bool get_conto(int r, TConto& c) const; bool get_conto(int r, TConto& c) const;
void mask2rel(const TMask& m); void mask2rel(const TMask& m);
TipoIVA iva() const { return _iva; } TipoIVA iva() const { return _iva; }
TMask& TPrimanota_application::mask() const; TMask& TPrimanota_application::mask() const;
void fill_sheet(TMask& m) const; void fill_sheet(TMask& m) const;
void init_mask(TMask& m); void init_mask(TMask& m);
TSheet_field& cgs() const; TSheet_field& cgs() const;
TSheet_field& ivas() const; TSheet_field& ivas() const;
static real imp2sez(const real& importo); static real imp2sez(const real& importo);
static int bill2pos(const TConto& conto, char tipo); static int bill2pos(const TConto& conto, char tipo);
static TipoIVA reg2IVA(const char* registro, int anno); static TipoIVA reg2IVA(const char* registro, int anno);
static TipoIVA cau2IVA(const char* causale, int anno); static TipoIVA cau2IVA(const char* causale, int anno);
static int type2pos(char tipo); static int type2pos(char tipo);
static const real& cod2IVA(const char* codiva); static const real& cod2IVA(const char* codiva);
static real scorpora(real& imponibile, const real& percentuale); static real scorpora(real& imponibile, const real& percentuale);
static int date2esc(const TDate& d, int* prev = NULL); static int date2esc(const TDate& d, int* prev = NULL);
static bool detraibile(int tipodet); static bool detraibile(int tipodet);
bool bill_used(const TConto& conto) const; bool bill_used(const TConto& conto) const;
int bill2contr(const TConto& c, char sezione) const; int bill2contr(const TConto& c, char sezione) const;
bool read_caus(const char* cod, int year); bool read_caus(const char* cod, int year);
TCausale& causale() { return _causale; } TCausale& causale() { return _causale; }
TLibro_giornale& giornale() { return _giornale; } TLibro_giornale& giornale() { return _giornale; }
void set_cgs_imp(int n, const real& importo); void set_cgs_imp(int n, const real& importo);
real get_cgs_imp(int n); real get_cgs_imp(int n);
void add_cgs_imp(int n, const real& importo); void add_cgs_imp(int n, const real& importo);
void cgs_pack(); void cgs_pack();
void set_ivas_row(int n, const char* codiva, TConto& tc, const char* desc); void set_ivas_row(int n, const char* codiva, TConto& tc, const char* desc);
int set_cgs_row(int n, const real& importo, TConto& conto, const char* desc, char tipo); int set_cgs_row(int n, const real& importo, TConto& conto, const char* desc, char tipo);
void disable_cgs_cells(int n, char tipo); void disable_cgs_cells(int n, char tipo);
void add_cgs_tot(TMask& m); void add_cgs_tot(TMask& m);
void add_cgs_rit(bool fisc); void add_cgs_rit(bool fisc);
public: public:
TPrimanota_application(); TPrimanota_application();
}; };
#endif #endif