Patch level : 2.1 048
Files correlati : mg0.exe mg1.exe mg3.exe mg4.exe Ricompilazione Demo : [ ] Commento : Bug 0000134 Implementare la gestione multilingua git-svn-id: svn://10.65.10.50/trunk@12084 c028cbd2-c16b-5b4b-a496-9718f37d4682
This commit is contained in:
parent
746ba52727
commit
3005fcd67a
@ -108,7 +108,7 @@ bool TMask_tabmag::singlemag_handler(TMask_field& f, KEY k)
|
||||
mag.first();
|
||||
if (!mag.eof() && mag.get("CODTAB")!=f.get())
|
||||
{
|
||||
f.error_box("E' abilitata la gestione di un solo magazzino");
|
||||
f.error_box(TR("E' abilitata la gestione di un solo magazzino"));
|
||||
f.set(mag.get("CODTAB"));
|
||||
}
|
||||
}
|
||||
@ -138,7 +138,7 @@ bool TMask_tabmag::sumsign_handler(TMask_field& f, KEY k)
|
||||
f.mask().set(F_SUMSIGN,long(ss));
|
||||
if (ss!=0)
|
||||
{
|
||||
f.error_box("La somma dei segni \n((GIAC-RIM)-(ACQ+ENTR)+(VEN+USC)+(ACL-INCL)+(PRODF-PRODC) + SCARTI) \ndeve essere uguale a zero");
|
||||
f.error_box(TR("La somma dei segni \n((GIAC-RIM)-(ACQ+ENTR)+(VEN+USC)+(ACL-INCL)+(PRODF-PRODC) + SCARTI) \ndeve essere uguale a zero"));
|
||||
return FALSE;
|
||||
}
|
||||
#define ABSSALDO(fld) abs(f.mask().get_int(fld))
|
||||
@ -152,12 +152,12 @@ bool TMask_tabmag::sumsign_handler(TMask_field& f, KEY k)
|
||||
ps+=ABSSALDO(F_SGNORDC)+ABSSALDO(F_SGNORDF);
|
||||
ps+=ABSSALDO(F_SGNLABEL)+ABSSALDO(F_SGNSCAR);
|
||||
if (ps==0)
|
||||
ok = f.yesno_box("Attenzione: la causale non movimenta nessun saldo. Confermi ?");
|
||||
ok = f.yesno_box(TR("Attenzione: la causale non movimenta nessun saldo. Confermi ?"));
|
||||
const char tipomov=*f.mask().get(F_TIPOMOV);
|
||||
if ((f.mask().get_int(F_SGNGIAC) >=0 && tipomov=='S') )
|
||||
ok = f.yesno_box("Attenzione: la causale e' impostata come scarico ma la giacenza non e' movimentata in negativo. Confermi ?");
|
||||
ok = f.yesno_box(TR("Attenzione: la causale e' impostata come scarico ma la giacenza non e' movimentata in negativo. Confermi ?"));
|
||||
if ((f.mask().get_int(F_SGNGIAC) <=0 && tipomov=='C'))
|
||||
ok = f.yesno_box("Attenzione: la causale e' impostata come carico ma la giacenza non e' movimentata in positivo. Confermi ?");
|
||||
ok = f.yesno_box(TR("Attenzione: la causale e' impostata come carico ma la giacenza non e' movimentata in positivo. Confermi ?"));
|
||||
}
|
||||
}
|
||||
return ok;
|
||||
@ -182,7 +182,7 @@ bool TMask_tabmag::format_handler(TMask_field& f, KEY k)
|
||||
// non è l'ultimo livello: solo caratteri obbligatori
|
||||
if (mask.metach->has_opzchars(s))
|
||||
{
|
||||
f.error_box("I caratteri di formato opzionali ('%s') sono consentiti solo per l'ultimo livello",
|
||||
f.error_box(FR("I caratteri di formato opzionali ('%s') sono consentiti solo per l'ultimo livello"),
|
||||
mask.metach->opz_chars());
|
||||
return FALSE;
|
||||
}
|
||||
@ -218,7 +218,7 @@ bool TMask_tabmag::formatgiac_handler(TMask_field& f, KEY k)
|
||||
total_len+=mask.get_int(F_LENFORM);
|
||||
if (total_len > maxlen)
|
||||
{
|
||||
f.error_box("La somma delle lunghezze dei codici \n dei livelli di giacenza eccede \nil massimo consentito di %d caratteri",maxlen);
|
||||
f.error_box(FR("La somma delle lunghezze dei codici \n dei livelli di giacenza eccede \nil massimo consentito di %d caratteri"),maxlen);
|
||||
return FALSE;
|
||||
}
|
||||
}
|
||||
@ -248,11 +248,11 @@ bool TMask_tabmag::codlivart_handler(TMask_field& f, KEY k)
|
||||
aux_tabf->put("CODTAB",codliv+1);
|
||||
if (aux_tabf->read()!=NOERR && mask.metach->has_opzchars(prevformat))
|
||||
{
|
||||
f.error_box("Il livello precedente include caratteri opzionali nel formato\ne non puo' divenire un livello intermedio");
|
||||
f.error_box(TR("Il livello precedente include caratteri opzionali nel formato\ne non puo' divenire un livello intermedio"));
|
||||
return FALSE;
|
||||
}
|
||||
} else {
|
||||
f.error_box("Non si possono inserire salti nel livello del codice");
|
||||
f.error_box(TR("Non si possono inserire salti nel livello del codice"));
|
||||
return FALSE;
|
||||
}
|
||||
}
|
||||
@ -278,7 +278,7 @@ bool TMask_tabmag::codlivgiac_handler(TMask_field& f, KEY k)
|
||||
if (aux_tabf->read()!=NOERR)
|
||||
// non esiste un precedente
|
||||
{
|
||||
f.error_box("Non si possono inserire salti nel livello del codice");
|
||||
f.error_box(TR("Non si possono inserire salti nel livello del codice"));
|
||||
return FALSE;
|
||||
}
|
||||
}
|
||||
@ -296,7 +296,7 @@ bool TMask_tabmag::numlivart_handler(TMask_field& f, KEY k)
|
||||
if (mask.get_int(F_CODLIV)==mask.cod_liv->last_level())
|
||||
// non esiste un seguente
|
||||
{
|
||||
f.error_box("Non è possibile definire gruppi per l'ultimo livello di codice articolo");
|
||||
f.error_box(TR("Non è possibile definire gruppi per l'ultimo livello di codice articolo"));
|
||||
return FALSE;
|
||||
}
|
||||
}
|
||||
@ -314,13 +314,13 @@ bool TMask_tabmag::codgrp_handler(TMask_field& f, KEY k)
|
||||
|
||||
if (!mask.cod_liv->enabled())
|
||||
{
|
||||
f.error_box("Livelli del codice non abilitati");
|
||||
f.error_box(TR("Livelli del codice non abilitati"));
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
if (!f.empty() && !(mask.cod_liv->fit_to_format(f.get(),mask.get_int(F_CODLIV))))
|
||||
{
|
||||
f.error_box("Codice non corrispondente al formato previsto");
|
||||
f.error_box(TR("Codice non corrispondente al formato previsto"));
|
||||
return FALSE;
|
||||
}
|
||||
}
|
||||
@ -423,7 +423,7 @@ int Tab_app_mag::rewrite(const TMask& m)
|
||||
int mg0100(int argc, char* argv[])
|
||||
{
|
||||
Tab_app_mag a;
|
||||
a.run(argc, argv, "Tabella");
|
||||
a.run(argc, argv, TR("Tabella"));
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
@ -110,6 +110,6 @@ void TStampa_tabmag::main_loop()
|
||||
int mg0200(int argc, char* argv[])
|
||||
{
|
||||
TStampa_tabmag a;// derivata da Application e con uso di form
|
||||
a.run(argc,argv,"Stampa tabelle di magazzino");
|
||||
a.run(argc,argv,TR("Stampa tabelle di magazzino"));
|
||||
return 0;
|
||||
}
|
||||
|
@ -2,8 +2,6 @@
|
||||
|
||||
#include "mgconf.h"
|
||||
|
||||
#define SINTASSI "Usage: mg0 -2 -[1|2|3|4|5|6]"
|
||||
|
||||
class TConf_magazz : public TConfig_application
|
||||
{
|
||||
char _current;
|
||||
@ -42,7 +40,7 @@ bool TConf_magazz::user_create( )
|
||||
{
|
||||
TString16 arg( argv(2) );
|
||||
if( arg[ 0 ] != '-' )
|
||||
fatal_box( SINTASSI );
|
||||
fatal_box( TR( "Usage: mg0 -2 -[1|2|3|4|5|6]") );
|
||||
_current = arg[1];
|
||||
|
||||
TConfig conf(_current == '6' ? CONFIG_STUDIO : CONFIG_DITTA );
|
||||
@ -56,7 +54,7 @@ bool TConf_magazz::user_create( )
|
||||
conf.set( "EdMask", "mg0300b", "mg" );
|
||||
break;
|
||||
default:
|
||||
fatal_box( SINTASSI );
|
||||
fatal_box( TR("Usage: mg0 -2 -[1|2|3|4|5|6]") );
|
||||
return FALSE;
|
||||
break;
|
||||
}
|
||||
@ -71,6 +69,6 @@ bool TConf_magazz::user_destroy( )
|
||||
int mg0300(int argc, char* argv[])
|
||||
{
|
||||
TConf_magazz appc;
|
||||
appc.run(argc, argv, "Parametri gestione magazzino");
|
||||
appc.run(argc, argv, TR("Parametri gestione magazzino"));
|
||||
return 0;
|
||||
}
|
||||
|
@ -62,7 +62,7 @@ bool TMask_movmag::codgrp_handler(TMask_field& f, KEY k)
|
||||
{
|
||||
if (!livelli_giacenza().enabled())
|
||||
{
|
||||
f.error_box("Livelli del codice non abilitati");
|
||||
f.error_box(TR("Livelli del codice non abilitati"));
|
||||
return FALSE;
|
||||
}
|
||||
const int levnum=1+f.dlg()-F_LIV1;
|
||||
@ -170,7 +170,7 @@ bool TMask_movmag::handle_righe(TMask_field &f, KEY k)
|
||||
{
|
||||
if (*ss.cell(i,codmag) <= ' ')
|
||||
{
|
||||
f.error_box("Nella riga %d manca l'indicazione del magazzino ",i+1);
|
||||
f.error_box(FR("Nella riga %d manca l'indicazione del magazzino "),i+1);
|
||||
return FALSE;
|
||||
}
|
||||
}
|
||||
@ -261,14 +261,14 @@ bool TMask_movmag::qta_inventory(real & qta)
|
||||
if (codcau.blank())
|
||||
codcau = get(F_CODCAUS);
|
||||
if (codcau.blank())
|
||||
return error_box("La causale non e' indicata");
|
||||
return error_box(TR("La causale non e' indicata"));
|
||||
|
||||
TCausale_magazzino cau = cache().get("%CAU",codcau);
|
||||
switch (cau.sgn(s_giac))
|
||||
{
|
||||
case 1: break;
|
||||
case -1: qta = - qta; break;
|
||||
default: message_box("La causale indicata non movimenta la giacenza");
|
||||
default: message_box(TR("La causale indicata non movimenta la giacenza"));
|
||||
}
|
||||
}
|
||||
return TRUE;
|
||||
@ -328,7 +328,8 @@ bool TMask_movmag::handle_checksosp(TMask_field &f, KEY k)
|
||||
const TCausale_magazzino c(caus);
|
||||
|
||||
if (!c.movimenta_sospesi() && mov_mask.curr_art().get_bool("SOSPESO"))
|
||||
return error_box("Articolo %s sospeso, quindi non movimentabile", (const char *)f.get());
|
||||
return error_box(FR("Articolo %s sospeso, quindi non movimentabile"), (const char *)f.get());
|
||||
|
||||
}
|
||||
return TRUE;
|
||||
}
|
||||
@ -602,11 +603,11 @@ bool TMask_movmag::add_explrows(int r)
|
||||
if (boom.items() > 0)
|
||||
{
|
||||
if (boom.items() == 1 && codart == ((TRiga_esplosione &)boom[0]).articolo())
|
||||
error_box("Distinta %s ciclica", (const char *)codart);
|
||||
error_box(TR("Distinta %s ciclica"), (const char *)codart);
|
||||
sheet.destroy(r);
|
||||
}
|
||||
else
|
||||
message_box("Impossibile esplodere l'articolo %s", (const char *)codart);
|
||||
message_box(FR("Impossibile esplodere l'articolo %s"), (const char *)codart);
|
||||
|
||||
|
||||
}
|
||||
@ -684,7 +685,7 @@ bool TMask_movmag::handle_datacomp(TMask_field &fld, KEY k)
|
||||
fld.mask().field(H_ANNOES).set(codes);
|
||||
}
|
||||
else
|
||||
return fld.error_box("La data indicata non appartiene a nessuno degli esercizi contabili inseriti ") ;
|
||||
return fld.error_box(TR("La data indicata non appartiene a nessuno degli esercizi contabili inseriti ")) ;
|
||||
}
|
||||
return TRUE;
|
||||
}
|
||||
@ -778,10 +779,9 @@ const char *TApp_movmag::get_next_key()
|
||||
int mg1100(int argc, char* argv[])
|
||||
{
|
||||
TApp_movmag a;
|
||||
a.run(argc, argv, "Movimenti di magazzino");
|
||||
a.run(argc, argv, TR("Movimenti di magazzino"));
|
||||
exit(0);
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
@ -37,7 +37,7 @@ bool TMask_buildmov::handle_annoes(TMask_field &fld, KEY k)
|
||||
const TEsercizio & e=mask.esercizi.esercizio(mask.get_int(F_ANNOES));
|
||||
if (e.chiusura_mag()!=TDate(NULLDATE))
|
||||
{
|
||||
fld.error_box("Il magazzino dell'esercizio indicato risulta chiuso \nImpossibile effettuare la ricostruzione saldi") ;
|
||||
fld.error_box(TR("Il magazzino dell'esercizio indicato risulta chiuso \nImpossibile effettuare la ricostruzione saldi")) ;
|
||||
return FALSE;
|
||||
}
|
||||
}
|
||||
@ -79,7 +79,8 @@ void TApp_rebuildbalances::main_loop()
|
||||
while (m.run()==K_ENTER)
|
||||
{
|
||||
if (!rebuild_balances(m.get(F_ANNOES)))
|
||||
warning_box(TR("A causa degli errori riscontrati i saldi di magazzino \npotrebbero non essere stati del tutto aggiornati. \nProcedere ad una nuova operazione di 'Ricostruzione saldi'"));
|
||||
warning_box(TR("A causa degli errori riscontrati i saldi di magazzino \npotrebbero non essere stati del tutto aggiornati. \nProcedere ad una nuova operazione di ''Ricostruzione saldi''"));
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@ -89,4 +90,4 @@ int mg1200(int argc, char* argv[])
|
||||
|
||||
a.run(argc, argv, TR("Ricostruzione saldi"));
|
||||
return 0;
|
||||
}
|
||||
}
|
@ -71,16 +71,16 @@ bool TMask_openclose::handle_close(TMask_field &fld, KEY k)
|
||||
const int es_close = ex.date2esc(d);
|
||||
mask.set(F_ESTOCLOSE, es_close);
|
||||
if (es_close == 0)
|
||||
return fld.error_box("La data indicata non appartiene a nessun esercizio.");
|
||||
return fld.error_box(TR("La data indicata non appartiene a nessun esercizio."));
|
||||
|
||||
if (k == K_ENTER && ex.esercizio(es_close).chiusura_mag() != TDate(NULLDATE))
|
||||
return fld.error_box("L'esercizio %d risulta gia' chiuso. Selezionare"
|
||||
" un altro esercizio o togliere la data di chiusura.", es_close);
|
||||
return fld.error_box(FR("L'esercizio %d risulta gia' chiuso. Selezionare"
|
||||
" un altro esercizio o togliere la data di chiusura."), es_close);
|
||||
else
|
||||
{
|
||||
int pred = ex.pred(es_close);
|
||||
if (k == K_ENTER && pred != 0 && ex.esercizio(pred).chiusura_mag() == TDate(NULLDATE))
|
||||
return fld.error_box("L'esercizio precedente a quello indicato non e' ancora stato chiuso.");
|
||||
return fld.error_box(TR("L'esercizio precedente a quello indicato non e' ancora stato chiuso."));
|
||||
}
|
||||
}
|
||||
return TRUE;
|
||||
@ -94,16 +94,16 @@ bool TMask_openclose::handle_open(TMask_field &fld, KEY k)
|
||||
TDate in(mask.get(F_DATEOPEN));
|
||||
TDate fi(mask.get(F_DATECLOSE));
|
||||
if (k == K_ENTER && in <= fi )
|
||||
return fld.warning_box ("La data di apertura del nuovo esercizio deve essere superiore alla data di chiusura dell'esercizio precedente");
|
||||
return fld.warning_box (TR("La data di apertura del nuovo esercizio deve essere superiore alla data di chiusura dell'esercizio precedente"));
|
||||
const int es_open = mask.exercise().date2esc(in);
|
||||
|
||||
mask.set(F_ESTOOPEN, es_open);
|
||||
if (es_open == 0)
|
||||
return fld.error_box("La data indicata non appartiene a nessun esercizio");
|
||||
return fld.error_box(TR("La data indicata non appartiene a nessun esercizio"));
|
||||
|
||||
const int es_close = mask.exercise().pred(es_open);
|
||||
if (es_close == 0)
|
||||
return fld.error_box("Non esiste l'esercizio precedente per la data indicata.");
|
||||
return fld.error_box(TR("Non esiste l'esercizio precedente per la data indicata."));
|
||||
|
||||
// Setta data ed esercizio di chiusura
|
||||
mask.set(F_ESTOCLOSE,es_close);
|
||||
@ -176,12 +176,6 @@ bool TMask_openclose::handle_val(TMask_field &fld, KEY k)
|
||||
|
||||
class TApp_openclose : public TSkeleton_application
|
||||
{
|
||||
TLocalisamfile *_anamag,
|
||||
*_umart,
|
||||
*_mag,
|
||||
*_movmag,
|
||||
*_rmovmag,
|
||||
*_stomag;
|
||||
TMask_openclose *_msk;
|
||||
TArray _movimenti; // Array di movimenti di TMov_mag
|
||||
TString_array _causali; // Array delle causali per i movimenti d'apertura (7)
|
||||
@ -213,13 +207,8 @@ public:
|
||||
bool TApp_openclose::create()
|
||||
{
|
||||
TConfig c(CONFIG_DITTA);
|
||||
open_files(LF_ANAMAG, LF_UMART, LF_MAG, LF_MOVMAG, LF_RMOVMAG, LF_STOMAG, 0);
|
||||
_msk = new TMask_openclose(!c.get_bool("RIPORD"));
|
||||
_anamag = new TLocalisamfile(LF_ANAMAG);
|
||||
_umart = new TLocalisamfile(LF_UMART);
|
||||
_mag = new TLocalisamfile(LF_MAG);
|
||||
_movmag = new TLocalisamfile(LF_MOVMAG);
|
||||
_rmovmag = new TLocalisamfile(LF_RMOVMAG);
|
||||
_stomag = new TLocalisamfile(LF_STOMAG);
|
||||
return TSkeleton_application::create();
|
||||
}
|
||||
|
||||
@ -227,12 +216,6 @@ bool TApp_openclose::create()
|
||||
bool TApp_openclose::destroy()
|
||||
{
|
||||
delete _msk;
|
||||
delete _anamag;
|
||||
delete _umart;
|
||||
delete _mag;
|
||||
delete _movmag;
|
||||
delete _rmovmag;
|
||||
delete _stomag;
|
||||
return TSkeleton_application::destroy();
|
||||
}
|
||||
|
||||
@ -383,13 +366,15 @@ void TApp_openclose::chiudi_esercizio()
|
||||
TTable magazzini("MAG");
|
||||
|
||||
// rebuild_balances(_es_to_close); // Cosi' ci assicuriamo che i saldi dell'esercizio vecchio siano a posto
|
||||
descr1.format(_what == definitiva ? "Apertura esercizio %s" : "Aggiornamento saldi esercizio %s", (const char*) _es_to_open);
|
||||
descr2 << descr1 << " in corso...";
|
||||
descr1.format(_what == definitiva ? FR("Apertura esercizio %s") : FR("Aggiornamento saldi esercizio %s"), (const char*) _es_to_open);
|
||||
descr2 << descr1 << TR(" in corso...");
|
||||
|
||||
// cose specifiche per chiusura definitiva...
|
||||
// Reperisce l'ultimo movimento di magazzino per il numero di registrazione
|
||||
_movmag->last();
|
||||
long numreg = _movmag->get_long(MOVMAG_NUMREG) +1;
|
||||
TLocalisamfile movmag(LF_MOVMAG);
|
||||
|
||||
movmag.last();
|
||||
long numreg = movmag.get_long(MOVMAG_NUMREG) +1;
|
||||
// Indici per i movimenti. Crea i movimenti di base (uno per ogni causale)
|
||||
int indici[9], last = 8;
|
||||
if (_what == definitiva)
|
||||
@ -508,7 +493,7 @@ void TApp_openclose::chiudi_esercizio()
|
||||
// **************
|
||||
// Effettua la scrittura dei movimenti di apertura generati
|
||||
const int max_mov = _movimenti.items();
|
||||
prog = new TProgind(max_mov, "Scrittura movimenti di apertura in corso...",FALSE,TRUE);
|
||||
prog = new TProgind(max_mov, TR("Scrittura movimenti di apertura in corso..."),FALSE,TRUE);
|
||||
for (int i=0; err == NOERR && i<max_mov;i++)
|
||||
{
|
||||
prog->addstatus(1L);
|
||||
@ -516,7 +501,7 @@ void TApp_openclose::chiudi_esercizio()
|
||||
if (mov.rows() == 0)
|
||||
continue; // Salta eventuali movimenti senza righe (OrdC e OrdF)
|
||||
// Effettua la rinumerazione del movimento se esso esiste gia'?
|
||||
err = mov.write(*_movmag);
|
||||
err = mov.write(movmag);
|
||||
}
|
||||
delete prog;
|
||||
|
||||
@ -532,13 +517,13 @@ void TApp_openclose::chiudi_esercizio()
|
||||
esc.put("D4", _date_to_close);
|
||||
err = esc.rewrite();
|
||||
if (err != NOERR)
|
||||
error_box("Errore %d in fase di chiusura esercizio %s.", err, (const char*) _es_to_close);
|
||||
error_box(FR("Errore %d in fase di chiusura esercizio %s."), err, (const char*) _es_to_close);
|
||||
}
|
||||
else
|
||||
error_box("Error %d in fase di lettura esercizio %s.", err, (const char*) _es_to_close);
|
||||
error_box(FR("Errore %d in fase di lettura esercizio %s."), err, (const char*) _es_to_close);
|
||||
}
|
||||
else
|
||||
error_box("Errore %d durante la scrittura dei movimenti.",err);
|
||||
error_box(FR("Errore %d durante la scrittura dei movimenti."),err);
|
||||
_movimenti.destroy();
|
||||
}
|
||||
|
||||
@ -592,6 +577,6 @@ int mg1400(int argc, char* argv[])
|
||||
{
|
||||
TApp_openclose a;
|
||||
|
||||
a.run(argc, argv, "Apertura/Chiusura esercizio");
|
||||
a.run(argc, argv, TR("Apertura/Chiusura esercizio"));
|
||||
return 0;
|
||||
}
|
||||
|
@ -4,7 +4,6 @@
|
||||
// Modulo di Gestione ???
|
||||
#include "mg0.h"
|
||||
|
||||
#define usage "Error - usage : %s -{0|1|2|3|4|5|6|7|8|9}"
|
||||
|
||||
int main(int argc, char** argv)
|
||||
{
|
||||
@ -15,7 +14,7 @@ int main(int argc, char** argv)
|
||||
{
|
||||
case 0: // gestione
|
||||
default:
|
||||
error_box(usage, argv[0]) ; break;
|
||||
error_box(FR("Error - usage : %s -{0|1|2|3|4|5|6|7|8|9}"), argv[0]) ; break;
|
||||
}
|
||||
|
||||
return rt ;
|
||||
|
@ -155,14 +155,6 @@ bool TStampadatist_mask::handle_subord(TMask_field &fld, KEY k)
|
||||
fraggcod.do_message(0);
|
||||
fragggiac.reset(); fragggiac.disable();
|
||||
fragggiac.do_message(0);
|
||||
//m.field(F_FROMLIVELLOART).set(m.artlev().last_level());
|
||||
//m.disable(F_FROMLIVELLOART);
|
||||
//m.field(F_TOLIVELLOART).set("0");
|
||||
//m.disable(F_TOLIVELLOART);
|
||||
//m.field(F_FROMLIVELLOGIAC).set("0");
|
||||
//m.disable(F_FROMLIVELLOGIAC);
|
||||
//m.field(F_TOLIVELLOGIAC).set("0");
|
||||
//m.disable(F_TOLIVELLOGIAC);
|
||||
break;
|
||||
}
|
||||
}
|
||||
@ -287,23 +279,23 @@ void TStampa_datistorici::setprint_permagazzini()
|
||||
cfilter << "(CODART[1," << _mask->get(F_AART).len() << "]<=" <<'"' << _mask->get(F_AART)<< "\")&&" ;
|
||||
srangea << "fino a " << _mask->get(F_AART) << "\" ";
|
||||
}
|
||||
rangea.set(srangea.empty() ? "Tutti gli articoli" : format("Articoli %s", (const char *)srangea));
|
||||
rangea.set(srangea.empty() ? TR("Tutti gli articoli") : format(FR("Articoli %s"), (const char *)srangea));
|
||||
switch (*_mask->get(F_FILTRO)) {
|
||||
case '0': // non nulli
|
||||
cfilter << "(STR(" << LF_MAG << "->GIAC!=\"0\"))&&";
|
||||
it_filtro.set("non nulle");
|
||||
it_filtro.set(TR("non nulle"));
|
||||
break;
|
||||
case 'P': // positivi
|
||||
cfilter << "(STR(" << LF_MAG << "->GIAC>\"0\"))&&";
|
||||
it_filtro.set("positive");
|
||||
it_filtro.set(TR("positive"));
|
||||
break;
|
||||
case 'N': // negativi
|
||||
cfilter << "(STR(" << LF_MAG << "->GIAC<\"0\"))&&";
|
||||
it_filtro.set("negative");
|
||||
it_filtro.set(TR("negative"));
|
||||
break;
|
||||
case 'S': // sottoscorta
|
||||
cfilter << "(STR(GIAC<SCORTAMIN))&&";
|
||||
it_filtro.set("sottoscorta");
|
||||
it_filtro.set(TR("sottoscorta"));
|
||||
break;
|
||||
}
|
||||
if (cfilter.not_empty())
|
||||
@ -354,7 +346,7 @@ void TStampa_datistorici::setprint_permagazzini()
|
||||
arec.put("CODMAG",_mask->get(F_AMAG));
|
||||
srangem << "fino a \"" << _mask->get(F_AMAG) << "\" ";
|
||||
}
|
||||
rangem.set(srangem.empty() ? "Tutti i magazzini" : format("Magazzini %s", (const char *)srangem));
|
||||
rangem.set(srangem.empty() ? TR("Tutti i magazzini") : format(FR("Magazzini %s"), (const char *)srangem));
|
||||
darec.put("ANNOES",_mask->get(F_ANNOES));
|
||||
arec.put("ANNOES",_mask->get(F_ANNOES));
|
||||
_cur->setfilter(cfilter);
|
||||
@ -379,7 +371,7 @@ void TStampa_datistorici::setprint_perarticoli()
|
||||
if (*_mask->get(F_AMAG))
|
||||
srangem << "fino a \"" << _mask->get(F_AMAG) << "\"";
|
||||
|
||||
rangem.set(srangem.blank()? "Tutti i magazzini" : format("Magazzini %s",(const char *)srangem));
|
||||
rangem.set(srangem.blank()? TR("Tutti i magazzini") : format(FR("Magazzini %s"),(const char *)srangem));
|
||||
|
||||
// ********************
|
||||
// filtro giacenze
|
||||
@ -387,19 +379,19 @@ void TStampa_datistorici::setprint_perarticoli()
|
||||
switch (filtro_articoli) {
|
||||
case '0': // non nulli
|
||||
filter << "(STR(" << LF_MAG << "->GIAC!=\"0\"))&&";
|
||||
it_filtro.set("non nulle");
|
||||
it_filtro.set(TR("non nulle"));
|
||||
break;
|
||||
case 'P': // positivi
|
||||
filter << "(STR(" << LF_MAG << "->GIAC>\"0\"))&&";
|
||||
it_filtro.set("positive");
|
||||
it_filtro.set(TR("positive"));
|
||||
break;
|
||||
case 'N': // negativi
|
||||
filter << "(STR(" << LF_MAG << "->GIAC<\"0\"))&&";
|
||||
it_filtro.set("negative");
|
||||
it_filtro.set(TR("negative"));
|
||||
break;
|
||||
case 'S': // sottoscorta
|
||||
filter << "(STR("<< LF_MAG << "->GIAC < " <<LF_MAG << "->SCORTAMIN))&&";
|
||||
it_filtro.set("sottoscorta");
|
||||
it_filtro.set(TR("sottoscorta"));
|
||||
break;
|
||||
}
|
||||
if (_mask->get(F_DAART).not_empty())
|
||||
@ -419,7 +411,7 @@ void TStampa_datistorici::setprint_perarticoli()
|
||||
srangea << "da \"" << _mask->get(F_DAART) << "\" ";
|
||||
if (!_mask->get(F_AART).blank())
|
||||
srangea << "fino a \"" << _mask->get(F_AART) << "\"";
|
||||
rangea.set(srangea.empty() ? "Tutti gli articoli" : format("Articoli %s", (const char *)srangea));
|
||||
rangea.set(srangea.empty() ? TR("Tutti gli articoli") : format(FR("Articoli %s"), (const char *)srangea));
|
||||
switch (subordine)
|
||||
{
|
||||
case 'C':
|
||||
@ -447,7 +439,7 @@ void TStampa_datistorici::setprint_perarticoli()
|
||||
srangecm << "fino a \"" << _mask->get(F_ASCATMER) << "\"";
|
||||
filter << "&&(" << espr << "<=\"" << _mask->get(F_ASCATMER) << "\")";
|
||||
}
|
||||
rangecm.set(srangecm.empty() ? "Tutte le categorie merceologiche" : format("Categorie merc. %s", (const char *)srangecm));
|
||||
rangecm.set(srangecm.empty() ? TR("Tutte le categorie merceologiche") : format(FR("Categorie merc. %s"), (const char *)srangecm));
|
||||
break;
|
||||
}
|
||||
|
||||
@ -531,26 +523,26 @@ void TStampa_datistorici::setprint_perarticoli_all()
|
||||
filter << "(" << LF_MAG <<"->CODMAG[1,3]<=" <<'"' << _mask->get(F_AMAG)<< "\")&&" ;
|
||||
srangem << "fino a \"" << _mask->get(F_AMAG) << "\"";
|
||||
}
|
||||
rangem.set(srangem.blank()? "Tutti i magazzini" : format("Magazzini %s",(const char *)srangem));
|
||||
rangem.set(srangem.blank()? TR("Tutti i magazzini") : format(FR("Magazzini %s"),(const char *)srangem));
|
||||
// ********************
|
||||
// filtro giacenze
|
||||
TForm_item & it_filtro=_form->find_field('H',odd_page,FF_FILTRO);
|
||||
switch (filtro_articoli) {
|
||||
case '0': // non nulli
|
||||
filter << "(STR(" << LF_MAG << "->GIAC!=\"0\"))&&";
|
||||
it_filtro.set("non nulle");
|
||||
it_filtro.set(TR("non nulle"));
|
||||
break;
|
||||
case 'P': // positivi
|
||||
filter << "(STR(" << LF_MAG << "->GIAC>\"0\"))&&";
|
||||
it_filtro.set("positive");
|
||||
it_filtro.set(TR("positive"));
|
||||
break;
|
||||
case 'N': // negativi
|
||||
filter << "(STR(" << LF_MAG << "->GIAC<\"0\"))&&";
|
||||
it_filtro.set("negative");
|
||||
it_filtro.set(TR("negative"));
|
||||
break;
|
||||
case 'S': // sottoscorta
|
||||
filter << "(STR("<< LF_MAG << "->GIAC < " <<LF_MAG << "->SCORTAMIN))&&";
|
||||
it_filtro.set("sottoscorta");
|
||||
it_filtro.set(TR("sottoscorta"));
|
||||
break;
|
||||
}
|
||||
if (filter.not_empty())
|
||||
@ -571,9 +563,9 @@ void TStampa_datistorici::setprint_perarticoli_all()
|
||||
_form->find_field('B',odd_page,"TOT_CATMER").hide();
|
||||
_form->set_ordering(mg_normale);
|
||||
if (!_mask->get(F_DAART).blank())
|
||||
srangea << "da \"" << _mask->get(F_DAART) << "\" ";
|
||||
srangea << TR("da \"") << _mask->get(F_DAART) << "\" ";
|
||||
if (!_mask->get(F_AART).blank())
|
||||
srangea << "fino a \"" << _mask->get(F_AART) << "\"";
|
||||
srangea << TR("fino a \"") << _mask->get(F_AART) << "\"";
|
||||
break;
|
||||
case 'D':
|
||||
_cur->setkey(2);
|
||||
@ -583,9 +575,9 @@ void TStampa_datistorici::setprint_perarticoli_all()
|
||||
_form->find_field('B',odd_page,"TOT_CATMER").hide();
|
||||
_form->set_ordering(mg_normale);
|
||||
if (!_mask->get(F_DADES).blank())
|
||||
srangea << "da \"" << _mask->get(F_DADES) << "\" ";
|
||||
srangea << TR("da \"") << _mask->get(F_DADES) << "\" ";
|
||||
if (!_mask->get(F_ADES).blank())
|
||||
srangea << "fino a \"" << _mask->get(F_ADES) << "\"";
|
||||
srangea << TR("fino a \"") << _mask->get(F_ADES) << "\"";
|
||||
break;
|
||||
case 'M':
|
||||
case 'S':
|
||||
@ -598,22 +590,22 @@ void TStampa_datistorici::setprint_perarticoli_all()
|
||||
|
||||
if (!_mask->get(F_DAART).blank())
|
||||
{
|
||||
srangea << "da \"" << _mask->get(F_DAART) << "\" ";
|
||||
srangea << TR("da \"") << _mask->get(F_DAART) << "\" ";
|
||||
cfilter << "(CODART[1," << _mask->get(F_DAART).len() << "]>=" <<'"' << _mask->get(F_AART)<< "\")&&" ;
|
||||
}
|
||||
if (!_mask->get(F_AART).blank())
|
||||
{
|
||||
srangea << "fino a \"" << _mask->get(F_AART) << "\"";
|
||||
srangea << TR("fino a \"") << _mask->get(F_AART) << "\"";
|
||||
cfilter << "(CODART[1," << _mask->get(F_AART).len() << "]<=" <<'"' << _mask->get(F_AART)<< "\")&&" ;
|
||||
}
|
||||
if (!_mask->get(F_DACATMER).blank())
|
||||
srangecm << "da \"" << _mask->get(F_DACATMER) << "\" ";
|
||||
srangecm << TR("da \"") << _mask->get(F_DACATMER) << "\" ";
|
||||
if (!_mask->get(F_ACATMER).blank())
|
||||
srangecm << "fino a \"" << _mask->get(F_ACATMER) << "\"";
|
||||
rangecm.set(srangecm.empty() ? "Tutte le categorie merceologiche" : format("Categorie merc. %s", (const char *)srangecm));
|
||||
srangecm << TR("fino a \"") << _mask->get(F_ACATMER) << "\"";
|
||||
rangecm.set(srangecm.empty() ? TR("Tutte le categorie merceologiche") : format(FR("Categorie merc. %s"), (const char *)srangecm));
|
||||
break;
|
||||
}
|
||||
rangea.set(srangea.empty() ? "Tutti gli articoli" : format("Articoli %s", (const char *)srangea));
|
||||
rangea.set(srangea.empty() ? TR("Tutti gli articoli") : format(FR("Articoli %s"), (const char *)srangea));
|
||||
|
||||
_form->setdett_perart(
|
||||
_mask->get_bool(F_RAGGCODICE),
|
||||
@ -691,6 +683,6 @@ void TStampa_datistorici::main_loop()
|
||||
int mg3100(int argc, char* argv[])
|
||||
{
|
||||
TStampa_datistorici a;// derivata da Application e con uso di form
|
||||
a.run(argc,argv,"Stampa dati storici di giacenza");
|
||||
a.run(argc,argv,TR("Stampa dati storici di giacenza"));
|
||||
return 0;
|
||||
}
|
||||
|
@ -129,7 +129,6 @@ bool TStampadisp_mask::handle_ragg(TMask_field &fld, KEY k)
|
||||
// mg3200 Stampa
|
||||
class TStampa_disp : public TSkeleton_application
|
||||
{
|
||||
TArray * _files;
|
||||
TStampadisp_mask * _mask;
|
||||
TCursor * _cur;
|
||||
TForm_stampemg * _form; // to be moved into TPrint_application
|
||||
@ -152,15 +151,13 @@ public:
|
||||
bool TStampa_disp::create()
|
||||
{
|
||||
_mask = new TStampadisp_mask;
|
||||
_files = new TArray();
|
||||
_files->add(new TLocalisamfile(LF_MAG));
|
||||
open_files(LF_ANAMAG, LF_MAG, LF_CODCORR, LF_DESLIN, 0);
|
||||
return TSkeleton_application::create();
|
||||
}
|
||||
|
||||
bool TStampa_disp::destroy()
|
||||
{
|
||||
delete _mask;
|
||||
delete _files;
|
||||
return TSkeleton_application::destroy();
|
||||
}
|
||||
|
||||
@ -186,17 +183,17 @@ void TStampa_disp::setprint_permagazzini()
|
||||
if (*_mask->get(F_DAART))
|
||||
{
|
||||
cfilter << "(CODART[1," << _mask->get(F_DAART).len() << "]>=" <<'"' << _mask->get(F_DAART)<< "\")&&" ;
|
||||
srangea << "da \"" << _mask->get(F_DAART) << "\" ";
|
||||
srangea << TR("da \"") << _mask->get(F_DAART) << "\" ";
|
||||
}
|
||||
if (*_mask->get(F_AART))
|
||||
{
|
||||
cfilter << "(CODART[1," << _mask->get(F_AART).len() << "]<=" <<'"' << _mask->get(F_AART)<< "\")&&" ;
|
||||
srangea << "fino a \"" << _mask->get(F_AART) << "\"";
|
||||
srangea << TR("fino a \"") << _mask->get(F_AART) << "\"";
|
||||
}
|
||||
if (cfilter.not_empty())
|
||||
cfilter.cut(cfilter.len()-2);
|
||||
|
||||
rangea.set(srangea.empty() ? "Tutti gli articoli" : format("Articoli %s",(const char *)srangea));
|
||||
rangea.set(srangea.empty() ? TR("Tutti gli articoli") : format(FR("Articoli %s"),(const char *)srangea));
|
||||
// ***************
|
||||
// gestione dei livelli di raggruppamento e di detaglio
|
||||
// (abilita/disabilita le sezioni dei totali/header)
|
||||
@ -227,10 +224,10 @@ void TStampa_disp::setprint_permagazzini()
|
||||
darec.put("CODMAG",_mask->get(F_DAMAG));
|
||||
arec.put("CODMAG",_mask->get(F_AMAG));
|
||||
if (*_mask->get(F_DAMAG))
|
||||
srangem << "da \"" << _mask->get(F_DAMAG) << "\" ";
|
||||
srangem << TR("da \"") << _mask->get(F_DAMAG) << "\" ";
|
||||
if (*_mask->get(F_AMAG))
|
||||
srangem << "fino a \"" << _mask->get(F_AMAG) << "\" ";
|
||||
rangem.set(srangem.empty() ? "Tutti i magazzini" : format("Magazzini %s",(const char *)srangem));
|
||||
srangem << TR("fino a \"") << _mask->get(F_AMAG) << "\" ";
|
||||
rangem.set(srangem.empty() ? TR("Tutti i magazzini") : format(FR("Magazzini %s"),(const char *)srangem));
|
||||
|
||||
cur.setfilter(cfilter);
|
||||
cur.setregion(darec,arec);
|
||||
@ -265,14 +262,14 @@ void TStampa_disp::setprint_perarticoli()
|
||||
if (*_mask->get(F_DAMAG))
|
||||
{
|
||||
filter << "(" << LF_MAG<< "->CODMAG[1,3]>=" <<'"' << _mask->get(F_DAMAG)<< "\")&&" ;
|
||||
srangem << "da \"" << _mask->get(F_DAMAG) << "\" ";
|
||||
srangem << TR("da \"") << _mask->get(F_DAMAG) << "\" ";
|
||||
}
|
||||
if (*_mask->get(F_AMAG))
|
||||
{
|
||||
filter << "(" << LF_MAG<< "->CODMAG[1,3]<=" <<'"' << _mask->get(F_AMAG)<< "\")&&" ;
|
||||
srangem << "fino a \"" << _mask->get(F_AMAG) << "\" ";
|
||||
srangem << TR("fino a \"") << _mask->get(F_AMAG) << "\" ";
|
||||
}
|
||||
rangem.set(srangem.empty() ? "Tutti i magazzini" : format("Magazzini %s",(const char *)srangem));
|
||||
rangem.set(srangem.empty() ? TR("Tutti i magazzini") : format(FR("Magazzini %s"),(const char *)srangem));
|
||||
if (filter.not_empty())
|
||||
filter.cut(filter.len()-2);
|
||||
// ********************
|
||||
@ -290,9 +287,9 @@ void TStampa_disp::setprint_perarticoli()
|
||||
_form->find_field('B',odd_page,"TOT_CATMER").hide();
|
||||
_form->set_ordering(mg_normale);
|
||||
if (!_mask->get(F_DAART).blank())
|
||||
srangea << "da \"" << _mask->get(F_DAART) << "\" ";
|
||||
srangea << TR("da \"") << _mask->get(F_DAART) << "\" ";
|
||||
if (!_mask->get(F_AART).blank())
|
||||
srangea << "fino a \"" << _mask->get(F_AART) << "\"";
|
||||
srangea << TR("fino a \"") << _mask->get(F_AART) << "\"";
|
||||
break;
|
||||
case 'D':
|
||||
_cur->setkey(2);
|
||||
@ -302,9 +299,9 @@ void TStampa_disp::setprint_perarticoli()
|
||||
_form->find_field('B',odd_page,"TOT_CATMER").hide();
|
||||
_form->set_ordering(mg_normale);
|
||||
if (!_mask->get(F_DADES).blank())
|
||||
srangea << "da \"" << _mask->get(F_DADES) << "\" ";
|
||||
srangea << TR("da \"") << _mask->get(F_DADES) << "\" ";
|
||||
if (!_mask->get(F_ADES).blank())
|
||||
srangea << "fino a \"" << _mask->get(F_ADES) << "\"";
|
||||
srangea << TR("fino a \"") << _mask->get(F_ADES) << "\"";
|
||||
break;
|
||||
case 'M':
|
||||
_cur->setkey(3);
|
||||
@ -315,22 +312,22 @@ void TStampa_disp::setprint_perarticoli()
|
||||
_form->set_ordering(mg_cat_merc);
|
||||
if (!_mask->get(F_DAART).blank())
|
||||
{
|
||||
srangea << "da \"" << _mask->get(F_DAART) << "\" ";
|
||||
srangea << TR("da \"") << _mask->get(F_DAART) << "\" ";
|
||||
cfilter << "(CODART[1," << _mask->get(F_DAART).len() << "]>=" <<'"' << _mask->get(F_AART)<< "\")&&" ;
|
||||
}
|
||||
if (!_mask->get(F_AART).blank())
|
||||
{
|
||||
srangea << "fino a \"" << _mask->get(F_AART) << "\"";
|
||||
srangea << TR("fino a \"") << _mask->get(F_AART) << "\"";
|
||||
cfilter << "(CODART[1," << _mask->get(F_AART).len() << "]<=" <<'"' << _mask->get(F_AART)<< "\")&&" ;
|
||||
}
|
||||
if (!_mask->get(F_DACATMER).blank())
|
||||
srangecm << "da \"" << _mask->get(F_DACATMER) << "\" ";
|
||||
srangecm << TR("da \"") << _mask->get(F_DACATMER) << "\" ";
|
||||
if (!_mask->get(F_ACATMER).blank())
|
||||
srangecm << "fino a \"" << _mask->get(F_ACATMER) << "\"";
|
||||
rangecm.set(srangecm.empty() ? "Tutte le categorie merceologiche" : format("Categorie merc. %s", (const char *)srangecm));
|
||||
srangecm << TR("fino a \"") << _mask->get(F_ACATMER) << "\"";
|
||||
rangecm.set(srangecm.empty() ? TR("Tutte le categorie merceologiche") : format(FR("Categorie merc. %s"), (const char *)srangecm));
|
||||
break;
|
||||
}
|
||||
rangea.set(srangea.empty() ? "Tutti gli articoli" : format("Articoli %s",(const char *)srangea));
|
||||
rangea.set(srangea.empty() ? TR("Tutti gli articoli") : format(FR("Articoli %s"),(const char *)srangea));
|
||||
|
||||
_form->setdett_perart(
|
||||
_mask->get_bool(F_RAGGCODICE),
|
||||
@ -383,6 +380,6 @@ void TStampa_disp::main_loop()
|
||||
int mg3200(int argc, char* argv[])
|
||||
{
|
||||
TStampa_disp a;// derivata da Application e con uso di form
|
||||
a.run(argc,argv,"Stampa disponibilita'");
|
||||
a.run(argc,argv,TR("Stampa disponibilita'"));
|
||||
return 0;
|
||||
}
|
||||
|
@ -70,19 +70,19 @@ const char* TForm_schedemag::descr_tiposcheda() const
|
||||
switch (_tiposcheda)
|
||||
{
|
||||
case s_giac:
|
||||
return ("Giacenza");
|
||||
return (TR("Giacenza"));
|
||||
case s_acl:
|
||||
return ("A conto lavoro");
|
||||
return (TR("A conto lavoro"));
|
||||
case s_incl:
|
||||
return ("In conto lavoro");
|
||||
return (TR("In conto lavoro"));
|
||||
case s_prodc:
|
||||
return ("In produzione componenti");
|
||||
return (TR("In produzione componenti"));
|
||||
case s_prodf:
|
||||
return ("In produzione finiti");
|
||||
return (TR("In produzione finiti"));
|
||||
case s_ordc:
|
||||
return ("Ordinato clienti");
|
||||
return (TR("Ordinato clienti"));
|
||||
case s_ordf:
|
||||
return ("Ordinato fornitori");
|
||||
return (TR("Ordinato fornitori"));
|
||||
case s_acq:
|
||||
default:
|
||||
break;
|
||||
@ -938,7 +938,7 @@ bool TStampa_schede_mag::handle_dadata(TMask_field& f, KEY k)
|
||||
const TEsercizio& es = ec[annoes];
|
||||
TDate data(f.get());
|
||||
if (data < es.inizio())
|
||||
return f.error_box ("La data di inizio non puo' essere anteriore al %s", es.inizio().string());
|
||||
return f.error_box (FR("La data di inizio non puo' essere anteriore al %s"), es.inizio().string());
|
||||
}
|
||||
return TRUE;
|
||||
}
|
||||
@ -952,7 +952,7 @@ bool TStampa_schede_mag::handle_adata(TMask_field& f, KEY k)
|
||||
const TEsercizio& es = ec[annoes];
|
||||
const TDate data(f.get());
|
||||
if (data > es.fine())
|
||||
return f.error_box ("La data di fine non puo' essere successiva al %s", es.fine().string());
|
||||
return f.error_box (FR("La data di fine non puo' essere successiva al %s"), es.fine().string());
|
||||
}
|
||||
return TRUE;
|
||||
}
|
||||
@ -980,7 +980,7 @@ static bool linker(int n, const char* str)
|
||||
TMailbox m;
|
||||
while (m.next_s(MSG_LN) != NULL); // Vuota mailbox
|
||||
|
||||
if (n == 1 && yesno_box("Si desidera aggiornare la stampa?"))
|
||||
if (n == 1 && yesno_box(TR("Si desidera aggiornare la stampa?")))
|
||||
{
|
||||
WINDOW viswin = cur_win();
|
||||
dispatch_e_char(viswin, K_ESC); // Chiude la viswin dell'anteprima
|
||||
@ -1013,6 +1013,6 @@ bool TStampa_schede_mag::destroy()
|
||||
int mg3300(int argc, char* argv[])
|
||||
{
|
||||
TStampa_schede_mag a;// derivata da Application e con uso di form
|
||||
a.run(argc,argv,"Stampa schede di magazzino");
|
||||
a.run(argc,argv,TR("Stampa schede di magazzino"));
|
||||
return 0;
|
||||
}
|
||||
}
|
@ -85,15 +85,12 @@ public:
|
||||
bool TStampa_storgiac::create()
|
||||
{
|
||||
_mask = new TStampemg_mask("mg3500");
|
||||
_files = new TArray();
|
||||
_files->add(new TLocalisamfile(LF_STOMAG));
|
||||
return TSkeleton_application::create();
|
||||
}
|
||||
|
||||
bool TStampa_storgiac::destroy()
|
||||
{
|
||||
delete _mask;
|
||||
delete _files;
|
||||
return TSkeleton_application::destroy();
|
||||
}
|
||||
|
||||
@ -219,6 +216,6 @@ void TStampa_storgiac::main_loop()
|
||||
int mg3500(int argc, char* argv[])
|
||||
{
|
||||
TStampa_storgiac a;
|
||||
a.run(argc,argv,"Stampa storico rimanenze");
|
||||
a.run(argc,argv,TR("Stampa storico rimanenze"));
|
||||
return 0;
|
||||
}
|
||||
|
@ -14,7 +14,6 @@ public:
|
||||
|
||||
class TStampa_storgiac : public TSkeleton_application
|
||||
{
|
||||
TArray * _files;
|
||||
TStampemg_mask * _mask;
|
||||
TCursor * _cur;
|
||||
TForm_storgiac * _form; // to be moved into TPrint_application
|
||||
|
@ -267,6 +267,6 @@ void TStampa_listamov::setprint_x_art()
|
||||
int mg4100(int argc, char* argv[])
|
||||
{
|
||||
TStampa_listamov a;// derivata da Application e con uso di form
|
||||
a.run(argc,argv,"Stampa lista movimenti");
|
||||
a.run(argc,argv,TR("Stampa lista movimenti"));
|
||||
return 0;
|
||||
}
|
||||
|
@ -48,30 +48,12 @@ bool TForm_inventario::validate(TForm_item &cf, TToken_string &s)
|
||||
else
|
||||
if (subcode=="VAL6" && _colonne >=6)
|
||||
valorizzazione(cf,_valorizz_scelte[5]);
|
||||
/* else
|
||||
if (subcode=="NAMEVAL1")
|
||||
cf.set(Nome_valorizz[_valorizz_scelte[0]]);
|
||||
else
|
||||
if (subcode=="NAMEVAL2"&& _colonne >=2)
|
||||
cf.set(Nome_valorizz[_valorizz_scelte[1]]);
|
||||
else
|
||||
if (subcode=="NAMEVAL3" && _colonne >=3)
|
||||
cf.set(Nome_valorizz[_valorizz_scelte[2]]);
|
||||
else
|
||||
if (subcode=="NAMEVAL4" && _colonne >=4)
|
||||
cf.set(Nome_valorizz[_valorizz_scelte[3]]);
|
||||
else
|
||||
if (subcode=="NAMEVAL5"&& _colonne >=5)
|
||||
cf.set(Nome_valorizz[_valorizz_scelte[4]]);
|
||||
else
|
||||
if (subcode=="NAMEVAL6" && _colonne >=6)
|
||||
cf.set(Nome_valorizz[_valorizz_scelte[5]]); */
|
||||
else
|
||||
if (subcode=="LINEATOTALI")
|
||||
{
|
||||
TString l(29*_colonne+12,'-');
|
||||
cf.set(l);
|
||||
}
|
||||
else
|
||||
if (subcode=="LINEATOTALI")
|
||||
{
|
||||
TString l(29*_colonne+12,'-');
|
||||
cf.set(l);
|
||||
}
|
||||
}
|
||||
else
|
||||
if (code == "_ANNO")
|
||||
@ -197,7 +179,7 @@ bool TForm_inventario::genera_intestazione_supplementare(pagetype p, short y)
|
||||
for (int j=0;j<_colonne;j++)
|
||||
{
|
||||
TForm_item& fi = body->find_field(FF_COL1HEADER+j*2);
|
||||
des = Nome_valorizz[_valorizz_scelte[j]];
|
||||
des = nome_valorizz(_valorizz_scelte[j]);
|
||||
int w = fi.width();
|
||||
if (_valorizz_scelte[j] < valorizz_FIFOa)
|
||||
w *= 2;
|
||||
@ -379,7 +361,7 @@ bool TStampainv_mask::handle_codlist(TMask_field &fld, KEY k)
|
||||
m.get_int(F_VAL5)-1==valorizz_przlist ||
|
||||
m.get_int(F_VAL6)-1==valorizz_przlist
|
||||
)
|
||||
return fld.error_box("Occorre specificare il listino per la valorizzazione");
|
||||
return fld.error_box(TR("Occorre specificare il listino per la valorizzazione"));
|
||||
|
||||
}
|
||||
}
|
||||
@ -399,23 +381,12 @@ void TStampa_inventario ::on_firm_change()
|
||||
bool TStampa_inventario::create()
|
||||
{
|
||||
_mask = new TStampainv_mask();
|
||||
_files = new TArray();
|
||||
// aggiunge i files per usare i tracciati record
|
||||
_files->add(new TLocalisamfile(LF_ANAMAG));
|
||||
_files->add(new TLocalisamfile(LF_UMART));
|
||||
_files->add(new TLocalisamfile(LF_DESLIN));
|
||||
_files->add(new TLocalisamfile(LF_CODCORR));
|
||||
_files->add(new TLocalisamfile(LF_MAG));
|
||||
_files->add(new TLocalisamfile(LF_STOMAG));
|
||||
_files->add(new TLocalisamfile(LF_MOVMAG));
|
||||
_files->add(new TLocalisamfile(LF_RMOVMAG));
|
||||
return TSkeleton_application::create();
|
||||
}
|
||||
|
||||
bool TStampa_inventario::destroy()
|
||||
{
|
||||
delete _mask;
|
||||
delete _files;
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
@ -465,7 +436,7 @@ bool TStampa_inventario::crea_tempmag(const bool b)
|
||||
const bool rt = temp_mag->good();
|
||||
if (!rt)
|
||||
{
|
||||
error_box("Errore %d in creazione file temporaneo per saldi di magazzino alla data indicata.", temp_mag->status());
|
||||
error_box(FR("Errore %d in creazione file temporaneo per saldi di magazzino alla data indicata."), temp_mag->status());
|
||||
delete temp_mag;
|
||||
}
|
||||
else
|
||||
@ -502,7 +473,7 @@ bool TStampa_inventario::calcola_giacenze(const bool b)
|
||||
TString16 annoes; annoes.format("%04d", anno);
|
||||
|
||||
TString msg;
|
||||
msg << "Elaborazione saldi al " << data_limite << " ...";
|
||||
msg << TR("Elaborazione saldi al ") << data_limite << " ...";
|
||||
|
||||
TProgind pi(items, msg, FALSE, TRUE);
|
||||
|
||||
@ -531,7 +502,7 @@ bool TStampa_inventario::calcola_giacenze(const bool b)
|
||||
const bool rt = temp_mag->good();
|
||||
if (!rt)
|
||||
{
|
||||
error_box("Errore %d in creazione file temporaneo per saldi di magazzino alla data indicata.", temp_mag->status());
|
||||
error_box(FR("Errore %d in creazione file temporaneo per saldi di magazzino alla data indicata."), temp_mag->status());
|
||||
delete temp_mag;
|
||||
}
|
||||
else
|
||||
@ -980,7 +951,7 @@ void TStampa_inventario::main_loop()
|
||||
empty = _mask->get(F_DADES).blank() && _mask->get(F_ADES).blank();
|
||||
else
|
||||
empty = _mask->get(F_DAART).blank() && _mask->get(F_AART).blank();
|
||||
if (empty && !yesno_box("Sono stati selezionati tutti gli articoli. Confermare la stampa?"))
|
||||
if (empty && !yesno_box(TR("Sono stati selezionati tutti gli articoli. Confermare la stampa?")))
|
||||
continue;
|
||||
}
|
||||
|
||||
@ -1059,7 +1030,7 @@ void TStampa_inventario::main_loop()
|
||||
{
|
||||
TForm_item & f = _form->find_field('H',odd_page,4);
|
||||
TString prompt = f.prompt();
|
||||
prompt << "al " << data_limite.string() << " ";
|
||||
prompt << TR("al ") << data_limite.string() << TR(" ");
|
||||
f.set_prompt(prompt);
|
||||
}
|
||||
_form->print();
|
||||
@ -1073,6 +1044,6 @@ void TStampa_inventario::main_loop()
|
||||
int mg4200(int argc, char* argv[])
|
||||
{
|
||||
TStampa_inventario a;
|
||||
a.run(argc,argv,"Stampa inventario");
|
||||
a.run(argc,argv,TR("Stampa inventario"));
|
||||
return 0;
|
||||
}
|
||||
|
@ -36,7 +36,6 @@ public:
|
||||
|
||||
class TStampa_inventario : public TSkeleton_application
|
||||
{
|
||||
TArray * _files;
|
||||
TStampemg_mask * _mask;
|
||||
TCursor * _cur;
|
||||
TForm_inventario * _form; // to be moved into TPrint_application
|
||||
|
@ -44,7 +44,7 @@ TRegistro_giornalemag::TRegistro_giornalemag(const char* cod, int year)
|
||||
:TRegistro_std(cod,year)
|
||||
{
|
||||
if (tipo()!=TIPOREG_GIOMAG)
|
||||
fatal_box("Il registro richiesto non è relativo ad un libro giornale di magazzino");
|
||||
fatal_box(TR("Il registro richiesto non è relativo ad un libro giornale di magazzino"));
|
||||
}
|
||||
|
||||
|
||||
@ -158,11 +158,11 @@ bool TGiornalemag::validate(TForm_item &cf, TToken_string &s)
|
||||
TDate datamov(cursor()->relation()->curr(LF_MOVMAG).get_date("DATAREG"));
|
||||
switch (freq_stampa ) {
|
||||
case 0:
|
||||
valore.format("%7g Movimento del %s ", (double)last_num_reg+1, (const char *)datamov.string());
|
||||
valore.format(FR("%7g Movimento del %s "), (double)last_num_reg+1, (const char *)datamov.string());
|
||||
valore << cursor()->relation()->curr(LF_MOVMAG).get("DESCR");
|
||||
break;
|
||||
default:
|
||||
valore.format("%7g Movimenti di %s, dal %d al %d", (double)last_num_reg+1,
|
||||
valore.format(FR("%7g Movimenti di %s, dal %d al %d"), (double)last_num_reg+1,
|
||||
(const char *)itom(datamov.month()),
|
||||
(int)((datamov.day()-1)/freq_stampa)*freq_stampa+1,
|
||||
(int)min(((datamov.day()-1)/freq_stampa+1)*freq_stampa,TDate::last_day(datamov.month(),datamov.year())) );
|
||||
@ -176,7 +176,7 @@ bool TGiornalemag::validate(TForm_item &cf, TToken_string &s)
|
||||
if (!ragg_mag)
|
||||
{
|
||||
vv=cursor()->relation()->lfile(LF_RMOVMAG).get("CODMAG");
|
||||
valore << "Mag." << vv.mid(0,3);
|
||||
valore << TR("Mag.") << vv.mid(0,3);
|
||||
vv=vv.mid(3,2);
|
||||
if (vv.not_empty())
|
||||
valore << '-' << vv ;
|
||||
@ -189,8 +189,8 @@ bool TGiornalemag::validate(TForm_item &cf, TToken_string &s)
|
||||
const TRectype& anamag = cursor()->relation()->curr(LF_ANAMAG);
|
||||
if (ragg_articoli)
|
||||
{
|
||||
valore << "Art." << anamag.get(ANAMAG_CODART) << ' ';
|
||||
//vv << ' ' << cursor()->relation()->lfile(LF_RMOVMAG).get("LIVGIAC") << ' ';
|
||||
valore << TR("Art.") << cursor()->relation()->lfile(LF_ANAMAG).get(ANAMAG_CODART) << ' ';
|
||||
|
||||
TString livello(cursor()->relation()->curr(LF_RMOVMAG).get("LIVGIAC"));
|
||||
if (livello.not_empty() && livello_giac != 0)
|
||||
{
|
||||
@ -211,20 +211,17 @@ bool TGiornalemag::validate(TForm_item &cf, TToken_string &s)
|
||||
{
|
||||
if (ragg_classi)
|
||||
{
|
||||
valore << "Classe fiscale " << anamag.get(ANAMAG_CLASSEFIS) << ' ';
|
||||
valore << TR("Classe fiscale ") << cursor()->relation()->lfile(LF_ANAMAG).get(ANAMAG_CLASSEFIS) << ' ';
|
||||
|
||||
if (ragg_raggart)
|
||||
{
|
||||
valore << " ragg. " << anamag.get(ANAMAG_RAGGFIS) << ' ';
|
||||
valore << TR(" ragg. ") << cursor()->relation()->lfile(LF_ANAMAG).get(ANAMAG_RAGGFIS) << ' ';
|
||||
|
||||
}
|
||||
} else {
|
||||
vv.cut(0);
|
||||
if (!ragg_caus && freq_stampa==0)
|
||||
{
|
||||
//valore << "Mov." << cursor()->relation()->lfile(LF_RMOVMAG).get("NUMREG") << "/";
|
||||
//valore << cursor()->relation()->lfile(LF_RMOVMAG).get("NRIG");
|
||||
}
|
||||
vv << "Art. " << anamag.get(ANAMAG_CODART);
|
||||
//vv << ' ' << cursor()->relation()->lfile(LF_RMOVMAG).get("LIVGIAC") << ' ';
|
||||
vv << TR("Art. ") << cursor()->relation()->lfile(LF_ANAMAG).get(ANAMAG_CODART);
|
||||
|
||||
}
|
||||
}
|
||||
valore << vv;
|
||||
@ -238,16 +235,16 @@ bool TGiornalemag::validate(TForm_item &cf, TToken_string &s)
|
||||
{
|
||||
const TString16 raggcau = rec_caus.get("S8");
|
||||
if (raggcau.blank())
|
||||
valore << "Causali varie";
|
||||
valore << TR("Causali varie");
|
||||
else
|
||||
{
|
||||
const TRectype& rec_rag = cache().get("%RFC", raggcau);
|
||||
valore << "Causali gruppo " << raggcau << ' ' << rec_rag.get("S0");
|
||||
valore << TR("Causali gruppo ") << raggcau << ' ' << rec_rag.get("S0");
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
valore << "Causale " << cf.get() << ' ' << rec_caus.get("S0");
|
||||
valore << TR("Causale ") << cf.get() << ' ' << rec_caus.get("S0");
|
||||
}
|
||||
cf.set(valore);
|
||||
return TRUE;
|
||||
@ -439,31 +436,6 @@ void TGiornalemag::set_parametri(TMask & m)
|
||||
cursor()->set_filterfunction(filter_func,FALSE);
|
||||
}
|
||||
|
||||
/*
|
||||
// unused : ora i magazzini hanno l'indicazione esplicita del registro
|
||||
// aggiungeva in un array i vari codici di giornale mag usati
|
||||
void TGiornalemag::add_mag(TRectype & magrec,const char * codreg)
|
||||
{
|
||||
TString16 codmag(magrec.get("CODTAB").left(3));
|
||||
if (codmag.len() == 3)
|
||||
{
|
||||
if (_cod_magazzini.is_key(codmag)) return;
|
||||
if (magrec.get_int("I2")==1)
|
||||
{
|
||||
// Indicazione di magazzino
|
||||
TTable mag("MAG");
|
||||
mag.put("CODTAB",magrec.get("S6"));
|
||||
mag.read();
|
||||
add_mag(mag.curr(),codreg);
|
||||
} else {
|
||||
// Indicazione di libro giornale
|
||||
if (magrec.get("S8")==codreg)
|
||||
_cod_magazzini.add(codmag);
|
||||
}
|
||||
}
|
||||
}
|
||||
*/
|
||||
|
||||
bool TGiornalemag::filter_func(const TRelation* r)
|
||||
{
|
||||
// const TRectype& movmag = r->curr(LF_MOVMAG);
|
||||
@ -582,7 +554,7 @@ void TStampa_giornalemag::main_loop()
|
||||
if (_giorn_mag->can_be_printed())
|
||||
_giorn_mag->print();
|
||||
else
|
||||
error_box("Impossibile stampare il giornale dalla data indicata");
|
||||
error_box(TR("Impossibile stampare il giornale dalla data indicata"));
|
||||
delete _giorn_mag;
|
||||
}
|
||||
} // while true
|
||||
@ -593,6 +565,6 @@ void TStampa_giornalemag::main_loop()
|
||||
int mg4300(int argc, char* argv[])
|
||||
{
|
||||
TStampa_giornalemag a;
|
||||
a.run(argc,argv,"Stampa giornale di magazzino");
|
||||
a.run(argc,argv,TR("Stampa giornale di magazzino"));
|
||||
return 0;
|
||||
}
|
||||
}
|
@ -57,8 +57,6 @@ typedef enum {
|
||||
riga_nongenerata=' ' // immissione direttta del mov.
|
||||
} TTipo_rigamovmag;
|
||||
|
||||
extern const char* const Nome_valorizz[16];
|
||||
|
||||
typedef enum {
|
||||
valorizz_ultcos,
|
||||
valorizz_mediacos,
|
||||
@ -74,6 +72,8 @@ typedef enum {
|
||||
valorizz_LIFOr
|
||||
} TTipo_valorizz;
|
||||
|
||||
extern const char* const nome_valorizz(TTipo_valorizz tipo);
|
||||
|
||||
class TArticolo : public TMultiple_rectype
|
||||
{
|
||||
protected:
|
||||
|
@ -738,12 +738,10 @@ const bool TCodice_livelli::autoinsert( int levnum, TMask_field & fld) const
|
||||
TString16 value(fld.get());
|
||||
if (!fit_to_format(value,levnum))
|
||||
{
|
||||
fld.error_box("Codice non corrispondente al formato previsto (%s)",(const char *)code_format(levnum));
|
||||
fld.error_box(FR("Codice non corrispondente al formato previsto (%s)"),(const char *)code_format(levnum));
|
||||
return FALSE;
|
||||
}
|
||||
bool result = autoinsert( levnum, value);
|
||||
// if (!result)
|
||||
// fld.set("");
|
||||
fld.set_focus();
|
||||
return result;
|
||||
}
|
||||
|
@ -3,6 +3,7 @@
|
||||
// oggetto TMov_Mag , multirecord del movimento di magazzino
|
||||
// funzione di ricostruzione saldi
|
||||
|
||||
#include <diction.h>
|
||||
#include <fraction.h>
|
||||
#include <progind.h>
|
||||
|
||||
@ -28,20 +29,56 @@ TTimed_skipbox:: TTimed_skipbox(const char * message,int seconds,int x,int y)
|
||||
{
|
||||
hide(DLG_OK);
|
||||
hide(DLG_CANCEL);
|
||||
add_button(DLG_OK, 0, "Continua", -11, -1, 12, 2,"",0);
|
||||
add_button(DLG_OK, 0, TR("Continua"), -11, -1, 12, 2,"",0);
|
||||
}
|
||||
|
||||
TTimed_skipbox::~TTimed_skipbox()
|
||||
{}
|
||||
|
||||
const char* const Nome_valorizz[16] =
|
||||
const char* const nome_valorizz(TTipo_valorizz tipo)
|
||||
{
|
||||
"Ultimo costo", "Media ultimi costi", "Prezzo di listino",
|
||||
"Costo standard", "Costo medio acquisto" ,
|
||||
"Costo medio ponderato" ,
|
||||
"FIFO annuale", "LIFO annuale",
|
||||
"FIFO", "LIFO",
|
||||
"FIFO Ragionieristico", "LIFO Ragionieristico"
|
||||
switch (tipo)
|
||||
{
|
||||
case valorizz_ultcos:
|
||||
return TR("Ultimo costo");
|
||||
break;
|
||||
case valorizz_mediacos:
|
||||
return TR("Media ultimi costi");
|
||||
break;
|
||||
case valorizz_przlist:
|
||||
return TR("Prezzo di listino");
|
||||
break;
|
||||
case valorizz_coststd:
|
||||
return TR("Costo standard");
|
||||
break;
|
||||
case valorizz_costmedio:
|
||||
return TR("Costo medio acquisto");
|
||||
break;
|
||||
case valorizz_costmediopond:
|
||||
return TR("Costo medio ponderato");
|
||||
break;
|
||||
case valorizz_FIFOa:
|
||||
return TR("FIFO annuale");
|
||||
break;
|
||||
case valorizz_LIFOa:
|
||||
return TR("LIFO annuale");
|
||||
break;
|
||||
case valorizz_FIFO:
|
||||
return TR("FIFO");
|
||||
break;
|
||||
case valorizz_LIFO:
|
||||
return TR("LIFO");
|
||||
break;
|
||||
case valorizz_FIFOr:
|
||||
return TR("FIFO Ragionieristico");
|
||||
break;
|
||||
case valorizz_LIFOr:
|
||||
return TR("LIFO Ragionieristico");
|
||||
break;
|
||||
default:
|
||||
return "";
|
||||
break;
|
||||
}
|
||||
} ;
|
||||
|
||||
const TString & TArticolo::get_str(const char* fieldname) const
|
||||
@ -247,7 +284,7 @@ bool TArticolo::lock_and_prompt(const char * cod)
|
||||
TString mess;
|
||||
if (err == _islocked)
|
||||
{
|
||||
mess << "Il record di anagrafica\ndell'articolo '" << cod << "' e' gia' usato da un altro programma.";
|
||||
mess << TR("Il record di anagrafica\ndell'articolo '") << cod << TR("' e' gia' usato da un altro programma.");
|
||||
TTimed_skipbox bbox((const char *)mess,10);
|
||||
while (err == _islocked)
|
||||
{
|
||||
@ -258,12 +295,12 @@ bool TArticolo::lock_and_prompt(const char * cod)
|
||||
else
|
||||
{
|
||||
if (err == _iskeyerr)
|
||||
mess << "Il codice articolo '" << cod << "' non e' valido";
|
||||
mess << TR("Il codice articolo '") << cod << TR("' non e' valido");
|
||||
else
|
||||
if (err == _iskeynotfound)
|
||||
mess << "Il record di anagrafica\ndell'articolo '"<< cod << "' non esiste.";
|
||||
mess << TR("Il record di anagrafica\ndell'articolo '")<< cod << TR("' non esiste.");
|
||||
else
|
||||
mess << "Non riesco ad accedere al\nrecord di anagrafica dell'articolo '"<< cod << "' - errore " << err << ".";
|
||||
mess << TR("Non riesco ad accedere al\nrecord di anagrafica dell'articolo '")<< cod << TR("' - errore ") << err << ".";
|
||||
TTimed_skipbox bbox((const char *)mess,10);
|
||||
|
||||
bbox.run();
|
||||
@ -358,9 +395,10 @@ TArticolo::TArticolo(const char* codice)
|
||||
add_file(LF_DESLIN,"NRIGA");
|
||||
if (codice && *codice)
|
||||
{
|
||||
const int err = read(codice);
|
||||
const int err=read(codice);
|
||||
if (err != NOERR)
|
||||
error_box("Impossibile leggere l'articolo %s: Errore %d",codice, err);
|
||||
error_box(FR("Impossibile leggere l'articolo %s: Errore %d"),codice, err);
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@ -1491,7 +1529,7 @@ void TArticolo_giacenza_data::al(const TDate& data, const char* codmag, const ch
|
||||
TProgind* pi = NULL;
|
||||
if (items >= 10)
|
||||
{
|
||||
TString80 str; str << "Calcolo giacenza articolo " << codice();
|
||||
TString80 str; str << TR("Calcolo giacenza articolo ") << codice();
|
||||
pi = new TProgind(items, str, FALSE, TRUE);
|
||||
}
|
||||
|
||||
@ -1774,18 +1812,6 @@ bool TCondizione_vendita::cerca( int tiporicerca, const char * codriga , const r
|
||||
|
||||
if (!found)
|
||||
{
|
||||
/*
|
||||
TLocalisamfile um(LF_UMART); // Use Frate cercone when possible!
|
||||
um.put("CODART", codriga);
|
||||
um.put("NRIGA", 1);
|
||||
if (um.read() == NOERR)
|
||||
{
|
||||
_prezzo = um.get_real("PREZZO");
|
||||
found = TRUE;
|
||||
}
|
||||
else
|
||||
_prezzo = ZERO;
|
||||
*/
|
||||
const TRectype& um = cache().get(LF_UMART, cod);
|
||||
_prezzo = um.get_real("PREZZO");
|
||||
found = !_prezzo.is_zero();
|
||||
@ -1828,4 +1854,4 @@ TCondizione_vendita::TCondizione_vendita(TConfig * ditta,
|
||||
_anamag(anamag), _umart(umart), _config_ditta(ditta), _ivarid(FALSE)
|
||||
{
|
||||
}
|
||||
|
||||
|
@ -2,6 +2,7 @@
|
||||
// oggetto TMov_Mag , multirecord del movimento di magazzino
|
||||
// funzione di ricostruzione saldi
|
||||
|
||||
#include <diction.h>
|
||||
#include <progind.h>
|
||||
|
||||
#include "mglib.h"
|
||||
@ -229,6 +230,7 @@ bool TMov_mag::add_explrows() const
|
||||
TRiga_esplosione & riga_esp=(TRiga_esplosione & )(boom[newrow]);
|
||||
linea_auto = new TRectype(row);
|
||||
linea_auto->put(RMOVMAG_CODART, riga_esp.articolo());
|
||||
linea_auto->put(RMOVMAG_LIVGIAC, riga_esp.livello());
|
||||
linea_auto->put(RMOVMAG_UM, riga_esp.um());
|
||||
linea_auto->put(RMOVMAG_QUANT, riga_esp.val());
|
||||
//if (codmag.not_empty())
|
||||
@ -272,11 +274,11 @@ bool TMov_mag::add_explrows() const
|
||||
if (boom.items() > 0 )
|
||||
{
|
||||
if (boom.items() == 1 && codart == ((TRiga_esplosione &)boom[0]).articolo())
|
||||
error_box("Movimento di magazzino %ld:\ndistinta %s ciclica", get_long(MOVMAG_NUMREG),(const char *)codart);
|
||||
error_box(FR("Movimento di magazzino %ld:\ndistinta %s ciclica"), get_long(MOVMAG_NUMREG),(const char *)codart);
|
||||
b.destroy_row(r,TRUE);
|
||||
}
|
||||
else
|
||||
message_box("Movimento di magazzino %ld:\nimpossibile esplodere l'articolo %s", get_long(MOVMAG_NUMREG),(const char *)codart);
|
||||
message_box(FR("Movimento di magazzino %ld:\nimpossibile esplodere l'articolo %s"), get_long(MOVMAG_NUMREG),(const char *)codart);
|
||||
}
|
||||
}
|
||||
} // ciclo righe
|
||||
@ -463,7 +465,7 @@ bool TMov_mag::lock_anamag(const char *codart)
|
||||
return TRUE;
|
||||
|
||||
TString mess;
|
||||
mess << "Il record di anagrafica dell'articolo '"<< codart << "' risulta essere già in uso.";
|
||||
mess << TR("Il record di anagrafica dell'articolo '")<< codart << TR("' risulta essere già in uso.");
|
||||
TTimed_breakbox bbox((const char *)mess,10);
|
||||
|
||||
key = bbox.run();
|
||||
@ -493,8 +495,8 @@ int TMov_mag::update_balances()
|
||||
|
||||
TString_array keys_to_add,keys_to_remove;
|
||||
|
||||
/*((TMov_mag *)this)->*/lines_to_add.get_keys(keys_to_add);
|
||||
/*((TMov_mag *)this)->*/lines_to_subtract.get_keys(keys_to_remove);
|
||||
lines_to_add.get_keys(keys_to_add);
|
||||
lines_to_subtract.get_keys(keys_to_remove);
|
||||
|
||||
// aggiunge i saldi nuovi
|
||||
keys_to_add.sort();
|
||||
@ -746,7 +748,7 @@ bool rebuild_balances(const TString& annoes,
|
||||
|
||||
if (maxart > 0)
|
||||
{
|
||||
information.format("Ricostruzione saldi esercizio %s: azzeramento...",(const char *)annoes);
|
||||
information.format(FR("Ricostruzione saldi esercizio %s: azzeramento..."),(const char *)annoes);
|
||||
TProgind barra_art(maxart,information, FALSE, TRUE);
|
||||
cur2.freeze();
|
||||
for (long a=0; a<maxart; a++)
|
||||
@ -773,7 +775,7 @@ bool rebuild_balances(const TString& annoes,
|
||||
if (maxmov > 0)
|
||||
{
|
||||
cur.freeze();
|
||||
information.format("Ricostruzione saldi esercizio %s: ricalcolo ...",(const char *)annoes);
|
||||
information.format(FR("Ricostruzione saldi esercizio %s: ricalcolo ..."),(const char *)annoes);
|
||||
TProgind barra_mov(maxmov,information, FALSE, TRUE);
|
||||
TMov_mag & mov_rec=(TMov_mag &)cur.curr();
|
||||
for (long m=0; m<maxmov; m++)
|
||||
|
@ -1,4 +1,5 @@
|
||||
#include <dongle.h>
|
||||
#include <diction.h>
|
||||
#include <modaut.h>
|
||||
|
||||
#include "mglib.h"
|
||||
@ -163,14 +164,9 @@ bool TForm_stampemg::validate(TForm_item &cf, TToken_string &s)
|
||||
if (valore!="")
|
||||
levname=livelli_giacenza().name(_tolivgiac+1);
|
||||
else
|
||||
levname="Giacenza";
|
||||
levname=TR("Giacenza");
|
||||
cf.set(levname << ' ' << valore);
|
||||
} else if (subcode=="VALIDATE_UM") {
|
||||
/*CHECK(last_um,"Unità di misura non definita");
|
||||
if (last_um->blank())
|
||||
cf.set("");
|
||||
delete last_um;
|
||||
last_um = NULL;*/
|
||||
TForm_string &um_field=(TForm_string &)cf.form().find_field('B',odd_page,atoi(s.get()) );
|
||||
if (*um_field.get()<=' ') // blank : not a valid UM!
|
||||
cf.set("0");
|
||||
@ -194,11 +190,9 @@ bool TForm_stampemg::validate(TForm_item &cf, TToken_string &s)
|
||||
{
|
||||
// impossibile sommare le quantità degli articoli per UM diverse
|
||||
dest.set(" ");
|
||||
//cf.form().find_field('B',odd_page,FF_FLAGTOTQTA).set("0");
|
||||
} else {
|
||||
// prima sommare le quantità degli articoli per UM diverse
|
||||
dest.set( cf.get() );
|
||||
//cf.form().find_field('B',odd_page,FF_FLAGTOTQTA).set("0");
|
||||
}
|
||||
} else if (subcode=="ORDINATO")
|
||||
{
|
||||
|
@ -4,16 +4,18 @@
|
||||
// *** classi per la libreria
|
||||
// ***
|
||||
//*****
|
||||
#include <diction.h>
|
||||
#include <tabutil.h>
|
||||
#include "mglib.h"
|
||||
|
||||
|
||||
// ************************************************
|
||||
// TEMP!!!!!!!!!!!!!!!!
|
||||
|
||||
TRegistro_std::TRegistro_std(const char* cod, int year) : TRectype(LF_TAB)
|
||||
{
|
||||
if (!read(cod, year))
|
||||
fatal_box("Il codice richiesto non è stato trovato nei registri");
|
||||
fatal_box(TR("Il codice richiesto non è stato trovato nei registri"));
|
||||
TTable itl("%ITL");
|
||||
itl.put("CODTAB",cod_intest());
|
||||
itl.read();
|
||||
@ -88,4 +90,4 @@ int TRegistro_std::unlock()
|
||||
TTable reg("REG");
|
||||
reg.put("CODTAB",this->get("CODTAB"));
|
||||
return reg.read(_unlock);
|
||||
}
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user