This commit is contained in:
roberto 2015-10-26 18:33:00 +00:00
parent f944f5e6e2
commit a2e3fdd629
9 changed files with 184 additions and 151 deletions

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

Binary file not shown.

View File

@ -65,8 +65,6 @@ begin
FDocumento := NIL; FDocumento := NIL;
FImportes := True; FImportes := True;
FNumCapitulos := 0; FNumCapitulos := 0;
FPlantilla := DarRutaInformes + rptInforme;
end; end;
procedure TRptWordCertificadoTrabajo.DataModuleCreate(Sender: TObject); procedure TRptWordCertificadoTrabajo.DataModuleCreate(Sender: TObject);
@ -195,6 +193,7 @@ begin
tbl_Cabecera.Active := True; tbl_Cabecera.Active := True;
tbl_Capitulos.Active := True; tbl_Capitulos.Active := True;
FPlantilla := DarRutaInformes + tbl_Cabecera.FieldByName('ID_EMPRESA').AsString + '\' + rptInforme;
FCodigoPresupuesto := AID; FCodigoPresupuesto := AID;
if RecuperarEmpresa(tbl_Cabecera.FieldByName('ID_EMPRESA').AsInteger, tbl_Empresa) then if RecuperarEmpresa(tbl_Cabecera.FieldByName('ID_EMPRESA').AsInteger, tbl_Empresa) then

View File

@ -444,24 +444,19 @@ begin
with FDocumento, tbl_Cabecera do with FDocumento, tbl_Cabecera do
begin begin
ReplaceBookmark('CodigoPresupuestoPortada', FieldByName('REFERENCIA').AsString);
ReplaceBookmark('FechaPresupuestoPortada', FieldByName('FECHA_PRESUPUESTO').AsString);
ReplaceBookmark('NombreClientePortada', FieldByName('NOMBRE').AsString);
//Solicitan que Azacan tenga nuevamente portada if FDocumento.BookmarkExists('DireccionClientePortada') then
// if (tbl_Cabecera.FieldByName('ID_EMPRESA').AsInteger <> 3) then ReplaceBookmark('DireccionClientePortada', FieldByName('CALLE').AsString);
// begin if FDocumento.BookmarkExists('PoblacionClientePortada') then
ReplaceBookmark('CodigoPresupuestoPortada', FieldByName('REFERENCIA').AsString); ReplaceBookmark('PoblacionClientePortada',
ReplaceBookmark('FechaPresupuestoPortada', FieldByName('FECHA_PRESUPUESTO').AsString); FieldByName('CODIGO_POSTAL').AsString + ' ' +
ReplaceBookmark('NombreClientePortada', FieldByName('NOMBRE').AsString); FieldByName('POBLACION').AsString + ' ' + FieldByName('PROVINCIA').AsString);
if FDocumento.BookmarkExists('DireccionClientePortada') then if not EsCadenaVacia(FieldByName('PERSONA_CONTACTO').AsString) then
ReplaceBookmark('DireccionClientePortada', FieldByName('CALLE').AsString); ReplaceBookmark('PersonaContactoClientePortada', 'A la atención de: ' + FieldByName('PERSONA_CONTACTO').AsString);
if FDocumento.BookmarkExists('PoblacionClientePortada') then
ReplaceBookmark('PoblacionClientePortada',
FieldByName('CODIGO_POSTAL').AsString + ' ' +
FieldByName('POBLACION').AsString + ' ' + FieldByName('PROVINCIA').AsString);
if not EsCadenaVacia(FieldByName('PERSONA_CONTACTO').AsString) then
ReplaceBookmark('PersonaContactoClientePortada', 'A la atención de: ' + FieldByName('PERSONA_CONTACTO').AsString);
// end;
Texto := FieldByName('PORTADA').AsString; Texto := FieldByName('PORTADA').AsString;
NombreFichero := DarFicheroTemporal; NombreFichero := DarFicheroTemporal;

View File

