SE adaptan facturas de proveedor y facturas de cliente para la nueva politica de funcionamiento (si la forma de pago no tiene plazos asignados, meter fecha de vencimiento y en caso contrario se desactiva la fecha de vencimiento)

git-svn-id: https://192.168.0.254/svn/Proyectos.Acana_FactuGES2/trunk@364 f4e31baf-9722-1c47-927c-6f952f962d4b
This commit is contained in:
David Arranz 2008-12-17 17:24:38 +00:00
parent 8e56b165bb
commit d2bba12ad7
20 changed files with 507 additions and 203 deletions

View File

@ -878,7 +878,8 @@ CREATE TABLE FACTURAS_CLIENTE (
RECARGO_EQUIVALENCIA TIPO_BOOLEANO, RECARGO_EQUIVALENCIA TIPO_BOOLEANO,
ID_COMISION_LIQUIDADA TIPO_ID, ID_COMISION_LIQUIDADA TIPO_ID,
IGNORAR_CONTABILIDAD SMALLINT, IGNORAR_CONTABILIDAD SMALLINT,
ID_TIENDA TIPO_ID ID_TIENDA TIPO_ID,
FECHA_VENCIMIENTO DATE
); );
CREATE TABLE FACTURAS_CLIENTE_DETALLES ( CREATE TABLE FACTURAS_CLIENTE_DETALLES (
@ -2318,6 +2319,7 @@ REFERENCIA,
TIPO, TIPO,
ID_COMISION_LIQUIDADA, ID_COMISION_LIQUIDADA,
FECHA_FACTURA, FECHA_FACTURA,
FECHA_VENCIMIENTO,
SITUACION, SITUACION,
BASE_IMPONIBLE, BASE_IMPONIBLE,
DESCUENTO, DESCUENTO,
@ -2359,6 +2361,7 @@ SELECT FACTURAS_CLIENTE.ID,
CASE WHEN (FACTURAS_CLIENTE.IMPORTE_TOTAL < 0) THEN 'A' ELSE 'F' END AS TIPO, CASE WHEN (FACTURAS_CLIENTE.IMPORTE_TOTAL < 0) THEN 'A' ELSE 'F' END AS TIPO,
FACTURAS_CLIENTE.ID_COMISION_LIQUIDADA, FACTURAS_CLIENTE.ID_COMISION_LIQUIDADA,
FACTURAS_CLIENTE.FECHA_FACTURA, FACTURAS_CLIENTE.FECHA_FACTURA,
FACTURAS_CLIENTE.FECHA_VENCIMIENTO,
TRIM(V_FAC_CLI_SITUACION.SITUACION), TRIM(V_FAC_CLI_SITUACION.SITUACION),
FACTURAS_CLIENTE.BASE_IMPONIBLE, FACTURAS_CLIENTE.BASE_IMPONIBLE,
FACTURAS_CLIENTE.DESCUENTO, FACTURAS_CLIENTE.DESCUENTO,

View File

@ -622,6 +622,9 @@ begin
end; end;
function TFacturasClienteController.ValidarFactura(AFactura: IBizFacturaCliente): Boolean; function TFacturasClienteController.ValidarFactura(AFactura: IBizFacturaCliente): Boolean;
var
AFormaPago: IBizFormaPago;
begin begin
Result := False; Result := False;
@ -648,6 +651,25 @@ begin
if (AFactura.Detalles.DataTable.RecordCount = 0) then if (AFactura.Detalles.DataTable.RecordCount = 0) then
raise Exception.Create('La factura debe tener al menos un concepto en su contenido'); raise Exception.Create('La factura debe tener al menos un concepto en su contenido');
if (AFactura.ID_FORMA_PAGO = 0) then
raise Exception.Create('Debe indicar una forma de pago para esta factura');
//De esta forma obligaremos siempre a tener un recibo asociado a la factura,
//porque si la forma de pago no tiene plazos es obligatorio la fecha de vencimiento
with TFormasPagoController.Create do
begin
try
AFormaPago := Buscar(AFactura.ID_FORMA_PAGO);
AFormaPago.DataTable.Active := True;
if (AFormaPago.Plazos.RecordCount = 0)
and (EsFechaVacia(AFactura.FECHA_VENCIMIENTO)) then
raise Exception.Create('Debe indicar una fecha de vencimiento para esta factura');
finally
AFormaPago := NIL;
Free;
end;
end;
if (AFactura.IGNORAR_CONTABILIDAD = 0) and ((AFactura.Cliente.SubCuentas.ID < 1) if (AFactura.IGNORAR_CONTABILIDAD = 0) and ((AFactura.Cliente.SubCuentas.ID < 1)
//REPASAR //REPASAR
or (AFactura.Cliente.SubCuentas.ID_EJERCICIO <> AppFactuGES.EjercicioActivo.ID)) then or (AFactura.Cliente.SubCuentas.ID_EJERCICIO <> AppFactuGES.EjercicioActivo.ID)) then
@ -1114,6 +1136,9 @@ var
ARecibos: IBizRecibosCliente; ARecibos: IBizRecibosCliente;
AFechaVencimiento: TDateTime; AFechaVencimiento: TDateTime;
i: Integer; i: Integer;
ADiaVencimiento: Integer;
ADiasMas: Integer;
begin begin
if not Assigned(AFactura) then if not Assigned(AFactura) then
Exit; Exit;
@ -1132,13 +1157,14 @@ begin
ARecibos := ARecibosClienteController.BuscarRecibosFactura(AFactura.ID); ARecibos := ARecibosClienteController.BuscarRecibosFactura(AFactura.ID);
ARecibosClienteController.EliminarTodo(ARecibos); ARecibosClienteController.EliminarTodo(ARecibos);
//Vamos a generar todos los recibos necesarios para la factura //Se cambia la lógica a peticion de acana, en el caso de meter una fecha de vencimiento,
//los plazos de la forma de pago no tendrán efecto, se generará un recibo con el 100% y fecha de vencimiento
//de la factura.
With AFormaPago.Plazos.DataTable do With AFormaPago.Plazos.DataTable do
begin begin
i := 1; i := 1;
First; First;
while not eof do repeat
begin
ARecibos := ARecibosClienteController.Nuevo; ARecibos := ARecibosClienteController.Nuevo;
ARecibos.Edit; ARecibos.Edit;
ARecibos.ID_FACTURA := AFactura.ID; ARecibos.ID_FACTURA := AFactura.ID;
@ -1152,32 +1178,40 @@ begin
ARecibos.POBLACION := AFactura.POBLACION; ARecibos.POBLACION := AFactura.POBLACION;
ARecibos.PROVINCIA := AFactura.PROVINCIA; ARecibos.PROVINCIA := AFactura.PROVINCIA;
ARecibos.CODIGO_POSTAL := AFactura.CODIGO_POSTAL; ARecibos.CODIGO_POSTAL := AFactura.CODIGO_POSTAL;
ARecibos.FECHA_EMISION := AFactura.FECHA_FACTURA;
AFechaVencimiento := AFactura.FECHA_FACTURA + AFormaPago.Plazos.NUM_DIAS; if AFormaPago.Plazos.RecordCount < 1 then
if (AFactura.Cliente.VENCIMIENTO_FACTURAS <> 0) then
begin begin
if DayOf(AFechaVencimiento) > AFactura.Cliente.VENCIMIENTO_FACTURAS then ARecibos.FECHA_VENCIMIENTO := AFactura.FECHA_VENCIMIENTO;
begin ARecibos.IMPORTE := AFactura.IMPORTE_TOTAL;
AFechaVencimiento := IncDay(AFechaVencimiento, (DaysInMonth(AFechaVencimiento) - DayOf(AFechaVencimiento))); end
AFechaVencimiento := IncDay(AFechaVencimiento, AFactura.Cliente.VENCIMIENTO_FACTURAS); else
end begin
else AFechaVencimiento := AFactura.FECHA_FACTURA + AFormaPago.Plazos.NUM_DIAS;
AFechaVencimiento := IncDay(AFechaVencimiento, (AFactura.Cliente.VENCIMIENTO_FACTURAS - DayOf(AFechaVencimiento))); ADiasMas := 0;
if (AFactura.Cliente.VENCIMIENTO_FACTURAS <> 0) then
begin
ADiaVencimiento := DayOf(AFechaVencimiento);
while (ADiaVencimiento <> AFactura.Cliente.VENCIMIENTO_FACTURAS) do
begin
if ADiaVencimiento = DaysInMonth(AFechaVencimiento) then
ADiaVencimiento := 1
else
Inc(ADiaVencimiento);
Inc(ADiasMas);
end;
end;
AFechaVencimiento := IncDay(AFechaVencimiento, ADiasMas);
ARecibos.FECHA_VENCIMIENTO := AFechaVencimiento;
ARecibos.IMPORTE := AFactura.IMPORTE_TOTAL * (AFormaPago.Plazos.PORCENTAJE / 100);
end; end;
//Comprobamos que la fecha de vencimiento no sea febrero si es asi hay que tratarlo
if (AFactura.Cliente.VENCIMIENTO_FACTURAS > 28)
and (MonthOf(AFechaVencimiento) = 3) and (DayOf(AFechaVencimiento) < 3) then
AFechaVencimiento := IncDay(AFechaVencimiento, - DayOf(AFechaVencimiento));
ARecibos.FECHA_VENCIMIENTO := AFechaVencimiento;
ARecibos.IMPORTE := AFactura.IMPORTE_TOTAL * (AFormaPago.Plazos.PORCENTAJE / 100);
ARecibos.DESCRIPCION := 'RECIBO ' + ARecibos.REFERENCIA + ' - ' + CifraToLetras(ARecibos.IMPORTE); ARecibos.DESCRIPCION := 'RECIBO ' + ARecibos.REFERENCIA + ' - ' + CifraToLetras(ARecibos.IMPORTE);
ARecibosClienteController.Guardar(ARecibos); ARecibosClienteController.Guardar(ARecibos);
Inc(i); Inc(i);
Next; Next;
end; until (eof);
end; end;
//Liberamos //Liberamos

View File

@ -65,6 +65,10 @@ inherited DataModuleFacturasCliente: TDataModuleFacturasCliente
DisplayLabel = 'Fecha de las factura' DisplayLabel = 'Fecha de las factura'
DictionaryEntry = 'FacturasCliente_FECHA_FACTURA' DictionaryEntry = 'FacturasCliente_FECHA_FACTURA'
end end
item
Name = 'FECHA_VENCIMIENTO'
DataType = datDateTime
end
item item
Name = 'SITUACION' Name = 'SITUACION'
DataType = datString DataType = datString

View File

@ -9,8 +9,8 @@ const
{ Data table rules ids { Data table rules ids
Feel free to change them to something more human readable Feel free to change them to something more human readable
but make sure they are unique in the context of your application } but make sure they are unique in the context of your application }
RID_FacturasCliente = '{AE5A4A76-8A04-4005-A949-58C1F079D651}'; RID_FacturasCliente = '{0B1914D0-B113-4995-B702-5A94444CE70C}';
RID_FacturasCliente_Detalles = '{A6BF3706-DC34-41F3-8469-835D382D23D8}'; RID_FacturasCliente_Detalles = '{44FAB69F-B375-47FE-8787-B5B1A305A0B6}';
{ Data table names } { Data table names }
nme_FacturasCliente = 'FacturasCliente'; nme_FacturasCliente = 'FacturasCliente';
@ -23,6 +23,7 @@ const
fld_FacturasClienteTIPO = 'TIPO'; fld_FacturasClienteTIPO = 'TIPO';
fld_FacturasClienteID_COMISION_LIQUIDADA = 'ID_COMISION_LIQUIDADA'; fld_FacturasClienteID_COMISION_LIQUIDADA = 'ID_COMISION_LIQUIDADA';
fld_FacturasClienteFECHA_FACTURA = 'FECHA_FACTURA'; fld_FacturasClienteFECHA_FACTURA = 'FECHA_FACTURA';
fld_FacturasClienteFECHA_VENCIMIENTO = 'FECHA_VENCIMIENTO';
fld_FacturasClienteSITUACION = 'SITUACION'; fld_FacturasClienteSITUACION = 'SITUACION';
fld_FacturasClienteBASE_IMPONIBLE = 'BASE_IMPONIBLE'; fld_FacturasClienteBASE_IMPONIBLE = 'BASE_IMPONIBLE';
fld_FacturasClienteDESCUENTO = 'DESCUENTO'; fld_FacturasClienteDESCUENTO = 'DESCUENTO';
@ -65,40 +66,41 @@ const
idx_FacturasClienteTIPO = 3; idx_FacturasClienteTIPO = 3;
idx_FacturasClienteID_COMISION_LIQUIDADA = 4; idx_FacturasClienteID_COMISION_LIQUIDADA = 4;
idx_FacturasClienteFECHA_FACTURA = 5; idx_FacturasClienteFECHA_FACTURA = 5;
idx_FacturasClienteSITUACION = 6; idx_FacturasClienteFECHA_VENCIMIENTO = 6;
idx_FacturasClienteBASE_IMPONIBLE = 7; idx_FacturasClienteSITUACION = 7;
idx_FacturasClienteDESCUENTO = 8; idx_FacturasClienteBASE_IMPONIBLE = 8;
idx_FacturasClienteIMPORTE_DESCUENTO = 9; idx_FacturasClienteDESCUENTO = 9;
idx_FacturasClienteIVA = 10; idx_FacturasClienteIMPORTE_DESCUENTO = 10;
idx_FacturasClienteIMPORTE_IVA = 11; idx_FacturasClienteIVA = 11;
idx_FacturasClienteRE = 12; idx_FacturasClienteIMPORTE_IVA = 12;
idx_FacturasClienteIMPORTE_RE = 13; idx_FacturasClienteRE = 13;
idx_FacturasClienteIMPORTE_TOTAL = 14; idx_FacturasClienteIMPORTE_RE = 14;
idx_FacturasClienteOBSERVACIONES = 15; idx_FacturasClienteIMPORTE_TOTAL = 15;
idx_FacturasClienteID_CLIENTE = 16; idx_FacturasClienteOBSERVACIONES = 16;
idx_FacturasClienteNOMBRE_CLIENTE = 17; idx_FacturasClienteID_CLIENTE = 17;
idx_FacturasClienteNOMBRE_COMERCIAL_CLIENTE = 18; idx_FacturasClienteNOMBRE_CLIENTE = 18;
idx_FacturasClienteNIF_CIF = 19; idx_FacturasClienteNOMBRE_COMERCIAL_CLIENTE = 19;
idx_FacturasClienteNOMBRE = 20; idx_FacturasClienteNIF_CIF = 20;
idx_FacturasClienteCALLE = 21; idx_FacturasClienteNOMBRE = 21;
idx_FacturasClientePOBLACION = 22; idx_FacturasClienteCALLE = 22;
idx_FacturasClientePROVINCIA = 23; idx_FacturasClientePOBLACION = 23;
idx_FacturasClienteCODIGO_POSTAL = 24; idx_FacturasClientePROVINCIA = 24;
idx_FacturasClienteFECHA_ALTA = 25; idx_FacturasClienteCODIGO_POSTAL = 25;
idx_FacturasClienteFECHA_MODIFICACION = 26; idx_FacturasClienteFECHA_ALTA = 26;
idx_FacturasClienteUSUARIO = 27; idx_FacturasClienteFECHA_MODIFICACION = 27;
idx_FacturasClienteID_FORMA_PAGO = 28; idx_FacturasClienteUSUARIO = 28;
idx_FacturasClienteRECARGO_EQUIVALENCIA = 29; idx_FacturasClienteID_FORMA_PAGO = 29;
idx_FacturasClienteID_TIPO_IVA = 30; idx_FacturasClienteRECARGO_EQUIVALENCIA = 30;
idx_FacturasClienteIMPORTE_NETO = 31; idx_FacturasClienteID_TIPO_IVA = 31;
idx_FacturasClienteIMPORTE_PORTE = 32; idx_FacturasClienteIMPORTE_NETO = 32;
idx_FacturasClienteID_AGENTE = 33; idx_FacturasClienteIMPORTE_PORTE = 33;
idx_FacturasClienteREFERENCIA_COMISION = 34; idx_FacturasClienteID_AGENTE = 34;
idx_FacturasClienteIGNORAR_CONTABILIDAD = 35; idx_FacturasClienteREFERENCIA_COMISION = 35;
idx_FacturasClienteID_TIENDA = 36; idx_FacturasClienteIGNORAR_CONTABILIDAD = 36;
idx_FacturasClienteTIENDA = 37; idx_FacturasClienteID_TIENDA = 37;
idx_FacturasClienteID_SUBCUENTA = 38; idx_FacturasClienteTIENDA = 38;
idx_FacturasClienteSUBCUENTA = 39; idx_FacturasClienteID_SUBCUENTA = 39;
idx_FacturasClienteSUBCUENTA = 40;
{ FacturasCliente_Detalles fields } { FacturasCliente_Detalles fields }
fld_FacturasCliente_DetallesID = 'ID'; fld_FacturasCliente_DetallesID = 'ID';
@ -135,7 +137,7 @@ const
type type
{ IFacturasCliente } { IFacturasCliente }
IFacturasCliente = interface(IDAStronglyTypedDataTable) IFacturasCliente = interface(IDAStronglyTypedDataTable)
['{89B45F34-48D2-4E4D-9C03-F1591EA6F05E}'] ['{0BE79A41-1EC4-48B2-AD7A-BD802A3B9ED5}']
{ Property getters and setters } { Property getters and setters }
function GetIDValue: Integer; function GetIDValue: Integer;
procedure SetIDValue(const aValue: Integer); procedure SetIDValue(const aValue: Integer);
@ -161,6 +163,10 @@ type
procedure SetFECHA_FACTURAValue(const aValue: DateTime); procedure SetFECHA_FACTURAValue(const aValue: DateTime);
function GetFECHA_FACTURAIsNull: Boolean; function GetFECHA_FACTURAIsNull: Boolean;
procedure SetFECHA_FACTURAIsNull(const aValue: Boolean); procedure SetFECHA_FACTURAIsNull(const aValue: Boolean);
function GetFECHA_VENCIMIENTOValue: DateTime;
procedure SetFECHA_VENCIMIENTOValue(const aValue: DateTime);
function GetFECHA_VENCIMIENTOIsNull: Boolean;
procedure SetFECHA_VENCIMIENTOIsNull(const aValue: Boolean);
function GetSITUACIONValue: String; function GetSITUACIONValue: String;
procedure SetSITUACIONValue(const aValue: String); procedure SetSITUACIONValue(const aValue: String);
function GetSITUACIONIsNull: Boolean; function GetSITUACIONIsNull: Boolean;
@ -311,6 +317,8 @@ type
property ID_COMISION_LIQUIDADAIsNull: Boolean read GetID_COMISION_LIQUIDADAIsNull write SetID_COMISION_LIQUIDADAIsNull; property ID_COMISION_LIQUIDADAIsNull: Boolean read GetID_COMISION_LIQUIDADAIsNull write SetID_COMISION_LIQUIDADAIsNull;
property FECHA_FACTURA: DateTime read GetFECHA_FACTURAValue write SetFECHA_FACTURAValue; property FECHA_FACTURA: DateTime read GetFECHA_FACTURAValue write SetFECHA_FACTURAValue;
property FECHA_FACTURAIsNull: Boolean read GetFECHA_FACTURAIsNull write SetFECHA_FACTURAIsNull; property FECHA_FACTURAIsNull: Boolean read GetFECHA_FACTURAIsNull write SetFECHA_FACTURAIsNull;
property FECHA_VENCIMIENTO: DateTime read GetFECHA_VENCIMIENTOValue write SetFECHA_VENCIMIENTOValue;
property FECHA_VENCIMIENTOIsNull: Boolean read GetFECHA_VENCIMIENTOIsNull write SetFECHA_VENCIMIENTOIsNull;
property SITUACION: String read GetSITUACIONValue write SetSITUACIONValue; property SITUACION: String read GetSITUACIONValue write SetSITUACIONValue;
property SITUACIONIsNull: Boolean read GetSITUACIONIsNull write SetSITUACIONIsNull; property SITUACIONIsNull: Boolean read GetSITUACIONIsNull write SetSITUACIONIsNull;
property BASE_IMPONIBLE: Currency read GetBASE_IMPONIBLEValue write SetBASE_IMPONIBLEValue; property BASE_IMPONIBLE: Currency read GetBASE_IMPONIBLEValue write SetBASE_IMPONIBLEValue;
@ -412,6 +420,10 @@ type
procedure SetFECHA_FACTURAValue(const aValue: DateTime); virtual; procedure SetFECHA_FACTURAValue(const aValue: DateTime); virtual;
function GetFECHA_FACTURAIsNull: Boolean; virtual; function GetFECHA_FACTURAIsNull: Boolean; virtual;
procedure SetFECHA_FACTURAIsNull(const aValue: Boolean); virtual; procedure SetFECHA_FACTURAIsNull(const aValue: Boolean); virtual;
function GetFECHA_VENCIMIENTOValue: DateTime; virtual;
procedure SetFECHA_VENCIMIENTOValue(const aValue: DateTime); virtual;
function GetFECHA_VENCIMIENTOIsNull: Boolean; virtual;
procedure SetFECHA_VENCIMIENTOIsNull(const aValue: Boolean); virtual;
function GetSITUACIONValue: String; virtual; function GetSITUACIONValue: String; virtual;
procedure SetSITUACIONValue(const aValue: String); virtual; procedure SetSITUACIONValue(const aValue: String); virtual;
function GetSITUACIONIsNull: Boolean; virtual; function GetSITUACIONIsNull: Boolean; virtual;
@ -561,6 +573,8 @@ type
property ID_COMISION_LIQUIDADAIsNull: Boolean read GetID_COMISION_LIQUIDADAIsNull write SetID_COMISION_LIQUIDADAIsNull; property ID_COMISION_LIQUIDADAIsNull: Boolean read GetID_COMISION_LIQUIDADAIsNull write SetID_COMISION_LIQUIDADAIsNull;
property FECHA_FACTURA: DateTime read GetFECHA_FACTURAValue write SetFECHA_FACTURAValue; property FECHA_FACTURA: DateTime read GetFECHA_FACTURAValue write SetFECHA_FACTURAValue;
property FECHA_FACTURAIsNull: Boolean read GetFECHA_FACTURAIsNull write SetFECHA_FACTURAIsNull; property FECHA_FACTURAIsNull: Boolean read GetFECHA_FACTURAIsNull write SetFECHA_FACTURAIsNull;
property FECHA_VENCIMIENTO: DateTime read GetFECHA_VENCIMIENTOValue write SetFECHA_VENCIMIENTOValue;
property FECHA_VENCIMIENTOIsNull: Boolean read GetFECHA_VENCIMIENTOIsNull write SetFECHA_VENCIMIENTOIsNull;
property SITUACION: String read GetSITUACIONValue write SetSITUACIONValue; property SITUACION: String read GetSITUACIONValue write SetSITUACIONValue;
property SITUACIONIsNull: Boolean read GetSITUACIONIsNull write SetSITUACIONIsNull; property SITUACIONIsNull: Boolean read GetSITUACIONIsNull write SetSITUACIONIsNull;
property BASE_IMPONIBLE: Currency read GetBASE_IMPONIBLEValue write SetBASE_IMPONIBLEValue; property BASE_IMPONIBLE: Currency read GetBASE_IMPONIBLEValue write SetBASE_IMPONIBLEValue;
@ -638,7 +652,7 @@ type
{ IFacturasCliente_Detalles } { IFacturasCliente_Detalles }
IFacturasCliente_Detalles = interface(IDAStronglyTypedDataTable) IFacturasCliente_Detalles = interface(IDAStronglyTypedDataTable)
['{6C713963-6140-464C-8BE5-4E547A0336EC}'] ['{B9257A51-DED8-42B0-82AD-2B683FCDCBE9}']
{ Property getters and setters } { Property getters and setters }
function GetIDValue: Integer; function GetIDValue: Integer;
procedure SetIDValue(const aValue: Integer); procedure SetIDValue(const aValue: Integer);
@ -979,6 +993,27 @@ begin
DataTable.Fields[idx_FacturasClienteFECHA_FACTURA].AsVariant := Null; DataTable.Fields[idx_FacturasClienteFECHA_FACTURA].AsVariant := Null;
end; end;
function TFacturasClienteDataTableRules.GetFECHA_VENCIMIENTOValue: DateTime;
begin
result := DataTable.Fields[idx_FacturasClienteFECHA_VENCIMIENTO].AsDateTime;
end;
procedure TFacturasClienteDataTableRules.SetFECHA_VENCIMIENTOValue(const aValue: DateTime);
begin
DataTable.Fields[idx_FacturasClienteFECHA_VENCIMIENTO].AsDateTime := aValue;
end;
function TFacturasClienteDataTableRules.GetFECHA_VENCIMIENTOIsNull: boolean;
begin
result := DataTable.Fields[idx_FacturasClienteFECHA_VENCIMIENTO].IsNull;
end;
procedure TFacturasClienteDataTableRules.SetFECHA_VENCIMIENTOIsNull(const aValue: Boolean);
begin
if aValue then
DataTable.Fields[idx_FacturasClienteFECHA_VENCIMIENTO].AsVariant := Null;
end;
function TFacturasClienteDataTableRules.GetSITUACIONValue: String; function TFacturasClienteDataTableRules.GetSITUACIONValue: String;
begin begin
result := DataTable.Fields[idx_FacturasClienteSITUACION].AsString; result := DataTable.Fields[idx_FacturasClienteSITUACION].AsString;

View File

@ -9,13 +9,13 @@ const
{ Delta rules ids { Delta rules ids
Feel free to change them to something more human readable Feel free to change them to something more human readable
but make sure they are unique in the context of your application } but make sure they are unique in the context of your application }
RID_FacturasClienteDelta = '{E601804E-04A1-4309-8827-23A675659EC2}'; RID_FacturasClienteDelta = '{98AACC73-D363-4458-A0D0-D9FD4739FC3A}';
RID_FacturasCliente_DetallesDelta = '{E26FF170-E793-4E14-86D0-6A5FCEAD94EB}'; RID_FacturasCliente_DetallesDelta = '{10944E21-F0F0-4154-9A06-F658143DE95A}';
type type
{ IFacturasClienteDelta } { IFacturasClienteDelta }
IFacturasClienteDelta = interface(IFacturasCliente) IFacturasClienteDelta = interface(IFacturasCliente)
['{E601804E-04A1-4309-8827-23A675659EC2}'] ['{98AACC73-D363-4458-A0D0-D9FD4739FC3A}']
{ Property getters and setters } { Property getters and setters }
function GetOldIDValue : Integer; function GetOldIDValue : Integer;
function GetOldID_EMPRESAValue : Integer; function GetOldID_EMPRESAValue : Integer;
@ -23,6 +23,7 @@ type
function GetOldTIPOValue : String; function GetOldTIPOValue : String;
function GetOldID_COMISION_LIQUIDADAValue : Integer; function GetOldID_COMISION_LIQUIDADAValue : Integer;
function GetOldFECHA_FACTURAValue : DateTime; function GetOldFECHA_FACTURAValue : DateTime;
function GetOldFECHA_VENCIMIENTOValue : DateTime;
function GetOldSITUACIONValue : String; function GetOldSITUACIONValue : String;
function GetOldBASE_IMPONIBLEValue : Currency; function GetOldBASE_IMPONIBLEValue : Currency;
function GetOldDESCUENTOValue : Float; function GetOldDESCUENTOValue : Float;
@ -65,6 +66,7 @@ type
property OldTIPO : String read GetOldTIPOValue; property OldTIPO : String read GetOldTIPOValue;
property OldID_COMISION_LIQUIDADA : Integer read GetOldID_COMISION_LIQUIDADAValue; property OldID_COMISION_LIQUIDADA : Integer read GetOldID_COMISION_LIQUIDADAValue;
property OldFECHA_FACTURA : DateTime read GetOldFECHA_FACTURAValue; property OldFECHA_FACTURA : DateTime read GetOldFECHA_FACTURAValue;
property OldFECHA_VENCIMIENTO : DateTime read GetOldFECHA_VENCIMIENTOValue;
property OldSITUACION : String read GetOldSITUACIONValue; property OldSITUACION : String read GetOldSITUACIONValue;
property OldBASE_IMPONIBLE : Currency read GetOldBASE_IMPONIBLEValue; property OldBASE_IMPONIBLE : Currency read GetOldBASE_IMPONIBLEValue;
property OldDESCUENTO : Float read GetOldDESCUENTOValue; property OldDESCUENTO : Float read GetOldDESCUENTOValue;
@ -144,6 +146,12 @@ type
function GetOldFECHA_FACTURAIsNull: Boolean; virtual; function GetOldFECHA_FACTURAIsNull: Boolean; virtual;
procedure SetFECHA_FACTURAValue(const aValue: DateTime); virtual; procedure SetFECHA_FACTURAValue(const aValue: DateTime); virtual;
procedure SetFECHA_FACTURAIsNull(const aValue: Boolean); virtual; procedure SetFECHA_FACTURAIsNull(const aValue: Boolean); virtual;
function GetFECHA_VENCIMIENTOValue: DateTime; virtual;
function GetFECHA_VENCIMIENTOIsNull: Boolean; virtual;
function GetOldFECHA_VENCIMIENTOValue: DateTime; virtual;
function GetOldFECHA_VENCIMIENTOIsNull: Boolean; virtual;
procedure SetFECHA_VENCIMIENTOValue(const aValue: DateTime); virtual;
procedure SetFECHA_VENCIMIENTOIsNull(const aValue: Boolean); virtual;
function GetSITUACIONValue: String; virtual; function GetSITUACIONValue: String; virtual;
function GetSITUACIONIsNull: Boolean; virtual; function GetSITUACIONIsNull: Boolean; virtual;
function GetOldSITUACIONValue: String; virtual; function GetOldSITUACIONValue: String; virtual;
@ -373,6 +381,10 @@ type
property FECHA_FACTURAIsNull : Boolean read GetFECHA_FACTURAIsNull write SetFECHA_FACTURAIsNull; property FECHA_FACTURAIsNull : Boolean read GetFECHA_FACTURAIsNull write SetFECHA_FACTURAIsNull;
property OldFECHA_FACTURA : DateTime read GetOldFECHA_FACTURAValue; property OldFECHA_FACTURA : DateTime read GetOldFECHA_FACTURAValue;
property OldFECHA_FACTURAIsNull : Boolean read GetOldFECHA_FACTURAIsNull; property OldFECHA_FACTURAIsNull : Boolean read GetOldFECHA_FACTURAIsNull;
property FECHA_VENCIMIENTO : DateTime read GetFECHA_VENCIMIENTOValue write SetFECHA_VENCIMIENTOValue;
property FECHA_VENCIMIENTOIsNull : Boolean read GetFECHA_VENCIMIENTOIsNull write SetFECHA_VENCIMIENTOIsNull;
property OldFECHA_VENCIMIENTO : DateTime read GetOldFECHA_VENCIMIENTOValue;
property OldFECHA_VENCIMIENTOIsNull : Boolean read GetOldFECHA_VENCIMIENTOIsNull;
property SITUACION : String read GetSITUACIONValue write SetSITUACIONValue; property SITUACION : String read GetSITUACIONValue write SetSITUACIONValue;
property SITUACIONIsNull : Boolean read GetSITUACIONIsNull write SetSITUACIONIsNull; property SITUACIONIsNull : Boolean read GetSITUACIONIsNull write SetSITUACIONIsNull;
property OldSITUACION : String read GetOldSITUACIONValue; property OldSITUACION : String read GetOldSITUACIONValue;
@ -518,7 +530,7 @@ type
{ IFacturasCliente_DetallesDelta } { IFacturasCliente_DetallesDelta }
IFacturasCliente_DetallesDelta = interface(IFacturasCliente_Detalles) IFacturasCliente_DetallesDelta = interface(IFacturasCliente_Detalles)
['{E26FF170-E793-4E14-86D0-6A5FCEAD94EB}'] ['{10944E21-F0F0-4154-9A06-F658143DE95A}']
{ Property getters and setters } { Property getters and setters }
function GetOldIDValue : Integer; function GetOldIDValue : Integer;
function GetOldID_FACTURAValue : Integer; function GetOldID_FACTURAValue : Integer;
@ -919,6 +931,37 @@ begin
BusinessProcessor.CurrentChange.NewValueByName[fld_FacturasClienteFECHA_FACTURA] := Null; BusinessProcessor.CurrentChange.NewValueByName[fld_FacturasClienteFECHA_FACTURA] := Null;
end; end;
function TFacturasClienteBusinessProcessorRules.GetFECHA_VENCIMIENTOValue: DateTime;
begin
result := BusinessProcessor.CurrentChange.NewValueByName[fld_FacturasClienteFECHA_VENCIMIENTO];
end;
function TFacturasClienteBusinessProcessorRules.GetFECHA_VENCIMIENTOIsNull: Boolean;
begin
result := VarIsNull(BusinessProcessor.CurrentChange.NewValueByName[fld_FacturasClienteFECHA_VENCIMIENTO]);
end;
function TFacturasClienteBusinessProcessorRules.GetOldFECHA_VENCIMIENTOValue: DateTime;
begin
result := BusinessProcessor.CurrentChange.OldValueByName[fld_FacturasClienteFECHA_VENCIMIENTO];
end;
function TFacturasClienteBusinessProcessorRules.GetOldFECHA_VENCIMIENTOIsNull: Boolean;
begin
result := VarIsNull(BusinessProcessor.CurrentChange.OldValueByName[fld_FacturasClienteFECHA_VENCIMIENTO]);
end;
procedure TFacturasClienteBusinessProcessorRules.SetFECHA_VENCIMIENTOValue(const aValue: DateTime);
begin
BusinessProcessor.CurrentChange.NewValueByName[fld_FacturasClienteFECHA_VENCIMIENTO] := aValue;
end;
procedure TFacturasClienteBusinessProcessorRules.SetFECHA_VENCIMIENTOIsNull(const aValue: Boolean);
begin
if aValue then
BusinessProcessor.CurrentChange.NewValueByName[fld_FacturasClienteFECHA_VENCIMIENTO] := Null;
end;
function TFacturasClienteBusinessProcessorRules.GetSITUACIONValue: String; function TFacturasClienteBusinessProcessorRules.GetSITUACIONValue: String;
begin begin
result := BusinessProcessor.CurrentChange.NewValueByName[fld_FacturasClienteSITUACION]; result := BusinessProcessor.CurrentChange.NewValueByName[fld_FacturasClienteSITUACION];

View File

@ -182,6 +182,10 @@ object srvFacturasCliente: TsrvFacturasCliente
item item
DatasetField = 'NOMBRE_COMERCIAL_CLIENTE' DatasetField = 'NOMBRE_COMERCIAL_CLIENTE'
TableField = 'NOMBRE_COMERCIAL_CLIENTE' TableField = 'NOMBRE_COMERCIAL_CLIENTE'
end
item
DatasetField = 'FECHA_VENCIMIENTO'
TableField = 'FECHA_VENCIMIENTO'
end> end>
end> end>
Name = 'FacturasCliente' Name = 'FacturasCliente'
@ -221,6 +225,10 @@ object srvFacturasCliente: TsrvFacturasCliente
DataType = datDateTime DataType = datDateTime
DictionaryEntry = 'FacturasCliente_FECHA_FACTURA' DictionaryEntry = 'FacturasCliente_FECHA_FACTURA'
end end
item
Name = 'FECHA_VENCIMIENTO'
DataType = datDateTime
end
item item
Name = 'SITUACION' Name = 'SITUACION'
DataType = datString DataType = datString
@ -853,6 +861,10 @@ object srvFacturasCliente: TsrvFacturasCliente
Name = 'FECHA_FACTURA' Name = 'FECHA_FACTURA'
Value = '' Value = ''
end end
item
Name = 'FECHA_VENCIMIENTO'
Value = ''
end
item item
Name = 'BASE_IMPONIBLE' Name = 'BASE_IMPONIBLE'
Value = '' Value = ''
@ -964,22 +976,23 @@ object srvFacturasCliente: TsrvFacturasCliente
TargetTable = 'FACTURAS_CLIENTE' TargetTable = 'FACTURAS_CLIENTE'
SQL = SQL =
'INSERT INTO FACTURAS_CLIENTE ('#10' ID,'#10' ID_EMPRESA,'#10' REFER' + 'INSERT INTO FACTURAS_CLIENTE ('#10' ID,'#10' ID_EMPRESA,'#10' REFER' +
'ENCIA,'#10' FECHA_FACTURA,'#10' BASE_IMPONIBLE,'#10' DESCUENTO,'#10' ' + 'ENCIA,'#10' FECHA_FACTURA,'#10' FECHA_VENCIMIENTO,'#10' BASE_IMPONI' +
' IMPORTE_DESCUENTO,'#10' IVA,'#10' IMPORTE_IVA,'#10' RE,'#10' IMPORT' + 'BLE,'#10' DESCUENTO,'#10' IMPORTE_DESCUENTO,'#10' IVA,'#10' IMPORTE_' +
'E_RE,'#10' IMPORTE_TOTAL,'#10' OBSERVACIONES,'#10' ID_CLIENTE,'#10' ' + 'IVA,'#10' RE,'#10' IMPORTE_RE,'#10' IMPORTE_TOTAL,'#10' OBSERVACIONE' +
'NIF_CIF,'#10' NOMBRE,'#10' CALLE,'#10' POBLACION,'#10' PROVINCIA,'#10' ' + 'S,'#10' ID_CLIENTE,'#10' NIF_CIF,'#10' NOMBRE,'#10' CALLE,'#10' POBLA' +
' CODIGO_POSTAL,'#10' FECHA_ALTA,'#10' FECHA_MODIFICACION,'#10' USU' + 'CION,'#10' PROVINCIA,'#10' CODIGO_POSTAL,'#10' FECHA_ALTA,'#10' FECH' +
'ARIO,'#10' ID_FORMA_PAGO,'#10' RECARGO_EQUIVALENCIA,'#10' ID_TIPO_I' + 'A_MODIFICACION,'#10' USUARIO,'#10' ID_FORMA_PAGO,'#10' RECARGO_EQUI' +
'VA,'#10' IMPORTE_NETO,'#10' IMPORTE_PORTE,'#10' IGNORAR_CONTABILIDA' + 'VALENCIA,'#10' ID_TIPO_IVA,'#10' IMPORTE_NETO,'#10' IMPORTE_PORTE,'#10 +
'D,'#10' ID_TIENDA)'#10' VALUES ('#10' :ID,'#10' :ID_EMPRESA,'#10' :REFE' + ' IGNORAR_CONTABILIDAD,'#10' ID_TIENDA)'#10' VALUES ('#10' :ID,'#10' ' +
'RENCIA,'#10' :FECHA_FACTURA,'#10' :BASE_IMPONIBLE,'#10' :DESCUENTO,' + ' :ID_EMPRESA,'#10' :REFERENCIA,'#10' :FECHA_FACTURA,'#10' :FECHA_VE' +
#10' :IMPORTE_DESCUENTO,'#10' :IVA,'#10' :IMPORTE_IVA,'#10' :RE,'#10' ' + 'NCIMIENTO,'#10' :BASE_IMPONIBLE,'#10' :DESCUENTO,'#10' :IMPORTE_DES' +
' :IMPORTE_RE,'#10' :IMPORTE_TOTAL,'#10' :OBSERVACIONES,'#10' :ID_C' + 'CUENTO,'#10' :IVA,'#10' :IMPORTE_IVA,'#10' :RE,'#10' :IMPORTE_RE,'#10' ' +
'LIENTE,'#10' :NIF_CIF,'#10' :NOMBRE,'#10' :CALLE,'#10' :POBLACION,'#10' ' + ' :IMPORTE_TOTAL,'#10' :OBSERVACIONES,'#10' :ID_CLIENTE,'#10' :NIF_' +
' :PROVINCIA,'#10' :CODIGO_POSTAL,'#10' :FECHA_ALTA,'#10' :FECHA_M' + 'CIF,'#10' :NOMBRE,'#10' :CALLE,'#10' :POBLACION,'#10' :PROVINCIA,'#10' ' +
'ODIFICACION,'#10' :USUARIO,'#10' :ID_FORMA_PAGO,'#10' :RECARGO_EQUI' + ' :CODIGO_POSTAL,'#10' :FECHA_ALTA,'#10' :FECHA_MODIFICACION,'#10' ' +
'VALENCIA,'#10' :ID_TIPO_IVA,'#10' :IMPORTE_NETO,'#10' :IMPORTE_PORT' + ':USUARIO,'#10' :ID_FORMA_PAGO,'#10' :RECARGO_EQUIVALENCIA,'#10' :ID' +
'E,'#10' :IGNORAR_CONTABILIDAD,'#10' :ID_TIENDA);'#10 '_TIPO_IVA,'#10' :IMPORTE_NETO,'#10' :IMPORTE_PORTE,'#10' :IGNORAR_C' +
'ONTABILIDAD,'#10' :ID_TIENDA);'#10
StatementType = stSQL StatementType = stSQL
ColumnMappings = <> ColumnMappings = <>
end> end>
@ -999,6 +1012,10 @@ object srvFacturasCliente: TsrvFacturasCliente
Name = 'FECHA_FACTURA' Name = 'FECHA_FACTURA'
Value = '' Value = ''
end end
item
Name = 'FECHA_VENCIMIENTO'
Value = ''
end
item item
Name = 'BASE_IMPONIBLE' Name = 'BASE_IMPONIBLE'
Value = '' Value = ''
@ -1114,20 +1131,20 @@ object srvFacturasCliente: TsrvFacturasCliente
SQL = SQL =
'UPDATE FACTURAS_CLIENTE'#10' SET'#10' ID_EMPRESA = :ID_EMPRESA,'#10' ' + 'UPDATE FACTURAS_CLIENTE'#10' SET'#10' ID_EMPRESA = :ID_EMPRESA,'#10' ' +
'REFERENCIA = :REFERENCIA,'#10' FECHA_FACTURA = :FECHA_FACTURA,'#10' ' + 'REFERENCIA = :REFERENCIA,'#10' FECHA_FACTURA = :FECHA_FACTURA,'#10' ' +
' BASE_IMPONIBLE = :BASE_IMPONIBLE,'#10' DESCUENTO = :DESCUENTO,'#10 + ' FECHA_VENCIMIENTO = :FECHA_VENCIMIENTO,'#10' BASE_IMPONIBLE = :' +
' IMPORTE_DESCUENTO = :IMPORTE_DESCUENTO,'#10' IVA = :IVA,'#10' ' + 'BASE_IMPONIBLE,'#10' DESCUENTO = :DESCUENTO,'#10' IMPORTE_DESCUENT' +
'IMPORTE_IVA = :IMPORTE_IVA,'#10' RE = :RE,'#10' IMPORTE_RE = :IMPO' + 'O = :IMPORTE_DESCUENTO,'#10' IVA = :IVA,'#10' IMPORTE_IVA = :IMPOR' +
'RTE_RE,'#10' IMPORTE_TOTAL = :IMPORTE_TOTAL,'#10' OBSERVACIONES = ' + 'TE_IVA,'#10' RE = :RE,'#10' IMPORTE_RE = :IMPORTE_RE,'#10' IMPORTE_' +
':OBSERVACIONES,'#10' ID_CLIENTE = :ID_CLIENTE,'#10' NIF_CIF = :NIF' + 'TOTAL = :IMPORTE_TOTAL,'#10' OBSERVACIONES = :OBSERVACIONES,'#10' ' +
'_CIF,'#10' NOMBRE = :NOMBRE,'#10' CALLE = :CALLE,'#10' POBLACION = ' + 'ID_CLIENTE = :ID_CLIENTE,'#10' NIF_CIF = :NIF_CIF,'#10' NOMBRE = :' +
':POBLACION,'#10' PROVINCIA = :PROVINCIA,'#10' CODIGO_POSTAL = :COD' + 'NOMBRE,'#10' CALLE = :CALLE,'#10' POBLACION = :POBLACION,'#10' PROV' +
'IGO_POSTAL,'#10' FECHA_ALTA = :FECHA_ALTA,'#10' FECHA_MODIFICACION' + 'INCIA = :PROVINCIA,'#10' CODIGO_POSTAL = :CODIGO_POSTAL,'#10' FECH' +
' = :FECHA_MODIFICACION,'#10' USUARIO = :USUARIO,'#10' ID_FORMA_PAG' + 'A_ALTA = :FECHA_ALTA,'#10' FECHA_MODIFICACION = :FECHA_MODIFICACI' +
'O = :ID_FORMA_PAGO,'#10' RECARGO_EQUIVALENCIA = :RECARGO_EQUIVALE' + 'ON,'#10' USUARIO = :USUARIO,'#10' ID_FORMA_PAGO = :ID_FORMA_PAGO,'#10 +
'NCIA,'#10' ID_TIPO_IVA = :ID_TIPO_IVA,'#10' IMPORTE_NETO = :IMPORT' + ' RECARGO_EQUIVALENCIA = :RECARGO_EQUIVALENCIA,'#10' ID_TIPO_IV' +
'E_NETO,'#10' IMPORTE_PORTE = :IMPORTE_PORTE,'#10' IGNORAR_CONTABIL' + 'A = :ID_TIPO_IVA,'#10' IMPORTE_NETO = :IMPORTE_NETO,'#10' IMPORTE_' +
'IDAD = :IGNORAR_CONTABILIDAD,'#10' ID_TIENDA = :ID_TIENDA'#10' WHERE' + 'PORTE = :IMPORTE_PORTE,'#10' IGNORAR_CONTABILIDAD = :IGNORAR_CONT' +
#10' (ID = :OLD_ID);'#10 'ABILIDAD,'#10' ID_TIENDA = :ID_TIENDA'#10' WHERE'#10' (ID = :OLD_ID);'#10
StatementType = stSQL StatementType = stSQL
ColumnMappings = <> ColumnMappings = <>
end> end>

View File

@ -14,13 +14,14 @@ inherited frViewFacturaCliente: TfrViewFacturaCliente
Align = alClient Align = alClient
ParentBackground = True ParentBackground = True
TabOrder = 0 TabOrder = 0
TabStop = False
AutoContentSizes = [acsWidth, acsHeight] AutoContentSizes = [acsWidth, acsHeight]
LookAndFeel = dxLayoutOfficeLookAndFeel1 LookAndFeel = dxLayoutOfficeLookAndFeel1
DesignSize = ( DesignSize = (
451 451
304) 304)
object eReferencia: TcxDBTextEdit object eReferencia: TcxDBTextEdit
Left = 124 Left = 135
Top = 30 Top = 30
Anchors = [akLeft, akTop, akRight] Anchors = [akLeft, akTop, akRight]
DataBinding.DataField = 'REFERENCIA' DataBinding.DataField = 'REFERENCIA'
@ -32,16 +33,20 @@ inherited frViewFacturaCliente: TfrViewFacturaCliente
Style.Color = clInfoBk Style.Color = clInfoBk
Style.HotTrack = False Style.HotTrack = False
Style.LookAndFeel.NativeStyle = True Style.LookAndFeel.NativeStyle = True
Style.LookAndFeel.SkinName = ''
StyleDisabled.Color = clMenuBar StyleDisabled.Color = clMenuBar
StyleDisabled.LookAndFeel.NativeStyle = True StyleDisabled.LookAndFeel.NativeStyle = True
StyleDisabled.LookAndFeel.SkinName = ''
StyleDisabled.TextColor = clWindowText StyleDisabled.TextColor = clWindowText
StyleFocused.LookAndFeel.NativeStyle = True StyleFocused.LookAndFeel.NativeStyle = True
StyleFocused.LookAndFeel.SkinName = ''
StyleHot.LookAndFeel.NativeStyle = True StyleHot.LookAndFeel.NativeStyle = True
StyleHot.LookAndFeel.SkinName = ''
TabOrder = 0 TabOrder = 0
Width = 159 Width = 159
end end
object edtFecha: TcxDBDateEdit object edtFecha: TcxDBDateEdit
Left = 124 Left = 135
Top = 57 Top = 57
Anchors = [akLeft, akTop, akRight] Anchors = [akLeft, akTop, akRight]
DataBinding.DataField = 'FECHA_FACTURA' DataBinding.DataField = 'FECHA_FACTURA'
@ -51,13 +56,17 @@ inherited frViewFacturaCliente: TfrViewFacturaCliente
Style.Color = clInfoBk Style.Color = clInfoBk
Style.HotTrack = False Style.HotTrack = False
Style.LookAndFeel.NativeStyle = True Style.LookAndFeel.NativeStyle = True
Style.LookAndFeel.SkinName = ''
Style.Shadow = False Style.Shadow = False
Style.ButtonStyle = bts3D Style.ButtonStyle = bts3D
Style.ButtonTransparency = ebtNone Style.ButtonTransparency = ebtNone
Style.PopupBorderStyle = epbsFrame3D Style.PopupBorderStyle = epbsFrame3D
StyleDisabled.LookAndFeel.NativeStyle = True StyleDisabled.LookAndFeel.NativeStyle = True
StyleDisabled.LookAndFeel.SkinName = ''
StyleFocused.LookAndFeel.NativeStyle = True StyleFocused.LookAndFeel.NativeStyle = True
StyleFocused.LookAndFeel.SkinName = ''
StyleHot.LookAndFeel.NativeStyle = True StyleHot.LookAndFeel.NativeStyle = True
StyleHot.LookAndFeel.SkinName = ''
TabOrder = 1 TabOrder = 1
Width = 159 Width = 159
end end
@ -72,16 +81,20 @@ inherited frViewFacturaCliente: TfrViewFacturaCliente
Style.BorderStyle = ebs3D Style.BorderStyle = ebs3D
Style.HotTrack = False Style.HotTrack = False
Style.LookAndFeel.NativeStyle = True Style.LookAndFeel.NativeStyle = True
Style.LookAndFeel.SkinName = ''
StyleDisabled.LookAndFeel.NativeStyle = True StyleDisabled.LookAndFeel.NativeStyle = True
StyleDisabled.LookAndFeel.SkinName = ''
StyleFocused.LookAndFeel.NativeStyle = True StyleFocused.LookAndFeel.NativeStyle = True
StyleFocused.LookAndFeel.SkinName = ''
StyleHot.LookAndFeel.NativeStyle = True StyleHot.LookAndFeel.NativeStyle = True
TabOrder = 6 StyleHot.LookAndFeel.SkinName = ''
TabOrder = 7
Height = 159 Height = 159
Width = 301 Width = 301
end end
object cbFormaPago: TcxDBLookupComboBox object cbFormaPago: TcxDBLookupComboBox
Left = 124 Left = 135
Top = 84 Top = 108
DataBinding.DataField = 'ID_FORMA_PAGO' DataBinding.DataField = 'ID_FORMA_PAGO'
DataBinding.DataSource = DADataSource DataBinding.DataSource = DADataSource
Properties.DropDownListStyle = lsFixedList Properties.DropDownListStyle = lsFixedList
@ -95,25 +108,30 @@ inherited frViewFacturaCliente: TfrViewFacturaCliente
Properties.ListOptions.ShowHeader = False Properties.ListOptions.ShowHeader = False
Properties.ListOptions.SyncMode = True Properties.ListOptions.SyncMode = True
Properties.ListSource = dsFormaPago Properties.ListSource = dsFormaPago
Properties.OnEditValueChanged = edtFechaVencimientoPropertiesEditValueChanged
Style.BorderColor = clWindowFrame Style.BorderColor = clWindowFrame
Style.BorderStyle = ebs3D Style.BorderStyle = ebs3D
Style.HotTrack = False Style.HotTrack = False
Style.LookAndFeel.Kind = lfStandard Style.LookAndFeel.Kind = lfStandard
Style.LookAndFeel.NativeStyle = True Style.LookAndFeel.NativeStyle = True
Style.LookAndFeel.SkinName = ''
Style.ButtonStyle = bts3D Style.ButtonStyle = bts3D
Style.PopupBorderStyle = epbsFrame3D Style.PopupBorderStyle = epbsFrame3D
StyleDisabled.LookAndFeel.Kind = lfStandard StyleDisabled.LookAndFeel.Kind = lfStandard
StyleDisabled.LookAndFeel.NativeStyle = True StyleDisabled.LookAndFeel.NativeStyle = True
StyleDisabled.LookAndFeel.SkinName = ''
StyleFocused.LookAndFeel.Kind = lfStandard StyleFocused.LookAndFeel.Kind = lfStandard
StyleFocused.LookAndFeel.NativeStyle = True StyleFocused.LookAndFeel.NativeStyle = True
StyleFocused.LookAndFeel.SkinName = ''
StyleHot.LookAndFeel.Kind = lfStandard StyleHot.LookAndFeel.Kind = lfStandard
StyleHot.LookAndFeel.NativeStyle = True StyleHot.LookAndFeel.NativeStyle = True
StyleHot.LookAndFeel.SkinName = ''
TabOrder = 2 TabOrder = 2
Width = 78 Width = 78
end end
object bFormasPago: TButton object bFormasPago: TButton
Left = 241 Left = 313
Top = 84 Top = 108
Width = 132 Width = 132
Height = 23 Height = 23
Caption = 'Ver las formas de pago...' Caption = 'Ver las formas de pago...'
@ -122,7 +140,7 @@ inherited frViewFacturaCliente: TfrViewFacturaCliente
end end
inline frViewTienda1: TfrViewTienda inline frViewTienda1: TfrViewTienda
Left = 22 Left = 22
Top = 137 Top = 188
Width = 351 Width = 351
Height = 48 Height = 48
Font.Charset = DEFAULT_CHARSET Font.Charset = DEFAULT_CHARSET
@ -131,10 +149,10 @@ inherited frViewFacturaCliente: TfrViewFacturaCliente
Font.Name = 'Tahoma' Font.Name = 'Tahoma'
Font.Style = [] Font.Style = []
ParentFont = False ParentFont = False
TabOrder = 4 TabOrder = 5
ReadOnly = False ReadOnly = False
ExplicitLeft = 22 ExplicitLeft = 22
ExplicitTop = 137 ExplicitTop = 188
ExplicitWidth = 351 ExplicitWidth = 351
ExplicitHeight = 48 ExplicitHeight = 48
inherited dxLayoutControl1: TdxLayoutControl inherited dxLayoutControl1: TdxLayoutControl
@ -143,13 +161,17 @@ inherited frViewFacturaCliente: TfrViewFacturaCliente
ExplicitWidth = 351 ExplicitWidth = 351
ExplicitHeight = 63 ExplicitHeight = 63
inherited cbTienda: TcxComboBox inherited cbTienda: TcxComboBox
Style.LookAndFeel.SkinName = ''
StyleDisabled.LookAndFeel.SkinName = ''
StyleFocused.LookAndFeel.SkinName = ''
StyleHot.LookAndFeel.SkinName = ''
ExplicitWidth = 399 ExplicitWidth = 399
Width = 399 Width = 399
end end
end end
end end
inline frViewClienteFactura1: TfrViewClienteFactura inline frViewClienteFactura1: TfrViewClienteFactura
Left = 401 Left = 473
Top = 30 Top = 30
Width = 398 Width = 398
Height = 265 Height = 265
@ -159,9 +181,9 @@ inherited frViewFacturaCliente: TfrViewFacturaCliente
Font.Name = 'Tahoma' Font.Name = 'Tahoma'
Font.Style = [] Font.Style = []
ParentFont = False ParentFont = False
TabOrder = 5 TabOrder = 6
ReadOnly = False ReadOnly = False
ExplicitLeft = 401 ExplicitLeft = 473
ExplicitTop = 30 ExplicitTop = 30
ExplicitWidth = 398 ExplicitWidth = 398
ExplicitHeight = 265 ExplicitHeight = 265
@ -171,27 +193,51 @@ inherited frViewFacturaCliente: TfrViewFacturaCliente
ExplicitWidth = 398 ExplicitWidth = 398
ExplicitHeight = 265 ExplicitHeight = 265
inherited edtlNombre: TcxDBTextEdit inherited edtlNombre: TcxDBTextEdit
Style.LookAndFeel.SkinName = ''
StyleDisabled.LookAndFeel.SkinName = ''
StyleFocused.LookAndFeel.SkinName = ''
StyleHot.LookAndFeel.SkinName = ''
ExplicitWidth = 276 ExplicitWidth = 276
Width = 276 Width = 276
end end
inherited edtNIFCIF: TcxDBTextEdit inherited edtNIFCIF: TcxDBTextEdit
Style.LookAndFeel.SkinName = ''
StyleDisabled.LookAndFeel.SkinName = ''
StyleFocused.LookAndFeel.SkinName = ''
StyleHot.LookAndFeel.SkinName = ''
ExplicitWidth = 276 ExplicitWidth = 276
Width = 276 Width = 276
end end
inherited edtCalle: TcxDBTextEdit inherited edtCalle: TcxDBTextEdit
Style.LookAndFeel.SkinName = ''
StyleDisabled.LookAndFeel.SkinName = ''
StyleFocused.LookAndFeel.SkinName = ''
StyleHot.LookAndFeel.SkinName = ''
ExplicitWidth = 276 ExplicitWidth = 276
Width = 276 Width = 276
end end
inherited edtPoblacion: TcxDBTextEdit inherited edtPoblacion: TcxDBTextEdit
Style.LookAndFeel.SkinName = ''
StyleDisabled.LookAndFeel.SkinName = ''
StyleFocused.LookAndFeel.SkinName = ''
StyleHot.LookAndFeel.SkinName = ''
ExplicitWidth = 158 ExplicitWidth = 158
Width = 158 Width = 158
end end
inherited edtProvincia: TcxDBTextEdit inherited edtProvincia: TcxDBTextEdit
Style.LookAndFeel.SkinName = ''
StyleDisabled.LookAndFeel.SkinName = ''
StyleFocused.LookAndFeel.SkinName = ''
StyleHot.LookAndFeel.SkinName = ''
ExplicitWidth = 276 ExplicitWidth = 276
Width = 276 Width = 276
end end
inherited edtCodigoPostal: TcxDBTextEdit inherited edtCodigoPostal: TcxDBTextEdit
Left = 192 Left = 192
Style.LookAndFeel.SkinName = ''
StyleDisabled.LookAndFeel.SkinName = ''
StyleFocused.LookAndFeel.SkinName = ''
StyleHot.LookAndFeel.SkinName = ''
ExplicitLeft = 192 ExplicitLeft = 192
end end
inherited Button3: TBitBtn inherited Button3: TBitBtn
@ -199,11 +245,41 @@ inherited frViewFacturaCliente: TfrViewFacturaCliente
ExplicitLeft = 82 ExplicitLeft = 82
end end
inherited cxDBTextEdit1: TcxDBTextEdit inherited cxDBTextEdit1: TcxDBTextEdit
Style.LookAndFeel.SkinName = ''
StyleDisabled.LookAndFeel.SkinName = ''
StyleFocused.LookAndFeel.SkinName = ''
StyleHot.LookAndFeel.SkinName = ''
ExplicitWidth = 283 ExplicitWidth = 283
Width = 283 Width = 283
end end
end end
end end
object edtFechaVencimiento: TcxDBDateEdit
Left = 135
Top = 137
Anchors = [akLeft, akTop, akRight]
DataBinding.DataField = 'FECHA_VENCIMIENTO'
DataBinding.DataSource = DADataSource
Properties.OnEditValueChanged = edtFechaVencimientoPropertiesEditValueChanged
Style.BorderColor = clWindowFrame
Style.BorderStyle = ebs3D
Style.Color = clInfoBk
Style.HotTrack = False
Style.LookAndFeel.NativeStyle = True
Style.LookAndFeel.SkinName = ''
Style.Shadow = False
Style.ButtonStyle = bts3D
Style.ButtonTransparency = ebtNone
Style.PopupBorderStyle = epbsFrame3D
StyleDisabled.LookAndFeel.NativeStyle = True
StyleDisabled.LookAndFeel.SkinName = ''
StyleFocused.LookAndFeel.NativeStyle = True
StyleFocused.LookAndFeel.SkinName = ''
StyleHot.LookAndFeel.NativeStyle = True
StyleHot.LookAndFeel.SkinName = ''
TabOrder = 4
Width = 310
end
object dxLayoutControl1Group_Root: TdxLayoutGroup object dxLayoutControl1Group_Root: TdxLayoutGroup
ShowCaption = False ShowCaption = False
Hidden = True Hidden = True
@ -231,6 +307,9 @@ inherited frViewFacturaCliente: TfrViewFacturaCliente
Control = edtFecha Control = edtFecha
ControlOptions.ShowBorder = False ControlOptions.ShowBorder = False
end end
end
object dxLayoutControl1Group8: TdxLayoutGroup
Caption = 'Forma de pago'
object dxLayoutControl1Group3: TdxLayoutGroup object dxLayoutControl1Group3: TdxLayoutGroup
ShowCaption = False ShowCaption = False
Hidden = True Hidden = True
@ -249,6 +328,11 @@ inherited frViewFacturaCliente: TfrViewFacturaCliente
ControlOptions.ShowBorder = False ControlOptions.ShowBorder = False
end end
end end
object ledtFechaVencimiento: TdxLayoutItem
Caption = 'Fecha de vencimiento:'
Control = edtFechaVencimiento
ControlOptions.ShowBorder = False
end
end end
object dxLayoutControl1Group4: TdxLayoutGroup object dxLayoutControl1Group4: TdxLayoutGroup
AutoAligns = [aaVertical] AutoAligns = [aaVertical]

View File

@ -44,7 +44,6 @@ type
cbFormaPago: TcxDBLookupComboBox; cbFormaPago: TcxDBLookupComboBox;
dxLayoutControl1Item10: TdxLayoutItem; dxLayoutControl1Item10: TdxLayoutItem;
bFormasPago: TButton; bFormasPago: TButton;
dxLayoutControl1Group3: TdxLayoutGroup;
dxLayoutControl1Group6: TdxLayoutGroup; dxLayoutControl1Group6: TdxLayoutGroup;
frViewTienda1: TfrViewTienda; frViewTienda1: TfrViewTienda;
dxLayoutControl1Group4: TdxLayoutGroup; dxLayoutControl1Group4: TdxLayoutGroup;
@ -52,9 +51,14 @@ type
dxLayoutControl1Group7: TdxLayoutGroup; dxLayoutControl1Group7: TdxLayoutGroup;
dxLayoutControl1Item6: TdxLayoutItem; dxLayoutControl1Item6: TdxLayoutItem;
frViewClienteFactura1: TfrViewClienteFactura; frViewClienteFactura1: TfrViewClienteFactura;
dxLayoutControl1Group8: TdxLayoutGroup;
ledtFechaVencimiento: TdxLayoutItem;
edtFechaVencimiento: TcxDBDateEdit;
dxLayoutControl1Group3: TdxLayoutGroup;
procedure bFormasPagoClick(Sender: TObject); procedure bFormasPagoClick(Sender: TObject);
procedure CustomViewDestroy(Sender: TObject); procedure CustomViewDestroy(Sender: TObject);
procedure CustomViewCreate(Sender: TObject); procedure CustomViewCreate(Sender: TObject);
procedure edtFechaVencimientoPropertiesEditValueChanged(Sender: TObject);
protected protected
FFactura : IBizFacturaCliente; FFactura : IBizFacturaCliente;
FController : IFacturasClienteController; FController : IFacturasClienteController;
@ -100,6 +104,15 @@ begin
FFormasPagoController := NIL; FFormasPagoController := NIL;
end; end;
procedure TfrViewFacturaCliente.edtFechaVencimientoPropertiesEditValueChanged(Sender: TObject);
begin
if Assigned(FFormasPago) then
if (FFormasPago.Plazos.RecordCount = 0) then
ledtFechaVencimiento.Enabled := True
else
ledtFechaVencimiento.Enabled := False;
end;
function TfrViewFacturaCliente.GetController: IFacturasClienteController; function TfrViewFacturaCliente.GetController: IFacturasClienteController;
begin begin
Result := FController; Result := FController;
@ -132,6 +145,13 @@ begin
dsFormaPago.DataTable := FFormasPago.DataTable; dsFormaPago.DataTable := FFormasPago.DataTable;
dsFormaPago.DataTable.Active := True; dsFormaPago.DataTable.Active := True;
//Posicionamos la tabla en la forma de pago que tiene la factura ya que no lo hace el componente por si solo
FFormasPago.DataTable.Locate(fld_FacturasClienteID, FFactura.ID_FORMA_PAGO, []);
if (FFormasPago.Plazos.RecordCount = 0) then
ledtFechaVencimiento.Enabled := True
else
ledtFechaVencimiento.Enabled := False;
//Solo se deshabilita al insertar, luego la referencia será modificable //Solo se deshabilita al insertar, luego la referencia será modificable
//eReferencia.Enabled := (FFactura.DataTable.State = dsInsert); //eReferencia.Enabled := (FFactura.DataTable.State = dsInsert);

View File

@ -127,7 +127,7 @@ uses
uAlbaranesProveedorController, schAlbaranesProveedorClient_Intf, uDetallesAlbaranProveedorController, uAlbaranesProveedorController, schAlbaranesProveedorClient_Intf, uDetallesAlbaranProveedorController,
uBizDetallesAlbaranProveedor, Variants, uBizDetallesAlbaranProveedor, Variants,
uBizPedidosProveedor, uPedidosProveedorController, uBizDetallesPedidoProveedor, uBizPedidosProveedor, uPedidosProveedorController, uBizDetallesPedidoProveedor,
uRecibosProveedorController, uBizRecibosProveedor, uRecibosProveedorController, uBizRecibosProveedor, uNumUtils,
uFacturasProveedorReportController, DateUtils, Forms, Dialogs, uFacturasProveedorReportController, DateUtils, Forms, Dialogs,
uFormasPagoController, uBizFormasPago; uFormasPagoController, uBizFormasPago;
@ -648,6 +648,8 @@ begin
if (AFactura.ID_FORMA_PAGO = 0) then if (AFactura.ID_FORMA_PAGO = 0) then
raise Exception.Create('Debe indicar una forma de pago para esta factura'); raise Exception.Create('Debe indicar una forma de pago para esta factura');
//De esta forma obligaremos siempre a tener un recibo asociado a la factura,
//porque si la forma de pago no tiene plazos es obligatorio la fecha de vencimiento
with TFormasPagoController.Create do with TFormasPagoController.Create do
begin begin
try try
@ -1134,9 +1136,9 @@ begin
ARecibos := ARecibosProveedorController.BuscarRecibosFactura(AFactura.ID); ARecibos := ARecibosProveedorController.BuscarRecibosFactura(AFactura.ID);
ARecibosProveedorController.EliminarTodo(ARecibos); ARecibosProveedorController.EliminarTodo(ARecibos);
//Se cambia la lógica para acana, en el caso de elegir una forma de pago sin plazos //Se cambia la lógica a peticion de acana, en el caso de meter una fecha de vencimiento,
//y meter una fecha de vencimiento se generará un recibo con el 100% y fecha de vencimiento //los plazos de la forma de pago no tendrán efecto, se generará un recibo con el 100% y fecha de vencimiento
//de la factura, en el caso de elegir una forma de pago con plazos la logica será la misma que en clientes //de la factura.
With AFormaPago.Plazos.DataTable do With AFormaPago.Plazos.DataTable do
begin begin
i := 1; i := 1;
@ -1156,6 +1158,7 @@ begin
ARecibos.PROVINCIA := AFactura.PROVINCIA; ARecibos.PROVINCIA := AFactura.PROVINCIA;
ARecibos.CODIGO_POSTAL := AFactura.CODIGO_POSTAL; ARecibos.CODIGO_POSTAL := AFactura.CODIGO_POSTAL;
ARecibos.FECHA_EMISION := AFactura.FECHA_FACTURA; ARecibos.FECHA_EMISION := AFactura.FECHA_FACTURA;
if AFormaPago.Plazos.RecordCount < 1 then if AFormaPago.Plazos.RecordCount < 1 then
begin begin
ARecibos.FECHA_VENCIMIENTO := AFactura.FECHA_VENCIMIENTO; ARecibos.FECHA_VENCIMIENTO := AFactura.FECHA_VENCIMIENTO;
@ -1166,6 +1169,8 @@ begin
ARecibos.FECHA_VENCIMIENTO := AFactura.FECHA_FACTURA + AFormaPago.Plazos.NUM_DIAS; ARecibos.FECHA_VENCIMIENTO := AFactura.FECHA_FACTURA + AFormaPago.Plazos.NUM_DIAS;
ARecibos.IMPORTE := AFactura.IMPORTE_TOTAL * (AFormaPago.Plazos.PORCENTAJE / 100); ARecibos.IMPORTE := AFactura.IMPORTE_TOTAL * (AFormaPago.Plazos.PORCENTAJE / 100);
end; end;
ARecibos.DESCRIPCION := 'Pago de factura ' + AFactura.REFERENCIA + ': son ' + CifraToLetras(ARecibos.IMPORTE);
ARecibosProveedorController.Guardar(ARecibos); ARecibosProveedorController.Guardar(ARecibos);
Inc(i); Inc(i);
Next; Next;

View File

@ -19,11 +19,9 @@
<Projects Include="..\Contactos\Model\Contactos_model.dproj" /> <Projects Include="..\Contactos\Model\Contactos_model.dproj" />
<Projects Include="..\Contactos\Views\Contactos_view.dproj" /> <Projects Include="..\Contactos\Views\Contactos_view.dproj" />
<Projects Include="..\Facturas de cliente\Controller\FacturasCliente_controller.dproj" /> <Projects Include="..\Facturas de cliente\Controller\FacturasCliente_controller.dproj" />
<Projects Include="..\Facturas de cliente\Data\FacturasCliente_data.dproj" />
<Projects Include="..\Facturas de cliente\Model\FacturasCliente_model.dproj" />
<Projects Include="..\Facturas de cliente\Views\FacturasCliente_view.dproj" /> <Projects Include="..\Facturas de cliente\Views\FacturasCliente_view.dproj" />
<Projects Include="..\Gestor de informes\Controller\GestorInformes_controller.dproj" />
<Projects Include="..\Gestor de informes\Data\GestorInformes_data.dproj" />
<Projects Include="..\Gestor de informes\Model\GestorInformes_model.dproj" />
<Projects Include="..\Gestor de informes\Views\GestorInformes_view.dproj" />
<Projects Include="..\Pedidos a proveedor\Controller\PedidosProveedor_controller.dproj" /> <Projects Include="..\Pedidos a proveedor\Controller\PedidosProveedor_controller.dproj" />
<Projects Include="..\Recibos de proveedor\Controller\RecibosProveedor_controller.dproj" /> <Projects Include="..\Recibos de proveedor\Controller\RecibosProveedor_controller.dproj" />
<Projects Include="Controller\FacturasProveedor_controller.dproj" /> <Projects Include="Controller\FacturasProveedor_controller.dproj" />
@ -182,15 +180,6 @@
<Target Name="FactuGES_Server:Make"> <Target Name="FactuGES_Server:Make">
<MSBuild Projects="..\..\Servidor\FactuGES_Server.dproj" Targets="Make" /> <MSBuild Projects="..\..\Servidor\FactuGES_Server.dproj" Targets="Make" />
</Target> </Target>
<Target Name="FacturasCliente_view">
<MSBuild Projects="..\Facturas de cliente\Views\FacturasCliente_view.dproj" Targets="" />
</Target>
<Target Name="FacturasCliente_view:Clean">
<MSBuild Projects="..\Facturas de cliente\Views\FacturasCliente_view.dproj" Targets="Clean" />
</Target>
<Target Name="FacturasCliente_view:Make">
<MSBuild Projects="..\Facturas de cliente\Views\FacturasCliente_view.dproj" Targets="Make" />
</Target>
<Target Name="Contabilidad_view"> <Target Name="Contabilidad_view">
<MSBuild Projects="..\Contabilidad\Views\Contabilidad_view.dproj" Targets="" /> <MSBuild Projects="..\Contabilidad\Views\Contabilidad_view.dproj" Targets="" />
</Target> </Target>
@ -236,6 +225,24 @@
<Target Name="Contactos_data:Make"> <Target Name="Contactos_data:Make">
<MSBuild Projects="..\Contactos\Data\Contactos_data.dproj" Targets="Make" /> <MSBuild Projects="..\Contactos\Data\Contactos_data.dproj" Targets="Make" />
</Target> </Target>
<Target Name="FacturasCliente_model">
<MSBuild Projects="..\Facturas de cliente\Model\FacturasCliente_model.dproj" Targets="" />
</Target>
<Target Name="FacturasCliente_model:Clean">
<MSBuild Projects="..\Facturas de cliente\Model\FacturasCliente_model.dproj" Targets="Clean" />
</Target>
<Target Name="FacturasCliente_model:Make">
<MSBuild Projects="..\Facturas de cliente\Model\FacturasCliente_model.dproj" Targets="Make" />
</Target>
<Target Name="FacturasCliente_data">
<MSBuild Projects="..\Facturas de cliente\Data\FacturasCliente_data.dproj" Targets="" />
</Target>
<Target Name="FacturasCliente_data:Clean">
<MSBuild Projects="..\Facturas de cliente\Data\FacturasCliente_data.dproj" Targets="Clean" />
</Target>
<Target Name="FacturasCliente_data:Make">
<MSBuild Projects="..\Facturas de cliente\Data\FacturasCliente_data.dproj" Targets="Make" />
</Target>
<Target Name="FacturasCliente_controller"> <Target Name="FacturasCliente_controller">
<MSBuild Projects="..\Facturas de cliente\Controller\FacturasCliente_controller.dproj" Targets="" /> <MSBuild Projects="..\Facturas de cliente\Controller\FacturasCliente_controller.dproj" Targets="" />
</Target> </Target>
@ -245,50 +252,23 @@
<Target Name="FacturasCliente_controller:Make"> <Target Name="FacturasCliente_controller:Make">
<MSBuild Projects="..\Facturas de cliente\Controller\FacturasCliente_controller.dproj" Targets="Make" /> <MSBuild Projects="..\Facturas de cliente\Controller\FacturasCliente_controller.dproj" Targets="Make" />
</Target> </Target>
<Target Name="GestorInformes_controller"> <Target Name="FacturasCliente_view">
<MSBuild Projects="..\Gestor de informes\Controller\GestorInformes_controller.dproj" Targets="" /> <MSBuild Projects="..\Facturas de cliente\Views\FacturasCliente_view.dproj" Targets="" />
</Target> </Target>
<Target Name="GestorInformes_controller:Clean"> <Target Name="FacturasCliente_view:Clean">
<MSBuild Projects="..\Gestor de informes\Controller\GestorInformes_controller.dproj" Targets="Clean" /> <MSBuild Projects="..\Facturas de cliente\Views\FacturasCliente_view.dproj" Targets="Clean" />
</Target> </Target>
<Target Name="GestorInformes_controller:Make"> <Target Name="FacturasCliente_view:Make">
<MSBuild Projects="..\Gestor de informes\Controller\GestorInformes_controller.dproj" Targets="Make" /> <MSBuild Projects="..\Facturas de cliente\Views\FacturasCliente_view.dproj" Targets="Make" />
</Target>
<Target Name="GestorInformes_data">
<MSBuild Projects="..\Gestor de informes\Data\GestorInformes_data.dproj" Targets="" />
</Target>
<Target Name="GestorInformes_data:Clean">
<MSBuild Projects="..\Gestor de informes\Data\GestorInformes_data.dproj" Targets="Clean" />
</Target>
<Target Name="GestorInformes_data:Make">
<MSBuild Projects="..\Gestor de informes\Data\GestorInformes_data.dproj" Targets="Make" />
</Target>
<Target Name="GestorInformes_view">
<MSBuild Projects="..\Gestor de informes\Views\GestorInformes_view.dproj" Targets="" />
</Target>
<Target Name="GestorInformes_view:Clean">
<MSBuild Projects="..\Gestor de informes\Views\GestorInformes_view.dproj" Targets="Clean" />
</Target>
<Target Name="GestorInformes_view:Make">
<MSBuild Projects="..\Gestor de informes\Views\GestorInformes_view.dproj" Targets="Make" />
</Target>
<Target Name="GestorInformes_model">
<MSBuild Projects="..\Gestor de informes\Model\GestorInformes_model.dproj" Targets="" />
</Target>
<Target Name="GestorInformes_model:Clean">
<MSBuild Projects="..\Gestor de informes\Model\GestorInformes_model.dproj" Targets="Clean" />
</Target>
<Target Name="GestorInformes_model:Make">
<MSBuild Projects="..\Gestor de informes\Model\GestorInformes_model.dproj" Targets="Make" />
</Target> </Target>
<Target Name="Build"> <Target Name="Build">
<CallTarget Targets="Base;GUIBase;ApplicationBase;Contactos_view;Articulos_controller;Articulos_view;PedidosProveedor_controller;AlbaranesProveedor_controller;RecibosProveedor_controller;FacturasProveedor_model;FacturasProveedor_data;FacturasProveedor_controller;FacturasProveedor_view;FacturasProveedor_plugin;FactuGES;FactuGES_Server;FacturasCliente_view;Contabilidad_view;Contabilidad_controller;Contactos_model;Contactos_controller;Contactos_data;FacturasCliente_controller;GestorInformes_controller;GestorInformes_data;GestorInformes_view;GestorInformes_model" /> <CallTarget Targets="Base;GUIBase;ApplicationBase;Contactos_view;Articulos_controller;Articulos_view;PedidosProveedor_controller;AlbaranesProveedor_controller;RecibosProveedor_controller;FacturasProveedor_model;FacturasProveedor_data;FacturasProveedor_controller;FacturasProveedor_view;FacturasProveedor_plugin;FactuGES;FactuGES_Server;Contabilidad_view;Contabilidad_controller;Contactos_model;Contactos_controller;Contactos_data;FacturasCliente_model;FacturasCliente_data;FacturasCliente_controller;FacturasCliente_view" />
</Target> </Target>
<Target Name="Clean"> <Target Name="Clean">
<CallTarget Targets="Base:Clean;GUIBase:Clean;ApplicationBase:Clean;Contactos_view:Clean;Articulos_controller:Clean;Articulos_view:Clean;PedidosProveedor_controller:Clean;AlbaranesProveedor_controller:Clean;RecibosProveedor_controller:Clean;FacturasProveedor_model:Clean;FacturasProveedor_data:Clean;FacturasProveedor_controller:Clean;FacturasProveedor_view:Clean;FacturasProveedor_plugin:Clean;FactuGES:Clean;FactuGES_Server:Clean;FacturasCliente_view:Clean;Contabilidad_view:Clean;Contabilidad_controller:Clean;Contactos_model:Clean;Contactos_controller:Clean;Contactos_data:Clean;FacturasCliente_controller:Clean;GestorInformes_controller:Clean;GestorInformes_data:Clean;GestorInformes_view:Clean;GestorInformes_model:Clean" /> <CallTarget Targets="Base:Clean;GUIBase:Clean;ApplicationBase:Clean;Contactos_view:Clean;Articulos_controller:Clean;Articulos_view:Clean;PedidosProveedor_controller:Clean;AlbaranesProveedor_controller:Clean;RecibosProveedor_controller:Clean;FacturasProveedor_model:Clean;FacturasProveedor_data:Clean;FacturasProveedor_controller:Clean;FacturasProveedor_view:Clean;FacturasProveedor_plugin:Clean;FactuGES:Clean;FactuGES_Server:Clean;Contabilidad_view:Clean;Contabilidad_controller:Clean;Contactos_model:Clean;Contactos_controller:Clean;Contactos_data:Clean;FacturasCliente_model:Clean;FacturasCliente_data:Clean;FacturasCliente_controller:Clean;FacturasCliente_view:Clean" />
</Target> </Target>
<Target Name="Make"> <Target Name="Make">
<CallTarget Targets="Base:Make;GUIBase:Make;ApplicationBase:Make;Contactos_view:Make;Articulos_controller:Make;Articulos_view:Make;PedidosProveedor_controller:Make;AlbaranesProveedor_controller:Make;RecibosProveedor_controller:Make;FacturasProveedor_model:Make;FacturasProveedor_data:Make;FacturasProveedor_controller:Make;FacturasProveedor_view:Make;FacturasProveedor_plugin:Make;FactuGES:Make;FactuGES_Server:Make;FacturasCliente_view:Make;Contabilidad_view:Make;Contabilidad_controller:Make;Contactos_model:Make;Contactos_controller:Make;Contactos_data:Make;FacturasCliente_controller:Make;GestorInformes_controller:Make;GestorInformes_data:Make;GestorInformes_view:Make;GestorInformes_model:Make" /> <CallTarget Targets="Base:Make;GUIBase:Make;ApplicationBase:Make;Contactos_view:Make;Articulos_controller:Make;Articulos_view:Make;PedidosProveedor_controller:Make;AlbaranesProveedor_controller:Make;RecibosProveedor_controller:Make;FacturasProveedor_model:Make;FacturasProveedor_data:Make;FacturasProveedor_controller:Make;FacturasProveedor_view:Make;FacturasProveedor_plugin:Make;FactuGES:Make;FactuGES_Server:Make;Contabilidad_view:Make;Contabilidad_controller:Make;Contactos_model:Make;Contactos_controller:Make;Contactos_data:Make;FacturasCliente_model:Make;FacturasCliente_data:Make;FacturasCliente_controller:Make;FacturasCliente_view:Make" />
</Target> </Target>
<Import Condition="Exists('$(MSBuildBinPath)\Borland.Group.Targets')" Project="$(MSBuildBinPath)\Borland.Group.Targets" /> <Import Condition="Exists('$(MSBuildBinPath)\Borland.Group.Targets')" Project="$(MSBuildBinPath)\Borland.Group.Targets" />
</Project> </Project>

View File

@ -9,8 +9,8 @@ const
{ Data table rules ids { Data table rules ids
Feel free to change them to something more human readable Feel free to change them to something more human readable
but make sure they are unique in the context of your application } but make sure they are unique in the context of your application }
RID_FacturasProveedor = '{0EF26853-CA11-423C-A717-4B46C60A1D1B}'; RID_FacturasProveedor = '{1486775D-D203-45FA-A947-C647563E9E7C}';
RID_FacturasProveedor_Detalles = '{55ADC035-4592-4CDA-968B-F19217917CD1}'; RID_FacturasProveedor_Detalles = '{B0F1438F-E96D-4190-B2CE-2AE580895113}';
{ Data table names } { Data table names }
nme_FacturasProveedor = 'FacturasProveedor'; nme_FacturasProveedor = 'FacturasProveedor';
@ -133,7 +133,7 @@ const
type type
{ IFacturasProveedor } { IFacturasProveedor }
IFacturasProveedor = interface(IDAStronglyTypedDataTable) IFacturasProveedor = interface(IDAStronglyTypedDataTable)
['{83594315-B925-4468-8505-380368A507A6}'] ['{A7AB33CE-569D-4132-A3CC-4E9534B46031}']
{ Property getters and setters } { Property getters and setters }
function GetIDValue: Integer; function GetIDValue: Integer;
procedure SetIDValue(const aValue: Integer); procedure SetIDValue(const aValue: Integer);
@ -624,7 +624,7 @@ type
{ IFacturasProveedor_Detalles } { IFacturasProveedor_Detalles }
IFacturasProveedor_Detalles = interface(IDAStronglyTypedDataTable) IFacturasProveedor_Detalles = interface(IDAStronglyTypedDataTable)
['{D0DDC85A-B7D6-4471-8F74-08884C18C78C}'] ['{2CEF42D5-3F51-41E3-B52B-1F1ED8599905}']
{ Property getters and setters } { Property getters and setters }
function GetIDValue: Integer; function GetIDValue: Integer;
procedure SetIDValue(const aValue: Integer); procedure SetIDValue(const aValue: Integer);

View File

@ -9,13 +9,13 @@ const
{ Delta rules ids { Delta rules ids
Feel free to change them to something more human readable Feel free to change them to something more human readable
but make sure they are unique in the context of your application } but make sure they are unique in the context of your application }
RID_FacturasProveedorDelta = '{0F97D038-E9E1-454B-9E40-B4E22FA5BDDE}'; RID_FacturasProveedorDelta = '{10FEC5CF-8C4F-41E2-8377-713BB2DA8E8A}';
RID_FacturasProveedor_DetallesDelta = '{2DA1017B-00B9-4125-B47A-1D65D934DFE7}'; RID_FacturasProveedor_DetallesDelta = '{03628F84-FD1E-4A7B-A510-E235E361A432}';
type type
{ IFacturasProveedorDelta } { IFacturasProveedorDelta }
IFacturasProveedorDelta = interface(IFacturasProveedor) IFacturasProveedorDelta = interface(IFacturasProveedor)
['{0F97D038-E9E1-454B-9E40-B4E22FA5BDDE}'] ['{10FEC5CF-8C4F-41E2-8377-713BB2DA8E8A}']
{ Property getters and setters } { Property getters and setters }
function GetOldIDValue : Integer; function GetOldIDValue : Integer;
function GetOldID_EMPRESAValue : Integer; function GetOldID_EMPRESAValue : Integer;
@ -506,7 +506,7 @@ type
{ IFacturasProveedor_DetallesDelta } { IFacturasProveedor_DetallesDelta }
IFacturasProveedor_DetallesDelta = interface(IFacturasProveedor_Detalles) IFacturasProveedor_DetallesDelta = interface(IFacturasProveedor_Detalles)
['{2DA1017B-00B9-4125-B47A-1D65D934DFE7}'] ['{03628F84-FD1E-4A7B-A510-E235E361A432}']
{ Property getters and setters } { Property getters and setters }
function GetOldIDValue : Integer; function GetOldIDValue : Integer;
function GetOldID_FACTURAValue : Integer; function GetOldID_FACTURAValue : Integer;

View File

@ -1,6 +1,6 @@
inherited frViewFacturaProveedor: TfrViewFacturaProveedor inherited frViewFacturaProveedor: TfrViewFacturaProveedor
Width = 790 Width = 796
Height = 496 Height = 415
Align = alClient Align = alClient
OnCreate = CustomViewCreate OnCreate = CustomViewCreate
OnDestroy = CustomViewDestroy OnDestroy = CustomViewDestroy
@ -9,18 +9,19 @@ inherited frViewFacturaProveedor: TfrViewFacturaProveedor
object dxLayoutControl1: TdxLayoutControl object dxLayoutControl1: TdxLayoutControl
Left = 0 Left = 0
Top = 0 Top = 0
Width = 790 Width = 796
Height = 496 Height = 415
Align = alClient Align = alClient
ParentBackground = True ParentBackground = True
TabOrder = 0 TabOrder = 0
TabStop = False
AutoContentSizes = [acsWidth, acsHeight] AutoContentSizes = [acsWidth, acsHeight]
LookAndFeel = dxLayoutOfficeLookAndFeel1 LookAndFeel = dxLayoutOfficeLookAndFeel1
ExplicitWidth = 451 ExplicitWidth = 451
ExplicitHeight = 304 ExplicitHeight = 304
DesignSize = ( DesignSize = (
790 796
496) 415)
object eReferencia: TcxDBTextEdit object eReferencia: TcxDBTextEdit
Left = 124 Left = 124
Top = 30 Top = 30
@ -33,11 +34,15 @@ inherited frViewFacturaProveedor: TfrViewFacturaProveedor
Style.Color = clInfoBk Style.Color = clInfoBk
Style.HotTrack = False Style.HotTrack = False
Style.LookAndFeel.NativeStyle = True Style.LookAndFeel.NativeStyle = True
Style.LookAndFeel.SkinName = ''
StyleDisabled.Color = clMenuBar StyleDisabled.Color = clMenuBar
StyleDisabled.LookAndFeel.NativeStyle = True StyleDisabled.LookAndFeel.NativeStyle = True
StyleDisabled.LookAndFeel.SkinName = ''
StyleDisabled.TextColor = clWindowText StyleDisabled.TextColor = clWindowText
StyleFocused.LookAndFeel.NativeStyle = True StyleFocused.LookAndFeel.NativeStyle = True
StyleFocused.LookAndFeel.SkinName = ''
StyleHot.LookAndFeel.NativeStyle = True StyleHot.LookAndFeel.NativeStyle = True
StyleHot.LookAndFeel.SkinName = ''
TabOrder = 0 TabOrder = 0
Width = 159 Width = 159
end end
@ -52,13 +57,17 @@ inherited frViewFacturaProveedor: TfrViewFacturaProveedor
Style.Color = clInfoBk Style.Color = clInfoBk
Style.HotTrack = False Style.HotTrack = False
Style.LookAndFeel.NativeStyle = True Style.LookAndFeel.NativeStyle = True
Style.LookAndFeel.SkinName = ''
Style.Shadow = False Style.Shadow = False
Style.ButtonStyle = bts3D Style.ButtonStyle = bts3D
Style.ButtonTransparency = ebtNone Style.ButtonTransparency = ebtNone
Style.PopupBorderStyle = epbsFrame3D Style.PopupBorderStyle = epbsFrame3D
StyleDisabled.LookAndFeel.NativeStyle = True StyleDisabled.LookAndFeel.NativeStyle = True
StyleDisabled.LookAndFeel.SkinName = ''
StyleFocused.LookAndFeel.NativeStyle = True StyleFocused.LookAndFeel.NativeStyle = True
StyleFocused.LookAndFeel.SkinName = ''
StyleHot.LookAndFeel.NativeStyle = True StyleHot.LookAndFeel.NativeStyle = True
StyleHot.LookAndFeel.SkinName = ''
TabOrder = 2 TabOrder = 2
Width = 159 Width = 159
end end
@ -73,16 +82,20 @@ inherited frViewFacturaProveedor: TfrViewFacturaProveedor
Style.BorderStyle = ebs3D Style.BorderStyle = ebs3D
Style.HotTrack = False Style.HotTrack = False
Style.LookAndFeel.NativeStyle = True Style.LookAndFeel.NativeStyle = True
Style.LookAndFeel.SkinName = ''
StyleDisabled.LookAndFeel.NativeStyle = True StyleDisabled.LookAndFeel.NativeStyle = True
StyleDisabled.LookAndFeel.SkinName = ''
StyleFocused.LookAndFeel.NativeStyle = True StyleFocused.LookAndFeel.NativeStyle = True
StyleFocused.LookAndFeel.SkinName = ''
StyleHot.LookAndFeel.NativeStyle = True StyleHot.LookAndFeel.NativeStyle = True
StyleHot.LookAndFeel.SkinName = ''
TabOrder = 8 TabOrder = 8
Height = 170 Height = 170
Width = 754 Width = 754
end end
object cbFormaPago: TcxDBLookupComboBox object cbFormaPago: TcxDBLookupComboBox
Left = 124 Left = 124
Top = 138 Top = 135
DataBinding.DataField = 'ID_FORMA_PAGO' DataBinding.DataField = 'ID_FORMA_PAGO'
DataBinding.DataSource = DADataSource DataBinding.DataSource = DADataSource
Properties.DropDownListStyle = lsFixedList Properties.DropDownListStyle = lsFixedList
@ -96,29 +109,34 @@ inherited frViewFacturaProveedor: TfrViewFacturaProveedor
Properties.ListOptions.ShowHeader = False Properties.ListOptions.ShowHeader = False
Properties.ListOptions.SyncMode = True Properties.ListOptions.SyncMode = True
Properties.ListSource = dsFormaPago Properties.ListSource = dsFormaPago
Properties.OnEditValueChanged = cbFormaPagoPropertiesEditValueChanged
Style.BorderColor = clWindowFrame Style.BorderColor = clWindowFrame
Style.BorderStyle = ebs3D Style.BorderStyle = ebs3D
Style.HotTrack = False Style.HotTrack = False
Style.LookAndFeel.Kind = lfStandard Style.LookAndFeel.Kind = lfStandard
Style.LookAndFeel.NativeStyle = True Style.LookAndFeel.NativeStyle = True
Style.LookAndFeel.SkinName = ''
Style.ButtonStyle = bts3D Style.ButtonStyle = bts3D
Style.PopupBorderStyle = epbsFrame3D Style.PopupBorderStyle = epbsFrame3D
StyleDisabled.LookAndFeel.Kind = lfStandard StyleDisabled.LookAndFeel.Kind = lfStandard
StyleDisabled.LookAndFeel.NativeStyle = True StyleDisabled.LookAndFeel.NativeStyle = True
StyleDisabled.LookAndFeel.SkinName = ''
StyleFocused.LookAndFeel.Kind = lfStandard StyleFocused.LookAndFeel.Kind = lfStandard
StyleFocused.LookAndFeel.NativeStyle = True StyleFocused.LookAndFeel.NativeStyle = True
StyleFocused.LookAndFeel.SkinName = ''
StyleHot.LookAndFeel.Kind = lfStandard StyleHot.LookAndFeel.Kind = lfStandard
StyleHot.LookAndFeel.NativeStyle = True StyleHot.LookAndFeel.NativeStyle = True
TabOrder = 4 StyleHot.LookAndFeel.SkinName = ''
TabOrder = 3
Width = 169 Width = 169
end end
object bFormasPago: TButton object bFormasPago: TButton
Left = 296 Left = 302
Top = 138 Top = 135
Width = 132 Width = 132
Height = 23 Height = 23
Caption = 'Ver las formas de pago...' Caption = 'Ver las formas de pago...'
TabOrder = 5 TabOrder = 4
OnClick = bFormasPagoClick OnClick = bFormasPagoClick
end end
object eReferenciaProveedor: TcxDBTextEdit object eReferenciaProveedor: TcxDBTextEdit
@ -133,17 +151,21 @@ inherited frViewFacturaProveedor: TfrViewFacturaProveedor
Style.Color = clInfoBk Style.Color = clInfoBk
Style.HotTrack = False Style.HotTrack = False
Style.LookAndFeel.NativeStyle = True Style.LookAndFeel.NativeStyle = True
Style.LookAndFeel.SkinName = ''
StyleDisabled.Color = clMenuBar StyleDisabled.Color = clMenuBar
StyleDisabled.LookAndFeel.NativeStyle = True StyleDisabled.LookAndFeel.NativeStyle = True
StyleDisabled.LookAndFeel.SkinName = ''
StyleDisabled.TextColor = clWindowText StyleDisabled.TextColor = clWindowText
StyleFocused.LookAndFeel.NativeStyle = True StyleFocused.LookAndFeel.NativeStyle = True
StyleFocused.LookAndFeel.SkinName = ''
StyleHot.LookAndFeel.NativeStyle = True StyleHot.LookAndFeel.NativeStyle = True
StyleHot.LookAndFeel.SkinName = ''
TabOrder = 1 TabOrder = 1
Width = 316 Width = 316
end end
inline frViewTienda1: TfrViewTienda inline frViewTienda1: TfrViewTienda
Left = 22 Left = 22
Top = 191 Top = 215
Width = 320 Width = 320
Height = 36 Height = 36
Font.Charset = DEFAULT_CHARSET Font.Charset = DEFAULT_CHARSET
@ -155,13 +177,17 @@ inherited frViewFacturaProveedor: TfrViewFacturaProveedor
TabOrder = 6 TabOrder = 6
ReadOnly = False ReadOnly = False
ExplicitLeft = 22 ExplicitLeft = 22
ExplicitTop = 191 ExplicitTop = 215
ExplicitWidth = 320 ExplicitWidth = 320
ExplicitHeight = 36 ExplicitHeight = 36
inherited dxLayoutControl1: TdxLayoutControl inherited dxLayoutControl1: TdxLayoutControl
Width = 320 Width = 320
ExplicitWidth = 320 ExplicitWidth = 320
inherited cbTienda: TcxComboBox inherited cbTienda: TcxComboBox
Style.LookAndFeel.SkinName = ''
StyleDisabled.LookAndFeel.SkinName = ''
StyleFocused.LookAndFeel.SkinName = ''
StyleHot.LookAndFeel.SkinName = ''
ExplicitWidth = 376 ExplicitWidth = 376
Width = 376 Width = 376
end end
@ -169,7 +195,7 @@ inherited frViewFacturaProveedor: TfrViewFacturaProveedor
end end
object edtFechaVencimiento: TcxDBDateEdit object edtFechaVencimiento: TcxDBDateEdit
Left = 124 Left = 124
Top = 111 Top = 164
Anchors = [akLeft, akTop, akRight] Anchors = [akLeft, akTop, akRight]
DataBinding.DataField = 'FECHA_VENCIMIENTO' DataBinding.DataField = 'FECHA_VENCIMIENTO'
DataBinding.DataSource = DADataSource DataBinding.DataSource = DADataSource
@ -178,18 +204,22 @@ inherited frViewFacturaProveedor: TfrViewFacturaProveedor
Style.Color = clInfoBk Style.Color = clInfoBk
Style.HotTrack = False Style.HotTrack = False
Style.LookAndFeel.NativeStyle = True Style.LookAndFeel.NativeStyle = True
Style.LookAndFeel.SkinName = ''
Style.Shadow = False Style.Shadow = False
Style.ButtonStyle = bts3D Style.ButtonStyle = bts3D
Style.ButtonTransparency = ebtNone Style.ButtonTransparency = ebtNone
Style.PopupBorderStyle = epbsFrame3D Style.PopupBorderStyle = epbsFrame3D
StyleDisabled.LookAndFeel.NativeStyle = True StyleDisabled.LookAndFeel.NativeStyle = True
StyleDisabled.LookAndFeel.SkinName = ''
StyleFocused.LookAndFeel.NativeStyle = True StyleFocused.LookAndFeel.NativeStyle = True
StyleFocused.LookAndFeel.SkinName = ''
StyleHot.LookAndFeel.NativeStyle = True StyleHot.LookAndFeel.NativeStyle = True
TabOrder = 3 StyleHot.LookAndFeel.SkinName = ''
TabOrder = 5
Width = 158 Width = 158
end end
inline frViewProveedorFactura1: TfrViewProveedorFactura inline frViewProveedorFactura1: TfrViewProveedorFactura
Left = 456 Left = 462
Top = 30 Top = 30
Width = 312 Width = 312
Height = 260 Height = 260
@ -201,7 +231,7 @@ inherited frViewFacturaProveedor: TfrViewFacturaProveedor
ParentFont = False ParentFont = False
TabOrder = 7 TabOrder = 7
ReadOnly = False ReadOnly = False
ExplicitLeft = 456 ExplicitLeft = 462
ExplicitTop = 30 ExplicitTop = 30
ExplicitWidth = 312 ExplicitWidth = 312
ExplicitHeight = 260 ExplicitHeight = 260
@ -213,27 +243,51 @@ inherited frViewFacturaProveedor: TfrViewFacturaProveedor
ExplicitWidth = 242 ExplicitWidth = 242
end end
inherited edtlNombre: TcxDBTextEdit inherited edtlNombre: TcxDBTextEdit
Style.LookAndFeel.SkinName = ''
StyleDisabled.LookAndFeel.SkinName = ''
StyleFocused.LookAndFeel.SkinName = ''
StyleHot.LookAndFeel.SkinName = ''
ExplicitWidth = 276 ExplicitWidth = 276
Width = 276 Width = 276
end end
inherited edtNIFCIF: TcxDBTextEdit inherited edtNIFCIF: TcxDBTextEdit
Style.LookAndFeel.SkinName = ''
StyleDisabled.LookAndFeel.SkinName = ''
StyleFocused.LookAndFeel.SkinName = ''
StyleHot.LookAndFeel.SkinName = ''
ExplicitWidth = 562 ExplicitWidth = 562
Width = 562 Width = 562
end end
inherited edtCalle: TcxDBTextEdit inherited edtCalle: TcxDBTextEdit
Style.LookAndFeel.SkinName = ''
StyleDisabled.LookAndFeel.SkinName = ''
StyleFocused.LookAndFeel.SkinName = ''
StyleHot.LookAndFeel.SkinName = ''
ExplicitWidth = 562 ExplicitWidth = 562
Width = 562 Width = 562
end end
inherited edtPoblacion: TcxDBTextEdit inherited edtPoblacion: TcxDBTextEdit
Style.LookAndFeel.SkinName = ''
StyleDisabled.LookAndFeel.SkinName = ''
StyleFocused.LookAndFeel.SkinName = ''
StyleHot.LookAndFeel.SkinName = ''
ExplicitWidth = 177 ExplicitWidth = 177
Width = 177 Width = 177
end end
inherited edtProvincia: TcxDBTextEdit inherited edtProvincia: TcxDBTextEdit
Style.LookAndFeel.SkinName = ''
StyleDisabled.LookAndFeel.SkinName = ''
StyleFocused.LookAndFeel.SkinName = ''
StyleHot.LookAndFeel.SkinName = ''
ExplicitWidth = 327 ExplicitWidth = 327
Width = 327 Width = 327
end end
inherited edtCodigoPostal: TcxDBTextEdit inherited edtCodigoPostal: TcxDBTextEdit
Left = 220 Left = 220
Style.LookAndFeel.SkinName = ''
StyleDisabled.LookAndFeel.SkinName = ''
StyleFocused.LookAndFeel.SkinName = ''
StyleHot.LookAndFeel.SkinName = ''
ExplicitLeft = 220 ExplicitLeft = 220
end end
inherited Button3: TBitBtn inherited Button3: TBitBtn
@ -241,6 +295,10 @@ inherited frViewFacturaProveedor: TfrViewFacturaProveedor
ExplicitLeft = 104 ExplicitLeft = 104
end end
inherited cxDBTextEdit1: TcxDBTextEdit inherited cxDBTextEdit1: TcxDBTextEdit
Style.LookAndFeel.SkinName = ''
StyleDisabled.LookAndFeel.SkinName = ''
StyleFocused.LookAndFeel.SkinName = ''
StyleHot.LookAndFeel.SkinName = ''
ExplicitWidth = 276 ExplicitWidth = 276
Width = 276 Width = 276
end end
@ -281,11 +339,9 @@ inherited frViewFacturaProveedor: TfrViewFacturaProveedor
Control = edtFecha Control = edtFecha
ControlOptions.ShowBorder = False ControlOptions.ShowBorder = False
end end
object dxLayoutControl1Item8: TdxLayoutItem end
Caption = 'Fecha vencimiento:' object dxLayoutControl1Group8: TdxLayoutGroup
Control = edtFechaVencimiento Caption = 'Forma de pago'
ControlOptions.ShowBorder = False
end
object dxLayoutControl1Group3: TdxLayoutGroup object dxLayoutControl1Group3: TdxLayoutGroup
ShowCaption = False ShowCaption = False
Hidden = True Hidden = True
@ -304,6 +360,11 @@ inherited frViewFacturaProveedor: TfrViewFacturaProveedor
ControlOptions.ShowBorder = False ControlOptions.ShowBorder = False
end end
end end
object ledtFechaVencimiento: TdxLayoutItem
Caption = 'Fecha vencimiento:'
Control = edtFechaVencimiento
ControlOptions.ShowBorder = False
end
end end
object dxLayoutControl1Group4: TdxLayoutGroup object dxLayoutControl1Group4: TdxLayoutGroup
Caption = 'La factura pertenece a la tienda' Caption = 'La factura pertenece a la tienda'

View File

@ -45,7 +45,6 @@ type
cbFormaPago: TcxDBLookupComboBox; cbFormaPago: TcxDBLookupComboBox;
dxLayoutControl1Item10: TdxLayoutItem; dxLayoutControl1Item10: TdxLayoutItem;
bFormasPago: TButton; bFormasPago: TButton;
dxLayoutControl1Group3: TdxLayoutGroup;
dxLayoutControl1Group6: TdxLayoutGroup; dxLayoutControl1Group6: TdxLayoutGroup;
dxLayoutControl1Item6: TdxLayoutItem; dxLayoutControl1Item6: TdxLayoutItem;
eReferenciaProveedor: TcxDBTextEdit; eReferenciaProveedor: TcxDBTextEdit;
@ -53,12 +52,14 @@ type
dxLayoutControl1Item7: TdxLayoutItem; dxLayoutControl1Item7: TdxLayoutItem;
frViewTienda1: TfrViewTienda; frViewTienda1: TfrViewTienda;
dxLayoutControl1Group7: TdxLayoutGroup; dxLayoutControl1Group7: TdxLayoutGroup;
dxLayoutControl1Item8: TdxLayoutItem; ledtFechaVencimiento: TdxLayoutItem;
edtFechaVencimiento: TcxDBDateEdit; edtFechaVencimiento: TcxDBDateEdit;
ActionList1: TActionList; ActionList1: TActionList;
actElegirDireccion: TAction; actElegirDireccion: TAction;
dxLayoutControl1Item3: TdxLayoutItem; dxLayoutControl1Item3: TdxLayoutItem;
frViewProveedorFactura1: TfrViewProveedorFactura; frViewProveedorFactura1: TfrViewProveedorFactura;
dxLayoutControl1Group8: TdxLayoutGroup;
dxLayoutControl1Group3: TdxLayoutGroup;
procedure bFormasPagoClick(Sender: TObject); procedure bFormasPagoClick(Sender: TObject);
procedure CustomViewDestroy(Sender: TObject); procedure CustomViewDestroy(Sender: TObject);
procedure CustomViewCreate(Sender: TObject); procedure CustomViewCreate(Sender: TObject);
@ -66,6 +67,7 @@ type
procedure frViewProveedorFacturaButton2Click(Sender: TObject); procedure frViewProveedorFacturaButton2Click(Sender: TObject);
procedure actElegirDireccionExecute(Sender: TObject); procedure actElegirDireccionExecute(Sender: TObject);
procedure actElegirDireccionUpdate(Sender: TObject); procedure actElegirDireccionUpdate(Sender: TObject);
procedure cbFormaPagoPropertiesEditValueChanged(Sender: TObject);
protected protected
FFactura : IBizFacturaProveedor; FFactura : IBizFacturaProveedor;
FFormasPago : IBizFormaPago; FFormasPago : IBizFormaPago;
@ -132,6 +134,15 @@ begin
FFormasPagoController.VerTodos(FFormasPago); FFormasPagoController.VerTodos(FFormasPago);
end; end;
procedure TfrViewFacturaProveedor.cbFormaPagoPropertiesEditValueChanged(Sender: TObject);
begin
if Assigned(FFormasPago) then
if (FFormasPago.Plazos.RecordCount = 0) then
ledtFechaVencimiento.Enabled := True
else
ledtFechaVencimiento.Enabled := False;
end;
procedure TfrViewFacturaProveedor.CustomViewCreate(Sender: TObject); procedure TfrViewFacturaProveedor.CustomViewCreate(Sender: TObject);
begin begin
inherited; inherited;
@ -200,6 +211,13 @@ begin
dsFormaPago.DataTable := FFormasPago.DataTable; dsFormaPago.DataTable := FFormasPago.DataTable;
dsFormaPago.DataTable.Active := True; dsFormaPago.DataTable.Active := True;
//Posicionamos la tabla en la forma de pago que tiene la factura ya que no lo hace el componente por si solo
FFormasPago.DataTable.Locate(fld_FacturasProveedorID, FFactura.ID_FORMA_PAGO, []);
if (FFormasPago.Plazos.RecordCount = 0) then
ledtFechaVencimiento.Enabled := True
else
ledtFechaVencimiento.Enabled := False;
//Solo se deshabilita al insertar, luego la referencia será modificable //Solo se deshabilita al insertar, luego la referencia será modificable
//eReferencia.Enabled := (FFactura.DataTable.State = dsInsert); //eReferencia.Enabled := (FFactura.DataTable.State = dsInsert);

View File

@ -13,4 +13,4 @@ BEGIN
END END
/* C:\Codigo Acana\Source\Modulos\Gestion de documentos\Controller\GestorDocumentos_Controller.res */ /* C:\Codigo Acana\Source\Modulos\Gestion de documentos\Controller\GestorDocumentos_Controller.res */
/* C:\DOCUME~1\Usuario\CONFIG~1\Temp\dtf59.tmp */ /* C:\DOCUME~1\Usuario\CONFIG~1\Temp\dtf62.tmp */

View File

@ -14,4 +14,4 @@ END
/* C:\Codigo Acana\Source\Modulos\Gestion de documentos\Data\uDataModuleGestorDocumentos.dfm */ /* C:\Codigo Acana\Source\Modulos\Gestion de documentos\Data\uDataModuleGestorDocumentos.dfm */
/* C:\Codigo Acana\Source\Modulos\Gestion de documentos\Data\GestorDocumentos_data.res */ /* C:\Codigo Acana\Source\Modulos\Gestion de documentos\Data\GestorDocumentos_data.res */
/* C:\DOCUME~1\Usuario\CONFIG~1\Temp\dtf57.tmp */ /* C:\DOCUME~1\Usuario\CONFIG~1\Temp\dtf60.tmp */

Binary file not shown.

View File

@ -97,8 +97,6 @@ uses
uRptAlbaranesCliente_Server in '..\Modulos\Albaranes de cliente\Reports\uRptAlbaranesCliente_Server.pas', uRptAlbaranesCliente_Server in '..\Modulos\Albaranes de cliente\Reports\uRptAlbaranesCliente_Server.pas',
schRecibosClienteClient_Intf in '..\Modulos\Recibos de cliente\Model\schRecibosClienteClient_Intf.pas', schRecibosClienteClient_Intf in '..\Modulos\Recibos de cliente\Model\schRecibosClienteClient_Intf.pas',
schRecibosClienteServer_Intf in '..\Modulos\Recibos de cliente\Model\schRecibosClienteServer_Intf.pas', schRecibosClienteServer_Intf in '..\Modulos\Recibos de cliente\Model\schRecibosClienteServer_Intf.pas',
schFacturasClienteClient_Intf in '..\Modulos\Facturas de cliente\Model\schFacturasClienteClient_Intf.pas',
schFacturasClienteServer_Intf in '..\Modulos\Facturas de cliente\Model\schFacturasClienteServer_Intf.pas',
uBizAsientosServer in '..\Modulos\Contabilidad\Model\uBizAsientosServer.pas', uBizAsientosServer in '..\Modulos\Contabilidad\Model\uBizAsientosServer.pas',
schContabilidadClient_Intf in '..\Modulos\Contabilidad\Model\schContabilidadClient_Intf.pas', schContabilidadClient_Intf in '..\Modulos\Contabilidad\Model\schContabilidadClient_Intf.pas',
schContabilidadServer_Intf in '..\Modulos\Contabilidad\Model\schContabilidadServer_Intf.pas', schContabilidadServer_Intf in '..\Modulos\Contabilidad\Model\schContabilidadServer_Intf.pas',
@ -122,8 +120,6 @@ uses
srvGestorInformes_Impl in '..\Modulos\Gestor de informes\Servidor\srvGestorInformes_Impl.pas' {srvGestorInformes: TDataAbstractService}, srvGestorInformes_Impl in '..\Modulos\Gestor de informes\Servidor\srvGestorInformes_Impl.pas' {srvGestorInformes: TDataAbstractService},
uRptFacturasProveedor_Server in '..\Modulos\Facturas de proveedor\Reports\uRptFacturasProveedor_Server.pas' {RptFacturasProveedor: TDataModule}, uRptFacturasProveedor_Server in '..\Modulos\Facturas de proveedor\Reports\uRptFacturasProveedor_Server.pas' {RptFacturasProveedor: TDataModule},
uRptRecibosProveedor_Server in '..\Modulos\Recibos de proveedor\Reports\uRptRecibosProveedor_Server.pas' {RptRecibosProveedor: TDataModule}, uRptRecibosProveedor_Server in '..\Modulos\Recibos de proveedor\Reports\uRptRecibosProveedor_Server.pas' {RptRecibosProveedor: TDataModule},
schFacturasProveedorClient_Intf in '..\Modulos\Facturas de proveedor\Model\schFacturasProveedorClient_Intf.pas',
schFacturasProveedorServer_Intf in '..\Modulos\Facturas de proveedor\Model\schFacturasProveedorServer_Intf.pas',
schRecibosProveedorClient_Intf in '..\Modulos\Recibos de proveedor\Model\schRecibosProveedorClient_Intf.pas', schRecibosProveedorClient_Intf in '..\Modulos\Recibos de proveedor\Model\schRecibosProveedorClient_Intf.pas',
schRecibosProveedorServer_Intf in '..\Modulos\Recibos de proveedor\Model\schRecibosProveedorServer_Intf.pas', schRecibosProveedorServer_Intf in '..\Modulos\Recibos de proveedor\Model\schRecibosProveedorServer_Intf.pas',
schEmpresasClient_Intf in '..\ApplicationBase\Empresas\Model\schEmpresasClient_Intf.pas', schEmpresasClient_Intf in '..\ApplicationBase\Empresas\Model\schEmpresasClient_Intf.pas',
@ -131,7 +127,11 @@ uses
schRemesasClienteClient_Intf in '..\Modulos\Remesas de cliente\Model\schRemesasClienteClient_Intf.pas', schRemesasClienteClient_Intf in '..\Modulos\Remesas de cliente\Model\schRemesasClienteClient_Intf.pas',
schRemesasClienteServer_Intf in '..\Modulos\Remesas de cliente\Model\schRemesasClienteServer_Intf.pas', schRemesasClienteServer_Intf in '..\Modulos\Remesas de cliente\Model\schRemesasClienteServer_Intf.pas',
schAlbaranesClienteClient_Intf in '..\Modulos\Albaranes de cliente\Model\schAlbaranesClienteClient_Intf.pas', schAlbaranesClienteClient_Intf in '..\Modulos\Albaranes de cliente\Model\schAlbaranesClienteClient_Intf.pas',
schAlbaranesClienteServer_Intf in '..\Modulos\Albaranes de cliente\Model\schAlbaranesClienteServer_Intf.pas'; schAlbaranesClienteServer_Intf in '..\Modulos\Albaranes de cliente\Model\schAlbaranesClienteServer_Intf.pas',
schFacturasClienteClient_Intf in '..\Modulos\Facturas de cliente\Model\schFacturasClienteClient_Intf.pas',
schFacturasClienteServer_Intf in '..\Modulos\Facturas de cliente\Model\schFacturasClienteServer_Intf.pas',
schFacturasProveedorClient_Intf in '..\Modulos\Facturas de proveedor\Model\schFacturasProveedorClient_Intf.pas',
schFacturasProveedorServer_Intf in '..\Modulos\Facturas de proveedor\Model\schFacturasProveedorServer_Intf.pas';
{$R *.res} {$R *.res}
{$R ..\Servicios\RODLFile.res} {$R ..\Servicios\RODLFile.res}

View File

@ -16,7 +16,7 @@ BEGIN
VALUE "FileVersion", "2.2.6.0\0" VALUE "FileVersion", "2.2.6.0\0"
VALUE "ProductName", "FactuGES (Servidor)\0" VALUE "ProductName", "FactuGES (Servidor)\0"
VALUE "ProductVersion", "2.2.6.0\0" VALUE "ProductVersion", "2.2.6.0\0"
VALUE "CompileDate", "lunes, 15 de diciembre de 2008 11:00\0" VALUE "CompileDate", "miércoles, 17 de diciembre de 2008 18:10\0"
END END
END END
BLOCK "VarFileInfo" BLOCK "VarFileInfo"

View File

@ -41,8 +41,8 @@ object dmServer: TdmServer
Name = 'IBX' Name = 'IBX'
ConnectionString = ConnectionString =
'IBX?Server=localhost;Database=C:\Codigo Acana\Output\Debug\Datab' + 'IBX?Server=localhost;Database=C:\Codigo Acana\Output\Debug\Datab' +
'ase\FactuGES.FDB;UserID=sysdba;Password=masterkey;Dialect=3;Char' + 'ase\FactuGES_PRODUCCION.FDB;UserID=sysdba;Password=masterkey;Dia' +
'set=ISO8859_1;' 'lect=3;Charset=ISO8859_1;'
ConnectionType = 'Interbase' ConnectionType = 'Interbase'
Default = True Default = True
end> end>