Cosmesi minore
git-svn-id: svn://10.65.10.50/branches/R_10_00@22965 c028cbd2-c16b-5b4b-a496-9718f37d4682
This commit is contained in:
		
							parent
							
								
									6fd0afb1bc
								
							
						
					
					
						commit
						574734d8a8
					
				| @ -1406,9 +1406,7 @@ void TStampaDoc_application::print_selected(KEY k) | ||||
|   } | ||||
| 
 | ||||
|   pr.open(); | ||||
|   TProgind* pi = pr.printtype() != screenvis ?  | ||||
|                    new TProgind(cur.items(), TR("Stampa documenti in corso..."),false,true) : | ||||
|                    NULL; | ||||
|   TProgress_monitor* pi = pr.printtype() != screenvis ? new TProgress_monitor(cur.items(), TR("Stampa documenti in corso..."),false) : NULL; | ||||
|   if (!_is_lista) | ||||
|   { | ||||
|     cur.setregion(darec, arec); | ||||
| @ -1650,24 +1648,26 @@ void TStampaDoc_application::set_filter(TDocumento_form& frm) | ||||
|     if (riga.empty_items() || sw.empty()) | ||||
|       break; // Interrompe alla prima riga vuota...
 | ||||
| 
 | ||||
|      | ||||
|     e1.format("((CODNUM==\"%s\")", (const char*)sw); | ||||
|      | ||||
|     TString4 td = riga.get(1);td.trim(); | ||||
|     if (td.not_empty()) | ||||
|     { | ||||
|       e1 << "&&(TIPODOC==\"" << td <<"\")"; | ||||
|     } | ||||
|     TString4 td = riga.get(1); | ||||
|     if (td.full()) | ||||
|       e1 << "&&(TIPODOC==\"" << td.trim() <<"\")"; | ||||
| 
 | ||||
|     const long da_ndoc = riga.get_long(2); | ||||
|     const long a_ndoc  = riga.get_long(3); | ||||
|     if (da_ndoc > 0 || a_ndoc > 0) | ||||
|       e1 << "&&(BETWEEN(NDOC," << da_ndoc << "," << a_ndoc << "))"; | ||||
|      | ||||
|     e2 = ""; | ||||
|     for (int k=2; k<=7; k++) // Famme vede' li stati generali... Aho' A BURINO! Che e' la Rivoluzione Francese?
 | ||||
|     for (int k=4; k<=7; k++) // Famme vede' li stati generali... Aho' A BURINO! Che e' la Rivoluzione Francese?
 | ||||
|     { | ||||
|       const char c = riga.get_char(k); | ||||
|       if (c <= ' ') | ||||
|         break; // Interrompe al primo blank... 
 | ||||
|       e2.format("(STATO==\"%c\")",c); | ||||
|       // Se k vale 3 o piu' significa ke gli stati prec erano != "" no!?
 | ||||
|       if (k == 2) | ||||
|       if (k == 4) | ||||
|         e1 << "&&("; | ||||
|       else | ||||
|         e1 << "||"; | ||||
|  | ||||
| @ -24,14 +24,14 @@ END | ||||
| SPREADSHEET F_SHEETNUMS 78 8 | ||||
| BEGIN | ||||
|   PROMPT 1 2 "" | ||||
|   ITEM "Cod. num." | ||||
|   ITEM "Tipo doc." | ||||
|   ITEM "Cod.\nnum.@4" | ||||
|   ITEM "Tipo\ndoc.@4" | ||||
|   ITEM "Da doc.\nnumero@7" | ||||
|   ITEM "A doc.\nnumero@7" | ||||
|   ITEM "Stato 1" | ||||
|   ITEM "Stato 2" | ||||
|   ITEM "Stato 3" | ||||
|   ITEM "Stato 4" | ||||
|   ITEM "Stato 5" | ||||
|   ITEM "Stato 6" | ||||
| END | ||||
| 
 | ||||
| 
 | ||||
| @ -145,31 +145,19 @@ BEGIN | ||||
|   FLAGS "UB" | ||||
| END | ||||
| 
 | ||||
| STRING 103 1 | ||||
| NUMBER 103 7 | ||||
| BEGIN | ||||
|   PROMPT 1 3 "Stato 1            " | ||||
|   USE %STD | ||||
|   INPUT CODTAB 103 | ||||
|   DISPLAY "Stato" CODTAB | ||||
|   DISPLAY "Descrizione@50" S0 | ||||
|   OUTPUT 103 CODTAB | ||||
|   CHECKTYPE NORMAL | ||||
|   PROMPT 1 3 "Da numero doc.     " | ||||
| END | ||||
| 
 | ||||
| STRING 104 1 | ||||
| NUMBER 104 7 | ||||
| BEGIN | ||||
|   PROMPT 1 4 "Stato 2            " | ||||
|   USE %STD | ||||
|   INPUT CODTAB 104 | ||||
|   DISPLAY "Stato" CODTAB | ||||
|   DISPLAY "Descrizione@50" S0 | ||||
|   OUTPUT 104 CODTAB | ||||
|   CHECKTYPE NORMAL | ||||
|   PROMPT 1 4 "A numero doc.      " | ||||
| END | ||||
| 
 | ||||
| STRING 105 1 | ||||
| BEGIN | ||||
|   PROMPT 1 5 "Stato 3            " | ||||
|   PROMPT 1 5 "Stato 1            " | ||||
|   USE %STD | ||||
|   INPUT CODTAB 105 | ||||
|   DISPLAY "Stato" CODTAB | ||||
| @ -180,33 +168,30 @@ END | ||||
| 
 | ||||
| STRING 106 1 | ||||
| BEGIN | ||||
|   PROMPT 1 6 "Stato 4            " | ||||
|   USE %STD | ||||
|   PROMPT 1 6 "Stato 2            " | ||||
|   COPY USE 105 | ||||
|   INPUT CODTAB 106 | ||||
|   DISPLAY "Stato" CODTAB | ||||
|   DISPLAY "Descrizione@50" S0 | ||||
|   COPY DISPLAY 105 | ||||
|   OUTPUT 106 CODTAB | ||||
|   CHECKTYPE NORMAL | ||||
| END | ||||
| 
 | ||||
| STRING 107 1 | ||||
| BEGIN | ||||
|   PROMPT 1 7 "Stato 5            " | ||||
|   USE %STD | ||||
|   PROMPT 1 7 "Stato 3            " | ||||
|   COPY USE 105 | ||||
|   INPUT CODTAB 107 | ||||
|   DISPLAY "Stato" CODTAB | ||||
|   DISPLAY "Descrizione@50" S0 | ||||
|   COPY DISPLAY 105 | ||||
|   OUTPUT 107 CODTAB | ||||
|   CHECKTYPE NORMAL | ||||
| END | ||||
| 
 | ||||
| STRING 108 1 | ||||
| BEGIN | ||||
|   PROMPT 1 8 "Stato 6            " | ||||
|   USE %STD | ||||
|   PROMPT 1 8 "Stato 4            " | ||||
|   COPY USE 105 | ||||
|   INPUT CODTAB 108 | ||||
|   DISPLAY "Stato" CODTAB | ||||
|   DISPLAY "Descrizione@50" S0 | ||||
|   COPY DISPLAY 105 | ||||
|   OUTPUT 108 CODTAB | ||||
|   CHECKTYPE NORMAL | ||||
| END | ||||
|  | ||||
| @ -747,6 +747,8 @@ protected: | ||||
| 	void dirty_tabella_iva() { _tabella_iva.destroy();} | ||||
| 	static void test_firm(); | ||||
| 
 | ||||
|   virtual void on_read(int err, word lockop); // Inizializzazioni comuni post lettura record
 | ||||
| 
 | ||||
| 	void init(); | ||||
| 	void check_modules(); | ||||
| 	virtual void set_variables(TExpression * e) const ; | ||||
| @ -780,7 +782,7 @@ public: | ||||
|   void sort_rows(const char * key); | ||||
| 
 | ||||
| 	int physical_rows() const { return	body().rows(); }  | ||||
| 	virtual int rows() const { return physical_rows() + ((_sconto != NULL) ? 1 : 0) + ((_esenzione != NULL) ? 1 : 0); }  | ||||
| 	virtual int rows() const { return physical_rows() + (ha_riga_sconto() ? 1 : 0) + (ha_riga_esenzione() ? 1 : 0); }  | ||||
| 	const TRiga_documento& operator[](int index) const { return (const TRiga_documento&)((TDocumento *)this)->row(index); } | ||||
| 	TRiga_documento& operator[](int index) { return (TRiga_documento&)row(index); }  | ||||
| 	 | ||||
| @ -790,7 +792,8 @@ public: | ||||
| 	TRiga_documento& insert_row(int row, const char *tipo = NULL); | ||||
| 	TRiga_documento& new_row(const char *tipo = NULL); | ||||
| 	virtual int read(TBaseisamfile& f, word op = _isequal, word lockop = _nolock); | ||||
| 	virtual int write(TBaseisamfile& f) const { return write_rewrite(f, FALSE); } | ||||
|   virtual int readat(TBaseisamfile& file, TRecnotype nrec, word lockop = _nolock); | ||||
| 	virtual int write(TBaseisamfile& f) const { return write_rewrite(f, false); } | ||||
| 	virtual int rewrite(TBaseisamfile& f) const { return write_rewrite(f, true); } | ||||
| 	virtual int remove(TBaseisamfile& f) const;				  | ||||
| 
 | ||||
|  | ||||
| @ -768,10 +768,8 @@ TRiga_documento& TDocumento::new_row(const char *tipo) | ||||
|   return r; | ||||
| } | ||||
| 
 | ||||
| int TDocumento::read(TBaseisamfile& f, word op, word lockop) | ||||
| void TDocumento::on_read(int err, word lockop) | ||||
| { | ||||
|   int err = TMultiple_rectype::read(f, op, lockop);  | ||||
| 
 | ||||
|   _cli_for.zero(); | ||||
|   _occas.zero(); | ||||
| 
 | ||||
| @ -813,7 +811,19 @@ int TDocumento::read(TBaseisamfile& f, word op, word lockop) | ||||
|     _old_agente = get(DOC_CODAG); | ||||
|     _old_agente1 = get(DOC_CODAGVIS); | ||||
| 	} | ||||
| } | ||||
| 
 | ||||
