Open amschaal opened 4 months ago
Convert 'table' type properties used by the submission system to their proper 'list' type. Details demonstrated by codeblock below:
def convert_to_jsonschema(coreomics_schema): import copy schema = copy.deepcopy(coreomics_schema) schema['type'] = 'object' # Make changes to schema for prop in schema['properties'].keys(): if 'table' == schema['properties'].get(prop,{}).get('type', '').lower(): list_prop = {'type': 'array', 'items': schema['properties'][prop].pop('schema')} schema['properties'][prop] = list_prop schema['properties'][prop]['items']['type'] = 'object' return schema
Modify frontend code to only work with proper JSON Schema (list of objects).
Convert 'table' type properties used by the submission system to their proper 'list' type. Details demonstrated by codeblock below:
Modify frontend code to only work with proper JSON Schema (list of objects).