// 771100c.uml - Dati rappresentante
#include "771100.h"

TOOLBAR "" 0 20 0 2

BUTTON F_FISICA 10 2
BEGIN
  PROMPT -14 -1 "F~isiche"
END

BUTTON DLG_SAVEREC 10 2
BEGIN
PROMPT -24 -1 "~Registra"
MESSAGE EXIT,K_SAVE   
PICTURE BMP_SAVEREC
PICTURE BMP_SAVERECDN
END

BUTTON DLG_CANCEL 10 2
BEGIN
PROMPT -34 -1 ""
MESSAGE EXIT,K_ESC
END

BUTTON DLG_QUIT 10 2
BEGIN
PROMPT -44 -1 ""
MESSAGE EXIT,K_QUIT
END

ENDPAGE

PAGE "Rappresentante" -1 -1 78 18

GROUPBOX DLG_NULL 78 4
BEGIN
  PROMPT 0 0 ""
  FLAGS "R"
END

NUMBER F_CODDITTA 5
BEGIN
  PROMPT 1 1 "Ditta             "
  FLAGS "GRD"
  USE LF_NDITTE KEY 1
  CHECKTYPE REQUIRED
  INPUT CODDITTA F_CODDITTA
  OUTPUT F_RAGSOC LF_NDITTE->RAGSOC 
  KEY 1
END

STRING F_RAGSOC 50
BEGIN
  PROMPT 1 2 "Ragione sociale   "
  FLAGS "D"
END                                

NUMBER F_ANAGR 5
BEGIN
  PROMPT 1 4 "Codice rappresentante   "
  FLAGS "D"
  USE LF_NDITTE 
  INPUT CODDITTA F_CODDITTA 
  FIELD LF_NDITTE->RAPPR   
  CHECKTYPE NORMAL
  JOIN LF_ANAG INTO CODANAGR==RAPPR TIPOA=="F"
  JOIN LF_ANAGFIS TO LF_ANAG INTO CODANAGR=CODANAGR   
  JOIN LF_COMUNI TO LF_ANAGFIS INTO COM==COMNASC
  JOIN LF_COMUNI TO LF_ANAG ALIAS 1 INTO COM==COMRES
  JOIN LF_COMUNI TO LF_ANAG ALIAS 2 INTO COM==COMRF
  OUTPUT F_COFI 		LF_ANAG->COFI
  OUTPUT F_COGNOME 	LF_ANAG->RAGSOC[1,30]
  OUTPUT F_NOME 		LF_ANAG->RAGSOC[31,50]
  OUTPUT F_SESSO 		LF_ANAGFIS->SESSO
  OUTPUT F_DATANASC LF_ANAGFIS->DATANASC     
  OUTPUT F_COMNASC 	LF_COMUNI->DENCOM
  OUTPUT F_PROVNASC	LF_COMUNI->PROVCOM
  OUTPUT F_INDRES		LF_ANAG->INDRES
  OUTPUT F_CIVRES 	LF_ANAG->CIVRES
  OUTPUT F_CAPRES 	LF_ANAG->CAPRES
  OUTPUT F_INDRF 		LF_ANAG->INDRF
  OUTPUT F_CIVRF 		LF_ANAG->CIVRF
  OUTPUT F_CAPRF 		LF_ANAG->CAPRF
  OUTPUT F_COMRES 	1@->DENCOM
  OUTPUT F_PROVRES 	1@->PROVCOM
  OUTPUT F_COMRF 		2@->DENCOM
  OUTPUT F_PROVRF 	2@->PROVCOM 
  OUTPUT F_DOMFISC 	LF_ANAG->VARSLORES
  OUTPUT F_ANAGR 		LF_ANAGFIS->CODANAGR
  OUTPUT F_PTELRF 	LF_ANAG->PTELRF
  OUTPUT F_TELRF  	LF_ANAG->TELRF
END

STRING F_COFI 16
BEGIN
  PROMPT 1 5 "Codice fiscale "
  FLAGS "D" 
END

STRING F_COGNOME 30
BEGIN
  PROMPT 1 6 "Cognome        "
  FLAGS "D"
END

STRING F_NOME 20
BEGIN
  PROMPT 1 7 "Nome           "
  FLAGS "D"
END 

STRING F_SESSO 1
BEGIN
  PROMPT 39 7 "Sesso "   
  FLAGS "D"
END

DATE F_DATANASC 
BEGIN
  PROMPT 49 7 "Data di nascita "
  FLAGS "D"
END

STRING F_COMNASC 50
BEGIN
  PROMPT 1 8 "Comune nascita "
  FLAGS "D"
END

STRING F_PROVNASC 5
BEGIN
  PROMPT 70 8 ""
  FLAGS "D"
END

LIST F_CARRAP 51
BEGIN
  PROMPT 1 9 "Carica         "
  HELP "Codice della carica del rappresentante legale"
  ITEM " |Nessun rappresentante"
  ITEM "1|Rappresentante legale o di fatto"
  ITEM "2|Curatore fallimentare"
  ITEM "3|Liquidatore"
  ITEM "4|Nominato in Italia per società con sede all'estero"
  ITEM "5|Erede"
  ITEM "6|Curatore di eredità giacente"
  FIELD LF_BASE->CARRAPP
END

BOOLEAN F_DOMFISC
BEGIN
  PROMPT 15 10 "Dom.fiscale o residenza variati rispetto all'anno precedente "
  FLAGS "D"
END

GROUPBOX DLG_NULL 78 4
BEGIN
  PROMPT 0 10 "Residenza"
END

STRING F_INDRES 35
BEGIN
  PROMPT 1 11 "Indirizzo "
  FLAGS "D"
END

STRING F_CIVRES 10
BEGIN
  PROMPT 47 11 ""
  FLAGS "D"
END

STRING F_CAPRES 5
BEGIN
  PROMPT 63 11 "C.A.P. "
  FLAGS "D"
END

STRING F_COMRES 50
BEGIN
  PROMPT 1 12 "Comune    "
  FLAGS "D"
END

STRING F_PROVRES 5
BEGIN
  PROMPT 63 12 "Prov.  "
  FLAGS "D"
END

GROUPBOX DLG_NULL 78 5
BEGIN
  PROMPT 0 14 "Domicilio fiscale "
END

STRING F_PTELRF 10
BEGIN
  PROMPT 1 15 "Telefono  "
  FLAGS "D"
END

STRING F_TELRF 30
BEGIN
  PROMPT 20 15 ""
  FLAGS "D"
END

STRING F_INDRF 35
BEGIN
  PROMPT 1 16 "Indirizzo "
  FLAGS "D"
END

STRING F_CIVRF 10
BEGIN
  PROMPT 47 16 ""
  FLAGS "D"
END

STRING F_CAPRF 5
BEGIN
  PROMPT 63 16 "C.A.P. "
  FLAGS "D"
END

STRING F_COMRF 50
BEGIN
  PROMPT 1 17 "Comune    "
  FLAGS "D"
END

STRING F_PROVRF 5
BEGIN
  PROMPT 63 17 "Prov.  "
  FLAGS "D"
END

ENDPAGE 

ENDMASK 
