Corretti alcuni conflitti
git-svn-id: svn://10.65.10.50/trunk@846 c028cbd2-c16b-5b4b-a496-9718f37d4682
This commit is contained in:
parent
5adee0648c
commit
287d1c812f
@ -13,7 +13,7 @@
|
|||||||
#include "ba1100.h"
|
#include "ba1100.h"
|
||||||
|
|
||||||
|
|
||||||
class BA1100_application : public TApplication
|
class TManutenzione_app : public TApplication
|
||||||
{
|
{
|
||||||
TDir_sheet * _browse;
|
TDir_sheet * _browse;
|
||||||
TMask * _mask;
|
TMask * _mask;
|
||||||
@ -35,11 +35,11 @@ protected:
|
|||||||
const char* dumpfilename(const FileDes& dep) const;
|
const char* dumpfilename(const FileDes& dep) const;
|
||||||
|
|
||||||
public:
|
public:
|
||||||
BA1100_application() : _browse(NULL), _rec(NULL), _mask(NULL) {}
|
TManutenzione_app() : _browse(NULL), _rec(NULL), _mask(NULL) {}
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
void BA1100_application::print()
|
void TManutenzione_app::print()
|
||||||
|
|
||||||
{
|
{
|
||||||
if (_rec == NULL) return;
|
if (_rec == NULL) return;
|
||||||
@ -97,7 +97,7 @@ void BA1100_application::print()
|
|||||||
p.close();
|
p.close();
|
||||||
}
|
}
|
||||||
|
|
||||||
bool BA1100_application::create() // initvar e arrmask
|
bool TManutenzione_app::create() // initvar e arrmask
|
||||||
|
|
||||||
{
|
{
|
||||||
TApplication::create();
|
TApplication::create();
|
||||||
@ -122,7 +122,7 @@ bool BA1100_application::create() // initvar e arrmask
|
|||||||
return TRUE ;
|
return TRUE ;
|
||||||
}
|
}
|
||||||
|
|
||||||
bool BA1100_application::destroy() // releasev e arrmask
|
bool TManutenzione_app::destroy() // releasev e arrmask
|
||||||
|
|
||||||
{
|
{
|
||||||
if (_firm) set_firm(_firm);
|
if (_firm) set_firm(_firm);
|
||||||
@ -132,7 +132,7 @@ bool BA1100_application::destroy() // releasev e arrmask
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void BA1100_application::insert_riga (long riga_sel, TToken_string& riga)
|
void TManutenzione_app::insert_riga (long riga_sel, TToken_string& riga)
|
||||||
{
|
{
|
||||||
const int logicnum = int(riga_sel) + 1;
|
const int logicnum = int(riga_sel) + 1;
|
||||||
const int num_files = (int)_browse->items();
|
const int num_files = (int)_browse->items();
|
||||||
@ -168,7 +168,7 @@ void BA1100_application::insert_riga (long riga_sel, TToken_string& riga)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
const char* BA1100_application::dumpfilename(const FileDes& dep) const
|
const char* TManutenzione_app::dumpfilename(const FileDes& dep) const
|
||||||
{
|
{
|
||||||
TFilename n; n.tempdir();
|
TFilename n; n.tempdir();
|
||||||
#if XVT_OS == XVT_OS_SCOUNIX
|
#if XVT_OS == XVT_OS_SCOUNIX
|
||||||
@ -185,7 +185,7 @@ const char* BA1100_application::dumpfilename(const FileDes& dep) const
|
|||||||
return __tmp_string;
|
return __tmp_string;
|
||||||
}
|
}
|
||||||
|
|
||||||
void BA1100_application::edit_riga (long riga_sel, TToken_string& riga)
|
void TManutenzione_app::edit_riga (long riga_sel, TToken_string& riga)
|
||||||
|
|
||||||
{
|
{
|
||||||
KEY tasto;
|
KEY tasto;
|
||||||
@ -317,7 +317,7 @@ break;
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void BA1100_application::delete_riga ()
|
void TManutenzione_app::delete_riga ()
|
||||||
|
|
||||||
{
|
{
|
||||||
_browse->dir()->get(LF_DIR);
|
_browse->dir()->get(LF_DIR);
|
||||||
@ -334,7 +334,7 @@ void BA1100_application::delete_riga ()
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void BA1100_application::update_dir()
|
void TManutenzione_app::update_dir()
|
||||||
|
|
||||||
{
|
{
|
||||||
const TString pref(prefhndl->name());
|
const TString pref(prefhndl->name());
|
||||||
@ -414,7 +414,7 @@ void BA1100_application::update_dir()
|
|||||||
d.put(LF_DIR, _nordir, _sysdirop);
|
d.put(LF_DIR, _nordir, _sysdirop);
|
||||||
}
|
}
|
||||||
|
|
||||||
void BA1100_application::convert_dir()
|
void TManutenzione_app::convert_dir()
|
||||||
|
|
||||||
{
|
{
|
||||||
const TString pref(prefhndl->name());
|
const TString pref(prefhndl->name());
|
||||||
@ -449,7 +449,7 @@ void BA1100_application::convert_dir()
|
|||||||
d.put(LF_DIR, _nordir, _sysdirop);
|
d.put(LF_DIR, _nordir, _sysdirop);
|
||||||
}
|
}
|
||||||
|
|
||||||
void BA1100_application::update()
|
void TManutenzione_app::update()
|
||||||
|
|
||||||
{
|
{
|
||||||
long firm = get_firm();
|
long firm = get_firm();
|
||||||
@ -457,9 +457,8 @@ void BA1100_application::update()
|
|||||||
if (firm == 0) pref = prefhndl->name();
|
if (firm == 0) pref = prefhndl->name();
|
||||||
|
|
||||||
do_events();
|
do_events();
|
||||||
CURSOR old_cur = get_cursor(TASK_WIN);
|
|
||||||
|
|
||||||
set_cursor(TASK_WIN, CURSOR_WAIT);
|
begin_wait();
|
||||||
prefhndl->set("com");
|
prefhndl->set("com");
|
||||||
update_dir();
|
update_dir();
|
||||||
convert_dir();
|
convert_dir();
|
||||||
@ -485,10 +484,11 @@ void BA1100_application::update()
|
|||||||
}
|
}
|
||||||
if (firm > 0) set_firm(firm);
|
if (firm > 0) set_firm(firm);
|
||||||
else prefhndl->set(pref);
|
else prefhndl->set(pref);
|
||||||
set_cursor(TASK_WIN, old_cur);
|
|
||||||
|
end_wait();
|
||||||
}
|
}
|
||||||
|
|
||||||
bool BA1100_application::menu(MENU_TAG m)
|
bool TManutenzione_app::menu(MENU_TAG m)
|
||||||
{
|
{
|
||||||
TToken_string riga;
|
TToken_string riga;
|
||||||
long riga_selezionata;
|
long riga_selezionata;
|
||||||
@ -539,7 +539,7 @@ bool BA1100_application::menu(MENU_TAG m)
|
|||||||
|
|
||||||
int ba1100(int argc, char** argv)
|
int ba1100(int argc, char** argv)
|
||||||
{
|
{
|
||||||
BA1100_application a;
|
TManutenzione_app a;
|
||||||
a.run(argc, argv, "Gestione files");
|
a.run(argc, argv, "Gestione files");
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
@ -14,10 +14,10 @@
|
|||||||
#define FLD_GD1_CODDITTAH 627
|
#define FLD_GD1_CODDITTAH 627
|
||||||
|
|
||||||
|
|
||||||
class BA4200_application : public TRelation_application
|
class TPersone_app : public TRelation_application
|
||||||
{
|
{
|
||||||
char _tip_ana ;
|
char _tip_ana ;
|
||||||
TString _cod_ana ;
|
TString16 _cod_ana ;
|
||||||
TMask* _msk[2] ;
|
TMask* _msk[2] ;
|
||||||
TRelation* _rel[2];
|
TRelation* _rel[2];
|
||||||
TLocalisamfile* _comuni;
|
TLocalisamfile* _comuni;
|
||||||
@ -51,13 +51,13 @@ public:
|
|||||||
char tip_ana() { return _tip_ana;}
|
char tip_ana() { return _tip_ana;}
|
||||||
virtual bool force_cursor_usage() const { return TRUE;}
|
virtual bool force_cursor_usage() const { return TRUE;}
|
||||||
|
|
||||||
BA4200_application(char ta) { set_tip_ana(ta); }
|
TPersone_app(char ta) { set_tip_ana(ta); }
|
||||||
virtual ~BA4200_application() {}
|
virtual ~TPersone_app() {}
|
||||||
};
|
};
|
||||||
|
|
||||||
bool BA4200_application::ba4200_handler(TMask& m, KEY k)
|
bool TPersone_app::ba4200_handler(TMask& m, KEY k)
|
||||||
{
|
{
|
||||||
BA4200_application& app = (BA4200_application&)main_app();
|
TPersone_app& app = (TPersone_app&)main_app();
|
||||||
|
|
||||||
if (k == K_F10)
|
if (k == K_F10)
|
||||||
{
|
{
|
||||||
@ -101,14 +101,14 @@ bool BA4200_application::ba4200_handler(TMask& m, KEY k)
|
|||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
void BA4200_application::init_query_mode(TMask& m)
|
void TPersone_app::init_query_mode(TMask& m)
|
||||||
|
|
||||||
{
|
{
|
||||||
m.disable(DLG_DITTE);
|
m.disable(DLG_DITTE);
|
||||||
m.enable(DLG_CHGTIP);
|
m.enable(DLG_CHGTIP);
|
||||||
}
|
}
|
||||||
|
|
||||||
const char* BA4200_application::get_next_key()
|
const char* TPersone_app::get_next_key()
|
||||||
|
|
||||||
{
|
{
|
||||||
TLocalisamfile& anag = get_relation()->lfile() ;
|
TLocalisamfile& anag = get_relation()->lfile() ;
|
||||||
@ -143,14 +143,14 @@ const char* BA4200_application::get_next_key()
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void BA4200_application::init_insert_mode(TMask& m)
|
void TPersone_app::init_insert_mode(TMask& m)
|
||||||
{
|
{
|
||||||
m.disable(DLG_DITTE);
|
m.disable(DLG_DITTE);
|
||||||
m.disable(DLG_CHGTIP);
|
m.disable(DLG_CHGTIP);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void BA4200_application::init_modify_mode(TMask& m)
|
void TPersone_app::init_modify_mode(TMask& m)
|
||||||
{
|
{
|
||||||
m.enable(DLG_DITTE);
|
m.enable(DLG_DITTE);
|
||||||
m.disable(DLG_CHGTIP);
|
m.disable(DLG_CHGTIP);
|
||||||
@ -167,7 +167,7 @@ HIDDEN bool clear_cap(TMask_field& f, KEY key)
|
|||||||
if (dlg != FLD_AG2_COMRES && dlg != FLD_AF1_COMRES && !f.to_check(key, TRUE))
|
if (dlg != FLD_AG2_COMRES && dlg != FLD_AF1_COMRES && !f.to_check(key, TRUE))
|
||||||
return TRUE;
|
return TRUE;
|
||||||
|
|
||||||
const bool giuridica = ((BA4200_application&)main_app()).ana_giu();
|
const bool giuridica = ((TPersone_app&)main_app()).ana_giu();
|
||||||
const TString16 val(f.get());
|
const TString16 val(f.get());
|
||||||
|
|
||||||
if ( giuridica )
|
if ( giuridica )
|
||||||
@ -210,7 +210,7 @@ bool gest_uff_imp(TMask_field& f, KEY key)
|
|||||||
|
|
||||||
TMask& msk = f.mask() ;
|
TMask& msk = f.mask() ;
|
||||||
const short dlg = f.dlg();
|
const short dlg = f.dlg();
|
||||||
const bool giuridica = ((BA4200_application&)main_app()).ana_giu();
|
const bool giuridica = ((TPersone_app&)main_app()).ana_giu();
|
||||||
|
|
||||||
if (giuridica && dlg == FLD_AG2_COMRES)
|
if (giuridica && dlg == FLD_AG2_COMRES)
|
||||||
clear_cap(f,key);
|
clear_cap(f,key);
|
||||||
@ -273,7 +273,7 @@ bool gest_uff_imp(TMask_field& f, KEY key)
|
|||||||
bool no_dup_fis(TMask_field& f, KEY key)
|
bool no_dup_fis(TMask_field& f, KEY key)
|
||||||
{
|
{
|
||||||
if (f.mask().query_mode() || !f.to_check(key)) return TRUE;
|
if (f.mask().query_mode() || !f.to_check(key)) return TRUE;
|
||||||
BA4200_application& app = (BA4200_application&)main_app();
|
TPersone_app& app = (TPersone_app&)main_app();
|
||||||
TLocalisamfile& anag = app.get_relation()->lfile(LF_ANAG) ;
|
TLocalisamfile& anag = app.get_relation()->lfile(LF_ANAG) ;
|
||||||
|
|
||||||
const TString16 cofi(f.get());
|
const TString16 cofi(f.get());
|
||||||
@ -302,7 +302,7 @@ bool gest_iva(TMask_field& f, KEY key , short fd_sta ,short fd_iva )
|
|||||||
{
|
{
|
||||||
if (f.mask().query_mode() || !f.to_check(key)) return TRUE;
|
if (f.mask().query_mode() || !f.to_check(key)) return TRUE;
|
||||||
|
|
||||||
BA4200_application& app = (BA4200_application&)main_app();
|
TPersone_app& app = (TPersone_app&)main_app();
|
||||||
TLocalisamfile& anag = app.get_relation()->lfile(LF_ANAG) ;
|
TLocalisamfile& anag = app.get_relation()->lfile(LF_ANAG) ;
|
||||||
TMask& msk = f.mask() ;
|
TMask& msk = f.mask() ;
|
||||||
|
|
||||||
@ -354,7 +354,7 @@ bool no_dup_iva_g(TMask_field& f, KEY key)
|
|||||||
return gest_iva(f , key , FLD_AG1_STATOPAIV ,FLD_AG1_PAIV ) ;
|
return gest_iva(f , key , FLD_AG1_STATOPAIV ,FLD_AG1_PAIV ) ;
|
||||||
}
|
}
|
||||||
|
|
||||||
TMask* BA4200_application::get_mask(int mode)
|
TMask* TPersone_app::get_mask(int mode)
|
||||||
{
|
{
|
||||||
if (!changing_mask(mode)) return _msk[tip_msk()];
|
if (!changing_mask(mode)) return _msk[tip_msk()];
|
||||||
if (ana_fis())
|
if (ana_fis())
|
||||||
@ -386,7 +386,7 @@ TMask* BA4200_application::get_mask(int mode)
|
|||||||
return _msk[tip_msk()];
|
return _msk[tip_msk()];
|
||||||
}
|
}
|
||||||
|
|
||||||
bool BA4200_application::user_create()
|
bool TPersone_app::user_create()
|
||||||
|
|
||||||
{
|
{
|
||||||
_msk[MSKF] = NULL;
|
_msk[MSKF] = NULL;
|
||||||
@ -411,14 +411,14 @@ bool BA4200_application::user_create()
|
|||||||
return TRUE;
|
return TRUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
void BA4200_application::write_enable(const bool on)
|
void TPersone_app::write_enable(const bool on)
|
||||||
|
|
||||||
{
|
{
|
||||||
_rel[MSKF]->write_enable(-1, on);
|
_rel[MSKF]->write_enable(-1, on);
|
||||||
_rel[MSKG]->write_enable(-1, on);
|
_rel[MSKG]->write_enable(-1, on);
|
||||||
}
|
}
|
||||||
|
|
||||||
bool BA4200_application::user_destroy()
|
bool TPersone_app::user_destroy()
|
||||||
{
|
{
|
||||||
for ( int j = 0 ; j < 2 ; j++ )
|
for ( int j = 0 ; j < 2 ; j++ )
|
||||||
{
|
{
|
||||||
@ -431,7 +431,7 @@ bool BA4200_application::user_destroy()
|
|||||||
return TRUE;
|
return TRUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
void BA4200_application::manual_save(const TMask& m)
|
void TPersone_app::manual_save(const TMask& m)
|
||||||
|
|
||||||
{
|
{
|
||||||
TRelation *r = get_relation();
|
TRelation *r = get_relation();
|
||||||
@ -453,7 +453,7 @@ void BA4200_application::manual_save(const TMask& m)
|
|||||||
anag.put(N_DATAAGG, oggi.string());
|
anag.put(N_DATAAGG, oggi.string());
|
||||||
}
|
}
|
||||||
|
|
||||||
int BA4200_application::read(TMask& m)
|
int TPersone_app::read(TMask& m)
|
||||||
|
|
||||||
{
|
{
|
||||||
const TRelation *r = get_relation();
|
const TRelation *r = get_relation();
|
||||||
@ -462,7 +462,7 @@ int BA4200_application::read(TMask& m)
|
|||||||
return NOERR;
|
return NOERR;
|
||||||
}
|
}
|
||||||
|
|
||||||
int BA4200_application::write(const TMask& m)
|
int TPersone_app::write(const TMask& m)
|
||||||
|
|
||||||
{
|
{
|
||||||
TRelation *r = get_relation();
|
TRelation *r = get_relation();
|
||||||
@ -472,7 +472,7 @@ int BA4200_application::write(const TMask& m)
|
|||||||
return r->write();
|
return r->write();
|
||||||
}
|
}
|
||||||
|
|
||||||
int BA4200_application::rewrite(const TMask& m)
|
int TPersone_app::rewrite(const TMask& m)
|
||||||
|
|
||||||
{
|
{
|
||||||
TRelation *r = get_relation();
|
TRelation *r = get_relation();
|
||||||
@ -489,7 +489,7 @@ int ba4200(int argc, char* argv[])
|
|||||||
TApplication::check_parameters(argc, argv);
|
TApplication::check_parameters(argc, argv);
|
||||||
if (argc > 2 && toupper(*argv[2]) == 'G') ta = 'G';
|
if (argc > 2 && toupper(*argv[2]) == 'G') ta = 'G';
|
||||||
|
|
||||||
BA4200_application a(ta);
|
TPersone_app a(ta);
|
||||||
|
|
||||||
TString80 titolo("Persone ");
|
TString80 titolo("Persone ");
|
||||||
titolo << (ta == 'F' ? "Fisiche" : "Giuridiche");
|
titolo << (ta == 'F' ? "Fisiche" : "Giuridiche");
|
||||||
|
@ -138,14 +138,14 @@ bool mask_reset_fields(TMask_field& mf, KEY k)
|
|||||||
{
|
{
|
||||||
TMask& m = mf.mask();
|
TMask& m = mf.mask();
|
||||||
BA6100_App& a = (BA6100_App&)main_app();
|
BA6100_App& a = (BA6100_App&)main_app();
|
||||||
m.set(FLD_BA6B_INDROW, a._ind_row));
|
m.set(FLD_BA6B_INDROW, a._ind_row);
|
||||||
m.set(FLD_BA6B_INDCOL, a._ind_col));
|
m.set(FLD_BA6B_INDCOL, a._ind_col);
|
||||||
m.set(FLD_BA6B_PIVROW, a._piv_row));
|
m.set(FLD_BA6B_PIVROW, a._piv_row);
|
||||||
m.set(FLD_BA6B_PIVCOL, a._piv_col));
|
m.set(FLD_BA6B_PIVCOL, a._piv_col);
|
||||||
m.set(FLD_BA6B_CODROW, a._cod_row));
|
m.set(FLD_BA6B_CODROW, a._cod_row);
|
||||||
m.set(FLD_BA6B_CODCOL, a._cod_col));
|
m.set(FLD_BA6B_CODCOL, a._cod_col);
|
||||||
m.set(FLD_BA6B_TOTROW, a._rows_et));
|
m.set(FLD_BA6B_TOTROW, a._rows_et);
|
||||||
m.set(FLD_BA6B_TOTCOL, a._cols_et));
|
m.set(FLD_BA6B_TOTCOL, a._cols_et);
|
||||||
m.set(CHK_BA6B_PIVA, a._is_piv ? "X" : " ");
|
m.set(CHK_BA6B_PIVA, a._is_piv ? "X" : " ");
|
||||||
m.set(CHK_BA6B_CODICE, a._is_cod ? "X": " ");
|
m.set(CHK_BA6B_CODICE, a._is_cod ? "X": " ");
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user