- Controladores: repaso a la visualización de editores => fallo con las llamadas a los 'Release'.

- Incremento de versión a 1.4.6


git-svn-id: https://192.168.0.254/svn/Proyectos.Tecsitel_FactuGES2/trunk@771 0c75b7a4-871f-7646-8a2f-f78d34cc349f
This commit is contained in:
David Arranz 2008-11-13 13:10:32 +00:00
parent 6d104b386c
commit 811bafd58b
68 changed files with 1561 additions and 1861 deletions

View File

@ -55,10 +55,10 @@
<DelphiCompile Include="ApplicationBase.dpk"> <DelphiCompile Include="ApplicationBase.dpk">
<MainSource>MainSource</MainSource> <MainSource>MainSource</MainSource>
</DelphiCompile> </DelphiCompile>
<DCCReference Include="..\Cliente\Base.dcp" /> <DCCReference Include="..\Modulos\Obras\Base.dcp" />
<DCCReference Include="..\Cliente\GUIBase.dcp" /> <DCCReference Include="..\Modulos\Obras\GUIBase.dcp" />
<DCCReference Include="..\Cliente\JvJansD11R.dcp" /> <DCCReference Include="..\Modulos\Obras\JvJansD11R.dcp" />
<DCCReference Include="..\Cliente\PluginSDK_D10R.dcp" /> <DCCReference Include="..\Modulos\Obras\PluginSDK_D10R.dcp" />
<DCCReference Include="Empresas\Controller\uDatosBancariosEmpresaController.pas" /> <DCCReference Include="Empresas\Controller\uDatosBancariosEmpresaController.pas" />
<DCCReference Include="Empresas\Controller\uEmpresasController.pas" /> <DCCReference Include="Empresas\Controller\uEmpresasController.pas" />
<DCCReference Include="Empresas\Controller\View\uIEditorDatosBancarioEmpresa.pas" /> <DCCReference Include="Empresas\Controller\View\uIEditorDatosBancarioEmpresa.pas" />

View File

