2019-07-01 15:39:49 +00:00
|
|
|
unit uEditorElegirFechaVencimiento;
|
|
|
|
|
|
|
|
|
|
interface
|
|
|
|
|
|
|
|
|
|
uses
|
|
|
|
|
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
|
|
|
|
|
Dialogs, StdCtrls, cxControls, cxContainer, cxEdit, cxTextEdit, cxMaskEdit,
|
|
|
|
|
cxDropDownEdit, cxCalendar, ExtCtrls, uEditorBasico, uIEditorElegirFechaVencimiento,
|
|
|
|
|
cxGraphics, DB, uDAInterfaces, uDADataTable, cxDBEdit, uEmpresasController;
|
|
|
|
|
|
|
|
|
|
type
|
|
|
|
|
TfEditorElegirFechaVencimiento = class(TfEditorBasico, IEditorElegirFechaVencimiento)
|
|
|
|
|
Label1: TLabel;
|
|
|
|
|
bAceptar: TButton;
|
|
|
|
|
bCancelar: TButton;
|
|
|
|
|
Label2: TLabel;
|
|
|
|
|
Panel1: TPanel;
|
|
|
|
|
Label3: TLabel;
|
|
|
|
|
cbFechaVencimiento: TcxDateEdit;
|
|
|
|
|
procedure FormShow(Sender: TObject);
|
|
|
|
|
|
|
|
|
|
private
|
|
|
|
|
FFechaVencimiento: datetime;
|
|
|
|
|
function GetFechaVencimiento: datetime;
|
|
|
|
|
procedure SetFechaVencimiento(const Value: datetime);
|
|
|
|
|
|
|
|
|
|
public
|
|
|
|
|
property FechaVencimiento: datetime Read GetFechaVencimiento write SetFechaVencimiento;
|
|
|
|
|
end;
|
|
|
|
|
|
|
|
|
|
implementation
|
|
|
|
|
{$R *.dfm}
|
|
|
|
|
|
2020-03-11 18:03:13 +00:00
|
|
|
uses uFactuGES_App, DateUtils;
|
2019-07-01 15:39:49 +00:00
|
|
|
|
|
|
|
|
procedure TfEditorElegirFechaVencimiento.FormShow(Sender: TObject);
|
|
|
|
|
begin
|
2020-03-11 18:03:13 +00:00
|
|
|
cbFechaVencimiento.EditValue := DateOf(Date);
|
2019-07-01 15:39:49 +00:00
|
|
|
end;
|
|
|
|
|
|
|
|
|
|
function TfEditorElegirFechaVencimiento.GetFechaVencimiento: datetime;
|
|
|
|
|
begin
|
|
|
|
|
Result := cbFechaVencimiento.EditValue;
|
|
|
|
|
end;
|
|
|
|
|
|
|
|
|
|
procedure TfEditorElegirFechaVencimiento.SetFechaVencimiento(const Value: datetime);
|
|
|
|
|
begin
|
|
|
|
|
cbFechaVencimiento.EditValue := Value;
|
|
|
|
|
end;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
end.
|