Correzione programma gestione DNINST
Correzione allineamento campi in maschera Banche Correzione allineamento campi in maschera Contatti git-svn-id: svn://10.65.10.50/branches/R_10_00@22653 c028cbd2-c16b-5b4b-a496-9718f37d4682
This commit is contained in:
parent
70b7377a24
commit
15b790159f
@ -600,11 +600,16 @@ bool TOutlook_mask::can_be_closed() const
|
|||||||
TBook_field& bf = book_field();
|
TBook_field& bf = book_field();
|
||||||
if (bf.pages() > 0)
|
if (bf.pages() > 0)
|
||||||
{
|
{
|
||||||
TMask cm(TR("Chiusura applicazioni"), 1, 50, 7);
|
TMask cm(TR("Chiusura applicazioni"), 1, 50, 8);
|
||||||
cm.add_radio(DLG_USER, 0, TR("Azione"), 1, 0, 48, "0|1",
|
|
||||||
TR("Non chiudere le applicazioni in esecuzione|Chiusura forzata (solo in caso d'emergenza)"));
|
TToken_string options;
|
||||||
|
options = TR("Non chiudere le applicazioni in esecuzione");
|
||||||
|
options.add(TR("Chiusura forzata (solo in caso d'emergenza)"));
|
||||||
|
cm.add_radio(DLG_USER, 0, TR("Azione"), 1, 0, 48, "0|1", options);
|
||||||
|
|
||||||
cm.add_button(DLG_OK, 0, "", -12, -1, 10, 2);
|
cm.add_button(DLG_OK, 0, "", -12, -1, 10, 2);
|
||||||
cm.add_button(DLG_CANCEL, 0, "", -22, -1, 10, 2);
|
cm.add_button(DLG_CANCEL, 0, "", -22, -1, 10, 2);
|
||||||
|
|
||||||
if (cm.run() == K_ENTER && cm.get_int(DLG_USER))
|
if (cm.run() == K_ENTER && cm.get_int(DLG_USER))
|
||||||
bf.kill_processes();
|
bf.kill_processes();
|
||||||
}
|
}
|
||||||
|
407
ba/ba2800.cpp
407
ba/ba2800.cpp
@ -43,7 +43,7 @@ int smart_cmp(const char* s1, const char* s2)
|
|||||||
// TOEM_cache
|
// TOEM_cache
|
||||||
///////////////////////////////////////////////////////////
|
///////////////////////////////////////////////////////////
|
||||||
|
|
||||||
class TOEM_cache
|
class TOEM_cache : public TObject
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
int Agente2OEM(int agente) const;
|
int Agente2OEM(int agente) const;
|
||||||
@ -88,11 +88,13 @@ public:
|
|||||||
bool exists(int key) const { return _chiavi.objptr(key) != NULL; }
|
bool exists(int key) const { return _chiavi.objptr(key) != NULL; }
|
||||||
|
|
||||||
bool load();
|
bool load();
|
||||||
bool save() const;
|
bool save(int version) const;
|
||||||
};
|
};
|
||||||
|
|
||||||
const char* const DNINST_ZIP = "setup/dninst.zip";
|
#define DNINST "setup/dninst."
|
||||||
const char* const DNINST_TXT = "setup/dninst.txt";
|
const char* const DNINST_ZIP = DNINST"zip";
|
||||||
|
const char* const DNINST_TXT = DNINST"txt";
|
||||||
|
const char* const DNINST_BAK = DNINST"bak";
|
||||||
|
|
||||||
void Tdnist_full::set(int key, const char* var, const TString& value)
|
void Tdnist_full::set(int key, const char* var, const TString& value)
|
||||||
{
|
{
|
||||||
@ -161,15 +163,16 @@ bool Tdnist_full::load()
|
|||||||
return !_chiavi.empty();
|
return !_chiavi.empty();
|
||||||
}
|
}
|
||||||
|
|
||||||
bool Tdnist_full::save() const
|
bool Tdnist_full::save(int version) const
|
||||||
{
|
{
|
||||||
Tdninst dninst;
|
Tdninst dninst;
|
||||||
bool done = dninst.ok();
|
bool done = dninst.ok();
|
||||||
|
|
||||||
if (done)
|
if (done)
|
||||||
{
|
{
|
||||||
|
const int ass_year = version < 11 ? 2101 : 2121;
|
||||||
ofstream out(DNINST_TXT);
|
ofstream out(DNINST_TXT);
|
||||||
out << dninst.assist_year() << endl;
|
out << ass_year << endl;
|
||||||
FOR_EACH_ARRAY_ITEM(_chiavi, key, obj)
|
FOR_EACH_ARRAY_ITEM(_chiavi, key, obj)
|
||||||
{
|
{
|
||||||
out << '[' << key << ']' << endl;
|
out << '[' << key << ']' << endl;
|
||||||
@ -183,7 +186,8 @@ bool Tdnist_full::save() const
|
|||||||
{
|
{
|
||||||
done = dninst.encode(DNINST_TXT);
|
done = dninst.encode(DNINST_TXT);
|
||||||
#ifdef DBG
|
#ifdef DBG
|
||||||
fcopy(DNINST_TXT, "../setup/dninst.txt");
|
if (version == 11)
|
||||||
|
fcopy(DNINST_TXT, "../src/setup/dninst.txt");
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -191,14 +195,14 @@ bool Tdnist_full::save() const
|
|||||||
}
|
}
|
||||||
|
|
||||||
///////////////////////////////////////////////////////////
|
///////////////////////////////////////////////////////////
|
||||||
// Tdnist_mask
|
// Tdninst_mask
|
||||||
///////////////////////////////////////////////////////////
|
///////////////////////////////////////////////////////////
|
||||||
|
|
||||||
static int _c_key, _c_oem, _c_owner, _c_suspend, _c_killed;
|
static int _c_key, _c_oem, _c_owner, _c_suspend, _c_killed;
|
||||||
static int _c_dboem, _c_dbowner, _c_dbsuspend, _c_dbkilled;
|
static int _c_dboem, _c_dbowner, _c_dbsuspend, _c_dbkilled;
|
||||||
static int _c_xmloem, _c_xmlowner, _c_xmlaccess;
|
static int _c_xmloem, _c_xmlowner, _c_xmlaccess;
|
||||||
|
|
||||||
class Tdnist_mask : public TAutomask
|
class Tdninst_mask : public TAutomask
|
||||||
{
|
{
|
||||||
TOEM_cache _oem;
|
TOEM_cache _oem;
|
||||||
Tdnist_full _dninst;
|
Tdnist_full _dninst;
|
||||||
@ -206,7 +210,7 @@ class Tdnist_mask : public TAutomask
|
|||||||
private:
|
private:
|
||||||
static int dongle_compare(const TSortable& o1, const TSortable& o2, void* jolly);
|
static int dongle_compare(const TSortable& o1, const TSortable& o2, void* jolly);
|
||||||
|
|
||||||
const TString& remote_dninst() const;
|
const TString& remote_dninst(int version) const;
|
||||||
|
|
||||||
void load_dninst(TString_array& a);
|
void load_dninst(TString_array& a);
|
||||||
bool load_odbc(TString_array& a) const;
|
bool load_odbc(TString_array& a) const;
|
||||||
@ -214,15 +218,73 @@ private:
|
|||||||
TToken_string& find_or_create_line(TString_array& a, int key) const;
|
TToken_string& find_or_create_line(TString_array& a, int key) const;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
void fill_sheet();
|
|
||||||
void merge_sheet();
|
|
||||||
virtual bool on_field_event(TOperable_field& o, TField_event e, long jolly);
|
virtual bool on_field_event(TOperable_field& o, TField_event e, long jolly);
|
||||||
|
bool fill_sheet();
|
||||||
|
void merge_sheet();
|
||||||
|
void save_sheet();
|
||||||
|
void log(int severity, const char* msg) const;
|
||||||
|
bool get_remote_dninst();
|
||||||
|
bool send_remote_dninst(const TString& ftp) const;
|
||||||
|
|
||||||
public:
|
public:
|
||||||
Tdnist_mask();
|
void overnight_batch();
|
||||||
|
|
||||||
|
Tdninst_mask();
|
||||||
};
|
};
|
||||||
|
|
||||||
int Tdnist_mask::dongle_compare(const TSortable& o1, const TSortable& o2, void* jolly)
|
void Tdninst_mask::log(int severity, const char* msg) const
|
||||||
|
{
|
||||||
|
FILE* f = fopen("DNINST.log", "a");
|
||||||
|
if (f != NULL)
|
||||||
|
{
|
||||||
|
if (msg && *msg > ' ')
|
||||||
|
{
|
||||||
|
char sev = ' ';
|
||||||
|
switch (severity)
|
||||||
|
{
|
||||||
|
case 0: sev = ' '; break;
|
||||||
|
case 1: sev = '-'; break;
|
||||||
|
default: sev = '!'; break;
|
||||||
|
}
|
||||||
|
time_t rawtime; time(&rawtime);
|
||||||
|
struct tm * timeinfo = localtime (&rawtime);
|
||||||
|
fprintf(f, "%c %02d-%02d-%04d %02d:%02d:%02d %s\n", sev,
|
||||||
|
timeinfo->tm_mday, timeinfo->tm_mon, timeinfo->tm_year+1900,
|
||||||
|
timeinfo->tm_hour, timeinfo->tm_min, timeinfo->tm_sec,
|
||||||
|
msg);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
fputc('\n', f);
|
||||||
|
fclose(f);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
void Tdninst_mask::overnight_batch()
|
||||||
|
{
|
||||||
|
log(0, TR("Inizio procedura aggiornamento DNINST"));
|
||||||
|
|
||||||
|
set(F_ZIP_ON, "X");
|
||||||
|
set(F_DSN_ON, "X");
|
||||||
|
set(F_XML_ON, "");
|
||||||
|
on_field_event(efield(F_ZIP_WWW), fe_init, 0);
|
||||||
|
on_field_event(efield(F_DSN_WWW), fe_init, 0);
|
||||||
|
|
||||||
|
log(0, TR("Caricamento dati da DSN"));
|
||||||
|
if (get_remote_dninst())
|
||||||
|
{
|
||||||
|
fill_sheet();
|
||||||
|
log(0, TR("Elaborazione abilitazioni"));
|
||||||
|
merge_sheet();
|
||||||
|
|
||||||
|
log(0, TR("Salvataggio dati"));
|
||||||
|
save_sheet();
|
||||||
|
}
|
||||||
|
|
||||||
|
log(0, TR("Fine procedura aggiornamento DNINST"));
|
||||||
|
log(0, "\n");
|
||||||
|
}
|
||||||
|
|
||||||
|
int Tdninst_mask::dongle_compare(const TSortable& o1, const TSortable& o2, void* jolly)
|
||||||
{
|
{
|
||||||
TToken_string& d1 = (TToken_string&)o1;
|
TToken_string& d1 = (TToken_string&)o1;
|
||||||
TToken_string& d2 = (TToken_string&)o2;
|
TToken_string& d2 = (TToken_string&)o2;
|
||||||
@ -239,7 +301,17 @@ int Tdnist_mask::dongle_compare(const TSortable& o1, const TSortable& o2, void*
|
|||||||
const int cmp = smart_cmp(o1, o2);
|
const int cmp = smart_cmp(o1, o2);
|
||||||
if (cmp != 0)
|
if (cmp != 0)
|
||||||
return cmp;
|
return cmp;
|
||||||
|
} else
|
||||||
|
if (sort == 3)
|
||||||
|
{
|
||||||
|
const TDate a1 = d1.get(_c_xmlaccess);
|
||||||
|
const TDate a2 = d2.get(_c_xmlaccess);
|
||||||
|
int cmp = a2.date2ansi() - a1.date2ansi();
|
||||||
|
if (cmp == 0)
|
||||||
|
cmp = atoi(d1) - atoi(d2);
|
||||||
|
return cmp;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (sort >= 1)
|
if (sort >= 1)
|
||||||
{
|
{
|
||||||
const char* o1 = d1.get(_c_owner);
|
const char* o1 = d1.get(_c_owner);
|
||||||
@ -256,19 +328,29 @@ int Tdnist_mask::dongle_compare(const TSortable& o1, const TSortable& o2, void*
|
|||||||
return atoi(d1) - atoi(d2);
|
return atoi(d1) - atoi(d2);
|
||||||
}
|
}
|
||||||
|
|
||||||
const TString& Tdnist_mask::remote_dninst() const
|
const TString& Tdninst_mask::remote_dninst(int version) const
|
||||||
{
|
{
|
||||||
TString& path = get_tmp_string();
|
if (!get_bool(F_ZIP_ON) || field(F_ZIP_WWW).empty())
|
||||||
if (get_bool(F_DNINST_ON))
|
return EMPTY_STRING;
|
||||||
|
|
||||||
|
if (version < 10)
|
||||||
{
|
{
|
||||||
path = get(F_DNINST); path.lower();
|
int year, tag, patch;
|
||||||
if (!path.ends_with(DNINST_ZIP))
|
main_app().get_version_info(year, version, tag, patch);
|
||||||
path << "/" << DNINST_ZIP;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
TString& path = get_tmp_string();
|
||||||
|
path << "ftp://" << get(F_ZIP_USR)
|
||||||
|
<< ':' << get(F_ZIP_PWD)
|
||||||
|
<< '@' << get(F_ZIP_WWW)
|
||||||
|
<< '/' << get(F_ZIP_USR)
|
||||||
|
<< "/release/v_" << version
|
||||||
|
<< ".0/program/" << DNINST_ZIP;
|
||||||
|
|
||||||
return path;
|
return path;
|
||||||
}
|
}
|
||||||
|
|
||||||
void Tdnist_mask::load_dninst(TString_array& a)
|
void Tdninst_mask::load_dninst(TString_array& a)
|
||||||
{
|
{
|
||||||
_dninst.load();
|
_dninst.load();
|
||||||
|
|
||||||
@ -285,7 +367,7 @@ void Tdnist_mask::load_dninst(TString_array& a)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
TToken_string& Tdnist_mask::find_or_create_line(TString_array& a, int key) const
|
TToken_string& Tdninst_mask::find_or_create_line(TString_array& a, int key) const
|
||||||
{
|
{
|
||||||
int mi = 0, ma = a.last();
|
int mi = 0, ma = a.last();
|
||||||
int k = 0;
|
int k = 0;
|
||||||
@ -308,19 +390,21 @@ TToken_string& Tdnist_mask::find_or_create_line(TString_array& a, int key) const
|
|||||||
return *str;
|
return *str;
|
||||||
}
|
}
|
||||||
|
|
||||||
bool Tdnist_mask::load_odbc(TString_array& a) const
|
bool Tdninst_mask::load_odbc(TString_array& a) const
|
||||||
{
|
{
|
||||||
if (!get_bool(F_DSN_ON))
|
const TString& dsn = get(F_DSN_WWW);
|
||||||
return false;
|
bool done = false;
|
||||||
|
|
||||||
|
if (dsn.full())
|
||||||
|
{
|
||||||
TString query;
|
TString query;
|
||||||
query << "ODBC(" << get(F_DSN) << ")\n"
|
query << "ODBC(" << dsn << ")\n"
|
||||||
<< "SELECT chiavette.codice AS Chiave, Agente, RagioneSociale, DataDisattivazione\n"
|
<< "SELECT chiavette.codice AS Chiave, Agente, RagioneSociale, DataDisattivazione\n"
|
||||||
<< "FROM chiavette,clienti WHERE chiavette.cliente=clienti.codice\n"
|
<< "FROM chiavette,clienti WHERE chiavette.cliente=clienti.codice\n"
|
||||||
<< "ORDER BY Chiave";
|
<< "ORDER BY Chiave";
|
||||||
|
|
||||||
TODBC_recordset att(query);
|
TODBC_recordset att(query);
|
||||||
TProgind pi(att.items(), get(F_DSN));
|
TProgind pi(att.items(), dsn);
|
||||||
for (bool ok = att.move_first(); ok; ok = att.move_next())
|
for (bool ok = att.move_first(); ok; ok = att.move_next())
|
||||||
{
|
{
|
||||||
if (!pi.addstatus(1)) break;
|
if (!pi.addstatus(1)) break;
|
||||||
@ -344,10 +428,25 @@ bool Tdnist_mask::load_odbc(TString_array& a) const
|
|||||||
default: break;
|
default: break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
done = true;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
return !att.empty();
|
if (!done)
|
||||||
|
{
|
||||||
|
if (is_running())
|
||||||
|
cantread_box(dsn);
|
||||||
|
else
|
||||||
|
{
|
||||||
|
TString msg;
|
||||||
|
msg << TR("Impossibile leggere i dati da ") << dsn;
|
||||||
|
log(2, msg);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return done;
|
||||||
}
|
}
|
||||||
|
|
||||||
static bool XmlScanner(TXmlItem& item, long jolly)
|
static bool XmlScanner(TXmlItem& item, long jolly)
|
||||||
@ -372,23 +471,18 @@ static bool XmlScanner(TXmlItem& item, long jolly)
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
bool Tdnist_mask::load_xml(TString_array& a) const
|
bool Tdninst_mask::load_xml(TString_array& a) const
|
||||||
{
|
{
|
||||||
if (!get_bool(F_FTP_ON))
|
TFilename path;
|
||||||
return false;
|
path << "ftp://" << get(F_XML_USR)
|
||||||
|
<< ':' << get(F_XML_PWD)
|
||||||
TFilename path = get(F_FTP);
|
<< '@' << get(F_XML_WWW)
|
||||||
if (!path.ends_with(".xml"))
|
<< "/attivazioni/?????.xml";
|
||||||
{
|
|
||||||
if (!path.ends_with("/"))
|
|
||||||
path << '/';
|
|
||||||
path << "attivazioni/?????.xml";
|
|
||||||
}
|
|
||||||
|
|
||||||
TString_array xml;
|
TString_array xml;
|
||||||
list_files(path, xml);
|
list_files(path, xml);
|
||||||
|
|
||||||
TString msg; msg.format(FR("Scansione cartella %s: %d files"), path.path(), xml.items());
|
TString msg; msg.format(FR("Scansione cartella %s: %d files"), (const char*)path, xml.items());
|
||||||
TProgind pi(xml.items(), msg);
|
TProgind pi(xml.items(), msg);
|
||||||
TFilename fname, tmpname;
|
TFilename fname, tmpname;
|
||||||
TFilename tmpdir; tmpdir.tempdir(); tmpdir.add("www");
|
TFilename tmpdir; tmpdir.tempdir(); tmpdir.add("www");
|
||||||
@ -420,14 +514,45 @@ bool Tdnist_mask::load_xml(TString_array& a) const
|
|||||||
return !xml.empty();
|
return !xml.empty();
|
||||||
}
|
}
|
||||||
|
|
||||||
void Tdnist_mask::fill_sheet()
|
bool Tdninst_mask::get_remote_dninst()
|
||||||
|
{
|
||||||
|
const TString& n = remote_dninst(10);
|
||||||
|
if (n.full())
|
||||||
|
{
|
||||||
|
if (fcopy(n, DNINST_BAK, false, true) && fsize(DNINST_BAK) > 0)
|
||||||
|
{
|
||||||
|
fcopy(DNINST_BAK, DNINST_ZIP);
|
||||||
|
remove(DNINST_BAK);
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (is_running())
|
||||||
|
cantread_box(n);
|
||||||
|
else
|
||||||
|
{
|
||||||
|
TString msg; msg << TR("Impossibile leggere ") << n;
|
||||||
|
log(2, msg);
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
bool Tdninst_mask::fill_sheet()
|
||||||
{
|
{
|
||||||
TSheet_field& s = sfield(F_DNSHEET);
|
TSheet_field& s = sfield(F_DNSHEET);
|
||||||
s.destroy();
|
s.destroy();
|
||||||
|
|
||||||
TString_array& a = s.rows_array();
|
TString_array& a = s.rows_array();
|
||||||
load_dninst(a);
|
load_dninst(a);
|
||||||
load_odbc(a);
|
if (a.empty())
|
||||||
|
return false;
|
||||||
|
|
||||||
|
if (get_bool(F_DSN_ON) && !field(F_DSN_WWW).empty())
|
||||||
|
{
|
||||||
|
if (!load_odbc(a))
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (get_bool(F_XML_ON) && !field(F_XML_WWW).empty())
|
||||||
load_xml(a);
|
load_xml(a);
|
||||||
|
|
||||||
const int sort = get_int(F_SORT);
|
const int sort = get_int(F_SORT);
|
||||||
@ -467,9 +592,10 @@ void Tdnist_mask::fill_sheet()
|
|||||||
s.force_update();
|
s.force_update();
|
||||||
|
|
||||||
enable(DLG_ELABORA, !s.empty());
|
enable(DLG_ELABORA, !s.empty());
|
||||||
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
void Tdnist_mask::merge_sheet()
|
void Tdninst_mask::merge_sheet()
|
||||||
{
|
{
|
||||||
TSheet_field& sheet = sfield(F_DNSHEET);
|
TSheet_field& sheet = sfield(F_DNSHEET);
|
||||||
|
|
||||||
@ -517,78 +643,29 @@ void Tdnist_mask::merge_sheet()
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
killed = row->get(_c_killed);
|
o1 = row->get(_c_suspend); o1.trim();
|
||||||
if (killed.blank())
|
c1 = row->get(_c_dbsuspend); c1.trim();
|
||||||
|
if (o1 != c1)
|
||||||
{
|
{
|
||||||
killed = row->get(_c_dbkilled);
|
row->add(c1, _c_suspend);
|
||||||
if (killed.full())
|
changed++;
|
||||||
row->add(killed, _c_killed);
|
}
|
||||||
|
|
||||||
|
o1 = row->get(_c_killed); o1.trim();
|
||||||
|
c1 = row->get(_c_dbkilled); c1.trim();
|
||||||
|
if (o1 != c1)
|
||||||
|
{
|
||||||
|
row->add(c1, _c_killed);
|
||||||
|
changed++;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
sheet.force_update();
|
sheet.force_update();
|
||||||
TString msg; msg.format(FR("Sono state aggiornate %d chiavi"), changed);
|
TString msg; msg.format(FR("Sono stati aggiornati %d campi"), changed);
|
||||||
xvt_dm_popup_message(msg);
|
xvt_dm_popup_message(msg);
|
||||||
}
|
}
|
||||||
|
|
||||||
static word _last_serno;
|
bool Tdninst_mask::send_remote_dninst(const TString& ftp) const
|
||||||
|
|
||||||
bool Tdnist_mask::on_field_event(TOperable_field& o, TField_event e, long jolly)
|
|
||||||
{
|
|
||||||
switch (o.dlg())
|
|
||||||
{
|
|
||||||
case DLG_RECALC:
|
|
||||||
if (e == fe_button && check_fields())
|
|
||||||
{
|
|
||||||
save_profile();
|
|
||||||
|
|
||||||
const TString& n = remote_dninst();
|
|
||||||
if (n.full())
|
|
||||||
{
|
|
||||||
TFilename tmp; tmp.tempdir(); tmp.add("dninst.zip");
|
|
||||||
if (fcopy(n, tmp, false, true) && fsize(tmp) > 0)
|
|
||||||
{
|
|
||||||
fcopy(tmp, DNINST_ZIP);
|
|
||||||
tmp.fremove();
|
|
||||||
}
|
|
||||||
else
|
|
||||||
cantread_box(n);
|
|
||||||
}
|
|
||||||
fill_sheet();
|
|
||||||
}
|
|
||||||
break;
|
|
||||||
case DLG_ELABORA:
|
|
||||||
if (e == fe_button && yesno_box(TR("Riporare sul DNINST tutte le chiavi presenti solo su DB?")))
|
|
||||||
{
|
|
||||||
merge_sheet();
|
|
||||||
}
|
|
||||||
break;
|
|
||||||
case DLG_SAVEREC:
|
|
||||||
if (e == fe_button)
|
|
||||||
{
|
|
||||||
TSheet_field& sheet = sfield(F_DNSHEET);
|
|
||||||
TString str;
|
|
||||||
FOR_EACH_SHEET_ROW(sheet, r, row)
|
|
||||||
{
|
|
||||||
const int key = row->get_int(0);
|
|
||||||
if (key > 0)
|
|
||||||
{
|
|
||||||
str = row->get(_c_oem);
|
|
||||||
_dninst.set(key, "OEM", str.trim());
|
|
||||||
str = row->get(_c_owner);
|
|
||||||
_dninst.set(key, "Owner", str.trim());
|
|
||||||
str = row->get(_c_suspend);
|
|
||||||
_dninst.set(key, "MustCall", str.trim());
|
|
||||||
str = row->get(_c_killed);
|
|
||||||
_dninst.set(key, "*", str.trim());
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if (_dninst.save())
|
|
||||||
{
|
|
||||||
fill_sheet();
|
|
||||||
const TString& ftp = remote_dninst();
|
|
||||||
if (ftp != DNINST_ZIP && ftp.starts_with("ftp://")
|
|
||||||
&& yesno_box(FR("Copiare il DNINST locale in %s?"), (const char*)ftp))
|
|
||||||
{
|
{
|
||||||
int at = ftp.find('@', 6); if (at < 0) at = 5;
|
int at = ftp.find('@', 6); if (at < 0) at = 5;
|
||||||
int slash = ftp.find('/', at+1);
|
int slash = ftp.find('/', at+1);
|
||||||
@ -610,21 +687,94 @@ bool Tdnist_mask::on_field_event(TOperable_field& o, TField_event e, long jolly)
|
|||||||
aga.RemoveConnection(id);
|
aga.RemoveConnection(id);
|
||||||
}
|
}
|
||||||
if (!sent)
|
if (!sent)
|
||||||
cantwrite_box(ftp);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
break;
|
|
||||||
case F_DNINST_ON:
|
|
||||||
if (e == fe_init)
|
|
||||||
{
|
{
|
||||||
if (field(F_DNINST).empty())
|
if (is_running())
|
||||||
set(F_DNINST, "ftp://guastalla:tk0nmo4q3@85.18.53.183/release/v_11.0/program");
|
cantwrite_box(ftp);
|
||||||
if (field(F_FTP).empty())
|
else
|
||||||
set(F_FTP, "ftp://attivazioni:viagra@85.18.53.183");
|
{
|
||||||
|
TString msg;
|
||||||
|
msg << TR("Impossibile aggiornare il file ") << ftp;
|
||||||
|
log(2, msg);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return sent;
|
||||||
|
}
|
||||||
|
|
||||||
|
void Tdninst_mask::save_sheet()
|
||||||
|
{
|
||||||
|
TSheet_field& sheet = sfield(F_DNSHEET);
|
||||||
|
TString str;
|
||||||
|
FOR_EACH_SHEET_ROW(sheet, r, row)
|
||||||
|
{
|
||||||
|
const int key = row->get_int(0);
|
||||||
|
if (key > 0)
|
||||||
|
{
|
||||||
|
str = row->get(_c_oem);
|
||||||
|
_dninst.set(key, "OEM", str.trim());
|
||||||
|
str = row->get(_c_owner);
|
||||||
|
_dninst.set(key, "Owner", str.trim());
|
||||||
|
str = row->get(_c_suspend);
|
||||||
|
_dninst.set(key, "MustCall", str.trim());
|
||||||
|
str = row->get(_c_killed);
|
||||||
|
_dninst.set(key, "*", str.trim());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (_dninst.save(10))
|
||||||
|
{
|
||||||
|
fill_sheet();
|
||||||
|
const TFilename ftp10 = remote_dninst(10);
|
||||||
|
if (ftp10 != DNINST_ZIP && ftp10.starts_with("ftp://"))
|
||||||
|
if (!is_running() || yesno_box(FR("Copiare il DNINST locale in %s?"), (const char*)ftp10))
|
||||||
|
{
|
||||||
|
send_remote_dninst(ftp10);
|
||||||
|
|
||||||
|
if (fcopy(DNINST_ZIP, DNINST_BAK))
|
||||||
|
{
|
||||||
|
_dninst.save(11);
|
||||||
|
const TFilename ftp11 = remote_dninst(11);
|
||||||
|
send_remote_dninst(ftp11);
|
||||||
|
fcopy(DNINST_BAK, DNINST_ZIP);
|
||||||
|
remove(DNINST_BAK);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
static word _last_serno;
|
||||||
|
|
||||||
|
bool Tdninst_mask::on_field_event(TOperable_field& o, TField_event e, long jolly)
|
||||||
|
{
|
||||||
|
switch (o.dlg())
|
||||||
|
{
|
||||||
|
case DLG_RECALC:
|
||||||
|
if (e == fe_button && check_fields())
|
||||||
|
{
|
||||||
|
get_remote_dninst();
|
||||||
|
fill_sheet();
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case F_DSN:
|
case DLG_ELABORA:
|
||||||
|
if (e == fe_button && yesno_box(TR("Aggiornare il file DNINST in base al DB MySQL?")))
|
||||||
|
merge_sheet();
|
||||||
|
break;
|
||||||
|
case DLG_SAVEREC:
|
||||||
|
if (e == fe_button)
|
||||||
|
save_sheet();
|
||||||
|
break;
|
||||||
|
case F_ZIP_ON:
|
||||||
|
if (e == fe_init && o.get().empty())
|
||||||
|
set(F_ZIP_ON, "X", 0x1);
|
||||||
|
break;
|
||||||
|
case F_ZIP_WWW:
|
||||||
|
if ((e == fe_init || e == fe_modify || e == fe_close) && o.empty())
|
||||||
|
{
|
||||||
|
set(F_ZIP_WWW, "85.18.53.183");
|
||||||
|
set(F_ZIP_USR, "guastalla");
|
||||||
|
set(F_ZIP_PWD, "tk0nmo4q3");
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
case F_DSN_WWW:
|
||||||
if (e == fe_button && !o.empty())
|
if (e == fe_button && !o.empty())
|
||||||
{
|
{
|
||||||
TString query;
|
TString query;
|
||||||
@ -646,6 +796,16 @@ bool Tdnist_mask::on_field_event(TOperable_field& o, TField_event e, long jolly)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
case F_XML_WWW:
|
||||||
|
if ((e == fe_init || e == fe_modify || e == fe_close) && o.empty())
|
||||||
|
{
|
||||||
|
o.set(get(F_XML_WWW));
|
||||||
|
if (o.empty())
|
||||||
|
o.set("85.18.53.183");
|
||||||
|
set(F_XML_USR, "attivazioni");
|
||||||
|
set(F_XML_PWD, "viagra");
|
||||||
|
}
|
||||||
|
break;
|
||||||
case F_SORT:
|
case F_SORT:
|
||||||
if (e == fe_modify)
|
if (e == fe_modify)
|
||||||
{
|
{
|
||||||
@ -720,7 +880,7 @@ bool Tdnist_mask::on_field_event(TOperable_field& o, TField_event e, long jolly)
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
Tdnist_mask::Tdnist_mask() : TAutomask("ba2800a")
|
Tdninst_mask::Tdninst_mask() : TAutomask("ba2800a")
|
||||||
{
|
{
|
||||||
const TSheet_field& s = sfield(F_DNSHEET);
|
const TSheet_field& s = sfield(F_DNSHEET);
|
||||||
TMask& m = s.sheet_mask();
|
TMask& m = s.sheet_mask();
|
||||||
@ -768,7 +928,12 @@ bool Tdninst_manager::create()
|
|||||||
|
|
||||||
void Tdninst_manager::main_loop()
|
void Tdninst_manager::main_loop()
|
||||||
{
|
{
|
||||||
Tdnist_mask m;
|
Tdninst_mask m;
|
||||||
|
|
||||||
|
const TFixed_string a(argv(1));
|
||||||
|
if (a == "-A" || a == "/A")
|
||||||
|
m.overnight_batch();
|
||||||
|
else
|
||||||
m.run();
|
m.run();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
24
ba/ba2800a.h
24
ba/ba2800a.h
@ -1,12 +1,20 @@
|
|||||||
#define F_DNINST 201
|
#define F_ZIP_ON 201
|
||||||
#define F_DSN 202
|
#define F_ZIP_WWW 202
|
||||||
#define F_FTP 203
|
#define F_ZIP_USR 203
|
||||||
#define F_DNINST_ON 211
|
#define F_ZIP_PWD 204
|
||||||
#define F_DSN_ON 212
|
|
||||||
#define F_FTP_ON 213
|
|
||||||
|
|
||||||
#define F_SORT 219
|
#define F_DSN_ON 211
|
||||||
#define F_DNSHEET 220
|
#define F_DSN_WWW 212
|
||||||
|
#define F_DSN_USR 213
|
||||||
|
#define F_DSN_PWD 214
|
||||||
|
|
||||||
|
#define F_XML_ON 221
|
||||||
|
#define F_XML_WWW 222
|
||||||
|
#define F_XML_USR 223
|
||||||
|
#define F_XML_PWD 224
|
||||||
|
|
||||||
|
#define F_SORT 198
|
||||||
|
#define F_DNSHEET 199
|
||||||
|
|
||||||
#define F_NUMBER 101
|
#define F_NUMBER 101
|
||||||
#define F_OEM 102
|
#define F_OEM 102
|
||||||
|
@ -27,44 +27,88 @@ ENDPAGE
|
|||||||
|
|
||||||
PAGE "Gestione attivazioni" 0 2 0 0
|
PAGE "Gestione attivazioni" 0 2 0 0
|
||||||
|
|
||||||
BOOLEAN F_DNINST_ON
|
BOOLEAN F_ZIP_ON
|
||||||
BEGIN
|
BEGIN
|
||||||
PROMPT 1 0 "DNINST (HTTP/FTP)"
|
PROMPT 1 0 "DNINST (HTTP/FTP)"
|
||||||
MESSAGE FALSE DISABLE,F_DNINST
|
MESSAGE FALSE DISABLE,1@
|
||||||
MESSAGE TRUE ENABLE,F_DNINST
|
MESSAGE TRUE ENABLE,1@
|
||||||
END
|
END
|
||||||
|
|
||||||
STRING F_DNINST 256 50
|
STRING F_ZIP_WWW 32 20
|
||||||
BEGIN
|
BEGIN
|
||||||
PROMPT 28 0 ""
|
PROMPT 22 0 ""
|
||||||
CHECKTYPE REQUIRED
|
CHECKTYPE REQUIRED
|
||||||
|
GROUP 1
|
||||||
|
END
|
||||||
|
|
||||||
|
STRING F_ZIP_USR 32 20
|
||||||
|
BEGIN
|
||||||
|
PROMPT 46 0 ""
|
||||||
|
CHECKTYPE REQUIRED
|
||||||
|
GROUP 1
|
||||||
|
END
|
||||||
|
|
||||||
|
STRING F_ZIP_PWD 32 10
|
||||||
|
BEGIN
|
||||||
|
PROMPT 68 0 ""
|
||||||
|
CHECKTYPE REQUIRED
|
||||||
|
GROUP 1
|
||||||
END
|
END
|
||||||
|
|
||||||
BOOLEAN F_DSN_ON
|
BOOLEAN F_DSN_ON
|
||||||
BEGIN
|
BEGIN
|
||||||
PROMPT 1 1 "DSN (ODBC)"
|
PROMPT 1 1 "DSN (ODBC)"
|
||||||
MESSAGE FALSE DISABLE,F_DSN
|
MESSAGE FALSE DISABLE,2@
|
||||||
MESSAGE TRUE ENABLE,F_DSN
|
MESSAGE TRUE ENABLE,2@
|
||||||
END
|
END
|
||||||
|
|
||||||
STRING F_DSN 256 50
|
STRING F_DSN_WWW 256 20
|
||||||
BEGIN
|
BEGIN
|
||||||
PROMPT 28 1 ""
|
PROMPT 22 1 ""
|
||||||
CHECKTYPE REQUIRED
|
CHECKTYPE REQUIRED
|
||||||
FLAGS "B"
|
FLAGS "B"
|
||||||
|
GROUP 2
|
||||||
END
|
END
|
||||||
|
|
||||||
BOOLEAN F_FTP_ON
|
STRING F_DSN_USR 32 20
|
||||||
|
BEGIN
|
||||||
|
PROMPT 46 1 ""
|
||||||
|
GROUP 2
|
||||||
|
END
|
||||||
|
|
||||||
|
STRING F_DSN_PWD 32 10
|
||||||
|
BEGIN
|
||||||
|
PROMPT 68 1 ""
|
||||||
|
GROUP 2
|
||||||
|
END
|
||||||
|
|
||||||
|
BOOLEAN F_XML_ON
|
||||||
BEGIN
|
BEGIN
|
||||||
PROMPT 1 2 "XML (FTP)"
|
PROMPT 1 2 "XML (FTP)"
|
||||||
MESSAGE FALSE DISABLE,F_FTP
|
MESSAGE FALSE DISABLE,3@
|
||||||
MESSAGE TRUE ENABLE,F_FTP
|
MESSAGE TRUE ENABLE,3@
|
||||||
END
|
END
|
||||||
|
|
||||||
STRING F_FTP 256 50
|
STRING F_XML_WWW 50 20
|
||||||
BEGIN
|
BEGIN
|
||||||
PROMPT 28 2 ""
|
PROMPT 22 2 ""
|
||||||
CHECKTYPE REQUIRED
|
CHECKTYPE REQUIRED
|
||||||
|
FLAGS "G"
|
||||||
|
GROUP 3
|
||||||
|
END
|
||||||
|
|
||||||
|
STRING F_XML_USR 32 20
|
||||||
|
BEGIN
|
||||||
|
PROMPT 46 2 ""
|
||||||
|
CHECKTYPE REQUIRED
|
||||||
|
GROUP 3
|
||||||
|
END
|
||||||
|
|
||||||
|
STRING F_XML_PWD 32 10
|
||||||
|
BEGIN
|
||||||
|
PROMPT 68 2 ""
|
||||||
|
CHECKTYPE REQUIRED
|
||||||
|
GROUP 3
|
||||||
END
|
END
|
||||||
|
|
||||||
LIST F_SORT 1 16
|
LIST F_SORT 1 16
|
||||||
@ -73,6 +117,7 @@ BEGIN
|
|||||||
ITEM "0|Chiave"
|
ITEM "0|Chiave"
|
||||||
ITEM "1|Rivenditore"
|
ITEM "1|Rivenditore"
|
||||||
ITEM "2|Cliente"
|
ITEM "2|Cliente"
|
||||||
|
ITEM "3|Accesso"
|
||||||
END
|
END
|
||||||
|
|
||||||
SPREADSHEET F_DNSHEET
|
SPREADSHEET F_DNSHEET
|
||||||
|
@ -75,7 +75,7 @@ public:
|
|||||||
HIDDEN inline TGeneric_table_app& app() { return (TGeneric_table_app&)main_app(); }
|
HIDDEN inline TGeneric_table_app& app() { return (TGeneric_table_app&)main_app(); }
|
||||||
|
|
||||||
TGeneric_table_app::TGeneric_table_app()
|
TGeneric_table_app::TGeneric_table_app()
|
||||||
: _exist_journal(FALSE), _stampa_intest(FALSE)
|
: _exist_journal(false), _stampa_intest(false)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -242,7 +242,7 @@ HIDDEN bool tiporeg_handler(TMask_field& f, KEY k)
|
|||||||
return f.error_box(TR("Non e' possibile avere due registri dichiarazioni d'intenti nello stesso anno"));
|
return f.error_box(TR("Non e' possibile avere due registri dichiarazioni d'intenti nello stesso anno"));
|
||||||
if (k == K_SPACE)
|
if (k == K_SPACE)
|
||||||
f.mask().enable_page(1, tipo != REG_DICHINT);
|
f.mask().enable_page(1, tipo != REG_DICHINT);
|
||||||
return TRUE;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
HIDDEN bool printer_handler(TMask_field& f, KEY k)
|
HIDDEN bool printer_handler(TMask_field& f, KEY k)
|
||||||
@ -272,7 +272,7 @@ HIDDEN bool printer_handler(TMask_field& f, KEY k)
|
|||||||
return f.error_box(TR("Nessun registro selezionato"));
|
return f.error_box(TR("Nessun registro selezionato"));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return TRUE;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
char TGeneric_table_app::frequenza_versamenti(long firm, int year) const
|
char TGeneric_table_app::frequenza_versamenti(long firm, int year) const
|
||||||
@ -304,7 +304,7 @@ HIDDEN bool ditta_handler(TMask_field& f, KEY k)
|
|||||||
TFirm firm(ditta);
|
TFirm firm(ditta);
|
||||||
f.mask().set(F_CODVAL, firm.codice_valuta());
|
f.mask().set(F_CODVAL, firm.codice_valuta());
|
||||||
}
|
}
|
||||||
return TRUE;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
HIDDEN bool coddel_handler(TMask_field& f, KEY k)
|
HIDDEN bool coddel_handler(TMask_field& f, KEY k)
|
||||||
@ -334,7 +334,7 @@ HIDDEN bool coddel_handler(TMask_field& f, KEY k)
|
|||||||
const bool isdel = anag.get_long("TIPOSTDEL") == 0l;
|
const bool isdel = anag.get_long("TIPOSTDEL") == 0l;
|
||||||
|
|
||||||
if (titcf && isdel)
|
if (titcf && isdel)
|
||||||
return TRUE; // Se e' titolare CF e ha scelto la delega vanno abilitati sia
|
return true; // Se e' titolare CF e ha scelto la delega vanno abilitati sia
|
||||||
// Il codice conc. che la banca
|
// Il codice conc. che la banca
|
||||||
if (id == F_CONCESSIONE)
|
if (id == F_CONCESSIONE)
|
||||||
{
|
{
|
||||||
@ -355,7 +355,7 @@ HIDDEN bool coddel_handler(TMask_field& f, KEY k)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return TRUE;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
HIDDEN bool intdel_handler(TMask_field& f, KEY k)
|
HIDDEN bool intdel_handler(TMask_field& f, KEY k)
|
||||||
@ -383,7 +383,7 @@ HIDDEN bool intdel_handler(TMask_field& f, KEY k)
|
|||||||
else if (!imp.is_zero() && imp == intr)
|
else if (!imp.is_zero() && imp == intr)
|
||||||
return f.error_box(TR("Incoerenza importo versato e interessi"));
|
return f.error_box(TR("Incoerenza importo versato e interessi"));
|
||||||
}
|
}
|
||||||
return TRUE;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
HIDDEN bool impdel_handler(TMask_field& f, KEY k)
|
HIDDEN bool impdel_handler(TMask_field& f, KEY k)
|
||||||
@ -424,7 +424,7 @@ HIDDEN bool impdel_handler(TMask_field& f, KEY k)
|
|||||||
return f.yesno_box(FR("Importo inferiore a %s. Registrare ugualmente?"), lim.string("."));
|
return f.yesno_box(FR("Importo inferiore a %s. Registrare ugualmente?"), lim.string("."));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return TRUE;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
HIDDEN bool mese_handler(TMask_field& f, KEY k)
|
HIDDEN bool mese_handler(TMask_field& f, KEY k)
|
||||||
@ -454,7 +454,7 @@ HIDDEN bool mese_handler(TMask_field& f, KEY k)
|
|||||||
attiv.put("CODATT",attprev);
|
attiv.put("CODATT",attprev);
|
||||||
if (attiv.read() != NOERR) attiv.zero();
|
if (attiv.read() != NOERR) attiv.zero();
|
||||||
bool benzinaio = attiv.get_bool("ART74_4");
|
bool benzinaio = attiv.get_bool("ART74_4");
|
||||||
bool gest4 = FALSE;
|
bool gest4 = false;
|
||||||
if (benzinaio)
|
if (benzinaio)
|
||||||
{
|
{
|
||||||
TConfig cnf(CONFIG_DITTA, "cg");
|
TConfig cnf(CONFIG_DITTA, "cg");
|
||||||
@ -479,7 +479,7 @@ HIDDEN bool mese_handler(TMask_field& f, KEY k)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return TRUE;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
HIDDEN bool key_handler(TMask& m, KEY k)
|
HIDDEN bool key_handler(TMask& m, KEY k)
|
||||||
@ -490,7 +490,7 @@ HIDDEN bool key_handler(TMask& m, KEY k)
|
|||||||
if (k == K_SHIFT+K_F12)
|
if (k == K_SHIFT+K_F12)
|
||||||
m.enable(-3);
|
m.enable(-3);
|
||||||
}
|
}
|
||||||
return TRUE;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
bool TGeneric_table_app::valute_decimals_handler(TMask_field& f, KEY k)
|
bool TGeneric_table_app::valute_decimals_handler(TMask_field& f, KEY k)
|
||||||
@ -511,7 +511,7 @@ bool TGeneric_table_app::valute_decimals_handler(TMask_field& f, KEY k)
|
|||||||
|
|
||||||
bool TGeneric_table_app::change_decimals_handler(TMask_field& f, KEY k)
|
bool TGeneric_table_app::change_decimals_handler(TMask_field& f, KEY k)
|
||||||
{
|
{
|
||||||
if (k == K_TAB && f.to_check(k, TRUE))
|
if (k == K_TAB && f.to_check(k, true))
|
||||||
{
|
{
|
||||||
TMask& m = f.mask();
|
TMask& m = f.mask();
|
||||||
const int dec = m.get_int(FLD_TABCAM_I2);
|
const int dec = m.get_int(FLD_TABCAM_I2);
|
||||||
@ -536,7 +536,7 @@ bool TGeneric_table_app::change_decimals_handler(TMask_field& f, KEY k)
|
|||||||
}
|
}
|
||||||
m.set(FLD_TABCAM_R10, cambio);
|
m.set(FLD_TABCAM_R10, cambio);
|
||||||
}
|
}
|
||||||
return TRUE;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
bool TGeneric_table_app::codcab_handler(TMask_field& f, KEY k)
|
bool TGeneric_table_app::codcab_handler(TMask_field& f, KEY k)
|
||||||
@ -549,7 +549,7 @@ bool TGeneric_table_app::codcab_handler(TMask_field& f, KEY k)
|
|||||||
if (rec.empty())
|
if (rec.empty())
|
||||||
return f.error_box(FR("Il codice ABI %s non esiste"), (const char*)abi);
|
return f.error_box(FR("Il codice ABI %s non esiste"), (const char*)abi);
|
||||||
}
|
}
|
||||||
return TRUE;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
bool TGeneric_table_app::codmag_handler(TMask_field& f, KEY k)
|
bool TGeneric_table_app::codmag_handler(TMask_field& f, KEY k)
|
||||||
|
@ -84,7 +84,7 @@ BEGIN
|
|||||||
FIELD CODALT
|
FIELD CODALT
|
||||||
END
|
END
|
||||||
|
|
||||||
GROUPBOX DLG_NULL 76 6
|
GROUPBOX DLG_NULL 76 4
|
||||||
BEGIN
|
BEGIN
|
||||||
PROMPT 1 6 "@bCliente/Fornitore"
|
PROMPT 1 6 "@bCliente/Fornitore"
|
||||||
END
|
END
|
||||||
@ -101,13 +101,14 @@ NUMBER F_CODCF 6
|
|||||||
BEGIN
|
BEGIN
|
||||||
PROMPT 16 7 ""
|
PROMPT 16 7 ""
|
||||||
USE LF_CLIFO
|
USE LF_CLIFO
|
||||||
INPUT TIPOCF F_TIPOCF
|
INPUT TIPOCF F_TIPOCF SELECT
|
||||||
DISPLAY "Codice" CODCF
|
DISPLAY "Codice" CODCF
|
||||||
DISPLAY "Ragione Sociale@50" RAGSOC
|
DISPLAY "Ragione Sociale@50" RAGSOC
|
||||||
DISPLAY "Cod. Alt.@15" RICALT
|
DISPLAY "Cod. Alt.@15" RICALT
|
||||||
DISPLAY "Codice Fiscale@16" COFI
|
DISPLAY "Codice Fiscale@16" COFI
|
||||||
DISPLAY "Partita IVA@15" PAIV
|
DISPLAY "Partita IVA@15" PAIV
|
||||||
OUTPUT F_CODCF CODCF
|
OUTPUT F_CODCF CODCF
|
||||||
|
OUTPUT F_RAGSOC RAGSOC
|
||||||
CHECKTYPE NORMAL
|
CHECKTYPE NORMAL
|
||||||
FIELD CODCF
|
FIELD CODCF
|
||||||
END
|
END
|
||||||
|
@ -28,7 +28,7 @@ NUMBER F_CODICECAB 5
|
|||||||
BEGIN
|
BEGIN
|
||||||
PROMPT 28 1 "Codice CAB "
|
PROMPT 28 1 "Codice CAB "
|
||||||
FIELD CODTAB[6,10]
|
FIELD CODTAB[6,10]
|
||||||
FLAGS "Z"
|
FLAGS "GZ"
|
||||||
KEY 1
|
KEY 1
|
||||||
USE %BAN
|
USE %BAN
|
||||||
INPUT CODTAB[1,5] F_CODICEABI
|
INPUT CODTAB[1,5] F_CODICEABI
|
||||||
|
Loading…
x
Reference in New Issue
Block a user