@ -49,19 +49,16 @@ begin
AEditor := NIL; AEditor := NIL;
CreateEditor('EditorDatosBancariosEmpresa', IEditorDatosBancariosEmpresa, AEditor); CreateEditor('EditorDatosBancariosEmpresa', IEditorDatosBancariosEmpresa, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
begin
with AEditor do
begin begin
try try
DatosBancarios := ADatosBancarios; AEditor.DatosBancarios := ADatosBancarios;
Controller := Self; AEditor.Controller := Self;
ShowModal; AEditor.ShowModal;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end; end;
end;
end. end.

View File

@ -273,18 +273,15 @@ begin
AEditor := NIL; AEditor := NIL;
CreateEditor('EditorEmpresa', IEditorEmpresa, AEditor); CreateEditor('EditorEmpresa', IEditorEmpresa, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
Empresa := AEmpresa; AEditor.Empresa := AEmpresa;
Controller := Self; AEditor.Controller := Self;
ShowModal; AEditor.ShowModal;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
procedure TEmpresasController.VerTodos(AEmpresas: IBizEmpresa); procedure TEmpresasController.VerTodos(AEmpresas: IBizEmpresa);
{var {var
@ -292,23 +289,15 @@ procedure TEmpresasController.VerTodos(AEmpresas: IBizEmpresa);
begin begin
{ {
AEditor := NIL; AEditor := NIL;
ShowHourglassCursor;
try
CreateEditor('EditorEmpresas', IEditorClientes, AEditor); CreateEditor('EditorEmpresas', IEditorClientes, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
Contactos := AContactos; AEditor.Contactos := AContactos;
Controller := Self; AEditor.Controller := Self;
ShowModal; AEditor.ShowModal;
finally
Release;
end;
end;
finally finally
AEditor.Release;
AEditor := NIL; AEditor := NIL;
HideHourglassCursor;
end; end;
} }
end; end;

View File

@ -147,19 +147,16 @@ begin
APerfilesUsuario.Active := True; APerfilesUsuario.Active := True;
CreateEditor('EditorPerfilesUsuario', IEditorPerfilesUsuario, AEditor); CreateEditor('EditorPerfilesUsuario', IEditorPerfilesUsuario, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
begin
with (AEditor as IEditorPerfilesUsuario) do
begin begin
try try
Controller := Self; //OJO ORDEN MUY IMPORTANTE AEditor.Controller := Self; //OJO ORDEN MUY IMPORTANTE
PerfilesUsuario := APerfilesUsuario; AEditor.PerfilesUsuario := APerfilesUsuario;
ShowModal; AEditor.ShowModal;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
finally finally
APerfilesUsuario := NIL; APerfilesUsuario := NIL;
end; end;
@ -178,17 +175,14 @@ begin
FPerfil.Active := True; FPerfil.Active := True;
CreateEditor('EditorPerfilUsuario', IEditorPerfilUsuario, AEditor); CreateEditor('EditorPerfilUsuario', IEditorPerfilUsuario, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with (AEditor as IEditorPerfilUsuario) do
begin
try try
Controller := Self; //OJO ORDEN MUY IMPORTANTE AEditor.Controller := Self; //OJO ORDEN MUY IMPORTANTE
PerfilUsuario := FPerfil; AEditor.PerfilUsuario := FPerfil;
ShowModal; AEditor.ShowModal;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end;
finally finally
FPerfil := NIL; FPerfil := NIL;
end; end;
@ -207,14 +201,12 @@ begin
APerfilesUsuario.Active := True; APerfilesUsuario.Active := True;
CreateEditor('EditorPerfilesUsuario', IEditorPerfilesUsuario, AEditor); CreateEditor('EditorPerfilesUsuario', IEditorPerfilesUsuario, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with (AEditor as IEditorPerfilesUsuario) do
begin
try try
Controller := Self; //OJO ORDEN MUY IMPORTANTE AEditor.Controller := Self; //OJO ORDEN MUY IMPORTANTE
PerfilesUsuario := APerfilesUsuario; AEditor.PerfilesUsuario := APerfilesUsuario;
ShowModal; AEditor.ShowModal;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;

View File

@ -303,7 +303,7 @@ end;
function TUsuariosController.CambiarPassword(const AIDUser: Integer) : Boolean; function TUsuariosController.CambiarPassword(const AIDUser: Integer) : Boolean;
var var
AUser : IBizUsuario; AUser : IBizUsuario;
AEditorCambiar : TfEditorCambiarPassword; AEditor : TfEditorCambiarPassword;
begin begin
Result := False; Result := False;
AUser := FDataModule.GetUsuario(AIDUser); AUser := FDataModule.GetUsuario(AIDUser);
@ -311,18 +311,17 @@ begin
begin begin
AUser.Active := True; AUser.Active := True;
AEditorCambiar := TfEditorCambiarPassword.Create(NIL); AEditor := TfEditorCambiarPassword.Create(NIL);
with AEditorCambiar do
try try
Controller := Self; AEditor.Controller := Self;
Usuario := AUser; AEditor.Usuario := AUser;
CambioObligatorio := False; AEditor.CambioObligatorio := False;
if (Length(Trim(AUser.PASS)) = 0) then if (Length(Trim(AUser.PASS)) = 0) then
EditAtu.Enabled := False; AEditor.EditAtu.Enabled := False;
if (ShowModal = mrOk) then if (AEditor.ShowModal = mrOk) then
Result := CambiarPassword(AIDUser, EditNova.Text); Result := CambiarPassword(AIDUser, AEditor.EditNova.Text);
finally finally
Release; AEditor.Release;
AUser.Active := False; AUser.Active := False;
AUser := NIL; AUser := NIL;
end; end;
@ -760,20 +759,17 @@ begin
APerfil.Active := True; APerfil.Active := True;
CreateEditor('EditorPerfilUsuario', IEditorPerfilUsuario, AEditor); CreateEditor('EditorPerfilUsuario', IEditorPerfilUsuario, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
begin
with (AEditor as IEditorPerfilUsuario) do
begin begin
try try
Controller := Self; //OJO ORDEN MUY IMPORTANTE AEditor.Controller := Self; //OJO ORDEN MUY IMPORTANTE
PerfilUsuario := APerfil; AEditor.PerfilUsuario := APerfil;
ShowModal; AEditor.ShowModal;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end; end;
end;
procedure TUsuariosController.VerPerfiles; procedure TUsuariosController.VerPerfiles;
var var
@ -787,17 +783,14 @@ begin
APerfilesUsuario.Active := True; APerfilesUsuario.Active := True;
CreateEditor('EditorPerfilesUsuario', IEditorPerfilesUsuario, AEditor); CreateEditor('EditorPerfilesUsuario', IEditorPerfilesUsuario, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with (AEditor as IEditorPerfilesUsuario) do
begin
try try
Controller := Self; //OJO ORDEN MUY IMPORTANTE AEditor.Controller := Self; //OJO ORDEN MUY IMPORTANTE
PerfilesUsuario := APerfilesUsuario; AEditor.PerfilesUsuario := APerfilesUsuario;
ShowModal; AEditor.ShowModal;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end;
finally finally
APerfilesUsuario := NIL; APerfilesUsuario := NIL;
end; end;
@ -822,18 +815,15 @@ begin
AUser.Active := True; AUser.Active := True;
CreateEditor('EditorUsuario', IEditorUsuario, AEditor); CreateEditor('EditorUsuario', IEditorUsuario, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with (AEditor as IEditorUsuario) do
begin
try try
Controller := Self; //OJO ORDEN MUY IMPORTANTE AEditor.Controller := Self; //OJO ORDEN MUY IMPORTANTE
Usuario := AUser; AEditor.Usuario := AUser;
ShowModal; AEditor.ShowModal;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
procedure TUsuariosController.VerUsuarios; procedure TUsuariosController.VerUsuarios;
var var
@ -847,17 +837,14 @@ begin
try try
CreateEditor('EditorUsuarios', IEditorUsuarios, AEditor); CreateEditor('EditorUsuarios', IEditorUsuarios, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with (AEditor as IEditorUsuarios) do
begin
try try
Controller := Self; //OJO ORDEN MUY IMPORTANTE AEditor.Controller := Self; //OJO ORDEN MUY IMPORTANTE
Usuarios := FUsuarios; AEditor.Usuarios := FUsuarios;
ShowModal; AEditor.ShowModal;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end;
finally finally
FUsuarios := NIL; FUsuarios := NIL;
end; end;
@ -878,17 +865,14 @@ begin
CreateEditor('EditorLogin', IEditorLogin, AEditor); CreateEditor('EditorLogin', IEditorLogin, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
Controller := Self; AEditor.Controller := Self;
Result := (AEditor.ShowModal = mrOk); Result := (AEditor.ShowModal = mrOk);
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
procedure TUsuariosController.FiltrarEmpresa(AUsuario: IBizUsuario); procedure TUsuariosController.FiltrarEmpresa(AUsuario: IBizUsuario);
{var {var

View File

@ -54,57 +54,57 @@
<DelphiCompile Include="Base.dpk"> <DelphiCompile Include="Base.dpk">
<MainSource>MainSource</MainSource> <MainSource>MainSource</MainSource>
</DelphiCompile> </DelphiCompile>
<DCCReference Include="..\..\Output\Debug\Servidor\Informes\1\adortl.dcp" /> <DCCReference Include="..\Modulos\Obras\adortl.dcp" />
<DCCReference Include="..\..\Output\Debug\Servidor\Informes\1\cxDataD11.dcp" /> <DCCReference Include="..\Modulos\Obras\cxDataD11.dcp" />
<DCCReference Include="..\..\Output\Debug\Servidor\Informes\1\cxEditorsD11.dcp" /> <DCCReference Include="..\Modulos\Obras\cxEditorsD11.dcp" />
<DCCReference Include="..\..\Output\Debug\Servidor\Informes\1\cxExportD11.dcp" /> <DCCReference Include="..\Modulos\Obras\cxExportD11.dcp" />
<DCCReference Include="..\..\Output\Debug\Servidor\Informes\1\cxExtEditorsD11.dcp" /> <DCCReference Include="..\Modulos\Obras\cxExtEditorsD11.dcp" />
<DCCReference Include="..\..\Output\Debug\Servidor\Informes\1\cxGridD11.dcp" /> <DCCReference Include="..\Modulos\Obras\cxGridD11.dcp" />
<DCCReference Include="..\..\Output\Debug\Servidor\Informes\1\cxIntl6D11.dcp" /> <DCCReference Include="..\Modulos\Obras\cxIntl6D11.dcp" />
<DCCReference Include="..\..\Output\Debug\Servidor\Informes\1\cxIntlPrintSys3D11.dcp" /> <DCCReference Include="..\Modulos\Obras\cxIntlPrintSys3D11.dcp" />
<DCCReference Include="..\..\Output\Debug\Servidor\Informes\1\cxLibraryD11.dcp" /> <DCCReference Include="..\Modulos\Obras\cxLibraryD11.dcp" />
<DCCReference Include="..\..\Output\Debug\Servidor\Informes\1\cxPageControlD11.dcp" /> <DCCReference Include="..\Modulos\Obras\cxPageControlD11.dcp" />
<DCCReference Include="..\..\Output\Debug\Servidor\Informes\1\DataAbstract_Core_D11.dcp" /> <DCCReference Include="..\Modulos\Obras\DataAbstract_Core_D11.dcp" />
<DCCReference Include="..\..\Output\Debug\Servidor\Informes\1\dbrtl.dcp" /> <DCCReference Include="..\Modulos\Obras\dbrtl.dcp" />
<DCCReference Include="..\..\Output\Debug\Servidor\Informes\1\dclIndyCore.dcp" /> <DCCReference Include="..\Modulos\Obras\dclIndyCore.dcp" />
<DCCReference Include="..\..\Output\Debug\Servidor\Informes\1\designide.dcp" /> <DCCReference Include="..\Modulos\Obras\designide.dcp" />
<DCCReference Include="..\..\Output\Debug\Servidor\Informes\1\dsnap.dcp" /> <DCCReference Include="..\Modulos\Obras\dsnap.dcp" />
<DCCReference Include="..\..\Output\Debug\Servidor\Informes\1\dxGDIPlusD11.dcp" /> <DCCReference Include="..\Modulos\Obras\dxGDIPlusD11.dcp" />
<DCCReference Include="..\..\Output\Debug\Servidor\Informes\1\dxPSCoreD11.dcp" /> <DCCReference Include="..\Modulos\Obras\dxPSCoreD11.dcp" />
<DCCReference Include="..\..\Output\Debug\Servidor\Informes\1\dxThemeD11.dcp" /> <DCCReference Include="..\Modulos\Obras\dxThemeD11.dcp" />
<DCCReference Include="..\..\Output\Debug\Servidor\Informes\1\GUISDK_D11.dcp" /> <DCCReference Include="..\Modulos\Obras\GUISDK_D11.dcp" />
<DCCReference Include="..\..\Output\Debug\Servidor\Informes\1\IndyCore.dcp" /> <DCCReference Include="..\Modulos\Obras\IndyCore.dcp" />
<DCCReference Include="..\..\Output\Debug\Servidor\Informes\1\IndyProtocols.dcp" /> <DCCReference Include="..\Modulos\Obras\IndyProtocols.dcp" />
<DCCReference Include="..\..\Output\Debug\Servidor\Informes\1\IndySystem.dcp" /> <DCCReference Include="..\Modulos\Obras\IndySystem.dcp" />
<DCCReference Include="..\..\Output\Debug\Servidor\Informes\1\Jcl.dcp" /> <DCCReference Include="..\Modulos\Obras\Jcl.dcp" />
<DCCReference Include="..\..\Output\Debug\Servidor\Informes\1\JclVcl.dcp" /> <DCCReference Include="..\Modulos\Obras\JclVcl.dcp" />
<DCCReference Include="..\..\Output\Debug\Servidor\Informes\1\JSDialog100.dcp" /> <DCCReference Include="..\Modulos\Obras\JSDialog100.dcp" />
<DCCReference Include="..\..\Output\Debug\Servidor\Informes\1\JvCmpD11R.dcp" /> <DCCReference Include="..\Modulos\Obras\JvCmpD11R.dcp" />
<DCCReference Include="..\..\Output\Debug\Servidor\Informes\1\JvCoreD11R.dcp" /> <DCCReference Include="..\Modulos\Obras\JvCoreD11R.dcp" />
<DCCReference Include="..\..\Output\Debug\Servidor\Informes\1\JvCtrlsD11R.dcp" /> <DCCReference Include="..\Modulos\Obras\JvCtrlsD11R.dcp" />
<DCCReference Include="..\..\Output\Debug\Servidor\Informes\1\JvDlgsD11R.dcp" /> <DCCReference Include="..\Modulos\Obras\JvDlgsD11R.dcp" />
<DCCReference Include="..\..\Output\Debug\Servidor\Informes\1\JvMMD11R.dcp" /> <DCCReference Include="..\Modulos\Obras\JvMMD11R.dcp" />
<DCCReference Include="..\..\Output\Debug\Servidor\Informes\1\JvNetD11R.dcp" /> <DCCReference Include="..\Modulos\Obras\JvNetD11R.dcp" />
<DCCReference Include="..\..\Output\Debug\Servidor\Informes\1\JvPageCompsD11R.dcp" /> <DCCReference Include="..\Modulos\Obras\JvPageCompsD11R.dcp" />
<DCCReference Include="..\..\Output\Debug\Servidor\Informes\1\JvStdCtrlsD11R.dcp" /> <DCCReference Include="..\Modulos\Obras\JvStdCtrlsD11R.dcp" />
<DCCReference Include="..\..\Output\Debug\Servidor\Informes\1\JvSystemD11R.dcp" /> <DCCReference Include="..\Modulos\Obras\JvSystemD11R.dcp" />
<DCCReference Include="..\..\Output\Debug\Servidor\Informes\1\pckMD5.dcp" /> <DCCReference Include="..\Modulos\Obras\pckMD5.dcp" />
<DCCReference Include="..\..\Output\Debug\Servidor\Informes\1\pckUCDataConnector.dcp" /> <DCCReference Include="..\Modulos\Obras\pckUCDataConnector.dcp" />
<DCCReference Include="..\..\Output\Debug\Servidor\Informes\1\pckUserControl_RT.dcp" /> <DCCReference Include="..\Modulos\Obras\pckUserControl_RT.dcp" />
<DCCReference Include="..\..\Output\Debug\Servidor\Informes\1\PngComponentsD10.dcp" /> <DCCReference Include="..\Modulos\Obras\PngComponentsD10.dcp" />
<DCCReference Include="..\..\Output\Debug\Servidor\Informes\1\PNG_D10.dcp" /> <DCCReference Include="..\Modulos\Obras\PNG_D10.dcp" />
<DCCReference Include="..\..\Output\Debug\Servidor\Informes\1\RemObjects_Core_D11.dcp" /> <DCCReference Include="..\Modulos\Obras\RemObjects_Core_D11.dcp" />
<DCCReference Include="..\..\Output\Debug\Servidor\Informes\1\RemObjects_Indy_D11.dcp" /> <DCCReference Include="..\Modulos\Obras\RemObjects_Indy_D11.dcp" />
<DCCReference Include="..\..\Output\Debug\Servidor\Informes\1\rtl.dcp" /> <DCCReference Include="..\Modulos\Obras\rtl.dcp" />
<DCCReference Include="..\..\Output\Debug\Servidor\Informes\1\TB2k_D10.dcp" /> <DCCReference Include="..\Modulos\Obras\TB2k_D10.dcp" />
<DCCReference Include="..\..\Output\Debug\Servidor\Informes\1\tbx_d10.dcp" /> <DCCReference Include="..\Modulos\Obras\tbx_d10.dcp" />
<DCCReference Include="..\..\Output\Debug\Servidor\Informes\1\vcl.dcp" /> <DCCReference Include="..\Modulos\Obras\vcl.dcp" />
<DCCReference Include="..\..\Output\Debug\Servidor\Informes\1\vclactnband.dcp" /> <DCCReference Include="..\Modulos\Obras\vclactnband.dcp" />
<DCCReference Include="..\..\Output\Debug\Servidor\Informes\1\vcldb.dcp" /> <DCCReference Include="..\Modulos\Obras\vcldb.dcp" />
<DCCReference Include="..\..\Output\Debug\Servidor\Informes\1\vcljpg.dcp" /> <DCCReference Include="..\Modulos\Obras\vcljpg.dcp" />
<DCCReference Include="..\..\Output\Debug\Servidor\Informes\1\VclSmp.dcp" /> <DCCReference Include="..\Modulos\Obras\VclSmp.dcp" />
<DCCReference Include="..\..\Output\Debug\Servidor\Informes\1\vclx.dcp" /> <DCCReference Include="..\Modulos\Obras\vclx.dcp" />
<DCCReference Include="..\..\Output\Debug\Servidor\Informes\1\xmlrtl.dcp" /> <DCCReference Include="..\Modulos\Obras\xmlrtl.dcp" />
<DCCReference Include="..\Servicios\FactuGES_Intf.pas" /> <DCCReference Include="..\Servicios\FactuGES_Intf.pas" />
<DCCReference Include="Conexion\uConfigurarConexion.pas"> <DCCReference Include="Conexion\uConfigurarConexion.pas">
<Form>fConfigurarConexion</Form> <Form>fConfigurarConexion</Form>

Binary file not shown.

View File

@ -54,7 +54,7 @@
<Borland.Personality>Delphi.Personality</Borland.Personality> <Borland.Personality>Delphi.Personality</Borland.Personality>
<Borland.ProjectType>VCLApplication</Borland.ProjectType> <Borland.ProjectType>VCLApplication</Borland.ProjectType>
<BorlandProject> <BorlandProject>
<BorlandProject><Delphi.Personality><Parameters><Parameters Name="UseLauncher">False</Parameters><Parameters Name="LoadAllSymbols">True</Parameters><Parameters Name="LoadUnspecifiedSymbols">False</Parameters></Parameters><Language><Language Name="RootDir">C:\Archivos de programa\Borland\Delphi7\Bin\</Language></Language><VersionInfo><VersionInfo Name="IncludeVerInfo">True</VersionInfo><VersionInfo Name="AutoIncBuild">False</VersionInfo><VersionInfo Name="MajorVer">1</VersionInfo><VersionInfo Name="MinorVer">4</VersionInfo><VersionInfo Name="Release">5</VersionInfo><VersionInfo Name="Build">0</VersionInfo><VersionInfo Name="Debug">False</VersionInfo><VersionInfo Name="PreRelease">False</VersionInfo><VersionInfo Name="Special">False</VersionInfo><VersionInfo Name="Private">False</VersionInfo><VersionInfo Name="DLL">False</VersionInfo><VersionInfo Name="Locale">3082</VersionInfo><VersionInfo Name="CodePage">1252</VersionInfo></VersionInfo><VersionInfoKeys><VersionInfoKeys Name="CompanyName">Rodax Software S.L.</VersionInfoKeys><VersionInfoKeys Name="FileDescription"></VersionInfoKeys><VersionInfoKeys Name="FileVersion">1.4.5.0</VersionInfoKeys><VersionInfoKeys Name="InternalName">FactuGES</VersionInfoKeys><VersionInfoKeys Name="LegalCopyright"></VersionInfoKeys><VersionInfoKeys Name="LegalTrademarks"></VersionInfoKeys><VersionInfoKeys Name="OriginalFilename"></VersionInfoKeys><VersionInfoKeys Name="ProductName">FactuGES</VersionInfoKeys><VersionInfoKeys Name="ProductVersion">1.4.5.0</VersionInfoKeys><VersionInfoKeys Name="Comments"></VersionInfoKeys></VersionInfoKeys><Excluded_Packages> <BorlandProject><Delphi.Personality><Parameters><Parameters Name="UseLauncher">False</Parameters><Parameters Name="LoadAllSymbols">True</Parameters><Parameters Name="LoadUnspecifiedSymbols">False</Parameters></Parameters><Language><Language Name="RootDir">C:\Archivos de programa\Borland\Delphi7\Bin\</Language></Language><VersionInfo><VersionInfo Name="IncludeVerInfo">True</VersionInfo><VersionInfo Name="AutoIncBuild">False</VersionInfo><VersionInfo Name="MajorVer">1</VersionInfo><VersionInfo Name="MinorVer">4</VersionInfo><VersionInfo Name="Release">6</VersionInfo><VersionInfo Name="Build">0</VersionInfo><VersionInfo Name="Debug">False</VersionInfo><VersionInfo Name="PreRelease">False</VersionInfo><VersionInfo Name="Special">False</VersionInfo><VersionInfo Name="Private">False</VersionInfo><VersionInfo Name="DLL">False</VersionInfo><VersionInfo Name="Locale">3082</VersionInfo><VersionInfo Name="CodePage">1252</VersionInfo></VersionInfo><VersionInfoKeys><VersionInfoKeys Name="CompanyName">Rodax Software S.L.</VersionInfoKeys><VersionInfoKeys Name="FileDescription"></VersionInfoKeys><VersionInfoKeys Name="FileVersion">1.4.6.0</VersionInfoKeys><VersionInfoKeys Name="InternalName">FactuGES</VersionInfoKeys><VersionInfoKeys Name="LegalCopyright"></VersionInfoKeys><VersionInfoKeys Name="LegalTrademarks"></VersionInfoKeys><VersionInfoKeys Name="OriginalFilename"></VersionInfoKeys><VersionInfoKeys Name="ProductName">FactuGES</VersionInfoKeys><VersionInfoKeys Name="ProductVersion">1.4.6.0</VersionInfoKeys><VersionInfoKeys Name="Comments"></VersionInfoKeys></VersionInfoKeys><Excluded_Packages>

View File

@ -1,7 +1,7 @@
MAINICON ICON "C:\Codigo Tecsitel\Resources\Iconos\Factuges.ico" MAINICON ICON "C:\Codigo Tecsitel\Resources\Iconos\Factuges.ico"
1 VERSIONINFO 1 VERSIONINFO
FILEVERSION 1,4,5,0 FILEVERSION 1,4,6,0
PRODUCTVERSION 1,4,5,0 PRODUCTVERSION 1,4,6,0
FILEFLAGSMASK 0x3FL FILEFLAGSMASK 0x3FL
FILEFLAGS 0x00L FILEFLAGS 0x00L
FILEOS 0x40004L FILEOS 0x40004L
@ -13,10 +13,10 @@ BEGIN
BLOCK "0C0A04E4" BLOCK "0C0A04E4"
BEGIN BEGIN
VALUE "CompanyName", "Rodax Software S.L.\0" VALUE "CompanyName", "Rodax Software S.L.\0"
VALUE "FileVersion", "1.4.5.0\0" VALUE "FileVersion", "1.4.6.0\0"
VALUE "InternalName", "FactuGES\0" VALUE "InternalName", "FactuGES\0"
VALUE "ProductName", "FactuGES\0" VALUE "ProductName", "FactuGES\0"
VALUE "ProductVersion", "1.4.5.0\0" VALUE "ProductVersion", "1.4.6.0\0"
END END
END END
BLOCK "VarFileInfo" BLOCK "VarFileInfo"

Binary file not shown.

View File

@ -59,30 +59,30 @@
<DelphiCompile Include="GUIBase.dpk"> <DelphiCompile Include="GUIBase.dpk">
<MainSource>MainSource</MainSource> <MainSource>MainSource</MainSource>
</DelphiCompile> </DelphiCompile>
<DCCReference Include="..\Modulos\Presupuestos de cliente\Views\Base.dcp" /> <DCCReference Include="..\Modulos\Obras\Base.dcp" />
<DCCReference Include="..\Modulos\Presupuestos de cliente\Views\cxLibraryD11.dcp" /> <DCCReference Include="..\Modulos\Obras\cxLibraryD11.dcp" />
<DCCReference Include="..\Modulos\Presupuestos de cliente\Views\cxTreeListD11.dcp" /> <DCCReference Include="..\Modulos\Obras\cxTreeListD11.dcp" />
<DCCReference Include="..\Modulos\Presupuestos de cliente\Views\dbrtl.dcp" /> <DCCReference Include="..\Modulos\Obras\dbrtl.dcp" />
<DCCReference Include="..\Modulos\Presupuestos de cliente\Views\dxBarD11.dcp" /> <DCCReference Include="..\Modulos\Obras\dxBarD11.dcp" />
<DCCReference Include="..\Modulos\Presupuestos de cliente\Views\dxBarExtItemsD11.dcp" /> <DCCReference Include="..\Modulos\Obras\dxBarExtItemsD11.dcp" />
<DCCReference Include="..\Modulos\Presupuestos de cliente\Views\dxComnD11.dcp" /> <DCCReference Include="..\Modulos\Obras\dxComnD11.dcp" />
<DCCReference Include="..\Modulos\Presupuestos de cliente\Views\dxGDIPlusD11.dcp" /> <DCCReference Include="..\Modulos\Obras\dxGDIPlusD11.dcp" />
<DCCReference Include="..\Modulos\Presupuestos de cliente\Views\dxLayoutControlD11.dcp" /> <DCCReference Include="..\Modulos\Obras\dxLayoutControlD11.dcp" />
<DCCReference Include="..\Modulos\Presupuestos de cliente\Views\dxPSCoreD11.dcp" /> <DCCReference Include="..\Modulos\Obras\dxPSCoreD11.dcp" />
<DCCReference Include="..\Modulos\Presupuestos de cliente\Views\dxPScxCommonD11.dcp" /> <DCCReference Include="..\Modulos\Obras\dxPScxCommonD11.dcp" />
<DCCReference Include="..\Modulos\Presupuestos de cliente\Views\dxPScxGrid6LnkD11.dcp" /> <DCCReference Include="..\Modulos\Obras\dxPScxGrid6LnkD11.dcp" />
<DCCReference Include="..\Modulos\Presupuestos de cliente\Views\dxPsPrVwAdvD11.dcp" /> <DCCReference Include="..\Modulos\Obras\dxPsPrVwAdvD11.dcp" />
<DCCReference Include="..\Modulos\Presupuestos de cliente\Views\dxThemeD11.dcp" /> <DCCReference Include="..\Modulos\Obras\dxThemeD11.dcp" />
<DCCReference Include="..\Modulos\Presupuestos de cliente\Views\frx11.dcp" /> <DCCReference Include="..\Modulos\Obras\frx11.dcp" />
<DCCReference Include="..\Modulos\Presupuestos de cliente\Views\frxe11.dcp" /> <DCCReference Include="..\Modulos\Obras\frxe11.dcp" />
<DCCReference Include="..\Modulos\Presupuestos de cliente\Views\fs11.dcp" /> <DCCReference Include="..\Modulos\Obras\fs11.dcp" />
<DCCReference Include="..\Modulos\Presupuestos de cliente\Views\JvAppFrmD11R.dcp" /> <DCCReference Include="..\Modulos\Obras\JvAppFrmD11R.dcp" />
<DCCReference Include="..\Modulos\Presupuestos de cliente\Views\JvCtrlsD11R.dcp" /> <DCCReference Include="..\Modulos\Obras\JvCtrlsD11R.dcp" />
<DCCReference Include="..\Modulos\Presupuestos de cliente\Views\rtl.dcp" /> <DCCReference Include="..\Modulos\Obras\rtl.dcp" />
<DCCReference Include="..\Modulos\Presupuestos de cliente\Views\vcl.dcp" /> <DCCReference Include="..\Modulos\Obras\vcl.dcp" />
<DCCReference Include="..\Modulos\Presupuestos de cliente\Views\vcldb.dcp" /> <DCCReference Include="..\Modulos\Obras\vcldb.dcp" />
<DCCReference Include="..\Modulos\Presupuestos de cliente\Views\vcljpg.dcp" /> <DCCReference Include="..\Modulos\Obras\vcljpg.dcp" />
<DCCReference Include="..\Modulos\Presupuestos de cliente\Views\vclx.dcp" /> <DCCReference Include="..\Modulos\Obras\vclx.dcp" />
<DCCReference Include="uDialogBase.pas"> <DCCReference Include="uDialogBase.pas">
<Form>fDialogBase</Form> <Form>fDialogBase</Form>
</DCCReference> </DCCReference>

View File

@ -572,7 +572,7 @@ end;
procedure TAlbaranesClienteController.Ver(AAlbaran: IBizAlbaranCliente); procedure TAlbaranesClienteController.Ver(AAlbaran: IBizAlbaranCliente);
var var
AEditor : IEditorDBItem; AEditor : IEditorAlbaranCliente;
begin begin
AEditor := NIL; AEditor := NIL;
RecuperarObjetos(AAlbaran); RecuperarObjetos(AAlbaran);
@ -583,30 +583,27 @@ begin
CreateEditor('EditorAlbaranDevCliente', IEditorAlbaranDevCliente, AEditor); CreateEditor('EditorAlbaranDevCliente', IEditorAlbaranDevCliente, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with (AEditor as IEditorAlbaranCliente) do
begin
try try
//MODO CONSULTAR //MODO CONSULTAR
Controller := Self; //OJO ORDEN MUY IMPORTANTE AEditor.Controller := Self; //OJO ORDEN MUY IMPORTANTE
Albaran := AAlbaran; AEditor.Albaran := AAlbaran;
if not EsModificable(AAlbaran) then if not EsModificable(AAlbaran) then
begin begin
SetDataTableReadOnly(AAlbaran.DataTable, True); SetDataTableReadOnly(AAlbaran.DataTable, True);
ReadOnly := True; AEditor.ReadOnly := True;
end; end;
ShowModal; AEditor.ShowModal;
//MODO CONSULTAR (Se deja la tabla como estaba) //MODO CONSULTAR (Se deja la tabla como estaba)
if ReadOnly then if AEditor.ReadOnly then
SetDataTableReadOnly(AAlbaran.DataTable, False); SetDataTableReadOnly(AAlbaran.DataTable, False);
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
procedure TAlbaranesClienteController.VerDireccionEntrega( procedure TAlbaranesClienteController.VerDireccionEntrega(
AAlbaran: IBizAlbaranCliente); AAlbaran: IBizAlbaranCliente);
@ -618,17 +615,14 @@ begin
//RecuperarObjetos(AAlbaran); <- No descomentar. No hace falta //RecuperarObjetos(AAlbaran); <- No descomentar. No hace falta
CreateEditor('EditorDireccionEntregaAlbaranCliente', IEditorDireccionEntregaAlbaranCliente, AEditor); CreateEditor('EditorDireccionEntregaAlbaranCliente', IEditorDireccionEntregaAlbaranCliente, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with (AEditor as IEditorDireccionEntregaAlbaranCliente) do
begin
try try
Albaran := AAlbaran; AEditor.Albaran := AAlbaran;
ShowModal; AEditor.ShowModal;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
procedure TAlbaranesClienteController.VerTodosAlbaranes(AAlbarans: IBizAlbaranCliente; procedure TAlbaranesClienteController.VerTodosAlbaranes(AAlbarans: IBizAlbaranCliente;
const AVerModal : Boolean = False; const AWindowCaption: String = ''; const AVerModal : Boolean = False; const AWindowCaption: String = '';
@ -639,8 +633,6 @@ begin
AEditor := NIL; AEditor := NIL;
CreateEditor('EditorAlbaranesCliente', IEditorAlbaranesCliente, AEditor); CreateEditor('EditorAlbaranesCliente', IEditorAlbaranesCliente, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
if not EsCadenaVacia(AWindowCaption) then if not EsCadenaVacia(AWindowCaption) then
AEditor.WindowCaption := AWindowCaption; AEditor.WindowCaption := AWindowCaption;
@ -648,21 +640,20 @@ begin
if not EsCadenaVacia(AHeaderText) then if not EsCadenaVacia(AHeaderText) then
AEditor.HeaderText := AHeaderText; AEditor.HeaderText := AHeaderText;
Controller := Self; //OJO ORDEN MUY IMPORTANTE AEditor.Controller := Self; //OJO ORDEN MUY IMPORTANTE
Albaranes := AAlbarans; AEditor.Albaranes := AAlbarans;
MultiSelect := True; AEditor.MultiSelect := True;
if AVerModal then if AVerModal then
ShowModal AEditor.ShowModal
else else
ShowEmbedded; AEditor.ShowEmbedded;
finally finally
if AVerModal then if AVerModal then
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
procedure TAlbaranesClienteController.VerTodosAlbaranesDev(AAlbarans: IBizAlbaranCliente; procedure TAlbaranesClienteController.VerTodosAlbaranesDev(AAlbarans: IBizAlbaranCliente;
const AVerModal : Boolean = False; const AWindowCaption: String = ''; const AVerModal : Boolean = False; const AWindowCaption: String = '';
@ -673,8 +664,6 @@ begin
AEditor := NIL; AEditor := NIL;
CreateEditor('EditorAlbaranesDevCliente', IEditorAlbaranesDevCliente, AEditor); CreateEditor('EditorAlbaranesDevCliente', IEditorAlbaranesDevCliente, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
if not EsCadenaVacia(AWindowCaption) then if not EsCadenaVacia(AWindowCaption) then
AEditor.WindowCaption := AWindowCaption; AEditor.WindowCaption := AWindowCaption;
@ -682,21 +671,20 @@ begin
if not EsCadenaVacia(AHeaderText) then if not EsCadenaVacia(AHeaderText) then
AEditor.HeaderText := AHeaderText; AEditor.HeaderText := AHeaderText;
Controller := Self; //OJO ORDEN MUY IMPORTANTE AEditor.Controller := Self; //OJO ORDEN MUY IMPORTANTE
Albaranes := AAlbarans; AEditor.Albaranes := AAlbarans;
MultiSelect := True; AEditor.MultiSelect := True;
if AVerModal then if AVerModal then
ShowModal AEditor.ShowModal
else else
ShowEmbedded; AEditor.ShowEmbedded;
finally finally
if AVerModal then if AVerModal then
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
function TAlbaranesClienteController._Vacio: IBizAlbaranCliente; function TAlbaranesClienteController._Vacio: IBizAlbaranCliente;
begin begin
@ -723,21 +711,18 @@ begin
Result := NIL; Result := NIL;
CreateEditor('EditorElegirAlbaranesCliente', IEditorElegirAlbaranesCliente, AEditor); CreateEditor('EditorElegirAlbaranesCliente', IEditorElegirAlbaranesCliente, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
Controller := Self; AEditor.Controller := Self;
Albaranes := AAlbaran; AEditor.Albaranes := AAlbaran;
MultiSelect := AMultiSelect; AEditor.MultiSelect := AMultiSelect;
Mensaje := AMensaje; AEditor.Mensaje := AMensaje;
if IsPositiveResult(ShowModal) then if IsPositiveResult(AEditor.ShowModal) then
Result := AlbaranesClienteSeleccionados; Result := AEditor.AlbaranesClienteSeleccionados;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
function TAlbaranesClienteController.Eliminar(AAlbaran: IBizAlbaranCliente; AllItems: Boolean = false): Boolean; function TAlbaranesClienteController.Eliminar(AAlbaran: IBizAlbaranCliente; AllItems: Boolean = false): Boolean;
//En el caso de eliminar almenos un elemento del conjunto se devuelve true //En el caso de eliminar almenos un elemento del conjunto se devuelve true

View File

@ -74,14 +74,11 @@ begin
try try
CreateEditor('EditorAlbaranesClientePreview', IEditorAlbaranesClientePreview, AEditor); CreateEditor('EditorAlbaranesClientePreview', IEditorAlbaranesClientePreview, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
LoadFromStream(AStream); AEditor.LoadFromStream(AStream);
Preview; AEditor.Preview;
finally finally
Release; AEditor.Release;
end;
end; end;
finally finally
FreeAndNil(AStream); FreeAndNil(AStream);
@ -99,14 +96,11 @@ begin
try try
CreateEditor('EditorAlbaranesClientePreview', IEditorAlbaranesClientePreview, AEditor); CreateEditor('EditorAlbaranesClientePreview', IEditorAlbaranesClientePreview, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
LoadFromStream(AStream); AEditor.LoadFromStream(AStream);
Print; AEditor.Print;
finally finally
Release; AEditor.Release;
end;
end; end;
finally finally
FreeAndNil(AStream); FreeAndNil(AStream);

View File

@ -29,20 +29,17 @@ begin
Result := NIL; Result := NIL;
CreateEditor('EditorElegirArticulosAlbaranesCliente', IEditorElegirArticulosAlbaranesCliente, AEditor); CreateEditor('EditorElegirArticulosAlbaranesCliente', IEditorElegirArticulosAlbaranesCliente, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
Controller := Self; AEditor.Controller := Self;
Articulos := AArticulos; AEditor.Articulos := AArticulos;
MultiSelect := AMultiSelect; AEditor.MultiSelect := AMultiSelect;
Mensaje := AMensaje; AEditor.Mensaje := AMensaje;
if IsPositiveResult(ShowModal) then if IsPositiveResult(AEditor.ShowModal) then
Result := ArticulosSeleccionados; Result := AEditor.ArticulosSeleccionados;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
end. end.

View File

@ -653,7 +653,7 @@ end;
procedure TAlbaranesProveedorController.Ver(AAlbaran: IBizAlbaranProveedor); procedure TAlbaranesProveedorController.Ver(AAlbaran: IBizAlbaranProveedor);
var var
AEditor : IEditorDBItem; AEditor : IEditorAlbaranProveedor;
begin begin
AEditor := NIL; AEditor := NIL;
@ -665,30 +665,27 @@ begin
CreateEditor('EditorAlbaranDevProveedor', IEditorAlbaranDevProveedor, AEditor); CreateEditor('EditorAlbaranDevProveedor', IEditorAlbaranDevProveedor, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with (AEditor as IEditorAlbaranProveedor) do
begin
try try
Controller := Self; //OJO ORDEN MUY IMPORTANTE AEditor.Controller := Self; //OJO ORDEN MUY IMPORTANTE
Albaran := AAlbaran; AEditor.Albaran := AAlbaran;
//MODO CONSULTAR //MODO CONSULTAR
if not EsModificable(AAlbaran) then if not EsModificable(AAlbaran) then
begin begin
SetDataTableReadOnly(AAlbaran.DataTable, True); SetDataTableReadOnly(AAlbaran.DataTable, True);
ReadOnly := True; AEditor.ReadOnly := True;
end; end;
ShowModal; AEditor.ShowModal;
//MODO CONSULTAR (Se deja la tabla como estaba) //MODO CONSULTAR (Se deja la tabla como estaba)
if ReadOnly then if AEditor.ReadOnly then
SetDataTableReadOnly(AAlbaran.DataTable, False); SetDataTableReadOnly(AAlbaran.DataTable, False);
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
procedure TAlbaranesProveedorController.VerDireccionEntrega(AAlbaran: IBizAlbaranProveedor); procedure TAlbaranesProveedorController.VerDireccionEntrega(AAlbaran: IBizAlbaranProveedor);
var var
@ -698,17 +695,14 @@ begin
//RecuperarObjetos(AAlbaran); <- No descomentar. No hace falta //RecuperarObjetos(AAlbaran); <- No descomentar. No hace falta
CreateEditor('EditorDireccionEntregaAlbaranProveedor', IEditorDireccionEntregaAlbaranProveedor, AEditor); CreateEditor('EditorDireccionEntregaAlbaranProveedor', IEditorDireccionEntregaAlbaranProveedor, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with (AEditor as IEditorDireccionEntregaAlbaranProveedor) do
begin
try try
Albaran := AAlbaran; AEditor.Albaran := AAlbaran;
ShowModal; AEditor.ShowModal;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
procedure TAlbaranesProveedorController.VerTodosAlbaranes(AAlbarans: IBizAlbaranProveedor; procedure TAlbaranesProveedorController.VerTodosAlbaranes(AAlbarans: IBizAlbaranProveedor;
const AVerModal : Boolean = False; const AWindowCaption: String = ''; const AVerModal : Boolean = False; const AWindowCaption: String = '';
@ -719,8 +713,6 @@ begin
AEditor := NIL; AEditor := NIL;
CreateEditor('EditorAlbaranesProveedor', IEditorAlbaranesProveedor, AEditor); CreateEditor('EditorAlbaranesProveedor', IEditorAlbaranesProveedor, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
if not EsCadenaVacia(AWindowCaption) then if not EsCadenaVacia(AWindowCaption) then
AEditor.WindowCaption := AWindowCaption; AEditor.WindowCaption := AWindowCaption;
@ -728,20 +720,19 @@ begin
if not EsCadenaVacia(AHeaderText) then if not EsCadenaVacia(AHeaderText) then
AEditor.HeaderText := AHeaderText; AEditor.HeaderText := AHeaderText;
Controller := Self; //OJO ORDEN MUY IMPORTANTE AEditor.Controller := Self; //OJO ORDEN MUY IMPORTANTE
Albaranes := AAlbarans; AEditor.Albaranes := AAlbarans;
MultiSelect := True; AEditor.MultiSelect := True;
if AVerModal then if AVerModal then
ShowModal AEditor.ShowModal
else else
ShowEmbedded; AEditor.ShowEmbedded;
finally finally
if AVerModal then if AVerModal then
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
procedure TAlbaranesProveedorController.VerTodosAlbaranesDev(AAlbarans: IBizAlbaranProveedor; procedure TAlbaranesProveedorController.VerTodosAlbaranesDev(AAlbarans: IBizAlbaranProveedor;
const AVerModal : Boolean = False; const AWindowCaption: String = ''; const AVerModal : Boolean = False; const AWindowCaption: String = '';
@ -752,8 +743,6 @@ begin
AEditor := NIL; AEditor := NIL;
CreateEditor('EditorAlbaranesDevProveedor', IEditorAlbaranesDevProveedor, AEditor); CreateEditor('EditorAlbaranesDevProveedor', IEditorAlbaranesDevProveedor, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
if not EsCadenaVacia(AWindowCaption) then if not EsCadenaVacia(AWindowCaption) then
AEditor.WindowCaption := AWindowCaption; AEditor.WindowCaption := AWindowCaption;
@ -761,20 +750,19 @@ begin
if not EsCadenaVacia(AHeaderText) then if not EsCadenaVacia(AHeaderText) then
AEditor.HeaderText := AHeaderText; AEditor.HeaderText := AHeaderText;
Controller := Self; //OJO ORDEN MUY IMPORTANTE AEditor.Controller := Self; //OJO ORDEN MUY IMPORTANTE
Albaranes := AAlbarans; AEditor.Albaranes := AAlbarans;
MultiSelect := True; AEditor.MultiSelect := True;
if AVerModal then if AVerModal then
ShowModal AEditor.ShowModal
else else
ShowEmbedded; AEditor.ShowEmbedded;
finally finally
if AVerModal then if AVerModal then
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
function TAlbaranesProveedorController._Vacio: IBizAlbaranProveedor; function TAlbaranesProveedorController._Vacio: IBizAlbaranProveedor;
begin begin
@ -801,21 +789,18 @@ begin
Result := NIL; Result := NIL;
CreateEditor('EditorElegirAlbaranesProveedor', IEditorElegirAlbaranesProveedor, AEditor); CreateEditor('EditorElegirAlbaranesProveedor', IEditorElegirAlbaranesProveedor, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
Controller := Self; AEditor.Controller := Self;
Albaranes := AAlbaran; AEditor.Albaranes := AAlbaran;
MultiSelect := AMultiSelect; AEditor.MultiSelect := AMultiSelect;
Mensaje := AMensaje; AEditor.Mensaje := AMensaje;
if IsPositiveResult(ShowModal) then if IsPositiveResult(AEditor.ShowModal) then
Result := AlbaranesProveedorSeleccionados; Result := AEditor.AlbaranesProveedorSeleccionados;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
function TAlbaranesProveedorController.Eliminar(AAlbaran: IBizAlbaranProveedor; AllItems: Boolean = false): Boolean; function TAlbaranesProveedorController.Eliminar(AAlbaran: IBizAlbaranProveedor; AllItems: Boolean = false): Boolean;
//En el caso de eliminar almenos un elemento del conjunto se devuelve true //En el caso de eliminar almenos un elemento del conjunto se devuelve true

View File

@ -64,14 +64,11 @@ begin
try try
CreateEditor('EditorAlbaranesProveedorPreview', IEditorAlbaranesProveedorPreview, AEditor); CreateEditor('EditorAlbaranesProveedorPreview', IEditorAlbaranesProveedorPreview, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
LoadFromStream(AStream); AEditor.LoadFromStream(AStream);
Preview; AEditor.Preview;
finally finally
Release; AEditor.Release;
end;
end; end;
finally finally
FreeAndNil(AStream); FreeAndNil(AStream);
@ -91,14 +88,11 @@ begin
try try
CreateEditor('EditorAlbaranesProveedorPreview', IEditorAlbaranesProveedorPreview, AEditor); CreateEditor('EditorAlbaranesProveedorPreview', IEditorAlbaranesProveedorPreview, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
LoadFromStream(AStream); AEditor.LoadFromStream(AStream);
Print; AEditor.Print;
finally finally
Release; AEditor.Release;
end;
end; end;
finally finally
FreeAndNil(AStream); FreeAndNil(AStream);

View File

@ -29,21 +29,18 @@ begin
Result := NIL; Result := NIL;
CreateEditor('EditorElegirArticulosAlbaranesProveedor', IEditorElegirArticulosAlbaranesProveedor, AEditor); CreateEditor('EditorElegirArticulosAlbaranesProveedor', IEditorElegirArticulosAlbaranesProveedor, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
Controller := Self; AEditor.Controller := Self;
Articulos := AArticulos; AEditor.Articulos := AArticulos;
Proveedor := AProveedor; AEditor.Proveedor := AProveedor;
MultiSelect := AMultiSelect; AEditor.MultiSelect := AMultiSelect;
Mensaje := AMensaje; AEditor.Mensaje := AMensaje;
if IsPositiveResult(ShowModal) then if IsPositiveResult(AEditor.ShowModal) then
Result := ArticulosSeleccionados; Result := AEditor.ArticulosSeleccionados;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
end. end.

View File

@ -189,8 +189,6 @@ end;
function TAlmacenesController.ValidarAlmacen(AAlmacen: IBizAlmacen): Boolean; function TAlmacenesController.ValidarAlmacen(AAlmacen: IBizAlmacen): Boolean;
begin begin
Result := False;
if (AAlmacen.DataTable.State in dsEditModes) then if (AAlmacen.DataTable.State in dsEditModes) then
AAlmacen.DataTable.Post; AAlmacen.DataTable.Post;
@ -215,24 +213,21 @@ end;
procedure TAlmacenesController.Ver(AAlmacen: IBizAlmacen); procedure TAlmacenesController.Ver(AAlmacen: IBizAlmacen);
var var
AEditor : IEditorDBItem; AEditor : IEditorAlmacen;
begin begin
AEditor := NIL; AEditor := NIL;
RecuperarObjetos(AAlmacen); RecuperarObjetos(AAlmacen);
CreateEditor('EditorAlmacen', IEditorAlmacen, AEditor); CreateEditor('EditorAlmacen', IEditorAlmacen, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with (AEditor as IEditorAlmacen) do
begin
try try
Controller := Self; //OJO ORDEN MUY IMPORTANTE AEditor.Controller := Self; //OJO ORDEN MUY IMPORTANTE
Almacen := AAlmacen; AEditor.Almacen := AAlmacen;
ShowModal; AEditor.ShowModal;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
function TAlmacenesController.VerLista(AAlmacenes: IBizAlmacen): IBizAlmacen; function TAlmacenesController.VerLista(AAlmacenes: IBizAlmacen): IBizAlmacen;
var var
@ -243,18 +238,15 @@ begin
CreateEditor('EditorListaAlmacenes', IEditorListaAlmacenes, AEditor); CreateEditor('EditorListaAlmacenes', IEditorListaAlmacenes, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
Almacenes := AAlmacenes; AEditor.Almacenes := AAlmacenes;
if IsPositiveResult(ShowModal) then if IsPositiveResult(AEditor.ShowModal) then
Result := AlmacenSeleccionado; Result := AEditor.AlmacenSeleccionado;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
procedure TAlmacenesController.VerTodos(AAlmacenes: IBizAlmacen); procedure TAlmacenesController.VerTodos(AAlmacenes: IBizAlmacen);
var var

View File

@ -55,22 +55,22 @@
<DelphiCompile Include="Articulos_controller.dpk"> <DelphiCompile Include="Articulos_controller.dpk">
<MainSource>MainSource</MainSource> <MainSource>MainSource</MainSource>
</DelphiCompile> </DelphiCompile>
<DCCReference Include="..\..\Pedidos a proveedor\Controller\adortl.dcp" /> <DCCReference Include="..\adortl.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\Controller\Articulos_data.dcp" /> <DCCReference Include="..\Articulos_data.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\Controller\Articulos_model.dcp" /> <DCCReference Include="..\Articulos_model.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\Controller\Contactos_controller.dcp" /> <DCCReference Include="..\Contactos_controller.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\Controller\Contactos_model.dcp" /> <DCCReference Include="..\Contactos_model.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\Controller\cxLibraryD11.dcp" /> <DCCReference Include="..\cxLibraryD11.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\Controller\DataAbstract_Core_D11.dcp" /> <DCCReference Include="..\DataAbstract_Core_D11.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\Controller\dbrtl.dcp" /> <DCCReference Include="..\dbrtl.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\Controller\dsnap.dcp" /> <DCCReference Include="..\dsnap.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\Controller\dxGDIPlusD11.dcp" /> <DCCReference Include="..\dxGDIPlusD11.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\Controller\dxThemeD11.dcp" /> <DCCReference Include="..\dxThemeD11.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\Controller\GUIBase.dcp" /> <DCCReference Include="..\GUIBase.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\Controller\RemObjects_Core_D11.dcp" /> <DCCReference Include="..\RemObjects_Core_D11.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\Controller\rtl.dcp" /> <DCCReference Include="..\rtl.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\Controller\vcl.dcp" /> <DCCReference Include="..\vcl.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\Controller\vcldb.dcp" /> <DCCReference Include="..\vcldb.dcp" />
<DCCReference Include="uArticulosController.pas" /> <DCCReference Include="uArticulosController.pas" />
<DCCReference Include="uControllerDetallesArticulos.pas" /> <DCCReference Include="uControllerDetallesArticulos.pas" />
<DCCReference Include="View\uIEditorArticulo.pas" /> <DCCReference Include="View\uIEditorArticulo.pas" />

View File

@ -446,18 +446,15 @@ begin
CreateEditor('EditorArticulo', IEditorArticulo, AEditor); CreateEditor('EditorArticulo', IEditorArticulo, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with (AEditor as IEditorArticulo) do
begin
try try
Controller := Self; //OJO ORDEN MUY IMPORTANTE AEditor.Controller := Self; //OJO ORDEN MUY IMPORTANTE
Articulo := AArticulo; AEditor.Articulo := AArticulo;
ShowModal; AEditor.ShowModal;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
procedure TArticulosController.VerProveedor(AArticulo: IBizArticulo); procedure TArticulosController.VerProveedor(AArticulo: IBizArticulo);
var var
@ -519,21 +516,18 @@ begin
CreateEditor('EditorElegirArticulos', IEditorElegirArticulos, AEditor); CreateEditor('EditorElegirArticulos', IEditorElegirArticulos, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
Controller := Self; AEditor.Controller := Self;
Articulos := AArticulos; AEditor.Articulos := AArticulos;
MultiSelect := AMultiSelect; AEditor.MultiSelect := AMultiSelect;
Mensaje := AMensaje; AEditor.Mensaje := AMensaje;
if IsPositiveResult(ShowModal) then if IsPositiveResult(AEditor.ShowModal) then
Result := ArticulosSeleccionados; Result := AEditor.ArticulosSeleccionados;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
procedure TArticulosController.ElegirProveedor(AArticulo: IBizArticulo); procedure TArticulosController.ElegirProveedor(AArticulo: IBizArticulo);
var var

View File

@ -185,25 +185,22 @@ begin
CreateEditor('EditorExportacionNorma19', IEditorExportacionNorma19, AEditor); CreateEditor('EditorExportacionNorma19', IEditorExportacionNorma19, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
CodigoEntidad := Entidad; AEditor.CodigoEntidad := Entidad;
CodigoAgencia := Oficina; AEditor.CodigoAgencia := Oficina;
FechaCargo := AFechaCargo; AEditor.FechaCargo := AFechaCargo;
Fichero := AFileName; AEditor.Fichero := AFileName;
if (ShowModal = mrOk) then if (AEditor.ShowModal = mrOk) then
begin begin
Entidad := CodigoEntidad; AEditor.Entidad := CodigoEntidad;
Oficina := CodigoAgencia; AEditor.Oficina := CodigoAgencia;
AFechaCargo := FechaCargo; AFechaCargo := AEditor.FechaCargo;
AFileName := Fichero; AFileName := AEditor.Fichero;
Result := True; Result := True;
end; end;
finally finally
Release; AEditor.Release;
end;
end; end;
end; end;

View File

@ -149,7 +149,7 @@ begin
if IsPositiveResult(AEditor.ShowModal) then if IsPositiveResult(AEditor.ShowModal) then
Result := AEditor.DireccionSeleccionada; Result := AEditor.DireccionSeleccionada;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
Application.ProcessMessages; Application.ProcessMessages;
end; end;
@ -172,7 +172,7 @@ begin
if IsPositiveResult(AEditor.ShowModal) then if IsPositiveResult(AEditor.ShowModal) then
Result := AEditor.PersonaSeleccionada; Result := AEditor.PersonaSeleccionada;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
Application.ProcessMessages; Application.ProcessMessages;
end; end;
@ -391,18 +391,15 @@ begin
CreateEditor('EditorCliente', IEditorCliente, AEditor); CreateEditor('EditorCliente', IEditorCliente, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
Contacto := AContacto; AEditor.Contacto := AContacto;
Controller := Self; AEditor.Controller := Self;
ShowModal; AEditor.ShowModal;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
procedure TClientesController.VerAlbaranesDeCliente(ACliente: IBizCliente); procedure TClientesController.VerAlbaranesDeCliente(ACliente: IBizCliente);
var var

View File

@ -73,17 +73,14 @@ begin
CreateEditor('EditorDatoBancarioContacto', IEditorDatoBancarioContacto, AEditor); CreateEditor('EditorDatoBancarioContacto', IEditorDatoBancarioContacto, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
DatoBancario := ADatoBancario; AEditor.DatoBancario := ADatoBancario;
Controller := Self; AEditor.Controller := Self;
ShowModal; AEditor.ShowModal;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
end. end.

View File

@ -138,17 +138,14 @@ begin
CreateEditor('EditorDireccion', IEditorEditorDireccion, AEditor); CreateEditor('EditorDireccion', IEditorEditorDireccion, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
Direccion := ADireccion; AEditor.Direccion := ADireccion;
Controller := Self; AEditor.Controller := Self;
ShowModal; AEditor.ShowModal;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
end. end.

View File

@ -269,18 +269,15 @@ begin
CreateEditor('EditorEmpleado', IEditorEmpleado, AEditor); CreateEditor('EditorEmpleado', IEditorEmpleado, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
Contacto := AContacto; AEditor.Contacto := AContacto;
Controller := Self; AEditor.Controller := Self;
ShowModal; AEditor.ShowModal;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
procedure TEmpleadosController.VerTodos(AContactos: IBizContacto); procedure TEmpleadosController.VerTodos(AContactos: IBizContacto);
var var

View File

@ -143,18 +143,15 @@ begin
CreateEditor('EditorGruposCliente', IEditorGruposCliente, AEditor); CreateEditor('EditorGruposCliente', IEditorGruposCliente, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
Controller := Self; //OJO ORDEN MUY IMPORTANTE AEditor.Controller := Self; //OJO ORDEN MUY IMPORTANTE
GruposCliente := AGruposCliente; AEditor.GruposCliente := AGruposCliente;
ShowModal; AEditor.ShowModal;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
function TGruposClienteController.Eliminar(AGrupoCliente: IBizGrupoCliente): Boolean; function TGruposClienteController.Eliminar(AGrupoCliente: IBizGrupoCliente): Boolean;
begin begin

View File

@ -143,18 +143,15 @@ begin
CreateEditor('EditorGruposEmpleado', IEditorGruposEmpleado, AEditor); CreateEditor('EditorGruposEmpleado', IEditorGruposEmpleado, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
Controller := Self; //OJO ORDEN MUY IMPORTANTE AEditor.Controller := Self; //OJO ORDEN MUY IMPORTANTE
GruposEmpleado := AGruposEmpleado; AEditor.GruposEmpleado := AGruposEmpleado;
ShowModal; AEditor.ShowModal;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
function TGruposEmpleadoController.Eliminar(AGrupoEmpleado: IBizGrupoEmpleado): Boolean; function TGruposEmpleadoController.Eliminar(AGrupoEmpleado: IBizGrupoEmpleado): Boolean;
begin begin

View File

@ -143,18 +143,15 @@ begin
CreateEditor('EditorGruposProveedor', IEditorGruposProveedor, AEditor); CreateEditor('EditorGruposProveedor', IEditorGruposProveedor, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
Controller := Self; //OJO ORDEN MUY IMPORTANTE AEditor.Controller := Self; //OJO ORDEN MUY IMPORTANTE
GruposProveedor := AGruposProveedor; AEditor.GruposProveedor := AGruposProveedor;
ShowModal; AEditor.ShowModal;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
function TGruposProveedorController.Eliminar(AGrupoProveedor: IBizGrupoProveedor): Boolean; function TGruposProveedorController.Eliminar(AGrupoProveedor: IBizGrupoProveedor): Boolean;
begin begin

View File

@ -72,15 +72,12 @@ begin
CreateEditor('EditorPersonalContacto', IEditorPersonalContacto, AEditor); CreateEditor('EditorPersonalContacto', IEditorPersonalContacto, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
Personal := APersonal; AEditor.Personal := APersonal;
Controller := Self; AEditor.Controller := Self;
ShowModal; AEditor.ShowModal;
finally finally
Release; AEditor.Release;
end;
end; end;
end; end;

View File

@ -124,21 +124,18 @@ begin
CreateEditor('EditorElegirProveedores', IEditorElegirProveedores, AEditor); CreateEditor('EditorElegirProveedores', IEditorElegirProveedores, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
Contactos := AContactos; AEditor.Contactos := AContactos;
Controller := Self; AEditor.Controller := Self;
MultiSelect := AMultiSelect; AEditor.MultiSelect := AMultiSelect;
Mensaje := AMensaje; AEditor.Mensaje := AMensaje;
if IsPositiveResult(ShowModal) then if IsPositiveResult(AEditor.ShowModal) then
Result := ContactosSeleccionados; Result := AEditor.ContactosSeleccionados;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
function TProveedoresController.ElegirDireccionEntrega(AProveedor: IBizProveedor; function TProveedoresController.ElegirDireccionEntrega(AProveedor: IBizProveedor;
AMensaje: String): IBizDireccionesContacto; AMensaje: String): IBizDireccionesContacto;
@ -149,19 +146,16 @@ begin
CreateEditor('EditorElegirDireccionEntrega', IEditorElegirDireccionEntrega, AEditor); CreateEditor('EditorElegirDireccionEntrega', IEditorElegirDireccionEntrega, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
Contacto := AProveedor; AEditor.Contacto := AProveedor;
Mensaje := AMensaje; AEditor.Mensaje := AMensaje;
if IsPositiveResult(ShowModal) then if IsPositiveResult(AEditor.ShowModal) then
Result := DireccionSeleccionada; Result := AEditor.DireccionSeleccionada;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
function TProveedoresController.Eliminar(AProveedor: IBizContacto; AllItems: Boolean): Boolean; function TProveedoresController.Eliminar(AProveedor: IBizContacto; AllItems: Boolean): Boolean;
//En el caso de eliminar almenos un elemento del conjunto se devuelve true //En el caso de eliminar almenos un elemento del conjunto se devuelve true
@ -315,18 +309,15 @@ begin
CreateEditor('EditorProveedor', IEditorProveedor, AEditor); CreateEditor('EditorProveedor', IEditorProveedor, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
Contacto := AContacto; AEditor.Contacto := AContacto;
Controller := Self; AEditor.Controller := Self;
ShowModal; AEditor.ShowModal;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
procedure TProveedoresController.VerAlbaranesDeProveedor( procedure TProveedoresController.VerAlbaranesDeProveedor(
AProveedor: IBizProveedor); AProveedor: IBizProveedor);

View File

@ -49,52 +49,52 @@
<DelphiCompile Include="Contactos_view.dpk"> <DelphiCompile Include="Contactos_view.dpk">
<MainSource>MainSource</MainSource> <MainSource>MainSource</MainSource>
</DelphiCompile> </DelphiCompile>
<DCCReference Include="..\..\Pedidos a proveedor\adortl.dcp" /> <DCCReference Include="..\..\Obras\adortl.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\ApplicationBase.dcp" /> <DCCReference Include="..\..\Obras\ApplicationBase.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\Base.dcp" /> <DCCReference Include="..\..\Obras\Base.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\bdertl.dcp" /> <DCCReference Include="..\..\Obras\bdertl.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\ccpackD11.dcp" /> <DCCReference Include="..\..\Obras\ccpackD11.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\cfpack_d11.dcp" /> <DCCReference Include="..\..\Obras\cfpack_d11.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\Contactos_controller.dcp" /> <DCCReference Include="..\..\Obras\Contactos_controller.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\Contactos_model.dcp" /> <DCCReference Include="..\..\Obras\Contactos_model.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\cxDataD11.dcp" /> <DCCReference Include="..\..\Obras\cxDataD11.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\cxEditorsD11.dcp" /> <DCCReference Include="..\..\Obras\cxEditorsD11.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\cxExportD11.dcp" /> <DCCReference Include="..\..\Obras\cxExportD11.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\cxExtEditorsD11.dcp" /> <DCCReference Include="..\..\Obras\cxExtEditorsD11.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\cxGridD11.dcp" /> <DCCReference Include="..\..\Obras\cxGridD11.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\cxLibraryD11.dcp" /> <DCCReference Include="..\..\Obras\cxLibraryD11.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\cxPageControlD11.dcp" /> <DCCReference Include="..\..\Obras\cxPageControlD11.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\DataAbstract_Core_D11.dcp" /> <DCCReference Include="..\..\Obras\DataAbstract_Core_D11.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\dbrtl.dcp" /> <DCCReference Include="..\..\Obras\dbrtl.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\designide.dcp" /> <DCCReference Include="..\..\Obras\designide.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\dsnap.dcp" /> <DCCReference Include="..\..\Obras\dsnap.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\dxComnD11.dcp" /> <DCCReference Include="..\..\Obras\dxComnD11.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\dxGDIPlusD11.dcp" /> <DCCReference Include="..\..\Obras\dxGDIPlusD11.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\dxLayoutControlD11.dcp" /> <DCCReference Include="..\..\Obras\dxLayoutControlD11.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\dxThemeD11.dcp" /> <DCCReference Include="..\..\Obras\dxThemeD11.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\FormasPago_controller.dcp" /> <DCCReference Include="..\..\Obras\FormasPago_controller.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\FormasPago_model.dcp" /> <DCCReference Include="..\..\Obras\FormasPago_model.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\GUIBase.dcp" /> <DCCReference Include="..\..\Obras\GUIBase.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\GUISDK_D11.dcp" /> <DCCReference Include="..\..\Obras\GUISDK_D11.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\Jcl.dcp" /> <DCCReference Include="..\..\Obras\Jcl.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\JclVcl.dcp" /> <DCCReference Include="..\..\Obras\JclVcl.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\JvCoreD11R.dcp" /> <DCCReference Include="..\..\Obras\JvCoreD11R.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\JvCtrlsD11R.dcp" /> <DCCReference Include="..\..\Obras\JvCtrlsD11R.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\JvGlobusD11R.dcp" /> <DCCReference Include="..\..\Obras\JvGlobusD11R.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\JvStdCtrlsD11R.dcp" /> <DCCReference Include="..\..\Obras\JvStdCtrlsD11R.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\JvSystemD11R.dcp" /> <DCCReference Include="..\..\Obras\JvSystemD11R.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\PngComponentsD10.dcp" /> <DCCReference Include="..\..\Obras\PngComponentsD10.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\PNG_D10.dcp" /> <DCCReference Include="..\..\Obras\PNG_D10.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\RemObjects_Core_D11.dcp" /> <DCCReference Include="..\..\Obras\RemObjects_Core_D11.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\rtl.dcp" /> <DCCReference Include="..\..\Obras\rtl.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\TiposIVA_controller.dcp" /> <DCCReference Include="..\..\Obras\TiposIVA_controller.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\TiposIVA_model.dcp" /> <DCCReference Include="..\..\Obras\TiposIVA_model.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\vcl.dcp" /> <DCCReference Include="..\..\Obras\vcl.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\vclactnband.dcp" /> <DCCReference Include="..\..\Obras\vclactnband.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\vcldb.dcp" /> <DCCReference Include="..\..\Obras\vcldb.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\vcljpg.dcp" /> <DCCReference Include="..\..\Obras\vcljpg.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\vclx.dcp" /> <DCCReference Include="..\..\Obras\vclx.dcp" />
<DCCReference Include="..\..\Pedidos a proveedor\xmlrtl.dcp" /> <DCCReference Include="..\..\Obras\xmlrtl.dcp" />
<DCCReference Include="uContactosViewRegister.pas" /> <DCCReference Include="uContactosViewRegister.pas" />
<DCCReference Include="uEditorCliente.pas"> <DCCReference Include="uEditorCliente.pas">
<Form>fEditorCliente</Form> <Form>fEditorCliente</Form>

View File

@ -155,18 +155,15 @@ begin
CreateEditor('EditorFabricantes', IEditorFabricantes, AEditor); CreateEditor('EditorFabricantes', IEditorFabricantes, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
Controller := Self; //OJO ORDEN MUY IMPORTANTE AEditor.Controller := Self; //OJO ORDEN MUY IMPORTANTE
Fabricantes := AFabricantes; AEditor.Fabricantes := AFabricantes;
ShowModal; AEditor.ShowModal;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
function TFabricantesController.Eliminar(AFabricante: IBizFabricante): Boolean; function TFabricantesController.Eliminar(AFabricante: IBizFabricante): Boolean;
begin begin

View File

@ -30,20 +30,17 @@ begin
CreateEditor('EditorElegirArticulosFacturaCliente', IEditorElegirArticulosFacturasCliente, AEditor); CreateEditor('EditorElegirArticulosFacturaCliente', IEditorElegirArticulosFacturasCliente, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
Controller := Self; AEditor.Controller := Self;
Articulos := AArticulos; AEditor.Articulos := AArticulos;
MultiSelect := AMultiSelect; AEditor.MultiSelect := AMultiSelect;
Mensaje := AMensaje; AEditor.Mensaje := AMensaje;
if IsPositiveResult(ShowModal) then if IsPositiveResult(AEditor.ShowModal) then
Result := ArticulosSeleccionados; Result := AEditor.ArticulosSeleccionados;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
end. end.

View File

@ -615,30 +615,27 @@ begin
CreateEditor('EditorFacturaCliente', IEditorFacturaCliente, AEditor); CreateEditor('EditorFacturaCliente', IEditorFacturaCliente, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
Controller := Self; //OJO ORDEN MUY IMPORTANTE AEditor.Controller := Self; //OJO ORDEN MUY IMPORTANTE
Factura := AFactura; AEditor.Factura := AFactura;
//MODO CONSULTAR //MODO CONSULTAR
if not EsModificable(AFactura) then if not EsModificable(AFactura) then
begin begin
SetDataTableReadOnly(AFactura.DataTable, True); SetDataTableReadOnly(AFactura.DataTable, True);
ReadOnly := True; AEditor.ReadOnly := True;
end; end;
ShowModal; AEditor.ShowModal;
//MODO CONSULTAR (Se deja la tabla como estaba) //MODO CONSULTAR (Se deja la tabla como estaba)
if ReadOnly then if AEditor.ReadOnly then
SetDataTableReadOnly(AFactura.DataTable, False); SetDataTableReadOnly(AFactura.DataTable, False);
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
procedure TFacturasClienteController.VerTodos(AFacturas: IBizFacturaCliente; procedure TFacturasClienteController.VerTodos(AFacturas: IBizFacturaCliente;
const AVerModal : Boolean = False; const AWindowCaption: String = ''; const AVerModal : Boolean = False; const AWindowCaption: String = '';
@ -650,8 +647,6 @@ begin
CreateEditor('EditorFacturasCliente', IEditorFacturasCliente, AEditor); CreateEditor('EditorFacturasCliente', IEditorFacturasCliente, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
if not EsCadenaVacia(AWindowCaption) then if not EsCadenaVacia(AWindowCaption) then
AEditor.WindowCaption := AWindowCaption; AEditor.WindowCaption := AWindowCaption;
@ -659,20 +654,19 @@ begin
if not EsCadenaVacia(AHeaderText) then if not EsCadenaVacia(AHeaderText) then
AEditor.HeaderText := AHeaderText; AEditor.HeaderText := AHeaderText;
Controller := Self; //OJO ORDEN MUY IMPORTANTE AEditor.Controller := Self; //OJO ORDEN MUY IMPORTANTE
Facturas := AFacturas; AEditor.Facturas := AFacturas;
MultiSelect := True; AEditor.MultiSelect := True;
if AVerModal then if AVerModal then
ShowModal AEditor.ShowModal
else else
ShowEmbedded; AEditor.ShowEmbedded;
finally finally
if AVerModal then if AVerModal then
Release; AEditor.Release;
AEditor := Nil; AEditor := Nil;
end; end;
end; end;
end;
function TFacturasClienteController._Vacio: IBizFacturaCliente; function TFacturasClienteController._Vacio: IBizFacturaCliente;
begin begin
@ -701,21 +695,18 @@ begin
CreateEditor('EditorElegirFacturasCliente', IEditorElegirFacturasCliente, AEditor); CreateEditor('EditorElegirFacturasCliente', IEditorElegirFacturasCliente, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
Controller := Self; AEditor.Controller := Self;
Facturas := AFacturas; AEditor.Facturas := AFacturas;
MultiSelect := AMultiSelect; AEditor.MultiSelect := AMultiSelect;
Mensaje := AMensaje; AEditor.Mensaje := AMensaje;
if IsPositiveResult(ShowModal) then if IsPositiveResult(AEditor.ShowModal) then
Result := FacturasClienteSeleccionados; Result := AEditor.FacturasClienteSeleccionados;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
function TFacturasClienteController.Eliminar(AFactura: IBizFacturaCliente; AllItems: Boolean = false): Boolean; function TFacturasClienteController.Eliminar(AFactura: IBizFacturaCliente; AllItems: Boolean = false): Boolean;
//En el caso de eliminar almenos un elemento del conjunto se devuelve true //En el caso de eliminar almenos un elemento del conjunto se devuelve true

View File

@ -119,16 +119,13 @@ begin
try try
CreateEditor('EditorFacturasClientePreview', IEditorFacturasClientePreview, AEditor); CreateEditor('EditorFacturasClientePreview', IEditorFacturasClientePreview, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
AEditor.Controller := Self; AEditor.Controller := Self;
ListaID := AListaID; AEditor.ListaID := AListaID;
LoadFromStream(AStream); AEditor.LoadFromStream(AStream);
Preview; AEditor.Preview;
finally finally
Release; AEditor.Release;
end;
end; end;
finally finally
FreeAndNil(AStream); FreeAndNil(AStream);
@ -148,15 +145,12 @@ begin
try try
CreateEditor('EditorFacturasClientePreview', IEditorFacturasClientePreview, AEditor); CreateEditor('EditorFacturasClientePreview', IEditorFacturasClientePreview, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
AEditor.Controller := Self; AEditor.Controller := Self;
LoadFromStream(AStream); AEditor.LoadFromStream(AStream);
Print; AEditor.Print;
finally finally
Release; AEditor.Release;
end;
end; end;
finally finally
FreeAndNil(AStream); FreeAndNil(AStream);

View File

@ -31,21 +31,18 @@ begin
CreateEditor('EditorElegirArticulosFacturaProveedor', IEditorElegirArticulosFacturasProveedor, AEditor); CreateEditor('EditorElegirArticulosFacturaProveedor', IEditorElegirArticulosFacturasProveedor, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
Controller := Self; AEditor.Controller := Self;
Articulos := AArticulos; AEditor.Articulos := AArticulos;
Proveedor := AProveedor; AEditor.Proveedor := AProveedor;
MultiSelect := AMultiSelect; AEditor.MultiSelect := AMultiSelect;
Mensaje := AMensaje; AEditor.Mensaje := AMensaje;
if IsPositiveResult(ShowModal) then if IsPositiveResult(AEditor.ShowModal) then
Result := ArticulosSeleccionados; Result := AEditor.ArticulosSeleccionados;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
end. end.

View File

@ -468,30 +468,27 @@ begin
CreateEditor('EditorFacturaProveedor', IEditorFacturaProveedor, AEditor); CreateEditor('EditorFacturaProveedor', IEditorFacturaProveedor, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
Controller := Self; //OJO ORDEN MUY IMPORTANTE AEditor.Controller := Self; //OJO ORDEN MUY IMPORTANTE
Factura := AFactura; AEditor.Factura := AFactura;
//MODO CONSULTAR //MODO CONSULTAR
if not EsModificable(AFactura) then if not EsModificable(AFactura) then
begin begin
SetDataTableReadOnly(AFactura.DataTable, True); SetDataTableReadOnly(AFactura.DataTable, True);
ReadOnly := True; AEditor.ReadOnly := True;
end; end;
ShowModal; AEditor.ShowModal;
//MODO CONSULTAR (Se deja la tabla como estaba) //MODO CONSULTAR (Se deja la tabla como estaba)
if ReadOnly then if AEditor.ReadOnly then
SetDataTableReadOnly(AFactura.DataTable, False); SetDataTableReadOnly(AFactura.DataTable, False);
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
procedure TFacturasProveedorController.VerTodos(AFacturas: IBizFacturaProveedor; procedure TFacturasProveedorController.VerTodos(AFacturas: IBizFacturaProveedor;
const AVerModal : Boolean = False; const AWindowCaption: String = ''; const AVerModal : Boolean = False; const AWindowCaption: String = '';
@ -502,8 +499,6 @@ begin
AEditor := NIL; AEditor := NIL;
CreateEditor('EditorFacturasProveedor', IEditorFacturasProveedor, AEditor); CreateEditor('EditorFacturasProveedor', IEditorFacturasProveedor, AEditor);
with AEditor do
begin
try try
if not EsCadenaVacia(AWindowCaption) then if not EsCadenaVacia(AWindowCaption) then
AEditor.WindowCaption := AWindowCaption; AEditor.WindowCaption := AWindowCaption;
@ -511,20 +506,19 @@ begin
if not EsCadenaVacia(AHeaderText) then if not EsCadenaVacia(AHeaderText) then
AEditor.HeaderText := AHeaderText; AEditor.HeaderText := AHeaderText;
Controller := Self; //OJO ORDEN MUY IMPORTANTE AEditor.Controller := Self; //OJO ORDEN MUY IMPORTANTE
Facturas := AFacturas; AEditor.Facturas := AFacturas;
MultiSelect := True; AEditor.MultiSelect := True;
if AVerModal then if AVerModal then
ShowModal AEditor.ShowModal
else else
ShowEmbedded; AEditor.ShowEmbedded;
finally finally
if AVerModal then if AVerModal then
Release; AEditor.Release;
AEditor := Nil; AEditor := Nil;
end; end;
end; end;
end;
function TFacturasProveedorController._Vacio: IBizFacturaProveedor; function TFacturasProveedorController._Vacio: IBizFacturaProveedor;
begin begin
@ -563,7 +557,7 @@ begin
if IsPositiveResult(ShowModal) then if IsPositiveResult(ShowModal) then
Result := FacturasProveedoreSeleccionados; Result := FacturasProveedoreSeleccionados;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;

View File

@ -64,14 +64,11 @@ begin
try try
CreateEditor('EditorFacturasProveedorPreview', IEditorFacturasProveedorPreview, AEditor); CreateEditor('EditorFacturasProveedorPreview', IEditorFacturasProveedorPreview, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
LoadFromStream(AStream); AEditor.LoadFromStream(AStream);
Preview; AEditor.Preview;
finally finally
Release; AEditor.Release;
end;
end; end;
finally finally
FreeAndNil(AStream); FreeAndNil(AStream);
@ -92,14 +89,11 @@ begin
try try
CreateEditor('EditorFacturasProveedorPreview', IEditorFacturasProveedorPreview, AEditor); CreateEditor('EditorFacturasProveedorPreview', IEditorFacturasProveedorPreview, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
LoadFromStream(AStream); AEditor.LoadFromStream(AStream);
Print; AEditor.Print;
finally finally
Release; AEditor.Release;
end;
end; end;
finally finally
FreeAndNil(AStream); FreeAndNil(AStream);

View File

@ -148,18 +148,15 @@ begin
CreateEditor('EditorFamilias', IEditorFamilias, AEditor); CreateEditor('EditorFamilias', IEditorFamilias, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
Controller := Self; //OJO ORDEN MUY IMPORTANTE AEditor.Controller := Self; //OJO ORDEN MUY IMPORTANTE
Familias := AFamilias; AEditor.Familias := AFamilias;
ShowModal; AEditor.ShowModal;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
function TFamiliasController.Eliminar(AFamilia: IBizFamilia): Boolean; function TFamiliasController.Eliminar(AFamilia: IBizFamilia): Boolean;
begin begin

View File

@ -181,17 +181,14 @@ begin
CreateEditor('EditorFormaPago', IEditorFormaPago, AEditor); CreateEditor('EditorFormaPago', IEditorFormaPago, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
FormaPago := AFormaPago; AEditor.FormaPago := AFormaPago;
ShowModal; AEditor.ShowModal;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
procedure TFormasPagoController.VerTodos(AFormasPago: IBizFormaPago); procedure TFormasPagoController.VerTodos(AFormasPago: IBizFormaPago);
var var
@ -201,17 +198,14 @@ begin
CreateEditor('EditorFormasPago', IEditorFormasPago, AEditor); CreateEditor('EditorFormasPago', IEditorFormasPago, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
FormasPago := AFormasPago; AEditor.FormasPago := AFormasPago;
ShowModal; AEditor.ShowModal;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
function TFormasPagoController.Eliminar(AFormaPago: IBizFormaPago): Boolean; function TFormasPagoController.Eliminar(AFormaPago: IBizFormaPago): Boolean;
begin begin

View File

@ -283,21 +283,20 @@ begin
AEditor := NIL; AEditor := NIL;
CreateEditor('EditorInformeIVAClientesReport', IEditorInformeIVAClientesReport, AEditor); CreateEditor('EditorInformeIVAClientesReport', IEditorInformeIVAClientesReport, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
AEditor.Controller := Self; AEditor.Controller := Self;
AEditor.Title := 'Listado de IVA de facturas de cliente'; AEditor.Title := 'Listado de IVA de facturas de cliente';
AStream := FDataModule.GenerarInformeIVAClientes(AppFactuGES.EmpresaActiva.ID, FechaInicio, FechaFin, ListaIDClientes, DesglosadoCliente, ImporteMinimo); AStream := FDataModule.GenerarInformeIVAClientes(AppFactuGES.EmpresaActiva.ID,
LoadFromStream(AStream); AEditor.FechaInicio, AEditor.FechaFin, AEditor.ListaIDClientes,
Preview; AEditor.DesglosadoCliente, AEditor.ImporteMinimo);
AEditor.LoadFromStream(AStream);
AEditor.Preview;
finally finally
Release; AEditor.Release;
AEditor := Nil; AEditor := Nil;
FreeAndNil(AStream); FreeAndNil(AStream);
end; end;
end; end;
end;
procedure TGestorInformesController.VerInformeIVAProveedores; procedure TGestorInformesController.VerInformeIVAProveedores;
var var
@ -308,21 +307,21 @@ begin
CreateEditor('EditorInformeIVAProveedoresReport', IEditorInformeIVAProveedoresReport, AEditor); CreateEditor('EditorInformeIVAProveedoresReport', IEditorInformeIVAProveedoresReport, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
AEditor.Controller := Self; AEditor.Controller := Self;
AEditor.Title := 'Listado de IVA de facturas de proveedor'; AEditor.Title := 'Listado de IVA de facturas de proveedor';
AStream := FDataModule.GenerarInformeIVAProveedores(AppFactuGES.EmpresaActiva.ID, FechaInicio, FechaFin, ListaIDProveedores, DesglosadoProveedor, ImporteMinimo); AStream := FDataModule.GenerarInformeIVAProveedores(AppFactuGES.EmpresaActiva.ID,
LoadFromStream(AStream); AEditor.FechaInicio, AEditor.FechaFin,
Preview; AEditor.ListaIDProveedores, AEditor.DesglosadoProveedor,
AEditor.ImporteMinimo);
AEditor.LoadFromStream(AStream);
AEditor.Preview;
finally finally
Release; AEditor.Release;
AEditor := Nil; AEditor := Nil;
FreeAndNil(AStream); FreeAndNil(AStream);
end; end;
end; end;
end;
procedure TGestorInformesController.VerInformeListadoFacturasCli; procedure TGestorInformesController.VerInformeListadoFacturasCli;
var var
@ -333,21 +332,20 @@ begin
CreateEditor('EditorInformeFacturasClienteReport', IEditorInformeFacturasClienteReport, AEditor); CreateEditor('EditorInformeFacturasClienteReport', IEditorInformeFacturasClienteReport, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
AEditor.Controller := Self; AEditor.Controller := Self;
AEditor.Title := 'Listado de facturas de cliente'; AEditor.Title := 'Listado de facturas de cliente';
AStream := FDataModule.GenerarInformeListadoFacturasCli(AppFactuGES.EmpresaActiva.ID, FechaInicio, FechaFin, ListaIDClientes, DesglosadoCliente, ImporteMinimo); AStream := FDataModule.GenerarInformeListadoFacturasCli(AppFactuGES.EmpresaActiva.ID,
LoadFromStream(AStream); AEditor.FechaInicio, AEditor.FechaFin, AEditor.ListaIDClientes,
Preview; AEditor.DesglosadoCliente, AEditor.ImporteMinimo);
AEditor.LoadFromStream(AStream);
AEditor.Preview;
finally finally
Release; AEditor.Release;
AEditor := Nil; AEditor := Nil;
FreeAndNil(AStream); FreeAndNil(AStream);
end; end;
end; end;
end;
procedure TGestorInformesController.VerInformeListadoFacturasCliPendientes; procedure TGestorInformesController.VerInformeListadoFacturasCliPendientes;
var var
@ -358,21 +356,20 @@ begin
CreateEditor('EditorInformeFacturasClientePendientesReport', IEditorInformeFacturasClientePendientesReport, AEditor); CreateEditor('EditorInformeFacturasClientePendientesReport', IEditorInformeFacturasClientePendientesReport, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
AEditor.Controller := Self; AEditor.Controller := Self;
AEditor.Title := 'Listado de facturas de cliente pendientes'; AEditor.Title := 'Listado de facturas de cliente pendientes';
AStream := FDataModule.GenerarInformeListadoFacturasCliPendientes(AppFactuGES.EmpresaActiva.ID, FechaInicio, FechaFin, ListaIDClientes, DesglosadoCliente, ImporteMinimo); AStream := FDataModule.GenerarInformeListadoFacturasCliPendientes(AppFactuGES.EmpresaActiva.ID,
LoadFromStream(AStream); AEditor.FechaInicio, AEditor.FechaFin, AEditor.ListaIDClientes,
Preview; AEditor.DesglosadoCliente, AEditor.ImporteMinimo);
AEditor.LoadFromStream(AStream);
AEditor.Preview;
finally finally
Release; AEditor.Release;
AEditor := Nil; AEditor := Nil;
FreeAndNil(AStream); FreeAndNil(AStream);
end; end;
end; end;
end;
procedure TGestorInformesController.VerInformeListadoFacturasProv; procedure TGestorInformesController.VerInformeListadoFacturasProv;
var var
@ -382,21 +379,20 @@ begin
AEditor := NIL; AEditor := NIL;
CreateEditor('EditorInformeFacturasProveedorReport', IEditorInformeFacturasProveedorReport, AEditor); CreateEditor('EditorInformeFacturasProveedorReport', IEditorInformeFacturasProveedorReport, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
AEditor.Controller := Self; AEditor.Controller := Self;
AEditor.Title := 'Listado de facturas de proveedor'; AEditor.Title := 'Listado de facturas de proveedor';
AStream := FDataModule.GenerarInformeListadoFacturasProv(AppFactuGES.EmpresaActiva.ID, FechaInicio, FechaFin, ListaIDProveedores, DesglosadoProveedor, ImporteMinimo); AStream := FDataModule.GenerarInformeListadoFacturasProv(AppFactuGES.EmpresaActiva.ID,
LoadFromStream(AStream); AEditor.FechaInicio, AEditor.FechaFin, AEditor.ListaIDProveedores,
Preview; AEditor.DesglosadoProveedor, AEditor.ImporteMinimo);
AEditor.LoadFromStream(AStream);
AEditor.Preview;
finally finally
Release; AEditor.Release;
AEditor := Nil; AEditor := Nil;
FreeAndNil(AStream); FreeAndNil(AStream);
end; end;
end; end;
end;
procedure TGestorInformesController.VerInformeListadoFacturasProvPendientes; procedure TGestorInformesController.VerInformeListadoFacturasProvPendientes;
var var
@ -406,21 +402,20 @@ begin
AEditor := NIL; AEditor := NIL;
CreateEditor('EditorInformeFacturasProveedorPendientesReport', IEditorInformeFacturasProveedorPendientesReport, AEditor); CreateEditor('EditorInformeFacturasProveedorPendientesReport', IEditorInformeFacturasProveedorPendientesReport, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
AEditor.Controller := Self; AEditor.Controller := Self;
AEditor.Title := 'Listado de facturas de proveedor pendientes'; AEditor.Title := 'Listado de facturas de proveedor pendientes';
AStream := FDataModule.GenerarInformeListadoFacturasProvPendientes(AppFactuGES.EmpresaActiva.ID, FechaInicio, FechaFin, ListaIDProveedores, DesglosadoProveedor, ImporteMinimo); AStream := FDataModule.GenerarInformeListadoFacturasProvPendientes(AppFactuGES.EmpresaActiva.ID,
LoadFromStream(AStream); AEditor.FechaInicio, AEditor.FechaFin, AEditor.ListaIDProveedores,
Preview; AEditor.DesglosadoProveedor, AEditor.ImporteMinimo);
AEditor.LoadFromStream(AStream);
AEditor.Preview;
finally finally
Release; AEditor.Release;
AEditor := Nil; AEditor := Nil;
FreeAndNil(AStream); FreeAndNil(AStream);
end; end;
end; end;
end;
procedure TGestorInformesController.VerInformeListadoPedidos; procedure TGestorInformesController.VerInformeListadoPedidos;
var var
@ -431,21 +426,20 @@ begin
ShowHourglassCursor; ShowHourglassCursor;
CreateEditor('EditorInformePedidosReport', IEditorInformePedidosReport, AEditor); CreateEditor('EditorInformePedidosReport', IEditorInformePedidosReport, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
AEditor.Controller := Self; AEditor.Controller := Self;
AEditor.Title := 'Listado de pedidos de proveedor'; AEditor.Title := 'Listado de pedidos de proveedor';
AStream := FDataModule.GenerarInformeListadoPedidos(AppFactuGES.EmpresaActiva.ID, FechaInicio, FechaFin, ListaIDProveedores, DesglosadoProveedor, ImporteMinimo); AStream := FDataModule.GenerarInformeListadoPedidos(AppFactuGES.EmpresaActiva.ID,
LoadFromStream(AStream); AEditor.FechaInicio, AEditor.FechaFin, AEditor.ListaIDProveedores,
Preview; AEditor.DesglosadoProveedor, AEditor.ImporteMinimo);
AEditor.LoadFromStream(AStream);
AEditor.Preview;
finally finally
Release; AEditor.Release;
AEditor := Nil; AEditor := Nil;
FreeAndNil(AStream); FreeAndNil(AStream);
end; end;
end; end;
end;
procedure TGestorInformesController.VerInformeListadoPresupuestos; procedure TGestorInformesController.VerInformeListadoPresupuestos;
var var
@ -456,21 +450,20 @@ begin
CreateEditor('EditorInformePresupuestosReport', IEditorInformePresupuestosReport, AEditor); CreateEditor('EditorInformePresupuestosReport', IEditorInformePresupuestosReport, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
AEditor.Controller := Self; AEditor.Controller := Self;
AEditor.Title := 'Listado de presupuestos de cliente'; AEditor.Title := 'Listado de presupuestos de cliente';
AStream := FDataModule.GenerarInformeListadoPresupuestos(AppFactuGES.EmpresaActiva.ID, FechaInicio, FechaFin, ListaIDClientes, DesglosadoCliente, ImporteMinimo); AStream := FDataModule.GenerarInformeListadoPresupuestos(AppFactuGES.EmpresaActiva.ID,
LoadFromStream(AStream); AEditor.FechaInicio, AEditor.FechaFin, AEditor.ListaIDClientes,
Preview; AEditor.DesglosadoCliente, AEditor.ImporteMinimo);
AEditor.LoadFromStream(AStream);
AEditor.Preview;
finally finally
Release; AEditor.Release;
AEditor := Nil; AEditor := Nil;
FreeAndNil(AStream); FreeAndNil(AStream);
end; end;
end; end;
end;
procedure TGestorInformesController.VerInformeListadoRecibosCliente; procedure TGestorInformesController.VerInformeListadoRecibosCliente;
var var
@ -480,20 +473,19 @@ begin
AEditor := NIL; AEditor := NIL;
CreateEditor('EditorInformeRecibosClienteReport', IEditorInformeRecibosClienteReport, AEditor); CreateEditor('EditorInformeRecibosClienteReport', IEditorInformeRecibosClienteReport, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
AEditor.Controller := Self; AEditor.Controller := Self;
AStream := FDataModule.GenerarInformeListadoRecibosCliente(AppFactuGES.EmpresaActiva.ID, FechaInicio, FechaFin, ListaIDClientes, DesglosadoCliente, ImporteMinimo); AStream := FDataModule.GenerarInformeListadoRecibosCliente(AppFactuGES.EmpresaActiva.ID,
LoadFromStream(AStream); AEditor.FechaInicio, AEditor.FechaFin, AEditor.ListaIDClientes,
Preview; AEditor.DesglosadoCliente, AEditor.ImporteMinimo);
AEditor.LoadFromStream(AStream);
AEditor.Preview;
finally finally
Release; AEditor.Release;
AEditor := Nil; AEditor := Nil;
FreeAndNil(AStream); FreeAndNil(AStream);
end; end;
end; end;
end;
procedure TGestorInformesController.VerInformeListadoRecibosCliPendientes; procedure TGestorInformesController.VerInformeListadoRecibosCliPendientes;
var var
@ -504,20 +496,19 @@ begin
CreateEditor('EditorInformeRecibosCliPendientesReport', IEditorInformeRecibosCliPendientesReport, AEditor); CreateEditor('EditorInformeRecibosCliPendientesReport', IEditorInformeRecibosCliPendientesReport, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
AEditor.Controller := Self; AEditor.Controller := Self;
AStream := FDataModule.GenerarInformeListadoRecibosCliPendientes(AppFactuGES.EmpresaActiva.ID, FechaInicio, FechaFin, ListaIDClientes, DesglosadoCliente, ImporteMinimo); AStream := FDataModule.GenerarInformeListadoRecibosCliPendientes(AppFactuGES.EmpresaActiva.ID,
LoadFromStream(AStream); AEditor.FechaInicio, AEditor.FechaFin, AEditor.ListaIDClientes,
Preview; AEditor.DesglosadoCliente, AEditor.ImporteMinimo);
AEditor.LoadFromStream(AStream);
AEditor.Preview;
finally finally
Release; AEditor.Release;
AEditor := Nil; AEditor := Nil;
FreeAndNil(AStream); FreeAndNil(AStream);
end; end;
end; end;
end;
procedure TGestorInformesController.VerInformeListadoRecibosProveedor; procedure TGestorInformesController.VerInformeListadoRecibosProveedor;
@ -529,20 +520,19 @@ begin
CreateEditor('EditorInformeRecibosProveedorReport', IEditorInformeRecibosProveedorReport, AEditor); CreateEditor('EditorInformeRecibosProveedorReport', IEditorInformeRecibosProveedorReport, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
AEditor.Controller := Self; AEditor.Controller := Self;
AStream := FDataModule.GenerarInformeListadoRecibosProveedor(AppFactuGES.EmpresaActiva.ID, FechaInicio, FechaFin, ListaIDProveedores, DesglosadoProveedor, ImporteMinimo); AStream := FDataModule.GenerarInformeListadoRecibosProveedor(AppFactuGES.EmpresaActiva.ID,
LoadFromStream(AStream); AEditor.FechaInicio, AEditor.FechaFin, AEditor.ListaIDProveedores,
Preview; AEditor.DesglosadoProveedor, AEditor.ImporteMinimo);
AEditor.LoadFromStream(AStream);
AEditor.Preview;
finally finally
Release; AEditor.Release;
AEditor := Nil; AEditor := Nil;
FreeAndNil(AStream); FreeAndNil(AStream);
end; end;
end; end;
end;
procedure TGestorInformesController.VerInformeListadoRecibosProvPendientes; procedure TGestorInformesController.VerInformeListadoRecibosProvPendientes;
var var
@ -553,20 +543,19 @@ begin
CreateEditor('EditorInformeRecibosProvPendientesReport', IEditorInformeRecibosProvPendientesReport, AEditor); CreateEditor('EditorInformeRecibosProvPendientesReport', IEditorInformeRecibosProvPendientesReport, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
AEditor.Controller := Self; AEditor.Controller := Self;
AStream := FDataModule.GenerarInformeListadoRecibosProvPendientes(AppFactuGES.EmpresaActiva.ID, FechaInicio, FechaFin, ListaIDProveedores, DesglosadoProveedor, ImporteMinimo); AStream := FDataModule.GenerarInformeListadoRecibosProvPendientes(AppFactuGES.EmpresaActiva.ID,
LoadFromStream(AStream); AEditor.FechaInicio, AEditor.FechaFin, AEditor.ListaIDProveedores,
Preview; AEditor.DesglosadoProveedor, AEditor.ImporteMinimo);
AEditor.LoadFromStream(AStream);
AEditor.Preview;
finally finally
Release; AEditor.Release;
AEditor := Nil; AEditor := Nil;
FreeAndNil(AStream); FreeAndNil(AStream);
end; end;
end; end;
end;
{ {
procedure TGestorInformesController.Ver(AFactura: IBizFacturaCliente); procedure TGestorInformesController.Ver(AFactura: IBizFacturaCliente);
@ -599,7 +588,7 @@ begin
if ReadOnly then if ReadOnly then
SetDataTableReadOnly(AFactura.DataTable, False); SetDataTableReadOnly(AFactura.DataTable, False);
finally finally
Release; AEditor.Release;
end; end;
end; end;
finally finally

View File

@ -29,19 +29,16 @@ begin
Result := NIL; Result := NIL;
CreateEditor('EditorElegirArticulosCatalogo', IEditorElegirArticulosCatalogo, AEditor); CreateEditor('EditorElegirArticulosCatalogo', IEditorElegirArticulosCatalogo, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
Controller := Self; AEditor.Controller := Self;
Articulos := AArticulos; AEditor.Articulos := AArticulos;
MultiSelect := AMultiSelect; AEditor.MultiSelect := AMultiSelect;
if IsPositiveResult(ShowModal) then if IsPositiveResult(AEditor.ShowModal) then
Result := ArticulosSeleccionados; Result := AEditor.ArticulosSeleccionados;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
end. end.

View File

@ -195,8 +195,6 @@ begin
end; end;
function TInventarioController.Buscar(const ID_ALMACEN: Integer): IBizInventario; function TInventarioController.Buscar(const ID_ALMACEN: Integer): IBizInventario;
var
Condicion: TDAWhereExpression;
begin begin
Result := (FDataModule as IDataModuleInventario).GetItems(ID_ALMACEN); Result := (FDataModule as IDataModuleInventario).GetItems(ID_ALMACEN);
FiltrarEmpresa(Result); FiltrarEmpresa(Result);
@ -409,21 +407,18 @@ begin
CreateEditor('EditorElegirArticulosAlmacen', IEditorElegirArticulosAlmacen, AEditor); CreateEditor('EditorElegirArticulosAlmacen', IEditorElegirArticulosAlmacen, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
Controller := Self; AEditor.Controller := Self;
Inventario := AArticulos; AEditor.Inventario := AArticulos;
MultiSelect := AMultiSelect; AEditor.MultiSelect := AMultiSelect;
Mensaje := AMensaje; AEditor.Mensaje := AMensaje;
if IsPositiveResult(ShowModal) then if IsPositiveResult(AEditor.ShowModal) then
Result := ArticulosSeleccionados; Result := AEditor.ArticulosSeleccionados;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
function TInventarioController.Eliminar(AInventario: IBizInventario; Todos: Boolean; ApplyUpdates: Boolean): Boolean; function TInventarioController.Eliminar(AInventario: IBizInventario; Todos: Boolean; ApplyUpdates: Boolean): Boolean;
begin begin
@ -534,22 +529,19 @@ begin
CreateEditor('EditorEntradaSalidaArticulos', IEditorEntradaSalidaArticulos, AEditor); CreateEditor('EditorEntradaSalidaArticulos', IEditorEntradaSalidaArticulos, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
Controller := Self; //OJO ORDEN MUY IMPORTANTE AEditor.Controller := Self; //OJO ORDEN MUY IMPORTANTE
Articulos := AArticulos; AEditor.Articulos := AArticulos;
Inventario := AInventario; AEditor.Inventario := AInventario;
if Assigned(APedido) then if Assigned(APedido) then
PedidoProveedor := APedido; AEditor.PedidoProveedor := APedido;
ShowModal; AEditor.ShowModal;
Result := ResultadoModalOK; Result := AEditor.ResultadoModalOK;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
procedure TInventarioController.VerReservas(AArticulo: IBizInventario; const ATipoReservas: String); procedure TInventarioController.VerReservas(AArticulo: IBizInventario; const ATipoReservas: String);
var var
@ -559,21 +551,18 @@ begin
CreateEditor('EditorDetalleReservas', IEditorDetalleReservas, AEditor); CreateEditor('EditorDetalleReservas', IEditorDetalleReservas, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
Controller := Self; //OJO ORDEN MUY IMPORTANTE AEditor.Controller := Self; //OJO ORDEN MUY IMPORTANTE
TipoReservas := ATipoReservas; AEditor.TipoReservas := ATipoReservas;
DetalleReservas := FDataModule.GetDetalleReservas; AEditor.DetalleReservas := FDataModule.GetDetalleReservas;
Articulo := AArticulo; AEditor.Articulo := AArticulo;
MultiSelect := True; AEditor.MultiSelect := True;
ShowModal; AEditor.ShowModal;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
procedure TInventarioController.VerTodos(AInventario: IBizInventario; const pTipoInventario: String); procedure TInventarioController.VerTodos(AInventario: IBizInventario; const pTipoInventario: String);
var var

View File

@ -47,12 +47,12 @@
<DelphiCompile Include="Obras_controller.dpk"> <DelphiCompile Include="Obras_controller.dpk">
<MainSource>MainSource</MainSource> <MainSource>MainSource</MainSource>
</DelphiCompile> </DelphiCompile>
<DCCReference Include="..\ApplicationBase.dcp" />
<DCCReference Include="..\Contactos_model.dcp" />
<DCCReference Include="..\GUIBase.dcp" />
<DCCReference Include="..\Obras_data.dcp" />
<DCCReference Include="..\Obras_model.dcp" />
<DCCReference Include="uObrasController.pas" /> <DCCReference Include="uObrasController.pas" />
<DCCReference Include="View\ApplicationBase.dcp" />
<DCCReference Include="View\Contactos_model.dcp" />
<DCCReference Include="View\GUIBase.dcp" />
<DCCReference Include="View\Obras_data.dcp" />
<DCCReference Include="View\Obras_model.dcp" />
<DCCReference Include="View\uIEditorEjecucionObra.pas" /> <DCCReference Include="View\uIEditorEjecucionObra.pas" />
<DCCReference Include="View\uIEditorFechaCierreObra.pas" /> <DCCReference Include="View\uIEditorFechaCierreObra.pas" />
<DCCReference Include="View\uIEditorListaObras.pas" /> <DCCReference Include="View\uIEditorListaObras.pas" />

View File

@ -7,6 +7,7 @@ type
['{2124B621-143A-4955-90EF-EC2053840A47}'] ['{2124B621-143A-4955-90EF-EC2053840A47}']
function ShowModal : Integer; function ShowModal : Integer;
procedure Show; procedure Show;
procedure Release;
procedure SetFechaCierre (const Value : TDateTime); procedure SetFechaCierre (const Value : TDateTime);
function GetFechaCierre : TDateTime; function GetFechaCierre : TDateTime;

View File

@ -192,22 +192,19 @@ begin
CreateEditor('EditorFechaCierreObra', IEditorFechaCierreObra, AEditor); CreateEditor('EditorFechaCierreObra', IEditorFechaCierreObra, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with (AEditor as IEditorFechaCierreObra) do
begin
try try
FechaCierre := DateOf(AFecha); AEditor.FechaCierre := DateOf(AFecha);
if (ShowModal = mrOk) then if (AEditor.ShowModal = mrOk) then
begin begin
AObra.Ejecuciones.Edit; AObra.Ejecuciones.Edit;
AObra.Ejecuciones.FECHA_FIN := DateOf(FechaCierre); AObra.Ejecuciones.FECHA_FIN := DateOf(AEditor.FechaCierre);
AObra.Ejecuciones.Post; AObra.Ejecuciones.Post;
end; end;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
procedure TObrasController.CopiarDireccion(const ACliente: IBizCliente; procedure TObrasController.CopiarDireccion(const ACliente: IBizCliente;
AObra: IBizObra); AObra: IBizObra);
@ -342,25 +339,22 @@ end;
procedure TObrasController.Ver(AObra: IBizObra); procedure TObrasController.Ver(AObra: IBizObra);
var var
AEditor : IEditorDBItem; AEditor : IEditorObra;
begin begin
AEditor := NIL; AEditor := NIL;
RecuperarObjetos(AObra); RecuperarObjetos(AObra);
CreateEditor('EditorObra', IEditorObra, AEditor); CreateEditor('EditorObra', IEditorObra, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with (AEditor as IEditorObra) do
begin
try try
Controller := Self; //OJO ORDEN MUY IMPORTANTE AEditor.Controller := Self; //OJO ORDEN MUY IMPORTANTE
Obra := AObra; AEditor.Obra := AObra;
ShowModal; AEditor.ShowModal;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
procedure TObrasController.VerEjecucion(AObra: IBizObra); procedure TObrasController.VerEjecucion(AObra: IBizObra);
var var
@ -371,18 +365,15 @@ begin
RecuperarObjetos(AObra); RecuperarObjetos(AObra);
CreateEditor('EditorEjecucionObra', IEditorEjecucionObra, AEditor); CreateEditor('EditorEjecucionObra', IEditorEjecucionObra, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with (AEditor as IEditorEjecucionObra) do
begin
try try
Controller := Self; //OJO ORDEN MUY IMPORTANTE AEditor.Controller := Self; //OJO ORDEN MUY IMPORTANTE
Obra := AObra; AEditor.Obra := AObra;
ShowModal; AEditor.ShowModal;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
function TObrasController.VerLista(AObras: IBizObra): IBizObra; function TObrasController.VerLista(AObras: IBizObra): IBizObra;
var var
@ -393,18 +384,15 @@ begin
CreateEditor('EditorListaObras', IEditorListaObras, AEditor); CreateEditor('EditorListaObras', IEditorListaObras, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
Obras := AObras; AEditor.Obras := AObras;
if IsPositiveResult(ShowModal) then if IsPositiveResult(AEditor.ShowModal) then
Result := ObraSeleccionado; Result := AEditor.ObraSeleccionado;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
procedure TObrasController.VerTodos(AObras: IBizObra); procedure TObrasController.VerTodos(AObras: IBizObra);
var var

View File

@ -46,13 +46,12 @@
<DelphiCompile Include="Obras_plugin.dpk"> <DelphiCompile Include="Obras_plugin.dpk">
<MainSource>MainSource</MainSource> <MainSource>MainSource</MainSource>
</DelphiCompile> </DelphiCompile>
<DCCReference Include="C:\Documents and Settings\Usuario\Obras_controller.dcp" /> <DCCReference Include="..\Obras_controller.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\Obras_model.dcp" /> <DCCReference Include="..\Obras_model.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\Obras_view.dcp" /> <DCCReference Include="..\Obras_view.dcp" />
<DCCReference Include="uPluginObras.pas" /> <DCCReference Include="uPluginObras.pas" />
</ItemGroup> </ItemGroup>
</Project> </Project>
<!-- EurekaLog First Line <!-- EurekaLog First Line
[Exception Log] [Exception Log]
EurekaLog Version=6011 EurekaLog Version=6011

View File

@ -37,18 +37,18 @@
<DelphiCompile Include="Obras_view.dpk"> <DelphiCompile Include="Obras_view.dpk">
<MainSource>MainSource</MainSource> <MainSource>MainSource</MainSource>
</DelphiCompile> </DelphiCompile>
<DCCReference Include="ApplicationBase.dcp" /> <DCCReference Include="..\ApplicationBase.dcp" />
<DCCReference Include="Base.dcp" /> <DCCReference Include="..\Base.dcp" />
<DCCReference Include="Contactos_controller.dcp" /> <DCCReference Include="..\Contactos_controller.dcp" />
<DCCReference Include="Contactos_model.dcp" /> <DCCReference Include="..\Contactos_model.dcp" />
<DCCReference Include="Contactos_view.dcp" /> <DCCReference Include="..\Contactos_view.dcp" />
<DCCReference Include="GUIBase.dcp" /> <DCCReference Include="..\GUIBase.dcp" />
<DCCReference Include="Obras_controller.dcp" /> <DCCReference Include="..\Obras_controller.dcp" />
<DCCReference Include="Obras_model.dcp" /> <DCCReference Include="..\Obras_model.dcp" />
<DCCReference Include="PedidosProveedor_controller.dcp" /> <DCCReference Include="..\PedidosProveedor_controller.dcp" />
<DCCReference Include="PedidosProveedor_model.dcp" /> <DCCReference Include="..\PedidosProveedor_model.dcp" />
<DCCReference Include="PresupuestosCliente_controller.dcp" /> <DCCReference Include="..\PresupuestosCliente_controller.dcp" />
<DCCReference Include="PresupuestosCliente_model.dcp" /> <DCCReference Include="..\PresupuestosCliente_model.dcp" />
<DCCReference Include="uEditorEjecucionObra.pas"> <DCCReference Include="uEditorEjecucionObra.pas">
<Form>fEditorEjecucionObra</Form> <Form>fEditorEjecucionObra</Form>
<DesignClass>TfEditorEjecucionObra</DesignClass> <DesignClass>TfEditorEjecucionObra</DesignClass>
@ -104,7 +104,6 @@
</DCCReference> </DCCReference>
</ItemGroup> </ItemGroup>
</Project> </Project>
<!-- EurekaLog First Line <!-- EurekaLog First Line
[Exception Log] [Exception Log]
EurekaLog Version=6011 EurekaLog Version=6011

View File

@ -31,21 +31,18 @@ begin
Result := NIL; Result := NIL;
CreateEditor('EditorElegirArticulosPedidoProveedor', IEditorElegirArticulosPedidosProveedor, AEditor); CreateEditor('EditorElegirArticulosPedidoProveedor', IEditorElegirArticulosPedidosProveedor, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
Controller := Self; AEditor.Controller := Self;
Articulos := AArticulos; AEditor.Articulos := AArticulos;
Proveedor := AProveedor; AEditor.Proveedor := AProveedor;
MultiSelect := AMultiSelect; AEditor.MultiSelect := AMultiSelect;
Mensaje := AMensaje; AEditor.Mensaje := AMensaje;
if IsPositiveResult(ShowModal) then if IsPositiveResult(AEditor.ShowModal) then
Result := ArticulosSeleccionados; Result := AEditor.ArticulosSeleccionados;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
end. end.

View File

@ -346,19 +346,16 @@ begin
RecuperarProveedor(APedido); RecuperarProveedor(APedido);
CreateEditor('EditorSituacionPedidoProveedor', IEditorSituacionPedidoProveedor, AEditor); CreateEditor('EditorSituacionPedidoProveedor', IEditorSituacionPedidoProveedor, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
Controller := Self; //OJO ORDEN MUY IMPORTANTE AEditor.Controller := Self; //OJO ORDEN MUY IMPORTANTE
PedidoProveedor := APedido; AEditor.PedidoProveedor := APedido;
ShowModal; AEditor.ShowModal;
Result := True; Result := True;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
destructor TPedidosProveedorController.Destroy; destructor TPedidosProveedorController.Destroy;
begin begin
@ -478,30 +475,27 @@ begin
CreateEditor('EditorPedidoProveedor', IEditorPedidoProveedor, AEditor); CreateEditor('EditorPedidoProveedor', IEditorPedidoProveedor, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
Controller := Self; //OJO ORDEN MUY IMPORTANTE AEditor.Controller := Self; //OJO ORDEN MUY IMPORTANTE
Pedido := APedido; AEditor.Pedido := APedido;
//MODO CONSULTAR //MODO CONSULTAR
if not EsModificable(APedido) then if not EsModificable(APedido) then
begin begin
SetDataTableReadOnly(APedido.DataTable, True); SetDataTableReadOnly(APedido.DataTable, True);
ReadOnly := True; AEditor.ReadOnly := True;
end; end;
ShowModal; AEditor.ShowModal;
//MODO CONSULTAR (Se deja la tabla como estaba) //MODO CONSULTAR (Se deja la tabla como estaba)
if ReadOnly then if AEditor.ReadOnly then
SetDataTableReadOnly(APedido.DataTable, False); SetDataTableReadOnly(APedido.DataTable, False);
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
procedure TPedidosProveedorController.VerTodos(APedidos: IBizPedidoProveedor; procedure TPedidosProveedorController.VerTodos(APedidos: IBizPedidoProveedor;
const AVerModal : Boolean = False; const AWindowCaption: String = ''; const AVerModal : Boolean = False; const AWindowCaption: String = '';
@ -513,8 +507,6 @@ begin
CreateEditor('EditorPedidosProveedor', IEditorPedidosProveedor, AEditor); CreateEditor('EditorPedidosProveedor', IEditorPedidosProveedor, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
if not EsCadenaVacia(AWindowCaption) then if not EsCadenaVacia(AWindowCaption) then
AEditor.WindowCaption := AWindowCaption; AEditor.WindowCaption := AWindowCaption;
@ -522,20 +514,19 @@ begin
if not EsCadenaVacia(AHeaderText) then if not EsCadenaVacia(AHeaderText) then
AEditor.HeaderText := AHeaderText; AEditor.HeaderText := AHeaderText;
Controller := Self; //OJO ORDEN MUY IMPORTANTE AEditor.Controller := Self; //OJO ORDEN MUY IMPORTANTE
Pedidos := APedidos; AEditor.Pedidos := APedidos;
MultiSelect := True; AEditor.MultiSelect := True;
if AVerModal then if AVerModal then
ShowModal AEditor.ShowModal
else else
ShowEmbedded; AEditor.ShowEmbedded;
finally finally
if AVerModal then if AVerModal then
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
procedure TPedidosProveedorController.VerDireccionEntrega( procedure TPedidosProveedorController.VerDireccionEntrega(
APedido: IBizPedidoProveedor); APedido: IBizPedidoProveedor);
@ -547,17 +538,14 @@ begin
//RecuperarObjetos(APedido); <- No descomentar. No hace falta //RecuperarObjetos(APedido); <- No descomentar. No hace falta
CreateEditor('EditorDireccionEntregaPedidoProveedor', IEditorDireccionEntregaPedidoProveedor, AEditor); CreateEditor('EditorDireccionEntregaPedidoProveedor', IEditorDireccionEntregaPedidoProveedor, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with (AEditor as IEditorDireccionEntregaPedidoProveedor) do
begin
try try
Pedido := APedido; AEditor.Pedido := APedido;
ShowModal; AEditor.ShowModal;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
function TPedidosProveedorController._Vacio: IBizPedidoProveedor; function TPedidosProveedorController._Vacio: IBizPedidoProveedor;
begin begin
@ -585,21 +573,18 @@ begin
CreateEditor('EditorElegirPedidosProveedor', IEditorElegirPedidosProveedor, AEditor); CreateEditor('EditorElegirPedidosProveedor', IEditorElegirPedidosProveedor, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
Controller := Self; AEditor.Controller := Self;
Pedidos := APedido; AEditor.Pedidos := APedido;
MultiSelect := AMultiSelect; AEditor.MultiSelect := AMultiSelect;
Mensaje := AMensaje; AEditor.Mensaje := AMensaje;
if IsPositiveResult(ShowModal) then if IsPositiveResult(AEditor.ShowModal) then
Result := PedidosProveedorSeleccionados; Result := AEditor.PedidosProveedorSeleccionados;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
function TPedidosProveedorController.Eliminar(APedido: IBizPedidoProveedor; AllItems: Boolean = false): Boolean; function TPedidosProveedorController.Eliminar(APedido: IBizPedidoProveedor; AllItems: Boolean = false): Boolean;
//En el caso de eliminar almenos un elemento del conjunto se devuelve true //En el caso de eliminar almenos un elemento del conjunto se devuelve true

View File

@ -49,12 +49,12 @@
<DelphiCompile Include="PresupuestosCliente_controller.dpk"> <DelphiCompile Include="PresupuestosCliente_controller.dpk">
<MainSource>MainSource</MainSource> <MainSource>MainSource</MainSource>
</DelphiCompile> </DelphiCompile>
<DCCReference Include="..\Articulos_controller.dcp" /> <DCCReference Include="..\..\Obras\Articulos_controller.dcp" />
<DCCReference Include="..\Contactos_controller.dcp" /> <DCCReference Include="..\..\Obras\Contactos_controller.dcp" />
<DCCReference Include="..\GestorDocumentos_controller.dcp" /> <DCCReference Include="..\..\Obras\GestorDocumentos_controller.dcp" />
<DCCReference Include="..\GUIBase.dcp" /> <DCCReference Include="..\..\Obras\GUIBase.dcp" />
<DCCReference Include="..\PresupuestosCliente_data.dcp" /> <DCCReference Include="..\..\Obras\PresupuestosCliente_data.dcp" />
<DCCReference Include="..\PresupuestosCliente_model.dcp" /> <DCCReference Include="..\..\Obras\PresupuestosCliente_model.dcp" />
<DCCReference Include="uArticulosPresupuestoClienteController.pas" /> <DCCReference Include="uArticulosPresupuestoClienteController.pas" />
<DCCReference Include="uDetallesPresupuestoClienteController.pas" /> <DCCReference Include="uDetallesPresupuestoClienteController.pas" />
<DCCReference Include="uPresupuestosClienteController.pas" /> <DCCReference Include="uPresupuestosClienteController.pas" />

View File

@ -30,20 +30,17 @@ begin
CreateEditor('EditorElegirArticulosPresupuestosCliente', IEditorElegirArticulosPresupuestosCliente, AEditor); CreateEditor('EditorElegirArticulosPresupuestosCliente', IEditorElegirArticulosPresupuestosCliente, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
Controller := Self; AEditor.Controller := Self;
Articulos := AArticulos; AEditor.Articulos := AArticulos;
MultiSelect := AMultiSelect; AEditor.MultiSelect := AMultiSelect;
Mensaje := AMensaje; AEditor.Mensaje := AMensaje;
if IsPositiveResult(ShowModal) then if IsPositiveResult(AEditor.ShowModal) then
Result := ArticulosSeleccionados; Result := AEditor.ArticulosSeleccionados;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
end. end.

View File

@ -500,30 +500,27 @@ begin
CreateEditor('EditorPresupuestoCliente', IEditorPresupuestoCliente, AEditor); CreateEditor('EditorPresupuestoCliente', IEditorPresupuestoCliente, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
Controller := Self; //OJO ORDEN MUY IMPORTANTE AEditor.Controller := Self; //OJO ORDEN MUY IMPORTANTE
Presupuesto := APresupuesto; AEditor.Presupuesto := APresupuesto;
//MODO CONSULTAR //MODO CONSULTAR
if not EsModificable(APresupuesto) then if not EsModificable(APresupuesto) then
begin begin
SetDataTableReadOnly(APresupuesto.DataTable, True); SetDataTableReadOnly(APresupuesto.DataTable, True);
ReadOnly := True; AEditor.ReadOnly := True;
end; end;
ShowModal; AEditor.ShowModal;
//MODO CONSULTAR (Se deja la tabla como estaba) //MODO CONSULTAR (Se deja la tabla como estaba)
if ReadOnly then if AEditor.ReadOnly then
SetDataTableReadOnly(APresupuesto.DataTable, False); SetDataTableReadOnly(APresupuesto.DataTable, False);
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
procedure TPresupuestosClienteController.VerDireccionEntrega( procedure TPresupuestosClienteController.VerDireccionEntrega(
APresupuesto: IBizPresupuestoCliente); APresupuesto: IBizPresupuestoCliente);
@ -541,7 +538,7 @@ begin
Presupuesto := APresupuesto; Presupuesto := APresupuesto;
ShowModal; ShowModal;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
@ -557,8 +554,6 @@ begin
AEditor := NIL; AEditor := NIL;
CreateEditor('EditorPresupuestosCliente', IEditorPresupuestosCliente, AEditor); CreateEditor('EditorPresupuestosCliente', IEditorPresupuestosCliente, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
if not EsCadenaVacia(AWindowCaption) then if not EsCadenaVacia(AWindowCaption) then
AEditor.WindowCaption := AWindowCaption; AEditor.WindowCaption := AWindowCaption;
@ -566,20 +561,19 @@ begin
if not EsCadenaVacia(AHeaderText) then if not EsCadenaVacia(AHeaderText) then
AEditor.HeaderText := AHeaderText; AEditor.HeaderText := AHeaderText;
Controller := Self; //OJO ORDEN MUY IMPORTANTE AEditor.Controller := Self; //OJO ORDEN MUY IMPORTANTE
Presupuestos := APresupuestos; AEditor.Presupuestos := APresupuestos;
MultiSelect := True; AEditor.MultiSelect := True;
if AVerModal then if AVerModal then
ShowModal AEditor.ShowModal
else else
ShowEmbedded; AEditor.ShowEmbedded;
finally finally
if AVerModal then if AVerModal then
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
function TPresupuestosClienteController._Vacio: IBizPresupuestoCliente; function TPresupuestosClienteController._Vacio: IBizPresupuestoCliente;
begin begin
@ -607,21 +601,18 @@ begin
CreateEditor('EditorElegirPresupuestosCliente', IEditorElegirPresupuestosCliente, AEditor); CreateEditor('EditorElegirPresupuestosCliente', IEditorElegirPresupuestosCliente, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
Controller := Self; AEditor.Controller := Self;
Presupuestos := APresupuesto; AEditor.Presupuestos := APresupuesto;
MultiSelect := AMultiSelect; AEditor.MultiSelect := AMultiSelect;
Mensaje := AMensaje; AEditor.Mensaje := AMensaje;
if IsPositiveResult(ShowModal) then if IsPositiveResult(AEditor.ShowModal) then
Result := PresupuestosClienteSeleccionados; Result := AEditor.PresupuestosClienteSeleccionados;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
function TPresupuestosClienteController.Eliminar(APresupuesto: IBizPresupuestoCliente; AllItems: Boolean = false): Boolean; function TPresupuestosClienteController.Eliminar(APresupuesto: IBizPresupuestoCliente; AllItems: Boolean = false): Boolean;
//En el caso de eliminar almenos un elemento del conjunto se devuelve true //En el caso de eliminar almenos un elemento del conjunto se devuelve true

View File

@ -52,16 +52,16 @@
<DelphiCompile Include="PresupuestosCliente_model.dpk"> <DelphiCompile Include="PresupuestosCliente_model.dpk">
<MainSource>MainSource</MainSource> <MainSource>MainSource</MainSource>
</DelphiCompile> </DelphiCompile>
<DCCReference Include="..\..\Obras\adortl.dcp" />
<DCCReference Include="..\..\Obras\Base.dcp" />
<DCCReference Include="..\..\Obras\Contactos_model.dcp" />
<DCCReference Include="..\..\Obras\dbrtl.dcp" />
<DCCReference Include="..\..\Obras\dsnap.dcp" />
<DCCReference Include="..\..\Obras\rtl.dcp" />
<DCCReference Include="..\..\Obras\vcl.dcp" />
<DCCReference Include="..\..\Obras\vcldb.dcp" />
<DCCReference Include="..\Controller\adortlBase.dcp" /> <DCCReference Include="..\Controller\adortlBase.dcp" />
<DCCReference Include="..\Controller\Contactos_modelcontainsuIDataModulePresupuestosClientein.dcp" /> <DCCReference Include="..\Controller\Contactos_modelcontainsuIDataModulePresupuestosClientein.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\adortl.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\Base.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\Contactos_model.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\dbrtl.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\dsnap.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\rtl.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\vcl.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\vcldb.dcp" />
<DCCReference Include="Data\uIDataModulePresupuestosCliente.pas" /> <DCCReference Include="Data\uIDataModulePresupuestosCliente.pas" />
<DCCReference Include="Data\uIDataModulePresupuestosClienteReport.pas" /> <DCCReference Include="Data\uIDataModulePresupuestosClienteReport.pas" />
<DCCReference Include="schPresupuestosClienteClient_Intf.pas" /> <DCCReference Include="schPresupuestosClienteClient_Intf.pas" />

View File

@ -49,27 +49,30 @@
<DelphiCompile Include="PresupuestosCliente_view.dpk"> <DelphiCompile Include="PresupuestosCliente_view.dpk">
<MainSource>MainSource</MainSource> <MainSource>MainSource</MainSource>
</DelphiCompile> </DelphiCompile>
<DCCReference Include="adortl.dcp" /> <DCCReference Include="..\..\Obras\adortl.dcp" />
<DCCReference Include="Articulos_view.dcp" /> <DCCReference Include="..\..\Obras\Articulos_view.dcp" />
<DCCReference Include="Base.dcp" /> <DCCReference Include="..\..\Obras\Base.dcp" />
<DCCReference Include="cxDataD11.dcp" /> <DCCReference Include="..\..\Obras\cxDataD11.dcp" />
<DCCReference Include="cxEditorsD11.dcp" /> <DCCReference Include="..\..\Obras\cxEditorsD11.dcp" />
<DCCReference Include="cxLibraryD11.dcp" /> <DCCReference Include="..\..\Obras\cxLibraryD11.dcp" />
<DCCReference Include="DataAbstract_Core_D11.dcp" /> <DCCReference Include="..\..\Obras\DataAbstract_Core_D11.dcp" />
<DCCReference Include="dbrtl.dcp" /> <DCCReference Include="..\..\Obras\dbrtl.dcp" />
<DCCReference Include="dsnap.dcp" /> <DCCReference Include="..\..\Obras\dsnap.dcp" />
<DCCReference Include="dxComnD11.dcp" /> <DCCReference Include="..\..\Obras\dxComnD11.dcp" />
<DCCReference Include="dxGDIPlusD11.dcp" /> <DCCReference Include="..\..\Obras\dxGDIPlusD11.dcp" />
<DCCReference Include="dxLayoutControlD11.dcp" /> <DCCReference Include="..\..\Obras\dxLayoutControlD11.dcp" />
<DCCReference Include="dxThemeD11.dcp" /> <DCCReference Include="..\..\Obras\dxThemeD11.dcp" />
<DCCReference Include="GestorInformes_controller.dcp" /> <DCCReference Include="..\..\Obras\GestorInformes_controller.dcp" />
<DCCReference Include="GUIBase.dcp" /> <DCCReference Include="..\..\Obras\GUIBase.dcp" />
<DCCReference Include="PreCli_AlbCli_relation.dcp" /> <DCCReference Include="..\..\Obras\PreCli_AlbCli_relation.dcp" />
<DCCReference Include="PreCli_FacCli_relation.dcp" /> <DCCReference Include="..\..\Obras\PreCli_FacCli_relation.dcp" />
<DCCReference Include="PresupuestosCliente_controller.dcp" /> <DCCReference Include="..\..\Obras\PresupuestosCliente_controller.dcp" />
<DCCReference Include="PresupuestosCliente_model.dcp" /> <DCCReference Include="..\..\Obras\PresupuestosCliente_model.dcp" />
<DCCReference Include="RemObjects_Core_D11.dcp" /> <DCCReference Include="..\..\Obras\RemObjects_Core_D11.dcp" />
<DCCReference Include="rtl.dcp" /> <DCCReference Include="..\..\Obras\rtl.dcp" />
<DCCReference Include="..\..\Obras\vcl.dcp" />
<DCCReference Include="..\..\Obras\vcldb.dcp" />
<DCCReference Include="..\..\Obras\vcljpg.dcp" />
<DCCReference Include="uEditorElegirArticulosPresupuestoCliente.pas"> <DCCReference Include="uEditorElegirArticulosPresupuestoCliente.pas">
<Form>fEditorElegirArticulosPresupuestoCliente</Form> <Form>fEditorElegirArticulosPresupuestoCliente</Form>
<DesignClass>TfEditorElegirArticulosPedidoCliente</DesignClass> <DesignClass>TfEditorElegirArticulosPedidoCliente</DesignClass>
@ -127,9 +130,6 @@
<Form>frViewTotalesPresupuesto</Form> <Form>frViewTotalesPresupuesto</Form>
<DesignClass>TFrame</DesignClass> <DesignClass>TFrame</DesignClass>
</DCCReference> </DCCReference>
<DCCReference Include="vcl.dcp" />
<DCCReference Include="vcldb.dcp" />
<DCCReference Include="vcljpg.dcp" />
</ItemGroup> </ItemGroup>
</Project> </Project>
<!-- EurekaLog First Line <!-- EurekaLog First Line

View File

@ -556,18 +556,15 @@ begin
RecuperarCliente(ARecibosCliente); RecuperarCliente(ARecibosCliente);
CreateEditor('EditorReciboCliente', IEditorReciboCliente, AEditor); CreateEditor('EditorReciboCliente', IEditorReciboCliente, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
Controller := Self; //OJO ORDEN MUY IMPORTANTE AEditor.Controller := Self; //OJO ORDEN MUY IMPORTANTE
Recibo := ARecibosCliente; AEditor.Recibo := ARecibosCliente;
ShowModal; AEditor.ShowModal;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
procedure TRecibosClienteController.VerTodos(ARecibosCliente: IBizRecibosCliente; procedure TRecibosClienteController.VerTodos(ARecibosCliente: IBizRecibosCliente;
const AVerModal : Boolean = False; const AWindowCaption: String = ''; const AVerModal : Boolean = False; const AWindowCaption: String = '';
@ -579,8 +576,6 @@ begin
CreateEditor('EditorRecibosCliente', IEditorRecibosCliente, AEditor); CreateEditor('EditorRecibosCliente', IEditorRecibosCliente, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
if not EsCadenaVacia(AWindowCaption) then if not EsCadenaVacia(AWindowCaption) then
AEditor.WindowCaption := AWindowCaption; AEditor.WindowCaption := AWindowCaption;
@ -588,21 +583,20 @@ begin
if not EsCadenaVacia(AHeaderText) then if not EsCadenaVacia(AHeaderText) then
AEditor.HeaderText := AHeaderText; AEditor.HeaderText := AHeaderText;
Controller := Self; //OJO ORDEN MUY IMPORTANTE AEditor.Controller := Self; //OJO ORDEN MUY IMPORTANTE
RecibosCliente := ARecibosCliente; AEditor.RecibosCliente := ARecibosCliente;
MultiSelect := True; AEditor.MultiSelect := True;
if AVerModal then if AVerModal then
ShowModal AEditor.ShowModal
else else
ShowEmbedded; AEditor.ShowEmbedded;
finally finally
if AVerModal then if AVerModal then
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
function TRecibosClienteController.ElegirRecibos(ARecibos: IBizRecibosCliente; AMensaje: String; AMultiSelect: Boolean): IBizRecibosCliente; function TRecibosClienteController.ElegirRecibos(ARecibos: IBizRecibosCliente; AMensaje: String; AMultiSelect: Boolean): IBizRecibosCliente;
var var
@ -612,21 +606,18 @@ begin
CreateEditor('EditorElegirRecibosCliente', IEditorElegirRecibosCliente, AEditor); CreateEditor('EditorElegirRecibosCliente', IEditorElegirRecibosCliente, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
Controller := Self; AEditor.Controller := Self;
RecibosCliente := ARecibos; AEditor.RecibosCliente := ARecibos;
MultiSelect := AMultiSelect; AEditor.MultiSelect := AMultiSelect;
Mensaje := AMensaje; AEditor.Mensaje := AMensaje;
if IsPositiveResult(ShowModal) then if IsPositiveResult(AEditor.ShowModal) then
Result := RecibosClienteSeleccionados; Result := AEditor.RecibosClienteSeleccionados;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
function TRecibosClienteController.ElegirRecibosCompensados(ARecibo: IBizRecibosCliente): Boolean; function TRecibosClienteController.ElegirRecibosCompensados(ARecibo: IBizRecibosCliente): Boolean;
var var

View File

@ -175,7 +175,7 @@ begin
if (AEditor.ShowModal = mrOk) then if (AEditor.ShowModal = mrOk) then
FechaPago := DateToStr(AEditor.FechaPago); FechaPago := DateToStr(AEditor.FechaPago);
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
@ -533,18 +533,15 @@ begin
RecuperarCliente(ARecibosProveedor); RecuperarCliente(ARecibosProveedor);
CreateEditor('EditorReciboProveedor', IEditorReciboProveedor, AEditor); CreateEditor('EditorReciboProveedor', IEditorReciboProveedor, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
Controller := Self; //OJO ORDEN MUY IMPORTANTE AEditor.Controller := Self; //OJO ORDEN MUY IMPORTANTE
Recibo := ARecibosProveedor; AEditor.Recibo := ARecibosProveedor;
ShowModal; AEditor.ShowModal;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
procedure TRecibosProveedorController.VerTodos(ARecibosProveedor: IBizRecibosProveedor; procedure TRecibosProveedorController.VerTodos(ARecibosProveedor: IBizRecibosProveedor;
const AVerModal : Boolean = False; const AWindowCaption: String = ''; const AVerModal : Boolean = False; const AWindowCaption: String = '';
@ -556,8 +553,6 @@ begin
CreateEditor('EditorRecibosProveedor', IEditorRecibosProveedor, AEditor); CreateEditor('EditorRecibosProveedor', IEditorRecibosProveedor, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
if not EsCadenaVacia(AWindowCaption) then if not EsCadenaVacia(AWindowCaption) then
AEditor.WindowCaption := AWindowCaption; AEditor.WindowCaption := AWindowCaption;
@ -565,19 +560,18 @@ begin
if not EsCadenaVacia(AHeaderText) then if not EsCadenaVacia(AHeaderText) then
AEditor.HeaderText := AHeaderText; AEditor.HeaderText := AHeaderText;
Controller := Self; AEditor.Controller := Self;
RecibosProveedor := ARecibosProveedor; AEditor.RecibosProveedor := ARecibosProveedor;
if AVerModal then if AVerModal then
ShowModal AEditor.ShowModal
else else
ShowEmbedded; AEditor.ShowEmbedded;
finally finally
if AVerModal then if AVerModal then
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
function TRecibosProveedorController.ElegirRecibos(ARecibos: IBizRecibosProveedor; AMensaje: String; function TRecibosProveedorController.ElegirRecibos(ARecibos: IBizRecibosProveedor; AMensaje: String;
AMultiSelect: Boolean): IBizRecibosProveedor; AMultiSelect: Boolean): IBizRecibosProveedor;
@ -588,18 +582,15 @@ begin
CreateEditor('EditorElegirRecibosProveedor', IEditorElegirRecibosProveedor, AEditor); CreateEditor('EditorElegirRecibosProveedor', IEditorElegirRecibosProveedor, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
Controller := Self; AEditor.Controller := Self;
RecibosProveedor := ARecibos; AEditor.RecibosProveedor := ARecibos;
MultiSelect := AMultiSelect; AEditor.MultiSelect := AMultiSelect;
Mensaje := AMensaje; AEditor.Mensaje := AMensaje;
if IsPositiveResult(ShowModal) then if IsPositiveResult(AEditor.ShowModal) then
Result := RecibosProveedorSeleccionados; Result := AEditor.RecibosProveedorSeleccionados;
finally finally
Release; AEditor.Release;
end;
end; end;
end; end;

View File

@ -63,14 +63,11 @@ begin
try try
CreateEditor('EditorRecibosProveedorPreview', IEditorRecibosProveedorPreview, AEditor); CreateEditor('EditorRecibosProveedorPreview', IEditorRecibosProveedorPreview, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
LoadFromStream(AStream); AEditor.LoadFromStream(AStream);
Preview; AEditor.Preview;
finally finally
Release; AEditor.Release;
end;
end; end;
finally finally
FreeAndNil(AStream); FreeAndNil(AStream);
@ -90,14 +87,11 @@ begin
try try
CreateEditor('EditorRecibosProveedorPreview', IEditorRecibosProveedorPreview, AEditor); CreateEditor('EditorRecibosProveedorPreview', IEditorRecibosProveedorPreview, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
LoadFromStream(AStream); AEditor.LoadFromStream(AStream);
Print; AEditor.Print;
finally finally
Release; AEditor.Release;
end;
end; end;
finally finally
FreeAndNil(AStream); FreeAndNil(AStream);

View File

@ -132,17 +132,14 @@ var
begin begin
CreateEditor('EditorReferencias', IEditorReferencias, AEditor); CreateEditor('EditorReferencias', IEditorReferencias, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
Referencias := AReferencias; AEditor.Referencias := AReferencias;
ShowModal; AEditor.ShowModal;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
{ {
procedure TReferenciasController.RecibirAviso(ASujeto: ISujeto; ADataTable: IDAStronglyTypedDataTable); procedure TReferenciasController.RecibirAviso(ASujeto: ISujeto; ADataTable: IDAStronglyTypedDataTable);
begin begin

View File

@ -222,30 +222,27 @@ begin
CreateEditor('EditorRemesaCliente', IEditorRemesaCliente, AEditor); CreateEditor('EditorRemesaCliente', IEditorRemesaCliente, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with (AEditor as IEditorRemesaCliente) do
begin
try try
Controller := Self; //OJO ORDEN MUY IMPORTANTE AEditor.Controller := Self; //OJO ORDEN MUY IMPORTANTE
RemesaCliente := ARemesaCliente; AEditor.RemesaCliente := ARemesaCliente;
//MODO CONSULTAR //MODO CONSULTAR
if not EsModificable(ARemesaCliente) then if not EsModificable(ARemesaCliente) then
begin begin
SetDataTableReadOnly(ARemesaCliente.DataTable, True); SetDataTableReadOnly(ARemesaCliente.DataTable, True);
ReadOnly := True; AEditor.ReadOnly := True;
end; end;
ShowModal; AEditor.ShowModal;
//MODO CONSULTAR (Se deja la tabla como estaba) //MODO CONSULTAR (Se deja la tabla como estaba)
if ReadOnly then if AEditor.ReadOnly then
SetDataTableReadOnly(ARemesaCliente.DataTable, False); SetDataTableReadOnly(ARemesaCliente.DataTable, False);
finally finally
AEditor.Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
procedure TRemesasClienteController.VerTodos(ARemesasCliente: IBizRemesaCliente); procedure TRemesasClienteController.VerTodos(ARemesasCliente: IBizRemesaCliente);
var var

View File

@ -62,14 +62,11 @@ begin
try try
CreateEditor('EditorRemesasClientePreview', IEditorRemesasClientePreview, AEditor); CreateEditor('EditorRemesasClientePreview', IEditorRemesasClientePreview, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
LoadFromStream(AStream); AEditor.LoadFromStream(AStream);
Preview; AEditor.Preview;
finally finally
Release; AEditor.Release;
end;
end; end;
finally finally
FreeAndNil(AStream); FreeAndNil(AStream);
@ -89,14 +86,11 @@ begin
try try
CreateEditor('EditorRemesasClientePreview', IEditorRemesasClientePreview, AEditor); CreateEditor('EditorRemesasClientePreview', IEditorRemesasClientePreview, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
LoadFromStream(AStream); AEditor.LoadFromStream(AStream);
Print; AEditor.Print;
finally finally
Release; AEditor.Release;
end;
end; end;
finally finally
FreeAndNil(AStream); FreeAndNil(AStream);

View File

@ -63,14 +63,11 @@ begin
try try
CreateEditor('EditorRemesasProveedorPreview', IEditorRemesasProveedorPreview, AEditor); CreateEditor('EditorRemesasProveedorPreview', IEditorRemesasProveedorPreview, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
LoadFromStream(AStream); AEditor.LoadFromStream(AStream);
Preview; AEditor.Preview;
finally finally
Release; AEditor.Release;
end;
end; end;
finally finally
FreeAndNil(AStream); FreeAndNil(AStream);
@ -91,14 +88,11 @@ begin
try try
CreateEditor('EditorRemesasProveedorPreview', IEditorRemesasProveedorPreview, AEditor); CreateEditor('EditorRemesasProveedorPreview', IEditorRemesasProveedorPreview, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
LoadFromStream(AStream); AEditor.LoadFromStream(AStream);
Print; AEditor.Print;
finally finally
Release; AEditor.Release;
end;
end; end;
finally finally
FreeAndNil(AStream); FreeAndNil(AStream);

View File

@ -214,14 +214,11 @@ begin
AEditor := NIL; AEditor := NIL;
CreateEditor('EditorTipoIVA', IEditorTipoIVA, AEditor); CreateEditor('EditorTipoIVA', IEditorTipoIVA, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
TipoIVA := ATipoIVA; AEditor.TipoIVA := ATipoIVA;
ShowModal; AEditor.ShowModal;
finally finally
Release; AEditor.Release;
end;
end; end;
end; end;
@ -232,17 +229,14 @@ begin
AEditor := NIL; AEditor := NIL;
CreateEditor('EditorTiposIVA', IEditorTiposIVA, AEditor); CreateEditor('EditorTiposIVA', IEditorTiposIVA, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
TiposIVA := ATiposIVA; AEditor.TiposIVA := ATiposIVA;
ShowModal; AEditor.ShowModal;
finally finally
Release; AEditor.Release;
AEditor := NIL; AEditor := NIL;
end; end;
end; end;
end;
function TTiposIVAController.Eliminar(ATipoIVA: IBizTipoIVA): Boolean; function TTiposIVAController.Eliminar(ATipoIVA: IBizTipoIVA): Boolean;
begin begin

View File

@ -146,15 +146,12 @@ begin
AEditor := NIL; AEditor := NIL;
CreateEditor('EditorUnidadesMedida', IEditorUnidadesMedida, AEditor); CreateEditor('EditorUnidadesMedida', IEditorUnidadesMedida, AEditor);
if Assigned(AEditor) then if Assigned(AEditor) then
with AEditor do
begin
try try
Controller := Self; //OJO ORDEN MUY IMPORTANTE AEditor.Controller := Self; //OJO ORDEN MUY IMPORTANTE
UnidadesMedida := AUnidadesMedida; AEditor.UnidadesMedida := AUnidadesMedida;
ShowModal; AEditor.ShowModal;
finally finally
Release; AEditor.Release;
end;
end; end;
end; end;

Binary file not shown.

View File

@ -1,4 +1,4 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> <Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup> <PropertyGroup>
<ProjectGuid>{ebdcd25d-40d7-4146-91ec-a0ea4aa1dcd1}</ProjectGuid> <ProjectGuid>{ebdcd25d-40d7-4146-91ec-a0ea4aa1dcd1}</ProjectGuid>
@ -35,7 +35,7 @@
<Borland.Personality>Delphi.Personality</Borland.Personality> <Borland.Personality>Delphi.Personality</Borland.Personality>
<Borland.ProjectType/> <Borland.ProjectType/>
<BorlandProject> <BorlandProject>
<BorlandProject><Delphi.Personality><Parameters><Parameters Name="UseLauncher">False</Parameters><Parameters Name="LoadAllSymbols">True</Parameters><Parameters Name="LoadUnspecifiedSymbols">False</Parameters><Parameters Name="RunParams">/standalone</Parameters></Parameters><VersionInfo><VersionInfo Name="IncludeVerInfo">True</VersionInfo><VersionInfo Name="AutoIncBuild">False</VersionInfo><VersionInfo Name="MajorVer">1</VersionInfo><VersionInfo Name="MinorVer">4</VersionInfo><VersionInfo Name="Release">5</VersionInfo><VersionInfo Name="Build">0</VersionInfo><VersionInfo Name="Debug">False</VersionInfo><VersionInfo Name="PreRelease">False</VersionInfo><VersionInfo Name="Special">False</VersionInfo><VersionInfo Name="Private">False</VersionInfo><VersionInfo Name="DLL">False</VersionInfo><VersionInfo Name="Locale">3082</VersionInfo><VersionInfo Name="CodePage">1252</VersionInfo></VersionInfo><VersionInfoKeys><VersionInfoKeys Name="CompanyName"></VersionInfoKeys><VersionInfoKeys Name="FileDescription"></VersionInfoKeys><VersionInfoKeys Name="FileVersion">1.4.5.0</VersionInfoKeys><VersionInfoKeys Name="InternalName"></VersionInfoKeys><VersionInfoKeys Name="LegalCopyright"></VersionInfoKeys><VersionInfoKeys Name="LegalTrademarks"></VersionInfoKeys><VersionInfoKeys Name="OriginalFilename"></VersionInfoKeys><VersionInfoKeys Name="ProductName"></VersionInfoKeys><VersionInfoKeys Name="ProductVersion">1.4.5.0</VersionInfoKeys><VersionInfoKeys Name="Comments"></VersionInfoKeys><VersionInfoKeys Name="CompileDate">lunes, 10 de noviembre de 2008 14:07</VersionInfoKeys></VersionInfoKeys><Excluded_Packages /><Source><Source Name="MainSource">FactuGES_Server.dpr</Source></Source></Delphi.Personality></BorlandProject></BorlandProject> <BorlandProject><Delphi.Personality><Parameters><Parameters Name="UseLauncher">False</Parameters><Parameters Name="LoadAllSymbols">True</Parameters><Parameters Name="LoadUnspecifiedSymbols">False</Parameters><Parameters Name="RunParams">/standalone</Parameters></Parameters><VersionInfo><VersionInfo Name="IncludeVerInfo">True</VersionInfo><VersionInfo Name="AutoIncBuild">False</VersionInfo><VersionInfo Name="MajorVer">1</VersionInfo><VersionInfo Name="MinorVer">4</VersionInfo><VersionInfo Name="Release">6</VersionInfo><VersionInfo Name="Build">0</VersionInfo><VersionInfo Name="Debug">False</VersionInfo><VersionInfo Name="PreRelease">False</VersionInfo><VersionInfo Name="Special">False</VersionInfo><VersionInfo Name="Private">False</VersionInfo><VersionInfo Name="DLL">False</VersionInfo><VersionInfo Name="Locale">3082</VersionInfo><VersionInfo Name="CodePage">1252</VersionInfo></VersionInfo><VersionInfoKeys><VersionInfoKeys Name="CompanyName"></VersionInfoKeys><VersionInfoKeys Name="FileDescription"></VersionInfoKeys><VersionInfoKeys Name="FileVersion">1.4.6.0</VersionInfoKeys><VersionInfoKeys Name="InternalName"></VersionInfoKeys><VersionInfoKeys Name="LegalCopyright"></VersionInfoKeys><VersionInfoKeys Name="LegalTrademarks"></VersionInfoKeys><VersionInfoKeys Name="OriginalFilename"></VersionInfoKeys><VersionInfoKeys Name="ProductName"></VersionInfoKeys><VersionInfoKeys Name="ProductVersion">1.4.6.0</VersionInfoKeys><VersionInfoKeys Name="Comments"></VersionInfoKeys><VersionInfoKeys Name="CompileDate">martes, 11 de noviembre de 2008 20:02</VersionInfoKeys></VersionInfoKeys><Excluded_Packages/><Source><Source Name="MainSource">FactuGES_Server.dpr</Source></Source></Delphi.Personality></BorlandProject></BorlandProject>
</ProjectExtensions> </ProjectExtensions>
<Import Project="$(MSBuildBinPath)\Borland.Delphi.Targets"/> <Import Project="$(MSBuildBinPath)\Borland.Delphi.Targets"/>
<ItemGroup> <ItemGroup>

View File

@ -1,7 +1,7 @@
MAINICON ICON "C:\Codigo Tecsitel\Resources\Iconos\Servidor.ico" MAINICON ICON "C:\Codigo Tecsitel\Resources\Iconos\Servidor.ico"
1 VERSIONINFO 1 VERSIONINFO
FILEVERSION 1,4,5,0 FILEVERSION 1,4,6,0
PRODUCTVERSION 1,4,5,0 PRODUCTVERSION 1,4,6,0
FILEFLAGSMASK 0x3FL FILEFLAGSMASK 0x3FL
FILEFLAGS 0x00L FILEFLAGS 0x00L
FILEOS 0x40004L FILEOS 0x40004L
@ -12,9 +12,9 @@ BEGIN
BEGIN BEGIN
BLOCK "0C0A04E4" BLOCK "0C0A04E4"
BEGIN BEGIN
VALUE "FileVersion", "1.4.5.0\0" VALUE "FileVersion", "1.4.6.0\0"
VALUE "ProductVersion", "1.4.5.0\0" VALUE "ProductVersion", "1.4.6.0\0"
VALUE "CompileDate", "miércoles, 12 de noviembre de 2008 18:53\0" VALUE "CompileDate", "jueves, 13 de noviembre de 2008 11:42\0"
END END
END END
BLOCK "VarFileInfo" BLOCK "VarFileInfo"