@ -214,90 +214,94 @@ inherited fEditorPresupuestoCliente: TfEditorPresupuestoCliente
inherited ToolButton4: TToolButton inherited ToolButton4: TToolButton
Left = 278 Left = 278
Top = 0 Top = 0
Wrap = True
ExplicitLeft = 278 ExplicitLeft = 278
ExplicitTop = 0 ExplicitTop = 0
end end
inherited ToolButton14: TToolButton inherited ToolButton14: TToolButton
Left = 334
Top = 0
Wrap = True
ExplicitLeft = 334
ExplicitTop = 0
end
inherited ToolButton9: TToolButton
Left = 0 Left = 0
Wrap = False
ExplicitLeft = 0 ExplicitLeft = 0
end end
inherited FontName: TJvFontComboBox inherited FontName: TJvFontComboBox
Left = 145 Left = 65
ExplicitLeft = 544 Top = 22
ExplicitTop = 0 ExplicitTop = 22
end
inherited UpDown1: TUpDown
Left = 689
Top = 0
ExplicitLeft = 689
ExplicitTop = 0
end
inherited ToolButton13: TToolButton
Top = 0
ExplicitTop = 0
end
inherited ToolButton6: TToolButton
Top = 27
ExplicitTop = 27
end end
inherited FontSize: TEdit inherited FontSize: TEdit
Top = 27 Top = 22
Width = 200 Width = 200
ExplicitTop = 27 ExplicitTop = 22
ExplicitWidth = 200 ExplicitWidth = 200
end end
inherited UpDown1: TUpDown
Left = 345
Top = 22
ExplicitLeft = 345
ExplicitTop = 22
end
inherited ToolButton13: TToolButton
Left = 362
Top = 22
ExplicitLeft = 362
ExplicitTop = 22
end
inherited ToolButton6: TToolButton
Left = 370
Top = 22
ExplicitLeft = 370
ExplicitTop = 22
end
inherited ToolButton7: TToolButton inherited ToolButton7: TToolButton
Left = 266 Left = 436
Top = 27 Top = 22
ExplicitLeft = 266 ExplicitLeft = 436
ExplicitTop = 27 ExplicitTop = 22
end
inherited ToolButton11: TToolButton
Left = 333
Top = 27
ExplicitLeft = 333
ExplicitTop = 27
end
inherited ToolButton12: TToolButton
Left = 474
Top = 27
Wrap = False
ExplicitLeft = 474
ExplicitTop = 27
ExplicitHeight = 22
end
inherited ToolButton10: TToolButton
Left = 482
Top = 27
ExplicitLeft = 482
ExplicitTop = 27
end end
inherited ToolButton8: TToolButton inherited ToolButton8: TToolButton
Left = 607 Left = 503
Top = 27 Top = 22
ExplicitLeft = 607 ExplicitLeft = 503
ExplicitTop = 27 ExplicitTop = 22
end
inherited ToolButton12: TToolButton
Left = 0
Top = 22
Wrap = True
ExplicitLeft = 0
ExplicitTop = 22
ExplicitHeight = 27
end
inherited ToolButton9: TToolButton
Left = 0
Top = 49
ExplicitLeft = 0
ExplicitTop = 49
end
inherited ToolButton10: TToolButton
Left = 145
Top = 49
ExplicitLeft = 145
ExplicitTop = 49
end
inherited ToolButton11: TToolButton
Left = 270
Top = 49
ExplicitLeft = 270
ExplicitTop = 49
end end
end end
inherited cxGrid: TcxGrid inherited cxGrid: TcxGrid
Top = 77 Top = 99
Width = 750 Width = 750
Height = 261 Height = 239
ExplicitTop = 77 ExplicitTop = 77
ExplicitWidth = 750 ExplicitWidth = 750
ExplicitHeight = 239 ExplicitHeight = 239
end end
inherited TBXDock1: TTBXDock inherited TBXDock1: TTBXDock
Top = 51 Top = 73
Width = 750 Width = 750
ExplicitTop = 73
ExplicitWidth = 750 ExplicitWidth = 750
inherited TBXToolbar1: TTBXToolbar inherited TBXToolbar1: TTBXToolbar
ExplicitWidth = 750 ExplicitWidth = 750

View File

@ -228,9 +228,6 @@ begin
raise Exception.Create('No hay ningún presupuesto asignado'); raise Exception.Create('No hay ningún presupuesto asignado');
pgPaginas.ActivePage := pagGeneral; pgPaginas.ActivePage := pagGeneral;
//Para AZACAN NO HAY PORTADA EN PRESUPUESTOS
if (AppFactuGES.EmpresaActiva.ID = 3) then
pagPortada.TabVisible := false;
Presupuesto.DataTable.Active := True; Presupuesto.DataTable.Active := True;
end; end;

View File

