Patch level : 10.0
Files correlati : ps0398.exe Ricompilazione Demo : [ ] Commento : Aggiunti vari TR() ed eliminate inclusioni inutili git-svn-id: svn://10.65.10.50/branches/R_10_00@22203 c028cbd2-c16b-5b4b-a496-9718f37d4682
This commit is contained in:
parent
67bbdeca8b
commit
80e9fd0938
@ -8,7 +8,7 @@ int main( int argc, char** argv )
|
||||
|
||||
switch (r)
|
||||
{
|
||||
case 0: ps0398100(argc, argv); break; // trasferimento ordini da sito web a campo (gianni ferrari)
|
||||
case 0: ps0398100(argc, argv); break; // trasferimento ordini da web a Campo (Gianni Ferrari)
|
||||
default: break;
|
||||
}
|
||||
return 0;
|
||||
|
@ -1,11 +1,9 @@
|
||||
#include <applicat.h>
|
||||
#include <automask.h>
|
||||
#include <config.h>
|
||||
#include <defmask.h>
|
||||
#include <dongle.h>
|
||||
#include <execp.h>
|
||||
#include <lffiles.h>
|
||||
#include <modaut.h>
|
||||
#include <progind.h>
|
||||
#include <recarray.h>
|
||||
#include <reputils.h>
|
||||
@ -191,7 +189,7 @@ void TTrasferimento_ordini::elab_ho(const TString& riga_txt, const int curr_nrig
|
||||
if (!datadoc.ok())
|
||||
{
|
||||
TString msg;
|
||||
msg.format("Data documento non valida: %s", (const char*)str_data);
|
||||
msg.format(FR("Data documento non valida: %s"), (const char*)str_data);
|
||||
log.log(2, msg);
|
||||
}
|
||||
TString4 head_paragrafo;
|
||||
@ -239,9 +237,11 @@ void TTrasferimento_ordini::elab_ra(const TString& riga_txt, const int curr_nrig
|
||||
if (rec_anamag.empty())
|
||||
{
|
||||
TString msg;
|
||||
msg.format("Articolo non in anagrafica: %s", (const char*)codart);
|
||||
msg = TR("Articolo non in anagrafica");
|
||||
curr_ini.set(RDOC_DESCR, msg);
|
||||
|
||||
msg << ": " << codart;
|
||||
log.log(2, msg);
|
||||
curr_ini.set(RDOC_DESCR, "Articolo non in anagrafica");
|
||||
}
|
||||
else //sennò va tranquillo
|
||||
{
|
||||
@ -432,13 +432,13 @@ bool TTrasferimento_ordini::elabora()
|
||||
if (!crea_dir)
|
||||
{
|
||||
TString msg;
|
||||
msg.format("Impossibile creare la cartella di lavoro %s !", tmp);
|
||||
msg.format(FR("Impossibile creare la cartella di lavoro %s!"), tmp);
|
||||
return error_box(msg);
|
||||
}
|
||||
|
||||
//scansione dello string_array per il trasferimento (con tanto di progind e log)
|
||||
TProgind pi(n_files_txt, TR("Acquisizione ordini in corso..."), true, true);
|
||||
TLog_report log("ERRORI DI TRASFERIMENTO");
|
||||
TProgind pi(n_files_txt, main_app().title(), true, true);
|
||||
TLog_report log(main_app().title());
|
||||
|
||||
//si accatta anche il magazzino
|
||||
_codmag = _mask->get(F_CODMAG);
|
||||
@ -452,25 +452,24 @@ bool TTrasferimento_ordini::elabora()
|
||||
//file in formato filename (è l'ordine corrente da elaborare)
|
||||
const TFilename curr_fname = src_files_list.row(i);
|
||||
TFilename tempfile(tmp);
|
||||
|
||||
tempfile << '/' << curr_fname.name();
|
||||
tempfile.add(curr_fname.name());
|
||||
fcopy(curr_fname, tempfile, false, true);
|
||||
|
||||
//creazione del recordset associato al file
|
||||
TTrasferimento_ordini_recordset recset(tempfile);
|
||||
|
||||
//se il file non è di GF (si vede dal codart) viene saltato! ohp!
|
||||
//se il file non è di GF (si vede dal codart) viene saltato! Hop!
|
||||
if (!ordine_gf(recset))
|
||||
{
|
||||
TString msg;
|
||||
msg.format("Scartato file: %s ", (const char*)curr_fname.name());
|
||||
msg << TR("File Scartato: ") << curr_fname.name();
|
||||
log.log(1, msg);
|
||||
continue;
|
||||
}
|
||||
|
||||
//avverte sul log quale file sta elaborando
|
||||
TString msg;
|
||||
msg.format("Elaborazione file: %s", (const char*)curr_fname.name());
|
||||
msg << TR("Elaborazione file ") << curr_fname.name();
|
||||
log.log(0, msg);
|
||||
|
||||
//per ogni ordine in formato .txt genera un file.ini che andrà poi documentizzato
|
||||
@ -484,7 +483,7 @@ bool TTrasferimento_ordini::elabora()
|
||||
if (elaborazione_ok)
|
||||
{
|
||||
TString commandline;
|
||||
commandline.format("ve0 -0 /i%s",(const char*)ini_fname);
|
||||
commandline << "ve0 -0 /i" << ini_fname;
|
||||
TExternal_app ve(commandline);
|
||||
ve.run();
|
||||
}
|
||||
@ -493,9 +492,6 @@ bool TTrasferimento_ordini::elabora()
|
||||
TFilename dst_file = dst_path;
|
||||
dst_file.add(curr_fname.name());
|
||||
const bool copia_riuscita = sposta_file_elaborato(dst_file, curr_fname, log);
|
||||
|
||||
|
||||
|
||||
} //for(int i...
|
||||
|
||||
message_box(TR("Acquisizione ordini completata"));
|
||||
@ -509,9 +505,6 @@ bool TTrasferimento_ordini::elabora()
|
||||
|
||||
bool TTrasferimento_ordini::create()
|
||||
{
|
||||
//se non ha la VE non può proseguire
|
||||
if (!has_module(VEAUT))
|
||||
return error_box(TR("Modulo non autorizzato"));
|
||||
Tdninst dninst;
|
||||
if (!dninst.can_I_run(true))
|
||||
return error_box(TR("Programma non autorizzato!"));
|
||||
@ -531,6 +524,6 @@ void TTrasferimento_ordini::main_loop()
|
||||
int ps0398100 (int argc, char **argv)
|
||||
{
|
||||
TTrasferimento_ordini a;
|
||||
a.run(argc,argv, TR("Trasferimento ordini"));
|
||||
a.run(argc,argv, TR("Acquisizione ordini web"));
|
||||
return true;
|
||||
}
|
||||
|
@ -1,6 +1,6 @@
|
||||
#include "ps0398100a.h"
|
||||
|
||||
PAGE "Trasferimento Ordini Web->Campo" -1 -1 78 12
|
||||
PAGE "Trasferimento Ordini Web->Campo" -1 -1 78 13
|
||||
|
||||
GROUPBOX DLG_NULL 76 4
|
||||
BEGIN
|
||||
@ -105,7 +105,7 @@ END
|
||||
|
||||
STRING DLG_PROFILE 50
|
||||
BEGIN
|
||||
PROMPT 1 -1 "Profilo "
|
||||
PROMPT 2 -2 "Profilo "
|
||||
PSELECT
|
||||
END
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user