def create_package_schema(self): ''' Returns the schema for mapping package data from a form to a format suitable for the database. ''' from ckanext.harvest.logic.schema import harvest_source_create_package_schema schema = harvest_source_create_package_schema() if self.startup: schema['id'] = [unicode] schema.update({ 'catalogue_country': [tk.get_validator('ignore_missing'), tk.get_converter('convert_to_extras')] }) schema.update({ 'catalogue_date_created': [tk.get_validator('ignore_missing'), tk.get_converter('convert_to_extras')] }) schema.update({ 'catalogue_date_updated': [tk.get_validator('ignore_missing'), tk.get_converter('convert_to_extras')] }) schema.update({ 'language': [tk.get_validator('ignore_missing'), tk.get_converter('convert_to_extras')] }) return schema
def create_package_schema(self): ''' Returns the schema for mapping package data from a form to a format suitable for the database. ''' from ckanext.harvest.logic.schema import harvest_source_create_package_schema, unicode_safe schema = harvest_source_create_package_schema() if self.startup: schema['id'] = [unicode_safe] return schema
def create_package_schema(self): ''' Returns the schema for mapping package data from a form to a format suitable for the database. ''' from ckanext.harvest.logic.schema import harvest_source_create_package_schema schema = harvest_source_create_package_schema() if self.startup: schema['id'] = [unicode] return schema
def harvest_source_create_package_schema(cls): from ckanext.harvest.logic.schema import harvest_source_create_package_schema return cls._harvest_non_unique_url(harvest_source_create_package_schema())
def harvest_source_create_package_schema(cls): from ckanext.harvest.logic.schema import harvest_source_create_package_schema return cls._harvest_non_unique_url( harvest_source_create_package_schema())