Patch level : 10.0 patch ???
Files correlati : lv2 lv2300a.rep lv2200z.rep Ricompilazione Demo : [ ] Commento : Sulla stampa dei giri, sia giornaliero che settimanale non funziona l'opzione di "utilizza mnemonico" git-svn-id: svn://10.65.10.50/branches/R_10_00@22175 c028cbd2-c16b-5b4b-a496-9718f37d4682
This commit is contained in:
		
							parent
							
								
									03aefe6226
								
							
						
					
					
						commit
						ba4adf23ce
					
				
							
								
								
									
										285
									
								
								lv/lv2200z.rep
									
									
									
									
									
								
							
							
						
						
									
										285
									
								
								lv/lv2200z.rep
									
									
									
									
									
								
							| @ -1,148 +1,147 @@ | ||||
| <?xml version="1.0" encoding="UTF-8" ?> | ||||
| <report name="lv2200z" orientation="1" lpi="6" command="lv0 -1 lv2200z"> | ||||
|   <description>Stampa Giri Giornaliero</description> | ||||
|   <font face="Courier New" size="10" /> | ||||
|   <section type="Head"> | ||||
|     <field y="1" type="Testo" width="12" height="1.5" pattern="1" text="Data elab. :" /> | ||||
|     <field x="12.5" y="1" type="Stringa" width="12" height="1.5" pattern="1"> | ||||
|       <prescript description="H0.0 PRESCRIPT">MESSAGE _TODAY</prescript> | ||||
|     </field> | ||||
|     <field x="27.5" y="1" type="Testo" align="center" width="45" height="1.5" pattern="1" text="Stampa Giro Giornaliero"> | ||||
|       <font face="Courier New" bold="1" size="12" /> | ||||
|     </field> | ||||
|     <field x="79.87" y="1.12" type="Testo" width="5" height="1.5" pattern="1" text="Pag." /> | ||||
|     <field x="85" y="1.12" type="Stringa" width="10" height="1.5" pattern="1"> | ||||
|       <prescript description="H0.0 PRESCRIPT">MESSAGE _PAGENO</prescript> | ||||
|     </field> | ||||
|   </section> | ||||
|   <section type="Head" level="1" /> | ||||
|   <section type="Head" level="2" height="10" page_break="1"> | ||||
|     <groupby>DTCONS+CODITI</groupby> | ||||
|     <field x="68" y="0.31" type="Array" width="25" height="1.5" pattern="1"> | ||||
|       <font face="Courier New" bold="1" size="14" /> | ||||
|       <source>167.GGCONS</source> | ||||
|       <list> | ||||
|         <li Value="Luned&#EC;" Code="1" /> | ||||
|         <li Value="Marted&#EC;" Code="2" /> | ||||
|         <li Value="Mercoled&#EC;" Code="3" /> | ||||
|         <li Value="Gioved&#EC;" Code="4" /> | ||||
|         <li Value="Venerd&#EC;" Code="5" /> | ||||
|         <li Value="Sabato" Code="6" /> | ||||
|         <li Value="Domenica" Code="7" /> | ||||
|       </list> | ||||
|     </field> | ||||
|     <field x="0.5" y="0.37" type="Numero" align="right" width="10" height="1.5" pattern="1"> | ||||
|       <font face="Courier New" bold="1" size="14" /> | ||||
|       <source>167.CODITI</source> | ||||
|     </field> | ||||
|     <field x="11.5" y="0.37" type="Stringa" width="50" height="1.5" pattern="1"> | ||||
|       <font face="Courier New" bold="1" size="14" /> | ||||
|       <source>300@.S0</source> | ||||
|     </field> | ||||
|     <field x="0.5" y="2.24" type="Stringa" width="10" height="1.5" pattern="1"> | ||||
|       <font face="Courier New" bold="1" size="14" /> | ||||
|       <source>167.CODAUT</source> | ||||
|     </field> | ||||
|     <field x="11.5" y="2.24" type="Stringa" width="50" height="1.5" pattern="1"> | ||||
|       <font face="Courier New" bold="1" size="14" /> | ||||
|       <source>301@.S0</source> | ||||
|     </field> | ||||
|     <field x="68" y="2.31" type="Data" width="16" height="1.5" pattern="1"> | ||||
|       <font face="Courier New" bold="1" size="14" /> | ||||
|       <source>DTCONS</source> | ||||
|     </field> | ||||
|     <field border="1" x="0.5" y="4" type="Rettangolo" width="92.5" height="3" pattern="1" /> | ||||
|     <field border="1" x="51.5" y="4" type="Linea" height="2.95" pattern="1" /> | ||||
|     <field border="1" x="72" y="4" type="Linea" height="2.95" pattern="1" /> | ||||
|     <field x="72" y="4" type="Linea" height="2.95" pattern="1" /> | ||||
|     <field x="51.5" y="4.06" type="Linea" height="2.95" pattern="1" /> | ||||
|     <field x="52" y="4.56" type="Testo" width="13" pattern="1" text="KM. PARTENZA:" /> | ||||
|     <field x="72.5" y="4.56" type="Testo" width="13" pattern="1" text="ORA PARTENZA:" /> | ||||
|     <field x="1.5" y="4.81" type="Stringa" width="50" pattern="1"> | ||||
|       <source>302@.S0</source> | ||||
|     </field> | ||||
|     <field border="1" x="65" y="5.25" type="Linea" width="6" height="0" pattern="1" /> | ||||
|     <field border="1" x="86" y="5.25" type="Linea" width="6" height="0" pattern="1" /> | ||||
|     <field x="1.5" y="5.81" type="Testo" width="7" pattern="1" text="TARGA" /> | ||||
|     <field x="8.5" y="5.81" type="Stringa" width="40" pattern="1"> | ||||
|       <source>167.CODMEZ</source> | ||||
|     </field> | ||||
|     <field x="52" y="5.81" type="Testo" width="13" pattern="1" text="KM. ARRIVO  :" /> | ||||
|     <field x="72.5" y="5.81" type="Testo" width="13" pattern="1" text="ORA ARRIVO  :" /> | ||||
|     <field border="1" x="65" y="6.5" type="Linea" width="6" height="0" pattern="1" /> | ||||
|     <field border="1" x="86" y="6.5" type="Linea" width="6" height="0" pattern="1" /> | ||||
|     <field border="1" x="0.5" y="8" type="Rettangolo" width="92.5" height="2" pattern="1" /> | ||||
|     <field border="1" x="6.5" y="8" type="Linea" height="1.95" pattern="1" /> | ||||
|     <field x="57" y="8" type="Testo" align="center" width="9" pattern="1" text="MODALITA'" /> | ||||
|     <field border="1" x="66.25" y="8" type="Linea" height="2" pattern="1" /> | ||||
|     <field x="66.5" y="8" type="Testo" width="15" height="1.5" pattern="1" text="BOLLE CONS." /> | ||||
|     <field border="1" x="13.5" y="8.06" type="Linea" height="1.95" pattern="1" /> | ||||
|     <field border="1" x="31.37" y="8.06" type="Linea" height="1.95" pattern="1" /> | ||||
|     <field border="1" x="56.75" y="8.06" type="Linea" height="1.95" pattern="1" /> | ||||
|     <field border="1" x="81.5" y="8.06" type="Linea" height="1.95" pattern="1" /> | ||||
|     <field x="81.75" y="8.06" type="Testo" width="10" pattern="1" text="PROSSIMA" /> | ||||
|     <field x="1.12" y="8.31" type="Testo" align="right" width="5" pattern="1" text="FERM." /> | ||||
|     <field x="7" y="8.31" type="Testo" align="right" width="6" pattern="1" text="CODICE" /> | ||||
|     <field x="14.12" y="8.31" type="Testo" width="17" pattern="1" text="RAGIONE SOCIALE " /> | ||||
|     <field x="31.5" y="8.31" type="Testo" width="25" pattern="1" text="LOCALITA'" /> | ||||
|     <field x="14.12" y="9" type="Testo" width="17" pattern="1" text="CLIENTE" /> | ||||
|     <field x="57" y="9" type="Testo" align="center" width="9" pattern="1" text="PASSAGGIO" /> | ||||
|     <field x="81.75" y="9.06" type="Testo" width="10.5" pattern="1" text="CONSEGNA" /> | ||||
|   </section> | ||||
|   <section type="Body"> | ||||
|     <field y="197" type="Numero" align="right" width="3" pattern="1"> | ||||
|       <source>CODITI</source> | ||||
|     </field> | ||||
|   </section> | ||||
|   <section type="Body" level="1"> | ||||
|     <field border="1" x="92.9" y="-0.07" type="Linea" height="4" pattern="1" /> | ||||
|     <field border="1" x="0.5" type="Linea" height="4" pattern="1" /> | ||||
|     <field x="1" type="Numero" align="right" width="5" pattern="1" hide_zero="1"> | ||||
|       <source>167.ORDFER</source> | ||||
|     </field> | ||||
|     <field border="1" x="6.5" type="Linea" height="4" pattern="1" /> | ||||
|     <field x="7" type="Numero" align="right" width="6" pattern="1"> | ||||
|       <source>167.CODCF</source> | ||||
|     </field> | ||||
|     <field border="1" x="13.5" type="Linea" height="4" pattern="1" /> | ||||
|     <field x="14" type="Stringa" width="17" height="3" pattern="1"> | ||||
|       <source>303@.RAGSOC</source> | ||||
|     </field> | ||||
|     <field border="1" x="31.37" type="Linea" height="4" pattern="1" /> | ||||
|     <field x="31.5" type="Stringa" width="25" height="2" pattern="1"> | ||||
|       <source>IF(304@.CODINDSP= "0" ;303@.LOCALITACF;305@.LOCALITA)</source> | ||||
|     </field> | ||||
|     <field border="1" x="56.75" type="Linea" height="4" pattern="1" /> | ||||
|     <field x="57" type="Array" align="center" width="9" pattern="1"> | ||||
|       <source>167.MODPASS</source> | ||||
|       <list> | ||||
|         <li Value="ENTRAMBI" Code=" " /> | ||||
|         <li Value="ENTRAMBI" Code="E" /> | ||||
|         <li Value="CONSEGNA" Code="C" /> | ||||
|         <li Value="RITIRO" Code="R" /> | ||||
|       </list> | ||||
|     </field> | ||||
|     <field border="1" x="66.25" type="Linea" height="4" pattern="1" /> | ||||
|     <field x="66.5" type="Stringa" width="15" pattern="1"> | ||||
|       <source>167.CODNUM</source> | ||||
|     </field> | ||||
|     <field border="1" x="81.5" type="Linea" height="4" pattern="1" /> | ||||
|     <field x="81.75" type="Stringa" width="10" pattern="1"> | ||||
|       <source>#NEXTCONS</source> | ||||
|     </field> | ||||
|     <field x="31.5" y="2" type="Stringa" width="25" height="2" pattern="1"> | ||||
|       <source>IF(304@.CODINDSP= "0";303@.CIVCF+','+303@.INDCF;305@.CIV+','+305@.INDIR)</source> | ||||
|     </field> | ||||
|     <field x="66.5" y="2" type="Numero" align="right" width="13" pattern="1" hide_zero="1"> | ||||
|       <source>167.NDOC</source> | ||||
|     </field> | ||||
|     <field border="1" x="0.5" y="4" type="Linea" width="92.4" height="0" pattern="1" /> | ||||
|   </section> | ||||
|   <section type="Foot" /> | ||||
|   <section type="Foot" level="1" /> | ||||
|   <section type="Foot" level="2" /> | ||||
|   <sql> | ||||
|     USE 167 KEY 2 | ||||
|  <description>Stampa Giri Giornaliero</description> | ||||
|  <font face="Courier New" size="10" /> | ||||
|  <section type="Head" pattern="1"> | ||||
|   <field y="1" type="Testo" width="12" height="1.5" pattern="1" text="Data elab. :" /> | ||||
|   <field x="12.5" y="1" type="Stringa" width="12" height="1.5" pattern="1"> | ||||
|    <prescript description="H0.0 PRESCRIPT">MESSAGE _TODAY</prescript> | ||||
|   </field> | ||||
|   <field x="27.5" y="1" type="Testo" align="center" width="45" height="1.5" pattern="1" text="Stampa Giro Giornaliero"> | ||||
|    <font face="Courier New" bold="1" size="12" /> | ||||
|   </field> | ||||
|   <field x="79.87" y="1.12" type="Testo" width="5" height="1.5" pattern="1" text="Pag." /> | ||||
|   <field x="85" y="1.12" type="Stringa" width="10" height="1.5" pattern="1"> | ||||
|    <prescript description="H0.0 PRESCRIPT">MESSAGE _PAGENO</prescript> | ||||
|   </field> | ||||
|  </section> | ||||
|  <section type="Head" level="1" pattern="1" /> | ||||
|  <section type="Head" level="2" height="10" page_break="1" pattern="1"> | ||||
|   <groupby>DTCONS+CODITI</groupby> | ||||
|   <field x="68" y="0.31" type="Array" width="25" height="1.5" pattern="1"> | ||||
|    <font face="Courier New" bold="1" size="14" /> | ||||
|    <source>167.GGCONS</source> | ||||
|    <list> | ||||
|     <li Value="Luned&#EC;" Code="1" /> | ||||
|     <li Value="Marted&#EC;" Code="2" /> | ||||
|     <li Value="Mercoled&#EC;" Code="3" /> | ||||
|     <li Value="Gioved&#EC;" Code="4" /> | ||||
|     <li Value="Venerd&#EC;" Code="5" /> | ||||
|     <li Value="Sabato" Code="6" /> | ||||
|     <li Value="Domenica" Code="7" /> | ||||
|    </list> | ||||
|   </field> | ||||
|   <field x="0.5" y="0.37" type="Numero" align="right" width="10" height="1.5" pattern="1"> | ||||
|    <font face="Courier New" bold="1" size="14" /> | ||||
|    <source>167.CODITI</source> | ||||
|   </field> | ||||
|   <field x="11.5" y="0.37" type="Stringa" width="50" height="1.5" pattern="1"> | ||||
|    <font face="Courier New" bold="1" size="14" /> | ||||
|    <source>300@.S0</source> | ||||
|   </field> | ||||
|   <field x="0.5" y="2.24" type="Stringa" width="10" height="1.5" pattern="1"> | ||||
|    <font face="Courier New" bold="1" size="14" /> | ||||
|    <source>167.CODAUT</source> | ||||
|   </field> | ||||
|   <field x="11.5" y="2.24" type="Stringa" width="50" height="1.5" pattern="1"> | ||||
|    <font face="Courier New" bold="1" size="14" /> | ||||
|    <source>301@.S0</source> | ||||
|   </field> | ||||
|   <field x="68" y="2.31" type="Data" width="16" height="1.5" pattern="1"> | ||||
|    <font face="Courier New" bold="1" size="14" /> | ||||
|    <source>DTCONS</source> | ||||
|   </field> | ||||
|   <field border="1" x="0.5" y="4" type="Rettangolo" width="92.5" height="3" pattern="1" /> | ||||
|   <field border="1" x="51.5" y="4" type="Linea" height="2.95" pattern="1" /> | ||||
|   <field border="1" x="72" y="4" type="Linea" height="2.95" pattern="1" /> | ||||
|   <field x="72" y="4" type="Linea" height="2.95" pattern="1" /> | ||||
|   <field x="51.5" y="4.06" type="Linea" height="2.95" pattern="1" /> | ||||
|   <field x="52" y="4.56" type="Testo" width="13" pattern="1" text="KM. PARTENZA:" /> | ||||
|   <field x="72.5" y="4.56" type="Testo" width="13" pattern="1" text="ORA PARTENZA:" /> | ||||
|   <field x="1.5" y="4.81" type="Stringa" width="50" pattern="1"> | ||||
|    <source>302@.S0</source> | ||||
|   </field> | ||||
|   <field border="1" x="65" y="5.25" type="Linea" width="6" height="0" pattern="1" /> | ||||
|   <field border="1" x="86" y="5.25" type="Linea" width="6" height="0" pattern="1" /> | ||||
|   <field x="1.5" y="5.81" type="Testo" width="7" pattern="1" text="TARGA" /> | ||||
|   <field x="8.5" y="5.81" type="Stringa" width="40" pattern="1"> | ||||
|    <source>167.CODMEZ</source> | ||||
|   </field> | ||||
|   <field x="52" y="5.81" type="Testo" width="13" pattern="1" text="KM. ARRIVO  :" /> | ||||
|   <field x="72.5" y="5.81" type="Testo" width="13" pattern="1" text="ORA ARRIVO  :" /> | ||||
|   <field border="1" x="65" y="6.5" type="Linea" width="6" height="0" pattern="1" /> | ||||
|   <field border="1" x="86" y="6.5" type="Linea" width="6" height="0" pattern="1" /> | ||||
|   <field border="1" x="0.5" y="8" type="Rettangolo" width="92.5" height="2" pattern="1" /> | ||||
|   <field border="1" x="6.5" y="8" type="Linea" height="1.95" pattern="1" /> | ||||
|   <field x="57" y="8" type="Testo" align="center" width="9" pattern="1" text="MODALITA'" /> | ||||
|   <field border="1" x="66.25" y="8" type="Linea" height="2" pattern="1" /> | ||||
|   <field x="66.5" y="8" type="Testo" width="15" height="1.5" pattern="1" text="BOLLE CONS." /> | ||||
|   <field border="1" x="13.5" y="8.06" type="Linea" height="1.95" pattern="1" /> | ||||
|   <field border="1" x="31.37" y="8.06" type="Linea" height="1.95" pattern="1" /> | ||||
|   <field border="1" x="56.75" y="8.06" type="Linea" height="1.95" pattern="1" /> | ||||
|   <field border="1" x="81.5" y="8.06" type="Linea" height="1.95" pattern="1" /> | ||||
|   <field x="81.75" y="8.06" type="Testo" width="10" pattern="1" text="PROSSIMA" /> | ||||
|   <field x="1.12" y="8.31" type="Testo" align="right" width="5" pattern="1" text="FERM." /> | ||||
|   <field x="7" y="8.31" type="Testo" align="right" width="6" pattern="1" text="CODICE" /> | ||||
|   <field x="14.12" y="8.31" type="Testo" width="17" pattern="1" text="RAGIONE SOCIALE " /> | ||||
|   <field x="31.5" y="8.31" type="Testo" width="25" pattern="1" text="LOCALITA'" /> | ||||
|   <field x="14.12" y="9" type="Testo" width="17" pattern="1" text="CLIENTE" /> | ||||
|   <field x="57" y="9" type="Testo" align="center" width="9" pattern="1" text="PASSAGGIO" /> | ||||
|   <field x="81.75" y="9.06" type="Testo" width="10.5" pattern="1" text="CONSEGNA" /> | ||||
|  </section> | ||||
|  <section type="Body" pattern="1"> | ||||
|   <field y="197" type="Numero" align="right" width="3" pattern="1"> | ||||
|    <source>CODITI</source> | ||||
|   </field> | ||||
|  </section> | ||||
|  <section type="Body" level="1" pattern="1"> | ||||
|   <field border="1" x="92.9" y="-0.07" type="Linea" height="4" pattern="1" /> | ||||
|   <field border="1" x="0.5" type="Linea" height="4" pattern="1" /> | ||||
|   <field x="1" type="Numero" align="right" width="5" pattern="1" hide_zero="1"> | ||||
|    <source>167.ORDFER</source> | ||||
|   </field> | ||||
|   <field border="1" x="6.5" type="Linea" height="4" pattern="1" /> | ||||
|   <field x="7" type="Numero" align="right" width="6" pattern="1"> | ||||
|    <source>167.CODCF</source> | ||||
|   </field> | ||||
|   <field border="1" x="13.5" type="Linea" height="4" pattern="1" /> | ||||
|   <field x="14" type="Stringa" width="17" height="3" pattern="1"> | ||||
|    <source>IF(#F_CHECK_MNEM=="X";303@.RICALT;303@.RAGSOC)</source> | ||||
|   </field> | ||||
|   <field border="1" x="31.37" type="Linea" height="4" pattern="1" /> | ||||
|   <field x="31.5" type="Stringa" width="25" height="2" pattern="1"> | ||||
|    <source>IF(304@.CODINDSP= "0" ;303@.LOCALITACF;305@.LOCALITA)</source> | ||||
|   </field> | ||||
|   <field border="1" x="56.75" type="Linea" height="4" pattern="1" /> | ||||
|   <field x="57" type="Array" align="center" width="9" pattern="1"> | ||||
|    <source>167.MODPASS</source> | ||||
|    <list> | ||||
|     <li Value="ENTRAMBI" Code=" " /> | ||||
|     <li Value="ENTRAMBI" Code="E" /> | ||||
|     <li Value="CONSEGNA" Code="C" /> | ||||
|     <li Value="RITIRO" Code="R" /> | ||||
|    </list> | ||||
|   </field> | ||||
|   <field border="1" x="66.25" type="Linea" height="4" pattern="1" /> | ||||
|   <field x="66.5" type="Stringa" width="15" pattern="1"> | ||||
|    <source>167.CODNUM</source> | ||||
|   </field> | ||||
|   <field border="1" x="81.5" type="Linea" height="4" pattern="1" /> | ||||
|   <field x="81.75" type="Stringa" width="10" pattern="1"> | ||||
|    <source>#NEXTCONS</source> | ||||
|   </field> | ||||
|   <field x="31.5" y="2" type="Stringa" width="25" height="2" pattern="1"> | ||||
|    <source>IF(304@.CODINDSP= "0";303@.CIVCF+','+303@.INDCF;305@.CIV+','+305@.INDIR)</source> | ||||
|   </field> | ||||
|   <field x="66.5" y="2" type="Numero" align="right" width="13" pattern="1" hide_zero="1"> | ||||
|    <source>167.NDOC</source> | ||||
|   </field> | ||||
|   <field border="1" x="0.5" y="4" type="Linea" width="92.4" height="0" pattern="1" /> | ||||
|  </section> | ||||
|  <section type="Foot" pattern="1" /> | ||||
|  <section type="Foot" level="1" pattern="1" /> | ||||
|  <section type="Foot" level="2" pattern="1" /> | ||||
|  <sql>USE 167 KEY 2 | ||||
|     SELECT (BETWEEN(CODITI,#FROM_CODITI,#TO_CODITI))(BETWEEN(CODAUT,#FROM_CODAUT,#TO_CODAUT))(BETWEEN(CODCF,#FROM_CODCF,#TO_CODCF)) | ||||
|     JOIN ITI ALIAS 300 INTO CODTAB==CODITI | ||||
|     JOIN AUT TO 167 ALIAS 301 INTO CODTAB==CODAUT | ||||
|  | ||||
| @ -3,6 +3,8 @@ | ||||
| #include <reprint.h> | ||||
| #include <textset.h> | ||||
| 
 | ||||
| #include "clifo.h" | ||||
|   | ||||
| #include "lvlib.h" | ||||
| #include "lv2300a.h" | ||||
| 
 | ||||
| @ -16,13 +18,14 @@ public: | ||||
| //ordine fermata e eventualmente l'ora
 | ||||
| struct TPassaggio: public TObject | ||||
| { | ||||
|   long _codcf; | ||||
|   int _ordfer; | ||||
|   int _ora; | ||||
|   long     _codcf; | ||||
|   TString80 _ragsoc; | ||||
|   int      _ordfer; | ||||
|   int      _ora; | ||||
|   TString4 _iter; | ||||
| 
 | ||||
|   TPassaggio() :_codcf(0),_ordfer(0),_ora(0) {} | ||||
|   TPassaggio(long codcf, int ordfer, int ora, const TString& iter) :_codcf(codcf),_ordfer(ordfer),_ora(ora),_iter(iter) {} | ||||
|   TPassaggio(long codcf, TString& ragsoc, int ordfer, int ora, const TString& iter) :_codcf(codcf),_ragsoc(ragsoc),_ordfer(ordfer),_ora(ora),_iter(iter) {} | ||||
| }; | ||||
| 
 | ||||
| class TPassaggi: public TArray | ||||
| @ -79,7 +82,7 @@ void TPassaggi::add(TPassaggio* p) | ||||
| class TSettimana: public TArray | ||||
| { | ||||
| public: | ||||
|   void add(int g,TPassaggio* p); | ||||
|   void add(int g, TPassaggio* p); | ||||
|   TPassaggio& passaggio(int g, int p);//giorno, fermata
 | ||||
|   int passaggi(int g) const; | ||||
|   int passaggi() const; | ||||
| @ -137,7 +140,7 @@ class TItinerari: public TArray | ||||
| { | ||||
| public: | ||||
|   void add(long i,int g,TPassaggio* p); | ||||
|   void add(long i,int g,long codcf, int ordfer, int ora,TString iter); | ||||
|   void add(long i,int g,long codcf, TString& ragsoc, int ordfer, int ora,TString& iter); | ||||
|   TSettimana& settimana(long codIti); | ||||
| }; | ||||
| 
 | ||||
| @ -146,9 +149,9 @@ void TItinerari::add(long i,int g,TPassaggio* p) | ||||
|   settimana(i).add(g,p); | ||||
| } | ||||
| 
 | ||||
| void TItinerari::add(long i,int g,long codcf, int ordfer, int ora, TString iter) | ||||
| void TItinerari::add(long i,int g,long codcf, TString& ragsoc, int ordfer, int ora, TString& iter) | ||||
| { | ||||
|   TPassaggio* p = new TPassaggio(codcf,ordfer,ora,iter); | ||||
|   TPassaggio* p = new TPassaggio(codcf,ragsoc,ordfer,ora,iter); | ||||
|   add(i,g,p); | ||||
| } | ||||
| TSettimana& TItinerari::settimana(long codIti) | ||||
| @ -193,6 +196,8 @@ protected: | ||||
| 
 | ||||
| void TGiri_app::elabora(const TMask& mask) const | ||||
| { | ||||
|   const bool mnemonico = mask.get_bool(F_CHECK_MNEM_TO); | ||||
| 
 | ||||
|   TISAM_recordset giri("USE LVRCONSPLAN KEY 2\n" | ||||
|                        "SELECT (BETWEEN(CODITI,#FROM_CODITI,#TO_CODITI))" | ||||
|                        "&&(BETWEEN(CODCF,#FROM_CODCF,#TO_CODCF))" | ||||
| @ -202,43 +207,51 @@ void TGiri_app::elabora(const TMask& mask) const | ||||
|                        ); | ||||
| 
 | ||||
|   //inserire parametri filtri
 | ||||
|   giri.set_var("#FROM_DATA",mask.get_date(F_DATA_FROM)); | ||||
|   giri.set_var("#TO_DATA",mask.get_date(F_DATA_TO));   | ||||
|   giri.set_var("#FROM_DATA",   mask.get_date(F_DATA_FROM)); | ||||
|   giri.set_var("#TO_DATA",     mask.get_date(F_DATA_TO));   | ||||
|   giri.set_var("#FROM_CODITI", TVariant(mask.get(F_CODITI_FROM))); | ||||
|   giri.set_var("#TO_CODITI",TVariant(mask.get(F_CODITI_TO))); | ||||
|   giri.set_var("#FROM_CODAUT",TVariant(mask.get(F_CODAUT_FROM))); | ||||
|   giri.set_var("#TO_CODAUT",TVariant(mask.get(F_CODAUT_TO))); | ||||
|   giri.set_var("#FROM_CODCF",TVariant(mask.get(F_CODCF_FROM))); | ||||
|   giri.set_var("#TO_CODCF",TVariant(mask.get(F_CODCF_TO))); | ||||
|   giri.set_var("#TO_CODITI",   TVariant(mask.get(F_CODITI_TO))); | ||||
|   giri.set_var("#FROM_CODAUT", TVariant(mask.get(F_CODAUT_FROM))); | ||||
|   giri.set_var("#TO_CODAUT",   TVariant(mask.get(F_CODAUT_TO))); | ||||
|   giri.set_var("#FROM_CODCF",  TVariant(mask.get(F_CODCF_FROM))); | ||||
|   giri.set_var("#TO_CODCF",    TVariant(mask.get(F_CODCF_TO))); | ||||
| 
 | ||||
|   TItinerari iti; | ||||
| 
 | ||||
|   for(bool ok = giri.move_first();ok;ok=giri.move_next()) | ||||
|   { | ||||
|     TDate giorno = giri.get("DTCONS").as_date();   | ||||
|     int wday = giorno.wday();//1=lunedì
 | ||||
|     long itinerario=giri.get("CODITI").as_int(); | ||||
|     TString iter=giri.get("CODITI").as_string(); | ||||
|     long cliente=giri.get("CODCF").as_int(); | ||||
|     int ordfer=giri.get("ORDFER").as_int(); | ||||
|     int ora = 0;//in attesa che venga inserito
 | ||||
|     TDate giorno    = giri.get("DTCONS").as_date();   | ||||
|     int wday        = giorno.wday(); //1 = lunedì
 | ||||
|     long itinerario = giri.get("CODITI").as_int(); | ||||
|     TString iter    = giri.get("CODITI").as_string(); | ||||
|     long cliente    = giri.get("CODCF").as_int(); | ||||
|     int ordfer      = giri.get("ORDFER").as_int(); | ||||
|     int ora         = 0; //in attesa che venga inserito
 | ||||
| 
 | ||||
|     iti.add(itinerario,wday,cliente,ordfer,ora,iter); | ||||
|     TToken_string key; | ||||
|     key.add('C'); | ||||
|     key.add(cliente); | ||||
|     TString80 ragsoc = cache().get(LF_CLIFO, key, mnemonico ? CLI_RICALT : CLI_RAGSOC); | ||||
| 
 | ||||
|     iti.add(itinerario,wday,cliente,ragsoc,ordfer,ora,iter); | ||||
|   } | ||||
| 
 | ||||
|   | ||||
|   TGiri_report r(true); | ||||
|   TGiri_recordset* giri_set = new TGiri_recordset(); | ||||
| 
 | ||||
|   giri_set->set_var("#F_CHECK_MNEM",TVariant(mask.get(F_CHECK_MNEM_TO))); | ||||
|   giri_set->set_var("#F_CHECK_MNEM",TVariant(mnemonico)); | ||||
| 	r.set_recordset(giri_set); | ||||
|   FOR_EACH_ARRAY_ITEM(iti,i,obj)//scandisce itinerario e tiene
 | ||||
|     //buoni solo quelli valorizzati
 | ||||
| #ifdef DBG | ||||
|   //const long cazzoni = giri_set->items();
 | ||||
|   //giri_set->save_as("C:/tmp/cazzone.txt", fmt_text);
 | ||||
| #endif | ||||
| 
 | ||||
|   FOR_EACH_ARRAY_ITEM(iti, i, obj) //scandisce itinerario e tiene buoni solo quelli valorizzati
 | ||||
|   { | ||||
|     TSettimana& s = *(TSettimana*) obj; | ||||
|     const int max = s.passaggi(); | ||||
| 
 | ||||
|     for(int j=0; j<max;j++) | ||||
|     for(int j=0; j<max; j++) | ||||
|     { | ||||
|       giri_set->new_rec(); | ||||
| 
 | ||||
| @ -246,14 +259,14 @@ void TGiri_app::elabora(const TMask& mask) const | ||||
|       str_iti.format("%03d", i); | ||||
|       giri_set->set(0,TVariant(str_iti)); | ||||
|        | ||||
|       for(int g=1; g<=7;g++) | ||||
|       for(int g = 1; g <= 7; g++) | ||||
|       { | ||||
|         const TPassaggio& pass = s.passaggio(g,j); | ||||
|         const int column = (g-1)*3+1; | ||||
|         const int column = (g-1) * 3 + 1; | ||||
|          | ||||
|         giri_set->set(column,pass._codcf); | ||||
|         giri_set->set(column + 1,TVariant(long (pass._ordfer))); | ||||
|         giri_set->set(column + 2,TVariant(long (pass._ora))); | ||||
|         giri_set->set(column,pass._ragsoc); | ||||
|         giri_set->set(column + 1, TVariant(long (pass._ordfer))); | ||||
|         giri_set->set(column + 2, TVariant(long (pass._ora))); | ||||
|       } | ||||
|     } | ||||
|   } | ||||
| @ -266,6 +279,11 @@ void TGiri_app::elabora(const TMask& mask) const | ||||
|     giri_set->set_var(varname, giri.get_var(varname), true); | ||||
|   } | ||||
| 
 | ||||
|  #ifdef DBG | ||||
|   const long cazzoni = giri_set->items(); | ||||
|   giri_set->save_as("C:/tmp/cazzone.xls", fmt_html); | ||||
| #endif | ||||
| 
 | ||||
|   TReport_book b; | ||||
|   bool ok = b.add(r);// Richiede parametri di stampa in base alla maschera omonima
 | ||||
|   if (ok) | ||||
|  | ||||
| @ -2,7 +2,7 @@ | ||||
| <report name="lv2300a" orientation="2" lpi="6"> | ||||
|  <description>Stampa Giri Settimanale</description> | ||||
|  <font face="Courier New" size="10" /> | ||||
|  <section type="Head"> | ||||
|  <section type="Head" pattern="1"> | ||||
|   <field x="1.5" type="Testo" width="12" height="1.5" pattern="1" text="Data elab. :" /> | ||||
|   <field x="14" type="Stringa" width="12" height="1.5" pattern="1"> | ||||
|    <prescript>MESSAGE _TODAY</prescript> | ||||
| @ -15,8 +15,8 @@ | ||||
|    <prescript>MESSAGE _PAGENO</prescript> | ||||
|   </field> | ||||
|  </section> | ||||
|  <section type="Head" level="1" /> | ||||
|  <section repeat="1" type="Head" level="2" height="3" page_break="1"> | ||||
|  <section type="Head" level="1" pattern="1" /> | ||||
|  <section repeat="1" type="Head" level="2" height="3" page_break="1" pattern="1"> | ||||
|   <groupby>A</groupby> | ||||
|   <field x="2" type="Testo" width="10" pattern="1" text="Itinerario:"> | ||||
|    <font face="Courier New" bold="1" size="8" /> | ||||
| @ -78,8 +78,8 @@ | ||||
|    <prescript description="H2.2000 PRESCRIPT">MESSAGE _ISAMREAD,163,MOD='LV'!COD='AUT'!CODTAB=H2.1000,S0</prescript> | ||||
|   </field> | ||||
|  </section> | ||||
|  <section type="Body" /> | ||||
|  <section type="Body" level="1" height="2"> | ||||
|  <section type="Body" pattern="1" /> | ||||
|  <section type="Body" level="1" height="2" pattern="1"> | ||||
|   <font face="Courier New" size="8" /> | ||||
|   <field border="1" x="0.5" type="Linea" height="2" pattern="1" /> | ||||
|   <field border="1" x="19" type="Linea" height="2" pattern="1" /> | ||||
| @ -91,21 +91,18 @@ | ||||
|   <field border="1" x="133" type="Linea" height="2" pattern="1" /> | ||||
|   <field x="1" y="0.5" type="Stringa" width="15" pattern="1"> | ||||
|    <source>B</source> | ||||
|    <prescript description="B1.0 PRESCRIPT">MESSAGE _ISAMREAD,CLIFO,TIPOCF='C'!CODCF=#THIS,RAGSOC</prescript> | ||||
|   </field> | ||||
|   <field x="16.5" y="0.5" type="Numero" align="right" width="2" pattern="1" hide_zero="1"> | ||||
|    <source>C</source> | ||||
|   </field> | ||||
|   <field x="20" y="0.5" type="Stringa" width="15" pattern="1"> | ||||
|    <source>E</source> | ||||
|    <prescript description="B1.0 PRESCRIPT">MESSAGE _ISAMREAD,CLIFO,TIPOCF='C'!CODCF=#THIS,RAGSOC</prescript> | ||||
|   </field> | ||||
|   <field x="35.5" y="0.5" type="Numero" align="right" width="2" pattern="1" hide_zero="1"> | ||||
|    <source>F</source> | ||||
|   </field> | ||||
|   <field x="39" y="0.5" type="Stringa" width="15" pattern="1"> | ||||
|    <source>H</source> | ||||
|    <prescript description="B1.0 PRESCRIPT">MESSAGE _ISAMREAD,CLIFO,TIPOCF='C'!CODCF=#THIS,RAGSOC</prescript> | ||||
|   </field> | ||||
|   <field x="54.5" y="0.5" type="Numero" align="right" width="2" pattern="1" hide_zero="1"> | ||||
|    <source>I</source> | ||||
| @ -119,29 +116,26 @@ | ||||
|   </field> | ||||
|   <field x="77" y="0.5" type="Stringa" width="15" pattern="1"> | ||||
|    <source>N</source> | ||||
|    <prescript description="B1.0 PRESCRIPT">MESSAGE _ISAMREAD,CLIFO,TIPOCF='C'!CODCF=#THIS,RAGSOC</prescript> | ||||
|   </field> | ||||
|   <field x="92.5" y="0.5" type="Numero" align="right" width="2" pattern="1" hide_zero="1"> | ||||
|    <source>O</source> | ||||
|   </field> | ||||
|   <field x="96" y="0.5" type="Stringa" width="15" pattern="1"> | ||||
|    <source>Q</source> | ||||
|    <prescript description="B1.0 PRESCRIPT">MESSAGE _ISAMREAD,CLIFO,TIPOCF='C'!CODCF=#THIS,RAGSOC</prescript> | ||||
|   </field> | ||||
|   <field x="111.5" y="0.5" type="Numero" align="right" width="2" pattern="1" hide_zero="1"> | ||||
|    <source>R</source> | ||||
|   </field> | ||||
|   <field x="115" y="0.5" type="Stringa" width="15" pattern="1"> | ||||
|    <source>T</source> | ||||
|    <prescript description="B1.0 PRESCRIPT">MESSAGE _ISAMREAD,CLIFO,TIPOCF='C'!CODCF=#THIS,RAGSOC</prescript> | ||||
|   </field> | ||||
|   <field x="130.5" y="0.5" type="Numero" align="right" width="2" pattern="1" hide_zero="1"> | ||||
|    <source>U</source> | ||||
|   </field> | ||||
|  </section> | ||||
|  <section type="Foot" /> | ||||
|  <section type="Foot" level="1" /> | ||||
|  <section type="Foot" level="2"> | ||||
|  <section type="Foot" pattern="1" /> | ||||
|  <section type="Foot" level="1" pattern="1" /> | ||||
|  <section type="Foot" level="2" pattern="1"> | ||||
|   <field border="2" x="0.5" y="0.01" type="Linea" width="132.5" height="0" pattern="1" /> | ||||
|  </section> | ||||
| </report> | ||||
| @ -177,7 +177,7 @@ BEGIN | ||||
| END | ||||
| 
 | ||||
| BOOLEAN F_CHECK_MNEM_TO | ||||
|   BEGIN | ||||
| BEGIN | ||||
|   PROMPT 2 18 "Utilizza Mnemorico (Ricerca Alt.)" | ||||
|   FIELD #F_CHECK_MNEM | ||||
| END | ||||
|  | ||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user