object traza_materiales2: Ttraza_materiales2
  Left = 0
  Top = 0
  Caption = 'Materiales Auxiliares'
  ClientHeight = 599
  ClientWidth = 1075
  Color = clBtnFace
  Font.Charset = DEFAULT_CHARSET
  Font.Color = clWindowText
  Font.Height = -11
  Font.Name = 'Tahoma'
  Font.Style = []
  OldCreateOrder = False
  Position = poOwnerFormCenter
  PixelsPerInch = 96
  TextHeight = 13
  object Panel2: TPanel
    Left = 0
    Top = 49
    Width = 1075
    Height = 550
    Align = alClient
    TabOrder = 0
    ExplicitLeft = -127
    ExplicitTop = -9
    ExplicitWidth = 978
    ExplicitHeight = 308
    object Panel1: TPanel
      Left = 1
      Top = 1
      Width = 1073
      Height = 548
      Align = alClient
      TabOrder = 0
      ExplicitWidth = 976
      ExplicitHeight = 306
      object DBGrid2: TDBGrid
        Left = 1
        Top = 1
        Width = 1071
        Height = 546
        Align = alClient
        DataSource = dsqpesadas
        Font.Charset = DEFAULT_CHARSET
        Font.Color = clWindowText
        Font.Height = -8
        Font.Name = 'Tahoma'
        Font.Style = []
        ParentFont = False
        TabOrder = 0
        TitleFont.Charset = DEFAULT_CHARSET
        TitleFont.Color = clWindowText
        TitleFont.Height = -11
        TitleFont.Name = 'Tahoma'
        TitleFont.Style = []
        Columns = <
          item
            Expanded = False
            FieldName = 'documento'
            Title.Caption = 'Factura'
            Width = 81
            Visible = True
          end
          item
            Expanded = False
            FieldName = 'idea'
            Title.Caption = 'Id'
            Width = 68
            Visible = True
          end
          item
            Expanded = False
            FieldName = 'idaf'
            Title.Caption = 'Id Material'
            Width = 152
            Visible = True
          end
          item
            Expanded = False
            FieldName = 'descripcion'
            Title.Caption = 'Descripcion'
            Width = 236
            Visible = True
          end
          item
            Expanded = False
            FieldName = 'lote'
            Title.Caption = 'Lote Prov'
            Width = 133
            Visible = True
          end
          item
            Expanded = False
            FieldName = 'proveedor'
            Title.Caption = 'Proveedor'
            Width = 220
            Visible = True
          end
          item
            Expanded = False
            FieldName = 'doc_compra'
            Title.Caption = 'Doc. Compra'
            Width = 140
            Visible = True
          end>
      end
    end
  end
  object Panel4: TPanel
    Left = 0
    Top = 0
    Width = 1075
    Height = 49
    Align = alTop
    TabOrder = 1
    ExplicitLeft = -127
    ExplicitWidth = 978
    object btexcel: TButton
      Left = 1
      Top = 1
      Width = 70
      Height = 47
      Align = alLeft
      Caption = 'Exportar a excel'
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clWindowText
      Font.Height = -11
      Font.Name = 'Tahoma'
      Font.Style = [fsBold]
      ImageAlignment = iaBottom
      ImageIndex = 11
      Images = BASE.listaiconos
      ParentFont = False
      TabOrder = 0
      WordWrap = True
      OnClick = btexcelClick
    end
  end
  object SaveDialog1: TSaveDialog
    Left = 296
  end
  object dsqpesadas: TDataSource
    DataSet = qpesadas
    Left = 400
    Top = 88
  end
  object qpesadas: TFDQuery
    Connection = DM.DBagrigest
    SQL.Strings = (
      
        'select mat.idea,mat.idea2,mat.idaf,af.descripcion,mat.cantidad,m' +
        'at.lote,e.documento as doc_compra,p.nombre as proveedor,'#39'21/20'#39' ' +
        'as documento from ea_materiales mat ,articulosf af,entradas_deta' +
        'lle ed,entradas e,proveedores p  where '
      
        'mat.idaf=af.id and mat.ide=af.idempresa and  mat.idaf=ed.id_prop' +
        'io and mat.lote=ed.lote and ed.identrada=e.id and mat.ide=e.idem' +
        'presa and e.idproveedor=p.id and'
      
        '(ide,idea,idea2) in (select idempresa,id,idea from ea_pesadas wh' +
        'ere idfactura='#39'21/20'#39') order by idaf,idea,idea2')
    Params = <>
    Left = 472
    Top = 128
    object qpesadasidea: TIntegerField
      FieldName = 'idea'
      Required = True
    end
    object qpesadasidea2: TIntegerField
      FieldName = 'idea2'
      Required = True
    end
    object qpesadasidaf: TIntegerField
      FieldName = 'idaf'
      Required = True
    end
    object qpesadasdescripcion: TWideStringField
      FieldName = 'descripcion'
      Required = True
      Size = 100
    end
    object qpesadascantidad: TFloatField
      FieldName = 'cantidad'
      Required = True
    end
    object qpesadaslote: TWideStringField
      FieldName = 'lote'
      Size = 40
    end
    object qpesadasdoc_compra: TWideStringField
      FieldName = 'doc_compra'
      Required = True
      Size = 30
    end
    object qpesadasproveedor: TWideStringField
      FieldName = 'proveedor'
      Required = True
      Size = 80
    end
    object qpesadasdocumento: TWideStringField
      FieldName = 'documento'
      ReadOnly = True
      Size = 10
    end
  end
end
