Patch level : 10.0 1174
Files correlati : ha2.exe Ricompilazione Demo : [ ] Commento : Corretta percentuale di sconto Esselunga git-svn-id: svn://10.65.10.50/branches/R_10_00@22507 c028cbd2-c16b-5b4b-a496-9718f37d4682
This commit is contained in:
		
							parent
							
								
									87552939bb
								
							
						
					
					
						commit
						b559577672
					
				| @ -510,19 +510,6 @@ void THardy_esselunga_fat::add_rec_testata(TFatture_recordset& fat, TDocumento& | ||||
| 
 | ||||
| void THardy_esselunga_fat::add_rec_sommario(TFatture_recordset& fat, TDocumento& doc) | ||||
| { | ||||
| 	//fat.new_rec("FTT"); non ci sono note nel documento!
 | ||||
| 	// se c'e' sconto scrivo il record corrispondente
 | ||||
| 	/*
 | ||||
| 	real r;                                              | ||||
|   TString80 s;     | ||||
| 	bool sconto = scontoexpr2perc(doc.get(DOC_SCONTOPERC), FALSE, s, r); | ||||
|   if (sconto && r != ZERO) | ||||
| 	{ | ||||
| 		fat.new_rec("ALT"); | ||||
| 		fat.set("ALT.IMPORTO", r); | ||||
| 		fat.set("ALT.PERC", s); | ||||
| 	} | ||||
| 	*/ | ||||
| 	TAssoc_array& tabella_iva = doc.tabella_iva(); | ||||
| 	TRiepilogo_iva* ri; | ||||
| 	for (ri = (TRiepilogo_iva*) tabella_iva.first_item(); ri != NULL; ri = (TRiepilogo_iva*) tabella_iva.succ_item()) | ||||
| @ -594,7 +581,7 @@ void THardy_esselunga_fat::add_recs_dettaglio(TFatture_recordset& fat, TDocument | ||||
| 		//fat.new_rec("RFN"); // solo per note di debito e di credito (chiedere a Robbi)
 | ||||
| 
 | ||||
| 		fat.new_rec("TAX");  | ||||
|     const TString8 aliquota = real(rigadoc->iva().percentuale()*10000).string(7,0,0); | ||||
|     const TString8 aliquota = real(rigadoc->iva().percentuale()*10000).string(7,0,'0'); | ||||
| 		fat.set("TAX.ALIQIVA", aliquota); | ||||
| 		fat.set("TAX.DESCRIZ", rigadoc->iva().descrizione()); | ||||
| 		fat.set("TAX.IMPORTO", rigadoc->imposta()); | ||||
| @ -617,10 +604,9 @@ void THardy_esselunga_fat::add_recs_dettaglio(TFatture_recordset& fat, TDocument | ||||
|       fat.set("ALD.IMPORTO", sconto); | ||||
|        | ||||
|       TString80 str; | ||||
|       real perc; | ||||
|       scontoexpr2perc(rigadoc->get(RDOC_SCONTO), false, str, perc); | ||||
| 			str = perc.string(8,4,'0'); | ||||
| 			str.strip("." ); | ||||
|       real quota; scontoexpr2perc(rigadoc->get(RDOC_SCONTO), false, str, quota); | ||||
|       const real perc = (UNO - quota)*1000000; | ||||
| 			str = perc.string(7,0,'0'); | ||||
| 			fat.set("ALD.PERC", str); | ||||
| 		} | ||||
| 		fat.new_rec("NAD"); | ||||
|  | ||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user