object srvTiposIVA: TsrvTiposIVA
  OldCreateOrder = True
  OnCreate = DARemoteServiceCreate
  RequiresSession = True
  SessionManager = dmServer.SessionManager
  AcquireConnection = True
  ServiceSchema = schTiposIVA
  ServiceAdapter = DABINAdapter
  OnBeforeAcquireConnection = DARemoteServiceBeforeAcquireConnection
  Height = 300
  Width = 334
  object Diagrams: TDADiagrams
    Left = 150
    Top = 80
    DiagramData = '<Diagrams>'#13#10'</Diagrams>'#13#10
  end
  object DataDictionary: TDADataDictionary
    Fields = <
      item
        Name = 'TIPOS_IVA_ID'
        DataType = datInteger
        BlobType = dabtUnknown
        DisplayWidth = 0
        Alignment = taLeftJustify
      end
      item
        Name = 'TIPOS_IVA_REFERENCIA'
        DataType = datString
        Size = 255
        BlobType = dabtUnknown
        DisplayWidth = 0
        DisplayLabel = 'Referencia'
        Alignment = taLeftJustify
      end
      item
        Name = 'TIPOS_IVA_DESCRIPCION'
        DataType = datString
        Size = 255
        BlobType = dabtUnknown
        DisplayWidth = 0
        DisplayLabel = 'Descripci'#243'n'
        Alignment = taLeftJustify
      end
      item
        Name = 'TIPOS_IVA_IVA'
        DataType = datFloat
        BlobType = dabtUnknown
        DisplayWidth = 0
        DisplayLabel = '% IVA'
        Alignment = taRightJustify
      end
      item
        Name = 'TIPOS_IVA_RE'
        DataType = datFloat
        BlobType = dabtUnknown
        DisplayWidth = 0
        DisplayLabel = '% RE'
        Alignment = taRightJustify
      end>
    Left = 150
    Top = 24
  end
  object schTiposIVA: TDASchema
    ConnectionManager = dmServer.ConnectionManager
    DataDictionary = DataDictionary
    Diagrams = Diagrams
    Datasets = <
      item
        Params = <>
        Statements = <
          item
            Connection = 'IBX'
            TargetTable = 'TIPOS_IVA'
            SQL = 
              'SELECT '#10'    ID, REFERENCIA, DESCRIPCION, IVA, RE'#10'  FROM'#10'    TIPO' +
              'S_IVA'
            StatementType = stSQL
            ColumnMappings = <
              item
                DatasetField = 'ID'
                TableField = 'ID'
              end
              item
                DatasetField = 'REFERENCIA'
                TableField = 'REFERENCIA'
              end
              item
                DatasetField = 'DESCRIPCION'
                TableField = 'DESCRIPCION'
              end
              item
                DatasetField = 'IVA'
                TableField = 'IVA'
              end
              item
                DatasetField = 'RE'
                TableField = 'RE'
              end>
          end>
        Name = 'TiposIVA'
        Fields = <
          item
            Name = 'ID'
            DataType = datInteger
            BlobType = dabtUnknown
            DictionaryEntry = 'TIPOS_IVA_ID'
            InPrimaryKey = True
            Calculated = False
            Lookup = False
            LookupCache = False
          end
          item
            Name = 'REFERENCIA'
            DataType = datString
            Size = 255
            BlobType = dabtUnknown
            DictionaryEntry = 'TIPOS_IVA_REFERENCIA'
            InPrimaryKey = False
            Calculated = False
            Lookup = False
            LookupCache = False
          end
          item
            Name = 'DESCRIPCION'
            DataType = datString
            Size = 255
            BlobType = dabtUnknown
            DictionaryEntry = 'TIPOS_IVA_DESCRIPCION'
            InPrimaryKey = False
            Calculated = False
            Lookup = False
            LookupCache = False
          end
          item
            Name = 'IVA'
            DataType = datFloat
            BlobType = dabtUnknown
            DictionaryEntry = 'TIPOS_IVA_IVA'
            InPrimaryKey = False
            Calculated = False
            Lookup = False
            LookupCache = False
          end
          item
            Name = 'RE'
            DataType = datFloat
            BlobType = dabtUnknown
            DictionaryEntry = 'TIPOS_IVA_RE'
            InPrimaryKey = False
            Calculated = False
            Lookup = False
            LookupCache = False
          end>
        BusinessRulesClient.ScriptLanguage = rslPascalScript
        BusinessRulesServer.ScriptLanguage = rslPascalScript
      end>
    Commands = <
      item
        Params = <
          item
            Name = 'ID'
            DataType = datInteger
            BlobType = dabtUnknown
            Value = ''
            ParamType = daptInput
          end
          item
            Name = 'REFERENCIA'
            DataType = datString
            Size = 255
            BlobType = dabtUnknown
            Value = ''
            ParamType = daptInput
          end
          item
            Name = 'DESCRIPCION'
            DataType = datString
            Size = 255
            BlobType = dabtUnknown
            Value = ''
            ParamType = daptInput
          end
          item
            Name = 'IVA'
            DataType = datFloat
            BlobType = dabtUnknown
            Value = ''
            ParamType = daptInput
          end
          item
            Name = 'RE'
            DataType = datFloat
            BlobType = dabtUnknown
            Value = ''
            ParamType = daptInput
          end>
        Statements = <
          item
            Connection = 'IBX'
            TargetTable = 'TIPOS_IVA'
            SQL = 
              'INSERT'#10'  INTO TIPOS_IVA'#10'    (ID, REFERENCIA, DESCRIPCION, IVA, R' +
              'E)'#10'  VALUES'#10'    (:ID, :REFERENCIA, :DESCRIPCION, :IVA, :RE)'
            StatementType = stSQL
            ColumnMappings = <>
          end>
        Name = 'Insert_TiposIVA'
      end
      item
        Params = <
          item
            Name = 'OLD_ID'
            DataType = datInteger
            BlobType = dabtUnknown
            Value = ''
            ParamType = daptInput
          end>
        Statements = <
          item
            Connection = 'IBX'
            TargetTable = 'TIPOS_IVA'
            SQL = 'DELETE '#10'  FROM'#10'    TIPOS_IVA'#10'  WHERE'#10'    (ID = :OLD_ID)'
            StatementType = stSQL
            ColumnMappings = <>
          end>
        Name = 'Delete_TiposIVA'
      end
      item
        Params = <
          item
            Name = 'REFERENCIA'
            DataType = datString
            Size = 255
            BlobType = dabtUnknown
            Value = ''
            ParamType = daptInput
          end
          item
            Name = 'DESCRIPCION'
            DataType = datString
            Size = 255
            BlobType = dabtUnknown
            Value = ''
            ParamType = daptInput
          end
          item
            Name = 'IVA'
            DataType = datFloat
            BlobType = dabtUnknown
            Value = ''
            ParamType = daptInput
          end
          item
            Name = 'RE'
            DataType = datFloat
            BlobType = dabtUnknown
            Value = ''
            ParamType = daptInput
          end
          item
            Name = 'OLD_ID'
            DataType = datInteger
            BlobType = dabtUnknown
            Value = ''
            ParamType = daptInput
          end>
        Statements = <
          item
            Connection = 'IBX'
            TargetTable = 'TIPOS_IVA'
            SQL = 
              'UPDATE TIPOS_IVA'#10'  SET '#10'    REFERENCIA = :REFERENCIA,'#10'    DESCRI' +
              'PCION = :DESCRIPCION, '#10'    IVA = :IVA, '#10'    RE = :RE'#10'  WHERE'#10'   ' +
              ' (ID = :OLD_ID)'
            StatementType = stSQL
            ColumnMappings = <>
          end>
        Name = 'Update_TiposIVA'
      end>
    RelationShips = <>
    UpdateRules = <
      item
        Name = 'Insert Familias'
        DoUpdate = False
        DoInsert = True
        DoDelete = False
        DatasetName = 'Familias'
        FailureBehaviour = fbRaiseException
      end
      item
        Name = 'Update Familias'
        DoUpdate = True
        DoInsert = False
        DoDelete = False
        DatasetName = 'Familias'
        FailureBehaviour = fbRaiseException
      end
      item
        Name = 'Delete Familias'
        DoUpdate = False
        DoInsert = False
        DoDelete = True
        DatasetName = 'Familias'
        FailureBehaviour = fbRaiseException
      end>
    Left = 48
    Top = 24
  end
  object DABINAdapter: TDABINAdapter
    Left = 48
    Top = 80
  end
  object bpTiposIVA: TDABusinessProcessor
    Schema = schTiposIVA
    InsertCommandName = 'Insert_TiposIVA'
    DeleteCommandName = 'Delete_TiposIVA'
    UpdateCommandName = 'Update_TiposIVA'
    ReferencedDataset = 'TiposIVA'
    ProcessorOptions = [poAutoGenerateRefreshDataset, poPrepareCommands]
    UpdateMode = updWhereKeyOnly
    Left = 251
    Top = 24
  end
end
