- Proveedores: indicar si es subcontrata o no.

- Contactos: lista de personal asociado a un contacto (en clientes y proveedores).
- Obras: poder indicar una subcontrata
- Pedidos a proveedor: usar obras como destino del pedido.

git-svn-id: https://192.168.0.254/svn/Proyectos.Tecsitel_FactuGES2/trunk@350 0c75b7a4-871f-7646-8a2f-f78d34cc349f
This commit is contained in:
David Arranz 2008-03-24 20:50:41 +00:00
parent acd42ab3a2
commit e94ba43e81
88 changed files with 4795 additions and 1013 deletions

View File

@ -6680,7 +6680,7 @@ Comments=
<Property name="IgnoreFailure" type="WordBool">False</Property>
<Property name="IncludeCompileDate" type="WordBool">False</Property>
<Property name="IncludeManifest" type="Boolean">False</Property>
<Property name="IncludeVerInfo" type="WordBool">False</Property>
<Property name="IncludeVerInfo" type="WordBool">True</Property>
<Property name="IsAction" type="Boolean">True</Property>
<Property name="IsBreakPoint" type="WordBool">False</Property>
<Property name="IsDebug" type="WordBool">False</Property>
@ -6690,7 +6690,7 @@ Comments=
<Property name="IsSpecial" type="WordBool">False</Property>
<Property name="KeepCFG" type="Boolean">False</Property>
<Property name="LinkProductVersionToFileVersion" type="Boolean">False</Property>
<Property name="Locale" type="Integer">3081</Property>
<Property name="Locale" type="Integer">3082</Property>
<Property MultiValue="0" name="LogToVariable" type="string"></Property>
<Property name="MajorVersion" type="Integer">1</Property>
<Property MultiValue="0" name="ManifestFile" type="string"></Property>
@ -6713,7 +6713,16 @@ Comments=
<Property name="UseProjectSettings" type="TFBUseProjectSettings">[usPackages,usCompiler,usLinker,usVersionInfo]</Property>
<Property name="UsePropertySet" type="Boolean">False</Property>
<Property name="UseVersionFromDOF" type="Boolean">False</Property>
<Property MultiValue="1" name="VersionInfoKeys" type="WideString"><![CDATA[FileVersion=1.0.0.0
<Property MultiValue="1" name="VersionInfoKeys" type="WideString"><![CDATA[CompanyName=
FileDescription=
FileVersion=1.0.0.0
InternalName=
LegalCopyright=
LegalTrademarks=
OriginalFilename=
ProductName=
ProductVersion=1.0.0.0
Comments=
]]>
</Property>
<Property MultiValue="0" name="VersionInfoPropertySetName" type="string"></Property>
@ -6798,7 +6807,7 @@ Comments=
<Property name="IgnoreFailure" type="WordBool">False</Property>
<Property name="IncludeCompileDate" type="WordBool">False</Property>
<Property name="IncludeManifest" type="Boolean">False</Property>
<Property name="IncludeVerInfo" type="WordBool">False</Property>
<Property name="IncludeVerInfo" type="WordBool">True</Property>
<Property name="IsAction" type="Boolean">True</Property>
<Property name="IsBreakPoint" type="WordBool">False</Property>
<Property name="IsDebug" type="WordBool">False</Property>
@ -6808,7 +6817,7 @@ Comments=
<Property name="IsSpecial" type="WordBool">False</Property>
<Property name="KeepCFG" type="Boolean">False</Property>
<Property name="LinkProductVersionToFileVersion" type="Boolean">False</Property>
<Property name="Locale" type="Integer">3081</Property>
<Property name="Locale" type="Integer">3082</Property>
<Property MultiValue="0" name="LogToVariable" type="string"></Property>
<Property name="MajorVersion" type="Integer">1</Property>
<Property MultiValue="0" name="ManifestFile" type="string"></Property>
@ -6831,7 +6840,16 @@ Comments=
<Property name="UseProjectSettings" type="TFBUseProjectSettings">[usPackages,usCompiler,usLinker,usVersionInfo]</Property>
<Property name="UsePropertySet" type="Boolean">False</Property>
<Property name="UseVersionFromDOF" type="Boolean">False</Property>
<Property MultiValue="1" name="VersionInfoKeys" type="WideString"><![CDATA[FileVersion=1.0.0.0
<Property MultiValue="1" name="VersionInfoKeys" type="WideString"><![CDATA[CompanyName=
FileDescription=
FileVersion=1.0.0.0
InternalName=
LegalCopyright=
LegalTrademarks=
OriginalFilename=
ProductName=
ProductVersion=1.0.0.0
Comments=
]]>
</Property>
<Property MultiValue="0" name="VersionInfoPropertySetName" type="string"></Property>
@ -16687,7 +16705,7 @@ Comments=
<Property name="IgnoreFailure" type="WordBool">False</Property>
<Property name="IncludeCompileDate" type="WordBool">False</Property>
<Property name="IncludeManifest" type="Boolean">False</Property>
<Property name="IncludeVerInfo" type="WordBool">False</Property>
<Property name="IncludeVerInfo" type="WordBool">True</Property>
<Property name="IsAction" type="Boolean">True</Property>
<Property name="IsBreakPoint" type="WordBool">False</Property>
<Property name="IsDebug" type="WordBool">False</Property>
@ -16697,7 +16715,7 @@ Comments=
<Property name="IsSpecial" type="WordBool">False</Property>
<Property name="KeepCFG" type="Boolean">False</Property>
<Property name="LinkProductVersionToFileVersion" type="Boolean">False</Property>
<Property name="Locale" type="Integer">3081</Property>
<Property name="Locale" type="Integer">3082</Property>
<Property MultiValue="0" name="LogToVariable" type="string"></Property>
<Property name="MajorVersion" type="Integer">1</Property>
<Property MultiValue="0" name="ManifestFile" type="string"></Property>
@ -16721,7 +16739,16 @@ Comments=
<Property name="UseProjectSettings" type="TFBUseProjectSettings">[usPackages,usCompiler,usLinker,usVersionInfo]</Property>
<Property name="UsePropertySet" type="Boolean">False</Property>
<Property name="UseVersionFromDOF" type="Boolean">False</Property>
<Property MultiValue="1" name="VersionInfoKeys" type="WideString"><![CDATA[FileVersion=1.0.0.0
<Property MultiValue="1" name="VersionInfoKeys" type="WideString"><![CDATA[CompanyName=
FileDescription=
FileVersion=1.0.0.0
InternalName=
LegalCopyright=
LegalTrademarks=
OriginalFilename=
ProductName=
ProductVersion=1.0.0.0
Comments=
]]>
</Property>
<Property MultiValue="0" name="VersionInfoPropertySetName" type="string"></Property>

View File

@ -115,6 +115,9 @@ SET GENERATOR GEN_CONTACTOS_DATOS_BANCO_ID TO 1;
CREATE GENERATOR GEN_CONTACTOS_DIR_ID;
SET GENERATOR GEN_CONTACTOS_DIR_ID TO 1;
CREATE GENERATOR GEN_CONTACTOS_PERSONAL_ID;
SET GENERATOR GEN_CONTACTOS_PERSONAL_ID TO 1;
CREATE GENERATOR GEN_CONTACTOS_ID;
SET GENERATOR GEN_CONTACTOS_ID TO 1;
@ -392,7 +395,7 @@ CREATE TABLE ARTICULOS (
PRECIO_NETO TIPO_IMPORTE,
PRECIO_PORTE TIPO_IMPORTE,
FABRICANTE VARCHAR(255),
REFERENCIA_FABR VARCHAR(255),
REFERENCIA_FABR VARCHAR(255),
FECHA_ALTA TIMESTAMP,
FECHA_MODIFICACION TIMESTAMP,
USUARIO TIPO_USUARIO,
@ -524,6 +527,18 @@ CREATE TABLE CONTACTOS_DIRECCIONES (
FECHA_MODIFICACION TIMESTAMP
);
CREATE TABLE CONTACTOS_DATOS_PERSONAL (
ID TIPO_ID NOT NULL,
ID_CONTACTO TIPO_ID NOT NULL,
NOMBRE VARCHAR(255),
PUESTO VARCHAR(255),
TELEFONO VARCHAR(25),
MOVIL VARCHAR(25),
FAX VARCHAR(25),
EMAIL VARCHAR(255),
FECHA_ALTA TIMESTAMP,
FECHA_MODIFICACION TIMESTAMP
);
CREATE TABLE EMPLEADOS_DATOS (
ID_EMPLEADO TIPO_ID NOT NULL,
@ -790,7 +805,8 @@ CREATE TABLE OBRAS (
FAX VARCHAR(25),
PERSONA_CONTACTO VARCHAR(255),
OBSERVACIONES TIPO_NOTAS,
ID_CLIENTE TIPO_ID,
ID_CLIENTE TIPO_ID,
ID_SUBCONTRATA TIPO_ID,
FECHA_ALTA TIMESTAMP,
FECHA_MODIFICACION TIMESTAMP,
USUARIO TIPO_USUARIO
@ -889,6 +905,7 @@ CREATE TABLE PEDIDOS_PROVEEDOR (
FECHA_CONFIRMACION DATE,
FECHA_ENTREGA DATE,
ID_ALMACEN TIPO_ID,
ID_OBRA TIPO_ID,
OBSERVACIONES TIPO_NOTAS,
INCIDENCIAS TIPO_NOTAS,
INCIDENCIAS_ACTIVAS SMALLINT DEFAULT 0 NOT NULL,
@ -923,7 +940,7 @@ CREATE TABLE PEDIDOS_PROVEEDOR_DETALLES (
ID_ARTICULO TIPO_ID,
CONCEPTO TIPO_CONCEPTO,
CANTIDAD INTEGER,
UNIDAD_MEDIDA VARCHAR(255),
UNIDAD_MEDIDA VARCHAR(255),
IMPORTE_UNIDAD TIPO_IMPORTE,
DESCUENTO TIPO_PORCENTAJE,
IMPORTE_PORTE TIPO_IMPORTE,
@ -992,7 +1009,7 @@ CREATE TABLE PRESUPUESTOS_CLIENTE_DETALLES (
ID_ARTICULO TIPO_ID,
CONCEPTO TIPO_CONCEPTO,
CANTIDAD INTEGER,
UNIDAD_MEDIDA VARCHAR(255),
UNIDAD_MEDIDA VARCHAR(255),
IMPORTE_UNIDAD TIPO_IMPORTE,
DESCUENTO TIPO_PORCENTAJE,
IMPORTE_PORTE TIPO_IMPORTE,
@ -1014,7 +1031,8 @@ CREATE TABLE PROVEEDORES_DATOS (
DESCRIPCION_PROVEEDOR VARCHAR(255),
CODIGO_ASIGNADO VARCHAR(255),
CERTIFICACION VARCHAR(255),
HOMOLOGADO SMALLINT
HOMOLOGADO SMALLINT,
SUBCONTRATA TIPO_BOOLEANO
);
@ -1426,7 +1444,7 @@ CREATE VIEW V_ARTICULOS(
NOMBRE_PROVEEDOR,
ELIMINADO,
FABRICANTE,
REFERENCIA_FABR)
REFERENCIA_FABR)
AS
SELECT ARTICULOS.ID, ARTICULOS.ID_EMPRESA, ARTICULOS.REFERENCIA, ARTICULOS.DESCRIPCION,
ARTICULOS.UNIDAD_MEDIDA, ARTICULOS.FAMILIA, ARTICULOS.IMAGEN,
@ -1442,7 +1460,7 @@ SELECT ARTICULOS.ID, ARTICULOS.ID_EMPRESA, ARTICULOS.REFERENCIA, ARTICULOS.DESCR
CONTACTOS.NOMBRE AS NOMBRE_PROVEEDOR,
ARTICULOS.ELIMINADO,
ARTICULOS.FABRICANTE,
ARTICULOS.REFERENCIA_FABR
ARTICULOS.REFERENCIA_FABR
FROM ARTICULOS
LEFT OUTER JOIN CONTACTOS ON (CONTACTOS.ID = ARTICULOS.ID_PROVEEDOR)
WHERE (ARTICULOS.ELIMINADO = 0)
@ -1668,31 +1686,36 @@ WHERE V_CONTACTOS.ID_CATEGORIA = 3
CREATE VIEW V_OBRAS (
ID,
ID_EMPRESA,
NOMBRE,
CALLE,
PROVINCIA,
POBLACION,
CODIGO_POSTAL,
TELEFONO,
MOVIL,
FAX,
PERSONA_CONTACTO,
OBSERVACIONES,
ID_CLIENTE,
NOMBRE_CLIENTE,
FECHA_ALTA,
FECHA_MODIFICACION,
USUARIO)
ID,
ID_EMPRESA,
NOMBRE,
CALLE,
PROVINCIA,
POBLACION,
CODIGO_POSTAL,
TELEFONO,
MOVIL,
FAX,
PERSONA_CONTACTO,
OBSERVACIONES,
ID_CLIENTE,
NOMBRE_CLIENTE,
ID_SUBCONTRATA,
NOMBRE_SUBCONTRATA,
FECHA_ALTA,
FECHA_MODIFICACION,
USUARIO)
AS
SELECT OBRAS.ID, OBRAS.ID_EMPRESA, OBRAS.NOMBRE,
OBRAS.CALLE, OBRAS.PROVINCIA, OBRAS.POBLACION, OBRAS.CODIGO_POSTAL,
OBRAS.TELEFONO, OBRAS.MOVIL, OBRAS.FAX, OBRAS.PERSONA_CONTACTO,
OBRAS.OBSERVACIONES, OBRAS.ID_CLIENTE, V_CLIENTES.NOMBRE AS NOMBRE_CLIENTE, OBRAS.FECHA_ALTA,
OBRAS.FECHA_MODIFICACION, OBRAS.USUARIO
OBRAS.CALLE, OBRAS.PROVINCIA, OBRAS.POBLACION, OBRAS.CODIGO_POSTAL,
OBRAS.TELEFONO, OBRAS.MOVIL, OBRAS.FAX, OBRAS.PERSONA_CONTACTO,
OBRAS.OBSERVACIONES, OBRAS.ID_CLIENTE, CLIENTES.NOMBRE AS NOMBRE_CLIENTE,
OBRAS.ID_SUBCONTRATA, SUBCONTRATAS.NOMBRE AS NOMBRE_SUBCONTRATA,
OBRAS.FECHA_ALTA, OBRAS.FECHA_MODIFICACION, OBRAS.USUARIO
FROM OBRAS
LEFT OUTER JOIN V_CLIENTES ON (V_CLIENTES.ID = OBRAS.ID_CLIENTE);
LEFT OUTER JOIN CONTACTOS AS CLIENTES ON (CLIENTES .ID = OBRAS.ID_CLIENTE)
LEFT OUTER JOIN CONTACTOS AS SUBCONTRATAS ON (SUBCONTRATAS.ID = OBRAS.ID_SUBCONTRATA)
;
/* View: V_REC_FAC_CLI */
@ -2138,7 +2161,8 @@ CREATE VIEW V_PROVEEDORES(
ID_FORMA_PAGO,
TIENDA_WEB,
HOMOLOGADO,
CERTIFICACION)
CERTIFICACION,
SUBCONTRATA)
AS
SELECT
V_CONTACTOS.ID,
@ -2173,16 +2197,16 @@ SELECT
PROVEEDORES_DATOS.ID_FORMA_PAGO,
PROVEEDORES_DATOS.TIENDA_WEB,
PROVEEDORES_DATOS.HOMOLOGADO,
PROVEEDORES_DATOS.CERTIFICACION
PROVEEDORES_DATOS.CERTIFICACION,
PROVEEDORES_DATOS.SUBCONTRATA
FROM
PROVEEDORES_DATOS
INNER JOIN V_CONTACTOS ON (PROVEEDORES_DATOS.ID_PROVEEDOR = V_CONTACTOS.ID)
V_CONTACTOS
INNER JOIN PROVEEDORES_DATOS ON (PROVEEDORES_DATOS.ID_PROVEEDOR = V_CONTACTOS.ID)
WHERE
V_CONTACTOS.ID_CATEGORIA = 2
;
/* View: V_PEDIDOS_PROVEEDOR */
CREATE VIEW V_PEDIDOS_PROVEEDOR(
ID,
@ -2197,6 +2221,8 @@ CREATE VIEW V_PEDIDOS_PROVEEDOR(
FECHA_ENTREGA,
ID_ALMACEN,
NOMBRE_ALMACEN,
ID_OBRA,
NOMBRE_OBRA,
OBSERVACIONES,
IMPORTE_TOTAL,
INCIDENCIAS,
@ -2234,6 +2260,8 @@ SELECT
PEDIDOS_PROVEEDOR.FECHA_ENTREGA,
PEDIDOS_PROVEEDOR.ID_ALMACEN,
ALMACENES.NOMBRE AS NOMBRE_ALMACEN,
PEDIDOS_PROVEEDOR.ID_OBRA,
OBRAS.NOMBRE AS NOMBRE_OBRA,
PEDIDOS_PROVEEDOR.OBSERVACIONES,
PEDIDOS_PROVEEDOR.IMPORTE_TOTAL,
PEDIDOS_PROVEEDOR.INCIDENCIAS,
@ -2262,6 +2290,7 @@ FROM
INNER JOIN V_PROVEEDORES ON (PEDIDOS_PROVEEDOR.ID_PROVEEDOR = V_PROVEEDORES.ID)
INNER JOIN V_PED_PROV_SITUACION ON (V_PED_PROV_SITUACION.ID_PEDIDO = PEDIDOS_PROVEEDOR.ID)
LEFT OUTER JOIN ALMACENES ON (ALMACENES.ID = PEDIDOS_PROVEEDOR.ID_ALMACEN)
LEFT OUTER JOIN OBRAS ON (OBRAS.ID = PEDIDOS_PROVEEDOR.ID_OBRA)
LEFT OUTER JOIN PEDIDOS_CLIENTE ON (PEDIDOS_CLIENTE.ID = PEDIDOS_PROVEEDOR.ID_PEDIDO_CLIENTE)
;
@ -2546,6 +2575,7 @@ ALTER TABLE CONTACTOS ADD CONSTRAINT PK_CONTACTOS PRIMARY KEY (ID);
ALTER TABLE CONTACTOS_CATEGORIAS ADD CONSTRAINT PK_CONTACTOS_CATEGORIAS PRIMARY KEY (ID_CONTACTO, ID_CATEGORIA);
ALTER TABLE CONTACTOS_DATOS_BANCO ADD CONSTRAINT PK_CONTACTOS_DATOS_BANCO PRIMARY KEY (ID);
ALTER TABLE CONTACTOS_DIRECCIONES ADD CONSTRAINT PK_CONTACTOS_DIR PRIMARY KEY (ID);
ALTER TABLE CONTACTOS_DATOS_PERSONAL ADD CONSTRAINT PK_CONTACTOS_DATOS_PER PRIMARY KEY (ID);
ALTER TABLE EMPLEADOS_DATOS ADD CONSTRAINT PK_EMPLEADOS_DATOS PRIMARY KEY (ID_EMPLEADO);
ALTER TABLE EMPRESAS ADD CONSTRAINT PK_EMPRESAS PRIMARY KEY (ID);
ALTER TABLE EMPRESAS_CONTACTOS ADD CONSTRAINT PK_EMPRESAS_CONTACTOS PRIMARY KEY (ID);
@ -2654,6 +2684,7 @@ CREATE INDEX IDX_CONTACTOS_CATEGORIAS ON CONTACTOS_CATEGORIAS (ID_CONTACTO);
CREATE INDEX IDX_CONTACTOS_CATEGORIAS1 ON CONTACTOS_CATEGORIAS (ID_CATEGORIA);
CREATE INDEX IDX_CONTACTOS_DATOS_BANCO ON CONTACTOS_DATOS_BANCO (ID_CONTACTO);
CREATE INDEX IDX_CONTACTOS_DIR_ID_CONTACTO ON CONTACTOS_DIRECCIONES (ID_CONTACTO);
CREATE INDEX IDX_CONTACTOS_PER_ID_CONTACTO ON CONTACTOS_DATOS_PERSONAL (ID_CONTACTO);
CREATE INDEX IDX_EMPRESAS_CONTACTOS ON EMPRESAS_CONTACTOS (ID_EMPRESA, ID_CONTACTO);
CREATE INDEX IDX_EMPRESAS_USUARIOS ON EMPRESAS_USUARIOS (ID_EMPRESA, ID_USUARIO);
CREATE INDEX IDX_FACTURAS_CLIENTE ON FACTURAS_CLIENTE (ID_FORMA_PAGO);
@ -2675,6 +2706,8 @@ CREATE INDEX IDX_PEDIDOS_CLIENTE_DETALLES1 ON PEDIDOS_CLIENTE_DETALLES (ID_ARTIC
CREATE INDEX IDX_PEDIDOS_PROVEEDOR ON PEDIDOS_PROVEEDOR (ID_PEDIDO_CLIENTE);
CREATE INDEX IDX_PEDIDOS_PROVEEDOR1 ON PEDIDOS_PROVEEDOR (ID_ALMACEN);
CREATE INDEX IDX_PEDIDOS_PROVEEDOR2 ON PEDIDOS_PROVEEDOR (ID_FORMA_PAGO);
CREATE INDEX IDX_PEDIDOS_PROVEEDOR3 ON PEDIDOS_PROVEEDOR (ID_OBRA);
CREATE INDEX IDX_PEDIDOS_PROVEEDOR4 ON PEDIDOS_PROVEEDOR (ID_PROVEEDOR);
CREATE INDEX IDX_PEDIDOS_PROVEEDOR_DETALLES ON PEDIDOS_PROVEEDOR_DETALLES (ID_ARTICULO);
CREATE INDEX IDX_PROVEEDORES_DATOS ON PROVEEDORES_DATOS (ID_TIPO_IVA);
CREATE INDEX IDX_PROVEEDORES_DATOS1 ON PROVEEDORES_DATOS (ID_FORMA_PAGO);
@ -2799,7 +2832,7 @@ returns (
referencia varchar(255),
concepto varchar(2000),
cantidad integer,
unidad_medida varchar(255),
unidad_medida varchar(255),
importe_unidad numeric(11,2),
descuento float,
importe_porte numeric(11,2),

View File

@ -9,8 +9,8 @@ const
{ Data table rules ids
Feel free to change them to something more human readable
but make sure they are unique in the context of your application }
RID_Empresas = '{4D4B7384-254D-4DEE-A7C6-15C6D95FE62C}';
RID_EmpresasDatosBanco = '{A13C092F-8B20-475E-AB73-BC64846EC069}';
RID_Empresas = '{C3D4A098-DEBE-4C2B-B91E-7371A6FA2608}';
RID_EmpresasDatosBanco = '{30C8046D-7C1C-4CFB-B7F3-CEA665F701F5}';
{ Data table names }
nme_Empresas = 'Empresas';
@ -91,7 +91,7 @@ const
type
{ IEmpresas }
IEmpresas = interface(IDAStronglyTypedDataTable)
['{94D82008-5773-4226-8E6F-8F86C4BC613C}']
['{1D920893-489E-4359-A55A-9146247372EF}']
{ Property getters and setters }
function GetIDValue: Integer;
procedure SetIDValue(const aValue: Integer);
@ -390,7 +390,7 @@ type
{ IEmpresasDatosBanco }
IEmpresasDatosBanco = interface(IDAStronglyTypedDataTable)
['{3FB044E3-CC5B-45D7-BE74-941172D25782}']
['{DB4CAAE0-5E1D-41E0-9B92-3F41A237F812}']
{ Property getters and setters }
function GetIDValue: Integer;
procedure SetIDValue(const aValue: Integer);

View File

@ -9,13 +9,13 @@ const
{ Delta rules ids
Feel free to change them to something more human readable
but make sure they are unique in the context of your application }
RID_EmpresasDelta = '{B5530DFB-2CAF-472C-9946-BADA26FF23FA}';
RID_EmpresasDatosBancoDelta = '{0F24EA86-6CBB-49BD-BCC2-9B48AC059D72}';
RID_EmpresasDelta = '{6F02EFDD-030E-4464-B393-8062C40DA26A}';
RID_EmpresasDatosBancoDelta = '{601F0536-A7EC-45DF-8E25-B741AB86A055}';
type
{ IEmpresasDelta }
IEmpresasDelta = interface(IEmpresas)
['{B5530DFB-2CAF-472C-9946-BADA26FF23FA}']
['{6F02EFDD-030E-4464-B393-8062C40DA26A}']
{ Property getters and setters }
function GetOldIDValue : Integer;
function GetOldNIF_CIFValue : String;
@ -315,7 +315,7 @@ type
{ IEmpresasDatosBancoDelta }
IEmpresasDatosBancoDelta = interface(IEmpresasDatosBanco)
['{0F24EA86-6CBB-49BD-BCC2-9B48AC059D72}']
['{601F0536-A7EC-45DF-8E25-B741AB86A055}']
{ Property getters and setters }
function GetOldIDValue : Integer;
function GetOldID_EMPRESAValue : Integer;

View File

@ -53,58 +53,58 @@
<DelphiCompile Include="Base.dpk">
<MainSource>MainSource</MainSource>
</DelphiCompile>
<DCCReference Include="..\Modulos\Pedidos a proveedor\Model\adortl.dcp" />
<DCCReference Include="..\Modulos\Pedidos a proveedor\Model\cxDataD11.dcp" />
<DCCReference Include="..\Modulos\Pedidos a proveedor\Model\cxEditorsD11.dcp" />
<DCCReference Include="..\Modulos\Pedidos a proveedor\Model\cxExportD11.dcp" />
<DCCReference Include="..\Modulos\Pedidos a proveedor\Model\cxExtEditorsD11.dcp" />
<DCCReference Include="..\Modulos\Pedidos a proveedor\Model\cxGridD11.dcp" />
<DCCReference Include="..\Modulos\Pedidos a proveedor\Model\cxIntl6D11.dcp" />
<DCCReference Include="..\Modulos\Pedidos a proveedor\Model\cxIntlPrintSys3D11.dcp" />
<DCCReference Include="..\Modulos\Pedidos a proveedor\Model\cxLibraryD11.dcp" />
<DCCReference Include="..\Modulos\Pedidos a proveedor\Model\cxPageControlD11.dcp" />
<DCCReference Include="..\Modulos\Pedidos a proveedor\Model\DataAbstract_Core_D11.dcp" />
<DCCReference Include="..\Modulos\Pedidos a proveedor\Model\dbrtl.dcp" />
<DCCReference Include="..\Modulos\Pedidos a proveedor\Model\dclIndyCore.dcp" />
<DCCReference Include="..\Modulos\Pedidos a proveedor\Model\designide.dcp" />
<DCCReference Include="..\Modulos\Pedidos a proveedor\Model\dsnap.dcp" />
<DCCReference Include="..\Modulos\Pedidos a proveedor\Model\dxGDIPlusD11.dcp" />
<DCCReference Include="..\Modulos\Pedidos a proveedor\Model\dxPSCoreD11.dcp" />
<DCCReference Include="..\Modulos\Pedidos a proveedor\Model\dxThemeD11.dcp" />
<DCCReference Include="..\Modulos\Pedidos a proveedor\Model\GUISDK_D11.dcp" />
<DCCReference Include="..\Modulos\Pedidos a proveedor\Model\IndyCore.dcp" />
<DCCReference Include="..\Modulos\Pedidos a proveedor\Model\IndyProtocols.dcp" />
<DCCReference Include="..\Modulos\Pedidos a proveedor\Model\IndySystem.dcp" />
<DCCReference Include="..\Modulos\Pedidos a proveedor\Model\Jcl.dcp" />
<DCCReference Include="..\Modulos\Pedidos a proveedor\Model\JclVcl.dcp" />
<DCCReference Include="..\Modulos\Pedidos a proveedor\Model\JSDialog100.dcp" />
<DCCReference Include="..\Modulos\Pedidos a proveedor\Model\JvCmpD11R.dcp" />
<DCCReference Include="..\Modulos\Pedidos a proveedor\Model\JvCoreD11R.dcp" />
<DCCReference Include="..\Modulos\Pedidos a proveedor\Model\JvCtrlsD11R.dcp" />
<DCCReference Include="..\Modulos\Pedidos a proveedor\Model\JvDlgsD11R.dcp" />
<DCCReference Include="..\Modulos\Pedidos a proveedor\Model\JvMMD11R.dcp" />
<DCCReference Include="..\Modulos\Pedidos a proveedor\Model\JvNetD11R.dcp" />
<DCCReference Include="..\Modulos\Pedidos a proveedor\Model\JvPageCompsD11R.dcp" />
<DCCReference Include="..\Modulos\Pedidos a proveedor\Model\JvStdCtrlsD11R.dcp" />
<DCCReference Include="..\Modulos\Pedidos a proveedor\Model\JvSystemD11R.dcp" />
<DCCReference Include="..\Modulos\Pedidos a proveedor\Model\pckMD5.dcp" />
<DCCReference Include="..\Modulos\Pedidos a proveedor\Model\pckUCDataConnector.dcp" />
<DCCReference Include="..\Modulos\Pedidos a proveedor\Model\pckUserControl_RT.dcp" />
<DCCReference Include="..\Modulos\Pedidos a proveedor\Model\PngComponentsD10.dcp" />
<DCCReference Include="..\Modulos\Pedidos a proveedor\Model\PNG_D10.dcp" />
<DCCReference Include="..\Modulos\Pedidos a proveedor\Model\RemObjects_Core_D11.dcp" />
<DCCReference Include="..\Modulos\Pedidos a proveedor\Model\RemObjects_Indy_D11.dcp" />
<DCCReference Include="..\Modulos\Pedidos a proveedor\Model\rtl.dcp" />
<DCCReference Include="..\Modulos\Pedidos a proveedor\Model\TB2k_D10.dcp" />
<DCCReference Include="..\Modulos\Pedidos a proveedor\Model\tbx_d10.dcp" />
<DCCReference Include="..\Modulos\Pedidos a proveedor\Model\vcl.dcp" />
<DCCReference Include="..\Modulos\Pedidos a proveedor\Model\vclactnband.dcp" />
<DCCReference Include="..\Modulos\Pedidos a proveedor\Model\vcldb.dcp" />
<DCCReference Include="..\Modulos\Pedidos a proveedor\Model\vcljpg.dcp" />
<DCCReference Include="..\Modulos\Pedidos a proveedor\Model\VclSmp.dcp" />
<DCCReference Include="..\Modulos\Pedidos a proveedor\Model\vclx.dcp" />
<DCCReference Include="..\Modulos\Pedidos a proveedor\Model\xmlrtl.dcp" />
<DCCReference Include="..\Servicios\FactuGES_Intf.pas" />
<DCCReference Include="C:\Documents and Settings\Usuario\adortl.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\cxDataD11.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\cxEditorsD11.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\cxExportD11.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\cxExtEditorsD11.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\cxGridD11.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\cxIntl6D11.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\cxIntlPrintSys3D11.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\cxLibraryD11.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\cxPageControlD11.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\DataAbstract_Core_D11.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\dbrtl.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\dclIndyCore.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\designide.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\dsnap.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\dxGDIPlusD11.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\dxPSCoreD11.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\dxThemeD11.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\GUISDK_D11.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\IndyCore.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\IndyProtocols.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\IndySystem.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\Jcl.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\JclVcl.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\JSDialog100.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\JvCmpD11R.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\JvCoreD11R.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\JvCtrlsD11R.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\JvDlgsD11R.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\JvMMD11R.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\JvNetD11R.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\JvPageCompsD11R.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\JvStdCtrlsD11R.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\JvSystemD11R.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\pckMD5.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\pckUCDataConnector.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\pckUserControl_RT.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\PngComponentsD10.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\PNG_D10.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\RemObjects_Core_D11.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\RemObjects_Indy_D11.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\rtl.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\TB2k_D10.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\tbx_d10.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\vcl.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\vclactnband.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\vcldb.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\vcljpg.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\VclSmp.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\vclx.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\xmlrtl.dcp" />
<DCCReference Include="Conexion\uConfigurarConexion.pas">
<Form>fConfigurarConexion</Form>
<DesignClass>TForm</DesignClass>

View File

@ -63,6 +63,8 @@ contains
uEtiquetasContactosReportController in 'uEtiquetasContactosReportController.pas',
uIEditorEtiquetasContactosPreview in 'View\uIEditorEtiquetasContactosPreview.pas',
uDatosBancariosContactoController in 'uDatosBancariosContactoController.pas',
uIEditorDatoBancarioContacto in 'View\uIEditorDatoBancarioContacto.pas';
uIEditorDatoBancarioContacto in 'View\uIEditorDatoBancarioContacto.pas',
uPersonalContactoController in 'uPersonalContactoController.pas',
uIEditorPersonalContacto in 'View\uIEditorPersonalContacto.pas';
end.

View File

@ -49,27 +49,6 @@
<Excluded_Packages Name="D:\MISDOC~1\BORLAN~1\Bpl\JclDebugExpert100.bpl">JCL Debug IDE extension</Excluded_Packages>
<Excluded_Packages Name="D:\MISDOC~1\BORLAN~1\Bpl\JclProjectAnalysisExpert100.bpl">JCL Project Analyzer</Excluded_Packages>
<Excluded_Packages Name="D:\MISDOC~1\BORLAN~1\Bpl\JclFavoriteFoldersExpert100.bpl">JCL Open and Save IDE dialogs with favorite folders</Excluded_Packages>
@ -90,6 +69,7 @@
<DCCReference Include="uGruposClienteController.pas" />
<DCCReference Include="uGruposEmpleadoController.pas" />
<DCCReference Include="uGruposProveedorController.pas" />
<DCCReference Include="uPersonalContactoController.pas" />
<DCCReference Include="uProveedoresController.pas" />
<DCCReference Include="View\ApplicationBase.dcp" />
<DCCReference Include="View\Base.dcp" />
@ -114,6 +94,7 @@
<DCCReference Include="View\uIEditorGruposCliente.pas" />
<DCCReference Include="View\uIEditorGruposEmpleado.pas" />
<DCCReference Include="View\uIEditorGruposProveedor.pas" />
<DCCReference Include="View\uIEditorPersonalContacto.pas" />
<DCCReference Include="View\uIEditorProveedor.pas" />
<DCCReference Include="View\uIEditorProveedores.pas" />
<DCCReference Include="View\vcl.dcp" />

View File

@ -0,0 +1,28 @@
unit uIEditorPersonalContacto;
interface
uses
uBizContactosPersonal, uPersonalContactoController;
type
IEditorPersonalContacto = interface
['{2221A124-2ECF-426A-A462-24CC87AC26EC}']
function GetController : IPersonalContactoController;
procedure SetController (const Value : IPersonalContactoController);
property Controller : IPersonalContactoController read GetController
write SetController;
function GetPersonal: IBizContactoPersonal;
procedure SetPersonal(const Value: IBizContactoPersonal);
property Personal: IBizContactoPersonal read GetPersonal write SetPersonal;
function ShowModal : Integer;
procedure Release;
end;
implementation
end.

View File

@ -0,0 +1,89 @@
unit uPersonalContactoController;
interface
uses
Windows, Forms, Classes, Controls, Contnrs, SysUtils, uDADataTable,
uBizContactos, uBizContactosPersonal, uIDataModuleContactos,
uControllerBase;
type
IPersonalContactoController = interface(IControllerBase)
['{2A848939-9558-40DA-9886-F34D72331DA9}']
procedure Ver(APersonal : IBizContactoPersonal);
function Localizar(APersonal: IBizContactoPersonal; const ID : Integer): Boolean;
end;
TPersonalContactoController = class(TControllerBase, IPersonalContactoController)
private
FDataModule : IDataModuleContactos;
public
procedure Ver(APersonal : IBizContactoPersonal);
function Localizar(APersonal: IBizContactoPersonal; const ID : Integer): Boolean;
constructor Create; virtual;
destructor Destroy; override;
end;
implementation
{ TPersonalContactoController }
uses
uDataModuleContactos, schContactosClient_Intf, uIEditorPersonalContacto,
uEditorRegistryUtils, cxControls;
constructor TPersonalContactoController.Create;
begin
inherited;
FDataModule := TDataModuleContactos.Create(Nil);
end;
destructor TPersonalContactoController.Destroy;
begin
FDataModule := Nil;
inherited;
end;
function TPersonalContactoController.Localizar(
APersonal: IBizContactoPersonal; const ID: Integer): Boolean;
begin
Result := True;
ShowHourglassCursor;
try
with APersonal.DataTable do
begin
DisableControls;
First;
if not Locate(fld_PersonalContactoID, ID, []) then
Result := False;
EnableControls;
end;
finally
HideHourglassCursor;
end;
end;
procedure TPersonalContactoController.Ver(
APersonal: IBizContactoPersonal);
var
AEditor : IEditorPersonalContacto;
begin
AEditor := NIL;
ShowHourglassCursor;
try
CreateEditor('EditorPersonalContacto', IEditorPersonalContacto, AEditor);
if Assigned(AEditor) then
with AEditor do
begin
Personal := APersonal;
Controller := Self;
ShowModal;
Release;
end;
finally
AEditor := NIL;
HideHourglassCursor;
end;
end;
end.

View File

@ -9,6 +9,7 @@ uses
type
IProveedoresController = interface(IContactosController)
['{50F10D01-5120-470D-A61D-99FE8A76DF93}']
function BuscarSubcontratas: IBizProveedor;
function BuscarTodosTiendaWeb: IBizProveedor;
function ElegirDireccionEntrega(ADirecciones: IBizDireccionesContacto; AMensaje: String): IBizDireccionesContacto;
function EsEliminable(AProveedor: IBizContacto): Boolean;
@ -29,6 +30,7 @@ type
function Buscar(const ID: Integer): IBizContacto; override;
function BuscarTodos: IBizContacto; override;
function BuscarTodosTiendaWeb: IBizProveedor;
function BuscarSubcontratas: IBizProveedor;
function Nuevo : IBizContacto; override;
procedure Ver(AContacto : IBizContacto); override;
procedure VerTodos(AContactos: IBizContacto); override;
@ -49,7 +51,7 @@ uses
SysUtils, cxControls, Dialogs, uDataModuleProveedores, uEditorRegistryUtils,
uDataTableUtils, uDADataTable, DB, schContactosClient_Intf, uEtiquetasContactosReportController,
uIEditorElegirProveedores, Controls, uIEditorElegirDireccionEntrega,
uEditorGridBase;
uEditorGridBase, uDAInterfaces;
{ TProveedoresController }
@ -59,6 +61,19 @@ begin
FiltrarEmpresa(Result);
end;
function TProveedoresController.BuscarSubcontratas: IBizProveedor;
var
Condicion: TDAWhereExpression;
begin
Result := BuscarTodos as IBizProveedor;
with Result.DataTable.DynamicWhere do
begin
Condicion := NewBinaryExpression(NewField('', fld_ProveedoresSUBCONTRATA), NewConstant(1, datInteger), dboEqual);
Clear;
Expression := Condicion
end;
end;
function TProveedoresController.BuscarTodos: IBizContacto;
begin
Result := (FDataModule as IDataModuleProveedores).GetItems;

View File

@ -49,12 +49,12 @@
<DelphiCompile Include="Contactos_data.dpk">
<MainSource>MainSource</MainSource>
</DelphiCompile>
<DCCReference Include="..\ApplicationBase.dcp" />
<DCCReference Include="..\Base.dcp" />
<DCCReference Include="..\Contactos_model.dcp" />
<DCCReference Include="..\GUIBase.dcp" />
<DCCReference Include="..\rtl.dcp" />
<DCCReference Include="..\vcl.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\ApplicationBase.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\GUIBase.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\rtl.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\vcl.dcp" />
<DCCReference Include="uDataModuleClientes.pas">
<Form>DataModuleClientes</Form>
<DesignClass>TDAClientDataModule</DesignClass>
@ -76,7 +76,7 @@
</Project>
<!-- EurekaLog First Line
[Exception Log]
EurekaLog Version=6006
EurekaLog Version=6011
Activate=0
Activate Handle=1
Save Log File=1

View File

@ -174,6 +174,13 @@ inherited DataModuleClientes: TDataModuleClientes
inherited ds_DatosBancarios: TDADataSource
DataSet = tbl_DatosBancarios.Dataset
end
inherited tbl_PersonalContacto: TDAMemDataTable
Left = 440
end
inherited ds_PersonalContacto: TDADataSource
DataSet = tbl_PersonalContacto.Dataset
Left = 440
end
object tbl_Clientes: TDAMemDataTable
RemoteUpdatesOptions = []
Fields = <
@ -202,7 +209,6 @@ inherited DataModuleClientes: TDataModuleClientes
Name = 'NOMBRE'
DataType = datString
Size = 255
Required = True
DisplayLabel = 'Nombre'
DictionaryEntry = 'Contactos_NOMBRE'
end
@ -266,6 +272,7 @@ inherited DataModuleClientes: TDataModuleClientes
Name = 'MOVIL_2'
DataType = datString
Size = 25
DisplayLabel = 'M'#243'vil 2'
DictionaryEntry = 'Contactos_MOVIL_2'
end
item

View File

@ -93,6 +93,7 @@ begin
DatosBancarios := _GetDatosBancarios;
Direcciones := _GetDirecciones;
Descuentos := _GetDescuentos;
Personal := _GetPersonal;
end;
Result := (AContacto as IBizCliente);

View File

@ -2,7 +2,7 @@ inherited DataModuleContactos: TDataModuleContactos
OnCreate = DAClientDataModuleCreate
OnDestroy = DataModuleDestroy
Height = 306
Width = 595
Width = 561
object RORemoteService: TRORemoteService
Message = dmConexion.ROMessage
Channel = dmConexion.ROChannel
@ -50,7 +50,6 @@ inherited DataModuleContactos: TDataModuleContactos
Name = 'NOMBRE'
DataType = datString
Size = 255
Required = True
DisplayLabel = 'Nombre'
DictionaryEntry = 'Contactos_NOMBRE'
end
@ -114,6 +113,7 @@ inherited DataModuleContactos: TDataModuleContactos
Name = 'MOVIL_2'
DataType = datString
Size = 25
DisplayLabel = 'M'#243'vil 2'
DictionaryEntry = 'Contactos_MOVIL_2'
end
item
@ -179,6 +179,7 @@ inherited DataModuleContactos: TDataModuleContactos
DataType = datString
Size = 255
DisplayLabel = 'Referencia'
ServerAutoRefresh = True
DictionaryEntry = 'Contactos_REFERENCIA'
end>
Params = <>
@ -316,13 +317,13 @@ inherited DataModuleContactos: TDataModuleContactos
MasterOptions = [moCascadeOpenClose, moCascadeApplyUpdates, moCascadeDelete, moCascadeUpdate, moDisableLogOfCascadeDeletes, moDisableLogOfCascadeUpdates]
LogicalName = 'DireccionesContacto'
IndexDefs = <>
Left = 448
Left = 320
Top = 16
end
object ds_DireccionesContacto: TDADataSource
DataSet = tbl_DireccionesContacto.Dataset
DataTable = tbl_DireccionesContacto
Left = 448
Left = 320
Top = 80
end
object tbl_DatosBancarios: TDAMemDataTable
@ -405,4 +406,97 @@ inherited DataModuleContactos: TDataModuleContactos
Left = 176
Top = 232
end
object tbl_PersonalContacto: TDAMemDataTable
RemoteUpdatesOptions = []
Fields = <
item
Name = 'ID'
DataType = datAutoInc
GeneratorName = 'GEN_CONTACTOS_PERSONAL_ID'
Required = True
DisplayLabel = 'PersonalContacto_ID'
DictionaryEntry = 'PersonalContacto_ID'
InPrimaryKey = True
end
item
Name = 'ID_CONTACTO'
DataType = datInteger
DisplayLabel = 'PersonalContacto_ID_CONTACTO'
DictionaryEntry = 'PersonalContacto_ID_CONTACTO'
end
item
Name = 'NOMBRE'
DataType = datString
Size = 255
DisplayLabel = 'Nombre'
DictionaryEntry = 'PersonalContacto_NOMBRE'
end
item
Name = 'PUESTO'
DataType = datString
Size = 255
DisplayLabel = 'Puesto'
DictionaryEntry = 'PersonalContacto_PUESTO'
end
item
Name = 'TELEFONO'
DataType = datString
Size = 25
DisplayLabel = 'Tel'#233'fono'
DictionaryEntry = 'PersonalContacto_TELEFONO'
end
item
Name = 'MOVIL'
DataType = datString
Size = 25
DisplayLabel = 'M'#243'vil'
DictionaryEntry = 'PersonalContacto_MOVIL'
end
item
Name = 'FAX'
DataType = datString
Size = 25
DisplayLabel = 'Fax'
DictionaryEntry = 'PersonalContacto_FAX'
end
item
Name = 'EMAIL'
DataType = datString
Size = 255
DisplayLabel = 'E-mail'
DictionaryEntry = 'PersonalContacto_EMAIL'
end
item
Name = 'FECHA_ALTA'
DataType = datDateTime
DisplayLabel = 'PersonalContacto_FECHA_ALTA'
DictionaryEntry = 'PersonalContacto_FECHA_ALTA'
end
item
Name = 'FECHA_MODIFICACION'
DataType = datDateTime
DisplayLabel = 'PersonalContacto_FECHA_MODIFICACION'
DictionaryEntry = 'PersonalContacto_FECHA_MODIFICACION'
end>
Params = <>
MasterMappingMode = mmWhere
StreamingOptions = [soDisableEventsWhileStreaming]
RemoteDataAdapter = rda_Contactos
LocalDataStreamer = Bin2DataStreamer
MasterSource = ds_Contactos
MasterFields = 'ID'
DetailFields = 'ID_CONTACTO'
DetailOptions = [dtCascadeOpenClose, dtCascadeApplyUpdates, dtAutoFetch, dtCascadeDelete, dtCascadeUpdate, dtDisableLogOfCascadeDeletes, dtDisableLogOfCascadeUpdates, dtIncludeInAllInOneFetch]
MasterOptions = [moCascadeOpenClose, moCascadeApplyUpdates, moCascadeDelete, moCascadeUpdate, moDisableLogOfCascadeDeletes, moDisableLogOfCascadeUpdates]
LogicalName = 'PersonalContacto'
IndexDefs = <>
Left = 456
Top = 16
end
object ds_PersonalContacto: TDADataSource
DataSet = tbl_PersonalContacto.Dataset
DataTable = tbl_PersonalContacto
Left = 456
Top = 80
end
end

View File

@ -11,7 +11,7 @@ uses
uBizDireccionesContacto, uIDataModuleEtiquetasContactosReport,
uIDataModuleContactos, uDADesigntimeCall, uROTypes, uRODynamicRequest,
uDAInterfaces, uDADataStreamer, uDARemoteDataAdapter, uDABin2DataStreamer,
uDAMemDataTable, uDataModuleBase;
uDAMemDataTable, uDataModuleBase, uBizContactosPersonal;
type
TDataModuleContactos = class(TDataModuleBase, IDataModuleContactos, IDataModuleEtiquetasContactosReport)
@ -24,12 +24,15 @@ type
ds_DireccionesContacto: TDADataSource;
tbl_DatosBancarios: TDAMemDataTable;
ds_DatosBancarios: TDADataSource;
tbl_PersonalContacto: TDAMemDataTable;
ds_PersonalContacto: TDADataSource;
procedure DAClientDataModuleCreate(Sender: TObject);
procedure DataModuleDestroy(Sender: TObject);
public
function _GetDatosBancarios : IBizContactosDatosBancarios;
function _GetDirecciones: IBizDireccionesContacto;
function _GetItems (IDCategoria : Integer): IBizContacto; virtual;
function _GetPersonal: IBizContactoPersonal;
// Report
function GetReport(const AContactosID: String): Binary;
@ -118,6 +121,7 @@ begin
begin
DatosBancarios := _GetDatosBancarios;
Direcciones := _GetDirecciones;
Personal := _GetPersonal;
end;
Result := (AContacto as IBizContacto);
@ -126,4 +130,23 @@ begin
end;
end;
function TDataModuleContactos._GetPersonal: IBizContactoPersonal;
var
APersonal : TDAMemDataTable;
begin
ShowHourglassCursor;
try
APersonal := CloneDataTable(tbl_PersonalContacto);
with APersonal do
begin
BusinessRulesID := BIZ_CLIENT_CONTACTO_PERSONAL;
DetailOptions := DetailOptions -
[dtDisableLogOfCascadeDeletes, dtDisableLogOfCascadeUpdates];
end;
Result := (APersonal as IBizContactoPersonal);
finally
HideHourglassCursor;
end;
end;
end.

View File

@ -1,4 +1,6 @@
inherited DataModuleEmpleados: TDataModuleEmpleados
Height = 302
Width = 543
inherited tbl_Contactos: TDAMemDataTable
Fields = <
item
@ -166,6 +168,9 @@ inherited DataModuleEmpleados: TDataModuleEmpleados
inherited ds_DatosBancarios: TDADataSource
DataSet = tbl_DatosBancarios.Dataset
end
inherited ds_PersonalContacto: TDADataSource
DataSet = tbl_PersonalContacto.Dataset
end
object tbl_Empleados: TDAMemDataTable
RemoteUpdatesOptions = []
Fields = <
@ -194,7 +199,6 @@ inherited DataModuleEmpleados: TDataModuleEmpleados
Name = 'NOMBRE'
DataType = datString
Size = 255
Required = True
DisplayLabel = 'Nombre'
DictionaryEntry = 'Contactos_NOMBRE'
end

View File

@ -1,6 +1,6 @@
inherited DataModuleProveedores: TDataModuleProveedores
Height = 311
Width = 550
Width = 632
inherited ds_Contactos: TDADataSource
DataSet = tbl_Contactos.Dataset
end
@ -10,6 +10,15 @@ inherited DataModuleProveedores: TDataModuleProveedores
inherited ds_DatosBancarios: TDADataSource
DataSet = tbl_DatosBancarios.Dataset
end
inherited tbl_PersonalContacto: TDAMemDataTable
Left = 408
Top = 176
end
inherited ds_PersonalContacto: TDADataSource
DataSet = tbl_PersonalContacto.Dataset
Left = 408
Top = 240
end
object tbl_GruposProveedor: TDAMemDataTable
RemoteUpdatesOptions = []
Fields = <
@ -36,14 +45,14 @@ inherited DataModuleProveedores: TDataModuleProveedores
MasterOptions = [moCascadeOpenClose, moCascadeApplyUpdates, moCascadeDelete, moCascadeUpdate, moDisableLogOfCascadeDeletes, moDisableLogOfCascadeUpdates]
LogicalName = 'GruposProveedor'
IndexDefs = <>
Left = 448
Top = 168
Left = 536
Top = 176
end
object ds_GruposProveedor: TDADataSource
DataSet = tbl_GruposProveedor.Dataset
DataTable = tbl_GruposProveedor
Left = 448
Top = 232
Left = 536
Top = 240
end
object tbl_Proveedores: TDAMemDataTable
RemoteUpdatesOptions = []
@ -73,7 +82,6 @@ inherited DataModuleProveedores: TDataModuleProveedores
Name = 'NOMBRE'
DataType = datString
Size = 255
Required = True
DisplayLabel = 'Nombre'
DictionaryEntry = 'Contactos_NOMBRE'
end
@ -137,6 +145,7 @@ inherited DataModuleProveedores: TDataModuleProveedores
Name = 'MOVIL_2'
DataType = datString
Size = 25
DisplayLabel = 'M'#243'vil 2'
DictionaryEntry = 'Contactos_MOVIL_2'
end
item
@ -177,10 +186,14 @@ inherited DataModuleProveedores: TDataModuleProveedores
item
Name = 'FECHA_ALTA'
DataType = datDateTime
DisplayLabel = 'Proveedores_FECHA_ALTA'
DictionaryEntry = 'Proveedores_FECHA_ALTA'
end
item
Name = 'FECHA_MODIFICACION'
DataType = datDateTime
DisplayLabel = 'Proveedores_FECHA_MODIFICACION'
DictionaryEntry = 'Proveedores_FECHA_MODIFICACION'
end
item
Name = 'USUARIO'
@ -225,7 +238,8 @@ inherited DataModuleProveedores: TDataModuleProveedores
item
Name = 'GRUPO_PROVEEDOR'
DataType = datString
Size = 255
DisplayLabel = 'Grupo proveedor'
DictionaryEntry = 'Proveedores_GRUPO_PROVEEDOR'
end
item
Name = 'REGIMEN_IVA'
@ -261,6 +275,12 @@ inherited DataModuleProveedores: TDataModuleProveedores
Size = 255
DisplayLabel = 'Certificaciones'
DictionaryEntry = 'Proveedores_CERTIFICACION'
end
item
Name = 'SUBCONTRATA'
DataType = datSmallInt
DisplayLabel = 'Subcontrata'
DictionaryEntry = 'Proveedores_SUBCONTRATA'
end>
Params = <>
StreamingOptions = [soDisableEventsWhileStreaming]

View File

@ -93,6 +93,7 @@ begin
begin
DatosBancarios := _GetDatosBancarios;
Direcciones := _GetDirecciones;
Personal := _GetPersonal;
end;
Result := (AContacto as IBizProveedor);

View File

@ -47,6 +47,7 @@ contains
uIDataModuleFichasEmpleadoReport in 'Data\uIDataModuleFichasEmpleadoReport.pas',
uIDataModuleEtiquetasContactosReport in 'Data\uIDataModuleEtiquetasContactosReport.pas',
schContactosClient_Intf in 'schContactosClient_Intf.pas',
schContactosServer_Intf in 'schContactosServer_Intf.pas';
schContactosServer_Intf in 'schContactosServer_Intf.pas',
uBizContactosPersonal in 'uBizContactosPersonal.pas';
end.

View File

@ -65,6 +65,7 @@
<DCCReference Include="uBizClientesDescuentos.pas" />
<DCCReference Include="uBizContactos.pas" />
<DCCReference Include="uBizContactosDatosBancarios.pas" />
<DCCReference Include="uBizContactosPersonal.pas" />
<DCCReference Include="uBizDireccionesContacto.pas" />
<DCCReference Include="uBizGruposCliente.pas" />
<DCCReference Include="uBizGruposEmpleado.pas" />

View File

@ -4,13 +4,16 @@ interface
uses
SysUtils, Classes,
uBizContactos, uBizContactosDatosBancarios;
uBizContactos, uBizContactosDatosBancarios, uBizDireccionesContacto,
uBizContactosPersonal;
type
IDataModuleContactos = interface
['{835FFC4D-1AE9-4020-A042-C9D84EC25A2C}']
function _GetItems (IDCategoria : Integer): IBizContacto;
function _GetDatosBancarios : IBizContactosDatosBancarios;
function _GetDirecciones: IBizDireccionesContacto;
function _GetPersonal: IBizContactoPersonal;
end;
implementation

View File

@ -9,19 +9,20 @@ const
{ Data table rules ids
Feel free to change them to something more human readable
but make sure they are unique in the context of your application }
RID_Contactos = '{A4D7F874-9AA6-478C-AAB9-8C72B89D5587}';
RID_GruposCliente = '{1C96451B-7D16-472A-8A32-1980C73168F1}';
RID_DatosBancarios = '{17AE17CD-D4F4-49B3-8EB5-001FAC1E35A9}';
RID_Clientes = '{DF344842-83AC-4CD8-BF84-C4AD0BF0BC4C}';
RID_Proveedores = '{FEC4E64E-F9A3-4CCC-8FF4-95D40EF5D976}';
RID_Empleados = '{60C35CF4-7BCF-4B5F-B49B-97C322134C9F}';
RID_DireccionesContacto = '{9A84C7A3-D210-451C-A3C6-4E68505DCC05}';
RID_ClientesDescuentos = '{064EFA39-B948-4B38-BB8B-D2BDF7A9A889}';
RID_GruposProveedor = '{AAA36EB6-1D98-4A1E-B26C-70DB3B6970D4}';
RID_GruposEmpleado = '{F3EC9B3B-3E20-4A89-89BD-78CF3DDC024A}';
RID_Contactos_Refresh = '{8A0B1D05-EF34-47A3-B06C-2AA9942097E2}';
RID_ContratosEmpleados = '{048968BF-970A-4A6E-B42D-C2083E283280}';
RID_DescripcionesProveedores = '{505162D5-88A0-4873-8205-7BD33AE36269}';
RID_Contactos = '{93EE37EB-EC83-4592-8FE0-7213976D576D}';
RID_GruposCliente = '{405EBA8C-423C-4F5C-A73D-C2ED7FADCF50}';
RID_DatosBancarios = '{553F9CFD-FE58-4438-A870-320A6710FCBB}';
RID_Clientes = '{E6D1F0FB-258F-418D-A500-D78BFF26BDD9}';
RID_Proveedores = '{4A0F6766-6036-4C05-8C74-5353D2DA1E2B}';
RID_Empleados = '{5D29F2D4-A1FA-491F-A55F-E0FD6580AF8D}';
RID_DireccionesContacto = '{FBCF230B-6E4D-41E0-A1AA-32B8974AFA2D}';
RID_ClientesDescuentos = '{492B1649-7148-4F9C-AAAD-779E432AAA55}';
RID_GruposProveedor = '{F1D82002-96A0-4752-BC1B-094DE5333C26}';
RID_GruposEmpleado = '{99BFA415-6A6F-4FAD-9BA4-1CA0C43C8703}';
RID_Contactos_Refresh = '{2E88E5F4-9D4C-41EB-8124-B7E11F35EC30}';
RID_ContratosEmpleados = '{EAC10CE6-2393-438D-B2EC-6B42270C7A54}';
RID_DescripcionesProveedores = '{B54CE8F6-BE2F-4585-8FD2-74C9F174B767}';
RID_PersonalContacto = '{E684C573-A7E7-48C0-BA69-47291498ED5B}';
{ Data table names }
nme_Contactos = 'Contactos';
@ -37,6 +38,7 @@ const
nme_Contactos_Refresh = 'Contactos_Refresh';
nme_ContratosEmpleados = 'ContratosEmpleados';
nme_DescripcionesProveedores = 'DescripcionesProveedores';
nme_PersonalContacto = 'PersonalContacto';
{ Contactos fields }
fld_ContactosID = 'ID';
@ -226,6 +228,7 @@ const
fld_ProveedoresTIENDA_WEB = 'TIENDA_WEB';
fld_ProveedoresHOMOLOGADO = 'HOMOLOGADO';
fld_ProveedoresCERTIFICACION = 'CERTIFICACION';
fld_ProveedoresSUBCONTRATA = 'SUBCONTRATA';
{ Proveedores field indexes }
idx_ProveedoresID = 0;
@ -261,6 +264,7 @@ const
idx_ProveedoresTIENDA_WEB = 30;
idx_ProveedoresHOMOLOGADO = 31;
idx_ProveedoresCERTIFICACION = 32;
idx_ProveedoresSUBCONTRATA = 33;
{ Empleados fields }
fld_EmpleadosID = 'ID';
@ -454,10 +458,34 @@ const
{ DescripcionesProveedores field indexes }
idx_DescripcionesProveedoresDESCRIPCION_PROVEEDOR = 0;
{ PersonalContacto fields }
fld_PersonalContactoID = 'ID';
fld_PersonalContactoID_CONTACTO = 'ID_CONTACTO';
fld_PersonalContactoNOMBRE = 'NOMBRE';
fld_PersonalContactoPUESTO = 'PUESTO';
fld_PersonalContactoTELEFONO = 'TELEFONO';
fld_PersonalContactoMOVIL = 'MOVIL';
fld_PersonalContactoFAX = 'FAX';
fld_PersonalContactoEMAIL = 'EMAIL';
fld_PersonalContactoFECHA_ALTA = 'FECHA_ALTA';
fld_PersonalContactoFECHA_MODIFICACION = 'FECHA_MODIFICACION';
{ PersonalContacto field indexes }
idx_PersonalContactoID = 0;
idx_PersonalContactoID_CONTACTO = 1;
idx_PersonalContactoNOMBRE = 2;
idx_PersonalContactoPUESTO = 3;
idx_PersonalContactoTELEFONO = 4;
idx_PersonalContactoMOVIL = 5;
idx_PersonalContactoFAX = 6;
idx_PersonalContactoEMAIL = 7;
idx_PersonalContactoFECHA_ALTA = 8;
idx_PersonalContactoFECHA_MODIFICACION = 9;
type
{ IContactos }
IContactos = interface(IDAStronglyTypedDataTable)
['{9BC70D6F-DDBB-455A-8ED6-277F6F015990}']
['{E59305EA-4E84-419D-BD85-09D7CCE228B0}']
{ Property getters and setters }
function GetIDValue: Integer;
procedure SetIDValue(const aValue: Integer);
@ -756,7 +784,7 @@ type
{ IGruposCliente }
IGruposCliente = interface(IDAStronglyTypedDataTable)
['{CD452866-91FC-4B57-AF2E-51EFC32955CA}']
['{A5E9E3A7-70E6-497D-A259-BA3D053DFC4E}']
{ Property getters and setters }
function GetIDValue: Integer;
procedure SetIDValue(const aValue: Integer);
@ -803,7 +831,7 @@ type
{ IDatosBancarios }
IDatosBancarios = interface(IDAStronglyTypedDataTable)
['{634A6F68-7F67-4E95-96CF-79E555FD64B4}']
['{8099114C-D422-4D38-922C-E8A3D6AC04DD}']
{ Property getters and setters }
function GetIDValue: Integer;
procedure SetIDValue(const aValue: Integer);
@ -934,7 +962,7 @@ type
{ IClientes }
IClientes = interface(IDAStronglyTypedDataTable)
['{D56F28C2-CEFE-4755-9092-F7D740DED9C9}']
['{F0AA957B-22FD-410C-8BDD-7E51344DDA81}']
{ Property getters and setters }
function GetIDValue: Integer;
procedure SetIDValue(const aValue: Integer);
@ -1377,7 +1405,7 @@ type
{ IProveedores }
IProveedores = interface(IDAStronglyTypedDataTable)
['{6DF906CE-7A60-4F70-B2E1-EF3B18FE5785}']
['{B87D9D38-E5EF-48AE-8462-2651C12521D7}']
{ Property getters and setters }
function GetIDValue: Integer;
procedure SetIDValue(const aValue: Integer);
@ -1510,6 +1538,10 @@ type
procedure SetCERTIFICACIONValue(const aValue: String);
function GetCERTIFICACIONIsNull: Boolean;
procedure SetCERTIFICACIONIsNull(const aValue: Boolean);
function GetSUBCONTRATAValue: SmallInt;
procedure SetSUBCONTRATAValue(const aValue: SmallInt);
function GetSUBCONTRATAIsNull: Boolean;
procedure SetSUBCONTRATAIsNull(const aValue: Boolean);
{ Properties }
@ -1579,6 +1611,8 @@ type
property HOMOLOGADOIsNull: Boolean read GetHOMOLOGADOIsNull write SetHOMOLOGADOIsNull;
property CERTIFICACION: String read GetCERTIFICACIONValue write SetCERTIFICACIONValue;
property CERTIFICACIONIsNull: Boolean read GetCERTIFICACIONIsNull write SetCERTIFICACIONIsNull;
property SUBCONTRATA: SmallInt read GetSUBCONTRATAValue write SetSUBCONTRATAValue;
property SUBCONTRATAIsNull: Boolean read GetSUBCONTRATAIsNull write SetSUBCONTRATAIsNull;
end;
{ TProveedoresDataTableRules }
@ -1719,6 +1753,10 @@ type
procedure SetCERTIFICACIONValue(const aValue: String); virtual;
function GetCERTIFICACIONIsNull: Boolean; virtual;
procedure SetCERTIFICACIONIsNull(const aValue: Boolean); virtual;
function GetSUBCONTRATAValue: SmallInt; virtual;
procedure SetSUBCONTRATAValue(const aValue: SmallInt); virtual;
function GetSUBCONTRATAIsNull: Boolean; virtual;
procedure SetSUBCONTRATAIsNull(const aValue: Boolean); virtual;
{ Properties }
property ID: Integer read GetIDValue write SetIDValue;
@ -1787,6 +1825,8 @@ type
property HOMOLOGADOIsNull: Boolean read GetHOMOLOGADOIsNull write SetHOMOLOGADOIsNull;
property CERTIFICACION: String read GetCERTIFICACIONValue write SetCERTIFICACIONValue;
property CERTIFICACIONIsNull: Boolean read GetCERTIFICACIONIsNull write SetCERTIFICACIONIsNull;
property SUBCONTRATA: SmallInt read GetSUBCONTRATAValue write SetSUBCONTRATAValue;
property SUBCONTRATAIsNull: Boolean read GetSUBCONTRATAIsNull write SetSUBCONTRATAIsNull;
public
constructor Create(aDataTable: TDADataTable); override;
@ -1796,7 +1836,7 @@ type
{ IEmpleados }
IEmpleados = interface(IDAStronglyTypedDataTable)
['{CB027BF3-E930-4108-8992-BC7CB8F78B34}']
['{F05CFAAA-AFD5-4EEA-9153-CCAC4226505B}']
{ Property getters and setters }
function GetIDValue: Integer;
procedure SetIDValue(const aValue: Integer);
@ -2203,7 +2243,7 @@ type
{ IDireccionesContacto }
IDireccionesContacto = interface(IDAStronglyTypedDataTable)
['{9BFD1F3F-13FE-40FC-A5DD-236EBCC45998}']
['{18FB7335-FF1C-4630-8854-17884DC46240}']
{ Property getters and setters }
function GetIDValue: Integer;
procedure SetIDValue(const aValue: Integer);
@ -2418,7 +2458,7 @@ type
{ IClientesDescuentos }
IClientesDescuentos = interface(IDAStronglyTypedDataTable)
['{C0E7C4E7-306A-441E-A310-31D2C8801423}']
['{E5432957-80FF-4189-BB6C-FC5AFF168B06}']
{ Property getters and setters }
function GetIDValue: Integer;
procedure SetIDValue(const aValue: Integer);
@ -2501,7 +2541,7 @@ type
{ IGruposProveedor }
IGruposProveedor = interface(IDAStronglyTypedDataTable)
['{B0E72900-9B72-4A0A-9DB9-F87C56E6A002}']
['{4E1C83AD-248C-4770-8423-06D6781FAD25}']
{ Property getters and setters }
function GetIDValue: Integer;
procedure SetIDValue(const aValue: Integer);
@ -2548,7 +2588,7 @@ type
{ IGruposEmpleado }
IGruposEmpleado = interface(IDAStronglyTypedDataTable)
['{425C3BF6-7FB4-41CE-AB81-CE7220B030ED}']
['{9A44FB5F-D13D-4E10-8C49-288C227EAD86}']
{ Property getters and setters }
function GetIDValue: Integer;
procedure SetIDValue(const aValue: Integer);
@ -2595,7 +2635,7 @@ type
{ IContactos_Refresh }
IContactos_Refresh = interface(IDAStronglyTypedDataTable)
['{BE66BA4F-21CD-4F00-9640-6D2A7C8BC2CA}']
['{4A0B8556-7E34-434D-9A0E-B0C9D491CE4D}']
{ Property getters and setters }
function GetIDValue: Integer;
procedure SetIDValue(const aValue: Integer);
@ -2870,7 +2910,7 @@ type
{ IContratosEmpleados }
IContratosEmpleados = interface(IDAStronglyTypedDataTable)
['{23DC52D6-E760-444F-BB2D-134398ECCB26}']
['{87553D29-875F-488F-861C-29563ABC962F}']
{ Property getters and setters }
function GetCONTRATOValue: String;
procedure SetCONTRATOValue(const aValue: String);
@ -2905,7 +2945,7 @@ type
{ IDescripcionesProveedores }
IDescripcionesProveedores = interface(IDAStronglyTypedDataTable)
['{A512DEBE-E8E2-4E28-852A-E89484CEA0B3}']
['{7F14E7C1-A3ED-4F13-9C58-2375D3663AFC}']
{ Property getters and setters }
function GetDESCRIPCION_PROVEEDORValue: String;
procedure SetDESCRIPCION_PROVEEDORValue(const aValue: String);
@ -2938,6 +2978,149 @@ type
end;
{ IPersonalContacto }
IPersonalContacto = interface(IDAStronglyTypedDataTable)
['{B0636C03-3DAC-4019-974C-EE81DAB0BA70}']
{ Property getters and setters }
function GetIDValue: Integer;
procedure SetIDValue(const aValue: Integer);
function GetIDIsNull: Boolean;
procedure SetIDIsNull(const aValue: Boolean);
function GetID_CONTACTOValue: Integer;
procedure SetID_CONTACTOValue(const aValue: Integer);
function GetID_CONTACTOIsNull: Boolean;
procedure SetID_CONTACTOIsNull(const aValue: Boolean);
function GetNOMBREValue: String;
procedure SetNOMBREValue(const aValue: String);
function GetNOMBREIsNull: Boolean;
procedure SetNOMBREIsNull(const aValue: Boolean);
function GetPUESTOValue: String;
procedure SetPUESTOValue(const aValue: String);
function GetPUESTOIsNull: Boolean;
procedure SetPUESTOIsNull(const aValue: Boolean);
function GetTELEFONOValue: String;
procedure SetTELEFONOValue(const aValue: String);
function GetTELEFONOIsNull: Boolean;
procedure SetTELEFONOIsNull(const aValue: Boolean);
function GetMOVILValue: String;
procedure SetMOVILValue(const aValue: String);
function GetMOVILIsNull: Boolean;
procedure SetMOVILIsNull(const aValue: Boolean);
function GetFAXValue: String;
procedure SetFAXValue(const aValue: String);
function GetFAXIsNull: Boolean;
procedure SetFAXIsNull(const aValue: Boolean);
function GetEMAILValue: String;
procedure SetEMAILValue(const aValue: String);
function GetEMAILIsNull: Boolean;
procedure SetEMAILIsNull(const aValue: Boolean);
function GetFECHA_ALTAValue: DateTime;
procedure SetFECHA_ALTAValue(const aValue: DateTime);
function GetFECHA_ALTAIsNull: Boolean;
procedure SetFECHA_ALTAIsNull(const aValue: Boolean);
function GetFECHA_MODIFICACIONValue: DateTime;
procedure SetFECHA_MODIFICACIONValue(const aValue: DateTime);
function GetFECHA_MODIFICACIONIsNull: Boolean;
procedure SetFECHA_MODIFICACIONIsNull(const aValue: Boolean);
{ Properties }
property ID: Integer read GetIDValue write SetIDValue;
property IDIsNull: Boolean read GetIDIsNull write SetIDIsNull;
property ID_CONTACTO: Integer read GetID_CONTACTOValue write SetID_CONTACTOValue;
property ID_CONTACTOIsNull: Boolean read GetID_CONTACTOIsNull write SetID_CONTACTOIsNull;
property NOMBRE: String read GetNOMBREValue write SetNOMBREValue;
property NOMBREIsNull: Boolean read GetNOMBREIsNull write SetNOMBREIsNull;
property PUESTO: String read GetPUESTOValue write SetPUESTOValue;
property PUESTOIsNull: Boolean read GetPUESTOIsNull write SetPUESTOIsNull;
property TELEFONO: String read GetTELEFONOValue write SetTELEFONOValue;
property TELEFONOIsNull: Boolean read GetTELEFONOIsNull write SetTELEFONOIsNull;
property MOVIL: String read GetMOVILValue write SetMOVILValue;
property MOVILIsNull: Boolean read GetMOVILIsNull write SetMOVILIsNull;
property FAX: String read GetFAXValue write SetFAXValue;
property FAXIsNull: Boolean read GetFAXIsNull write SetFAXIsNull;
property EMAIL: String read GetEMAILValue write SetEMAILValue;
property EMAILIsNull: Boolean read GetEMAILIsNull write SetEMAILIsNull;
property FECHA_ALTA: DateTime read GetFECHA_ALTAValue write SetFECHA_ALTAValue;
property FECHA_ALTAIsNull: Boolean read GetFECHA_ALTAIsNull write SetFECHA_ALTAIsNull;
property FECHA_MODIFICACION: DateTime read GetFECHA_MODIFICACIONValue write SetFECHA_MODIFICACIONValue;
property FECHA_MODIFICACIONIsNull: Boolean read GetFECHA_MODIFICACIONIsNull write SetFECHA_MODIFICACIONIsNull;
end;
{ TPersonalContactoDataTableRules }
TPersonalContactoDataTableRules = class(TIntfObjectDADataTableRules, IPersonalContacto)
private
protected
{ Property getters and setters }
function GetIDValue: Integer; virtual;
procedure SetIDValue(const aValue: Integer); virtual;
function GetIDIsNull: Boolean; virtual;
procedure SetIDIsNull(const aValue: Boolean); virtual;
function GetID_CONTACTOValue: Integer; virtual;
procedure SetID_CONTACTOValue(const aValue: Integer); virtual;
function GetID_CONTACTOIsNull: Boolean; virtual;
procedure SetID_CONTACTOIsNull(const aValue: Boolean); virtual;
function GetNOMBREValue: String; virtual;
procedure SetNOMBREValue(const aValue: String); virtual;
function GetNOMBREIsNull: Boolean; virtual;
procedure SetNOMBREIsNull(const aValue: Boolean); virtual;
function GetPUESTOValue: String; virtual;
procedure SetPUESTOValue(const aValue: String); virtual;
function GetPUESTOIsNull: Boolean; virtual;
procedure SetPUESTOIsNull(const aValue: Boolean); virtual;
function GetTELEFONOValue: String; virtual;
procedure SetTELEFONOValue(const aValue: String); virtual;
function GetTELEFONOIsNull: Boolean; virtual;
procedure SetTELEFONOIsNull(const aValue: Boolean); virtual;
function GetMOVILValue: String; virtual;
procedure SetMOVILValue(const aValue: String); virtual;
function GetMOVILIsNull: Boolean; virtual;
procedure SetMOVILIsNull(const aValue: Boolean); virtual;
function GetFAXValue: String; virtual;
procedure SetFAXValue(const aValue: String); virtual;
function GetFAXIsNull: Boolean; virtual;
procedure SetFAXIsNull(const aValue: Boolean); virtual;
function GetEMAILValue: String; virtual;
procedure SetEMAILValue(const aValue: String); virtual;
function GetEMAILIsNull: Boolean; virtual;
procedure SetEMAILIsNull(const aValue: Boolean); virtual;
function GetFECHA_ALTAValue: DateTime; virtual;
procedure SetFECHA_ALTAValue(const aValue: DateTime); virtual;
function GetFECHA_ALTAIsNull: Boolean; virtual;
procedure SetFECHA_ALTAIsNull(const aValue: Boolean); virtual;
function GetFECHA_MODIFICACIONValue: DateTime; virtual;
procedure SetFECHA_MODIFICACIONValue(const aValue: DateTime); virtual;
function GetFECHA_MODIFICACIONIsNull: Boolean; virtual;
procedure SetFECHA_MODIFICACIONIsNull(const aValue: Boolean); virtual;
{ Properties }
property ID: Integer read GetIDValue write SetIDValue;
property IDIsNull: Boolean read GetIDIsNull write SetIDIsNull;
property ID_CONTACTO: Integer read GetID_CONTACTOValue write SetID_CONTACTOValue;
property ID_CONTACTOIsNull: Boolean read GetID_CONTACTOIsNull write SetID_CONTACTOIsNull;
property NOMBRE: String read GetNOMBREValue write SetNOMBREValue;
property NOMBREIsNull: Boolean read GetNOMBREIsNull write SetNOMBREIsNull;
property PUESTO: String read GetPUESTOValue write SetPUESTOValue;
property PUESTOIsNull: Boolean read GetPUESTOIsNull write SetPUESTOIsNull;
property TELEFONO: String read GetTELEFONOValue write SetTELEFONOValue;
property TELEFONOIsNull: Boolean read GetTELEFONOIsNull write SetTELEFONOIsNull;
property MOVIL: String read GetMOVILValue write SetMOVILValue;
property MOVILIsNull: Boolean read GetMOVILIsNull write SetMOVILIsNull;
property FAX: String read GetFAXValue write SetFAXValue;
property FAXIsNull: Boolean read GetFAXIsNull write SetFAXIsNull;
property EMAIL: String read GetEMAILValue write SetEMAILValue;
property EMAILIsNull: Boolean read GetEMAILIsNull write SetEMAILIsNull;
property FECHA_ALTA: DateTime read GetFECHA_ALTAValue write SetFECHA_ALTAValue;
property FECHA_ALTAIsNull: Boolean read GetFECHA_ALTAIsNull write SetFECHA_ALTAIsNull;
property FECHA_MODIFICACION: DateTime read GetFECHA_MODIFICACIONValue write SetFECHA_MODIFICACIONValue;
property FECHA_MODIFICACIONIsNull: Boolean read GetFECHA_MODIFICACIONIsNull write SetFECHA_MODIFICACIONIsNull;
public
constructor Create(aDataTable: TDADataTable); override;
destructor Destroy; override;
end;
implementation
uses Variants, uROBinaryHelpers;
@ -5164,6 +5347,27 @@ begin
DataTable.Fields[idx_ProveedoresCERTIFICACION].AsVariant := Null;
end;
function TProveedoresDataTableRules.GetSUBCONTRATAValue: SmallInt;
begin
result := DataTable.Fields[idx_ProveedoresSUBCONTRATA].AsSmallInt;
end;
procedure TProveedoresDataTableRules.SetSUBCONTRATAValue(const aValue: SmallInt);
begin
DataTable.Fields[idx_ProveedoresSUBCONTRATA].AsSmallInt := aValue;
end;
function TProveedoresDataTableRules.GetSUBCONTRATAIsNull: boolean;
begin
result := DataTable.Fields[idx_ProveedoresSUBCONTRATA].IsNull;
end;
procedure TProveedoresDataTableRules.SetSUBCONTRATAIsNull(const aValue: Boolean);
begin
if aValue then
DataTable.Fields[idx_ProveedoresSUBCONTRATA].AsVariant := Null;
end;
{ TEmpleadosDataTableRules }
constructor TEmpleadosDataTableRules.Create(aDataTable: TDADataTable);
@ -6982,6 +7186,228 @@ begin
end;
{ TPersonalContactoDataTableRules }
constructor TPersonalContactoDataTableRules.Create(aDataTable: TDADataTable);
begin
inherited;
end;
destructor TPersonalContactoDataTableRules.Destroy;
begin
inherited;
end;
function TPersonalContactoDataTableRules.GetIDValue: Integer;
begin
result := DataTable.Fields[idx_PersonalContactoID].AsInteger;
end;
procedure TPersonalContactoDataTableRules.SetIDValue(const aValue: Integer);
begin
DataTable.Fields[idx_PersonalContactoID].AsInteger := aValue;
end;
function TPersonalContactoDataTableRules.GetIDIsNull: boolean;
begin
result := DataTable.Fields[idx_PersonalContactoID].IsNull;
end;
procedure TPersonalContactoDataTableRules.SetIDIsNull(const aValue: Boolean);
begin
if aValue then
DataTable.Fields[idx_PersonalContactoID].AsVariant := Null;
end;
function TPersonalContactoDataTableRules.GetID_CONTACTOValue: Integer;
begin
result := DataTable.Fields[idx_PersonalContactoID_CONTACTO].AsInteger;
end;
procedure TPersonalContactoDataTableRules.SetID_CONTACTOValue(const aValue: Integer);
begin
DataTable.Fields[idx_PersonalContactoID_CONTACTO].AsInteger := aValue;
end;
function TPersonalContactoDataTableRules.GetID_CONTACTOIsNull: boolean;
begin
result := DataTable.Fields[idx_PersonalContactoID_CONTACTO].IsNull;
end;
procedure TPersonalContactoDataTableRules.SetID_CONTACTOIsNull(const aValue: Boolean);
begin
if aValue then
DataTable.Fields[idx_PersonalContactoID_CONTACTO].AsVariant := Null;
end;
function TPersonalContactoDataTableRules.GetNOMBREValue: String;
begin
result := DataTable.Fields[idx_PersonalContactoNOMBRE].AsString;
end;
procedure TPersonalContactoDataTableRules.SetNOMBREValue(const aValue: String);
begin
DataTable.Fields[idx_PersonalContactoNOMBRE].AsString := aValue;
end;
function TPersonalContactoDataTableRules.GetNOMBREIsNull: boolean;
begin
result := DataTable.Fields[idx_PersonalContactoNOMBRE].IsNull;
end;
procedure TPersonalContactoDataTableRules.SetNOMBREIsNull(const aValue: Boolean);
begin
if aValue then
DataTable.Fields[idx_PersonalContactoNOMBRE].AsVariant := Null;
end;
function TPersonalContactoDataTableRules.GetPUESTOValue: String;
begin
result := DataTable.Fields[idx_PersonalContactoPUESTO].AsString;
end;
procedure TPersonalContactoDataTableRules.SetPUESTOValue(const aValue: String);
begin
DataTable.Fields[idx_PersonalContactoPUESTO].AsString := aValue;
end;
function TPersonalContactoDataTableRules.GetPUESTOIsNull: boolean;
begin
result := DataTable.Fields[idx_PersonalContactoPUESTO].IsNull;
end;
procedure TPersonalContactoDataTableRules.SetPUESTOIsNull(const aValue: Boolean);
begin
if aValue then
DataTable.Fields[idx_PersonalContactoPUESTO].AsVariant := Null;
end;
function TPersonalContactoDataTableRules.GetTELEFONOValue: String;
begin
result := DataTable.Fields[idx_PersonalContactoTELEFONO].AsString;
end;
procedure TPersonalContactoDataTableRules.SetTELEFONOValue(const aValue: String);
begin
DataTable.Fields[idx_PersonalContactoTELEFONO].AsString := aValue;
end;
function TPersonalContactoDataTableRules.GetTELEFONOIsNull: boolean;
begin
result := DataTable.Fields[idx_PersonalContactoTELEFONO].IsNull;
end;
procedure TPersonalContactoDataTableRules.SetTELEFONOIsNull(const aValue: Boolean);
begin
if aValue then
DataTable.Fields[idx_PersonalContactoTELEFONO].AsVariant := Null;
end;
function TPersonalContactoDataTableRules.GetMOVILValue: String;
begin
result := DataTable.Fields[idx_PersonalContactoMOVIL].AsString;
end;
procedure TPersonalContactoDataTableRules.SetMOVILValue(const aValue: String);
begin
DataTable.Fields[idx_PersonalContactoMOVIL].AsString := aValue;
end;
function TPersonalContactoDataTableRules.GetMOVILIsNull: boolean;
begin
result := DataTable.Fields[idx_PersonalContactoMOVIL].IsNull;
end;
procedure TPersonalContactoDataTableRules.SetMOVILIsNull(const aValue: Boolean);
begin
if aValue then
DataTable.Fields[idx_PersonalContactoMOVIL].AsVariant := Null;
end;
function TPersonalContactoDataTableRules.GetFAXValue: String;
begin
result := DataTable.Fields[idx_PersonalContactoFAX].AsString;
end;
procedure TPersonalContactoDataTableRules.SetFAXValue(const aValue: String);
begin
DataTable.Fields[idx_PersonalContactoFAX].AsString := aValue;
end;
function TPersonalContactoDataTableRules.GetFAXIsNull: boolean;
begin
result := DataTable.Fields[idx_PersonalContactoFAX].IsNull;
end;
procedure TPersonalContactoDataTableRules.SetFAXIsNull(const aValue: Boolean);
begin
if aValue then
DataTable.Fields[idx_PersonalContactoFAX].AsVariant := Null;
end;
function TPersonalContactoDataTableRules.GetEMAILValue: String;
begin
result := DataTable.Fields[idx_PersonalContactoEMAIL].AsString;
end;
procedure TPersonalContactoDataTableRules.SetEMAILValue(const aValue: String);
begin
DataTable.Fields[idx_PersonalContactoEMAIL].AsString := aValue;
end;
function TPersonalContactoDataTableRules.GetEMAILIsNull: boolean;
begin
result := DataTable.Fields[idx_PersonalContactoEMAIL].IsNull;
end;
procedure TPersonalContactoDataTableRules.SetEMAILIsNull(const aValue: Boolean);
begin
if aValue then
DataTable.Fields[idx_PersonalContactoEMAIL].AsVariant := Null;
end;
function TPersonalContactoDataTableRules.GetFECHA_ALTAValue: DateTime;
begin
result := DataTable.Fields[idx_PersonalContactoFECHA_ALTA].AsDateTime;
end;
procedure TPersonalContactoDataTableRules.SetFECHA_ALTAValue(const aValue: DateTime);
begin
DataTable.Fields[idx_PersonalContactoFECHA_ALTA].AsDateTime := aValue;
end;
function TPersonalContactoDataTableRules.GetFECHA_ALTAIsNull: boolean;
begin
result := DataTable.Fields[idx_PersonalContactoFECHA_ALTA].IsNull;
end;
procedure TPersonalContactoDataTableRules.SetFECHA_ALTAIsNull(const aValue: Boolean);
begin
if aValue then
DataTable.Fields[idx_PersonalContactoFECHA_ALTA].AsVariant := Null;
end;
function TPersonalContactoDataTableRules.GetFECHA_MODIFICACIONValue: DateTime;
begin
result := DataTable.Fields[idx_PersonalContactoFECHA_MODIFICACION].AsDateTime;
end;
procedure TPersonalContactoDataTableRules.SetFECHA_MODIFICACIONValue(const aValue: DateTime);
begin
DataTable.Fields[idx_PersonalContactoFECHA_MODIFICACION].AsDateTime := aValue;
end;
function TPersonalContactoDataTableRules.GetFECHA_MODIFICACIONIsNull: boolean;
begin
result := DataTable.Fields[idx_PersonalContactoFECHA_MODIFICACION].IsNull;
end;
procedure TPersonalContactoDataTableRules.SetFECHA_MODIFICACIONIsNull(const aValue: Boolean);
begin
if aValue then
DataTable.Fields[idx_PersonalContactoFECHA_MODIFICACION].AsVariant := Null;
end;
initialization
RegisterDataTableRules(RID_Contactos, TContactosDataTableRules);
RegisterDataTableRules(RID_GruposCliente, TGruposClienteDataTableRules);
@ -6996,5 +7422,6 @@ initialization
RegisterDataTableRules(RID_Contactos_Refresh, TContactos_RefreshDataTableRules);
RegisterDataTableRules(RID_ContratosEmpleados, TContratosEmpleadosDataTableRules);
RegisterDataTableRules(RID_DescripcionesProveedores, TDescripcionesProveedoresDataTableRules);
RegisterDataTableRules(RID_PersonalContacto, TPersonalContactoDataTableRules);
end.

View File

@ -9,24 +9,25 @@ const
{ Delta rules ids
Feel free to change them to something more human readable
but make sure they are unique in the context of your application }
RID_ContactosDelta = '{D88BCAA7-5886-4CD4-BECA-2B4D8D21D8A6}';
RID_GruposClienteDelta = '{24C81A94-CB18-447A-8456-93B88582D6EE}';
RID_DatosBancariosDelta = '{B8CD12A2-4C6A-497F-A846-DD30666F98EB}';
RID_ClientesDelta = '{25F17FB7-C487-4575-8923-DDB43C061A63}';
RID_ProveedoresDelta = '{E8A7D090-1BE0-4634-89FB-68667B108276}';
RID_EmpleadosDelta = '{EAD95E6C-4119-43F9-9511-00EABC406D71}';
RID_DireccionesContactoDelta = '{E0D5C7C8-B321-4931-9AB1-6006701F5E74}';
RID_ClientesDescuentosDelta = '{C8D3CE65-0FD7-4E5C-8CB4-6C726AEF3915}';
RID_GruposProveedorDelta = '{B7B504ED-0204-492C-A44E-B3E06C143342}';
RID_GruposEmpleadoDelta = '{7EF7BDCC-C559-4C6B-A4A3-C179D2ED2C17}';
RID_Contactos_RefreshDelta = '{1F66DD99-4349-4931-87A9-9245408B5EBC}';
RID_ContratosEmpleadosDelta = '{901039B3-7FD1-45A7-8262-B946DD38E534}';
RID_DescripcionesProveedoresDelta = '{6C4014E7-35BD-4C80-8AFD-CF99C24D9787}';
RID_ContactosDelta = '{DC6F6461-F577-4A1C-A1BB-EC1E73A19C7E}';
RID_GruposClienteDelta = '{B8209C23-AEBA-42A5-A5BC-459C0774043A}';
RID_DatosBancariosDelta = '{BFD56656-7A74-44F2-A4DF-2101321A9BA5}';
RID_ClientesDelta = '{F68DC47E-1F6C-4AB6-9F4D-58DA04D34466}';
RID_ProveedoresDelta = '{1773D482-A165-4F3C-963F-04057C33EC5F}';
RID_EmpleadosDelta = '{93D28665-986C-4574-BB95-2E129DF0EF59}';
RID_DireccionesContactoDelta = '{2DB84B28-7422-43C3-8D75-53D31444CA9D}';
RID_ClientesDescuentosDelta = '{C9C2DF04-9907-4B61-90A4-F44243B0E952}';
RID_GruposProveedorDelta = '{EC035096-E936-4A1D-8160-C602BFF6AD1A}';
RID_GruposEmpleadoDelta = '{938B3E8F-B9BE-42C1-8451-D1ACE543035C}';
RID_Contactos_RefreshDelta = '{F1258795-69A3-4A08-87A0-E9E0A3E82FA0}';
RID_ContratosEmpleadosDelta = '{DDEB329D-3B2C-49FF-A10F-DA282E098379}';
RID_DescripcionesProveedoresDelta = '{845273A7-ABAD-460B-8079-150C94E427AC}';
RID_PersonalContactoDelta = '{47E745DC-106B-473F-9CB1-BC3193862428}';
type
{ IContactosDelta }
IContactosDelta = interface(IContactos)
['{D88BCAA7-5886-4CD4-BECA-2B4D8D21D8A6}']
['{DC6F6461-F577-4A1C-A1BB-EC1E73A19C7E}']
{ Property getters and setters }
function GetOldIDValue : Integer;
function GetOldID_CATEGORIAValue : Integer;
@ -325,7 +326,7 @@ type
{ IGruposClienteDelta }
IGruposClienteDelta = interface(IGruposCliente)
['{24C81A94-CB18-447A-8456-93B88582D6EE}']
['{B8209C23-AEBA-42A5-A5BC-459C0774043A}']
{ Property getters and setters }
function GetOldIDValue : Integer;
function GetOldDESCRIPCIONValue : String;
@ -371,7 +372,7 @@ type
{ IDatosBancariosDelta }
IDatosBancariosDelta = interface(IDatosBancarios)
['{B8CD12A2-4C6A-497F-A846-DD30666F98EB}']
['{BFD56656-7A74-44F2-A4DF-2101321A9BA5}']
{ Property getters and setters }
function GetOldIDValue : Integer;
function GetOldID_CONTACTOValue : Integer;
@ -501,7 +502,7 @@ type
{ IClientesDelta }
IClientesDelta = interface(IClientes)
['{25F17FB7-C487-4575-8923-DDB43C061A63}']
['{F68DC47E-1F6C-4AB6-9F4D-58DA04D34466}']
{ Property getters and setters }
function GetOldIDValue : Integer;
function GetOldID_CATEGORIAValue : Integer;
@ -944,7 +945,7 @@ type
{ IProveedoresDelta }
IProveedoresDelta = interface(IProveedores)
['{E8A7D090-1BE0-4634-89FB-68667B108276}']
['{1773D482-A165-4F3C-963F-04057C33EC5F}']
{ Property getters and setters }
function GetOldIDValue : Integer;
function GetOldID_CATEGORIAValue : Integer;
@ -979,6 +980,7 @@ type
function GetOldTIENDA_WEBValue : SmallInt;
function GetOldHOMOLOGADOValue : SmallInt;
function GetOldCERTIFICACIONValue : String;
function GetOldSUBCONTRATAValue : SmallInt;
{ Properties }
property OldID : Integer read GetOldIDValue;
@ -1014,6 +1016,7 @@ type
property OldTIENDA_WEB : SmallInt read GetOldTIENDA_WEBValue;
property OldHOMOLOGADO : SmallInt read GetOldHOMOLOGADOValue;
property OldCERTIFICACION : String read GetOldCERTIFICACIONValue;
property OldSUBCONTRATA : SmallInt read GetOldSUBCONTRATAValue;
end;
{ TProveedoresBusinessProcessorRules }
@ -1220,6 +1223,12 @@ type
function GetOldCERTIFICACIONIsNull: Boolean; virtual;
procedure SetCERTIFICACIONValue(const aValue: String); virtual;
procedure SetCERTIFICACIONIsNull(const aValue: Boolean); virtual;
function GetSUBCONTRATAValue: SmallInt; virtual;
function GetSUBCONTRATAIsNull: Boolean; virtual;
function GetOldSUBCONTRATAValue: SmallInt; virtual;
function GetOldSUBCONTRATAIsNull: Boolean; virtual;
procedure SetSUBCONTRATAValue(const aValue: SmallInt); virtual;
procedure SetSUBCONTRATAIsNull(const aValue: Boolean); virtual;
{ Properties }
property ID : Integer read GetIDValue write SetIDValue;
@ -1354,6 +1363,10 @@ type
property CERTIFICACIONIsNull : Boolean read GetCERTIFICACIONIsNull write SetCERTIFICACIONIsNull;
property OldCERTIFICACION : String read GetOldCERTIFICACIONValue;
property OldCERTIFICACIONIsNull : Boolean read GetOldCERTIFICACIONIsNull;
property SUBCONTRATA : SmallInt read GetSUBCONTRATAValue write SetSUBCONTRATAValue;
property SUBCONTRATAIsNull : Boolean read GetSUBCONTRATAIsNull write SetSUBCONTRATAIsNull;
property OldSUBCONTRATA : SmallInt read GetOldSUBCONTRATAValue;
property OldSUBCONTRATAIsNull : Boolean read GetOldSUBCONTRATAIsNull;
public
constructor Create(aBusinessProcessor: TDABusinessProcessor); override;
@ -1363,7 +1376,7 @@ type
{ IEmpleadosDelta }
IEmpleadosDelta = interface(IEmpleados)
['{EAD95E6C-4119-43F9-9511-00EABC406D71}']
['{93D28665-986C-4574-BB95-2E129DF0EF59}']
{ Property getters and setters }
function GetOldIDValue : Integer;
function GetOldID_CATEGORIAValue : Integer;
@ -1774,7 +1787,7 @@ type
{ IDireccionesContactoDelta }
IDireccionesContactoDelta = interface(IDireccionesContacto)
['{E0D5C7C8-B321-4931-9AB1-6006701F5E74}']
['{2DB84B28-7422-43C3-8D75-53D31444CA9D}']
{ Property getters and setters }
function GetOldIDValue : Integer;
function GetOldID_CONTACTOValue : Integer;
@ -1989,7 +2002,7 @@ type
{ IClientesDescuentosDelta }
IClientesDescuentosDelta = interface(IClientesDescuentos)
['{C8D3CE65-0FD7-4E5C-8CB4-6C726AEF3915}']
['{C9C2DF04-9907-4B61-90A4-F44243B0E952}']
{ Property getters and setters }
function GetOldIDValue : Integer;
function GetOldID_CLIENTEValue : Integer;
@ -2071,7 +2084,7 @@ type
{ IGruposProveedorDelta }
IGruposProveedorDelta = interface(IGruposProveedor)
['{B7B504ED-0204-492C-A44E-B3E06C143342}']
['{EC035096-E936-4A1D-8160-C602BFF6AD1A}']
{ Property getters and setters }
function GetOldIDValue : Integer;
function GetOldDESCRIPCIONValue : String;
@ -2117,7 +2130,7 @@ type
{ IGruposEmpleadoDelta }
IGruposEmpleadoDelta = interface(IGruposEmpleado)
['{7EF7BDCC-C559-4C6B-A4A3-C179D2ED2C17}']
['{938B3E8F-B9BE-42C1-8451-D1ACE543035C}']
{ Property getters and setters }
function GetOldIDValue : Integer;
function GetOldDESCRIPCIONValue : String;
@ -2163,7 +2176,7 @@ type
{ IContactos_RefreshDelta }
IContactos_RefreshDelta = interface(IContactos_Refresh)
['{1F66DD99-4349-4931-87A9-9245408B5EBC}']
['{F1258795-69A3-4A08-87A0-E9E0A3E82FA0}']
{ Property getters and setters }
function GetOldIDValue : Integer;
function GetOldNIF_CIFValue : String;
@ -2438,7 +2451,7 @@ type
{ IContratosEmpleadosDelta }
IContratosEmpleadosDelta = interface(IContratosEmpleados)
['{901039B3-7FD1-45A7-8262-B946DD38E534}']
['{DDEB329D-3B2C-49FF-A10F-DA282E098379}']
{ Property getters and setters }
function GetOldCONTRATOValue : String;
@ -2472,7 +2485,7 @@ type
{ IDescripcionesProveedoresDelta }
IDescripcionesProveedoresDelta = interface(IDescripcionesProveedores)
['{6C4014E7-35BD-4C80-8AFD-CF99C24D9787}']
['{845273A7-ABAD-460B-8079-150C94E427AC}']
{ Property getters and setters }
function GetOldDESCRIPCION_PROVEEDORValue : String;
@ -2504,6 +2517,148 @@ type
end;
{ IPersonalContactoDelta }
IPersonalContactoDelta = interface(IPersonalContacto)
['{47E745DC-106B-473F-9CB1-BC3193862428}']
{ Property getters and setters }
function GetOldIDValue : Integer;
function GetOldID_CONTACTOValue : Integer;
function GetOldNOMBREValue : String;
function GetOldPUESTOValue : String;
function GetOldTELEFONOValue : String;
function GetOldMOVILValue : String;
function GetOldFAXValue : String;
function GetOldEMAILValue : String;
function GetOldFECHA_ALTAValue : DateTime;
function GetOldFECHA_MODIFICACIONValue : DateTime;
{ Properties }
property OldID : Integer read GetOldIDValue;
property OldID_CONTACTO : Integer read GetOldID_CONTACTOValue;
property OldNOMBRE : String read GetOldNOMBREValue;
property OldPUESTO : String read GetOldPUESTOValue;
property OldTELEFONO : String read GetOldTELEFONOValue;
property OldMOVIL : String read GetOldMOVILValue;
property OldFAX : String read GetOldFAXValue;
property OldEMAIL : String read GetOldEMAILValue;
property OldFECHA_ALTA : DateTime read GetOldFECHA_ALTAValue;
property OldFECHA_MODIFICACION : DateTime read GetOldFECHA_MODIFICACIONValue;
end;
{ TPersonalContactoBusinessProcessorRules }
TPersonalContactoBusinessProcessorRules = class(TDABusinessProcessorRules, IPersonalContacto, IPersonalContactoDelta)
private
protected
{ Property getters and setters }
function GetIDValue: Integer; virtual;
function GetIDIsNull: Boolean; virtual;
function GetOldIDValue: Integer; virtual;
function GetOldIDIsNull: Boolean; virtual;
procedure SetIDValue(const aValue: Integer); virtual;
procedure SetIDIsNull(const aValue: Boolean); virtual;
function GetID_CONTACTOValue: Integer; virtual;
function GetID_CONTACTOIsNull: Boolean; virtual;
function GetOldID_CONTACTOValue: Integer; virtual;
function GetOldID_CONTACTOIsNull: Boolean; virtual;
procedure SetID_CONTACTOValue(const aValue: Integer); virtual;
procedure SetID_CONTACTOIsNull(const aValue: Boolean); virtual;
function GetNOMBREValue: String; virtual;
function GetNOMBREIsNull: Boolean; virtual;
function GetOldNOMBREValue: String; virtual;
function GetOldNOMBREIsNull: Boolean; virtual;
procedure SetNOMBREValue(const aValue: String); virtual;
procedure SetNOMBREIsNull(const aValue: Boolean); virtual;
function GetPUESTOValue: String; virtual;
function GetPUESTOIsNull: Boolean; virtual;
function GetOldPUESTOValue: String; virtual;
function GetOldPUESTOIsNull: Boolean; virtual;
procedure SetPUESTOValue(const aValue: String); virtual;
procedure SetPUESTOIsNull(const aValue: Boolean); virtual;
function GetTELEFONOValue: String; virtual;
function GetTELEFONOIsNull: Boolean; virtual;
function GetOldTELEFONOValue: String; virtual;
function GetOldTELEFONOIsNull: Boolean; virtual;
procedure SetTELEFONOValue(const aValue: String); virtual;
procedure SetTELEFONOIsNull(const aValue: Boolean); virtual;
function GetMOVILValue: String; virtual;
function GetMOVILIsNull: Boolean; virtual;
function GetOldMOVILValue: String; virtual;
function GetOldMOVILIsNull: Boolean; virtual;
procedure SetMOVILValue(const aValue: String); virtual;
procedure SetMOVILIsNull(const aValue: Boolean); virtual;
function GetFAXValue: String; virtual;
function GetFAXIsNull: Boolean; virtual;
function GetOldFAXValue: String; virtual;
function GetOldFAXIsNull: Boolean; virtual;
procedure SetFAXValue(const aValue: String); virtual;
procedure SetFAXIsNull(const aValue: Boolean); virtual;
function GetEMAILValue: String; virtual;
function GetEMAILIsNull: Boolean; virtual;
function GetOldEMAILValue: String; virtual;
function GetOldEMAILIsNull: Boolean; virtual;
procedure SetEMAILValue(const aValue: String); virtual;
procedure SetEMAILIsNull(const aValue: Boolean); virtual;
function GetFECHA_ALTAValue: DateTime; virtual;
function GetFECHA_ALTAIsNull: Boolean; virtual;
function GetOldFECHA_ALTAValue: DateTime; virtual;
function GetOldFECHA_ALTAIsNull: Boolean; virtual;
procedure SetFECHA_ALTAValue(const aValue: DateTime); virtual;
procedure SetFECHA_ALTAIsNull(const aValue: Boolean); virtual;
function GetFECHA_MODIFICACIONValue: DateTime; virtual;
function GetFECHA_MODIFICACIONIsNull: Boolean; virtual;
function GetOldFECHA_MODIFICACIONValue: DateTime; virtual;
function GetOldFECHA_MODIFICACIONIsNull: Boolean; virtual;
procedure SetFECHA_MODIFICACIONValue(const aValue: DateTime); virtual;
procedure SetFECHA_MODIFICACIONIsNull(const aValue: Boolean); virtual;
{ Properties }
property ID : Integer read GetIDValue write SetIDValue;
property IDIsNull : Boolean read GetIDIsNull write SetIDIsNull;
property OldID : Integer read GetOldIDValue;
property OldIDIsNull : Boolean read GetOldIDIsNull;
property ID_CONTACTO : Integer read GetID_CONTACTOValue write SetID_CONTACTOValue;
property ID_CONTACTOIsNull : Boolean read GetID_CONTACTOIsNull write SetID_CONTACTOIsNull;
property OldID_CONTACTO : Integer read GetOldID_CONTACTOValue;
property OldID_CONTACTOIsNull : Boolean read GetOldID_CONTACTOIsNull;
property NOMBRE : String read GetNOMBREValue write SetNOMBREValue;
property NOMBREIsNull : Boolean read GetNOMBREIsNull write SetNOMBREIsNull;
property OldNOMBRE : String read GetOldNOMBREValue;
property OldNOMBREIsNull : Boolean read GetOldNOMBREIsNull;
property PUESTO : String read GetPUESTOValue write SetPUESTOValue;
property PUESTOIsNull : Boolean read GetPUESTOIsNull write SetPUESTOIsNull;
property OldPUESTO : String read GetOldPUESTOValue;
property OldPUESTOIsNull : Boolean read GetOldPUESTOIsNull;
property TELEFONO : String read GetTELEFONOValue write SetTELEFONOValue;
property TELEFONOIsNull : Boolean read GetTELEFONOIsNull write SetTELEFONOIsNull;
property OldTELEFONO : String read GetOldTELEFONOValue;
property OldTELEFONOIsNull : Boolean read GetOldTELEFONOIsNull;
property MOVIL : String read GetMOVILValue write SetMOVILValue;
property MOVILIsNull : Boolean read GetMOVILIsNull write SetMOVILIsNull;
property OldMOVIL : String read GetOldMOVILValue;
property OldMOVILIsNull : Boolean read GetOldMOVILIsNull;
property FAX : String read GetFAXValue write SetFAXValue;
property FAXIsNull : Boolean read GetFAXIsNull write SetFAXIsNull;
property OldFAX : String read GetOldFAXValue;
property OldFAXIsNull : Boolean read GetOldFAXIsNull;
property EMAIL : String read GetEMAILValue write SetEMAILValue;
property EMAILIsNull : Boolean read GetEMAILIsNull write SetEMAILIsNull;
property OldEMAIL : String read GetOldEMAILValue;
property OldEMAILIsNull : Boolean read GetOldEMAILIsNull;
property FECHA_ALTA : DateTime read GetFECHA_ALTAValue write SetFECHA_ALTAValue;
property FECHA_ALTAIsNull : Boolean read GetFECHA_ALTAIsNull write SetFECHA_ALTAIsNull;
property OldFECHA_ALTA : DateTime read GetOldFECHA_ALTAValue;
property OldFECHA_ALTAIsNull : Boolean read GetOldFECHA_ALTAIsNull;
property FECHA_MODIFICACION : DateTime read GetFECHA_MODIFICACIONValue write SetFECHA_MODIFICACIONValue;
property FECHA_MODIFICACIONIsNull : Boolean read GetFECHA_MODIFICACIONIsNull write SetFECHA_MODIFICACIONIsNull;
property OldFECHA_MODIFICACION : DateTime read GetOldFECHA_MODIFICACIONValue;
property OldFECHA_MODIFICACIONIsNull : Boolean read GetOldFECHA_MODIFICACIONIsNull;
public
constructor Create(aBusinessProcessor: TDABusinessProcessor); override;
destructor Destroy; override;
end;
implementation
uses
@ -5754,6 +5909,37 @@ begin
BusinessProcessor.CurrentChange.NewValueByName[fld_ProveedoresCERTIFICACION] := Null;
end;
function TProveedoresBusinessProcessorRules.GetSUBCONTRATAValue: SmallInt;
begin
result := BusinessProcessor.CurrentChange.NewValueByName[fld_ProveedoresSUBCONTRATA];
end;
function TProveedoresBusinessProcessorRules.GetSUBCONTRATAIsNull: Boolean;
begin
result := VarIsNull(BusinessProcessor.CurrentChange.NewValueByName[fld_ProveedoresSUBCONTRATA]);
end;
function TProveedoresBusinessProcessorRules.GetOldSUBCONTRATAValue: SmallInt;
begin
result := BusinessProcessor.CurrentChange.OldValueByName[fld_ProveedoresSUBCONTRATA];
end;
function TProveedoresBusinessProcessorRules.GetOldSUBCONTRATAIsNull: Boolean;
begin
result := VarIsNull(BusinessProcessor.CurrentChange.OldValueByName[fld_ProveedoresSUBCONTRATA]);
end;
procedure TProveedoresBusinessProcessorRules.SetSUBCONTRATAValue(const aValue: SmallInt);
begin
BusinessProcessor.CurrentChange.NewValueByName[fld_ProveedoresSUBCONTRATA] := aValue;
end;
procedure TProveedoresBusinessProcessorRules.SetSUBCONTRATAIsNull(const aValue: Boolean);
begin
if aValue then
BusinessProcessor.CurrentChange.NewValueByName[fld_ProveedoresSUBCONTRATA] := Null;
end;
{ TEmpleadosBusinessProcessorRules }
constructor TEmpleadosBusinessProcessorRules.Create(aBusinessProcessor: TDABusinessProcessor);
@ -8379,6 +8565,328 @@ begin
end;
{ TPersonalContactoBusinessProcessorRules }
constructor TPersonalContactoBusinessProcessorRules.Create(aBusinessProcessor: TDABusinessProcessor);
begin
inherited;
end;
destructor TPersonalContactoBusinessProcessorRules.Destroy;
begin
inherited;
end;
function TPersonalContactoBusinessProcessorRules.GetIDValue: Integer;
begin
result := BusinessProcessor.CurrentChange.NewValueByName[fld_PersonalContactoID];
end;
function TPersonalContactoBusinessProcessorRules.GetIDIsNull: Boolean;
begin
result := VarIsNull(BusinessProcessor.CurrentChange.NewValueByName[fld_PersonalContactoID]);
end;
function TPersonalContactoBusinessProcessorRules.GetOldIDValue: Integer;
begin
result := BusinessProcessor.CurrentChange.OldValueByName[fld_PersonalContactoID];
end;
function TPersonalContactoBusinessProcessorRules.GetOldIDIsNull: Boolean;
begin
result := VarIsNull(BusinessProcessor.CurrentChange.OldValueByName[fld_PersonalContactoID]);
end;
procedure TPersonalContactoBusinessProcessorRules.SetIDValue(const aValue: Integer);
begin
BusinessProcessor.CurrentChange.NewValueByName[fld_PersonalContactoID] := aValue;
end;
procedure TPersonalContactoBusinessProcessorRules.SetIDIsNull(const aValue: Boolean);
begin
if aValue then
BusinessProcessor.CurrentChange.NewValueByName[fld_PersonalContactoID] := Null;
end;
function TPersonalContactoBusinessProcessorRules.GetID_CONTACTOValue: Integer;
begin
result := BusinessProcessor.CurrentChange.NewValueByName[fld_PersonalContactoID_CONTACTO];
end;
function TPersonalContactoBusinessProcessorRules.GetID_CONTACTOIsNull: Boolean;
begin
result := VarIsNull(BusinessProcessor.CurrentChange.NewValueByName[fld_PersonalContactoID_CONTACTO]);
end;
function TPersonalContactoBusinessProcessorRules.GetOldID_CONTACTOValue: Integer;
begin
result := BusinessProcessor.CurrentChange.OldValueByName[fld_PersonalContactoID_CONTACTO];
end;
function TPersonalContactoBusinessProcessorRules.GetOldID_CONTACTOIsNull: Boolean;
begin
result := VarIsNull(BusinessProcessor.CurrentChange.OldValueByName[fld_PersonalContactoID_CONTACTO]);
end;
procedure TPersonalContactoBusinessProcessorRules.SetID_CONTACTOValue(const aValue: Integer);
begin
BusinessProcessor.CurrentChange.NewValueByName[fld_PersonalContactoID_CONTACTO] := aValue;
end;
procedure TPersonalContactoBusinessProcessorRules.SetID_CONTACTOIsNull(const aValue: Boolean);
begin
if aValue then
BusinessProcessor.CurrentChange.NewValueByName[fld_PersonalContactoID_CONTACTO] := Null;
end;
function TPersonalContactoBusinessProcessorRules.GetNOMBREValue: String;
begin
result := BusinessProcessor.CurrentChange.NewValueByName[fld_PersonalContactoNOMBRE];
end;
function TPersonalContactoBusinessProcessorRules.GetNOMBREIsNull: Boolean;
begin
result := VarIsNull(BusinessProcessor.CurrentChange.NewValueByName[fld_PersonalContactoNOMBRE]);
end;
function TPersonalContactoBusinessProcessorRules.GetOldNOMBREValue: String;
begin
result := BusinessProcessor.CurrentChange.OldValueByName[fld_PersonalContactoNOMBRE];
end;
function TPersonalContactoBusinessProcessorRules.GetOldNOMBREIsNull: Boolean;
begin
result := VarIsNull(BusinessProcessor.CurrentChange.OldValueByName[fld_PersonalContactoNOMBRE]);
end;
procedure TPersonalContactoBusinessProcessorRules.SetNOMBREValue(const aValue: String);
begin
BusinessProcessor.CurrentChange.NewValueByName[fld_PersonalContactoNOMBRE] := aValue;
end;
procedure TPersonalContactoBusinessProcessorRules.SetNOMBREIsNull(const aValue: Boolean);
begin
if aValue then
BusinessProcessor.CurrentChange.NewValueByName[fld_PersonalContactoNOMBRE] := Null;
end;
function TPersonalContactoBusinessProcessorRules.GetPUESTOValue: String;
begin
result := BusinessProcessor.CurrentChange.NewValueByName[fld_PersonalContactoPUESTO];
end;
function TPersonalContactoBusinessProcessorRules.GetPUESTOIsNull: Boolean;
begin
result := VarIsNull(BusinessProcessor.CurrentChange.NewValueByName[fld_PersonalContactoPUESTO]);
end;
function TPersonalContactoBusinessProcessorRules.GetOldPUESTOValue: String;
begin
result := BusinessProcessor.CurrentChange.OldValueByName[fld_PersonalContactoPUESTO];
end;
function TPersonalContactoBusinessProcessorRules.GetOldPUESTOIsNull: Boolean;
begin
result := VarIsNull(BusinessProcessor.CurrentChange.OldValueByName[fld_PersonalContactoPUESTO]);
end;
procedure TPersonalContactoBusinessProcessorRules.SetPUESTOValue(const aValue: String);
begin
BusinessProcessor.CurrentChange.NewValueByName[fld_PersonalContactoPUESTO] := aValue;
end;
procedure TPersonalContactoBusinessProcessorRules.SetPUESTOIsNull(const aValue: Boolean);
begin
if aValue then
BusinessProcessor.CurrentChange.NewValueByName[fld_PersonalContactoPUESTO] := Null;
end;
function TPersonalContactoBusinessProcessorRules.GetTELEFONOValue: String;
begin
result := BusinessProcessor.CurrentChange.NewValueByName[fld_PersonalContactoTELEFONO];
end;
function TPersonalContactoBusinessProcessorRules.GetTELEFONOIsNull: Boolean;
begin
result := VarIsNull(BusinessProcessor.CurrentChange.NewValueByName[fld_PersonalContactoTELEFONO]);
end;
function TPersonalContactoBusinessProcessorRules.GetOldTELEFONOValue: String;
begin
result := BusinessProcessor.CurrentChange.OldValueByName[fld_PersonalContactoTELEFONO];
end;
function TPersonalContactoBusinessProcessorRules.GetOldTELEFONOIsNull: Boolean;
begin
result := VarIsNull(BusinessProcessor.CurrentChange.OldValueByName[fld_PersonalContactoTELEFONO]);
end;
procedure TPersonalContactoBusinessProcessorRules.SetTELEFONOValue(const aValue: String);
begin
BusinessProcessor.CurrentChange.NewValueByName[fld_PersonalContactoTELEFONO] := aValue;
end;
procedure TPersonalContactoBusinessProcessorRules.SetTELEFONOIsNull(const aValue: Boolean);
begin
if aValue then
BusinessProcessor.CurrentChange.NewValueByName[fld_PersonalContactoTELEFONO] := Null;
end;
function TPersonalContactoBusinessProcessorRules.GetMOVILValue: String;
begin
result := BusinessProcessor.CurrentChange.NewValueByName[fld_PersonalContactoMOVIL];
end;
function TPersonalContactoBusinessProcessorRules.GetMOVILIsNull: Boolean;
begin
result := VarIsNull(BusinessProcessor.CurrentChange.NewValueByName[fld_PersonalContactoMOVIL]);
end;
function TPersonalContactoBusinessProcessorRules.GetOldMOVILValue: String;
begin
result := BusinessProcessor.CurrentChange.OldValueByName[fld_PersonalContactoMOVIL];
end;
function TPersonalContactoBusinessProcessorRules.GetOldMOVILIsNull: Boolean;
begin
result := VarIsNull(BusinessProcessor.CurrentChange.OldValueByName[fld_PersonalContactoMOVIL]);
end;
procedure TPersonalContactoBusinessProcessorRules.SetMOVILValue(const aValue: String);
begin
BusinessProcessor.CurrentChange.NewValueByName[fld_PersonalContactoMOVIL] := aValue;
end;
procedure TPersonalContactoBusinessProcessorRules.SetMOVILIsNull(const aValue: Boolean);
begin
if aValue then
BusinessProcessor.CurrentChange.NewValueByName[fld_PersonalContactoMOVIL] := Null;
end;
function TPersonalContactoBusinessProcessorRules.GetFAXValue: String;
begin
result := BusinessProcessor.CurrentChange.NewValueByName[fld_PersonalContactoFAX];
end;
function TPersonalContactoBusinessProcessorRules.GetFAXIsNull: Boolean;
begin
result := VarIsNull(BusinessProcessor.CurrentChange.NewValueByName[fld_PersonalContactoFAX]);
end;
function TPersonalContactoBusinessProcessorRules.GetOldFAXValue: String;
begin
result := BusinessProcessor.CurrentChange.OldValueByName[fld_PersonalContactoFAX];
end;
function TPersonalContactoBusinessProcessorRules.GetOldFAXIsNull: Boolean;
begin
result := VarIsNull(BusinessProcessor.CurrentChange.OldValueByName[fld_PersonalContactoFAX]);
end;
procedure TPersonalContactoBusinessProcessorRules.SetFAXValue(const aValue: String);
begin
BusinessProcessor.CurrentChange.NewValueByName[fld_PersonalContactoFAX] := aValue;
end;
procedure TPersonalContactoBusinessProcessorRules.SetFAXIsNull(const aValue: Boolean);
begin
if aValue then
BusinessProcessor.CurrentChange.NewValueByName[fld_PersonalContactoFAX] := Null;
end;
function TPersonalContactoBusinessProcessorRules.GetEMAILValue: String;
begin
result := BusinessProcessor.CurrentChange.NewValueByName[fld_PersonalContactoEMAIL];
end;
function TPersonalContactoBusinessProcessorRules.GetEMAILIsNull: Boolean;
begin
result := VarIsNull(BusinessProcessor.CurrentChange.NewValueByName[fld_PersonalContactoEMAIL]);
end;
function TPersonalContactoBusinessProcessorRules.GetOldEMAILValue: String;
begin
result := BusinessProcessor.CurrentChange.OldValueByName[fld_PersonalContactoEMAIL];
end;
function TPersonalContactoBusinessProcessorRules.GetOldEMAILIsNull: Boolean;
begin
result := VarIsNull(BusinessProcessor.CurrentChange.OldValueByName[fld_PersonalContactoEMAIL]);
end;
procedure TPersonalContactoBusinessProcessorRules.SetEMAILValue(const aValue: String);
begin
BusinessProcessor.CurrentChange.NewValueByName[fld_PersonalContactoEMAIL] := aValue;
end;
procedure TPersonalContactoBusinessProcessorRules.SetEMAILIsNull(const aValue: Boolean);
begin
if aValue then
BusinessProcessor.CurrentChange.NewValueByName[fld_PersonalContactoEMAIL] := Null;
end;
function TPersonalContactoBusinessProcessorRules.GetFECHA_ALTAValue: DateTime;
begin
result := BusinessProcessor.CurrentChange.NewValueByName[fld_PersonalContactoFECHA_ALTA];
end;
function TPersonalContactoBusinessProcessorRules.GetFECHA_ALTAIsNull: Boolean;
begin
result := VarIsNull(BusinessProcessor.CurrentChange.NewValueByName[fld_PersonalContactoFECHA_ALTA]);
end;
function TPersonalContactoBusinessProcessorRules.GetOldFECHA_ALTAValue: DateTime;
begin
result := BusinessProcessor.CurrentChange.OldValueByName[fld_PersonalContactoFECHA_ALTA];
end;
function TPersonalContactoBusinessProcessorRules.GetOldFECHA_ALTAIsNull: Boolean;
begin
result := VarIsNull(BusinessProcessor.CurrentChange.OldValueByName[fld_PersonalContactoFECHA_ALTA]);
end;
procedure TPersonalContactoBusinessProcessorRules.SetFECHA_ALTAValue(const aValue: DateTime);
begin
BusinessProcessor.CurrentChange.NewValueByName[fld_PersonalContactoFECHA_ALTA] := aValue;
end;
procedure TPersonalContactoBusinessProcessorRules.SetFECHA_ALTAIsNull(const aValue: Boolean);
begin
if aValue then
BusinessProcessor.CurrentChange.NewValueByName[fld_PersonalContactoFECHA_ALTA] := Null;
end;
function TPersonalContactoBusinessProcessorRules.GetFECHA_MODIFICACIONValue: DateTime;
begin
result := BusinessProcessor.CurrentChange.NewValueByName[fld_PersonalContactoFECHA_MODIFICACION];
end;
function TPersonalContactoBusinessProcessorRules.GetFECHA_MODIFICACIONIsNull: Boolean;
begin
result := VarIsNull(BusinessProcessor.CurrentChange.NewValueByName[fld_PersonalContactoFECHA_MODIFICACION]);
end;
function TPersonalContactoBusinessProcessorRules.GetOldFECHA_MODIFICACIONValue: DateTime;
begin
result := BusinessProcessor.CurrentChange.OldValueByName[fld_PersonalContactoFECHA_MODIFICACION];
end;
function TPersonalContactoBusinessProcessorRules.GetOldFECHA_MODIFICACIONIsNull: Boolean;
begin
result := VarIsNull(BusinessProcessor.CurrentChange.OldValueByName[fld_PersonalContactoFECHA_MODIFICACION]);
end;
procedure TPersonalContactoBusinessProcessorRules.SetFECHA_MODIFICACIONValue(const aValue: DateTime);
begin
BusinessProcessor.CurrentChange.NewValueByName[fld_PersonalContactoFECHA_MODIFICACION] := aValue;
end;
procedure TPersonalContactoBusinessProcessorRules.SetFECHA_MODIFICACIONIsNull(const aValue: Boolean);
begin
if aValue then
BusinessProcessor.CurrentChange.NewValueByName[fld_PersonalContactoFECHA_MODIFICACION] := Null;
end;
initialization
RegisterBusinessProcessorRules(RID_ContactosDelta, TContactosBusinessProcessorRules);
RegisterBusinessProcessorRules(RID_GruposClienteDelta, TGruposClienteBusinessProcessorRules);
@ -8393,5 +8901,6 @@ initialization
RegisterBusinessProcessorRules(RID_Contactos_RefreshDelta, TContactos_RefreshBusinessProcessorRules);
RegisterBusinessProcessorRules(RID_ContratosEmpleadosDelta, TContratosEmpleadosBusinessProcessorRules);
RegisterBusinessProcessorRules(RID_DescripcionesProveedoresDelta, TDescripcionesProveedoresBusinessProcessorRules);
RegisterBusinessProcessorRules(RID_PersonalContactoDelta, TPersonalContactoBusinessProcessorRules);
end.

View File

@ -4,7 +4,7 @@ interface
uses
uDAInterfaces, uDADataTable, uROClasses,
schContactosClient_Intf, uBizContactosDatosBancarios,
schContactosClient_Intf, uBizContactosDatosBancarios, uBizContactosPersonal,
uDBSelectionListUtils, uBizDireccionesContacto, uBizClientesDescuentos;
const
@ -30,6 +30,11 @@ type
property DatosBancarios : IBizContactosDatosBancarios read GetDatosBancarios
write SetDatosBancarios;
procedure SetPersonal(AValue : IBizContactoPersonal);
function GetPersonal : IBizContactoPersonal;
property Personal : IBizContactoPersonal read GetPersonal
write SetPersonal;
function GetCategoria : String;
property Categoria : String read GetCategoria;
@ -123,6 +128,9 @@ type
function GetGRUPO_PROVEEDORValue: String;
procedure SetGRUPO_PROVEEDORValue(const aValue: String);
function GetSUBCONTRATAValue: SmallInt;
procedure SetSUBCONTRATAValue(const aValue: SmallInt);
property REGIMEN_IVA: String read GetREGIMEN_IVAValue write SetREGIMEN_IVAValue;
property DESCUENTO: Float read GetDESCUENTOValue write SetDESCUENTOValue;
property DESCRIPCION_PROVEEDOR: String read GetDESCRIPCION_PROVEEDORValue write SetDESCRIPCION_PROVEEDORValue;
@ -133,6 +141,7 @@ type
property HOMOLOGADO: Integer read GetHOMOLOGADOValue write SetHOMOLOGADOValue;
property CERTIFICACION: String read GetCERTIFICACIONValue write SetCERTIFICACIONValue;
property GRUPO_PROVEEDOR: String read GetGRUPO_PROVEEDORValue write SetGRUPO_PROVEEDORValue;
property SUBCONTRATA: SmallInt read GetSUBCONTRATAValue write SetSUBCONTRATAValue;
end;
IBizEmpleado = interface (IBizContacto)
@ -177,6 +186,8 @@ type
FDatosBancariosLink : TDADataSource;
FDirecciones : IBizDireccionesContacto;
FDireccionesLink : TDADataSource;
FPersonal : IBizContactoPersonal;
FPersonalLink : TDADataSource;
FSeleccionableInterface : ISeleccionable;
@ -188,6 +199,9 @@ type
function GetCategoria : String;
procedure SetPersonal(AValue : IBizContactoPersonal);
function GetPersonal : IBizContactoPersonal;
procedure OnNewRecord(Sender: TDADataTable); override;
public
function EsNuevo : Boolean;
@ -196,6 +210,9 @@ type
destructor Destroy; override;
property Categoria : String read GetCategoria;
property Personal : IBizContactoPersonal read GetPersonal
write SetPersonal;
property DatosBancarios : IBizContactosDatosBancarios read GetDatosBancarios
write SetDatosBancarios;
@ -294,6 +311,8 @@ type
function GetGRUPO_PROVEEDORValue: String;
procedure SetGRUPO_PROVEEDORValue(const aValue: String);
function GetSUBCONTRATAValue: SmallInt;
procedure SetSUBCONTRATAValue(const aValue: SmallInt);
public
procedure IniciarValoresContactoNuevo; override;
property DESCUENTO: Float read GetDESCUENTOValue write SetDESCUENTOValue;
@ -306,6 +325,7 @@ type
property HOMOLOGADO: Integer read GetHOMOLOGADOValue write SetHOMOLOGADOValue;
property CERTIFICACION: String read GetCERTIFICACIONValue write SetCERTIFICACIONValue;
property GRUPO_PROVEEDOR: String read GetGRUPO_PROVEEDORValue write SetGRUPO_PROVEEDORValue;
property SUBCONTRATA: SmallInt read GetSUBCONTRATAValue write SetSUBCONTRATAValue;
end;
@ -361,6 +381,9 @@ begin
FDireccionesLink := TDADataSource.Create(NIL);
FDireccionesLink.DataTable := aDataTable;
FPersonalLink := TDADataSource.Create(NIL);
FPersonalLink.DataTable := aDataTable;
FSeleccionableInterface := TSeleccionable.Create(aDataTable);
end;
@ -372,6 +395,9 @@ begin
FDirecciones := NIL;
FDireccionesLink.Free;
FPersonal := NIL;
FPersonalLink.Free;
FSeleccionableInterface := NIL;
inherited;
end;
@ -400,6 +426,11 @@ begin
Result := FDirecciones;
end;
function TBizContacto.GetPersonal: IBizContactoPersonal;
begin
Result := FPersonal;
end;
procedure TBizContacto.IniciarValoresContactoNuevo;
begin
USUARIO := AppFactuGES.UsuarioActivo.UserName;
@ -425,6 +456,12 @@ begin
end;
procedure TBizContacto.SetPersonal(AValue: IBizContactoPersonal);
begin
FPersonal := AValue;
EnlazarMaestroDetalle(FPersonalLink, FPersonal);
end;
{ TBizCliente }
constructor TBizCliente.Create(aDataTable: TDADataTable);
@ -590,6 +627,11 @@ begin
result := DataTable.Fields[idx_ProveedoresREGIMEN_IVA].AsString;
end;
function TBizProveedor.GetSUBCONTRATAValue: SmallInt;
begin
result := DataTable.Fields[idx_ProveedoresSUBCONTRATA].AsSmallInt;
end;
function TBizProveedor.GetTIENDA_WEBValue: Integer;
begin
result := DataTable.Fields[idx_ProveedoresTIENDA_WEB].AsInteger;
@ -667,6 +709,11 @@ begin
DataTable.Fields[idx_ProveedoresREGIMEN_IVA].AsString := aValue;
end;
procedure TBizProveedor.SetSUBCONTRATAValue(const aValue: SmallInt);
begin
DataTable.Fields[idx_ProveedoresSUBCONTRATA].AsSmallInt := aValue;
end;
procedure TBizProveedor.SetTIENDA_WEBValue(const aValue: Integer);
begin
DataTable.Fields[idx_ProveedoresTIENDA_WEB].AsInteger := aValue;

View File

@ -0,0 +1,61 @@
unit uBizContactosPersonal;
interface
uses
uDAInterfaces, uDADataTable,
schContactosClient_Intf;
const
BIZ_CLIENT_CONTACTO_PERSONAL = 'Client.ContactosPersonal';
type
IBizContactoPersonal = interface (IPersonalContacto)
['{9FFEFD2E-1EED-4FA2-80D7-81B1541B122C}']
end;
TBizContactoPersonal = class(TPersonalContactoDataTableRules, IBizContactoPersonal)
private
ContIdAux: Integer;
protected
procedure OnNewRecord(Sender: TDADataTable); override;
procedure BeforeInsert(Sender: TDADataTable); override;
public
constructor Create(aDataTable: TDADataTable); override;
end;
implementation
{ TBizContactoPersonal }
uses
DB;
procedure TBizContactoPersonal.BeforeInsert(Sender: TDADataTable);
var
AMasterTable : TDADataTable;
begin
inherited;
AMasterTable := DataTable.GetMasterDataTable;
if Assigned(AMasterTable) and (AMasterTable.State in dsEditModes) then
AMasterTable.Post;
end;
constructor TBizContactoPersonal.Create(aDataTable: TDADataTable);
begin
inherited;
ContIdAux := -1;
end;
procedure TBizContactoPersonal.OnNewRecord(Sender: TDADataTable);
begin
inherited;
ID := ContIdAux; // -1, -2, -3...
Dec(ContIdAux);
end;
initialization
RegisterDataTableRules(BIZ_CLIENT_CONTACTO_PERSONAL, TBizContactoPersonal);
end.

View File

@ -100,6 +100,7 @@ begin
ParamByName('HOMOLOGADO').Value := aChange.NewValueByName[fld_ProveedoresHOMOLOGADO];
ParamByName('CERTIFICACION').Value := aChange.NewValueByName[fld_ProveedoresCERTIFICACION];
ParamByName('GRUPO_PROVEEDOR').Value := aChange.NewValueByName[fld_ProveedoresGRUPO_PROVEEDOR];
ParamByName('SUBCONTRATA').Value := aChange.NewValueByName[fld_ProveedoresSUBCONTRATA];
Execute;
end;
finally
@ -135,6 +136,7 @@ begin
ParamByName('HOMOLOGADO').Value := aChange.NewValueByName[fld_ProveedoresHOMOLOGADO];
ParamByName('CERTIFICACION').Value := aChange.NewValueByName[fld_ProveedoresCERTIFICACION];
ParamByName('GRUPO_PROVEEDOR').Value := aChange.NewValueByName[fld_ProveedoresGRUPO_PROVEEDOR];
ParamByName('SUBCONTRATA').Value := aChange.NewValueByName[fld_ProveedoresSUBCONTRATA];
Execute;
end;
finally

View File

@ -874,6 +874,10 @@ object srvContactos: TsrvContactos
item
DatasetField = 'CERTIFICACION'
TableField = 'CERTIFICACION'
end
item
DatasetField = 'SUBCONTRATA'
TableField = 'SUBCONTRATA'
end>
end>
Name = 'Proveedores'
@ -990,10 +994,12 @@ object srvContactos: TsrvContactos
item
Name = 'FECHA_ALTA'
DataType = datDateTime
DictionaryEntry = 'Proveedores_FECHA_ALTA'
end
item
Name = 'FECHA_MODIFICACION'
DataType = datDateTime
DictionaryEntry = 'Proveedores_FECHA_MODIFICACION'
end
item
Name = 'USUARIO'
@ -1033,7 +1039,7 @@ object srvContactos: TsrvContactos
item
Name = 'GRUPO_PROVEEDOR'
DataType = datString
Size = 255
DictionaryEntry = 'Proveedores_GRUPO_PROVEEDOR'
end
item
Name = 'REGIMEN_IVA'
@ -1066,6 +1072,11 @@ object srvContactos: TsrvContactos
DataType = datString
Size = 255
DictionaryEntry = 'Proveedores_CERTIFICACION'
end
item
Name = 'SUBCONTRATA'
DataType = datSmallInt
DictionaryEntry = 'Proveedores_SUBCONTRATA'
end>
end
item
@ -1960,6 +1971,117 @@ object srvContactos: TsrvContactos
Size = 255
DictionaryEntry = 'Proveedores_DESCRIPCION_PROVEEDOR'
end>
end
item
Params = <>
Statements = <
item
ConnectionType = 'Interbase'
Default = True
TargetTable = 'CONTACTOS_DATOS_PERSONAL'
StatementType = stAutoSQL
ColumnMappings = <
item
DatasetField = 'ID'
TableField = 'ID'
end
item
DatasetField = 'ID_CONTACTO'
TableField = 'ID_CONTACTO'
end
item
DatasetField = 'NOMBRE'
TableField = 'NOMBRE'
end
item
DatasetField = 'PUESTO'
TableField = 'PUESTO'
end
item
DatasetField = 'TELEFONO'
TableField = 'TELEFONO'
end
item
DatasetField = 'MOVIL'
TableField = 'MOVIL'
end
item
DatasetField = 'FAX'
TableField = 'FAX'
end
item
DatasetField = 'EMAIL'
TableField = 'EMAIL'
end
item
DatasetField = 'FECHA_ALTA'
TableField = 'FECHA_ALTA'
end
item
DatasetField = 'FECHA_MODIFICACION'
TableField = 'FECHA_MODIFICACION'
end>
end>
Name = 'PersonalContacto'
Fields = <
item
Name = 'ID'
DataType = datAutoInc
GeneratorName = 'GEN_CONTACTOS_PERSONAL_ID'
DictionaryEntry = 'PersonalContacto_ID'
InPrimaryKey = True
end
item
Name = 'ID_CONTACTO'
DataType = datInteger
DictionaryEntry = 'PersonalContacto_ID_CONTACTO'
end
item
Name = 'NOMBRE'
DataType = datString
Size = 255
DictionaryEntry = 'PersonalContacto_NOMBRE'
end
item
Name = 'PUESTO'
DataType = datString
Size = 255
DictionaryEntry = 'PersonalContacto_PUESTO'
end
item
Name = 'TELEFONO'
DataType = datString
Size = 25
DictionaryEntry = 'PersonalContacto_TELEFONO'
end
item
Name = 'MOVIL'
DataType = datString
Size = 25
DictionaryEntry = 'PersonalContacto_MOVIL'
end
item
Name = 'FAX'
DataType = datString
Size = 25
DictionaryEntry = 'PersonalContacto_FAX'
end
item
Name = 'EMAIL'
DataType = datString
Size = 255
DictionaryEntry = 'PersonalContacto_EMAIL'
end
item
Name = 'FECHA_ALTA'
DataType = datDateTime
DictionaryEntry = 'PersonalContacto_FECHA_ALTA'
end
item
Name = 'FECHA_MODIFICACION'
DataType = datDateTime
DictionaryEntry = 'PersonalContacto_FECHA_MODIFICACION'
end>
end>
JoinDataTables = <>
UnionDataTables = <>
@ -2136,12 +2258,6 @@ object srvContactos: TsrvContactos
end
item
Params = <
item
Name = 'ID'
DataType = datInteger
Value = ''
ParamType = daptInput
end
item
Name = 'NIF_CIF'
DataType = datString
@ -2278,15 +2394,15 @@ object srvContactos: TsrvContactos
Connection = 'IBX'
TargetTable = 'CONTACTOS'
SQL =
'UPDATE CONTACTOS'#10' SET '#10' ID = :ID,'#10' NIF_CIF = :NIF_CIF, '#10' ' +
' NOMBRE = :NOMBRE, '#10' PERSONA_CONTACTO = :PERSONA_CONTACTO,'#10 +
' CALLE = :CALLE, '#10' POBLACION = :POBLACION, '#10' PROVINCIA ' +
'= :PROVINCIA, '#10' CODIGO_POSTAL = :CODIGO_POSTAL, '#10' TELEFONO' +
'_1 = :TELEFONO_1, '#10' TELEFONO_2 = :TELEFONO_2, '#10' MOVIL_1 = ' +
':MOVIL_1, '#10' MOVIL_2 = :MOVIL_2, '#10' FAX = :FAX, '#10' EMAIL_1' +
' = :EMAIL_1, '#10' EMAIL_2 = :EMAIL_2, '#10' PAGINA_WEB = :PAGINA_' +
'WEB, '#10' NOTAS = :NOTAS, '#10' USUARIO = :USUARIO,'#10' REFERENCI' +
'A = :REFERENCIA'#10' WHERE'#10' (ID = :OLD_ID)'
'UPDATE CONTACTOS'#10' SET '#10' NIF_CIF = :NIF_CIF,'#10' NOMBRE = :NO' +
'MBRE, '#10' PERSONA_CONTACTO = :PERSONA_CONTACTO,'#10' CALLE = :CA' +
'LLE, '#10' POBLACION = :POBLACION, '#10' PROVINCIA = :PROVINCIA, '#10 +
' CODIGO_POSTAL = :CODIGO_POSTAL, '#10' TELEFONO_1 = :TELEFONO_' +
'1, '#10' TELEFONO_2 = :TELEFONO_2, '#10' MOVIL_1 = :MOVIL_1, '#10' ' +
'MOVIL_2 = :MOVIL_2, '#10' FAX = :FAX, '#10' EMAIL_1 = :EMAIL_1, '#10' ' +
' EMAIL_2 = :EMAIL_2, '#10' PAGINA_WEB = :PAGINA_WEB, '#10' NOTAS' +
' = :NOTAS, '#10' USUARIO = :USUARIO,'#10' REFERENCIA = :REFERENCIA' +
#10' WHERE'#10' (ID = :OLD_ID)'#10
StatementType = stSQL
ColumnMappings = <>
end>
@ -2780,74 +2896,51 @@ object srvContactos: TsrvContactos
Params = <
item
Name = 'ID_PROVEEDOR'
DataType = datInteger
Value = ''
ParamType = daptInput
end
item
Name = 'REGIMEN_IVA'
DataType = datString
Size = 255
Value = ''
ParamType = daptInput
end
item
Name = 'DESCUENTO'
DataType = datFloat
Value = ''
ParamType = daptInput
end
item
Name = 'DESCRIPCION_PROVEEDOR'
DataType = datString
Size = 255
Value = ''
ParamType = daptInput
end
item
Name = 'CODIGO_ASIGNADO'
DataType = datString
Size = 255
Value = ''
ParamType = daptInput
end
item
Name = 'ID_TIPO_IVA'
DataType = datInteger
Value = ''
ParamType = daptInput
end
item
Name = 'SUBCONTRATA'
Value = ''
end
item
Name = 'ID_FORMA_PAGO'
DataType = datInteger
Value = ''
ParamType = daptInput
end
item
Name = 'TIENDA_WEB'
DataType = datInteger
Value = ''
ParamType = daptInput
end
item
Name = 'HOMOLOGADO'
DataType = datInteger
Value = ''
ParamType = daptInput
end
item
Name = 'CERTIFICACION'
DataType = datString
Size = 255
Value = ''
ParamType = daptInput
end
item
Name = 'GRUPO_PROVEEDOR'
DataType = datString
Size = 255
Value = ''
ParamType = daptInput
end>
Statements = <
item
@ -2856,11 +2949,11 @@ object srvContactos: TsrvContactos
SQL =
'INSERT'#10' INTO PROVEEDORES_DATOS'#10' (ID_PROVEEDOR, REGIMEN_IVA, ' +
'DESCUENTO, DESCRIPCION_PROVEEDOR,'#10' CODIGO_ASIGNADO, ID_TIPO_I' +
'VA,'#10' ID_FORMA_PAGO, TIENDA_WEB, HOMOLOGADO, CERTIFICACION, GR' +
'UPO_PROVEEDOR)'#10' VALUES'#10' (:ID_PROVEEDOR, :REGIMEN_IVA, :DESCU' +
'ENTO, :DESCRIPCION_PROVEEDOR,'#10' :CODIGO_ASIGNADO, :ID_TIPO_IVA' +
','#10' :ID_FORMA_PAGO, :TIENDA_WEB, :HOMOLOGADO, :CERTIFICACION, ' +
':GRUPO_PROVEEDOR)'
'VA, SUBCONTRATA,'#10' ID_FORMA_PAGO, TIENDA_WEB, HOMOLOGADO, CERT' +
'IFICACION, GRUPO_PROVEEDOR)'#10' VALUES'#10' (:ID_PROVEEDOR, :REGIME' +
'N_IVA, :DESCUENTO, :DESCRIPCION_PROVEEDOR,'#10' :CODIGO_ASIGNADO,' +
' :ID_TIPO_IVA, :SUBCONTRATA,'#10' :ID_FORMA_PAGO, :TIENDA_WEB, :H' +
'OMOLOGADO, :CERTIFICACION, :GRUPO_PROVEEDOR)'#10
StatementType = stSQL
ColumnMappings = <>
end>
@ -2890,80 +2983,55 @@ object srvContactos: TsrvContactos
Params = <
item
Name = 'ID_PROVEEDOR'
DataType = datInteger
Value = ''
ParamType = daptInput
end
item
Name = 'REGIMEN_IVA'
DataType = datString
Size = 255
Value = ''
ParamType = daptInput
end
item
Name = 'DESCUENTO'
DataType = datFloat
Value = ''
ParamType = daptInput
end
item
Name = 'DESCRIPCION_PROVEEDOR'
DataType = datString
Size = 255
Value = ''
ParamType = daptInput
end
item
Name = 'CODIGO_ASIGNADO'
DataType = datString
Size = 255
Value = ''
ParamType = daptInput
end
item
Name = 'ID_TIPO_IVA'
DataType = datInteger
Value = ''
ParamType = daptInput
end
item
Name = 'ID_FORMA_PAGO'
DataType = datInteger
Value = ''
ParamType = daptInput
end
item
Name = 'TIENDA_WEB'
DataType = datInteger
Value = ''
ParamType = daptInput
end
item
Name = 'HOMOLOGADO'
DataType = datInteger
Value = ''
ParamType = daptInput
end
item
Name = 'CERTIFICACION'
DataType = datString
Size = 255
Value = ''
ParamType = daptInput
end
item
Name = 'GRUPO_PROVEEDOR'
DataType = datString
Size = 255
Value = ''
ParamType = daptInput
end
item
Name = 'SUBCONTRATA'
Value = ''
end
item
Name = 'OLD_ID_PROVEEDOR'
DataType = datInteger
Value = ''
ParamType = daptInput
end>
Statements = <
item
@ -2976,8 +3044,8 @@ object srvContactos: TsrvContactos
'IGNADO = :CODIGO_ASIGNADO,'#10' ID_TIPO_IVA = :ID_TIPO_IVA,'#10' I' +
'D_FORMA_PAGO = :ID_FORMA_PAGO,'#10' TIENDA_WEB = :TIENDA_WEB,'#10' ' +
' HOMOLOGADO = :HOMOLOGADO,'#10' CERTIFICACION = :CERTIFICACION,'#10' ' +
' GRUPO_PROVEEDOR = :GRUPO_PROVEEDOR'#10' WHERE'#10' (ID_PROVEEDOR ' +
'= :OLD_ID_PROVEEDOR)'
' GRUPO_PROVEEDOR = :GRUPO_PROVEEDOR,'#10' SUBCONTRATA = :SUBCON' +
'TRATA'#10' WHERE'#10' (ID_PROVEEDOR = :OLD_ID_PROVEEDOR)'#10
StatementType = stSQL
ColumnMappings = <>
end>
@ -3518,8 +3586,165 @@ object srvContactos: TsrvContactos
ColumnMappings = <>
end>
Name = 'Delete_ContactoEmpresa'
end
item
Params = <
item
Name = 'ID'
DataType = datAutoInc
GeneratorName = 'GEN_CONTACTOS_PERSONAL_ID'
Value = ''
end
item
Name = 'ID_CONTACTO'
Value = ''
end
item
Name = 'NOMBRE'
Value = ''
end
item
Name = 'PUESTO'
Value = ''
end
item
Name = 'TELEFONO'
Value = ''
end
item
Name = 'MOVIL'
Value = ''
end
item
Name = 'FAX'
Value = ''
end
item
Name = 'EMAIL'
Value = ''
end>
Statements = <
item
ConnectionType = 'Interbase'
Default = True
TargetTable = 'CONTACTOS_DATOS_PERSONAL'
SQL =
'INSERT'#10' INTO CONTACTOS_DATOS_PERSONAL'#10' (ID, ID_CONTACTO, NOM' +
'BRE, PUESTO, TELEFONO, MOVIL, FAX,'#10' EMAIL, FECHA_ALTA)'#10' VAL' +
'UES'#10' (:ID, :ID_CONTACTO, :NOMBRE, :PUESTO, :TELEFONO, :MOVIL,' +
#10' :FAX, :EMAIL, CURRENT_TIME)'#10
StatementType = stSQL
ColumnMappings = <>
end>
Name = 'Insert_PersonalContacto'
end
item
Params = <
item
Name = 'OLD_ID'
DataType = datAutoInc
Value = '0'
end>
Statements = <
item
ConnectionType = 'Interbase'
Default = True
TargetTable = 'CONTACTOS_DATOS_PERSONAL'
SQL =
'DELETE '#10' FROM'#10' CONTACTOS_DATOS_PERSONAL'#10' WHERE'#10' (ID = :O' +
'LD_ID)'
StatementType = stSQL
ColumnMappings = <>
end>
Name = 'Delete_PersonalContacto'
end
item
Params = <
item
Name = 'ID_CONTACTO'
Value = ''
end
item
Name = 'NOMBRE'
Value = ''
end
item
Name = 'PUESTO'
Value = ''
end
item
Name = 'TELEFONO'
Value = ''
end
item
Name = 'MOVIL'
Value = ''
end
item
Name = 'FAX'
Value = ''
end
item
Name = 'EMAIL'
Value = ''
end
item
Name = 'FECHA_MODIFICACION'
Value = ''
end
item
Name = 'OLD_ID'
Value = ''
end>
Statements = <
item
ConnectionType = 'Interbase'
Default = True
TargetTable = 'CONTACTOS_DATOS_PERSONAL'
SQL =
'UPDATE CONTACTOS_DATOS_PERSONAL'#10' SET '#10' ID_CONTACTO = :ID_CON' +
'TACTO, '#10' NOMBRE = :NOMBRE, '#10' PUESTO = :PUESTO, '#10' TELEFO' +
'NO = :TELEFONO, '#10' MOVIL = :MOVIL, '#10' FAX = :FAX, '#10' EMAIL' +
' = :EMAIL, '#10' FECHA_MODIFICACION = :FECHA_MODIFICACION'#10' WHERE' +
#10' (ID = :OLD_ID)'#10
StatementType = stSQL
ColumnMappings = <>
end>
Name = 'Update_PersonalContacto'
end>
RelationShips = <
item
Name = 'FK_PersonalContacto_Empleados'
MasterDatasetName = 'Empleados'
MasterFields = 'ID'
DetailDatasetName = 'PersonalContacto'
DetailFields = 'ID_CONTACTO'
RelationshipType = rtForeignKey
end
item
Name = 'FK_PersonalContacto_Proveedores'
MasterDatasetName = 'Proveedores'
MasterFields = 'ID'
DetailDatasetName = 'PersonalContacto'
DetailFields = 'ID_CONTACTO'
RelationshipType = rtForeignKey
end
item
Name = 'FK_PersonalContacto_Clientes'
MasterDatasetName = 'Clientes'
MasterFields = 'ID'
DetailDatasetName = 'PersonalContacto'
DetailFields = 'ID_CONTACTO'
RelationshipType = rtForeignKey
end
item
Name = 'FK_PersonalContacto_Contactos'
MasterDatasetName = 'Contactos'
MasterFields = 'ID'
DetailDatasetName = 'PersonalContacto'
DetailFields = 'ID_CONTACTO'
RelationshipType = rtForeignKey
end
item
Name = 'FK_ClientesDescuentos_Clientes'
MasterDatasetName = 'Clientes'
@ -3663,6 +3888,20 @@ object srvContactos: TsrvContactos
DatasetName = 'DatosBancarios'
FailureBehavior = fbRaiseException
end
item
Name = 'Insert PersonalContacto'
DoUpdate = False
DoDelete = False
DatasetName = 'PersonalContacto'
FailureBehavior = fbRaiseException
end
item
Name = 'Update PersonalContacto'
DoInsert = False
DoDelete = False
DatasetName = 'PersonalContacto'
FailureBehavior = fbRaiseException
end
item
Name = 'Insert DireccionesContacto'
DoUpdate = False
@ -3726,6 +3965,13 @@ object srvContactos: TsrvContactos
DatasetName = 'AgentesComisiones'
FailureBehavior = fbRaiseException
end
item
Name = 'Delete PersonalContacto'
DoUpdate = False
DoInsert = False
DatasetName = 'PersonalContacto'
FailureBehavior = fbRaiseException
end
item
Name = 'Delete DireccionesContacto'
DoUpdate = False
@ -3762,7 +4008,7 @@ object srvContactos: TsrvContactos
FailureBehavior = fbRaiseException
end>
Version = 0
Left = 30
Left = 38
Top = 14
end
object DataDictionary: TDADataDictionary
@ -3866,7 +4112,7 @@ object srvContactos: TsrvContactos
Name = 'Contactos_MOVIL_2'
DataType = datString
Size = 25
DisplayLabel = 'MOVIL_2'
DisplayLabel = 'M'#243'vil 2'
end
item
Name = 'Contactos_FAX'
@ -4204,7 +4450,6 @@ object srvContactos: TsrvContactos
Name = 'Contactos_NOMBRE'
DataType = datString
Size = 255
Required = True
DisplayLabel = 'Nombre'
end
item
@ -4266,6 +4511,73 @@ object srvContactos: TsrvContactos
DataType = datString
Size = 255
DisplayLabel = 'Contrato'
end
item
Name = 'Proveedores_FECHA_ALTA'
DataType = datDateTime
end
item
Name = 'Proveedores_FECHA_MODIFICACION'
DataType = datDateTime
end
item
Name = 'Proveedores_SUBCONTRATA'
DataType = datSmallInt
DisplayLabel = 'Subcontrata'
end
item
Name = 'PersonalContacto_ID'
DataType = datAutoInc
GeneratorName = 'GEN_CONTACTOS_PERSONAL_ID'
Required = True
end
item
Name = 'PersonalContacto_ID_CONTACTO'
DataType = datInteger
end
item
Name = 'PersonalContacto_NOMBRE'
DataType = datString
Size = 255
DisplayLabel = 'Nombre'
end
item
Name = 'PersonalContacto_PUESTO'
DataType = datString
Size = 255
DisplayLabel = 'Puesto'
end
item
Name = 'PersonalContacto_TELEFONO'
DataType = datString
Size = 25
DisplayLabel = 'Tel'#233'fono'
end
item
Name = 'PersonalContacto_MOVIL'
DataType = datString
Size = 25
DisplayLabel = 'M'#243'vil'
end
item
Name = 'PersonalContacto_FAX'
DataType = datString
Size = 25
DisplayLabel = 'Fax'
end
item
Name = 'PersonalContacto_EMAIL'
DataType = datString
Size = 255
DisplayLabel = 'E-mail'
end
item
Name = 'PersonalContacto_FECHA_ALTA'
DataType = datDateTime
end
item
Name = 'PersonalContacto_FECHA_MODIFICACION'
DataType = datDateTime
end>
Left = 126
Top = 14
@ -4357,7 +4669,18 @@ object srvContactos: TsrvContactos
Top = 207
end
object Bin2DataStreamer: TDABin2DataStreamer
Left = 32
Left = 40
Top = 80
end
object bpPersonalContacto: TDABusinessProcessor
Schema = schContactos
InsertCommandName = 'Insert_PersonalContacto'
DeleteCommandName = 'Delete_PersonalContacto'
UpdateCommandName = 'Update_PersonalContacto'
ReferencedDataset = 'PersonalContacto'
ProcessorOptions = [poAutoGenerateRefreshDataset, poPrepareCommands]
UpdateMode = updWhereKeyOnly
Left = 224
Top = 143
end
end

View File

@ -31,6 +31,7 @@ type
bpDireccionesContacto: TDABusinessProcessor;
bpClientesDescuentos: TDABusinessProcessor;
Bin2DataStreamer: TDABin2DataStreamer;
bpPersonalContacto: TDABusinessProcessor;
schContactos: TDASchema;
DataDictionary: TDADataDictionary;
procedure DARemoteServiceBeforeGetDatasetData(const Dataset: IDADataset;
@ -67,12 +68,7 @@ procedure TsrvContactos.DARemoteServiceBeforeGetDatasetData(
const Dataset: IDADataset; const IncludeSchema: Boolean;
const MaxRecords: Integer);
begin
if (DataSet.Name <> nme_DatosBancarios) and
(DataSet.Name <> nme_DireccionesContacto) and
(DataSet.Name <> nme_GruposCliente) and
(DataSet.Name <> nme_GruposProveedor) and
(DataSet.Name <> nme_GruposEmpleado) and
(DataSet.Name <> nme_ClientesDescuentos) then
if Assigned(Dataset.FindField(fld_ContactosID_EMPRESA)) then
begin
{ Aquí se asegura que el usuario sólo accede a contactos
de las empresas a las que tiene permiso para acceder

View File

@ -93,6 +93,8 @@ contains
uEditorGruposEmpleado in 'uEditorGruposEmpleado.pas' {fEditorGruposEmpleado: TCustomEditor},
uEditorFichasEmpleadoReport in 'uEditorFichasEmpleadoReport.pas' {fEditorFichasEmpleadoReport: TCustomEditor},
uEditorEtiquetasContactosReport in 'uEditorEtiquetasContactosReport.pas' {fEditorEtiquetasContactosReport: TCustomEditor},
uEditorDireccion in 'uEditorDireccion.pas' {fEditorDireccion: TForm};
uEditorDireccion in 'uEditorDireccion.pas' {fEditorDireccion: TCustomEditor},
uEditorPersonal in 'uEditorPersonal.pas' {fEditorPersonal: TCustomEditor},
uViewPersonalContacto in 'uViewPersonalContacto.pas' {frViewPersonalContacto: TFrame};
end.

View File

@ -49,38 +49,38 @@
<DelphiCompile Include="Contactos_view.dpk">
<MainSource>MainSource</MainSource>
</DelphiCompile>
<DCCReference Include="C:\Documents and Settings\Usuario\adortl.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\ApplicationBase.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\Base.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\Contactos_controller.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\Contactos_model.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\cxDataD11.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\cxEditorsD11.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\cxExportD11.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\cxExtEditorsD11.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\cxGridD11.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\cxLibraryD11.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\cxPageControlD11.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\DataAbstract_Core_D11.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\dxGDIPlusD11.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\dxThemeD11.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\FormasPago_controller.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\FormasPago_model.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\GUIBase.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\JvGlobusD11R.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\PngComponentsD10.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\PNG_D10.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\RemObjects_Core_D11.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\rtl.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\TiposIVA_controller.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\TiposIVA_model.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\vcl.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\vclactnband.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\vcldb.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\vcljpg.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\vclx.dcp" />
<DCCReference Include="..\..\Obras\Views\adortl.dcp" />
<DCCReference Include="..\..\Obras\Views\ApplicationBase.dcp" />
<DCCReference Include="..\..\Obras\Views\Base.dcp" />
<DCCReference Include="..\..\Obras\Views\Contactos_controller.dcp" />
<DCCReference Include="..\..\Obras\Views\Contactos_model.dcp" />
<DCCReference Include="..\..\Obras\Views\cxDataD11.dcp" />
<DCCReference Include="..\..\Obras\Views\cxEditorsD11.dcp" />
<DCCReference Include="..\..\Obras\Views\cxExportD11.dcp" />
<DCCReference Include="..\..\Obras\Views\cxExtEditorsD11.dcp" />
<DCCReference Include="..\..\Obras\Views\cxGridD11.dcp" />
<DCCReference Include="..\..\Obras\Views\cxLibraryD11.dcp" />
<DCCReference Include="..\..\Obras\Views\cxPageControlD11.dcp" />
<DCCReference Include="..\..\Obras\Views\DataAbstract_Core_D11.dcp" />
<DCCReference Include="..\..\Obras\Views\dbrtl.dcp" />
<DCCReference Include="..\..\Obras\Views\dsnap.dcp" />
<DCCReference Include="..\..\Obras\Views\dxGDIPlusD11.dcp" />
<DCCReference Include="..\..\Obras\Views\dxThemeD11.dcp" />
<DCCReference Include="..\..\Obras\Views\FormasPago_controller.dcp" />
<DCCReference Include="..\..\Obras\Views\FormasPago_model.dcp" />
<DCCReference Include="..\..\Obras\Views\GUIBase.dcp" />
<DCCReference Include="..\..\Obras\Views\JvGlobusD11R.dcp" />
<DCCReference Include="..\..\Obras\Views\PngComponentsD10.dcp" />
<DCCReference Include="..\..\Obras\Views\PNG_D10.dcp" />
<DCCReference Include="..\..\Obras\Views\RemObjects_Core_D11.dcp" />
<DCCReference Include="..\..\Obras\Views\rtl.dcp" />
<DCCReference Include="..\..\Obras\Views\TiposIVA_controller.dcp" />
<DCCReference Include="..\..\Obras\Views\TiposIVA_model.dcp" />
<DCCReference Include="..\..\Obras\Views\vcl.dcp" />
<DCCReference Include="..\..\Obras\Views\vclactnband.dcp" />
<DCCReference Include="..\..\Obras\Views\vcldb.dcp" />
<DCCReference Include="..\..\Obras\Views\vcljpg.dcp" />
<DCCReference Include="..\..\Obras\Views\vclx.dcp" />
<DCCReference Include="uContactosViewRegister.pas" />
<DCCReference Include="uEditorCliente.pas">
<Form>fEditorCliente</Form>
@ -145,6 +145,10 @@
<Form>fEditorGruposProveedor</Form>
<DesignClass>TCustomEditor</DesignClass>
</DCCReference>
<DCCReference Include="uEditorPersonal.pas">
<Form>fEditorPersonal</Form>
<DesignClass>TCustomEditor</DesignClass>
</DCCReference>
<DCCReference Include="uEditorProveedor.pas">
<Form>fEditorProveedor</Form>
<DesignClass>TCustomEditor</DesignClass>
@ -205,6 +209,10 @@
<Form>frViewEmpleados</Form>
<DesignClass>TCustomView</DesignClass>
</DCCReference>
<DCCReference Include="uViewPersonalContacto.pas">
<Form>frViewPersonalContacto</Form>
<DesignClass>TFrame</DesignClass>
</DCCReference>
<DCCReference Include="uViewProveedor.pas">
<Form>frViewProveedor</Form>
<DesignClass>TCustomView</DesignClass>

View File

@ -15,7 +15,7 @@ uses
uEditorEmpleado, uEditorElegirProveedores, uEditorDireccion,
uEditorElegirDireccionEntrega, uEditorGruposCliente, uEditorGruposProveedor, uEditorGruposEmpleado,
uEditorFichasEmpleadoReport, uEditorEtiquetasContactosReport,
uEditorDatoBancario;
uEditorDatoBancario, uEditorPersonal;
procedure RegisterViews;
begin
@ -33,6 +33,8 @@ begin
EditorRegistry.RegisterClass(TfEditorDireccion, 'EditorDireccion');
EditorRegistry.RegisterClass(TfEditorElegirDireccionEntrega, 'EditorElegirDireccionEntrega');
EditorRegistry.RegisterClass(TfEditorPersonal, 'EditorPersonalContacto');
EditorRegistry.RegisterClass(TfEditorGruposCliente, 'EditorGruposCliente');
EditorRegistry.RegisterClass(TfEditorGruposProveedor, 'EditorGruposProveedor');
EditorRegistry.RegisterClass(TfEditorGruposEmpleado, 'EditorGruposEmpleado');
@ -59,6 +61,8 @@ begin
EditorRegistry.UnRegisterClass(TfEditorDireccion);
EditorRegistry.UnRegisterClass(TfEditorElegirDireccionEntrega);
EditorRegistry.UnRegisterClass(TfEditorPersonal);
EditorRegistry.UnRegisterClass(TfEditorGruposCliente);
EditorRegistry.UnRegisterClass(TfEditorGruposProveedor);
EditorRegistry.UnRegisterClass(TfEditorGruposEmpleado);

View File

@ -66,10 +66,10 @@ inherited fEditorCliente: TfEditorCliente
Width = 650
Height = 383
ExplicitWidth = 650
ExplicitHeight = 484
ExplicitHeight = 383
inherited pagGeneral: TTabSheet
ExplicitWidth = 642
ExplicitHeight = 456
ExplicitHeight = 355
inline frViewCliente1: TfrViewCliente
Left = 0
Top = 0
@ -85,13 +85,13 @@ inherited fEditorCliente: TfEditorCliente
TabOrder = 0
ReadOnly = False
ExplicitWidth = 642
ExplicitHeight = 456
ExplicitHeight = 355
inherited dxLayoutControlContacto: TdxLayoutControl
Width = 642
Height = 355
LookAndFeel = dxLayoutOfficeLookAndFeel
ExplicitWidth = 642
ExplicitHeight = 456
ExplicitHeight = 355
inherited PngSpeedButton1: TPngSpeedButton
Left = 581
Top = 218
@ -179,9 +179,9 @@ inherited fEditorCliente: TfEditorCliente
Top = 315
ExplicitLeft = 420
ExplicitTop = 315
ExplicitWidth = 189
ExplicitWidth = 184
ExplicitHeight = 34
Width = 189
Width = 184
end
inherited eTlfParticular: TcxDBTextEdit
Left = 515
@ -282,18 +282,17 @@ inherited fEditorCliente: TfEditorCliente
end
inherited pagDatosBancarios: TTabSheet
ExplicitWidth = 642
ExplicitHeight = 456
ExplicitHeight = 355
inherited frViewListaDatosBancarios: TfrViewListaDatosBancarios
Width = 642
Height = 355
ExplicitTop = 0
ExplicitWidth = 642
ExplicitHeight = 456
ExplicitHeight = 355
inherited cxGrid: TcxGrid
Width = 642
Height = 330
ExplicitWidth = 642
ExplicitHeight = 431
ExplicitHeight = 330
end
inherited ToolBar1: TToolBar
Width = 642
@ -301,10 +300,9 @@ inherited fEditorCliente: TfEditorCliente
end
end
end
object pagDatosComerciales: TTabSheet
object pagDatosComerciales: TTabSheet [2]
Caption = 'Datos comerciales'
ImageIndex = 4
ExplicitHeight = 456
inline frViewClienteDatosComerciales1: TfrViewClienteDatosComerciales
Left = 0
Top = 0
@ -390,10 +388,9 @@ inherited fEditorCliente: TfEditorCliente
end
end
end
object pagDirecciones: TTabSheet
object pagDirecciones: TTabSheet [3]
Caption = 'Direcciones'
ImageIndex = 1
ExplicitHeight = 456
inline frViewDireccionesEntrega1: TfrViewDireccionesEntrega
Left = 0
Top = 0
@ -409,12 +406,12 @@ inherited fEditorCliente: TfEditorCliente
TabOrder = 0
ReadOnly = False
ExplicitWidth = 642
ExplicitHeight = 456
ExplicitHeight = 355
inherited cxGrid: TcxGrid
Width = 642
Height = 330
ExplicitWidth = 642
ExplicitHeight = 431
ExplicitHeight = 330
inherited cxGridView: TcxGridDBTableView
inherited cxGridViewID: TcxGridDBColumn
SortIndex = 0
@ -425,25 +422,12 @@ inherited fEditorCliente: TfEditorCliente
inherited ToolBar1: TToolBar
Width = 642
ExplicitWidth = 642
inherited ToolButton1: TToolButton
ExplicitWidth = 113
end
inherited ToolButton4: TToolButton
ExplicitWidth = 113
end
inherited ToolButton2: TToolButton
ExplicitWidth = 113
end
inherited ToolButton7: TToolButton
ExplicitWidth = 113
end
end
end
end
object pagDescuentos: TTabSheet
object pagDescuentos: TTabSheet [4]
Caption = 'Descuentos'
ImageIndex = 2
ExplicitHeight = 456
inline frViewClienteDescuentos1: TfrViewClienteDescuentos
Left = 0
Top = 0
@ -459,12 +443,12 @@ inherited fEditorCliente: TfEditorCliente
TabOrder = 0
ReadOnly = False
ExplicitWidth = 642
ExplicitHeight = 456
ExplicitHeight = 355
inherited cxGrid: TcxGrid
Width = 642
Height = 330
ExplicitWidth = 642
ExplicitHeight = 431
ExplicitHeight = 330
end
inherited ToolBar1: TToolBar
Width = 642
@ -500,11 +484,32 @@ inherited fEditorCliente: TfEditorCliente
end
end
end
inherited pagPersonal: TTabSheet
ExplicitWidth = 642
ExplicitHeight = 355
inherited frViewPersonalContacto1: TfrViewPersonalContacto
Width = 642
Height = 355
ExplicitTop = 0
ExplicitWidth = 642
ExplicitHeight = 355
inherited cxGrid: TcxGrid
Width = 642
Height = 330
ExplicitWidth = 642
ExplicitHeight = 330
end
inherited ToolBar1: TToolBar
Width = 642
ExplicitWidth = 642
end
end
end
end
inherited StatusBar: TJvStatusBar
Top = 465
Width = 656
ExplicitTop = 566
ExplicitTop = 465
ExplicitWidth = 656
end
inherited EditorActionList: TActionList

View File

@ -14,7 +14,8 @@ uses
uIEditorCliente, TBXStatusBars, JvExComCtrls, JvStatusBar, uViewEmpleado,
uViewDireccionesEntrega, uViewDetallesGenerico, uViewClienteDescuentos,
uViewContactoDatosBancarios, dxLayoutLookAndFeels,
uViewClienteDatosComerciales, uDAInterfaces, uViewContactoListaDatosBancarios;
uViewClienteDatosComerciales, uDAInterfaces, uViewContactoListaDatosBancarios,
uViewPersonalContacto;
type
TfEditorCliente = class(TfEditorContacto, IEditorCliente)

View File

@ -69,7 +69,7 @@ inherited fEditorContacto: TfEditorContacto
end
inherited pgPaginas: TPageControl
Width = 626
ActivePage = pagDatosBancarios
ActivePage = pagPersonal
ExplicitWidth = 626
inherited pagGeneral: TTabSheet
ExplicitLeft = 4
@ -94,33 +94,63 @@ inherited fEditorContacto: TfEditorContacto
ParentFont = False
TabOrder = 0
ReadOnly = False
ExplicitTop = 113
ExplicitWidth = 618
ExplicitHeight = 219
ExplicitHeight = 332
inherited cxGrid: TcxGrid
Width = 618
Height = 307
ExplicitWidth = 618
ExplicitHeight = 194
ExplicitHeight = 307
end
inherited ToolBar1: TToolBar
Width = 618
ExplicitWidth = 618
inherited ToolButton1: TToolButton
ExplicitWidth = 62
ExplicitWidth = 113
end
inherited ToolButton4: TToolButton
ExplicitWidth = 74
ExplicitWidth = 113
end
inherited ToolButton2: TToolButton
ExplicitWidth = 67
ExplicitWidth = 113
end
inherited ToolButton7: TToolButton
ExplicitWidth = 117
ExplicitWidth = 113
end
end
end
end
object pagPersonal: TTabSheet
Caption = 'Personal'
ImageIndex = 2
inline frViewPersonalContacto1: TfrViewPersonalContacto
Left = 0
Top = 0
Width = 618
Height = 332
Align = alClient
Font.Charset = DEFAULT_CHARSET
Font.Color = clWindowText
Font.Height = -11
Font.Name = 'Tahoma'
Font.Style = []
ParentFont = False
TabOrder = 0
ReadOnly = False
ExplicitWidth = 618
ExplicitHeight = 332
inherited cxGrid: TcxGrid
Width = 618
Height = 307
ExplicitWidth = 618
ExplicitHeight = 307
end
inherited ToolBar1: TToolBar
Width = 618
ExplicitWidth = 618
end
end
end
end
inherited StatusBar: TJvStatusBar
Width = 632

View File

@ -14,7 +14,8 @@ uses
uIEditorContacto, uContactosController, TBXStatusBars, JvExComCtrls,
JvStatusBar, uViewContactoDatosBancarios, dxLayoutLookAndFeels, JvLabel,
uDAInterfaces, uViewDetallesGenerico, uViewContactoListaDatosBancarios;
uDAInterfaces, uViewDetallesGenerico, uViewContactoListaDatosBancarios,
uViewPersonalContacto;
type
TfEditorContacto = class(TfEditorDBItem, IEditorContacto)
@ -22,6 +23,8 @@ type
dxLayoutLookAndFeel: TdxLayoutLookAndFeelList;
dxLayoutOfficeLookAndFeel: TdxLayoutOfficeLookAndFeel;
frViewListaDatosBancarios: TfrViewListaDatosBancarios;
pagPersonal: TTabSheet;
frViewPersonalContacto1: TfrViewPersonalContacto;
procedure FormShow(Sender: TObject);
procedure dsDataTableDataChange(Sender: TObject; Field: TField);
protected
@ -115,9 +118,11 @@ begin
begin
FViewContacto.Contacto := Contacto;
frViewListaDatosBancarios.dsDetalles.DataTable := FContacto.DatosBancarios.DataTable;
frViewPersonalContacto1.dsDetalles.DataTable := FContacto.Personal.DataTable;
end
else begin
frViewListaDatosBancarios.dsDetalles.DataTable := NIL;
frViewPersonalContacto1.dsDetalles.DataTable := NIL;
end;
end;

View File

@ -2,7 +2,6 @@ inherited fEditorEmpleado: TfEditorEmpleado
Caption = 'fEditorEmpleado'
ClientHeight = 583
ClientWidth = 929
ExplicitTop = -46
ExplicitWidth = 937
ExplicitHeight = 610
PixelsPerInch = 96
@ -64,11 +63,12 @@ inherited fEditorEmpleado: TfEditorEmpleado
inherited pgPaginas: TPageControl
Width = 923
Height = 482
ActivePage = pagFormacion
ExplicitWidth = 923
ExplicitHeight = 601
ExplicitHeight = 482
inherited pagGeneral: TTabSheet
ExplicitWidth = 915
ExplicitHeight = 573
ExplicitHeight = 454
inline frViewEmpleado1: TfrViewEmpleado
Left = 0
Top = 0
@ -84,13 +84,13 @@ inherited fEditorEmpleado: TfEditorEmpleado
TabOrder = 0
ReadOnly = False
ExplicitWidth = 915
ExplicitHeight = 573
ExplicitHeight = 454
inherited dxLayoutControlContacto: TdxLayoutControl
Width = 915
Height = 454
LookAndFeel = dxLayoutOfficeLookAndFeel
ExplicitWidth = 915
ExplicitHeight = 573
ExplicitHeight = 454
inherited PngSpeedButton1: TPngSpeedButton
Left = 870
Top = 218
@ -268,18 +268,51 @@ inherited fEditorEmpleado: TfEditorEmpleado
end
inherited pagDatosBancarios: TTabSheet
ExplicitWidth = 915
ExplicitHeight = 573
ExplicitHeight = 454
inherited frViewListaDatosBancarios: TfrViewListaDatosBancarios
Width = 915
Height = 454
ExplicitTop = 0
ExplicitWidth = 915
ExplicitHeight = 573
ExplicitHeight = 454
inherited cxGrid: TcxGrid
Width = 915
Height = 429
ExplicitWidth = 915
ExplicitHeight = 548
ExplicitHeight = 429
end
inherited ToolBar1: TToolBar
Width = 915
ExplicitWidth = 915
inherited ToolButton1: TToolButton
ExplicitWidth = 113
end
inherited ToolButton4: TToolButton
ExplicitWidth = 113
end
inherited ToolButton2: TToolButton
ExplicitWidth = 113
end
inherited ToolButton7: TToolButton
ExplicitWidth = 113
end
end
end
end
inherited pagPersonal: TTabSheet
TabVisible = False
ExplicitWidth = 915
ExplicitHeight = 454
inherited frViewPersonalContacto1: TfrViewPersonalContacto
Width = 915
Height = 454
ExplicitTop = 0
ExplicitWidth = 915
ExplicitHeight = 454
inherited cxGrid: TcxGrid
Width = 915
Height = 429
ExplicitWidth = 915
ExplicitHeight = 429
end
inherited ToolBar1: TToolBar
Width = 915
@ -290,7 +323,6 @@ inherited fEditorEmpleado: TfEditorEmpleado
object pagFormacion: TTabSheet
Caption = 'Formaci'#243'n'
ImageIndex = 2
ExplicitHeight = 573
object dxLayoutControl1: TdxLayoutControl
Left = 0
Top = 0
@ -301,7 +333,6 @@ inherited fEditorEmpleado: TfEditorEmpleado
TabOrder = 0
AutoContentSizes = [acsWidth, acsHeight]
LookAndFeel = dxLayoutOfficeLookAndFeel
ExplicitHeight = 573
object eFormacionBasica: TcxDBMemo
Left = 22
Top = 30
@ -409,7 +440,6 @@ inherited fEditorEmpleado: TfEditorEmpleado
object pagExperiencia: TTabSheet
Caption = 'Experiencia'
ImageIndex = 3
ExplicitHeight = 573
object dxLayoutControl2: TdxLayoutControl
Left = 0
Top = 0
@ -420,7 +450,6 @@ inherited fEditorEmpleado: TfEditorEmpleado
TabOrder = 0
AutoContentSizes = [acsWidth, acsHeight]
LookAndFeel = dxLayoutOfficeLookAndFeel
ExplicitHeight = 573
object eExperiencia: TcxDBMemo
Left = 22
Top = 30
@ -466,7 +495,7 @@ inherited fEditorEmpleado: TfEditorEmpleado
inherited StatusBar: TJvStatusBar
Top = 564
Width = 929
ExplicitTop = 683
ExplicitTop = 564
ExplicitWidth = 929
end
inherited EditorActionList: TActionList

View File

@ -12,7 +12,7 @@ uses
uIEditorEmpleado, pngimage, TBXStatusBars, JvExComCtrls, JvStatusBar,
uViewDetallesGenerico, uViewContactoDatosBancarios, dxLayoutLookAndFeels,
dxLayoutControl, cxContainer, cxEdit, cxTextEdit, cxMemo, cxDBEdit, cxControls,
uDAInterfaces, uViewContactoListaDatosBancarios;
uDAInterfaces, uViewContactoListaDatosBancarios, uViewPersonalContacto;
type
TfEditorEmpleado = class(TfEditorContacto, IEditorEmpleado)

View File

@ -0,0 +1,201 @@
object fEditorPersonal: TfEditorPersonal
Left = 227
Top = 108
ActiveControl = eNombre
BorderStyle = bsDialog
Caption = 'Datos de personal'
ClientHeight = 205
ClientWidth = 527
Color = clBtnFace
ParentFont = True
OldCreateOrder = True
Position = poOwnerFormCenter
DesignSize = (
527
205)
PixelsPerInch = 96
TextHeight = 13
object Bevel1: TBevel
Left = 8
Top = 8
Width = 430
Height = 185
Anchors = [akLeft, akTop, akRight]
Shape = bsFrame
ExplicitWidth = 329
end
object Label5: TLabel
Left = 20
Top = 27
Width = 110
Height = 13
AutoSize = False
Caption = 'Nombre completo:'
end
object Label6: TLabel
Left = 20
Top = 55
Width = 109
Height = 13
AutoSize = False
Caption = 'Puesto:'
end
object Label7: TLabel
Left = 20
Top = 90
Width = 109
Height = 13
AutoSize = False
Caption = 'Tel'#233'fono:'
end
object Label11: TLabel
Left = 20
Top = 113
Width = 109
Height = 13
AutoSize = False
Caption = 'Movil:'
end
object Label12: TLabel
Left = 20
Top = 137
Width = 109
Height = 13
AutoSize = False
Caption = 'Fax:'
end
object PngSpeedButton3: TPngSpeedButton
Left = 401
Top = 154
Width = 23
Height = 22
Anchors = [akTop, akRight]
OnClick = PngSpeedButton3Click
PngImage.Data = {
89504E470D0A1A0A0000000D49484452000000100000001008060000001FF3FF
610000000970485973000017120000171201679FD252000001964944415478DA
63FCFFFF3F03232323033A58BCE9F87F647EAC9F258622B05E6C068034873B8A
80D92019C62F8F194C1356339CDF399D91A0014B361FFB1FE6208AA299E1F323
306D52F90CC5100C03566E3DFC3FD04E02A2F9F727064690462066006A66FC02
64FFFAC8603451096E088A01CB361FFDFF8F819981183077D11A86FDAB7B18E1
062CDD7CE27F14573FC3B2EF450CD13E86181ABE7DFFCDF0F5DB6F866FDFFE30
1CB97897218AB38FC1B85B98E1DC8E698C600396000D8861696058FAB7116CC0
94C5FBB0DAEC6CAECF70EED6238668E67AB057500CF8F0E10383A0A0208A0B90
6D06B1BF01D9379E3C67387AFE09C389A37BD15CE06B01B47907434EAC13C3EF
3F7F19662E3F8862BB898606C3EFDFFF1896EF3DCFA0A5C0CD306FE9265403FC
9D20362F5CB71F4CE7C47AA01890D5BC164C7716F980D56018606BAC0656B079
EF2986F82047AC6150DEB785A13CD911AC06C300234D05867DC72F30B8D818E1
8DC2494B0E63F702281075D455884A07576EDEC134404A5480E1DAED07441900
021806F44D5D44B46618801B400900007F4518F05E90AAF20000000049454E44
AE426082}
PngOptions = [pngBlendOnDisabled, pngGrayscaleOnDisabled]
ExplicitLeft = 302
end
object Label8: TLabel
Left = 20
Top = 158
Width = 109
Height = 13
AutoSize = False
Caption = 'Correo electr'#243'nico:'
end
object OKBtn: TButton
Left = 444
Top = 7
Width = 75
Height = 25
Anchors = [akTop, akRight]
Caption = '&Aceptar'
ModalResult = 1
TabOrder = 0
end
object CancelBtn: TButton
Left = 444
Top = 38
Width = 75
Height = 25
Anchors = [akTop, akRight]
Cancel = True
Caption = '&Cancelar'
ModalResult = 2
TabOrder = 1
OnClick = CancelBtnClick
end
object eNombre: TDBEdit
Left = 135
Top = 24
Width = 290
Height = 21
Anchors = [akLeft, akTop, akRight]
DataField = 'NOMBRE'
DataSource = dsPersonal
TabOrder = 2
end
object ePuesto: TDBEdit
Left = 135
Top = 55
Width = 290
Height = 21
Anchors = [akLeft, akTop, akRight]
DataField = 'PUESTO'
DataSource = dsPersonal
TabOrder = 3
end
object eTelefono: TDBEdit
Left = 135
Top = 87
Width = 290
Height = 21
Anchors = [akLeft, akTop, akRight]
DataField = 'TELEFONO'
DataSource = dsPersonal
TabOrder = 4
end
object eMovil: TDBEdit
Left = 135
Top = 110
Width = 290
Height = 21
Anchors = [akLeft, akTop, akRight]
DataField = 'MOVIL'
DataSource = dsPersonal
TabOrder = 5
end
object eFax: TDBEdit
Left = 135
Top = 132
Width = 290
Height = 21
Anchors = [akLeft, akTop, akRight]
DataField = 'FAX'
DataSource = dsPersonal
TabOrder = 6
end
object eMail: TcxDBHyperLinkEdit
Left = 134
Top = 155
Anchors = [akLeft, akTop, akRight]
DataBinding.DataField = 'EMAIL'
DataBinding.DataSource = dsPersonal
Properties.OnEditValueChanged = eMailPropertiesEditValueChanged
Properties.OnValidate = eMailPropertiesValidate
Properties.Prefix = 'mailto:'
Style.BorderColor = clWindowFrame
Style.BorderStyle = ebs3D
Style.HotTrack = False
Style.LookAndFeel.Kind = lfStandard
Style.LookAndFeel.NativeStyle = True
StyleDisabled.LookAndFeel.Kind = lfStandard
StyleDisabled.LookAndFeel.NativeStyle = True
StyleFocused.LookAndFeel.Kind = lfStandard
StyleFocused.LookAndFeel.NativeStyle = True
StyleHot.LookAndFeel.Kind = lfStandard
StyleHot.LookAndFeel.NativeStyle = True
TabOrder = 7
Width = 261
end
object dsPersonal: TDADataSource
Left = 440
Top = 72
end
end

View File

@ -0,0 +1,124 @@
unit uEditorPersonal;
interface
uses Windows, SysUtils, Classes, Graphics, Forms, Controls, StdCtrls,
Buttons, ExtCtrls, Mask, DBCtrls, DB, uDADataTable, PngSpeedButton,
cxControls, cxContainer, cxEdit, cxTextEdit, cxHyperLinkEdit, cxDBEdit,
uPersonalContactoController, uBizContactosPersonal,
uDAInterfaces, uIEditorPersonalContacto;
type
TfEditorPersonal = class(TForm, IEditorPersonalContacto)
OKBtn: TButton;
CancelBtn: TButton;
Bevel1: TBevel;
dsPersonal: TDADataSource;
Label5: TLabel;
eNombre: TDBEdit;
Label6: TLabel;
ePuesto: TDBEdit;
Label7: TLabel;
eTelefono: TDBEdit;
Label11: TLabel;
eMovil: TDBEdit;
Label12: TLabel;
eFax: TDBEdit;
eMail: TcxDBHyperLinkEdit;
PngSpeedButton3: TPngSpeedButton;
Label8: TLabel;
procedure PngSpeedButton3Click(Sender: TObject);
procedure eMailPropertiesEditValueChanged(Sender: TObject);
procedure eMailPropertiesValidate(Sender: TObject;
var DisplayValue: Variant; var ErrorText: TCaption; var Error: Boolean);
procedure CancelBtnClick(Sender: TObject);
protected
FController : IPersonalContactoController;
FPersonal: IBizContactoPersonal;
function GetController : IPersonalContactoController;
procedure SetController (const Value : IPersonalContactoController);
function GetPersonal: IBizContactoPersonal;
procedure SetPersonal(const Value: IBizContactoPersonal);
public
constructor Create(AOwner: TComponent); override;
destructor Destroy; override;
property Controller : IPersonalContactoController read GetController
write SetController;
property Personal: IBizContactoPersonal read GetPersonal write SetPersonal;
end;
implementation
uses
Variants;
type
THackcxDBHyperLinkEdit = class(TcxDBHyperLinkEdit);
{$R *.dfm}
{ TfEditorPersonal }
procedure TfEditorPersonal.CancelBtnClick(Sender: TObject);
begin
if FPersonal.DataTable.Editing then
FPersonal.Cancel;
end;
constructor TfEditorPersonal.Create(AOwner: TComponent);
begin
inherited;
FController := NIL;
end;
destructor TfEditorPersonal.Destroy;
begin
FController := NIL;
inherited;
end;
procedure TfEditorPersonal.eMailPropertiesEditValueChanged(Sender: TObject);
begin
if not VarIsNull((Sender as TcxDBHyperLinkEdit).EditValue) then
(Sender as TcxDBHyperLinkEdit).EditValue := StringReplace((Sender as TcxDBHyperLinkEdit).EditValue, (Sender as TcxDBHyperLinkEdit).Properties.Prefix, '', []);
end;
procedure TfEditorPersonal.eMailPropertiesValidate(Sender: TObject;
var DisplayValue: Variant; var ErrorText: TCaption; var Error: Boolean);
begin
if not VarIsNull(DisplayValue) then
DisplayValue := StringReplace(DisplayValue, (Sender as TcxDBHyperLinkEdit).Properties.Prefix, '', []);
end;
function TfEditorPersonal.GetController: IPersonalContactoController;
begin
Result := FController;
end;
function TfEditorPersonal.GetPersonal: IBizContactoPersonal;
begin
Result := FPersonal;
end;
procedure TfEditorPersonal.PngSpeedButton3Click(Sender: TObject);
begin
THackcxDBHyperLinkEdit(eMail).DoStart;
end;
procedure TfEditorPersonal.SetController(
const Value: IPersonalContactoController);
begin
FController := Value;
end;
procedure TfEditorPersonal.SetPersonal(const Value: IBizContactoPersonal);
begin
FPersonal := Value;
if Assigned(FPersonal) then
dsPersonal.DataTable := FPersonal.DataTable
else
dsPersonal.DataTable := NIL;
end;
end.

View File

@ -1,10 +1,10 @@
inherited fEditorProveedor: TfEditorProveedor
Caption = 'fEditorProveedor'
ClientHeight = 552
ClientHeight = 617
ClientWidth = 839
ExplicitTop = -15
ExplicitTop = -87
ExplicitWidth = 847
ExplicitHeight = 579
ExplicitHeight = 644
PixelsPerInch = 96
TextHeight = 13
inherited JvNavPanelHeader: TJvNavPanelHeader
@ -58,17 +58,18 @@ inherited fEditorProveedor: TfEditorProveedor
end
inherited pgPaginas: TPageControl
Width = 833
Height = 451
Height = 516
ActivePage = pagGeneral
ExplicitWidth = 833
ExplicitHeight = 564
ExplicitHeight = 451
inherited pagGeneral: TTabSheet
ExplicitWidth = 825
ExplicitHeight = 536
ExplicitHeight = 423
inline frViewProveedor1: TfrViewProveedor
Left = 0
Top = 0
Width = 825
Height = 423
Height = 488
Align = alClient
Font.Charset = DEFAULT_CHARSET
Font.Color = clWindowText
@ -79,36 +80,36 @@ inherited fEditorProveedor: TfEditorProveedor
TabOrder = 0
ReadOnly = False
ExplicitWidth = 825
ExplicitHeight = 536
ExplicitHeight = 423
inherited dxLayoutControlContacto: TdxLayoutControl
Width = 825
Height = 423
Height = 488
LookAndFeel = dxLayoutOfficeLookAndFeel
ExplicitWidth = 825
ExplicitHeight = 536
ExplicitHeight = 423
inherited PngSpeedButton1: TPngSpeedButton
Left = 764
Left = 780
Top = 218
ExplicitLeft = 764
ExplicitLeft = 780
ExplicitTop = 218
end
inherited PngSpeedButton2: TPngSpeedButton
Left = 764
Left = 780
Top = 190
ExplicitLeft = 764
ExplicitLeft = 780
ExplicitTop = 190
end
inherited PngSpeedButton3: TPngSpeedButton
Left = 764
Left = 780
Top = 162
ExplicitLeft = 764
ExplicitLeft = 780
ExplicitTop = 162
end
inherited Label1: TLabel
Left = 495
Left = 504
Top = 297
Width = 342
ExplicitLeft = 495
ExplicitLeft = 504
ExplicitTop = 297
ExplicitWidth = 342
end
@ -131,9 +132,9 @@ inherited fEditorProveedor: TfEditorProveedor
Width = 108
end
inherited eCodigoPostal: TcxDBTextEdit
Left = 402
Left = 411
Top = 294
ExplicitLeft = 402
ExplicitLeft = 411
ExplicitTop = 294
end
inherited eObservaciones: TcxDBMemo
@ -145,9 +146,9 @@ inherited fEditorProveedor: TfEditorProveedor
Width = 580
end
inherited cxDBCheckBox1: TcxDBCheckBox
Left = 495
Left = 504
Top = 270
ExplicitLeft = 495
ExplicitLeft = 504
ExplicitTop = 270
ExplicitWidth = 310
Width = 310
@ -183,33 +184,33 @@ inherited fEditorProveedor: TfEditorProveedor
Width = 221
end
inherited eTlfParticular: TcxDBTextEdit
Left = 590
Left = 599
Top = 57
ExplicitLeft = 590
ExplicitLeft = 599
ExplicitTop = 57
ExplicitWidth = 172
Width = 172
end
inherited eTlfTrabajo: TcxDBTextEdit
Left = 590
Left = 599
Top = 30
ExplicitLeft = 590
ExplicitLeft = 599
ExplicitTop = 30
ExplicitWidth = 172
Width = 172
end
inherited eTlfMovil: TcxDBTextEdit
Left = 590
Left = 599
Top = 84
ExplicitLeft = 590
ExplicitLeft = 599
ExplicitTop = 84
ExplicitWidth = 172
Width = 172
end
inherited eFax: TcxDBTextEdit
Left = 590
Left = 599
Top = 111
ExplicitLeft = 590
ExplicitLeft = 599
ExplicitTop = 111
ExplicitWidth = 172
Width = 172
@ -221,35 +222,41 @@ inherited fEditorProveedor: TfEditorProveedor
Width = 263
end
inherited eNIFCIF: TcxDBTextEdit
Left = 256
Left = 260
Top = 30
ExplicitLeft = 256
ExplicitLeft = 260
ExplicitTop = 30
ExplicitWidth = 254
Width = 254
end
inherited eMailTrabajo: TcxDBHyperLinkEdit
Left = 590
Left = 599
Top = 162
Properties.Prefix = 'mailto:'
ExplicitLeft = 590
ExplicitLeft = 599
ExplicitTop = 162
ExplicitWidth = 129
Width = 129
end
inherited eMailParticular: TcxDBHyperLinkEdit
Left = 590
Left = 599
Top = 190
Properties.Prefix = 'mailto:'
ExplicitLeft = 590
ExplicitLeft = 599
ExplicitTop = 190
ExplicitWidth = 165
Width = 165
end
inherited cxDBCheckBox3: TcxDBCheckBox
Left = 393
Top = 138
ExplicitLeft = 393
ExplicitTop = 138
end
inherited ePaginaWeb: TcxDBHyperLinkEdit
Left = 590
Left = 599
Top = 217
ExplicitLeft = 590
ExplicitLeft = 599
ExplicitTop = 217
ExplicitWidth = 165
Width = 165
@ -271,18 +278,17 @@ inherited fEditorProveedor: TfEditorProveedor
end
inherited pagDatosBancarios: TTabSheet
ExplicitWidth = 825
ExplicitHeight = 536
ExplicitHeight = 423
inherited frViewListaDatosBancarios: TfrViewListaDatosBancarios
Width = 825
Height = 423
ExplicitTop = 0
Height = 488
ExplicitWidth = 825
ExplicitHeight = 536
ExplicitHeight = 423
inherited cxGrid: TcxGrid
Width = 825
Height = 398
Height = 463
ExplicitWidth = 825
ExplicitHeight = 511
ExplicitHeight = 398
end
inherited ToolBar1: TToolBar
Width = 825
@ -290,10 +296,10 @@ inherited fEditorProveedor: TfEditorProveedor
end
end
end
object pagDatosComerciales: TTabSheet
object pagDatosComerciales: TTabSheet [2]
Caption = 'Datos comerciales'
ImageIndex = 2
ExplicitHeight = 536
ExplicitHeight = 423
inline frViewProveedorDatosComerciales1: TfrViewProveedorDatosComerciales
Left = 0
Top = 0
@ -363,15 +369,15 @@ inherited fEditorProveedor: TfEditorProveedor
end
end
end
object pagDirecciones: TTabSheet
object pagDirecciones: TTabSheet [3]
Caption = 'Direcciones'
ImageIndex = 3
ExplicitHeight = 536
ExplicitHeight = 423
inline frViewDireccionesEntrega1: TfrViewDireccionesEntrega
Left = 0
Top = 0
Width = 825
Height = 423
Height = 488
Align = alClient
Font.Charset = DEFAULT_CHARSET
Font.Color = clWindowText
@ -382,12 +388,12 @@ inherited fEditorProveedor: TfEditorProveedor
TabOrder = 0
ReadOnly = False
ExplicitWidth = 825
ExplicitHeight = 536
ExplicitHeight = 423
inherited cxGrid: TcxGrid
Width = 825
Height = 398
Height = 463
ExplicitWidth = 825
ExplicitHeight = 511
ExplicitHeight = 398
end
inherited ToolBar1: TToolBar
Width = 825
@ -407,11 +413,31 @@ inherited fEditorProveedor: TfEditorProveedor
end
end
end
inherited pagPersonal: TTabSheet
ExplicitWidth = 825
ExplicitHeight = 423
inherited frViewPersonalContacto1: TfrViewPersonalContacto
Width = 825
Height = 488
ExplicitWidth = 825
ExplicitHeight = 423
inherited cxGrid: TcxGrid
Width = 825
Height = 463
ExplicitWidth = 825
ExplicitHeight = 398
end
inherited ToolBar1: TToolBar
Width = 825
ExplicitWidth = 825
end
end
end
end
inherited StatusBar: TJvStatusBar
Top = 533
Top = 598
Width = 839
ExplicitTop = 646
ExplicitTop = 533
ExplicitWidth = 839
end
inherited EditorActionList: TActionList

View File

@ -14,7 +14,7 @@ uses
cxSpinEdit, cxDBEdit, pngimage, TBXStatusBars, JvExComCtrls, JvStatusBar,
dxLayoutLookAndFeels, uViewContactoDatosBancarios, uBizContactos,
uViewProveedorDatosComerciales, uViewDetallesGenerico, uViewDireccionesEntrega,
uDAInterfaces, uViewContactoListaDatosBancarios;
uDAInterfaces, uViewContactoListaDatosBancarios, uViewPersonalContacto;
type
TfEditorProveedor = class(TfEditorContacto, IEditorProveedor)

View File

@ -166,25 +166,40 @@ inherited frViewDatosYSeleccionCliente: TfrViewDatosYSeleccionCliente
Caption = 'Elegir un cliente'
TabOrder = 0
Glyph.Data = {
42020000424D4202000000000000420000002800000010000000100000000100
1000030000000002000000000000000000000000000000000000007C0000E003
00001F0000001F7C1F7C1F7C1D74186055547450735054505554365C19641D74
1F7C1F7C1F7C1F7C1F7C9658AA21091A281A481668164816481A091AC9190B29
1A681F7C1F7C1F7C1F7C8C25091A481A68168716A71687166716481A091ACA1D
744C1F7C1F7C1F7C1F7CAB25291A6816A716C616E512C612A6166816291AEA19
56581F7C1F7C1F7C1F7C3241291A6716A616C61A2F3FE516C6168716481AAA25
1D741F7C1F7C1F7C1F7C3E78CB296716C616B0425A6BF042C6168716091E7860
1F7C1F7C1F7C1F7C1F7C1F7C3D748F39461E2B56295E0952C51DAC2D5A681F7C
1F7C1F7C1F7C1F7C1F7C1F7C1F7C3D782C6A8A6E8A6A696A296253541F7C1F7C
1F7C1F7C1F7C1F7C1F7C1F7C1F7C916DAB6EAB6E8B6E8A6E6A6A6A551D741F7C
1F7C1F7C1F7C1F7C1F7C1F7C3D788C6ECC72CC72AC72AB6E8A6E496618601F7C
1F7C1F7C1F7C1F7C1F7C1F7CD874CC72CD76CD76CC72AC728B6E6A6A555C1F7C
1F7C1F7C1F7C1F7C1F7C1F7CF770295A09564B5ECD72CC72AB6E8A6A75601F7C
1F7C1F7C1F7C1F7C1F7C1F7C99746A626A62495EE8514A5E6A62E75137601F7C
1F7C1F7C1F7C1F7C1F7C1F7C1F7C4D6AAC6E8B6A6A620856E7556A511E781F7C
1F7C1F7C1F7C1F7C1F7C1F7C1F7C1875EE76CD728B66495EE85558681F7C1F7C
1F7C1F7C1F7C1F7C1F7C1F7C1F7C1F7CF978306E2C668F615A701F7C1F7C1F7C
1F7C1F7C1F7C}
36040000424D3604000000000000360000002800000010000000100000000100
2000000000000004000000000000000000000000000000000000FF00FF00FF00
FF00FF00FF00EB00EB00C507C600AB13AD00A119A2009F19A000A215A400AA10
AC00B608B800CE00CE00EF00EF00FF00FF00FF00FF00FF00FF00FF00FF00FF00
FF00B426B000526840004A823400478F310043962F0042992F0043972F004690
3100488533004B7237005A405100D201D200FF00FF00FF00FF00FF00FF00FF00
FF0062654E004F81350047903100409C2E003AA62C0038AA2B0039A72B003E9E
2D00459230004D84340056753800A0189F00FF00FF00FF00FF00FF00FF00FF00
FF005F6B4C004B89330042992F0039A82B0032B428002EBB260031B6270037AB
2A00409C2E00498C3200527B3600B015B100FF00FF00FF00FF00FF00FF00FF00
FF0090488700488D32003E9E2D0035AF290035B631007ACB7B002DBF280033B2
28003DA12D0047903100576A4800EC01EC00FF00FF00FF00FF00FF00FF00FF00
FF00F008F1005F7351003E9F2D0034B0290080AC8100D2D3D30081BB820032B2
28003DA22D004A863A00C519C500FF00FF00FF00FF00FF00FF00FF00FF00FF00
FF00FF00FF00EE09EF007861730036923E00598CAE00498CBB004A81A6002B70
3A00606D5900D613D600FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00
FF00FF00FF00FF00FF00EA0CF400608CD00054A2D80053A1D6004F9DD300488B
C2009D11AC00FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00
FF00FF00FF00FF00FF008C67DE005CA9DD005CA9DD005AA7DC0056A4D900519F
D400565FAB00EA00EA00FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00
FF00FF00FF00EC0DF60060A7DE0063B0E30063B0E30061AEE1005CA9DD0056A4
D9004E94CC00C105C600FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00
FF00FF00FF00C532ED0066B2E5006BB7E9006BB7E90067B3E60061AEE1005AA7
DC00539FD500A817BE00FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00
FF00FF00FF00BA3AE7004989B1004A85AC005895BD0068B2E30064B0E4005CA9
DE0053A0D400AA1BC300FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00
FF00FF00FF00CA23E8005098C400539AC7004E93BE00437DA2005190BA005198
C6003C79A000BE08C300FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00
FF00FF00FF00F804FC006995D40062ACDA005DA6D3005299C6004284AD003C7F
A900535AA100F300F300FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00
FF00FF00FF00FF00FF00C140ED0071BAEA0068B2E00059A1CF004990BC004378
AA00C315D600FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00
FF00FF00FF00FF00FF00FF00FF00C83EF000808BDF00668BCC007C60C700D116
E400FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00}
end
object Button2: TBitBtn
Left = 131
@ -195,25 +210,40 @@ inherited frViewDatosYSeleccionCliente: TfrViewDatosYSeleccionCliente
Caption = 'Dar de alta un cliente'
TabOrder = 1
Glyph.Data = {
42020000424D4202000000000000420000002800000010000000100000000100
1000030000000002000000000000000000000000000000000000007C0000E003
00001F0000001F7C1F7C1F7C1F7C1F7C1F7C1F7C1F7C1F7C1F7C1F7C1F7C1F7C
1F7C1F7C1F7CFA5A0D190D190D190D190D190D190D190D190D190D190D190D19
0D190D190D19FA5ADE77964A964A964A964A964A964A964A964A964A964A964A
964A964A0D19FA5A050EA205A205A205A205A205A205050E5C675C673B633B63
3B5F964A0D19FA5AAB2A281687168612861267162816A2057C6BD42DD42DD42D
D42D964A0D19FA5AF03E48168612661A661A86124716A2059D6F7C6B5C6B5C67
3B63964A0D19FA5AB96789224516AE4A8D46461AA205BD739D6FD42DD42DD42D
D42D964A0D19FA5AFF7F776369526A66496229461557BE77BD739D6F9D6F7C6B
5C6B964A0D19FA5AFF7F3477AB6EAB6E8A6E6A66F466DE77BE77BD739D6F9D6F
7C6B964A0D19FA5ADD7FED6ECC72CC72AB6E8A6A6D5EDE7BDE77BE7780018001
8001964A0D19FA5ADD7FCB6A8B6AAC6EAC728B6E0652FF7BDE7B9E3A8001262B
8001964A0D19FA5AFE7F0F6F8A666A666A66285E0652FF7F8001800180016833
800180018001FA5AFF7FB97BCC6E8B6A495E06527873FF7F8001EC4FCB47893F
6833472F8001FA5AFF7FFF7FB97B34773477B97BFF7FFF7F800180018001CB47
800180018001FA5AFA5AFA5AFA5AFA5AFA5AFA5AFA5AFA5AFA5AFA5A8001EC4F
8001FA5AFA5A1F7C1F7C1F7C1F7C1F7C1F7C1F7C1F7C1F7C1F7C1F7C80018001
80011F7C1F7C}
36040000424D3604000000000000360000002800000010000000100000000100
2000000000000004000000000000000000000000000000000000FF00FF00FF00
FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00
FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00D5BFB1006947
3100694731006947310069473100694731006947310069473100694731006947
3100694731006947310069473100694731006947310069473100D5BFB100F6F2
EF00B7A29300B7A29300B7A29300B7A29300B7A29300B7A29300B7A29300B7A2
9300B7A29300B7A29300B7A29300B7A29300B7A2930069473100D5BFB1002A80
1E00136F0D00136F0D00136F0D00136F0D00136F0D00136F0D002A801E00E3D5
CE00E0D1C900DFCFC600DCCBC100DBC9BF00B7A2930069473100D5BFB10059A8
5100448B2F003CA02C0032A4260032A526003D9E2C00438D2E00136F0D00E7DB
D500A1745C00A1745C00A1745C00A1745C00B7A2930069473100D5BFB10080BC
790042952E0031A62600369B3200369E320032A727003E952C00136F0D00EAE0
DA00E7DBD500E4D7D000E2D3CB00DFCFC600B7A2930069473100D5BFB100CFE8
CD004CA741002D942F0071AB90006FA68E0030923100136F0D00EFE8E300EDE4
DF00A1745C00A1745C00A1745C00A1745C00B7A2930069473100D5BFB100FFFF
FF00B9DDC2004F9DA000559BC8004E96C2004E8E8F00A8C2AA00F2ECE800EFE8
E300EDE4DF00EAE0DA00E7DBD500E4D7D000B7A2930069473100D5BFB100FFFF
FF00A5CDE8005DAADD005CA9DD0057A4D900519ACC00A0BACA00F5F0ED00F2EC
E800EFE8E300EDE4DF00EAE0DA00E7DBD500B7A2930069473100D5BFB100ECF6
FA006CB9DF0065B2E50065B1E5005FACDF0056A2D700689EBE00F7F4F100F5F0
ED00F2ECE800006000000060000000600000B7A2930069473100D5BFB100E9F6
FA005BB0D5005CA6D50065AFDF0062AFE20058A4D8003285A700FAF8F600F7F4
F100F7A073000060000033CB510000600000B7A2930069473100D5BFB100F4FA
FC0078C0DD0056A0CD00569DCA00539CCA00448DBB003285A700FDFCFB000060
0000006000000060000040D86500006000000060000000600000D5BFB100FFFF
FF00CEEAF40062B5DE005DA7D5004B92BE003285A700C6DCE600FFFFFF000060
000060F898005AF28F004DE57A0040D865003AD25C0000600000D5BFB100FFFF
FF00FFFFFF00CEEAF400A5CDE800A5CDE800CEEAF400FFFFFF00FFFFFF000060
000000600000006000005AF28F00006000000060000000600000D5BFB100D5BF
B100D5BFB100D5BFB100D5BFB100D5BFB100D5BFB100D5BFB100D5BFB100D5BF
B100D5BFB1000060000060F8980000600000D5BFB100D5BFB100FF00FF00FF00
FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00
FF00FF00FF00006000000060000000600000FF00FF00FF00FF00}
end
object Button3: TBitBtn
Left = 148
@ -224,25 +254,40 @@ inherited frViewDatosYSeleccionCliente: TfrViewDatosYSeleccionCliente
Caption = 'Ver ficha completa del cliente...'
TabOrder = 8
Glyph.Data = {
42020000424D4202000000000000420000002800000010000000100000000100
1000030000000002000000000000000000000000000000000000007C0000E003
00001F0000001F7C1F7C1F7C1F7C1F7C1F7C1F7C1F7C1F7C1F7C1F7C1F7C1F7C
1F7C1F7C1F7CFA5A0D190D190D190D190D190D190D190D190D190D190D190D19
0D190D190D19FA5ADE77964A964A964A964A964A964A964A964A964A964A964A
964A964A0D19FA5A050EA205A205A205A205A205A205050E5C675C673B633B63
3B5F964A0D19FA5AAB2A281687168612861267162816A2057C6BD42DD42DD42D
D42D964A0D19FA5AF03E48168612661A661A86124716A2059D6F7C6B5C6B5C67
3B63964A0D19FA5AB96789224516AE4A8D46461AA205BD739D6FD42DD42DD42D
D42D964A0D19FA5AFF7F776369526A66496229461557BE77BD739D6F9D6F7C6B
5C6B964A0D19FA5AFF7F3477AB6EAB6E8A6E6A66F466DE77BE77BD739D6F9D6F
7C6B964A0D19FA5ADD7FED6ECC72CC72AB6E8A6A6D5EDE7BDE77BE77BD739D6F
9D6F964A0D19FA5ADD7FCB6A8B6AAC6EAC728B6E0652FF7BDE7B9E3A9E3A9E3A
9E3A964A0D19FA5AFE7F0F6F8A666A666A66285E0652FF7FFF7BDE7BDE77BE77
BD73964A0D19FA5AFF7FB97BCC6E8B6A495E06527873FF7FFF7F9E3A9E3A9E3A
9E3A964A0D19FA5AFF7FFF7FB97B34773477B97BFF7FFF7FFF7FFF7FFF7FDF7B
DE77BE770D19FA5AFA5AFA5AFA5AFA5AFA5AFA5AFA5AFA5AFA5AFA5AFA5AFA5A
FA5AFA5AFA5A1F7C1F7C1F7C1F7C1F7C1F7C1F7C1F7C1F7C1F7C1F7C1F7C1F7C
1F7C1F7C1F7C}
36040000424D3604000000000000360000002800000010000000100000000100
2000000000000004000000000000000000000000000000000000FF00FF00FF00
FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00
FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00D5BFB1006947
3100694731006947310069473100694731006947310069473100694731006947
3100694731006947310069473100694731006947310069473100D5BFB100F6F2
EF00B7A29300B7A29300B7A29300B7A29300B7A29300B7A29300B7A29300B7A2
9300B7A29300B7A29300B7A29300B7A29300B7A2930069473100D5BFB1002A80
1E00136F0D00136F0D00136F0D00136F0D00136F0D00136F0D002A801E00E3D5
CE00E0D1C900DFCFC600DCCBC100DBC9BF00B7A2930069473100D5BFB10059A8
5100448B2F003CA02C0032A4260032A526003D9E2C00438D2E00136F0D00E7DB
D500A1745C00A1745C00A1745C00A1745C00B7A2930069473100D5BFB10080BC
790042952E0031A62600369B3200369E320032A727003E952C00136F0D00EAE0
DA00E7DBD500E4D7D000E2D3CB00DFCFC600B7A2930069473100D5BFB100CFE8
CD004CA741002D942F0071AB90006FA68E0030923100136F0D00EFE8E300EDE4
DF00A1745C00A1745C00A1745C00A1745C00B7A2930069473100D5BFB100FFFF
FF00B9DDC2004F9DA000559BC8004E96C2004E8E8F00A8C2AA00F2ECE800EFE8
E300EDE4DF00EAE0DA00E7DBD500E4D7D000B7A2930069473100D5BFB100FFFF
FF00A5CDE8005DAADD005CA9DD0057A4D900519ACC00A0BACA00F5F0ED00F2EC
E800EFE8E300EDE4DF00EAE0DA00E7DBD500B7A2930069473100D5BFB100ECF6
FA006CB9DF0065B2E50065B1E5005FACDF0056A2D700689EBE00F7F4F100F5F0
ED00F2ECE800EFE8E300EDE4DF00EAE0DA00B7A2930069473100D5BFB100E9F6
FA005BB0D5005CA6D50065AFDF0062AFE20058A4D8003285A700FAF8F600F7F4
F100F7A07300F7A07300F7A07300F7A07300B7A2930069473100D5BFB100F4FA
FC0078C0DD0056A0CD00569DCA00539CCA00448DBB003285A700FDFCFB00FAF8
F600F7F4F100F5F0ED00F2ECE800EFE8E300B7A2930069473100D5BFB100FFFF
FF00CEEAF40062B5DE005DA7D5004B92BE003285A700C6DCE600FFFFFF00FDFC
FB00F7A07300F7A07300F7A07300F7A07300B7A2930069473100D5BFB100FFFF
FF00FFFFFF00CEEAF400A5CDE800A5CDE800CEEAF400FFFFFF00FFFFFF00FFFF
FF00FEFEFD00FCFAF900F9F6F400F6F2EF00F3EEEA0069473100D5BFB100D5BF
B100D5BFB100D5BFB100D5BFB100D5BFB100D5BFB100D5BFB100D5BFB100D5BF
B100D5BFB100D5BFB100D5BFB100D5BFB100D5BFB100D5BFB100FF00FF00FF00
FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00
FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00}
end
object dxLayoutControl1Group_Root: TdxLayoutGroup
ShowCaption = False

View File

@ -22,6 +22,10 @@ type
procedure SetProveedor(Value: IBizProveedor);
property Proveedor: IBizProveedor read GetProveedor write SetProveedor;
function GetID_Proveedor: integer;
procedure SetID_Proveedor(const Value: integer);
property ID_Proveedor: integer read GetID_Proveedor write SetID_Proveedor;
function GetOnProveedorChanged : TNotifyEvent;
procedure SetOnProveedorChanged (const Value : TNotifyEvent);
property OnProveedorChanged : TNotifyEvent read GetOnProveedorChanged
@ -81,12 +85,19 @@ type
function GetMsgElegirProveedor: String;
procedure SetMsgElegirProveedor(const Value: String);
procedure SetReadOnly(Value: Boolean); override;
function GetID_Proveedor: integer;
procedure SetID_Proveedor(const Value: integer);
procedure ElegirProveedorInternal; virtual;
procedure VerFichaProveedorInternal; virtual;
procedure NuevoProveedorInternal; virtual;
public
constructor Create(AOwner: TComponent); override;
destructor Destroy; override;
property MsgElegirProveedor : String read GetMsgElegirProveedor write SetMsgElegirProveedor;
property Controller: IProveedoresController read GetController write SetController;
property Proveedor: IBizProveedor read GetProveedor write SetProveedor;
property ID_Proveedor: integer read GetID_Proveedor write SetID_Proveedor;
property OnProveedorChanged : TNotifyEvent read GetOnProveedorChanged write SetOnProveedorChanged;
end;
@ -98,6 +109,44 @@ uses
uDataModuleProveedores, Math;
procedure TfrViewDatosYSeleccionProveedor.actElegirContactoExecute(Sender: TObject);
begin
inherited;
ElegirProveedorInternal;
end;
procedure TfrViewDatosYSeleccionProveedor.actAnadirContactoExecute(
Sender: TObject);
begin
inherited;
NuevoProveedorInternal
end;
procedure TfrViewDatosYSeleccionProveedor.actVerContactoExecute(Sender: TObject);
begin
inherited;
VerFichaProveedorInternal;
end;
procedure TfrViewDatosYSeleccionProveedor.actVerContactoUpdate(Sender: TObject);
begin
inherited;
(Sender as TAction).Enabled := (Length(edtlNombre.Text) > 0);
end;
constructor TfrViewDatosYSeleccionProveedor.Create(AOwner: TComponent);
begin
inherited;
FMsgElegirProveedor := '';
FController := NIL;
end;
destructor TfrViewDatosYSeleccionProveedor.Destroy;
begin
FController := NIL;
inherited;
end;
procedure TfrViewDatosYSeleccionProveedor.ElegirProveedorInternal;
var
AProveedor : IBizProveedor;
begin
@ -117,45 +166,35 @@ begin
end;
end;
procedure TfrViewDatosYSeleccionProveedor.actAnadirContactoExecute(
Sender: TObject);
var
AProveedor : IBizProveedor;
begin
inherited;
AProveedor := (FController.Nuevo as IBizProveedor);
FController.Ver(AProveedor);
Proveedor := AProveedor;
end;
procedure TfrViewDatosYSeleccionProveedor.actVerContactoExecute(Sender: TObject);
begin
inherited;
FController.Ver(Proveedor);
end;
procedure TfrViewDatosYSeleccionProveedor.actVerContactoUpdate(Sender: TObject);
begin
inherited;
(Sender as TAction).Enabled := (Length(edtlNombre.Text) > 0);
end;
constructor TfrViewDatosYSeleccionProveedor.Create(AOwner: TComponent);
begin
inherited;
FMsgElegirProveedor := '';
end;
function TfrViewDatosYSeleccionProveedor.GetProveedor: IBizProveedor;
begin
Result := FProveedor;
end;
procedure TfrViewDatosYSeleccionProveedor.NuevoProveedorInternal;
var
AProveedor : IBizProveedor;
begin
inherited;
AProveedor := (Controller.Nuevo as IBizProveedor);
Controller.Ver(AProveedor);
Proveedor := AProveedor;
end;
function TfrViewDatosYSeleccionProveedor.GetController: IProveedoresController;
begin
if not Assigned(FController) then
FController := TProveedoresController.Create;
Result := FController;
end;
function TfrViewDatosYSeleccionProveedor.GetID_Proveedor: integer;
begin
Result := -1;
if Assigned(FProveedor) then
Result := FProveedor.ID;
end;
function TfrViewDatosYSeleccionProveedor.GetMsgElegirProveedor: String;
begin
Result := FMsgElegirProveedor;
@ -188,11 +227,24 @@ begin
end;
end;
procedure TfrViewDatosYSeleccionProveedor.VerFichaProveedorInternal;
begin
Controller.Ver(Proveedor);
end;
procedure TfrViewDatosYSeleccionProveedor.SetController(Value: IProveedoresController);
begin
if Assigned(FController) then
FController := NIL;
FController := Value;
end;
procedure TfrViewDatosYSeleccionProveedor.SetID_Proveedor(const Value: integer);
begin
Self.Proveedor := IBizProveedor(Controller.Buscar(Value));
end;
procedure TfrViewDatosYSeleccionProveedor.SetMsgElegirProveedor(
const Value: String);
begin

View File

@ -0,0 +1,88 @@
inherited frViewPersonalContacto: TfrViewPersonalContacto
Width = 583
Height = 464
ExplicitWidth = 583
ExplicitHeight = 464
inherited cxGrid: TcxGrid
Width = 583
Height = 439
ExplicitWidth = 583
ExplicitHeight = 439
inherited cxGridView: TcxGridDBTableView
OnDblClick = cxGridViewDblClick
OptionsData.Appending = False
OptionsData.Deleting = False
OptionsData.DeletingConfirmation = False
OptionsData.Editing = False
OptionsData.Inserting = False
object cxGridViewNOMBRE: TcxGridDBColumn
Caption = 'Nombre'
DataBinding.FieldName = 'NOMBRE'
PropertiesClassName = 'TcxTextEditProperties'
Width = 88
end
object cxGridViewPUESTO: TcxGridDBColumn
Caption = 'Puesto'
DataBinding.FieldName = 'PUESTO'
PropertiesClassName = 'TcxTextEditProperties'
Width = 128
end
object cxGridViewTELEFONO: TcxGridDBColumn
Caption = 'Tel'#233'fono'
DataBinding.FieldName = 'TELEFONO'
PropertiesClassName = 'TcxTextEditProperties'
Width = 54
end
object cxGridViewMOVIL: TcxGridDBColumn
Caption = 'M'#243'vil'
DataBinding.FieldName = 'MOVIL'
PropertiesClassName = 'TcxTextEditProperties'
Width = 54
end
object cxGridViewFAX: TcxGridDBColumn
Caption = 'Fax'
DataBinding.FieldName = 'FAX'
PropertiesClassName = 'TcxTextEditProperties'
Width = 54
end
object cxGridViewEMAIL: TcxGridDBColumn
Caption = 'E-Mail'
DataBinding.FieldName = 'EMAIL'
PropertiesClassName = 'TcxTextEditProperties'
Width = 50
end
end
end
inherited ToolBar1: TToolBar
Width = 583
ExplicitWidth = 583
inherited ToolButton1: TToolButton
Top = 0
ExplicitTop = 0
ExplicitWidth = 62
end
inherited ToolButton4: TToolButton
Top = 0
ExplicitTop = 0
ExplicitWidth = 74
end
inherited ToolButton5: TToolButton
Top = 0
ExplicitTop = 0
end
inherited ToolButton2: TToolButton
Top = 0
ExplicitTop = 0
ExplicitWidth = 67
end
inherited ToolButton6: TToolButton
Top = 0
ExplicitTop = 0
end
inherited ToolButton7: TToolButton
Top = 0
ExplicitTop = 0
ExplicitWidth = 117
end
end
end

View File

@ -0,0 +1,73 @@
unit uViewPersonalContacto;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, uViewBase, cxStyles, cxCustomData, cxGraphics, cxFilter, cxData,
cxDataStorage, cxEdit, DB, cxDBData, cxTextEdit, cxGridLevel,
cxGridCustomTableView, cxGridTableView, cxGridBandedTableView,
cxGridDBBandedTableView, cxClasses, cxControls, cxGridCustomView, cxGrid,
uDADataTable, Grids, DBGrids, ActnList, ImgList, PngImageList, ComCtrls,
ToolWin, cxGridDBTableView, uViewDetallesGenerico,
uDAInterfaces, StdCtrls;
type
TfrViewPersonalContacto = class(TfrViewDetallesGenerico)
cxGridViewNOMBRE: TcxGridDBColumn;
cxGridViewPUESTO: TcxGridDBColumn;
cxGridViewTELEFONO: TcxGridDBColumn;
cxGridViewMOVIL: TcxGridDBColumn;
cxGridViewFAX: TcxGridDBColumn;
cxGridViewEMAIL: TcxGridDBColumn;
procedure cxGridViewDblClick(Sender: TObject);
procedure actEliminarExecute(Sender: TObject);
protected
procedure AnadirInterno; override;
procedure ModificarInterno; override;
public
{ Public declarations }
end;
implementation
{$R *.dfm}
uses
uDialogUtils, uPersonalContactoController, uBizContactosPersonal;
procedure TfrViewPersonalContacto.actEliminarExecute(Sender: TObject);
begin
if (ShowConfirmMessage('Eliminar un contacto de personal', '¿Desea eliminar este contacto de personal?') = IDYES) then
inherited;
end;
procedure TfrViewPersonalContacto.AnadirInterno;
begin
inherited;
try
with TPersonalContactoController.Create do
Ver((dsDetalles.DataTable) as IBizContactoPersonal);
finally
if (dsDetalles.DataTable.State in dsEditModes) then
dsDetalles.DataTable.Post;
end;
end;
procedure TfrViewPersonalContacto.cxGridViewDblClick(Sender: TObject);
begin
inherited;
actModificar.Execute;
end;
procedure TfrViewPersonalContacto.ModificarInterno;
begin
inherited;
with TPersonalContactoController.Create do
Ver((dsDetalles.DataTable) as IBizContactoPersonal);
end;
end.

View File

@ -23,7 +23,7 @@ inherited frViewProveedor: TfrViewProveedor
ExplicitLeft = 738
end
object Label1: TLabel [3]
Left = 438
Left = 446
Top = 307
Width = 342
Height = 26
@ -35,7 +35,7 @@ inherited frViewProveedor: TfrViewProveedor
inherited eCalle: TcxDBTextEdit
Left = 134
Top = 277
TabOrder = 8
TabOrder = 9
ExplicitLeft = 134
ExplicitTop = 277
ExplicitWidth = 264
@ -44,7 +44,7 @@ inherited frViewProveedor: TfrViewProveedor
inherited eProvincia: TcxDBTextEdit
Left = 134
Top = 331
TabOrder = 11
TabOrder = 12
ExplicitLeft = 134
ExplicitTop = 331
ExplicitWidth = 264
@ -53,28 +53,28 @@ inherited frViewProveedor: TfrViewProveedor
inherited ePoblacion: TcxDBTextEdit
Left = 134
Top = 304
TabOrder = 9
TabOrder = 10
ExplicitLeft = 134
ExplicitTop = 304
ExplicitWidth = 163
Width = 163
end
inherited eCodigoPostal: TcxDBTextEdit
Left = 343
Left = 351
Top = 304
TabOrder = 10
ExplicitLeft = 343
TabOrder = 11
ExplicitLeft = 351
ExplicitTop = 304
end
inherited eObservaciones: TcxDBMemo
Top = 415
TabOrder = 21
TabOrder = 22
ExplicitTop = 415
ExplicitHeight = 20
Height = 20
end
object cxDBCheckBox1: TcxDBCheckBox [9]
Left = 438
Left = 446
Top = 280
Caption = 'Incluir este proveedor en la tienda web'
DataBinding.DataField = 'TIENDA_WEB'
@ -95,8 +95,8 @@ inherited frViewProveedor: TfrViewProveedor
StyleFocused.LookAndFeel.NativeStyle = True
StyleHot.LookAndFeel.Kind = lfStandard
StyleHot.LookAndFeel.NativeStyle = True
TabOrder = 20
Width = 310
TabOrder = 21
Width = 236
end
object cxDBCheckBox2: TcxDBCheckBox [10]
Left = 22
@ -119,7 +119,7 @@ inherited frViewProveedor: TfrViewProveedor
StyleFocused.LookAndFeel.NativeStyle = True
StyleHot.LookAndFeel.Kind = lfStandard
StyleHot.LookAndFeel.NativeStyle = True
TabOrder = 6
TabOrder = 7
Width = 326
end
object eCertificaciones: TcxDBTextEdit [11]
@ -138,7 +138,7 @@ inherited frViewProveedor: TfrViewProveedor
StyleFocused.LookAndFeel.NativeStyle = True
StyleHot.LookAndFeel.Kind = lfStandard
StyleHot.LookAndFeel.NativeStyle = True
TabOrder = 7
TabOrder = 8
Width = 227
end
object cbGrupoProveedor: TcxDBComboBox [12]
@ -207,30 +207,30 @@ inherited frViewProveedor: TfrViewProveedor
Width = 221
end
inherited eTlfParticular: TcxDBTextEdit
Left = 533
TabOrder = 14
ExplicitLeft = 533
Left = 541
TabOrder = 15
ExplicitLeft = 541
ExplicitWidth = 91
Width = 91
end
inherited eTlfTrabajo: TcxDBTextEdit
Left = 533
TabOrder = 13
ExplicitLeft = 533
Left = 541
TabOrder = 14
ExplicitLeft = 541
ExplicitWidth = 127
Width = 127
end
inherited eTlfMovil: TcxDBTextEdit
Left = 533
TabOrder = 15
ExplicitLeft = 533
Left = 541
TabOrder = 16
ExplicitLeft = 541
ExplicitWidth = 155
Width = 155
end
inherited eFax: TcxDBTextEdit
Left = 533
TabOrder = 16
ExplicitLeft = 533
Left = 541
TabOrder = 17
ExplicitLeft = 541
ExplicitWidth = 121
Width = 121
end
@ -241,31 +241,31 @@ inherited frViewProveedor: TfrViewProveedor
Width = 221
end
inherited eNIFCIF: TcxDBTextEdit
Left = 217
ExplicitLeft = 217
Left = 220
ExplicitLeft = 220
ExplicitWidth = 205
Width = 205
end
inherited eMailTrabajo: TcxDBHyperLinkEdit
Left = 533
Left = 541
Properties.Prefix = 'mailto:'
TabOrder = 17
ExplicitLeft = 533
TabOrder = 18
ExplicitLeft = 541
ExplicitWidth = 133
Width = 133
end
inherited eMailParticular: TcxDBHyperLinkEdit
Left = 533
Left = 541
Properties.Prefix = 'mailto:'
TabOrder = 18
ExplicitLeft = 533
TabOrder = 19
ExplicitLeft = 541
ExplicitWidth = 133
Width = 133
end
inherited ePaginaWeb: TcxDBHyperLinkEdit
Left = 533
TabOrder = 19
ExplicitLeft = 533
Left = 541
TabOrder = 20
ExplicitLeft = 541
ExplicitWidth = 133
Width = 133
end
@ -278,12 +278,36 @@ inherited frViewProveedor: TfrViewProveedor
inherited ePersonaContacto: TcxDBTextEdit
Left = 134
Top = 358
TabOrder = 12
TabOrder = 13
ExplicitLeft = 134
ExplicitTop = 358
ExplicitWidth = 256
Width = 256
end
object cxDBCheckBox3: TcxDBCheckBox [26]
Left = 333
Top = 136
Caption = 'Subcontrata'
DataBinding.DataField = 'SUBCONTRATA'
DataBinding.DataSource = dsContacto
Properties.ImmediatePost = True
Properties.NullStyle = nssUnchecked
Properties.ValueChecked = 1
Properties.ValueUnchecked = 0
Style.BorderColor = clWindowFrame
Style.BorderStyle = ebs3D
Style.HotTrack = False
Style.LookAndFeel.Kind = lfStandard
Style.LookAndFeel.NativeStyle = True
StyleDisabled.LookAndFeel.Kind = lfStandard
StyleDisabled.LookAndFeel.NativeStyle = True
StyleFocused.LookAndFeel.Kind = lfStandard
StyleFocused.LookAndFeel.NativeStyle = True
StyleHot.LookAndFeel.Kind = lfStandard
StyleHot.LookAndFeel.NativeStyle = True
TabOrder = 6
Width = 83
end
inherited dxLayoutControlContactoGroup_Root: TdxLayoutGroup
inherited dxLayoutControlContactoGroup9: TdxLayoutGroup
inherited dxLayoutControlContactoGroup4: TdxLayoutGroup
@ -298,10 +322,25 @@ inherited frViewProveedor: TfrViewProveedor
Control = eCodigoAsignado
ControlOptions.ShowBorder = False
end
object dxLayoutControlContactoItem20: TdxLayoutItem
Caption = 'Grupo de proveedor'
Control = cbGrupoProveedor
ControlOptions.ShowBorder = False
object dxLayoutControlContactoGroup15: TdxLayoutGroup
ShowCaption = False
Hidden = True
LayoutDirection = ldHorizontal
ShowBorder = False
object dxLayoutControlContactoItem20: TdxLayoutItem
AutoAligns = [aaVertical]
AlignHorz = ahClient
Caption = 'Grupo de proveedor'
Control = cbGrupoProveedor
ControlOptions.ShowBorder = False
end
object dxLayoutControlContactoItem26: TdxLayoutItem
AutoAligns = [aaVertical]
AlignHorz = ahRight
ShowCaption = False
Control = cxDBCheckBox3
ControlOptions.ShowBorder = False
end
end
end
object dxLayoutControlContactoGroup14: TdxLayoutGroup [1]

View File

@ -32,6 +32,9 @@ type
cbDescripcionProveedor: TcxDBComboBox;
dxLayoutControlContactoItem24: TdxLayoutItem;
eCodigoAsignado: TcxDBTextEdit;
dxLayoutControlContactoItem26: TdxLayoutItem;
cxDBCheckBox3: TcxDBCheckBox;
dxLayoutControlContactoGroup15: TdxLayoutGroup;
procedure CustomViewCreate(Sender: TObject);
procedure CustomViewDestroy(Sender: TObject);
procedure cbGrupoProveedorPropertiesInitPopup(Sender: TObject);

View File

@ -122,6 +122,19 @@ inherited DataModuleObras: TDataModuleObras
ServerAutoRefresh = True
DictionaryEntry = 'Obras_NOMBRE_CLIENTE'
end
item
Name = 'ID_SUBCONTRATA'
DataType = datInteger
DisplayLabel = 'Obras_ID_SUBCONTRATA'
DictionaryEntry = 'Obras_ID_SUBCONTRATA'
end
item
Name = 'NOMBRE_SUBCONTRATA'
DataType = datString
Size = 255
DisplayLabel = 'Subcontrata'
DictionaryEntry = 'Obras_NOMBRE_SUBCONTRATA'
end
item
Name = 'FECHA_ALTA'
DataType = datDateTime

View File

@ -31,6 +31,7 @@ requires
contains
uBizObras in 'uBizObras.pas',
uIDataModuleObras in 'Data\uIDataModuleObras.pas',
schObrasClient_Intf in 'schObrasClient_Intf.pas';
schObrasClient_Intf in 'schObrasClient_Intf.pas',
schObrasServer_Intf in 'schObrasServer_Intf.pas';
end.

View File

@ -42,7 +42,6 @@
<Borland.ProjectType>Package</Borland.ProjectType>
<BorlandProject>
<BorlandProject><Delphi.Personality><Parameters><Parameters Name="UseLauncher">False</Parameters><Parameters Name="LoadAllSymbols">True</Parameters><Parameters Name="LoadUnspecifiedSymbols">False</Parameters></Parameters><Package_Options><Package_Options Name="ImplicitBuild">True</Package_Options><Package_Options Name="DesigntimeOnly">False</Package_Options><Package_Options Name="RuntimeOnly">False</Package_Options></Package_Options><VersionInfo><VersionInfo Name="IncludeVerInfo">True</VersionInfo><VersionInfo Name="AutoIncBuild">False</VersionInfo><VersionInfo Name="MajorVer">1</VersionInfo><VersionInfo Name="MinorVer">0</VersionInfo><VersionInfo Name="Release">0</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.0.0.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.0.0.0</VersionInfoKeys><VersionInfoKeys Name="Comments"></VersionInfoKeys></VersionInfoKeys><Source><Source Name="MainSource">Obras_model.dpk</Source></Source><Excluded_Packages>
<Excluded_Packages Name="$(BDS)\bin\applet100.bpl">CodeGear Control Panel Applet Package</Excluded_Packages>
</Excluded_Packages></Delphi.Personality></BorlandProject></BorlandProject>
</ProjectExtensions>
@ -55,10 +54,10 @@
<DCCReference Include="Base.dcp" />
<DCCReference Include="Data\uIDataModuleObras.pas" />
<DCCReference Include="schObrasClient_Intf.pas" />
<DCCReference Include="schObrasServer_Intf.pas" />
<DCCReference Include="uBizObras.pas" />
</ItemGroup>
</Project>
<!-- EurekaLog First Line
[Exception Log]
EurekaLog Version=6011

View File

@ -9,7 +9,7 @@ const
{ Data table rules ids
Feel free to change them to something more human readable
but make sure they are unique in the context of your application }
RID_Obras = '{1DB0B399-5E0C-4F09-93D6-0774AEAD4B8D}';
RID_Obras = '{CCB7D10C-3660-4703-987A-0EBE16DB0AB8}';
{ Data table names }
nme_Obras = 'Obras';
@ -29,6 +29,8 @@ const
fld_ObrasOBSERVACIONES = 'OBSERVACIONES';
fld_ObrasID_CLIENTE = 'ID_CLIENTE';
fld_ObrasNOMBRE_CLIENTE = 'NOMBRE_CLIENTE';
fld_ObrasID_SUBCONTRATA = 'ID_SUBCONTRATA';
fld_ObrasNOMBRE_SUBCONTRATA = 'NOMBRE_SUBCONTRATA';
fld_ObrasFECHA_ALTA = 'FECHA_ALTA';
fld_ObrasFECHA_MODIFICACION = 'FECHA_MODIFICACION';
fld_ObrasUSUARIO = 'USUARIO';
@ -48,14 +50,16 @@ const
idx_ObrasOBSERVACIONES = 11;
idx_ObrasID_CLIENTE = 12;
idx_ObrasNOMBRE_CLIENTE = 13;
idx_ObrasFECHA_ALTA = 14;
idx_ObrasFECHA_MODIFICACION = 15;
idx_ObrasUSUARIO = 16;
idx_ObrasID_SUBCONTRATA = 14;
idx_ObrasNOMBRE_SUBCONTRATA = 15;
idx_ObrasFECHA_ALTA = 16;
idx_ObrasFECHA_MODIFICACION = 17;
idx_ObrasUSUARIO = 18;
type
{ IObras }
IObras = interface(IDAStronglyTypedDataTable)
['{6CBD823A-08C6-412B-9484-9D7E22FE3939}']
['{AEBE7430-B1DA-45EC-AD12-02499BF04C0C}']
{ Property getters and setters }
function GetIDValue: Integer;
procedure SetIDValue(const aValue: Integer);
@ -112,6 +116,14 @@ type
procedure SetNOMBRE_CLIENTEValue(const aValue: String);
function GetNOMBRE_CLIENTEIsNull: Boolean;
procedure SetNOMBRE_CLIENTEIsNull(const aValue: Boolean);
function GetID_SUBCONTRATAValue: Integer;
procedure SetID_SUBCONTRATAValue(const aValue: Integer);
function GetID_SUBCONTRATAIsNull: Boolean;
procedure SetID_SUBCONTRATAIsNull(const aValue: Boolean);
function GetNOMBRE_SUBCONTRATAValue: String;
procedure SetNOMBRE_SUBCONTRATAValue(const aValue: String);
function GetNOMBRE_SUBCONTRATAIsNull: Boolean;
procedure SetNOMBRE_SUBCONTRATAIsNull(const aValue: Boolean);
function GetFECHA_ALTAValue: DateTime;
procedure SetFECHA_ALTAValue(const aValue: DateTime);
function GetFECHA_ALTAIsNull: Boolean;
@ -155,6 +167,10 @@ type
property ID_CLIENTEIsNull: Boolean read GetID_CLIENTEIsNull write SetID_CLIENTEIsNull;
property NOMBRE_CLIENTE: String read GetNOMBRE_CLIENTEValue write SetNOMBRE_CLIENTEValue;
property NOMBRE_CLIENTEIsNull: Boolean read GetNOMBRE_CLIENTEIsNull write SetNOMBRE_CLIENTEIsNull;
property ID_SUBCONTRATA: Integer read GetID_SUBCONTRATAValue write SetID_SUBCONTRATAValue;
property ID_SUBCONTRATAIsNull: Boolean read GetID_SUBCONTRATAIsNull write SetID_SUBCONTRATAIsNull;
property NOMBRE_SUBCONTRATA: String read GetNOMBRE_SUBCONTRATAValue write SetNOMBRE_SUBCONTRATAValue;
property NOMBRE_SUBCONTRATAIsNull: Boolean read GetNOMBRE_SUBCONTRATAIsNull write SetNOMBRE_SUBCONTRATAIsNull;
property FECHA_ALTA: DateTime read GetFECHA_ALTAValue write SetFECHA_ALTAValue;
property FECHA_ALTAIsNull: Boolean read GetFECHA_ALTAIsNull write SetFECHA_ALTAIsNull;
property FECHA_MODIFICACION: DateTime read GetFECHA_MODIFICACIONValue write SetFECHA_MODIFICACIONValue;
@ -225,6 +241,14 @@ type
procedure SetNOMBRE_CLIENTEValue(const aValue: String); virtual;
function GetNOMBRE_CLIENTEIsNull: Boolean; virtual;
procedure SetNOMBRE_CLIENTEIsNull(const aValue: Boolean); virtual;
function GetID_SUBCONTRATAValue: Integer; virtual;
procedure SetID_SUBCONTRATAValue(const aValue: Integer); virtual;
function GetID_SUBCONTRATAIsNull: Boolean; virtual;
procedure SetID_SUBCONTRATAIsNull(const aValue: Boolean); virtual;
function GetNOMBRE_SUBCONTRATAValue: String; virtual;
procedure SetNOMBRE_SUBCONTRATAValue(const aValue: String); virtual;
function GetNOMBRE_SUBCONTRATAIsNull: Boolean; virtual;
procedure SetNOMBRE_SUBCONTRATAIsNull(const aValue: Boolean); virtual;
function GetFECHA_ALTAValue: DateTime; virtual;
procedure SetFECHA_ALTAValue(const aValue: DateTime); virtual;
function GetFECHA_ALTAIsNull: Boolean; virtual;
@ -267,6 +291,10 @@ type
property ID_CLIENTEIsNull: Boolean read GetID_CLIENTEIsNull write SetID_CLIENTEIsNull;
property NOMBRE_CLIENTE: String read GetNOMBRE_CLIENTEValue write SetNOMBRE_CLIENTEValue;
property NOMBRE_CLIENTEIsNull: Boolean read GetNOMBRE_CLIENTEIsNull write SetNOMBRE_CLIENTEIsNull;
property ID_SUBCONTRATA: Integer read GetID_SUBCONTRATAValue write SetID_SUBCONTRATAValue;
property ID_SUBCONTRATAIsNull: Boolean read GetID_SUBCONTRATAIsNull write SetID_SUBCONTRATAIsNull;
property NOMBRE_SUBCONTRATA: String read GetNOMBRE_SUBCONTRATAValue write SetNOMBRE_SUBCONTRATAValue;
property NOMBRE_SUBCONTRATAIsNull: Boolean read GetNOMBRE_SUBCONTRATAIsNull write SetNOMBRE_SUBCONTRATAIsNull;
property FECHA_ALTA: DateTime read GetFECHA_ALTAValue write SetFECHA_ALTAValue;
property FECHA_ALTAIsNull: Boolean read GetFECHA_ALTAIsNull write SetFECHA_ALTAIsNull;
property FECHA_MODIFICACION: DateTime read GetFECHA_MODIFICACIONValue write SetFECHA_MODIFICACIONValue;
@ -596,6 +624,48 @@ begin
DataTable.Fields[idx_ObrasNOMBRE_CLIENTE].AsVariant := Null;
end;
function TObrasDataTableRules.GetID_SUBCONTRATAValue: Integer;
begin
result := DataTable.Fields[idx_ObrasID_SUBCONTRATA].AsInteger;
end;
procedure TObrasDataTableRules.SetID_SUBCONTRATAValue(const aValue: Integer);
begin
DataTable.Fields[idx_ObrasID_SUBCONTRATA].AsInteger := aValue;
end;
function TObrasDataTableRules.GetID_SUBCONTRATAIsNull: boolean;
begin
result := DataTable.Fields[idx_ObrasID_SUBCONTRATA].IsNull;
end;
procedure TObrasDataTableRules.SetID_SUBCONTRATAIsNull(const aValue: Boolean);
begin
if aValue then
DataTable.Fields[idx_ObrasID_SUBCONTRATA].AsVariant := Null;
end;
function TObrasDataTableRules.GetNOMBRE_SUBCONTRATAValue: String;
begin
result := DataTable.Fields[idx_ObrasNOMBRE_SUBCONTRATA].AsString;
end;
procedure TObrasDataTableRules.SetNOMBRE_SUBCONTRATAValue(const aValue: String);
begin
DataTable.Fields[idx_ObrasNOMBRE_SUBCONTRATA].AsString := aValue;
end;
function TObrasDataTableRules.GetNOMBRE_SUBCONTRATAIsNull: boolean;
begin
result := DataTable.Fields[idx_ObrasNOMBRE_SUBCONTRATA].IsNull;
end;
procedure TObrasDataTableRules.SetNOMBRE_SUBCONTRATAIsNull(const aValue: Boolean);
begin
if aValue then
DataTable.Fields[idx_ObrasNOMBRE_SUBCONTRATA].AsVariant := Null;
end;
function TObrasDataTableRules.GetFECHA_ALTAValue: DateTime;
begin
result := DataTable.Fields[idx_ObrasFECHA_ALTA].AsDateTime;

View File

@ -9,12 +9,12 @@ const
{ Delta rules ids
Feel free to change them to something more human readable
but make sure they are unique in the context of your application }
RID_ObrasDelta = '{F492DD9C-B7CF-4C27-8901-850D71F32744}';
RID_ObrasDelta = '{F9AE7533-AB09-4DE5-BAC9-97D14691072A}';
type
{ IObrasDelta }
IObrasDelta = interface(IObras)
['{F492DD9C-B7CF-4C27-8901-850D71F32744}']
['{F9AE7533-AB09-4DE5-BAC9-97D14691072A}']
{ Property getters and setters }
function GetOldIDValue : Integer;
function GetOldID_EMPRESAValue : Integer;
@ -30,6 +30,8 @@ type
function GetOldOBSERVACIONESValue : IROStrings;
function GetOldID_CLIENTEValue : Integer;
function GetOldNOMBRE_CLIENTEValue : String;
function GetOldID_SUBCONTRATAValue : Integer;
function GetOldNOMBRE_SUBCONTRATAValue : String;
function GetOldFECHA_ALTAValue : DateTime;
function GetOldFECHA_MODIFICACIONValue : DateTime;
function GetOldUSUARIOValue : String;
@ -49,6 +51,8 @@ type
property OldOBSERVACIONES : IROStrings read GetOldOBSERVACIONESValue;
property OldID_CLIENTE : Integer read GetOldID_CLIENTEValue;
property OldNOMBRE_CLIENTE : String read GetOldNOMBRE_CLIENTEValue;
property OldID_SUBCONTRATA : Integer read GetOldID_SUBCONTRATAValue;
property OldNOMBRE_SUBCONTRATA : String read GetOldNOMBRE_SUBCONTRATAValue;
property OldFECHA_ALTA : DateTime read GetOldFECHA_ALTAValue;
property OldFECHA_MODIFICACION : DateTime read GetOldFECHA_MODIFICACIONValue;
property OldUSUARIO : String read GetOldUSUARIOValue;
@ -144,6 +148,18 @@ type
function GetOldNOMBRE_CLIENTEIsNull: Boolean; virtual;
procedure SetNOMBRE_CLIENTEValue(const aValue: String); virtual;
procedure SetNOMBRE_CLIENTEIsNull(const aValue: Boolean); virtual;
function GetID_SUBCONTRATAValue: Integer; virtual;
function GetID_SUBCONTRATAIsNull: Boolean; virtual;
function GetOldID_SUBCONTRATAValue: Integer; virtual;
function GetOldID_SUBCONTRATAIsNull: Boolean; virtual;
procedure SetID_SUBCONTRATAValue(const aValue: Integer); virtual;
procedure SetID_SUBCONTRATAIsNull(const aValue: Boolean); virtual;
function GetNOMBRE_SUBCONTRATAValue: String; virtual;
function GetNOMBRE_SUBCONTRATAIsNull: Boolean; virtual;
function GetOldNOMBRE_SUBCONTRATAValue: String; virtual;
function GetOldNOMBRE_SUBCONTRATAIsNull: Boolean; virtual;
procedure SetNOMBRE_SUBCONTRATAValue(const aValue: String); virtual;
procedure SetNOMBRE_SUBCONTRATAIsNull(const aValue: Boolean); virtual;
function GetFECHA_ALTAValue: DateTime; virtual;
function GetFECHA_ALTAIsNull: Boolean; virtual;
function GetOldFECHA_ALTAValue: DateTime; virtual;
@ -220,6 +236,14 @@ type
property NOMBRE_CLIENTEIsNull : Boolean read GetNOMBRE_CLIENTEIsNull write SetNOMBRE_CLIENTEIsNull;
property OldNOMBRE_CLIENTE : String read GetOldNOMBRE_CLIENTEValue;
property OldNOMBRE_CLIENTEIsNull : Boolean read GetOldNOMBRE_CLIENTEIsNull;
property ID_SUBCONTRATA : Integer read GetID_SUBCONTRATAValue write SetID_SUBCONTRATAValue;
property ID_SUBCONTRATAIsNull : Boolean read GetID_SUBCONTRATAIsNull write SetID_SUBCONTRATAIsNull;
property OldID_SUBCONTRATA : Integer read GetOldID_SUBCONTRATAValue;
property OldID_SUBCONTRATAIsNull : Boolean read GetOldID_SUBCONTRATAIsNull;
property NOMBRE_SUBCONTRATA : String read GetNOMBRE_SUBCONTRATAValue write SetNOMBRE_SUBCONTRATAValue;
property NOMBRE_SUBCONTRATAIsNull : Boolean read GetNOMBRE_SUBCONTRATAIsNull write SetNOMBRE_SUBCONTRATAIsNull;
property OldNOMBRE_SUBCONTRATA : String read GetOldNOMBRE_SUBCONTRATAValue;
property OldNOMBRE_SUBCONTRATAIsNull : Boolean read GetOldNOMBRE_SUBCONTRATAIsNull;
property FECHA_ALTA : DateTime read GetFECHA_ALTAValue write SetFECHA_ALTAValue;
property FECHA_ALTAIsNull : Boolean read GetFECHA_ALTAIsNull write SetFECHA_ALTAIsNull;
property OldFECHA_ALTA : DateTime read GetOldFECHA_ALTAValue;
@ -697,6 +721,68 @@ begin
BusinessProcessor.CurrentChange.NewValueByName[fld_ObrasNOMBRE_CLIENTE] := Null;
end;
function TObrasBusinessProcessorRules.GetID_SUBCONTRATAValue: Integer;
begin
result := BusinessProcessor.CurrentChange.NewValueByName[fld_ObrasID_SUBCONTRATA];
end;
function TObrasBusinessProcessorRules.GetID_SUBCONTRATAIsNull: Boolean;
begin
result := VarIsNull(BusinessProcessor.CurrentChange.NewValueByName[fld_ObrasID_SUBCONTRATA]);
end;
function TObrasBusinessProcessorRules.GetOldID_SUBCONTRATAValue: Integer;
begin
result := BusinessProcessor.CurrentChange.OldValueByName[fld_ObrasID_SUBCONTRATA];
end;
function TObrasBusinessProcessorRules.GetOldID_SUBCONTRATAIsNull: Boolean;
begin
result := VarIsNull(BusinessProcessor.CurrentChange.OldValueByName[fld_ObrasID_SUBCONTRATA]);
end;
procedure TObrasBusinessProcessorRules.SetID_SUBCONTRATAValue(const aValue: Integer);
begin
BusinessProcessor.CurrentChange.NewValueByName[fld_ObrasID_SUBCONTRATA] := aValue;
end;
procedure TObrasBusinessProcessorRules.SetID_SUBCONTRATAIsNull(const aValue: Boolean);
begin
if aValue then
BusinessProcessor.CurrentChange.NewValueByName[fld_ObrasID_SUBCONTRATA] := Null;
end;
function TObrasBusinessProcessorRules.GetNOMBRE_SUBCONTRATAValue: String;
begin
result := BusinessProcessor.CurrentChange.NewValueByName[fld_ObrasNOMBRE_SUBCONTRATA];
end;
function TObrasBusinessProcessorRules.GetNOMBRE_SUBCONTRATAIsNull: Boolean;
begin
result := VarIsNull(BusinessProcessor.CurrentChange.NewValueByName[fld_ObrasNOMBRE_SUBCONTRATA]);
end;
function TObrasBusinessProcessorRules.GetOldNOMBRE_SUBCONTRATAValue: String;
begin
result := BusinessProcessor.CurrentChange.OldValueByName[fld_ObrasNOMBRE_SUBCONTRATA];
end;
function TObrasBusinessProcessorRules.GetOldNOMBRE_SUBCONTRATAIsNull: Boolean;
begin
result := VarIsNull(BusinessProcessor.CurrentChange.OldValueByName[fld_ObrasNOMBRE_SUBCONTRATA]);
end;
procedure TObrasBusinessProcessorRules.SetNOMBRE_SUBCONTRATAValue(const aValue: String);
begin
BusinessProcessor.CurrentChange.NewValueByName[fld_ObrasNOMBRE_SUBCONTRATA] := aValue;
end;
procedure TObrasBusinessProcessorRules.SetNOMBRE_SUBCONTRATAIsNull(const aValue: Boolean);
begin
if aValue then
BusinessProcessor.CurrentChange.NewValueByName[fld_ObrasNOMBRE_SUBCONTRATA] := Null;
end;
function TObrasBusinessProcessorRules.GetFECHA_ALTAValue: DateTime;
begin
result := BusinessProcessor.CurrentChange.NewValueByName[fld_ObrasFECHA_ALTA];

View File

@ -113,6 +113,16 @@ object srvObras: TsrvObras
DataType = datString
Size = 255
DisplayLabel = 'Cliente'
end
item
Name = 'Obras_ID_SUBCONTRATA'
DataType = datInteger
end
item
Name = 'Obras_NOMBRE_SUBCONTRATA'
DataType = datString
Size = 255
DisplayLabel = 'Subcontrata'
end>
Left = 150
Top = 22
@ -197,6 +207,14 @@ object srvObras: TsrvObras
item
DatasetField = 'USUARIO'
TableField = 'USUARIO'
end
item
DatasetField = 'ID_SUBCONTRATA'
TableField = 'ID_SUBCONTRATA'
end
item
DatasetField = 'NOMBRE_SUBCONTRATA'
TableField = 'NOMBRE_SUBCONTRATA'
end>
end>
Name = 'Obras'
@ -284,6 +302,17 @@ object srvObras: TsrvObras
ServerAutoRefresh = True
DictionaryEntry = 'Obras_NOMBRE_CLIENTE'
end
item
Name = 'ID_SUBCONTRATA'
DataType = datInteger
DictionaryEntry = 'Obras_ID_SUBCONTRATA'
end
item
Name = 'NOMBRE_SUBCONTRATA'
DataType = datString
Size = 255
DictionaryEntry = 'Obras_NOMBRE_SUBCONTRATA'
end
item
Name = 'FECHA_ALTA'
DataType = datDateTime
@ -356,6 +385,10 @@ object srvObras: TsrvObras
Name = 'OBSERVACIONES'
Value = ''
end
item
Name = 'ID_SUBCONTRATA'
Value = ''
end
item
Name = 'ID_CLIENTE'
Value = ''
@ -372,11 +405,11 @@ object srvObras: TsrvObras
SQL =
'INSERT'#10' INTO OBRAS'#10' (ID, ID_EMPRESA, NOMBRE, CALLE, PROVINCI' +
'A, POBLACION, CODIGO_POSTAL,'#10' TELEFONO, MOVIL, FAX, PERSONA_' +
'CONTACTO, OBSERVACIONES, '#10' ID_CLIENTE, FECHA_ALTA,'#10' USUA' +
'RIO)'#10' VALUES'#10' (:ID, :ID_EMPRESA, :NOMBRE, :CALLE, :PROVINCIA' +
', :POBLACION,'#10' :CODIGO_POSTAL, :TELEFONO, :MOVIL, :FAX, :PER' +
'SONA_CONTACTO, '#10' :OBSERVACIONES, :ID_CLIENTE, CURRENT_DATE,'#10 +
' :USUARIO)'#10
'CONTACTO, OBSERVACIONES, '#10' ID_CLIENTE, ID_SUBCONTRATA, FECHA' +
'_ALTA,'#10' USUARIO)'#10' VALUES'#10' (:ID, :ID_EMPRESA, :NOMBRE, :C' +
'ALLE, :PROVINCIA, :POBLACION,'#10' :CODIGO_POSTAL, :TELEFONO, :M' +
'OVIL, :FAX, :PERSONA_CONTACTO, '#10' :OBSERVACIONES, :ID_CLIENTE' +
', :ID_SUBCONTRATA, CURRENT_DATE,'#10' :USUARIO)'#10
StatementType = stSQL
ColumnMappings = <>
end>
@ -401,6 +434,10 @@ object srvObras: TsrvObras
end
item
Params = <
item
Name = 'ID_SUBCONTRATA'
Value = ''
end
item
Name = 'ID_EMPRESA'
Value = ''
@ -472,9 +509,9 @@ object srvObras: TsrvObras
'POBLACION = :POBLACION, '#10' CODIGO_POSTAL = :CODIGO_POSTAL, '#10' ' +
' TELEFONO = :TELEFONO, '#10' MOVIL = :MOVIL, '#10' FAX = :FAX, '#10' ' +
' PERSONA_CONTACTO = :PERSONA_CONTACTO, '#10' OBSERVACIONES = :O' +
'BSERVACIONES, '#10' ID_CLIENTE = :ID_CLIENTE, '#10' FECHA_MODIFICA' +
'CION = :FECHA_MODIFICACION,'#10' USUARIO = :USUARIO'#10' WHERE'#10' (' +
'ID = :OLD_ID)'#10
'BSERVACIONES, '#10' ID_CLIENTE = :ID_CLIENTE, '#10' ID_SUBCONTRATA' +
' = :ID_SUBCONTRATA,'#10' FECHA_MODIFICACION = :FECHA_MODIFICACION' +
','#10' USUARIO = :USUARIO'#10' WHERE'#10' (ID = :OLD_ID)'#10
StatementType = stSQL
ColumnMappings = <>
end>

View File

@ -25,9 +25,11 @@ package Obras_view;
{$IMPLICITBUILD ON}
requires
Base,
GUIBase,
ApplicationBase,
Obras_controller,
Obras_model,
ApplicationBase,
Contactos_view;
contains
@ -36,6 +38,8 @@ contains
uEditorObras in 'uEditorObras.pas' {fEditorObras: TfEditorObras},
uObrasViewRegister in 'uObrasViewRegister.pas',
uEditorObra in 'uEditorObra.pas' {fEditorObra: TfEditorObra},
uEditorListaObras in 'uEditorListaObras.pas' {fEditorListaObras: TfListaObras};
uEditorListaObras in 'uEditorListaObras.pas' {fEditorListaObras: TfListaObras},
uViewSubcontrataObra in 'uViewSubcontrataObra.pas' {frViewSubcontrataObra: TFrame},
uViewClienteAsociadoObra in 'uViewClienteAsociadoObra.pas' {frViewClienteAsociadoObra: T};
end.

View File

@ -1,4 +1,5 @@
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<?xml version="1.0" encoding="utf-8"?>
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<ProjectGuid>{09ecb9ec-6de2-404d-984b-cc7d73caea9a}</ProjectGuid>
<MainSource>Obras_view.dpk</MainSource>
@ -46,10 +47,12 @@
<DelphiCompile Include="Obras_view.dpk">
<MainSource>MainSource</MainSource>
</DelphiCompile>
<DCCReference Include="..\..\..\Servidor\ApplicationBase.dcp" />
<DCCReference Include="..\..\..\Servidor\Contactos_view.dcp" />
<DCCReference Include="..\..\..\Servidor\Obras_controller.dcp" />
<DCCReference Include="..\..\..\Servidor\Obras_model.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\ApplicationBase.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\Base.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\Contactos_view.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\GUIBase.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\Obras_controller.dcp" />
<DCCReference Include="C:\Documents and Settings\Usuario\Obras_model.dcp" />
<DCCReference Include="uEditorListaObras.pas">
<Form>fEditorListaObras</Form>
<DesignClass>TfListaObras</DesignClass>
@ -63,6 +66,10 @@
<DesignClass>TfEditorObras</DesignClass>
</DCCReference>
<DCCReference Include="uObrasViewRegister.pas" />
<DCCReference Include="uViewClienteAsociadoObra.pas">
<Form>frViewClienteAsociadoObra</Form>
<DesignClass>T</DesignClass>
</DCCReference>
<DCCReference Include="uViewObra.pas">
<Form>frViewObra</Form>
<DesignClass>TFrame</DesignClass>
@ -71,6 +78,10 @@
<Form>frViewObras</Form>
<DesignClass>TFrame</DesignClass>
</DCCReference>
<DCCReference Include="uViewSubcontrataObra.pas">
<Form>frViewSubcontrataObra</Form>
<DesignClass>TFrame</DesignClass>
</DCCReference>
</ItemGroup>
</Project>
<!-- EurekaLog First Line

View File

@ -0,0 +1,74 @@
inherited frViewClienteAsociadoObra: TfrViewClienteAsociadoObra
Width = 420
Height = 247
ExplicitWidth = 420
ExplicitHeight = 247
inherited dxLayoutControl1: TdxLayoutControl
Width = 420
Height = 247
ExplicitWidth = 518
ExplicitHeight = 219
inherited edtNIFCIF: TcxDBTextEdit
Top = 99
TabOrder = 4
ExplicitTop = 99
end
inherited edtCalle: TcxDBTextEdit
Top = 126
TabOrder = 5
ExplicitTop = 126
end
inherited edtPoblacion: TcxDBTextEdit
Top = 153
TabOrder = 6
ExplicitTop = 153
end
inherited edtProvincia: TcxDBTextEdit
Top = 180
TabOrder = 8
ExplicitTop = 180
end
inherited edtCodigoPostal: TcxDBTextEdit
Left = 328
Top = 153
TabOrder = 7
ExplicitLeft = 328
ExplicitTop = 153
end
inherited Button3: TBitBtn
Left = 218
Top = 68
TabOrder = 3
ExplicitLeft = 218
ExplicitTop = 68
end
inherited dxLayoutControl1Group_Root: TdxLayoutGroup
inherited dxLayoutControl1Item9: TdxLayoutItem [2]
end
inherited dxLayoutControl1Item2: TdxLayoutItem [3]
Visible = False
end
inherited dxLayoutControl1Item3: TdxLayoutItem [4]
Visible = False
end
inherited dxLayoutControl1Group2: TdxLayoutGroup [5]
Visible = False
end
inherited dxLayoutControl1Item5: TdxLayoutItem [6]
Visible = False
end
end
end
inherited DADataSource: TDADataSource
Left = 280
Top = 8
end
inherited ActionList1: TActionList
Left = 312
Top = 8
end
inherited PngImageList: TPngImageList
Left = 344
Top = 8
end
end

View File

@ -0,0 +1,24 @@
unit uViewClienteAsociadoObra;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, uViewDatosYSeleccionCliente, ImgList, PngImageList, ActnList, DB,
uDAInterfaces, uDADataTable, dxLayoutControl, StdCtrls, Buttons, cxContainer,
cxEdit, cxTextEdit, cxDBEdit, cxControls;
type
TfrViewClienteAsociadoObra = class(TfrViewDatosYSeleccionCliente)
private
{ Private declarations }
public
{ Public declarations }
end;
implementation
{$R *.dfm}
end.

View File

@ -1,6 +1,6 @@
inherited frViewObra: TfrViewObra
Width = 634
Height = 449
Width = 838
Height = 585
Align = alClient
AutoSize = True
ExplicitWidth = 451
@ -8,8 +8,8 @@ inherited frViewObra: TfrViewObra
object dxLayoutControlObra: TdxLayoutControl
Left = 0
Top = 0
Width = 634
Height = 449
Width = 838
Height = 585
Align = alClient
ParentBackground = True
TabOrder = 0
@ -17,11 +17,11 @@ inherited frViewObra: TfrViewObra
ExplicitWidth = 451
ExplicitHeight = 304
DesignSize = (
634
449)
838
585)
object eNombre: TcxDBTextEdit
Left = 130
Top = 28
Top = 34
Anchors = [akLeft, akTop, akRight]
DataBinding.DataField = 'NOMBRE'
DataBinding.DataSource = DADataSource
@ -39,7 +39,7 @@ inherited frViewObra: TfrViewObra
end
object ePersonaContacto: TcxDBTextEdit
Left = 130
Top = 55
Top = 61
Anchors = [akLeft, akTop, akRight]
DataBinding.DataField = 'PERSONA_CONTACTO'
DataBinding.DataSource = DADataSource
@ -55,7 +55,7 @@ inherited frViewObra: TfrViewObra
end
object eTlfTelefono: TcxDBTextEdit
Left = 130
Top = 193
Top = 199
DataBinding.DataField = 'TELEFONO'
DataBinding.DataSource = DADataSource
Style.BorderColor = clWindowFrame
@ -70,7 +70,7 @@ inherited frViewObra: TfrViewObra
end
object eTlfMovil: TcxDBTextEdit
Left = 130
Top = 220
Top = 226
DataBinding.DataField = 'MOVIL'
DataBinding.DataSource = DADataSource
Style.BorderColor = clWindowFrame
@ -85,7 +85,7 @@ inherited frViewObra: TfrViewObra
end
object eFax: TcxDBTextEdit
Left = 130
Top = 247
Top = 253
DataBinding.DataField = 'FAX'
DataBinding.DataSource = DADataSource
Style.BorderColor = clWindowFrame
@ -100,7 +100,7 @@ inherited frViewObra: TfrViewObra
end
object eCalle: TcxDBTextEdit
Left = 130
Top = 112
Top = 118
DataBinding.DataField = 'CALLE'
DataBinding.DataSource = DADataSource
Style.BorderColor = clWindowFrame
@ -119,7 +119,7 @@ inherited frViewObra: TfrViewObra
end
object ePoblacion: TcxDBTextEdit
Left = 130
Top = 139
Top = 145
DataBinding.DataField = 'POBLACION'
DataBinding.DataSource = DADataSource
Style.BorderColor = clWindowFrame
@ -137,8 +137,8 @@ inherited frViewObra: TfrViewObra
Width = 177
end
object eCodigoPostal: TcxDBTextEdit
Left = 276
Top = 139
Left = 333
Top = 145
DataBinding.DataField = 'CODIGO_POSTAL'
DataBinding.DataSource = DADataSource
Style.BorderColor = clWindowFrame
@ -157,7 +157,7 @@ inherited frViewObra: TfrViewObra
end
object eProvincia: TcxDBTextEdit
Left = 130
Top = 166
Top = 172
DataBinding.DataField = 'PROVINCIA'
DataBinding.DataSource = DADataSource
Style.BorderColor = clWindowFrame
@ -174,56 +174,9 @@ inherited frViewObra: TfrViewObra
TabOrder = 5
Width = 278
end
inline frViewDatosYSeleccionCliente1: TfrViewDatosYSeleccionCliente
Left = 347
Top = 28
Width = 350
Height = 212
Font.Charset = DEFAULT_CHARSET
Font.Color = clWindowText
Font.Height = -11
Font.Name = 'Tahoma'
Font.Style = []
ParentFont = False
TabOrder = 9
ReadOnly = False
ExplicitLeft = 347
ExplicitTop = 28
inherited dxLayoutControl1: TdxLayoutControl
ExplicitWidth = 170
inherited edtlNombre: TcxDBTextEdit
ExplicitWidth = 224
Width = 224
end
inherited edtNIFCIF: TcxDBTextEdit
ExplicitWidth = 562
Width = 562
end
inherited edtCalle: TcxDBTextEdit
ExplicitWidth = 562
Width = 562
end
inherited edtPoblacion: TcxDBTextEdit
ExplicitWidth = 177
Width = 177
end
inherited edtProvincia: TcxDBTextEdit
ExplicitWidth = 327
Width = 327
end
inherited edtCodigoPostal: TcxDBTextEdit
Left = 192
ExplicitLeft = 192
end
inherited Button3: TBitBtn
Left = 82
ExplicitLeft = 82
end
end
end
object eObservaciones: TcxDBMemo
Left = 22
Top = 304
Top = 355
DataBinding.DataField = 'OBSERVACIONES'
DataBinding.DataSource = DADataSource
Properties.ScrollBars = ssVertical
@ -237,14 +190,143 @@ inherited frViewObra: TfrViewObra
StyleFocused.LookAndFeel.NativeStyle = True
StyleHot.LookAndFeel.Kind = lfStandard
StyleHot.LookAndFeel.NativeStyle = True
TabOrder = 10
TabOrder = 11
Height = 86
Width = 630
end
inline frViewSubcontrataObra1: TfrViewSubcontrataObra
Left = 424
Top = 169
Width = 409
Height = 150
Font.Charset = DEFAULT_CHARSET
Font.Color = clWindowText
Font.Height = -11
Font.Name = 'Tahoma'
Font.Style = []
ParentFont = False
TabOrder = 10
ReadOnly = False
ExplicitLeft = 424
ExplicitTop = 169
ExplicitWidth = 409
ExplicitHeight = 150
inherited dxLayoutControl1: TdxLayoutControl
Width = 409
inherited edtlNombre: TcxDBTextEdit
ExplicitWidth = 276
Width = 276
end
inherited edtNIFCIF: TcxDBTextEdit
ExplicitWidth = 276
Width = 276
end
inherited edtCalle: TcxDBTextEdit
ExplicitWidth = 276
Width = 276
end
inherited edtPoblacion: TcxDBTextEdit
ExplicitWidth = 158
Width = 158
end
inherited edtProvincia: TcxDBTextEdit
ExplicitWidth = 276
Width = 276
end
inherited edtCodigoPostal: TcxDBTextEdit
Left = 300
ExplicitLeft = 300
end
inherited Button3: TBitBtn
Left = 159
ExplicitLeft = 159
end
inherited edtPersonaContacto: TcxDBTextEdit
ExplicitWidth = 585
Width = 585
end
inherited edtReferenciaAsignada: TcxDBTextEdit
Left = 261
ExplicitLeft = 261
end
inherited edtTlf: TcxDBTextEdit
ExplicitWidth = 169
Width = 169
end
end
inherited DADataSource: TDADataSource
Left = 240
Top = 16
end
inherited ActionList1: TActionList
Left = 264
Top = 16
end
inherited PngImageList: TPngImageList
Left = 296
Top = 16
end
end
inline frViewClienteAsociadoObra1: TfrViewClienteAsociadoObra
Left = 424
Top = 34
Width = 392
Height = 99
Font.Charset = DEFAULT_CHARSET
Font.Color = clWindowText
Font.Height = -11
Font.Name = 'Tahoma'
Font.Style = []
ParentFont = False
TabOrder = 9
ReadOnly = False
ExplicitLeft = 424
ExplicitTop = 34
ExplicitWidth = 392
ExplicitHeight = 99
inherited dxLayoutControl1: TdxLayoutControl
Width = 392
Height = 99
ExplicitWidth = 420
ExplicitHeight = 247
inherited edtlNombre: TcxDBTextEdit
ExplicitWidth = 276
Width = 276
end
inherited edtNIFCIF: TcxDBTextEdit
ExplicitWidth = 276
Width = 276
end
inherited edtCalle: TcxDBTextEdit
ExplicitWidth = 276
Width = 276
end
inherited edtPoblacion: TcxDBTextEdit
ExplicitWidth = 158
Width = 158
end
inherited edtProvincia: TcxDBTextEdit
ExplicitWidth = 276
Width = 276
end
inherited edtCodigoPostal: TcxDBTextEdit
Left = 284
ExplicitLeft = 284
end
inherited Button3: TBitBtn
Left = 174
ExplicitLeft = 174
end
end
end
object dxLayoutControlObraGroup_Root: TdxLayoutGroup
ShowCaption = False
Hidden = True
ShowBorder = False
object dxLayoutControlObraItem12: TdxLayoutItem
ControlOptions.AutoColor = True
ControlOptions.ShowBorder = False
end
object dxLayoutControlObraGroup2: TdxLayoutGroup
ShowCaption = False
Hidden = True
@ -325,16 +407,31 @@ inherited frViewObra: TfrViewObra
end
end
end
object dxLayoutControlObraGroup7: TdxLayoutGroup
AutoAligns = []
object dxLayoutControlObraGroup10: TdxLayoutGroup
AutoAligns = [aaVertical]
AlignHorz = ahClient
Caption = 'Cliente asociado'
object dxLayoutControlObraItem8: TdxLayoutItem
Caption = 'New Item'
ShowCaption = False
Control = frViewDatosYSeleccionCliente1
ControlOptions.AutoColor = True
ControlOptions.ShowBorder = False
ShowCaption = False
Hidden = True
ShowBorder = False
object dxLayoutControlObraGroup7: TdxLayoutGroup
AutoAligns = []
AlignHorz = ahClient
Caption = 'Cliente asociado'
object dxLayoutControlObraItem13: TdxLayoutItem
Caption = 'New Item'
ShowCaption = False
Control = frViewClienteAsociadoObra1
ControlOptions.AutoColor = True
ControlOptions.ShowBorder = False
end
end
object dxLayoutControlObraGroup9: TdxLayoutGroup
Caption = 'Subcontrata'
object dxLayoutControlObraItem8: TdxLayoutItem
Control = frViewSubcontrataObra1
ControlOptions.AutoColor = True
ControlOptions.ShowBorder = False
end
end
end
end

View File

@ -7,7 +7,8 @@ uses
Dialogs, uViewBase, ExtCtrls, StdCtrls, Buttons, DB, uDADataTable,
DBCtrls, Grids, DBGrids, uBizObras, Mask, ComCtrls, uCustomView,
JvComponent, JvFormAutoSize, cxControls, cxContainer, cxEdit, cxTextEdit,
cxDBEdit, dxLayoutControl, uDAInterfaces, uViewDatosYSeleccionCliente, cxMemo;
cxDBEdit, dxLayoutControl, uDAInterfaces, uViewDatosYSeleccionCliente, cxMemo,
uViewDatosYSeleccionProveedor, uViewSubcontrataObra, uViewClienteAsociadoObra;
type
IViewObra = interface(IViewBase)
@ -43,19 +44,25 @@ type
dxLayoutControlObraItem9: TdxLayoutItem;
dxLayoutControlObraGroup6: TdxLayoutGroup;
eProvincia: TcxDBTextEdit;
frViewDatosYSeleccionCliente1: TfrViewDatosYSeleccionCliente;
dxLayoutControlObraGroup7: TdxLayoutGroup;
dxLayoutControlObraItem8: TdxLayoutItem;
dxLayoutControlObraGroup4: TdxLayoutGroup;
dxLayoutControlObraItem11: TdxLayoutItem;
eObservaciones: TcxDBMemo;
dxLayoutControlObraGroup2: TdxLayoutGroup;
dxLayoutControlObraGroup8: TdxLayoutGroup;
dxLayoutControlObraGroup9: TdxLayoutGroup;
dxLayoutControlObraGroup10: TdxLayoutGroup;
dxLayoutControlObraItem8: TdxLayoutItem;
frViewSubcontrataObra1: TfrViewSubcontrataObra;
frViewClienteAsociadoObra1: TfrViewClienteAsociadoObra;
dxLayoutControlObraItem12: TdxLayoutItem;
dxLayoutControlObraItem13: TdxLayoutItem;
protected
FObra: IBizObra;
function GetObra: IBizObra;
procedure SetObra(const Value: IBizObra);
procedure OnClienteChanged(Sender : TObject);
procedure OnSubcontrataChanged(Sender : TObject);
public
property Obra: IBizObra read GetObra write SetObra;
end;
@ -82,21 +89,37 @@ begin
if Assigned(FObra) then
begin
FObra.Edit;
FObra.ID_CLIENTE := frViewDatosYSeleccionCliente1.ID_Cliente;
FObra.ID_CLIENTE := frViewClienteAsociadoObra1.ID_Cliente;
end;
end;
procedure TfrViewObra.OnSubcontrataChanged(Sender: TObject);
begin
if Assigned(FObra) then
begin
FObra.Edit;
FObra.ID_SUBCONTRATA := frViewSubcontrataObra1.ID_Proveedor;
end;
end;
procedure TfrViewObra.SetObra(const Value: IBizObra);
begin
FObra := Value;
frViewDatosYSeleccionCliente1.OnClienteChanged := NIL;
frViewClienteAsociadoObra1.OnClienteChanged := NIL;
frViewSubcontrataObra1.OnProveedorChanged := NIL;
if Assigned(FObra) then
begin
DADataSource.DataTable := FObra.DataTable;
if not FObra.ID_CLIENTEIsNull then
frViewDatosYSeleccionCliente1.ID_Cliente := FObra.ID_CLIENTE;
frViewClienteAsociadoObra1.ID_Cliente := FObra.ID_CLIENTE;
frViewDatosYSeleccionCliente1.OnClienteChanged := OnClienteChanged;
if not FObra.ID_SUBCONTRATAIsNull then
frViewSubcontrataObra1.ID_Proveedor := FObra.ID_SUBCONTRATA;
frViewClienteAsociadoObra1.OnClienteChanged := OnClienteChanged;
frViewSubcontrataObra1.OnProveedorChanged := OnSubcontrataChanged;
end
else
DADataSource.DataTable := NIL;

View File

@ -0,0 +1,195 @@
inherited frViewSubcontrataObra: TfrViewSubcontrataObra
Width = 473
Height = 287
ExplicitWidth = 473
ExplicitHeight = 287
inherited dxLayoutControl1: TdxLayoutControl
Width = 473
Height = 273
ExplicitWidth = 473
ExplicitHeight = 273
DesignSize = (
473
273)
inherited edtlNombre: TcxDBTextEdit
Left = 118
ExplicitLeft = 118
end
inherited edtNIFCIF: TcxDBTextEdit
Left = 118
Top = 153
TabOrder = 7
ExplicitLeft = 118
ExplicitTop = 153
end
inherited edtCalle: TcxDBTextEdit
Left = 118
Top = 180
TabOrder = 8
ExplicitLeft = 118
ExplicitTop = 180
end
inherited edtPoblacion: TcxDBTextEdit
Left = 118
Top = 207
TabOrder = 9
ExplicitLeft = 118
ExplicitTop = 207
end
inherited edtProvincia: TcxDBTextEdit
Left = 118
Top = 234
TabOrder = 11
ExplicitLeft = 118
ExplicitTop = 234
end
inherited edtCodigoPostal: TcxDBTextEdit
Left = 381
Top = 207
TabOrder = 10
ExplicitLeft = 381
ExplicitTop = 207
end
inherited Button1: TBitBtn
Caption = 'Elegir subcontrata'
end
inherited Button3: TBitBtn
Left = 240
Top = 122
Width = 223
Caption = 'Ver ficha completa de la subcontrata...'
TabOrder = 6
ExplicitLeft = 240
ExplicitTop = 122
ExplicitWidth = 223
end
object edtPersonaContacto: TcxDBTextEdit [9]
Left = 118
Top = 95
Anchors = [akLeft, akTop, akRight]
AutoSize = False
DataBinding.DataField = 'PERSONA_CONTACTO'
DataBinding.DataSource = DADataSource
Enabled = False
ParentFont = False
Properties.ReadOnly = True
Properties.UseLeftAlignmentOnEditing = False
Style.BorderColor = clWindowFrame
Style.BorderStyle = ebs3D
Style.HotTrack = False
Style.LookAndFeel.NativeStyle = True
StyleDisabled.LookAndFeel.NativeStyle = True
StyleDisabled.TextColor = clWindowText
StyleFocused.LookAndFeel.NativeStyle = True
StyleHot.LookAndFeel.NativeStyle = True
TabOrder = 5
Height = 21
Width = 585
end
object edtReferenciaAsignada: TcxDBTextEdit [10]
Left = 342
Top = 68
Anchors = [akLeft, akTop, akRight]
AutoSize = False
DataBinding.DataField = 'CODIGO_ASIGNADO'
DataBinding.DataSource = DADataSource
Enabled = False
ParentFont = False
Properties.ReadOnly = True
Properties.UseLeftAlignmentOnEditing = False
Style.BorderColor = clWindowFrame
Style.BorderStyle = ebs3D
Style.HotTrack = False
Style.LookAndFeel.NativeStyle = True
StyleDisabled.LookAndFeel.NativeStyle = True
StyleDisabled.TextColor = clWindowText
StyleFocused.LookAndFeel.NativeStyle = True
StyleHot.LookAndFeel.NativeStyle = True
TabOrder = 4
Height = 21
Width = 121
end
object edtTlf: TcxDBTextEdit [11]
Left = 118
Top = 68
Anchors = [akLeft, akTop, akRight]
AutoSize = False
DataBinding.DataField = 'TELEFONO_1'
DataBinding.DataSource = DADataSource
Enabled = False
ParentFont = False
Properties.ReadOnly = True
Properties.UseLeftAlignmentOnEditing = False
Style.BorderColor = clWindowFrame
Style.BorderStyle = ebs3D
Style.HotTrack = False
Style.LookAndFeel.NativeStyle = True
StyleDisabled.LookAndFeel.NativeStyle = True
StyleDisabled.TextColor = clWindowText
StyleFocused.LookAndFeel.NativeStyle = True
StyleHot.LookAndFeel.NativeStyle = True
TabOrder = 3
Height = 21
Width = 169
end
inherited dxLayoutControl1Group_Root: TdxLayoutGroup
object dxLayoutControl1Group4: TdxLayoutGroup [2]
ShowCaption = False
Hidden = True
LayoutDirection = ldHorizontal
ShowBorder = False
object dxLayoutControl1Item13: TdxLayoutItem
AutoAligns = [aaVertical]
AlignHorz = ahClient
Caption = 'Tel'#233'fono:'
Control = edtTlf
ControlOptions.ShowBorder = False
end
object dxLayoutControl1Item11: TdxLayoutItem
AutoAligns = [aaVertical]
AlignHorz = ahRight
Caption = 'C'#243'd. cliente:'
Control = edtReferenciaAsignada
ControlOptions.ShowBorder = False
end
end
object dxLayoutControl1Item10: TdxLayoutItem [3]
Caption = 'Persona de contacto:'
Control = edtPersonaContacto
ControlOptions.ShowBorder = False
end
inherited dxLayoutControl1Item9: TdxLayoutItem [4]
end
inherited dxLayoutControl1Item2: TdxLayoutItem [5]
Visible = False
end
inherited dxLayoutControl1Item3: TdxLayoutItem [6]
Visible = False
end
inherited dxLayoutControl1Group2: TdxLayoutGroup [7]
Visible = False
end
inherited dxLayoutControl1Item5: TdxLayoutItem [8]
Visible = False
end
end
end
inherited DADataSource: TDADataSource
Left = 288
Top = 8
end
inherited ActionList1: TActionList
Left = 320
Top = 8
inherited actElegirContacto: TAction
Caption = 'Elegir subcontrata'
end
inherited actVerContacto: TAction
Caption = 'Ver ficha completa de la subcontrata...'
end
end
inherited PngImageList: TPngImageList
Left = 352
Top = 8
end
end

View File

@ -0,0 +1,57 @@
unit uViewSubcontrataObra;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, uViewDatosYSeleccionProveedor, ImgList, PngImageList, ActnList, DB,
uDAInterfaces, uDADataTable, dxLayoutControl, StdCtrls, Buttons, cxContainer,
cxEdit, cxTextEdit, cxDBEdit, cxControls;
type
TfrViewSubcontrataObra = class(TfrViewDatosYSeleccionProveedor)
dxLayoutControl1Item10: TdxLayoutItem;
edtPersonaContacto: TcxDBTextEdit;
dxLayoutControl1Item11: TdxLayoutItem;
edtReferenciaAsignada: TcxDBTextEdit;
dxLayoutControl1Item13: TdxLayoutItem;
edtTlf: TcxDBTextEdit;
dxLayoutControl1Group4: TdxLayoutGroup;
protected
procedure ElegirProveedorInternal; override;
public
{ Public declarations }
end;
implementation
{$R *.dfm}
uses
uBizContactos;
{ TfrViewSubcontrataObra }
procedure TfrViewSubcontrataObra.ElegirProveedorInternal;
var
AProveedor : IBizProveedor;
begin
// inherited; <- No llamar al padre
MsgElegirProveedor := ' ';
AProveedor := (Controller.ElegirContacto(Controller.BuscarSubcontratas,
MsgElegirProveedor, False) as IBizProveedor);
if Assigned(AProveedor) then
begin
Self.Update;
ShowHourglassCursor;
try
Proveedor := AProveedor;
finally
HideHourglassCursor;
end;
end;
end;
end.

View File

@ -324,7 +324,7 @@ begin
if (EsFechaVacia(APedido.FECHA_PEDIDO)) then
raise Exception.Create('Debe indicar la fecha de este pedido');
if (Length(APedido.CALLE) = 0) and (APedido.ID_ALMACEN = 0) then
if (Length(APedido.CALLE) = 0) and (APedido.ID_ALMACEN = 0) and (APedido.ID_OBRA = 0) then
raise Exception.Create('Debe indicar una dirección de entrega o almacén para este pedido');
if (APedido.Detalles.DataTable.RecordCount = 0) then

View File

@ -58,12 +58,14 @@ inherited DataModulePedidosProveedor: TDataModulePedidosProveedor
DataType = datString
Size = 255
ServerAutoRefresh = True
DictionaryEntry = 'PedidosProveedor_REFERENCIA'
end
item
Name = 'SITUACION'
DataType = datString
Size = 255
DisplayLabel = 'Situaci'#243'n'
ServerAutoRefresh = True
DictionaryEntry = 'PedidosProveedor_SITUACION'
end
item
@ -101,8 +103,23 @@ inherited DataModulePedidosProveedor: TDataModulePedidosProveedor
DataType = datString
Size = 255
DisplayLabel = 'Almac'#233'n'
ServerAutoRefresh = True
DictionaryEntry = 'PedidosProveedor_NOMBRE_ALMACEN'
end
item
Name = 'ID_OBRA'
DataType = datInteger
DisplayLabel = 'PedidosProveedor_ID_OBRA'
DictionaryEntry = 'PedidosProveedor_ID_OBRA'
end
item
Name = 'NOMBRE_OBRA'
DataType = datString
Size = 255
DisplayLabel = 'Obra'
ServerAutoRefresh = True
DictionaryEntry = 'PedidosProveedor_NOMBRE_OBRA'
end
item
Name = 'OBSERVACIONES'
DataType = datMemo

View File

@ -9,9 +9,9 @@ const
{ Data table rules ids
Feel free to change them to something more human readable
but make sure they are unique in the context of your application }
RID_PedidosProveedor = '{2F38A1ED-3A7F-46F7-B320-466FB2BB4214}';
RID_PedidosProveedor_Detalles = '{32CF76F8-6744-4027-A852-5378F5D96C95}';
RID_PedidosProveedor_Articulos_Pendientes = '{276A7DCD-86B0-4816-A798-6DBDCFDE5152}';
RID_PedidosProveedor = '{1CF81156-64C1-4FFB-9BA8-4A2F34CF3BB2}';
RID_PedidosProveedor_Detalles = '{E983623D-377F-457F-B248-BC3FE9E581B1}';
RID_PedidosProveedor_Articulos_Pendientes = '{0948DD42-EC15-48E7-A5A4-0F3DF630BDEF}';
{ Data table names }
nme_PedidosProveedor = 'PedidosProveedor';
@ -31,6 +31,8 @@ const
fld_PedidosProveedorFECHA_ENTREGA = 'FECHA_ENTREGA';
fld_PedidosProveedorID_ALMACEN = 'ID_ALMACEN';
fld_PedidosProveedorNOMBRE_ALMACEN = 'NOMBRE_ALMACEN';
fld_PedidosProveedorID_OBRA = 'ID_OBRA';
fld_PedidosProveedorNOMBRE_OBRA = 'NOMBRE_OBRA';
fld_PedidosProveedorOBSERVACIONES = 'OBSERVACIONES';
fld_PedidosProveedorIMPORTE_TOTAL = 'IMPORTE_TOTAL';
fld_PedidosProveedorINCIDENCIAS = 'INCIDENCIAS';
@ -68,29 +70,31 @@ const
idx_PedidosProveedorFECHA_ENTREGA = 9;
idx_PedidosProveedorID_ALMACEN = 10;
idx_PedidosProveedorNOMBRE_ALMACEN = 11;
idx_PedidosProveedorOBSERVACIONES = 12;
idx_PedidosProveedorIMPORTE_TOTAL = 13;
idx_PedidosProveedorINCIDENCIAS = 14;
idx_PedidosProveedorINCIDENCIAS_ACTIVAS = 15;
idx_PedidosProveedorCALLE = 16;
idx_PedidosProveedorPOBLACION = 17;
idx_PedidosProveedorPROVINCIA = 18;
idx_PedidosProveedorCODIGO_POSTAL = 19;
idx_PedidosProveedorPERSONA_CONTACTO = 20;
idx_PedidosProveedorTELEFONO = 21;
idx_PedidosProveedorFECHA_ALTA = 22;
idx_PedidosProveedorFECHA_MODIFICACION = 23;
idx_PedidosProveedorUSUARIO = 24;
idx_PedidosProveedorID_PEDIDO_CLIENTE = 25;
idx_PedidosProveedorREF_PED_CLIENTE = 26;
idx_PedidosProveedorIMPORTE_NETO = 27;
idx_PedidosProveedorIMPORTE_PORTE = 28;
idx_PedidosProveedorDESCUENTO = 29;
idx_PedidosProveedorIMPORTE_DESCUENTO = 30;
idx_PedidosProveedorBASE_IMPONIBLE = 31;
idx_PedidosProveedorIVA = 32;
idx_PedidosProveedorIMPORTE_IVA = 33;
idx_PedidosProveedorID_FORMA_PAGO = 34;
idx_PedidosProveedorID_OBRA = 12;
idx_PedidosProveedorNOMBRE_OBRA = 13;
idx_PedidosProveedorOBSERVACIONES = 14;
idx_PedidosProveedorIMPORTE_TOTAL = 15;
idx_PedidosProveedorINCIDENCIAS = 16;
idx_PedidosProveedorINCIDENCIAS_ACTIVAS = 17;
idx_PedidosProveedorCALLE = 18;
idx_PedidosProveedorPOBLACION = 19;
idx_PedidosProveedorPROVINCIA = 20;
idx_PedidosProveedorCODIGO_POSTAL = 21;
idx_PedidosProveedorPERSONA_CONTACTO = 22;
idx_PedidosProveedorTELEFONO = 23;
idx_PedidosProveedorFECHA_ALTA = 24;
idx_PedidosProveedorFECHA_MODIFICACION = 25;
idx_PedidosProveedorUSUARIO = 26;
idx_PedidosProveedorID_PEDIDO_CLIENTE = 27;
idx_PedidosProveedorREF_PED_CLIENTE = 28;
idx_PedidosProveedorIMPORTE_NETO = 29;
idx_PedidosProveedorIMPORTE_PORTE = 30;
idx_PedidosProveedorDESCUENTO = 31;
idx_PedidosProveedorIMPORTE_DESCUENTO = 32;
idx_PedidosProveedorBASE_IMPONIBLE = 33;
idx_PedidosProveedorIVA = 34;
idx_PedidosProveedorIMPORTE_IVA = 35;
idx_PedidosProveedorID_FORMA_PAGO = 36;
{ PedidosProveedor_Detalles fields }
fld_PedidosProveedor_DetallesID = 'ID';
@ -108,6 +112,7 @@ const
fld_PedidosProveedor_DetallesIMPORTE_PORTE = 'IMPORTE_PORTE';
fld_PedidosProveedor_DetallesREFERENCIA = 'REFERENCIA';
fld_PedidosProveedor_DetallesREFERENCIA_PROVEEDOR = 'REFERENCIA_PROVEEDOR';
fld_PedidosProveedor_DetallesREFERENCIA_FABRICANTE = 'REFERENCIA_FABRICANTE';
{ PedidosProveedor_Detalles field indexes }
idx_PedidosProveedor_DetallesID = 0;
@ -125,6 +130,7 @@ const
idx_PedidosProveedor_DetallesIMPORTE_PORTE = 12;
idx_PedidosProveedor_DetallesREFERENCIA = 13;
idx_PedidosProveedor_DetallesREFERENCIA_PROVEEDOR = 14;
idx_PedidosProveedor_DetallesREFERENCIA_FABRICANTE = 15;
{ PedidosProveedor_Articulos_Pendientes fields }
fld_PedidosProveedor_Articulos_PendientesID_PEDIDO = 'ID_PEDIDO';
@ -145,7 +151,7 @@ const
type
{ IPedidosProveedor }
IPedidosProveedor = interface(IDAStronglyTypedDataTable)
['{333644C7-E17E-4FD7-BFD1-3078A5D13F1E}']
['{C489C7DC-C83D-4A64-94D5-ADA513CD2C1E}']
{ Property getters and setters }
function GetIDValue: Integer;
procedure SetIDValue(const aValue: Integer);
@ -195,6 +201,14 @@ type
procedure SetNOMBRE_ALMACENValue(const aValue: String);
function GetNOMBRE_ALMACENIsNull: Boolean;
procedure SetNOMBRE_ALMACENIsNull(const aValue: Boolean);
function GetID_OBRAValue: Integer;
procedure SetID_OBRAValue(const aValue: Integer);
function GetID_OBRAIsNull: Boolean;
procedure SetID_OBRAIsNull(const aValue: Boolean);
function GetNOMBRE_OBRAValue: String;
procedure SetNOMBRE_OBRAValue(const aValue: String);
function GetNOMBRE_OBRAIsNull: Boolean;
procedure SetNOMBRE_OBRAIsNull(const aValue: Boolean);
function GetOBSERVACIONESValue: IROStrings;
function GetOBSERVACIONESIsNull: Boolean;
procedure SetOBSERVACIONESIsNull(const aValue: Boolean);
@ -312,6 +326,10 @@ type
property ID_ALMACENIsNull: Boolean read GetID_ALMACENIsNull write SetID_ALMACENIsNull;
property NOMBRE_ALMACEN: String read GetNOMBRE_ALMACENValue write SetNOMBRE_ALMACENValue;
property NOMBRE_ALMACENIsNull: Boolean read GetNOMBRE_ALMACENIsNull write SetNOMBRE_ALMACENIsNull;
property ID_OBRA: Integer read GetID_OBRAValue write SetID_OBRAValue;
property ID_OBRAIsNull: Boolean read GetID_OBRAIsNull write SetID_OBRAIsNull;
property NOMBRE_OBRA: String read GetNOMBRE_OBRAValue write SetNOMBRE_OBRAValue;
property NOMBRE_OBRAIsNull: Boolean read GetNOMBRE_OBRAIsNull write SetNOMBRE_OBRAIsNull;
property OBSERVACIONES: IROStrings read GetOBSERVACIONESValue;
property OBSERVACIONESIsNull: Boolean read GetOBSERVACIONESIsNull write SetOBSERVACIONESIsNull;
property IMPORTE_TOTAL: Currency read GetIMPORTE_TOTALValue write SetIMPORTE_TOTALValue;
@ -417,6 +435,14 @@ type
procedure SetNOMBRE_ALMACENValue(const aValue: String); virtual;
function GetNOMBRE_ALMACENIsNull: Boolean; virtual;
procedure SetNOMBRE_ALMACENIsNull(const aValue: Boolean); virtual;
function GetID_OBRAValue: Integer; virtual;
procedure SetID_OBRAValue(const aValue: Integer); virtual;
function GetID_OBRAIsNull: Boolean; virtual;
procedure SetID_OBRAIsNull(const aValue: Boolean); virtual;
function GetNOMBRE_OBRAValue: String; virtual;
procedure SetNOMBRE_OBRAValue(const aValue: String); virtual;
function GetNOMBRE_OBRAIsNull: Boolean; virtual;
procedure SetNOMBRE_OBRAIsNull(const aValue: Boolean); virtual;
function GetOBSERVACIONESValue: IROStrings; virtual;
function GetOBSERVACIONESIsNull: Boolean; virtual;
procedure SetOBSERVACIONESIsNull(const aValue: Boolean); virtual;
@ -533,6 +559,10 @@ type
property ID_ALMACENIsNull: Boolean read GetID_ALMACENIsNull write SetID_ALMACENIsNull;
property NOMBRE_ALMACEN: String read GetNOMBRE_ALMACENValue write SetNOMBRE_ALMACENValue;
property NOMBRE_ALMACENIsNull: Boolean read GetNOMBRE_ALMACENIsNull write SetNOMBRE_ALMACENIsNull;
property ID_OBRA: Integer read GetID_OBRAValue write SetID_OBRAValue;
property ID_OBRAIsNull: Boolean read GetID_OBRAIsNull write SetID_OBRAIsNull;
property NOMBRE_OBRA: String read GetNOMBRE_OBRAValue write SetNOMBRE_OBRAValue;
property NOMBRE_OBRAIsNull: Boolean read GetNOMBRE_OBRAIsNull write SetNOMBRE_OBRAIsNull;
property OBSERVACIONES: IROStrings read GetOBSERVACIONESValue;
property OBSERVACIONESIsNull: Boolean read GetOBSERVACIONESIsNull write SetOBSERVACIONESIsNull;
property IMPORTE_TOTAL: Currency read GetIMPORTE_TOTALValue write SetIMPORTE_TOTALValue;
@ -588,7 +618,7 @@ type
{ IPedidosProveedor_Detalles }
IPedidosProveedor_Detalles = interface(IDAStronglyTypedDataTable)
['{109F0849-4B0E-4D32-BF3F-F6449B8D2CE5}']
['{7E0C0A15-D909-4826-AE8E-7B10A4E20F96}']
{ Property getters and setters }
function GetIDValue: Integer;
procedure SetIDValue(const aValue: Integer);
@ -650,6 +680,10 @@ type
procedure SetREFERENCIA_PROVEEDORValue(const aValue: String);
function GetREFERENCIA_PROVEEDORIsNull: Boolean;
procedure SetREFERENCIA_PROVEEDORIsNull(const aValue: Boolean);
function GetREFERENCIA_FABRICANTEValue: String;
procedure SetREFERENCIA_FABRICANTEValue(const aValue: String);
function GetREFERENCIA_FABRICANTEIsNull: Boolean;
procedure SetREFERENCIA_FABRICANTEIsNull(const aValue: Boolean);
{ Properties }
@ -683,6 +717,8 @@ type
property REFERENCIAIsNull: Boolean read GetREFERENCIAIsNull write SetREFERENCIAIsNull;
property REFERENCIA_PROVEEDOR: String read GetREFERENCIA_PROVEEDORValue write SetREFERENCIA_PROVEEDORValue;
property REFERENCIA_PROVEEDORIsNull: Boolean read GetREFERENCIA_PROVEEDORIsNull write SetREFERENCIA_PROVEEDORIsNull;
property REFERENCIA_FABRICANTE: String read GetREFERENCIA_FABRICANTEValue write SetREFERENCIA_FABRICANTEValue;
property REFERENCIA_FABRICANTEIsNull: Boolean read GetREFERENCIA_FABRICANTEIsNull write SetREFERENCIA_FABRICANTEIsNull;
end;
{ TPedidosProveedor_DetallesDataTableRules }
@ -750,6 +786,10 @@ type
procedure SetREFERENCIA_PROVEEDORValue(const aValue: String); virtual;
function GetREFERENCIA_PROVEEDORIsNull: Boolean; virtual;
procedure SetREFERENCIA_PROVEEDORIsNull(const aValue: Boolean); virtual;
function GetREFERENCIA_FABRICANTEValue: String; virtual;
procedure SetREFERENCIA_FABRICANTEValue(const aValue: String); virtual;
function GetREFERENCIA_FABRICANTEIsNull: Boolean; virtual;
procedure SetREFERENCIA_FABRICANTEIsNull(const aValue: Boolean); virtual;
{ Properties }
property ID: Integer read GetIDValue write SetIDValue;
@ -782,6 +822,8 @@ type
property REFERENCIAIsNull: Boolean read GetREFERENCIAIsNull write SetREFERENCIAIsNull;
property REFERENCIA_PROVEEDOR: String read GetREFERENCIA_PROVEEDORValue write SetREFERENCIA_PROVEEDORValue;
property REFERENCIA_PROVEEDORIsNull: Boolean read GetREFERENCIA_PROVEEDORIsNull write SetREFERENCIA_PROVEEDORIsNull;
property REFERENCIA_FABRICANTE: String read GetREFERENCIA_FABRICANTEValue write SetREFERENCIA_FABRICANTEValue;
property REFERENCIA_FABRICANTEIsNull: Boolean read GetREFERENCIA_FABRICANTEIsNull write SetREFERENCIA_FABRICANTEIsNull;
public
constructor Create(aDataTable: TDADataTable); override;
@ -791,7 +833,7 @@ type
{ IPedidosProveedor_Articulos_Pendientes }
IPedidosProveedor_Articulos_Pendientes = interface(IDAStronglyTypedDataTable)
['{0C6DE081-242A-4ADF-99BE-2AFE45A142B1}']
['{F29B11FD-AB7A-4A83-AE4D-5C8BD44D8D38}']
{ Property getters and setters }
function GetID_PEDIDOValue: Integer;
procedure SetID_PEDIDOValue(const aValue: Integer);
@ -1171,6 +1213,48 @@ begin
DataTable.Fields[idx_PedidosProveedorNOMBRE_ALMACEN].AsVariant := Null;
end;
function TPedidosProveedorDataTableRules.GetID_OBRAValue: Integer;
begin
result := DataTable.Fields[idx_PedidosProveedorID_OBRA].AsInteger;
end;
procedure TPedidosProveedorDataTableRules.SetID_OBRAValue(const aValue: Integer);
begin
DataTable.Fields[idx_PedidosProveedorID_OBRA].AsInteger := aValue;
end;
function TPedidosProveedorDataTableRules.GetID_OBRAIsNull: boolean;
begin
result := DataTable.Fields[idx_PedidosProveedorID_OBRA].IsNull;
end;
procedure TPedidosProveedorDataTableRules.SetID_OBRAIsNull(const aValue: Boolean);
begin
if aValue then
DataTable.Fields[idx_PedidosProveedorID_OBRA].AsVariant := Null;
end;
function TPedidosProveedorDataTableRules.GetNOMBRE_OBRAValue: String;
begin
result := DataTable.Fields[idx_PedidosProveedorNOMBRE_OBRA].AsString;
end;
procedure TPedidosProveedorDataTableRules.SetNOMBRE_OBRAValue(const aValue: String);
begin
DataTable.Fields[idx_PedidosProveedorNOMBRE_OBRA].AsString := aValue;
end;
function TPedidosProveedorDataTableRules.GetNOMBRE_OBRAIsNull: boolean;
begin
result := DataTable.Fields[idx_PedidosProveedorNOMBRE_OBRA].IsNull;
end;
procedure TPedidosProveedorDataTableRules.SetNOMBRE_OBRAIsNull(const aValue: Boolean);
begin
if aValue then
DataTable.Fields[idx_PedidosProveedorNOMBRE_OBRA].AsVariant := Null;
end;
function TPedidosProveedorDataTableRules.GetOBSERVACIONESValue: IROStrings;
begin
result := f_OBSERVACIONES;
@ -1973,6 +2057,27 @@ begin
DataTable.Fields[idx_PedidosProveedor_DetallesREFERENCIA_PROVEEDOR].AsVariant := Null;
end;
function TPedidosProveedor_DetallesDataTableRules.GetREFERENCIA_FABRICANTEValue: String;
begin
result := DataTable.Fields[idx_PedidosProveedor_DetallesREFERENCIA_FABRICANTE].AsString;
end;
procedure TPedidosProveedor_DetallesDataTableRules.SetREFERENCIA_FABRICANTEValue(const aValue: String);
begin
DataTable.Fields[idx_PedidosProveedor_DetallesREFERENCIA_FABRICANTE].AsString := aValue;
end;
function TPedidosProveedor_DetallesDataTableRules.GetREFERENCIA_FABRICANTEIsNull: boolean;
begin
result := DataTable.Fields[idx_PedidosProveedor_DetallesREFERENCIA_FABRICANTE].IsNull;
end;
procedure TPedidosProveedor_DetallesDataTableRules.SetREFERENCIA_FABRICANTEIsNull(const aValue: Boolean);
begin
if aValue then
DataTable.Fields[idx_PedidosProveedor_DetallesREFERENCIA_FABRICANTE].AsVariant := Null;
end;
{ TPedidosProveedor_Articulos_PendientesDataTableRules }
constructor TPedidosProveedor_Articulos_PendientesDataTableRules.Create(aDataTable: TDADataTable);

View File

@ -9,14 +9,14 @@ const
{ Delta rules ids
Feel free to change them to something more human readable
but make sure they are unique in the context of your application }
RID_PedidosProveedorDelta = '{E6771CAE-270F-4C79-BDF5-0C7EFC7CDF68}';
RID_PedidosProveedor_DetallesDelta = '{A2EF2F8A-B1CB-4122-919F-06604309B1B8}';
RID_PedidosProveedor_Articulos_PendientesDelta = '{7AA8D557-941A-4B44-A8D2-35781BEBD144}';
RID_PedidosProveedorDelta = '{196C6489-D928-4C44-9BF8-805217F34B48}';
RID_PedidosProveedor_DetallesDelta = '{164697E4-3417-4195-9B7B-5DD7D5FF5C2D}';
RID_PedidosProveedor_Articulos_PendientesDelta = '{95000330-646B-489B-9300-A0B22EB9A7A6}';
type
{ IPedidosProveedorDelta }
IPedidosProveedorDelta = interface(IPedidosProveedor)
['{E6771CAE-270F-4C79-BDF5-0C7EFC7CDF68}']
['{196C6489-D928-4C44-9BF8-805217F34B48}']
{ Property getters and setters }
function GetOldIDValue : Integer;
function GetOldID_EMPRESAValue : Integer;
@ -30,6 +30,8 @@ type
function GetOldFECHA_ENTREGAValue : DateTime;
function GetOldID_ALMACENValue : Integer;
function GetOldNOMBRE_ALMACENValue : String;
function GetOldID_OBRAValue : Integer;
function GetOldNOMBRE_OBRAValue : String;
function GetOldOBSERVACIONESValue : IROStrings;
function GetOldIMPORTE_TOTALValue : Currency;
function GetOldINCIDENCIASValue : IROStrings;
@ -67,6 +69,8 @@ type
property OldFECHA_ENTREGA : DateTime read GetOldFECHA_ENTREGAValue;
property OldID_ALMACEN : Integer read GetOldID_ALMACENValue;
property OldNOMBRE_ALMACEN : String read GetOldNOMBRE_ALMACENValue;
property OldID_OBRA : Integer read GetOldID_OBRAValue;
property OldNOMBRE_OBRA : String read GetOldNOMBRE_OBRAValue;
property OldOBSERVACIONES : IROStrings read GetOldOBSERVACIONESValue;
property OldIMPORTE_TOTAL : Currency read GetOldIMPORTE_TOTALValue;
property OldINCIDENCIAS : IROStrings read GetOldINCIDENCIASValue;
@ -173,6 +177,18 @@ type
function GetOldNOMBRE_ALMACENIsNull: Boolean; virtual;
procedure SetNOMBRE_ALMACENValue(const aValue: String); virtual;
procedure SetNOMBRE_ALMACENIsNull(const aValue: Boolean); virtual;
function GetID_OBRAValue: Integer; virtual;
function GetID_OBRAIsNull: Boolean; virtual;
function GetOldID_OBRAValue: Integer; virtual;
function GetOldID_OBRAIsNull: Boolean; virtual;
procedure SetID_OBRAValue(const aValue: Integer); virtual;
procedure SetID_OBRAIsNull(const aValue: Boolean); virtual;
function GetNOMBRE_OBRAValue: String; virtual;
function GetNOMBRE_OBRAIsNull: Boolean; virtual;
function GetOldNOMBRE_OBRAValue: String; virtual;
function GetOldNOMBRE_OBRAIsNull: Boolean; virtual;
procedure SetNOMBRE_OBRAValue(const aValue: String); virtual;
procedure SetNOMBRE_OBRAIsNull(const aValue: Boolean); virtual;
function GetOBSERVACIONESValue: IROStrings; virtual;
function GetOBSERVACIONESIsNull: Boolean; virtual;
function GetOldOBSERVACIONESValue: IROStrings; virtual;
@ -359,6 +375,14 @@ type
property NOMBRE_ALMACENIsNull : Boolean read GetNOMBRE_ALMACENIsNull write SetNOMBRE_ALMACENIsNull;
property OldNOMBRE_ALMACEN : String read GetOldNOMBRE_ALMACENValue;
property OldNOMBRE_ALMACENIsNull : Boolean read GetOldNOMBRE_ALMACENIsNull;
property ID_OBRA : Integer read GetID_OBRAValue write SetID_OBRAValue;
property ID_OBRAIsNull : Boolean read GetID_OBRAIsNull write SetID_OBRAIsNull;
property OldID_OBRA : Integer read GetOldID_OBRAValue;
property OldID_OBRAIsNull : Boolean read GetOldID_OBRAIsNull;
property NOMBRE_OBRA : String read GetNOMBRE_OBRAValue write SetNOMBRE_OBRAValue;
property NOMBRE_OBRAIsNull : Boolean read GetNOMBRE_OBRAIsNull write SetNOMBRE_OBRAIsNull;
property OldNOMBRE_OBRA : String read GetOldNOMBRE_OBRAValue;
property OldNOMBRE_OBRAIsNull : Boolean read GetOldNOMBRE_OBRAIsNull;
property OBSERVACIONES : IROStrings read GetOBSERVACIONESValue;
property OBSERVACIONESIsNull : Boolean read GetOBSERVACIONESIsNull write SetOBSERVACIONESIsNull;
property OldOBSERVACIONES : IROStrings read GetOldOBSERVACIONESValue;
@ -460,7 +484,7 @@ type
{ IPedidosProveedor_DetallesDelta }
IPedidosProveedor_DetallesDelta = interface(IPedidosProveedor_Detalles)
['{A2EF2F8A-B1CB-4122-919F-06604309B1B8}']
['{164697E4-3417-4195-9B7B-5DD7D5FF5C2D}']
{ Property getters and setters }
function GetOldIDValue : Integer;
function GetOldID_PEDIDOValue : Integer;
@ -477,6 +501,7 @@ type
function GetOldIMPORTE_PORTEValue : Currency;
function GetOldREFERENCIAValue : String;
function GetOldREFERENCIA_PROVEEDORValue : String;
function GetOldREFERENCIA_FABRICANTEValue : String;
{ Properties }
property OldID : Integer read GetOldIDValue;
@ -494,6 +519,7 @@ type
property OldIMPORTE_PORTE : Currency read GetOldIMPORTE_PORTEValue;
property OldREFERENCIA : String read GetOldREFERENCIAValue;
property OldREFERENCIA_PROVEEDOR : String read GetOldREFERENCIA_PROVEEDORValue;
property OldREFERENCIA_FABRICANTE : String read GetOldREFERENCIA_FABRICANTEValue;
end;
{ TPedidosProveedor_DetallesBusinessProcessorRules }
@ -591,6 +617,12 @@ type
function GetOldREFERENCIA_PROVEEDORIsNull: Boolean; virtual;
procedure SetREFERENCIA_PROVEEDORValue(const aValue: String); virtual;
procedure SetREFERENCIA_PROVEEDORIsNull(const aValue: Boolean); virtual;
function GetREFERENCIA_FABRICANTEValue: String; virtual;
function GetREFERENCIA_FABRICANTEIsNull: Boolean; virtual;
function GetOldREFERENCIA_FABRICANTEValue: String; virtual;
function GetOldREFERENCIA_FABRICANTEIsNull: Boolean; virtual;
procedure SetREFERENCIA_FABRICANTEValue(const aValue: String); virtual;
procedure SetREFERENCIA_FABRICANTEIsNull(const aValue: Boolean); virtual;
{ Properties }
property ID : Integer read GetIDValue write SetIDValue;
@ -653,6 +685,10 @@ type
property REFERENCIA_PROVEEDORIsNull : Boolean read GetREFERENCIA_PROVEEDORIsNull write SetREFERENCIA_PROVEEDORIsNull;
property OldREFERENCIA_PROVEEDOR : String read GetOldREFERENCIA_PROVEEDORValue;
property OldREFERENCIA_PROVEEDORIsNull : Boolean read GetOldREFERENCIA_PROVEEDORIsNull;
property REFERENCIA_FABRICANTE : String read GetREFERENCIA_FABRICANTEValue write SetREFERENCIA_FABRICANTEValue;
property REFERENCIA_FABRICANTEIsNull : Boolean read GetREFERENCIA_FABRICANTEIsNull write SetREFERENCIA_FABRICANTEIsNull;
property OldREFERENCIA_FABRICANTE : String read GetOldREFERENCIA_FABRICANTEValue;
property OldREFERENCIA_FABRICANTEIsNull : Boolean read GetOldREFERENCIA_FABRICANTEIsNull;
public
constructor Create(aBusinessProcessor: TDABusinessProcessor); override;
@ -662,7 +698,7 @@ type
{ IPedidosProveedor_Articulos_PendientesDelta }
IPedidosProveedor_Articulos_PendientesDelta = interface(IPedidosProveedor_Articulos_Pendientes)
['{7AA8D557-941A-4B44-A8D2-35781BEBD144}']
['{95000330-646B-489B-9300-A0B22EB9A7A6}']
{ Property getters and setters }
function GetOldID_PEDIDOValue : Integer;
function GetOldREFERENCIAValue : String;
@ -1162,6 +1198,68 @@ begin
BusinessProcessor.CurrentChange.NewValueByName[fld_PedidosProveedorNOMBRE_ALMACEN] := Null;
end;
function TPedidosProveedorBusinessProcessorRules.GetID_OBRAValue: Integer;
begin
result := BusinessProcessor.CurrentChange.NewValueByName[fld_PedidosProveedorID_OBRA];
end;
function TPedidosProveedorBusinessProcessorRules.GetID_OBRAIsNull: Boolean;
begin
result := VarIsNull(BusinessProcessor.CurrentChange.NewValueByName[fld_PedidosProveedorID_OBRA]);
end;
function TPedidosProveedorBusinessProcessorRules.GetOldID_OBRAValue: Integer;
begin
result := BusinessProcessor.CurrentChange.OldValueByName[fld_PedidosProveedorID_OBRA];
end;
function TPedidosProveedorBusinessProcessorRules.GetOldID_OBRAIsNull: Boolean;
begin
result := VarIsNull(BusinessProcessor.CurrentChange.OldValueByName[fld_PedidosProveedorID_OBRA]);
end;
procedure TPedidosProveedorBusinessProcessorRules.SetID_OBRAValue(const aValue: Integer);
begin
BusinessProcessor.CurrentChange.NewValueByName[fld_PedidosProveedorID_OBRA] := aValue;
end;
procedure TPedidosProveedorBusinessProcessorRules.SetID_OBRAIsNull(const aValue: Boolean);
begin
if aValue then
BusinessProcessor.CurrentChange.NewValueByName[fld_PedidosProveedorID_OBRA] := Null;
end;
function TPedidosProveedorBusinessProcessorRules.GetNOMBRE_OBRAValue: String;
begin
result := BusinessProcessor.CurrentChange.NewValueByName[fld_PedidosProveedorNOMBRE_OBRA];
end;
function TPedidosProveedorBusinessProcessorRules.GetNOMBRE_OBRAIsNull: Boolean;
begin
result := VarIsNull(BusinessProcessor.CurrentChange.NewValueByName[fld_PedidosProveedorNOMBRE_OBRA]);
end;
function TPedidosProveedorBusinessProcessorRules.GetOldNOMBRE_OBRAValue: String;
begin
result := BusinessProcessor.CurrentChange.OldValueByName[fld_PedidosProveedorNOMBRE_OBRA];
end;
function TPedidosProveedorBusinessProcessorRules.GetOldNOMBRE_OBRAIsNull: Boolean;
begin
result := VarIsNull(BusinessProcessor.CurrentChange.OldValueByName[fld_PedidosProveedorNOMBRE_OBRA]);
end;
procedure TPedidosProveedorBusinessProcessorRules.SetNOMBRE_OBRAValue(const aValue: String);
begin
BusinessProcessor.CurrentChange.NewValueByName[fld_PedidosProveedorNOMBRE_OBRA] := aValue;
end;
procedure TPedidosProveedorBusinessProcessorRules.SetNOMBRE_OBRAIsNull(const aValue: Boolean);
begin
if aValue then
BusinessProcessor.CurrentChange.NewValueByName[fld_PedidosProveedorNOMBRE_OBRA] := Null;
end;
function TPedidosProveedorBusinessProcessorRules.GetOBSERVACIONESValue: IROStrings;
begin
result := f_OBSERVACIONES;
@ -2346,6 +2444,37 @@ begin
BusinessProcessor.CurrentChange.NewValueByName[fld_PedidosProveedor_DetallesREFERENCIA_PROVEEDOR] := Null;
end;
function TPedidosProveedor_DetallesBusinessProcessorRules.GetREFERENCIA_FABRICANTEValue: String;
begin
result := BusinessProcessor.CurrentChange.NewValueByName[fld_PedidosProveedor_DetallesREFERENCIA_FABRICANTE];
end;
function TPedidosProveedor_DetallesBusinessProcessorRules.GetREFERENCIA_FABRICANTEIsNull: Boolean;
begin
result := VarIsNull(BusinessProcessor.CurrentChange.NewValueByName[fld_PedidosProveedor_DetallesREFERENCIA_FABRICANTE]);
end;
function TPedidosProveedor_DetallesBusinessProcessorRules.GetOldREFERENCIA_FABRICANTEValue: String;
begin
result := BusinessProcessor.CurrentChange.OldValueByName[fld_PedidosProveedor_DetallesREFERENCIA_FABRICANTE];
end;
function TPedidosProveedor_DetallesBusinessProcessorRules.GetOldREFERENCIA_FABRICANTEIsNull: Boolean;
begin
result := VarIsNull(BusinessProcessor.CurrentChange.OldValueByName[fld_PedidosProveedor_DetallesREFERENCIA_FABRICANTE]);
end;
procedure TPedidosProveedor_DetallesBusinessProcessorRules.SetREFERENCIA_FABRICANTEValue(const aValue: String);
begin
BusinessProcessor.CurrentChange.NewValueByName[fld_PedidosProveedor_DetallesREFERENCIA_FABRICANTE] := aValue;
end;
procedure TPedidosProveedor_DetallesBusinessProcessorRules.SetREFERENCIA_FABRICANTEIsNull(const aValue: Boolean);
begin
if aValue then
BusinessProcessor.CurrentChange.NewValueByName[fld_PedidosProveedor_DetallesREFERENCIA_FABRICANTE] := Null;
end;
{ TPedidosProveedor_Articulos_PendientesBusinessProcessorRules }
constructor TPedidosProveedor_Articulos_PendientesBusinessProcessorRules.Create(aBusinessProcessor: TDABusinessProcessor);

View File

@ -201,10 +201,6 @@ begin
INCIDENCIAS_ACTIVAS := 0;
// ID_PEDIDO_CLIENTE := 0;
REF_PED_CLIENTE := '';
// OJOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO
// ALMACÉN PUESTO A CAPÓN Y PROVISIONAL
ID_ALMACEN := 2;
end;
procedure TBizPedidoProveedor.IVAOnChange(Sender: TDACustomField);

View File

@ -161,6 +161,14 @@ object srvPedidosProveedor: TsrvPedidosProveedor
item
DatasetField = 'ID_FORMA_PAGO'
TableField = 'ID_FORMA_PAGO'
end
item
DatasetField = 'ID_OBRA'
TableField = 'ID_OBRA'
end
item
DatasetField = 'NOMBRE_OBRA'
TableField = 'NOMBRE_OBRA'
end>
end>
Name = 'PedidosProveedor'
@ -194,11 +202,13 @@ object srvPedidosProveedor: TsrvPedidosProveedor
DataType = datString
Size = 255
ServerAutoRefresh = True
DictionaryEntry = 'PedidosProveedor_REFERENCIA'
end
item
Name = 'SITUACION'
DataType = datString
Size = 255
ServerAutoRefresh = True
DictionaryEntry = 'PedidosProveedor_SITUACION'
end
item
@ -230,8 +240,21 @@ object srvPedidosProveedor: TsrvPedidosProveedor
Name = 'NOMBRE_ALMACEN'
DataType = datString
Size = 255
ServerAutoRefresh = True
DictionaryEntry = 'PedidosProveedor_NOMBRE_ALMACEN'
end
item
Name = 'ID_OBRA'
DataType = datInteger
DictionaryEntry = 'PedidosProveedor_ID_OBRA'
end
item
Name = 'NOMBRE_OBRA'
DataType = datString
Size = 255
ServerAutoRefresh = True
DictionaryEntry = 'PedidosProveedor_NOMBRE_OBRA'
end
item
Name = 'OBSERVACIONES'
DataType = datMemo
@ -865,6 +888,10 @@ object srvPedidosProveedor: TsrvPedidosProveedor
Name = 'INCIDENCIAS_ACTIVAS'
Value = ''
end
item
Name = 'ID_OBRA'
Value = ''
end
item
Name = 'ID_ALMACEN'
Value = ''
@ -938,18 +965,18 @@ object srvPedidosProveedor: TsrvPedidosProveedor
'ERENCIA, ID, ID_EMPRESA,'#10' FECHA_ALTA, FECHA_MODIFICACION, ID' +
'_PROVEEDOR, FECHA_ENVIO,'#10' FECHA_PEDIDO, FECHA_CONFIRMACION, ' +
'FECHA_ENTREGA, INCIDENCIAS, '#10' IMPORTE_TOTAL, INCIDENCIAS_ACT' +
'IVAS, ID_ALMACEN, CALLE, '#10' POBLACION, PROVINCIA, CODIGO_POST' +
'AL, PERSONA_CONTACTO, '#10' TELEFONO, ID_PEDIDO_CLIENTE, IMPORTE' +
'_NETO, IMPORTE_PORTE, '#10' DESCUENTO, IMPORTE_DESCUENTO, BASE_I' +
'MPONIBLE, IVA, '#10' IMPORTE_IVA, ID_FORMA_PAGO)'#10' VALUES'#10' (:' +
'USUARIO, :OBSERVACIONES, :REFERENCIA, :ID,'#10' :ID_EMPRESA, :FE' +
'CHA_ALTA, :FECHA_MODIFICACION,'#10' :ID_PROVEEDOR, :FECHA_ENVIO,' +
' :FECHA_PEDIDO, :FECHA_CONFIRMACION,'#10' :FECHA_ENTREGA, :INCID' +
'ENCIAS, :IMPORTE_TOTAL, :INCIDENCIAS_ACTIVAS, '#10' :ID_ALMACEN,' +
' :CALLE, :POBLACION, :PROVINCIA, :CODIGO_POSTAL, '#10' :PERSONA_' +
'CONTACTO, :TELEFONO, :ID_PEDIDO_CLIENTE, :IMPORTE_NETO, '#10' :I' +
'MPORTE_PORTE, :DESCUENTO, :IMPORTE_DESCUENTO, :BASE_IMPONIBLE, '#10 +
' :IVA, :IMPORTE_IVA, :ID_FORMA_PAGO)'
'IVAS, ID_ALMACEN, ID_OBRA, CALLE,'#10' POBLACION, PROVINCIA, COD' +
'IGO_POSTAL, PERSONA_CONTACTO, '#10' TELEFONO, ID_PEDIDO_CLIENTE,' +
' IMPORTE_NETO, IMPORTE_PORTE, '#10' DESCUENTO, IMPORTE_DESCUENTO' +
', BASE_IMPONIBLE, IVA, '#10' IMPORTE_IVA, ID_FORMA_PAGO)'#10' VALUE' +
'S'#10' (:USUARIO, :OBSERVACIONES, :REFERENCIA, :ID,'#10' :ID_EMPR' +
'ESA, :FECHA_ALTA, :FECHA_MODIFICACION,'#10' :ID_PROVEEDOR, :FECH' +
'A_ENVIO, :FECHA_PEDIDO, :FECHA_CONFIRMACION,'#10' :FECHA_ENTREGA' +
', :INCIDENCIAS, :IMPORTE_TOTAL, :INCIDENCIAS_ACTIVAS, '#10' :ID_' +
'ALMACEN, :ID_OBRA, :CALLE, :POBLACION, :PROVINCIA, :CODIGO_POSTA' +
'L,'#10' :PERSONA_CONTACTO, :TELEFONO, :ID_PEDIDO_CLIENTE, :IMPOR' +
'TE_NETO, '#10' :IMPORTE_PORTE, :DESCUENTO, :IMPORTE_DESCUENTO, :' +
'BASE_IMPONIBLE, '#10' :IVA, :IMPORTE_IVA, :ID_FORMA_PAGO)'#10
StatementType = stSQL
ColumnMappings = <>
end>
@ -1017,6 +1044,10 @@ object srvPedidosProveedor: TsrvPedidosProveedor
Name = 'INCIDENCIAS_ACTIVAS'
Value = ''
end
item
Name = 'ID_OBRA'
Value = ''
end
item
Name = 'ID_ALMACEN'
Value = ''
@ -1099,15 +1130,15 @@ object srvPedidosProveedor: TsrvPedidosProveedor
'RMACION, '#10' FECHA_ENTREGA = :FECHA_ENTREGA, '#10' INCIDENCIAS =' +
' :INCIDENCIAS, '#10' IMPORTE_TOTAL = :IMPORTE_TOTAL, '#10' INCIDEN' +
'CIAS_ACTIVAS = :INCIDENCIAS_ACTIVAS, '#10' ID_ALMACEN = :ID_ALMAC' +
'EN, '#10' CALLE = :CALLE, '#10' POBLACION = :POBLACION, '#10' PROVI' +
'NCIA = :PROVINCIA, '#10' CODIGO_POSTAL = :CODIGO_POSTAL, '#10' PER' +
'SONA_CONTACTO = :PERSONA_CONTACTO, '#10' TELEFONO = :TELEFONO, '#10' ' +
' ID_PEDIDO_CLIENTE = :ID_PEDIDO_CLIENTE, '#10' IMPORTE_NETO = :' +
'IMPORTE_NETO, '#10' IMPORTE_PORTE = :IMPORTE_PORTE, '#10' DESCUENT' +
'O = :DESCUENTO, '#10' IMPORTE_DESCUENTO = :IMPORTE_DESCUENTO, '#10' ' +
' BASE_IMPONIBLE = :BASE_IMPONIBLE, '#10' IVA = :IVA, '#10' IMPORT' +
'E_IVA = :IMPORTE_IVA, '#10' ID_FORMA_PAGO = :ID_FORMA_PAGO'#10' WHER' +
'E'#10' (ID = :OLD_ID)'#10
'EN, '#10' ID_OBRA = :ID_OBRA,'#10' CALLE = :CALLE, '#10' POBLACION ' +
'= :POBLACION, '#10' PROVINCIA = :PROVINCIA, '#10' CODIGO_POSTAL = ' +
':CODIGO_POSTAL, '#10' PERSONA_CONTACTO = :PERSONA_CONTACTO, '#10' ' +
'TELEFONO = :TELEFONO, '#10' ID_PEDIDO_CLIENTE = :ID_PEDIDO_CLIENT' +
'E, '#10' IMPORTE_NETO = :IMPORTE_NETO, '#10' IMPORTE_PORTE = :IMPO' +
'RTE_PORTE, '#10' DESCUENTO = :DESCUENTO, '#10' IMPORTE_DESCUENTO =' +
' :IMPORTE_DESCUENTO, '#10' BASE_IMPONIBLE = :BASE_IMPONIBLE, '#10' ' +
' IVA = :IVA, '#10' IMPORTE_IVA = :IMPORTE_IVA, '#10' ID_FORMA_PAGO' +
' = :ID_FORMA_PAGO'#10' WHERE'#10' (ID = :OLD_ID)'#10
StatementType = stSQL
ColumnMappings = <>
end>
@ -1485,6 +1516,16 @@ object srvPedidosProveedor: TsrvPedidosProveedor
DataType = datString
Size = 255
DisplayLabel = 'Ref. fabricante'
end
item
Name = 'PedidosProveedor_ID_OBRA'
DataType = datInteger
end
item
Name = 'PedidosProveedor_NOMBRE_OBRA'
DataType = datString
Size = 255
DisplayLabel = 'Obra'
end>
Left = 88
Top = 152

View File

@ -31,8 +31,10 @@ requires
Almacenes_model,
Almacenes_controller,
Contactos_view,
Articulos_view;
Articulos_view,
Obras_model,
Obras_controller;
contains
uPedidosProveedorViewRegister in 'uPedidosProveedorViewRegister.pas',
uEditorPedidosProveedor in 'uEditorPedidosProveedor.pas' {fEditorPedidosProveedor: TfEditorPedidosProveedor},
@ -46,6 +48,7 @@ contains
uEditorDireccionEntregaPedidoProveedor in 'uEditorDireccionEntregaPedidoProveedor.pas' {fEditorDireccionEntregaPedidoProveedor : TfEditorDireccionEntregaPedidoProveedor},
uViewElegirArticulosPedidosProveedor in 'uViewElegirArticulosPedidosProveedor.pas' {frViewElegirArticulosPedidosProveedor: TFrame},
uEditorElegirArticulosPedidoProveedor in 'uEditorElegirArticulosPedidoProveedor.pas' {fEditorElegirArticulosPedidoProveedor: TForm},
uEditorSituacionPedidoProveedor in 'uEditorSituacionPedidoProveedor.pas' {fEditorSituacionPedidoProveedor: TfEditorSituacionPedidoProveedor};
uEditorSituacionPedidoProveedor in 'uEditorSituacionPedidoProveedor.pas' {fEditorSituacionPedidoProveedor: TfEditorSituacionPedidoProveedor},
uViewProveedorPedido in 'uViewProveedorPedido.pas' {frViewProveedorPedido: TFrame};
end.

View File

@ -41,60 +41,23 @@
<Borland.Personality>Delphi.Personality</Borland.Personality>
<Borland.ProjectType>Package</Borland.ProjectType>
<BorlandProject>
<BorlandProject xmlns=""> <Delphi.Personality> <Parameters>
<Parameters Name="UseLauncher">False</Parameters>
<Parameters Name="LoadAllSymbols">True</Parameters>
<Parameters Name="LoadUnspecifiedSymbols">False</Parameters>
</Parameters>
<Package_Options>
<Package_Options Name="ImplicitBuild">True</Package_Options>
<Package_Options Name="DesigntimeOnly">False</Package_Options>
<Package_Options Name="RuntimeOnly">False</Package_Options>
</Package_Options>
<VersionInfo>
<VersionInfo Name="IncludeVerInfo">True</VersionInfo>
<VersionInfo Name="AutoIncBuild">False</VersionInfo>
<VersionInfo Name="MajorVer">1</VersionInfo>
<VersionInfo Name="MinorVer">0</VersionInfo>
<VersionInfo Name="Release">0</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.0.0.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.0.0.0</VersionInfoKeys>
<VersionInfoKeys Name="Comments"></VersionInfoKeys>
</VersionInfoKeys>
<Source>
<Source Name="MainSource">PedidosProveedor_view.dpk</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><Package_Options><Package_Options Name="ImplicitBuild">True</Package_Options><Package_Options Name="DesigntimeOnly">False</Package_Options><Package_Options Name="RuntimeOnly">False</Package_Options></Package_Options><VersionInfo><VersionInfo Name="IncludeVerInfo">True</VersionInfo><VersionInfo Name="AutoIncBuild">False</VersionInfo><VersionInfo Name="MajorVer">1</VersionInfo><VersionInfo Name="MinorVer">0</VersionInfo><VersionInfo Name="Release">0</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.0.0.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.0.0.0</VersionInfoKeys><VersionInfoKeys Name="Comments"></VersionInfoKeys></VersionInfoKeys><Source><Source Name="MainSource">PedidosProveedor_view.dpk</Source></Source></Delphi.Personality></BorlandProject></BorlandProject>
</ProjectExtensions>
<Import Project="$(MSBuildBinPath)\Borland.Delphi.Targets" />
<ItemGroup>
<DelphiCompile Include="PedidosProveedor_view.dpk">
<MainSource>MainSource</MainSource>
</DelphiCompile>
<DCCReference Include="..\..\Lib\Almacenes_controller.dcp" />
<DCCReference Include="..\..\Lib\Almacenes_model.dcp" />
<DCCReference Include="..\..\Lib\Articulos_view.dcp" />
<DCCReference Include="..\..\Lib\Contactos_view.dcp" />
<DCCReference Include="..\..\Lib\GUIBase.dcp" />
<DCCReference Include="..\..\Lib\PedidosProveedor_controller.dcp" />
<DCCReference Include="..\..\Lib\PedidosProveedor_model.dcp" />
<DCCReference Include="..\..\Contactos\Plugin\Almacenes_controller.dcp" />
<DCCReference Include="..\..\Contactos\Plugin\Almacenes_model.dcp" />
<DCCReference Include="..\..\Contactos\Plugin\Articulos_view.dcp" />
<DCCReference Include="..\..\Contactos\Plugin\Contactos_view.dcp" />
<DCCReference Include="..\..\Contactos\Plugin\GUIBase.dcp" />
<DCCReference Include="..\..\Contactos\Plugin\Obras_controller.dcp" />
<DCCReference Include="..\..\Contactos\Plugin\Obras_controllercontainsuPedidosProveedorViewRegisterin.dcp" />
<DCCReference Include="..\..\Contactos\Plugin\Obras_model.dcp" />
<DCCReference Include="..\..\Contactos\Plugin\PedidosProveedor_controller.dcp" />
<DCCReference Include="..\..\Contactos\Plugin\PedidosProveedor_model.dcp" />
<DCCReference Include="uEditorDireccionEntregaPedidoProveedor.pas">
<Form>fEditorDireccionEntregaPedidoProveedor </Form>
<DesignClass>TfEditorDireccionEntregaPedidoProveedor</DesignClass>
@ -144,12 +107,15 @@
<Form>frViewPedidosProveedor</Form>
<DesignClass>TFrame</DesignClass>
</DCCReference>
<DCCReference Include="uViewProveedorPedido.pas">
<Form>frViewProveedorPedido</Form>
<DesignClass>TFrame</DesignClass>
</DCCReference>
</ItemGroup>
</Project>
<!-- EurekaLog First Line
[Exception Log]
EurekaLog Version=6006
EurekaLog Version=6011
Activate=0
Activate Handle=1
Save Log File=1

View File

@ -0,0 +1,22 @@
1 VERSIONINFO
FILEVERSION 1,0,0,0
PRODUCTVERSION 1,0,0,0
FILEFLAGSMASK 0x3FL
FILEFLAGS 0x00L
FILEOS 0x40004L
FILETYPE 0x1L
FILESUBTYPE 0x0L
BEGIN
BLOCK "StringFileInfo"
BEGIN
BLOCK "0C0A04E4"
BEGIN
VALUE "FileVersion", "1.0.0.0\0"
VALUE "ProductVersion", "1.0.0.0\0"
END
END
BLOCK "VarFileInfo"
BEGIN
VALUE "Translation", 0x0C0A, 1252
END
END

View File

@ -109,23 +109,25 @@ inherited fEditorPedidoProveedor: TfEditorPedidoProveedor
ExplicitLeft = 278
ExplicitTop = 0
end
inherited FontName: TJvFontComboBox
inherited ToolButton14: TToolButton [4]
Left = 334
Top = 0
ExplicitLeft = 334
ExplicitTop = 0
end
inherited ToolButton14: TToolButton
Left = 479
inherited FontName: TJvFontComboBox [5]
Left = 399
Top = 0
ExplicitLeft = 479
ExplicitLeft = 399
ExplicitTop = 0
end
inherited FontSize: TEdit
Left = 544
Top = 0
Width = 102
ExplicitLeft = 544
ExplicitTop = 0
ExplicitWidth = 102
end
inherited ToolButton13: TToolButton [7]
Left = 0
@ -141,49 +143,47 @@ inherited fEditorPedidoProveedor: TfEditorPedidoProveedor
ExplicitLeft = 0
ExplicitTop = 27
end
inherited ToolButton11: TToolButton
inherited ToolButton6: TToolButton [9]
Left = 17
Top = 27
ExplicitLeft = 17
ExplicitTop = 27
end
inherited ToolButton12: TToolButton
Left = 158
inherited ToolButton7: TToolButton [10]
Left = 83
Top = 27
Wrap = False
ExplicitLeft = 158
ExplicitLeft = 83
ExplicitTop = 27
end
inherited ToolButton8: TToolButton [11]
Left = 150
Top = 27
ExplicitLeft = 150
ExplicitTop = 27
end
inherited ToolButton12: TToolButton [12]
Left = 233
Top = 27
ExplicitLeft = 233
ExplicitTop = 27
ExplicitHeight = 22
end
inherited ToolButton9: TToolButton
Left = 166
inherited ToolButton9: TToolButton [13]
Left = 241
Top = 27
ExplicitLeft = 166
ExplicitLeft = 241
ExplicitTop = 27
end
inherited ToolButton10: TToolButton
Left = 311
inherited ToolButton10: TToolButton [14]
Left = 386
Top = 27
ExplicitLeft = 311
ExplicitLeft = 386
ExplicitTop = 27
end
inherited ToolButton6: TToolButton
Left = 436
inherited ToolButton11: TToolButton [15]
Left = 511
Top = 27
ExplicitLeft = 436
ExplicitTop = 27
end
inherited ToolButton7: TToolButton
Left = 502
Top = 27
Wrap = False
ExplicitLeft = 502
ExplicitTop = 27
end
inherited ToolButton8: TToolButton
Left = 569
Top = 27
ExplicitLeft = 569
ExplicitLeft = 511
ExplicitTop = 27
end
end
@ -191,9 +191,9 @@ inherited fEditorPedidoProveedor: TfEditorPedidoProveedor
Top = 77
Width = 751
Height = 365
ExplicitTop = 77
ExplicitTop = 72
ExplicitWidth = 751
ExplicitHeight = 365
ExplicitHeight = 370
inherited cxGridView: TcxGridDBTableView
inherited cxGridViewIMPORTENETO: TcxGridDBColumn
Options.Editing = True
@ -203,7 +203,6 @@ inherited fEditorPedidoProveedor: TfEditorPedidoProveedor
inherited TBXDock1: TTBXDock
Top = 51
Width = 751
ExplicitTop = 51
ExplicitWidth = 751
inherited TBXToolbar1: TTBXToolbar
ExplicitWidth = 626
@ -233,6 +232,9 @@ inherited fEditorPedidoProveedor: TfEditorPedidoProveedor
inherited pnlSup: TPanel
Width = 751
ExplicitWidth = 751
inherited eIncidenciaActiva: TcxDBCheckBox
ExplicitHeight = 21
end
end
inherited GroupBox1: TGroupBox
Width = 751

View File

@ -176,7 +176,6 @@ var
bEsNuevo : Boolean;
begin
inherited;
bEsNuevo := False;
ShowHourglassCursor;
// frViewDetallesPedidoProveedor1.SaveGridStatus; // Para guardar estado del grid

View File

@ -251,28 +251,33 @@ begin
end;
procedure TfEditorPedidosProveedor.NuevoInterno;
var
Respuesta : Integer;
{var
Respuesta : Integer;}
begin
inherited;
Respuesta := JsNuevoPedidoProveedorDialog.Execute;
// Para Tecsitel: No preguntar si hacer el pedido de proveedor
// basado en pedido de cliente.
{ Respuesta := JsNuevoPedidoProveedorDialog.Execute;
if Respuesta <> IDCANCEL then
begin
case JsNuevoPedidoProveedorDialog.CustomButtonResult of
200 : begin // Utilizar un pedido
// GenerarPedidosProv;
actRefrescar.Execute;
actRefrescar.Execute;
end;
100 : begin // Pedido nuevo vacio
FController.Anadir(Pedidos);
FController.Ver(Pedidos);
end;
end;
end;
end;}
// Pedido nuevo vacio
FController.Anadir(Pedidos);
FController.Ver(Pedidos);
end;
procedure TfEditorPedidosProveedor.PonerTitulos(const ATitulo: string);

View File

@ -20,26 +20,25 @@ inherited frViewDireccionEntregaPedidoProv: TfrViewDireccionEntregaPedidoProv
Top = 10
Width = 255
Height = 17
Action = actLista
Action = actListaAlmacenes
TabOrder = 0
TabStop = True
end
object rdxDestino2: TRadioButton
Left = 10
Top = 60
Top = 110
Width = 287
Height = 17
Action = actOtro
TabOrder = 2
TabOrder = 4
end
object cbLista: TcxDBLookupComboBox
object cbListaAlmacenes: TcxDBLookupComboBox
Left = 25
Top = 33
Anchors = [akLeft, akTop, akRight]
DataBinding.DataField = 'ID_ALMACEN'
DataBinding.DataSource = dsPedido
Properties.DropDownListStyle = lsFixedList
Properties.ListOptions.SyncMode = True
Properties.ImmediatePost = True
Properties.KeyFieldNames = 'ID'
Properties.ListColumns = <
@ -49,6 +48,7 @@ inherited frViewDireccionEntregaPedidoProv: TfrViewDireccionEntregaPedidoProv
Properties.ListOptions.AnsiSort = True
Properties.ListOptions.GridLines = glNone
Properties.ListOptions.ShowHeader = False
Properties.ListOptions.SyncMode = True
Properties.ListSource = dsAlmacenes
Properties.PostPopupValueOnTab = True
Style.BorderColor = clWindowFrame
@ -69,19 +69,59 @@ inherited frViewDireccionEntregaPedidoProv: TfrViewDireccionEntregaPedidoProv
Width = 128
Height = 25
Caption = 'Modificar la direcci'#243'n...'
TabOrder = 4
TabOrder = 6
OnClick = bModificarClick
end
object txtDireccion: TStaticText
Left = 25
Top = 83
Top = 133
Width = 551
Height = 177
AutoSize = False
BevelKind = bkFlat
TabOrder = 3
TabOrder = 5
OnDblClick = txtDireccionDblClick
end
object RadioButton1: TRadioButton
Left = 10
Top = 60
Width = 566
Height = 17
Action = actListaObras
TabOrder = 2
end
object cbListaObras: TcxDBLookupComboBox
Left = 25
Top = 83
Anchors = [akLeft, akTop, akRight]
DataBinding.DataField = 'ID_OBRA'
DataBinding.DataSource = dsPedido
Properties.DropDownListStyle = lsFixedList
Properties.ImmediatePost = True
Properties.KeyFieldNames = 'ID'
Properties.ListColumns = <
item
FieldName = 'NOMBRE'
end>
Properties.ListOptions.AnsiSort = True
Properties.ListOptions.GridLines = glNone
Properties.ListOptions.ShowHeader = False
Properties.ListOptions.SyncMode = True
Properties.ListSource = dsObras
Properties.PostPopupValueOnTab = True
Properties.OnInitPopup = cbListaObrasPropertiesInitPopup
Style.BorderColor = clWindowFrame
Style.BorderStyle = ebs3D
Style.HotTrack = False
Style.LookAndFeel.NativeStyle = True
Style.ButtonStyle = bts3D
Style.PopupBorderStyle = epbsFrame3D
StyleDisabled.LookAndFeel.NativeStyle = True
StyleFocused.LookAndFeel.NativeStyle = True
StyleHot.LookAndFeel.NativeStyle = True
TabOrder = 3
Width = 551
end
object dxLayoutGroup1: TdxLayoutGroup
ShowCaption = False
Hidden = True
@ -97,7 +137,19 @@ inherited frViewDireccionEntregaPedidoProv: TfrViewDireccionEntregaPedidoProv
Caption = 'New Item'
Offsets.Left = 15
ShowCaption = False
Control = cbLista
Control = cbListaAlmacenes
ControlOptions.ShowBorder = False
end
object dxLayoutControl1Item4: TdxLayoutItem
ShowCaption = False
Control = RadioButton1
ControlOptions.AutoColor = True
ControlOptions.ShowBorder = False
end
object dxLayoutControl1Item6: TdxLayoutItem
Offsets.Left = 15
ShowCaption = False
Control = cbListaObras
ControlOptions.ShowBorder = False
end
object dxLayoutControl1Item2: TdxLayoutItem
@ -128,26 +180,35 @@ inherited frViewDireccionEntregaPedidoProv: TfrViewDireccionEntregaPedidoProv
end
end
object ActionList1: TActionList
Left = 80
Top = 16
object actLista: TAction
Left = 384
Top = 8
object actListaAlmacenes: TAction
Caption = 'Recibir el pedido en el almac'#233'n:'
Checked = True
GroupIndex = 1
OnExecute = actListaExecute
OnExecute = actListaAlmacenesExecute
end
object actOtro: TAction
Caption = 'Recibir el pedido en esta otra direcci'#243'n:'
GroupIndex = 1
OnExecute = actOtroExecute
end
object actListaObras: TAction
Caption = 'Recibir el pedido en la obra:'
GroupIndex = 1
OnExecute = actListaObrasExecute
end
end
object dsPedido: TDADataSource
Left = 40
Left = 352
Top = 8
end
object dsAlmacenes: TDADataSource
Left = 8
Top = 40
Left = 320
Top = 8
end
object dsObras: TDADataSource
Left = 288
Top = 8
end
end

View File

@ -8,7 +8,7 @@ uses
cxContainer, cxEdit, cxTextEdit, cxMaskEdit, cxDropDownEdit, cxLookupEdit,
cxDBLookupEdit, cxDBLookupComboBox, StdCtrls, cxControls, DB, uDADataTable,
ActnList, uBizAlmacenes, uAlmacenesController, uPedidosProveedorController,
Buttons, uDAInterfaces;
Buttons, uDAInterfaces, uBizObras, uObrasController;
type
IViewDireccionEntregaPedidoProv = interface(IViewBase)
@ -22,13 +22,13 @@ type
dxLayoutControl1: TdxLayoutControl;
rdxDestino1: TRadioButton;
rdxDestino2: TRadioButton;
cbLista: TcxDBLookupComboBox;
cbListaAlmacenes: TcxDBLookupComboBox;
dxLayoutGroup1: TdxLayoutGroup;
dxLayoutItem1: TdxLayoutItem;
dxLayoutControl1Item3: TdxLayoutItem;
dxLayoutControl1Item2: TdxLayoutItem;
ActionList1: TActionList;
actLista: TAction;
actListaAlmacenes: TAction;
actOtro: TAction;
dsPedido: TDADataSource;
dsAlmacenes: TDADataSource;
@ -36,19 +36,31 @@ type
bModificar: TBitBtn;
txtDireccion: TStaticText;
dxLayoutControl1Item5: TdxLayoutItem;
procedure actListaExecute(Sender: TObject);
dxLayoutControl1Item4: TdxLayoutItem;
RadioButton1: TRadioButton;
dxLayoutControl1Item6: TdxLayoutItem;
cbListaObras: TcxDBLookupComboBox;
dsObras: TDADataSource;
actListaObras: TAction;
procedure actListaAlmacenesExecute(Sender: TObject);
procedure actOtroExecute(Sender: TObject);
procedure cbListaPropertiesValidate(Sender: TObject; var DisplayValue: Variant; var ErrorText: TCaption; var Error: Boolean);
procedure cbListaAlmacenesPropertiesValidate(Sender: TObject; var DisplayValue: Variant; var ErrorText: TCaption; var Error: Boolean);
procedure cbListaObrasPropertiesValidate(Sender: TObject; var DisplayValue: Variant; var ErrorText: TCaption; var Error: Boolean);
procedure bModificarClick(Sender: TObject);
procedure txtDireccionDblClick(Sender: TObject);
procedure cbListaObrasPropertiesInitPopup(Sender: TObject);
procedure actListaObrasExecute(Sender: TObject);
protected
FAlmacenesController : IAlmacenesController;
FAlmacenes: IBizAlmacen;
FObrasController : IObrasController;
FObras: IBizObra;
FPedido : IBizPedidoProveedor;
FController : IPedidosProveedorController;
function GetPedidoProveedor: IBizPedidoProveedor;
procedure SetPedidoProveedor(const Value: IBizPedidoProveedor);
procedure CambioDireccionAlmacen;
procedure CambioDireccionObra;
procedure RefrescarDireccion;
procedure SetReadOnly(Value: Boolean); override;
@ -65,9 +77,16 @@ implementation
uses
uEditorRegistryUtils, uCustomView;
procedure TfrViewDireccionEntregaPedidoProv.actListaExecute(Sender: TObject);
procedure TfrViewDireccionEntregaPedidoProv.actListaAlmacenesExecute(Sender: TObject);
begin
actLista.Checked := True;
actListaAlmacenes.Checked := True;
RefrescarDireccion;
end;
procedure TfrViewDireccionEntregaPedidoProv.actListaObrasExecute(
Sender: TObject);
begin
actListaObras.Checked := True;
RefrescarDireccion;
end;
@ -85,6 +104,11 @@ begin
FPedido.Edit;
FPedido.ID_ALMACEN := 0;
end;
if (FPedido.ID_OBRA > 0) then
begin
FPedido.Edit;
FPedido.ID_OBRA := 0;
end;
end;
RefrescarDireccion;
end;
@ -97,8 +121,7 @@ end;
procedure TfrViewDireccionEntregaPedidoProv.CambioDireccionAlmacen;
begin
if Assigned(FPedido)
and Assigned(FAlmacenes) then
if Assigned(FPedido) and Assigned(FAlmacenes) then
begin
FPedido.Edit;
FPedido.CALLE := FAlmacenes.CALLE;
@ -112,13 +135,46 @@ begin
end;
end;
procedure TfrViewDireccionEntregaPedidoProv.cbListaPropertiesValidate(
procedure TfrViewDireccionEntregaPedidoProv.CambioDireccionObra;
begin
if Assigned(FPedido) and Assigned(FObras) then
begin
FPedido.Edit;
FPedido.CALLE := FObras.CALLE;
FPedido.POBLACION := FObras.POBLACION;
FPedido.POBLACION := FObras.POBLACION;
FPedido.PROVINCIA := FObras.PROVINCIA;
FPedido.CODIGO_POSTAL := FObras.CODIGO_POSTAL;
FPedido.PERSONA_CONTACTO := FObras.PERSONA_CONTACTO;
FPedido.TELEFONO := FObras.TELEFONO;
RefrescarDireccion;
end;
end;
procedure TfrViewDireccionEntregaPedidoProv.cbListaObrasPropertiesInitPopup(
Sender: TObject);
begin
inherited;
FObrasController := TObrasController.Create;
FObras := FObrasController.BuscarTodos;
FObras.DataTable.Active := True;
dsObras.DataTable := FObras.DataTable;
end;
procedure TfrViewDireccionEntregaPedidoProv.cbListaObrasPropertiesValidate(
Sender: TObject; var DisplayValue: Variant; var ErrorText: TCaption;
var Error: Boolean);
begin
if Assigned(FPedido) and Assigned(FAlmacenes)
and (FPedido.ID_ALMACEN <> FAlmacenes.ID) then
CambioDireccionAlmacen;
if Assigned(FPedido) and Assigned(FObras) and (FPedido.ID_OBRA <> FObras.ID) then
CambioDireccionObra;
end;
procedure TfrViewDireccionEntregaPedidoProv.cbListaAlmacenesPropertiesValidate(
Sender: TObject; var DisplayValue: Variant; var ErrorText: TCaption;
var Error: Boolean);
begin
if Assigned(FPedido) and Assigned(FAlmacenes) and (FPedido.ID_ALMACEN <> FAlmacenes.ID) then
CambioDireccionAlmacen;
end;
constructor TfrViewDireccionEntregaPedidoProv.Create(AOwner: TComponent);
@ -133,9 +189,15 @@ end;
destructor TfrViewDireccionEntregaPedidoProv.Destroy;
begin
cbLista.Properties.OnValidate := Nil;
cbListaObras.Properties.OnValidate := Nil;
cbListaAlmacenes.Properties.OnValidate := Nil;
FAlmacenesController := Nil;
FAlmacenes := Nil;
FObrasController := Nil;
FObras := Nil;
FController := NIL;
inherited;
end;
@ -152,19 +214,35 @@ begin
begin
if (actOtro.Checked) then
begin
cbLista.Enabled := False;
cbLista.Text := '';
cbListaAlmacenes.Enabled := False;
cbListaAlmacenes.Text := '';
cbListaObras.Enabled := False;
cbListaObras.Text := '';
txtDireccion.Enabled := True;
txtDireccion.Caption := FPedido.CALLE;
txtDireccion.Caption := txtDireccion.Caption + #13#10 + FPedido.CODIGO_POSTAL + ' ' + FPedido.POBLACION;
txtDireccion.Caption := txtDireccion.Caption + #13#10 + FPedido.PROVINCIA;
bModificar.Enabled := True;
end
else if (actListaAlmacenes.Checked) then
begin
txtDireccion.Enabled := False;
cbListaObras.Enabled := False;
cbListaObras.Text := '';
cbListaAlmacenes.Enabled := True;
cbListaAlmacenes.DroppedDown := True;
bModificar.Enabled := False;
end
else begin
txtDireccion.Enabled := False;
cbLista.Enabled := True;
cbLista.DroppedDown := True;
bModificar.Enabled := False;
cbListaAlmacenes.Enabled := False;
cbListaAlmacenes.Text := '';
cbListaObras.Enabled := True;
cbListaObras.DroppedDown := True;
bModificar.Enabled := False;
end;
end;
end;
@ -172,19 +250,26 @@ end;
procedure TfrViewDireccionEntregaPedidoProv.SetPedidoProveedor(
const Value: IBizPedidoProveedor);
begin
cbLista.Properties.OnValidate := NIL;
cbListaAlmacenes.Properties.OnValidate := NIL;
cbListaObras.Properties.OnValidate := NIL;
dsPedido.DataTable := nil;
FPedido := Value;
dsPedido.DataTable := FPedido.DataTable;
cbLista.Properties.OnValidate := cbListaPropertiesValidate;
cbListaAlmacenes.Properties.OnValidate := cbListaAlmacenesPropertiesValidate;
cbListaObras.Properties.OnValidate := cbListaObrasPropertiesValidate;
if (FPedido.EsNuevo) then
CambioDireccionAlmacen
else
if (FPedido.ID_ALMACEN < 1) then
actOtro.Checked := True;
else begin
if (FPedido.ID_ALMACEN >= 1) then
actListaAlmacenes.Checked := True
else if (FPedido.ID_OBRA >= 1) then
actListaObras.Checked := True
else
actOtro.Checked := True;
end;
RefrescarDireccion;
end;

View File

@ -1,77 +1,23 @@
inherited frViewPedidoProveedor: TfrViewPedidoProveedor
Width = 704
Height = 467
Width = 787
Height = 522
OnCreate = CustomViewCreate
OnDestroy = CustomViewDestroy
ExplicitWidth = 704
ExplicitHeight = 467
ExplicitWidth = 787
ExplicitHeight = 522
object dxLayoutControl1: TdxLayoutControl
Left = 0
Top = 0
Width = 704
Height = 467
Width = 787
Height = 522
Align = alClient
ParentBackground = True
TabOrder = 0
AutoContentSizes = [acsWidth, acsHeight]
ExplicitWidth = 908
DesignSize = (
704
467)
inline frViewProveedorPedido: TfrViewDatosYSeleccionProveedor
Left = 339
Top = 28
Width = 310
Height = 215
Font.Charset = DEFAULT_CHARSET
Font.Color = clWindowText
Font.Height = -11
Font.Name = 'Tahoma'
Font.Style = []
ParentFont = False
TabOrder = 10
ReadOnly = False
ExplicitLeft = 339
ExplicitTop = 28
ExplicitWidth = 310
ExplicitHeight = 215
inherited dxLayoutControl1: TdxLayoutControl
Width = 310
Height = 215
Align = alClient
ExplicitWidth = 310
ExplicitHeight = 215
inherited edtlNombre: TcxDBTextEdit
ExplicitWidth = 185
Width = 185
end
inherited edtNIFCIF: TcxDBTextEdit
ExplicitWidth = 562
Width = 562
end
inherited edtCalle: TcxDBTextEdit
ExplicitWidth = 562
Width = 562
end
inherited edtPoblacion: TcxDBTextEdit
ExplicitWidth = 46
Width = 46
end
inherited edtProvincia: TcxDBTextEdit
ExplicitWidth = 327
Width = 327
end
inherited edtCodigoPostal: TcxDBTextEdit
Left = 262
ExplicitLeft = 262
ExplicitWidth = 71
Width = 71
end
inherited Button3: TBitBtn
Left = 135
ExplicitLeft = 135
end
end
end
787
522)
object edtFechaPedido: TcxDBDateEdit
Left = 137
Top = 55
@ -135,8 +81,8 @@ inherited frViewPedidoProveedor: TfrViewPedidoProveedor
Width = 55
end
object memObservaciones: TcxDBMemo
Left = 339
Top = 279
Left = 407
Top = 213
Anchors = [akLeft, akTop, akRight, akBottom]
DataBinding.DataField = 'OBSERVACIONES'
DataBinding.DataSource = DADataSource
@ -149,8 +95,8 @@ inherited frViewPedidoProveedor: TfrViewPedidoProveedor
StyleFocused.LookAndFeel.NativeStyle = True
StyleHot.LookAndFeel.NativeStyle = True
TabOrder = 11
Height = 133
Width = 530
Height = 287
Width = 333
end
object eReferencia: TcxDBTextEdit
Left = 137
@ -177,8 +123,8 @@ inherited frViewPedidoProveedor: TfrViewPedidoProveedor
inline frViewDireccionEntregaPedidoProv1: TfrViewDireccionEntregaPedidoProv
Left = 22
Top = 279
Width = 445
Height = 166
Width = 325
Height = 194
Font.Charset = DEFAULT_CHARSET
Font.Color = clWindowText
Font.Height = -11
@ -189,11 +135,11 @@ inherited frViewPedidoProveedor: TfrViewPedidoProveedor
ReadOnly = False
ExplicitLeft = 22
ExplicitTop = 279
ExplicitWidth = 445
ExplicitHeight = 166
ExplicitWidth = 325
ExplicitHeight = 194
inherited dxLayoutControl1: TdxLayoutControl
Width = 445
Height = 166
Width = 325
Height = 194
ExplicitWidth = 445
ExplicitHeight = 166
inherited rdxDestino1: TRadioButton
@ -204,15 +150,19 @@ inherited frViewPedidoProveedor: TfrViewPedidoProveedor
Width = 287
ExplicitWidth = 287
end
inherited cbLista: TcxDBLookupComboBox
ExplicitWidth = 112
Width = 112
inherited cbListaAlmacenes: TcxDBLookupComboBox
ExplicitWidth = 425
Width = 425
end
inherited bModificar: TBitBtn
Left = 149
Top = 131
ExplicitLeft = 149
ExplicitTop = 131
Left = 217
Top = 159
ExplicitLeft = 217
ExplicitTop = 159
end
inherited txtDireccion: TStaticText
Height = 177
ExplicitHeight = 177
end
end
inherited ActionList1: TActionList
@ -255,7 +205,7 @@ inherited frViewPedidoProveedor: TfrViewPedidoProveedor
Width = 32
end
object bFormasPago: TButton
Left = 177
Left = 245
Top = 82
Width = 132
Height = 21
@ -308,13 +258,77 @@ inherited frViewPedidoProveedor: TfrViewPedidoProveedor
Width = 78
end
object bVerPedidoCliente: TButton
Left = 177
Left = 245
Top = 109
Width = 132
Height = 23
Action = actVerPedidoCli
TabOrder = 5
end
inline frViewProveedorPedido1: TfrViewProveedorPedido
Left = 407
Top = 28
Width = 92
Height = 149
Font.Charset = DEFAULT_CHARSET
Font.Color = clWindowText
Font.Height = -11
Font.Name = 'Tahoma'
Font.Style = []
ParentFont = False
TabOrder = 10
ReadOnly = False
ExplicitLeft = 407
ExplicitTop = 28
ExplicitWidth = 92
ExplicitHeight = 149
inherited dxLayoutControl1: TdxLayoutControl
Width = 92
Height = 266
ExplicitWidth = 454
ExplicitHeight = 266
inherited edtlNombre: TcxDBTextEdit
ExplicitWidth = 276
Width = 276
end
inherited edtNIFCIF: TcxDBTextEdit
ExplicitWidth = 276
Width = 276
end
inherited edtCalle: TcxDBTextEdit
ExplicitWidth = 276
Width = 276
end
inherited edtPoblacion: TcxDBTextEdit
ExplicitWidth = 158
Width = 158
end
inherited edtProvincia: TcxDBTextEdit
ExplicitWidth = 276
Width = 276
end
inherited edtCodigoPostal: TcxDBTextEdit
Left = 266
ExplicitLeft = 266
end
inherited Button3: TBitBtn
Left = 150
ExplicitLeft = 150
end
inherited edtPersonaContacto: TcxDBTextEdit
ExplicitWidth = 585
Width = 585
end
inherited edtReferenciaAsignada: TcxDBTextEdit
Left = 227
ExplicitLeft = 227
end
inherited edtFax: TcxDBTextEdit
ExplicitWidth = 169
Width = 169
end
end
end
object dxLayoutControl1Group_Root: TdxLayoutGroup
ShowCaption = False
Hidden = True
@ -390,7 +404,6 @@ inherited frViewPedidoProveedor: TfrViewPedidoProveedor
end
object dxLayoutControl1Group5: TdxLayoutGroup
AutoAligns = [aaHorizontal]
AlignVert = avClient
Caption = 'Situaci'#243'n del pedido'
object dxLayoutControl1Item7: TdxLayoutItem
Caption = 'Enviado al prov. el d'#237'a:'
@ -411,8 +424,7 @@ inherited frViewPedidoProveedor: TfrViewPedidoProveedor
object dxLayoutControl1Group8: TdxLayoutGroup
AutoAligns = []
AlignHorz = ahClient
AlignVert = avClient
Caption = 'Direcci'#243'n de entrega'
Caption = 'Datos de la entrega'
object dxLayoutControl1Item8: TdxLayoutItem
AutoAligns = [aaHorizontal]
AlignVert = avClient
@ -433,11 +445,7 @@ inherited frViewPedidoProveedor: TfrViewPedidoProveedor
AlignHorz = ahClient
Caption = 'Datos del proveedor'
object dxLayoutControl1Item1: TdxLayoutItem
AutoAligns = [aaHorizontal]
AlignVert = avClient
Caption = 'frViewDatosYSeleccionProveedor1'
ShowCaption = False
Control = frViewProveedorPedido
Control = frViewProveedorPedido1
ControlOptions.AutoColor = True
ControlOptions.ShowBorder = False
end
@ -458,15 +466,15 @@ inherited frViewPedidoProveedor: TfrViewPedidoProveedor
end
object DADataSource: TDADataSource
Left = 24
Top = 40
Top = 8
end
object dsFormaPago: TDADataSource
Left = 56
Top = 8
end
object ActionList1: TActionList
Left = 24
Top = 72
Left = 88
Top = 8
object actVerPedidoCli: TAction
Caption = 'Ver pedido de cliente...'
OnExecute = actVerPedidoCliExecute

View File

@ -12,7 +12,8 @@ uses
cxTextEdit, cxMaskEdit, cxCalendar, dxLayoutControl, cxControls, cxMemo,
uViewDireccionEntregaPedidoProv, cxLookupEdit, cxDBLookupEdit,
// uBizPedidosCliente, uPedidosClienteController,
cxDBLookupComboBox, uFormasPagoController, ActnList, uDAInterfaces, uBizFormasPago;
cxDBLookupComboBox, uFormasPagoController, ActnList, uDAInterfaces, uBizFormasPago,
uViewProveedorPedido;
type
IViewPedidoProveedor = interface(IViewBase)
@ -28,10 +29,8 @@ type
TfrViewPedidoProveedor = class(TfrViewBase, IViewPedidoProveedor)
DADataSource: TDADataSource;
frViewProveedorPedido: TfrViewDatosYSeleccionProveedor;
dxLayoutControl1Group_Root: TdxLayoutGroup;
dxLayoutControl1: TdxLayoutControl;
dxLayoutControl1Item1: TdxLayoutItem;
dxLayoutControl1Item2: TdxLayoutItem;
edtFechaPedido: TcxDBDateEdit;
dxLayoutControl1Item4: TdxLayoutItem;
@ -67,6 +66,8 @@ type
dxLayoutControl1Group10: TdxLayoutGroup;
ActionList1: TActionList;
actVerPedidoCli: TAction;
dxLayoutControl1Item1: TdxLayoutItem;
frViewProveedorPedido1: TfrViewProveedorPedido;
procedure CustomViewCreate(Sender: TObject);
procedure CustomViewDestroy(Sender: TObject);
procedure bFormasPagoClick(Sender: TObject);
@ -94,6 +95,7 @@ type
implementation
{$R *.dfm}
{ TfrViewPedidoProveedor }
@ -123,7 +125,7 @@ begin
inherited;
FFormasPago := Nil;
FFormasPagoController := TFormasPagoController.Create;
FViewProveedorPedido := frViewProveedorPedido;
FViewProveedorPedido := frViewProveedorPedido1;
FViewProveedorPedido.MsgElegirProveedor := 'Elija el proveedor al que se le realizará el pedido.';
eReferencia.Enabled := False;
// eReferenciaPedidoCli.Enabled := False;
@ -147,7 +149,7 @@ begin
if (Application.MessageBox('Si cambia de proveedor, se eliminarán todos sus artículos del pedido actual, ¿Desea continuar?', 'Atención', MB_YESNO) = IDNO) then
Exit;
end;
frViewProveedorPedido.actElegirContacto.Execute;
frViewProveedorPedido1.actElegirContacto.Execute;
end;
procedure TfrViewPedidoProveedor.frViewProveedorPedidoButton2Click(Sender: TObject);
@ -158,7 +160,7 @@ begin
if (Application.MessageBox('Si cambia de proveedor, se eliminarán todos sus artículos del pedido actual, ¿Desea continuar?', 'Atención', MB_YESNO) = IDNO) then
Exit;
end;
frViewProveedorPedido.actAnadirContacto.Execute;
frViewProveedorPedido1.actAnadirContacto.Execute;
end;
function TfrViewPedidoProveedor.GetPedido: IBizPedidoProveedor;
@ -204,7 +206,7 @@ begin
// FPedidoCliAsociado := NIL;
end;
frViewProveedorPedido.Proveedor := FPedido.Proveedor;
frViewProveedorPedido1.Proveedor := FPedido.Proveedor;
frViewDireccionEntregaPedidoProv1.PedidoProveedor := FPedido;
end;

View File

@ -0,0 +1,183 @@
inherited frViewProveedorPedido: TfrViewProveedorPedido
Width = 473
Height = 287
ExplicitWidth = 473
ExplicitHeight = 287
inherited dxLayoutControl1: TdxLayoutControl
Width = 473
Height = 273
ExplicitWidth = 473
ExplicitHeight = 273
DesignSize = (
473
273)
inherited edtlNombre: TcxDBTextEdit
Left = 118
ExplicitLeft = 118
end
inherited edtNIFCIF: TcxDBTextEdit
Left = 118
Top = 153
TabOrder = 7
ExplicitLeft = 118
ExplicitTop = 153
end
inherited edtCalle: TcxDBTextEdit
Left = 118
Top = 180
TabOrder = 8
ExplicitLeft = 118
ExplicitTop = 180
end
inherited edtPoblacion: TcxDBTextEdit
Left = 118
Top = 207
TabOrder = 9
ExplicitLeft = 118
ExplicitTop = 207
end
inherited edtProvincia: TcxDBTextEdit
Left = 118
Top = 234
TabOrder = 11
ExplicitLeft = 118
ExplicitTop = 234
end
inherited edtCodigoPostal: TcxDBTextEdit
Left = 381
Top = 207
TabOrder = 10
ExplicitLeft = 381
ExplicitTop = 207
end
inherited Button3: TBitBtn
Left = 265
Top = 122
TabOrder = 6
ExplicitLeft = 265
ExplicitTop = 122
end
object edtPersonaContacto: TcxDBTextEdit [9]
Left = 118
Top = 95
Anchors = [akLeft, akTop, akRight]
AutoSize = False
DataBinding.DataField = 'PERSONA_CONTACTO'
DataBinding.DataSource = DADataSource
Enabled = False
ParentFont = False
Properties.ReadOnly = True
Properties.UseLeftAlignmentOnEditing = False
Style.BorderColor = clWindowFrame
Style.BorderStyle = ebs3D
Style.HotTrack = False
Style.LookAndFeel.NativeStyle = True
StyleDisabled.LookAndFeel.NativeStyle = True
StyleDisabled.TextColor = clWindowText
StyleFocused.LookAndFeel.NativeStyle = True
StyleHot.LookAndFeel.NativeStyle = True
TabOrder = 5
Height = 21
Width = 585
end
object edtReferenciaAsignada: TcxDBTextEdit [10]
Left = 342
Top = 68
Anchors = [akLeft, akTop, akRight]
AutoSize = False
DataBinding.DataField = 'CODIGO_ASIGNADO'
DataBinding.DataSource = DADataSource
Enabled = False
ParentFont = False
Properties.ReadOnly = True
Properties.UseLeftAlignmentOnEditing = False
Style.BorderColor = clWindowFrame
Style.BorderStyle = ebs3D
Style.HotTrack = False
Style.LookAndFeel.NativeStyle = True
StyleDisabled.LookAndFeel.NativeStyle = True
StyleDisabled.TextColor = clWindowText
StyleFocused.LookAndFeel.NativeStyle = True
StyleHot.LookAndFeel.NativeStyle = True
TabOrder = 4
Height = 21
Width = 121
end
object edtFax: TcxDBTextEdit [11]
Left = 118
Top = 68
Anchors = [akLeft, akTop, akRight]
AutoSize = False
DataBinding.DataField = 'FAX'
DataBinding.DataSource = DADataSource
Enabled = False
ParentFont = False
Properties.ReadOnly = True
Properties.UseLeftAlignmentOnEditing = False
Style.BorderColor = clWindowFrame
Style.BorderStyle = ebs3D
Style.HotTrack = False
Style.LookAndFeel.NativeStyle = True
StyleDisabled.LookAndFeel.NativeStyle = True
StyleDisabled.TextColor = clWindowText
StyleFocused.LookAndFeel.NativeStyle = True
StyleHot.LookAndFeel.NativeStyle = True
TabOrder = 3
Height = 21
Width = 169
end
inherited dxLayoutControl1Group_Root: TdxLayoutGroup
object dxLayoutControl1Group4: TdxLayoutGroup [2]
ShowCaption = False
Hidden = True
LayoutDirection = ldHorizontal
ShowBorder = False
object dxLayoutControl1Item13: TdxLayoutItem
AutoAligns = [aaVertical]
AlignHorz = ahClient
Caption = 'N'#250'mero de fax:'
Control = edtFax
ControlOptions.ShowBorder = False
end
object dxLayoutControl1Item11: TdxLayoutItem
AutoAligns = [aaVertical]
AlignHorz = ahRight
Caption = 'C'#243'd. cliente:'
Control = edtReferenciaAsignada
ControlOptions.ShowBorder = False
end
end
object dxLayoutControl1Item10: TdxLayoutItem [3]
Caption = 'Persona de contacto:'
Control = edtPersonaContacto
ControlOptions.ShowBorder = False
end
inherited dxLayoutControl1Item9: TdxLayoutItem [4]
end
inherited dxLayoutControl1Item2: TdxLayoutItem [5]
Visible = False
end
inherited dxLayoutControl1Item3: TdxLayoutItem [6]
Visible = False
end
inherited dxLayoutControl1Group2: TdxLayoutGroup [7]
Visible = False
end
inherited dxLayoutControl1Item5: TdxLayoutItem [8]
Visible = False
end
end
end
inherited DADataSource: TDADataSource
Left = 288
Top = 8
end
inherited ActionList1: TActionList
Left = 320
Top = 8
end
inherited PngImageList: TPngImageList
Left = 352
Top = 8
end
end

View File

@ -0,0 +1,31 @@
unit uViewProveedorPedido;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, uViewDatosYSeleccionProveedor, ImgList, PngImageList, ActnList, DB,
uDAInterfaces, uDADataTable, dxLayoutControl, StdCtrls, Buttons, cxContainer,
cxEdit, cxTextEdit, cxDBEdit, cxControls;
type
TfrViewProveedorPedido = class(TfrViewDatosYSeleccionProveedor)
dxLayoutControl1Item10: TdxLayoutItem;
edtPersonaContacto: TcxDBTextEdit;
dxLayoutControl1Item11: TdxLayoutItem;
edtReferenciaAsignada: TcxDBTextEdit;
dxLayoutControl1Item13: TdxLayoutItem;
edtFax: TcxDBTextEdit;
dxLayoutControl1Group4: TdxLayoutGroup;
private
{ Private declarations }
public
{ Public declarations }
end;
implementation
{$R *.dfm}
end.

View File

@ -42,7 +42,7 @@ inherited frViewPresupuestoCliente: TfrViewPresupuestoCliente
end
object memObservaciones: TcxDBMemo
Left = 22
Top = 276
Top = 220
Anchors = [akLeft, akTop, akRight, akBottom]
DataBinding.DataField = 'OBSERVACIONES'
DataBinding.DataSource = DADataSource
@ -58,7 +58,7 @@ inherited frViewPresupuestoCliente: TfrViewPresupuestoCliente
StyleFocused.LookAndFeel.NativeStyle = True
StyleHot.LookAndFeel.Kind = lfStandard
StyleHot.LookAndFeel.NativeStyle = True
TabOrder = 10
TabOrder = 8
Height = 253
Width = 186
end
@ -89,7 +89,7 @@ inherited frViewPresupuestoCliente: TfrViewPresupuestoCliente
Width = 122
end
inline frViewClientePresupuesto: TfrViewDatosYSeleccionCliente
Left = 403
Left = 413
Top = 28
Width = 350
Height = 212
@ -101,7 +101,7 @@ inherited frViewPresupuestoCliente: TfrViewPresupuestoCliente
ParentFont = False
TabOrder = 9
ReadOnly = False
ExplicitLeft = 403
ExplicitLeft = 413
ExplicitTop = 28
inherited dxLayoutControl1: TdxLayoutControl
inherited edtlNombre: TcxDBTextEdit
@ -124,14 +124,6 @@ inherited frViewPresupuestoCliente: TfrViewPresupuestoCliente
ExplicitWidth = 327
Width = 327
end
inherited edtCodigoPostal: TcxDBTextEdit
Left = 249
ExplicitLeft = 249
end
inherited Button3: TBitBtn
Left = 139
ExplicitLeft = 139
end
end
inherited DADataSource: TDADataSource
Top = 72
@ -145,7 +137,7 @@ inherited frViewPresupuestoCliente: TfrViewPresupuestoCliente
end
object cbFormaPago: TcxDBLookupComboBox
Left = 123
Top = 190
Top = 163
DataBinding.DataField = 'ID_FORMA_PAGO'
DataBinding.DataSource = DADataSource
Properties.KeyFieldNames = 'ID'
@ -170,16 +162,16 @@ inherited frViewPresupuestoCliente: TfrViewPresupuestoCliente
StyleFocused.LookAndFeel.NativeStyle = True
StyleHot.LookAndFeel.Kind = lfStandard
StyleHot.LookAndFeel.NativeStyle = True
TabOrder = 7
TabOrder = 6
Width = 101
end
object bFormasPago: TButton
Left = 241
Top = 190
Left = 251
Top = 163
Width = 132
Height = 21
Caption = 'Ver las formas de pago...'
TabOrder = 8
TabOrder = 7
OnClick = bFormasPagoClick
end
object edtFechaDecision: TcxDBDateEdit
@ -230,8 +222,8 @@ inherited frViewPresupuestoCliente: TfrViewPresupuestoCliente
Width = 216
end
object cbClienteFinal: TcxDBButtonEdit
Left = 123
Top = 163
Left = 413
Top = 276
Anchors = [akLeft, akTop, akRight]
DataBinding.DataField = 'CLIENTE_FINAL'
DataBinding.DataSource = DADataSource
@ -256,7 +248,7 @@ inherited frViewPresupuestoCliente: TfrViewPresupuestoCliente
StyleFocused.LookAndFeel.NativeStyle = True
StyleHot.LookAndFeel.Kind = lfStandard
StyleHot.LookAndFeel.NativeStyle = True
TabOrder = 6
TabOrder = 10
Width = 227
end
object cbSituacion: TcxDBImageComboBox
@ -287,7 +279,7 @@ inherited frViewPresupuestoCliente: TfrViewPresupuestoCliente
Width = 121
end
object eReferenciaAux: TcxDBTextEdit
Left = 245
Left = 251
Top = 28
Anchors = [akLeft, akTop, akRight]
DataBinding.DataField = 'REFERENCIA_AUX'
@ -314,11 +306,11 @@ inherited frViewPresupuestoCliente: TfrViewPresupuestoCliente
object dxLayoutControl1Group_Root: TdxLayoutGroup
ShowCaption = False
Hidden = True
LayoutDirection = ldHorizontal
ShowBorder = False
object dxLayoutControl1Group10: TdxLayoutGroup
object dxLayoutControl1Group8: TdxLayoutGroup
ShowCaption = False
Hidden = True
LayoutDirection = ldHorizontal
ShowBorder = False
object dxLayoutControl1Group1: TdxLayoutGroup
AutoAligns = []
@ -363,11 +355,6 @@ inherited frViewPresupuestoCliente: TfrViewPresupuestoCliente
Control = cbSituacion
ControlOptions.ShowBorder = False
end
object dxLayoutControl1Item8: TdxLayoutItem
Caption = 'Cliente final:'
Control = cbClienteFinal
ControlOptions.ShowBorder = False
end
object dxLayoutControl1Group5: TdxLayoutGroup
ShowCaption = False
Visible = False
@ -390,6 +377,22 @@ inherited frViewPresupuestoCliente: TfrViewPresupuestoCliente
end
end
end
object dxLayoutControl1Group7: TdxLayoutGroup
AutoAligns = [aaHorizontal]
AlignVert = avClient
Caption = 'Observaciones'
object dxLayoutControl1Item6: TdxLayoutItem
AutoAligns = [aaHorizontal]
AlignVert = avClient
Control = memObservaciones
ControlOptions.ShowBorder = False
end
end
end
object dxLayoutControl1Group6: TdxLayoutGroup
ShowCaption = False
Hidden = True
ShowBorder = False
object dxLayoutControl1Group2: TdxLayoutGroup
AutoAligns = [aaVertical]
AlignHorz = ahClient
@ -400,16 +403,14 @@ inherited frViewPresupuestoCliente: TfrViewPresupuestoCliente
ControlOptions.ShowBorder = False
end
end
end
object dxLayoutControl1Group7: TdxLayoutGroup
AutoAligns = [aaHorizontal]
AlignVert = avClient
Caption = 'Observaciones'
object dxLayoutControl1Item6: TdxLayoutItem
AutoAligns = [aaHorizontal]
AlignVert = avClient
Control = memObservaciones
ControlOptions.ShowBorder = False
object dxLayoutControl1Group4: TdxLayoutGroup
Caption = 'Cliente final'
object dxLayoutControl1Item8: TdxLayoutItem
Caption = 'Cliente final:'
ShowCaption = False
Control = cbClienteFinal
ControlOptions.ShowBorder = False
end
end
end
end

View File

@ -49,7 +49,6 @@ type
bFormasPago: TButton;
dxLayoutControl1Group5: TdxLayoutGroup;
dsFormaPago: TDADataSource;
dxLayoutControl1Group10: TdxLayoutGroup;
dxLayoutControl1Item7: TdxLayoutItem;
edtFechaDecision: TcxDBDateEdit;
dxLayoutControl1Item15: TdxLayoutItem;
@ -61,6 +60,9 @@ type
dxLayoutControl1Item9: TdxLayoutItem;
eReferenciaAux: TcxDBTextEdit;
dxLayoutControl1Group3: TdxLayoutGroup;
dxLayoutControl1Group4: TdxLayoutGroup;
dxLayoutControl1Group6: TdxLayoutGroup;
dxLayoutControl1Group8: TdxLayoutGroup;
procedure CustomViewCreate(Sender: TObject);
procedure CustomViewDestroy(Sender: TObject);
procedure actElegirDireccionExecute(Sender: TObject);

Binary file not shown.

View File

@ -96,8 +96,6 @@ uses
schUsuariosClient_Intf in '..\ApplicationBase\Usuarios\Model\schUsuariosClient_Intf.pas',
schUsuariosServer_Intf in '..\ApplicationBase\Usuarios\Model\schUsuariosServer_Intf.pas',
uRptAlbaranesCliente_Server in '..\Modulos\Albaranes de cliente\Reports\uRptAlbaranesCliente_Server.pas' {RptAlbaranesCliente: TDataModule},
schEmpresasClient_Intf in '..\ApplicationBase\Empresas\Model\schEmpresasClient_Intf.pas',
schEmpresasServer_Intf in '..\ApplicationBase\Empresas\Model\schEmpresasServer_Intf.pas',
uStringsUtils in '..\Base\Utiles\uStringsUtils.pas',
FactuGES_Intf in '..\Servicios\FactuGES_Intf.pas',
FactuGES_Invk in '..\Servicios\FactuGES_Invk.pas',
@ -122,7 +120,9 @@ uses
uRptWordPedidoProveedor in '..\Modulos\Pedidos a proveedor\Reports\uRptWordPedidoProveedor.pas' {RptWordPedidoProveedor: TDataModule},
srvObras_Impl in '..\Modulos\Obras\Servidor\srvObras_Impl.pas',
schObrasClient_Intf in '..\Modulos\Obras\Model\schObrasClient_Intf.pas',
schObrasServer_Intf in '..\Modulos\Obras\Model\schObrasServer_Intf.pas';
schObrasServer_Intf in '..\Modulos\Obras\Model\schObrasServer_Intf.pas',
schEmpresasClient_Intf in '..\ApplicationBase\Empresas\Model\schEmpresasClient_Intf.pas',
schEmpresasServer_Intf in '..\ApplicationBase\Empresas\Model\schEmpresasServer_Intf.pas';
{$R *.res}
{$R ..\Servicios\RODLFile.res}

View File

@ -14,7 +14,7 @@ BEGIN
BEGIN
VALUE "FileVersion", "1.0.2.0\0"
VALUE "ProductVersion", "1.0.2.0\0"
VALUE "CompileDate", "domingo, 23 de marzo de 2008 20:42\0"
VALUE "CompileDate", "lunes, 24 de marzo de 2008 21:33\0"
END
END
BLOCK "VarFileInfo"

View File

@ -3,8 +3,8 @@ object fServerForm: TfServerForm
Top = 611
BorderStyle = bsDialog
Caption = 'FactuGES Server'
ClientHeight = 144
ClientWidth = 371
ClientHeight = 140
ClientWidth = 267
Color = clBtnFace
Font.Charset = DEFAULT_CHARSET
Font.Color = clWindowText
@ -19,24 +19,26 @@ object fServerForm: TfServerForm
object JvGradient1: TJvGradient
Left = 0
Top = 57
Width = 371
Width = 267
Height = 4
Align = alTop
StartColor = 2971346
EndColor = 4828405
ExplicitWidth = 371
end
object Panel1: TPanel
Left = 0
Top = 0
Width = 371
Width = 267
Height = 57
Align = alTop
BevelOuter = bvNone
TabOrder = 0
ExplicitWidth = 371
object Image1: TImage
Left = 0
Top = 0
Width = 371
Width = 267
Height = 57
Align = alClient
Center = True
@ -986,6 +988,7 @@ object fServerForm: TfServerForm
1DEF98267859F0774F0B64071F444C5CA82B88274DE94A5B3AB02E58829BE11C
5E82E499A42A46048B79C567620DE1092D0074043B9BCB781AFAD02151B07719
0DE44000003B}
ExplicitWidth = 371
end
end
object PopupMenu1: TPopupMenu