code: def get_config(context, **kw):
      
      # get the ID formatting config
      config_map = api.get_bika_setup().getIDFormatting()
  
      # allow portal_type override
      portal_type = get_type_id(context, **kw)
  
      # check if we have a config for the given portal_type
      for config in config_map:
          if config['portal_type'].lower() == portal_type.lower():
              return config
  
      # return a default config
      default_config = {
          'form': '%s-{seq}' % portal_type.lower(),
          'sequence_type': 'generated',
          'prefix': '%s' % portal_type.lower(),
      }
      return default_config
docs: Fetch the config dict from the Bika Setup for the given portal_type