Patch level : 2.2

Files correlati     : 777
Ricompilazione Demo : [ ]
Commento            :
Migliorata gestione campi data


git-svn-id: svn://10.65.10.50/trunk@13426 c028cbd2-c16b-5b4b-a496-9718f37d4682
This commit is contained in:
guy 2005-10-17 10:15:01 +00:00
parent 18cb466b6b
commit fec0c8c76a

View File

@ -24,7 +24,7 @@
static int anno_dic()
{
static anno = 0;
static int anno = 0;
if (anno == 0)
{
TConfig ini(CONFIG_STUDIO);
@ -254,8 +254,6 @@ void TForm770::transfer_section(TPrint_section& body, int rigo,
TString8 basecode, code, type;
TString str;
TCursor& cur = *cursor();
body.update();
for (word f = 0; f < body.fields(); f++)
{
@ -273,7 +271,7 @@ void TForm770::transfer_section(TPrint_section& body, int rigo,
{
str = str.blank() ? "" : "1";
str.right_just(16);
}
} else
if (type == "CU")
{
const int dot = str.find('.');
@ -285,8 +283,12 @@ void TForm770::transfer_section(TPrint_section& body, int rigo,
str.cut(0);
else
str.right_just(16);
}
} else
if (type == "DT")
{
str.strip("-");
str.right_just(16);
} else
if (type == "NU")
str.right_just(16);
}
@ -297,7 +299,7 @@ void TForm770::transfer_section(TPrint_section& body, int rigo,
const TFieldref& fr = ((TForm_string&)fi).field(0);
const int num = fr.file();
const char* fn = fr.name();
const TFieldtypes ft = cur.curr(num).type(fn);
const TFieldtypes ft = cursor()->curr(num).type(fn);
switch (ft)
{
case _boolfld:
@ -308,9 +310,6 @@ void TForm770::transfer_section(TPrint_section& body, int rigo,
case _datefld:
if (str.len() == 10 && str[2] == '-' && str[5] == '-')
{
// str[2] = str[3]; str[3] = str[4];
// str[4] = str[8]; str[5] = str[9];
// str.cut(6);
str.strip("-");
str.right_just(16);
}