parameters: (search_type)
return_statement: return widget_config
docstring: get a schema config for a search type
docstring_summary: get a schema config for a search type
docstring_tokens: get a schema config for a search type
function: def get_schema_config(search_type):
          '''get a schema config for a search type'''
          xml = Xml(string='<config/>')
          root = xml.get_root_node()
          view = 'schema_definition'
          view_node = xml.create_element(view)
          xml.append_child(root, view_node)
          widget_config = None
  
          info = SearchType.get_column_info(search_type)
          columns = SearchType.get_columns(search_type)
  
          for column in columns:
              el = xml.create_element('element')
              Xml.set_attribute(el, 'name', column)
              dict = info.get(column)
              data_type = dict.get('data_type')
              nullable = dict.get('nullable')
  
              Xml.set_attribute(el, 'data_type', data_type)
              Xml.set_attribute(el, 'nullable', nullable)
              xml.append_child(view_node, el)
          from pyasm.widget import WidgetConfig
          widget_config = WidgetConfig.get(view=view, xml=xml.to_string())
          return widget_config
function_tokens: def get_schema_config ( search_type ) : xml = Xml ( string = '<config/>' ) root = xml . get_root_node ( ) view = 'schema_definition' view_node = xml . create_element ( view ) xml . append_child ( root , view_node ) widget_config = None info = SearchType . get_column_info ( search_type ) columns = SearchType . get_columns ( search_type ) for column in columns : el = xml . create_element ( 'element' ) Xml . set_attribute ( el , 'name' , column ) dict = info . get ( column ) data_type = dict . get ( 'data_type' ) nullable = dict . get ( 'nullable' ) Xml . set_attribute ( el , 'data_type' , data_type ) Xml . set_attribute ( el , 'nullable' , nullable ) xml . append_child ( view_node , el ) from pyasm . widget import WidgetConfig widget_config = WidgetConfig . get ( view = view , xml = xml . to_string ( ) ) return widget_config