Ahora se instalan los archivos de fuentes necesarios y se crea el ODBC de PosgreSQL

This commit is contained in:
Juan Ferrer Toribio 2016-03-18 14:12:24 +01:00
parent 07cafcc5cd
commit 765e03052f
39 changed files with 62 additions and 24 deletions

BIN
fonts/C128btt3.ttf Executable file

Binary file not shown.

BIN
fonts/ConnectCode39.ttf Executable file

Binary file not shown.

BIN
fonts/FRE3OF9X.TTF Executable file

Binary file not shown.

BIN
fonts/FREE3OF9.TTF Executable file

Binary file not shown.

BIN
fonts/IDAutomationHC39M.ttf Executable file

Binary file not shown.

BIN
fonts/Roboto-Black.ttf Executable file

Binary file not shown.

BIN
fonts/Roboto-BlackItalic.ttf Executable file

Binary file not shown.

BIN
fonts/Roboto-Bold.ttf Executable file

Binary file not shown.

BIN
fonts/Roboto-BoldItalic.ttf Executable file

Binary file not shown.

BIN
fonts/Roboto-Italic.ttf Executable file

Binary file not shown.

BIN
fonts/Roboto-LightItalic.ttf Executable file

Binary file not shown.

BIN
fonts/Roboto-Medium.ttf Executable file

Binary file not shown.

BIN
fonts/Roboto-MediumItalic.ttf Executable file

Binary file not shown.

BIN
fonts/Roboto-Regular.ttf Executable file

Binary file not shown.

BIN
fonts/Roboto-Thin.ttf Executable file

Binary file not shown.

BIN
fonts/Roboto-ThinItalic.ttf Executable file

Binary file not shown.

BIN
fonts/Roboto_light.ttf Executable file

Binary file not shown.

BIN
fonts/lsans.ttf Executable file

Binary file not shown.

BIN
fonts/lsansd.ttf Executable file

Binary file not shown.

BIN
fonts/lsansdi.ttf Executable file

Binary file not shown.

BIN
fonts/lsansi.ttf Executable file

Binary file not shown.

BIN
fonts/mrvcode39extma.ttf Executable file

Binary file not shown.

BIN
icons/comp.ico Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 264 KiB

BIN
icons/enc.ico Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 264 KiB

BIN
icons/ent.ico Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 264 KiB

BIN
icons/eti.ico Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 264 KiB

BIN
icons/lab.ico Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 264 KiB

BIN
icons/tpv.ico Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 264 KiB

BIN
ocx/mscomct2.ocx Normal file

Binary file not shown.

20
setup.iss Executable file → Normal file
View File

