2011-11-14 17:40:41 +00:00
|
|
|
|
unit uViewConfiguracionDocBano;
|
|
|
|
|
|
|
|
|
|
|
|
interface
|
|
|
|
|
|
|
|
|
|
|
|
uses
|
|
|
|
|
|
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
|
|
|
|
|
|
Dialogs, uViewConfiguracionBase, cxControls, cxContainer, cxEdit, cxTextEdit, cxMemo,
|
2011-11-18 17:12:39 +00:00
|
|
|
|
cxRichEdit, uViewBase, JvExControls, JvGradientHeaderPanel, StdCtrls, ExtCtrls,
|
2012-07-11 15:39:13 +00:00
|
|
|
|
ComCtrls, uCustomView, uViewDetallesBase, uViewConfiguracionCapitulo,
|
2013-09-25 17:13:02 +00:00
|
|
|
|
uViewDetallesDTO, uViewDetallesArticulos, cxGraphics, DB, uDAInterfaces,
|
|
|
|
|
|
uDADataTable, cxMaskEdit, cxDropDownEdit, cxLookupEdit, cxDBLookupEdit,
|
|
|
|
|
|
cxDBLookupComboBox, uFormasPagoController, uBizFormasPago;
|
2011-11-14 17:40:41 +00:00
|
|
|
|
|
|
|
|
|
|
type
|
2012-07-11 15:39:13 +00:00
|
|
|
|
TfrViewConfiguracionDocBANO = class(TfrViewConfiguracionBase)
|
|
|
|
|
|
paginas: TPageControl;
|
|
|
|
|
|
pagNotas: TTabSheet;
|
|
|
|
|
|
Label1: TLabel;
|
2011-11-14 17:40:41 +00:00
|
|
|
|
Label2: TLabel;
|
|
|
|
|
|
Label4: TLabel;
|
2012-07-11 15:39:13 +00:00
|
|
|
|
ePlazosEntrega: TMemo;
|
|
|
|
|
|
eFormaPago: TMemo;
|
|
|
|
|
|
eObservaciones: TMemo;
|
|
|
|
|
|
pagCapitulo: TTabSheet;
|
|
|
|
|
|
frViewConfiguracionCapitulo: TfrViewConfiguracionCapitulo;
|
|
|
|
|
|
pagCondiciones: TTabSheet;
|
|
|
|
|
|
eCondiciones: TcxRichEdit;
|
2013-09-25 17:13:02 +00:00
|
|
|
|
cbFormaPago: TcxLookupComboBox;
|
|
|
|
|
|
dsFormaPago: TDADataSource;
|
|
|
|
|
|
protected
|
|
|
|
|
|
FFormasPago : IBizFormaPago;
|
|
|
|
|
|
FFormasPagoController : IFormasPagoController;
|
|
|
|
|
|
|
2011-11-14 17:40:41 +00:00
|
|
|
|
public
|
|
|
|
|
|
class function GetViewClass : TClass; override;
|
|
|
|
|
|
class function DarEtiqueta : String; override;
|
|
|
|
|
|
procedure CargarValores; override;
|
|
|
|
|
|
procedure GuardarValores; override;
|
|
|
|
|
|
end;
|
|
|
|
|
|
|
|
|
|
|
|
var
|
2012-07-11 15:39:13 +00:00
|
|
|
|
frViewConfiguracionDocBANO: TfrViewConfiguracionDocBANO;
|
2011-11-14 17:40:41 +00:00
|
|
|
|
|
|
|
|
|
|
implementation
|
|
|
|
|
|
{$R *.dfm}
|
|
|
|
|
|
{ TfrViewConfiguracionDocBANO }
|
|
|
|
|
|
|
2012-07-11 15:39:13 +00:00
|
|
|
|
uses uFactuGES_App, uConfiguracionController, uPresupuestosClienteController,
|
|
|
|
|
|
uBizDetallesPresupuestoCliente, uDetallesPresupuestoClienteController;
|
2011-11-14 17:40:41 +00:00
|
|
|
|
|
2012-07-11 15:39:13 +00:00
|
|
|
|
procedure TfrViewConfiguracionDocBANO.CargarValores;
|
2011-11-14 17:40:41 +00:00
|
|
|
|
begin
|
|
|
|
|
|
inherited;
|
2013-09-25 17:13:02 +00:00
|
|
|
|
JvGradientHeaderPanel1.LabelCaption := JvGradientHeaderPanel1.LabelCaption + AppFactuGES.EmpresaActiva.NOMBRE;
|
|
|
|
|
|
|
|
|
|
|
|
FFormasPago := Nil;
|
|
|
|
|
|
FFormasPagoController := TFormasPagoController.Create;
|
|
|
|
|
|
FFormasPago := FFormasPagoController.BuscarTodos;
|
|
|
|
|
|
dsFormaPago.DataTable := FFormasPago.DataTable;
|
|
|
|
|
|
dsFormaPago.DataTable.Active := True;
|
|
|
|
|
|
|
2011-11-14 17:40:41 +00:00
|
|
|
|
ePlazosEntrega.Lines.Clear;
|
2013-09-25 17:13:02 +00:00
|
|
|
|
ePlazosEntrega.Text := AppFactuGES.Configuracion.GetSettingAsString(teBD,CTE_PLAZOS_ENTREGA_BANO, AppFactuGES.EmpresaActiva.ID);
|
2011-11-14 17:40:41 +00:00
|
|
|
|
eObservaciones.Lines.Clear;
|
2013-09-25 17:13:02 +00:00
|
|
|
|
eObservaciones.Text := AppFactuGES.Configuracion.GetSettingAsString(teBD,CTE_OBSERVACIONES_BANO, AppFactuGES.EmpresaActiva.ID);
|
2011-11-14 17:40:41 +00:00
|
|
|
|
eCondiciones.Lines.Clear;
|
2013-09-25 17:13:02 +00:00
|
|
|
|
eCondiciones.Text := AppFactuGES.Configuracion.GetSettingAsString(teBD,CTE_CONDICIONES_BANO, AppFactuGES.EmpresaActiva.ID);
|
|
|
|
|
|
|
|
|
|
|
|
cbFormaPago.EditValue := AppFactuGES.Configuracion.GetSettingAsString(teBD,CTE_FORMA_PAGO_BANO, AppFactuGES.EmpresaActiva.ID);
|
|
|
|
|
|
// eFormaPago.Lines.Clear;
|
|
|
|
|
|
// eFormaPago.Text := AppFactuGES.Configuracion.GetSettingAsString(teBD,CTE_FORMA_PAGO_BANO);
|
|
|
|
|
|
|
2011-11-14 17:40:41 +00:00
|
|
|
|
|
2012-07-11 15:39:13 +00:00
|
|
|
|
frViewConfiguracionCapitulo.Controller := TDetallesPresupuestoClienteController.Create;
|
|
|
|
|
|
frViewConfiguracionCapitulo.Detalles := (frViewConfiguracionCapitulo.Controller as IDetallesPresupuestoClienteController).BuscarCapitulo(TIPO_CAPITULO_B);
|
2011-11-18 17:12:39 +00:00
|
|
|
|
end;
|
|
|
|
|
|
|
2012-07-11 15:39:13 +00:00
|
|
|
|
class function TfrViewConfiguracionDocBANO.DarEtiqueta: String;
|
2011-11-14 17:40:41 +00:00
|
|
|
|
begin
|
|
|
|
|
|
Result := 'Documentos ba<62>o';
|
|
|
|
|
|
end;
|
|
|
|
|
|
|
2012-07-11 15:39:13 +00:00
|
|
|
|
class function TfrViewConfiguracionDocBANO.GetViewClass: TClass;
|
2011-11-14 17:40:41 +00:00
|
|
|
|
begin
|
|
|
|
|
|
Result := TfrViewConfiguracionDocBANO;
|
|
|
|
|
|
end;
|
|
|
|
|
|
|
2012-07-11 15:39:13 +00:00
|
|
|
|
procedure TfrViewConfiguracionDocBANO.GuardarValores;
|
2011-11-14 17:40:41 +00:00
|
|
|
|
begin
|
|
|
|
|
|
inherited;
|
2013-09-25 17:13:02 +00:00
|
|
|
|
// AppFactuGES.Configuracion.SetSettingAsString(teBD, CTE_FORMA_PAGO_BANO, eFormaPago.Text);
|
|
|
|
|
|
AppFactuGES.Configuracion.SetSettingAsString(teBD, CTE_FORMA_PAGO_BANO, AppFactuGES.EmpresaActiva.ID, cbFormaPago.EditValue);
|
|
|
|
|
|
AppFactuGES.Configuracion.SetSettingAsString(teBD, CTE_PLAZOS_ENTREGA_BANO, AppFactuGES.EmpresaActiva.ID, ePlazosEntrega.Text);
|
|
|
|
|
|
AppFactuGES.Configuracion.SetSettingAsString(teBD, CTE_OBSERVACIONES_BANO, AppFactuGES.EmpresaActiva.ID, eObservaciones.Text);
|
|
|
|
|
|
AppFactuGES.Configuracion.SetSettingAsString(teBD, CTE_CONDICIONES_BANO, AppFactuGES.EmpresaActiva.ID, eCondiciones.Text);
|
2012-07-11 15:39:13 +00:00
|
|
|
|
|
|
|
|
|
|
frViewConfiguracionCapitulo.Detalles.DataTable.ApplyUpdates;
|
2011-11-14 17:40:41 +00:00
|
|
|
|
end;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
end.
|