Changeset cea7e94 in rattail


Ignore:
Timestamp:
04/03/19 22:11:06 (10 months ago)
Author:
Lance Edgar <ledgar@…>
Branches:
master
Children:
7ed5ebc
Parents:
883df8f
Message:

Set importer direction early, in case supported_fields needs it

sometimes the supported field list may depend on target system, e.g. not all
data needs to go to all nodes

File:
1 edited

Legend:

Unmodified
Added
Removed
  • rattail/importing/importers.py

    r883df8f rcea7e94  
    109109    field_coltypes = {}
    110110
    111     def __init__(self, config=None, key=None, fields=None, exclude_fields=None, **kwargs):
     111    def __init__(self, config=None, key=None, direction='import', fields=None, exclude_fields=None, **kwargs):
    112112        self.config = config
    113113        self.enum = config.get_enum() if config else None
     
    115115        if key is not None:
    116116            self.key = key
     117        self.direction = direction
    117118        self.fields = fields or self.supported_fields
    118119        if exclude_fields:
Note: See TracChangeset for help on using the changeset viewer.