Files correlati : Ricompilazione Demo : [ ] Commento :postinstallazione moduli ripresa dalla 3.1 git-svn-id: svn://10.65.10.50/trunk@15412 c028cbd2-c16b-5b4b-a496-9718f37d4682
		
			
				
	
	
		
			57 lines
		
	
	
		
			1.1 KiB
		
	
	
	
		
			C++
		
	
	
		
			Executable File
		
	
	
	
	
			
		
		
	
	
			57 lines
		
	
	
		
			1.1 KiB
		
	
	
	
		
			C++
		
	
	
		
			Executable File
		
	
	
	
	
#include <modaut.h>
 | 
						|
#include <tabutil.h>
 | 
						|
#include <utility.h>
 | 
						|
 | 
						|
#include "bainstlib.h"
 | 
						|
#include "bainst17.h"
 | 
						|
 | 
						|
class TInstall_AT : public TInstallmodule_app
 | 
						|
{
 | 
						|
protected:
 | 
						|
  virtual bool something_to_load() const ;
 | 
						|
  virtual int module_number() const {return ATAUT;}
 | 
						|
 | 
						|
  virtual bool preload_mask() ;
 | 
						|
  bool post_installer() ;
 | 
						|
 
 | 
						|
public:
 | 
						|
  virtual ~TInstall_AT () {}
 | 
						|
};
 | 
						|
 | 
						|
//controlla la tabella idoneita': se risulta vuota -> deve caricare i dati di default
 | 
						|
bool TInstall_AT ::something_to_load() const
 | 
						|
{        
 | 
						|
  if (prefix().get_codditta() <= 0)
 | 
						|
    return true;
 | 
						|
  TTable ido("IDO");
 | 
						|
  const bool empty = ido.first() != NOERR;
 | 
						|
  
 | 
						|
  return empty;
 | 
						|
}
 | 
						|
 | 
						|
bool TInstall_AT ::post_installer() 
 | 
						|
{
 | 
						|
  bool ok = true;
 | 
						|
  if (_m->get_bool(F_USAMENUAVIS))
 | 
						|
  {
 | 
						|
    ok = fcopy("agaat.men","bamenu.men");
 | 
						|
    TConfig config (CONFIG_STUDIO, "at");
 | 
						|
    config.set("EdMask", "at0500a.msk");
 | 
						|
    config.set("EdApp", "at0 -4");
 | 
						|
  }
 | 
						|
 | 
						|
  return ok;
 | 
						|
}
 | 
						|
 | 
						|
bool TInstall_AT::preload_mask()
 | 
						|
{
 | 
						|
  _m->field(F_USAMENUAVIS).set("X");
 | 
						|
  return TInstallmodule_app::preload_mask();
 | 
						|
}
 | 
						|
 | 
						|
int bainst17(int argc, char** argv)
 | 
						|
{ 
 | 
						|
  TInstall_AT app;
 | 
						|
  app.run(argc, argv);
 | 
						|
  return 0;
 | 
						|
} |