@ -1,13 +1,12 @@
#define MyAppName "Verdnatura"
#define MyAppVersion "1.0"
#define MyAppVersion "1.1"
#define MyAppPublisher "Verdnatura"
#define MyAppURL "http://www.verdnatura.es/"
#define MyAppExeName "setup.exe"
[Setup]
; NOTE: The value of AppId uniquely identifies this application.
AppId={{7615F2D0-AB26-4EB0-948C-BBB2CE1151D7}
AppId={{1BFBC7A1-64B3-41E0-8A8E-0D29043EA8A3}
AppName={#MyAppName}
AppVersion={#MyAppVersion}
AppVerName={#MyAppName} {#MyAppVersion}
@ -19,7 +18,8 @@ CreateAppDir=yes
DefaultDirName={pf}\{#MyAppName}
DefaultGroupName={#MyAppName}
;LicenseFile=src\LICENSE.txt
SetupIconFile=src\icon.ico
SetupIconFile=src\logo.ico
UninstallDisplayIcon={app}\logo.ico
Compression=lzma
SolidCompression=yes
PrivilegesRequired=admin
@ -42,9 +42,11 @@ Name: "{sd}\fotos"; \
[Files]
Source: "src\*"; \
DestDir: "{app}"; Flags: ignoreversion
Source: "src\icons\*"; \
Source: "icons\*"; \
DestDir: "{app}\icons"; Flags: ignoreversion
Source: "src\barcodex.ocx"; \
Source: "fonts\*"; \
DestDir: "{fonts}"; Flags: onlyifdoesntexist uninsneveruninstall
Source: "ocx\*"; \
DestDir: {sys}; Flags: onlyifdoesntexist regserver 32bit
[Tasks]
@ -55,13 +57,13 @@ Name: "desktopicon"; \
[Components]
Name: "tpv"; \
Description: "Terminal Punto Venta"; \
Types: full compact custom
Types: full compact
Name: "ent"; \
Description: "Entradas"; \
Types: full compact custom
Types: full compact
Name: "com"; \
Description: "Comparativa"; \
Types: full compact custom
Types: full compact
Name: "enc"; \
Description: "Encajado"; \
Types: full

Binary file not shown.

Before

Width:  |  Height:  |  Size: 19 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 19 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 19 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 19 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 19 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 50 KiB

View File

Before

Width:  |  Height:  |  Size: 141 KiB

After

Width:  |  Height:  |  Size: 141 KiB

View File

@ -13,9 +13,10 @@ var App =
{
appName: 'Verdnatura',
dsName: 'verdnatura',
dsPath: 'HKCU\\Software\\ODBC\\ODBC.INI\\verdnatura',
regPath: 'HKCU\\Software\\Verdnatura',
odbcPath: 'HKCU\\Software\\ODBC\\ODBC.INI\\verdnatura',
remoteUrl: 'https://www.verdnatura.es/download',
dbHost: 'db.verdnatura.es',
shell: new ActiveXObject ('WScript.Shell'),
fso: new ActiveXObject ('scripting.filesystemobject'),
@ -69,29 +70,55 @@ var App =
// Crea el ODBC de MySQL
var dsDriverPath = this.getEnv ('ProgramFiles')
var driverPath = this.getEnv ('ProgramFiles')
+'\\MySQL\\Connector ODBC 5.1\\myodbc5.dll';
this.regWrites (this.odbcPath, 'REG_SZ', {
'Driver' : dsDriverPath,
var params = {
'Driver' : driverPath,
'DESCRIPTION' : this.appName,
'SERVER' : 'db.verdnatura.es',
'SERVER' : this.dbHost,
'DATABASE' : 'vn2008',
'SSLCA' : this.appDir +'\\cacert.pem',
'SSLVERIFY' : 1,
'AUTO_RECONNECT' : 1
});
};
path = 'HKCU\\Software\\ODBC\\ODBC.INI\\ODBC Data Sources';
this.regWrite (path, this.dsName, 'Mysql ODBC 5.1 Driver', 'REG_SZ');
this.createOdbc (
this.dsName,
'Mysql ODBC 5.1 Driver',
params
);
// Crea el ODBC de PosgreSQL
var driverPath = this.getEnv ('ProgramFiles')
+'\\psqlODBC\\0804\\bin\\psqlodbc35w.dll';
var params = {
'Driver' : driverPath,
'DESCRIPTION' : this.appName,
'Servername' : this.dbHost,
'DATABASE' : 'vn',
'UID' : '',
'USERNAME' : '',
'PASSWORD' : ''
};
this.createOdbc (
'verdnaturapg',
'PostgreSQL Unicode',
params
);
// Marca la aplicación como configurada
this.regWrite (this.regPath, 'configured', 1, 'REG_DWORD');
}
// Carga los datos del formulario
var user = this.regRead (this.odbcPath, 'UID');
var password = this.regRead (this.odbcPath, 'PWD');
var user = this.regRead (this.dsPath, 'UID');
var password = this.regRead (this.dsPath, 'PWD');
var remember = this.regRead (this.regPath, 'remember');
if (user)
@ -107,6 +134,15 @@ var App =
this.reset ();
},
createOdbc: function (dsName, driverName, params)
{
var odbcPath = 'HKCU\\Software\\ODBC\\ODBC.INI\\';
this.regWrites (odbcPath + dsName, 'REG_SZ', params);
this.regWrite (odbcPath + 'ODBC Data Sources',
dsName, driverName, 'REG_SZ');
},
reset: function ()
{
this.$('user').focus ();
@ -163,8 +199,8 @@ var App =
if (!password || password === '')
throw new Error ('Introduce una contraseña');
this.regWrite (this.odbcPath, 'UID', user, 'REG_SZ');
this.regWrite (this.odbcPath, 'PWD', password, 'REG_SZ');
this.regWrite (this.dsPath, 'UID', user, 'REG_SZ');
this.regWrite (this.dsPath, 'PWD', password, 'REG_SZ');
// Obtiene la última versión usando la conexión ODBC de MySQL
@ -216,7 +252,7 @@ var App =
}
catch (e)
{
//this.regWrite (this.odbcPath, 'PWD', '', 'REG_SZ');
//this.regWrite (this.dsPath, 'PWD', '', 'REG_SZ');
this._disableUi (false);
this.reset ();
this.showMessage (e.message);