| int TDocumento::read(TBaseisamfile& f, word op, word lockop) | ||||
| {  | ||||
|   const int err = TMultiple_rectype::read(f, op, lockop);  | ||||
|   on_read(err, lockop); | ||||
|   return err; | ||||
| } | ||||
| 
 | ||||
| int TDocumento::readat(TBaseisamfile& f, TRecnotype nrec, word lockop) | ||||
| { | ||||
|   const int err = TMultiple_rectype::readat(f, nrec, lockop);  | ||||
|   on_read(err, lockop); | ||||
|   return err; | ||||
| } | ||||
| 
 | ||||
| @ -2517,7 +2527,8 @@ real TDocumento::valore(bool totale, bool lordo, int ndec) const | ||||
| 
 | ||||
| void TDocumento::put_str(const char* fieldname, const char* val) | ||||
| {           | ||||
|   if (strcmp(fieldname, DOC_TIPODOC) == 0)                              | ||||
|   const TFixed_string fn(fieldname); | ||||
|   if (fn == DOC_TIPODOC) | ||||
|   {                        | ||||
|     const TString4 v(val); | ||||
|     if (TRectype::get(DOC_TIPODOC) != v) | ||||
| @ -2528,9 +2539,8 @@ void TDocumento::put_str(const char* fieldname, const char* val) | ||||
|     } | ||||
|     else | ||||
|       dirty_fields();                                 | ||||
|   } | ||||
|   else | ||||
|     if (strcmp(fieldname, DOC_CODCF) == 0)         | ||||
|   } else | ||||
|   if (fn == DOC_CODCF) | ||||
|   { | ||||
|     const TString8 v(val); | ||||
|     put(DOC_SPESEUPD, TRectype::get(DOC_CODCF) == v); | ||||
| @ -2541,7 +2551,7 @@ void TDocumento::put_str(const char* fieldname, const char* val) | ||||
|   { | ||||
|     TAuto_variable_rectype::put_str(fieldname, val); | ||||
|     dirty_fields();                                 | ||||
|       if (strcmp(fieldname, DOC_SCONTOPERC) == 0)  | ||||
|     if (fn == DOC_SCONTOPERC)  | ||||
|       set_riga_sconto(); | ||||
|   } | ||||
| } | ||||
|  | ||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user