@ -1,29 +1,63 @@
inherited frViewDetallesPresupuestoCliente: TfrViewDetallesPresupuestoCliente inherited frViewDetallesPresupuestoCliente: TfrViewDetallesPresupuestoCliente
inherited ToolBar1: TToolBar inherited ToolBar1: TToolBar
Height = 100 Height = 73
ExplicitHeight = 100 ExplicitHeight = 73
inherited ToolButton14: TToolButton inherited ToolButton3: TToolButton
Wrap = False Wrap = False
end end
inherited ToolButton9: TToolButton [5] inherited ToolButton4: TToolButton
Left = 121 Left = 278
Top = 0
ExplicitLeft = 278
ExplicitTop = 0
end
inherited ToolButton14: TToolButton
Left = 334
Top = 0
ExplicitLeft = 334
ExplicitTop = 0
end
inherited FontName: TJvFontComboBox
Top = 22 Top = 22
ExplicitLeft = 121
ExplicitTop = 22 ExplicitTop = 22
end end
inherited FontName: TJvFontComboBox [6] inherited FontSize: TEdit
Left = 266
Top = 22 Top = 22
ExplicitLeft = 266 Width = 58
ExplicitTop = 22 ExplicitTop = 22
ExplicitWidth = 58
end end
inherited UpDown1: TUpDown inherited UpDown1: TUpDown
Left = 411 Left = 203
Top = 22 Top = 22
ExplicitLeft = 411 ExplicitLeft = 203
ExplicitTop = 22 ExplicitTop = 22
end end
inherited ToolButton13: TToolButton inherited ToolButton13: TToolButton
Left = 220
Top = 22
ExplicitLeft = 220
ExplicitTop = 22
end
inherited ToolButton6: TToolButton
Left = 228
Top = 22
ExplicitLeft = 228
ExplicitTop = 22
end
inherited ToolButton7: TToolButton
Left = 294
Top = 22
ExplicitLeft = 294
ExplicitTop = 22
end
inherited ToolButton8: TToolButton
Left = 361
Top = 22
ExplicitLeft = 361
ExplicitTop = 22
end
inherited ToolButton12: TToolButton
Left = 0 Left = 0
Top = 22 Top = 22
Wrap = True Wrap = True
@ -31,57 +65,35 @@ inherited frViewDetallesPresupuestoCliente: TfrViewDetallesPresupuestoCliente
ExplicitTop = 22 ExplicitTop = 22
ExplicitHeight = 27 ExplicitHeight = 27
end end
inherited ToolButton6: TToolButton inherited ToolButton9: TToolButton
Left = 0 Left = 0
Top = 49 Top = 49
ExplicitLeft = 0 ExplicitLeft = 0
ExplicitTop = 49 ExplicitTop = 49
end end
inherited FontSize: TEdit [10]
Left = 66
Top = 49
Width = 58
ExplicitLeft = 66
ExplicitTop = 49
ExplicitWidth = 58
end
inherited ToolButton7: TToolButton [11]
Left = 124
Top = 49
ExplicitLeft = 124
ExplicitTop = 49
end
inherited ToolButton11: TToolButton [12]
Left = 191
Top = 49
ExplicitLeft = 191
ExplicitTop = 49
end
inherited ToolButton12: TToolButton [13]
Left = 0
Top = 49
Wrap = True
ExplicitLeft = 0
ExplicitTop = 49
ExplicitHeight = 27
end
inherited ToolButton10: TToolButton inherited ToolButton10: TToolButton
Left = 0 Left = 145
Top = 76 Top = 49
ExplicitLeft = 0 ExplicitLeft = 145
ExplicitTop = 76 ExplicitTop = 49
end end
inherited ToolButton8: TToolButton [15] inherited ToolButton11: TToolButton
Left = 125 Left = 270
Top = 76 Top = 49
ExplicitLeft = 125 ExplicitLeft = 270
ExplicitTop = 76 ExplicitTop = 49
end end
end end
inherited cxGrid: TcxGrid inherited cxGrid: TcxGrid
Top = 126 Top = 99
Height = 178 Height = 205
ExplicitTop = 99
ExplicitHeight = 205
inherited cxGridView: TcxGridDBTableView inherited cxGridView: TcxGridDBTableView
inherited cxGridViewTIPO: TcxGridDBColumn
Visible = False
VisibleForCustomization = False
end
inherited cxGridViewREFERENCIA_PROVEEDOR: TcxGridDBColumn inherited cxGridViewREFERENCIA_PROVEEDOR: TcxGridDBColumn
DataBinding.FieldName = '' DataBinding.FieldName = ''
end end
@ -94,7 +106,8 @@ inherited frViewDetallesPresupuestoCliente: TfrViewDetallesPresupuestoCliente
end end
end end
inherited TBXDock1: TTBXDock inherited TBXDock1: TTBXDock
Top = 100 Top = 73
ExplicitTop = 73
inherited TBXToolbar1: TTBXToolbar inherited TBXToolbar1: TTBXToolbar
object TBXSeparatorItem9: TTBXSeparatorItem object TBXSeparatorItem9: TTBXSeparatorItem
end end