def jqgrid_properties
      vals = {
          :name => name.gsub(".", "__"),
          :index => name
      }
      #xmlmap not required when same as :name
      # vals[:xmlmap]     = name          if data_type == :xml
      # vals[:jsonmap]    = name          if data_type == :json

      vals[:label] = label || name.titleize
      vals[:resizable] = false if resizable==false
      vals[:fixed] = fixed_width unless fixed_width==false
      vals[:sortable] = false if sortable==false
      vals[:sort_type] = jqgrid_type if sortable
      vals[:search] = false if searchable==false
      vals[:editable] = true if editable
      vals[:align] = align if align
      #vals[:align]      = 'right'       if [:integer, :float, :currency].include?(value_type)
      case value_type
        when :datetime
          vals[:formatter] = 'date'
          vals[:formatoptions] = {:srcformat => 'UniversalSortableDateTime', :newformat => 'FullDateTime'}
      end
      vals[:hidden] = true if hidden
      vals[:width] = width if width
      vals[:formatter] = formatter if formatter
      vals[:formatoptions] = format_options if format_options
      vals[:edittype] = edit_type if editable && edit_type
      vals[:formoptions] = form_options if editable && form_options
      vals[:editoptions] = edit_options if editable && edit_options
      vals[:editrules] = validations if editable && validations

      vals[:sort_type] = sort_type if sort_type
      vals[:search_type] = search_type if search_type
      vals[:search_rules] = search_rules if search_rules
      vals[:summaryType] = summary_type if summary_type
      vals[:summaryTpl] = summary_tpl if summary_tpl
      # and more...

      vals
    end
def jqgrid_properties
      vals = {
          :name => name.gsub(".", "__"),
          :index => name
      }
      #xmlmap not required when same as :name
      # vals[:xmlmap]     = name          if data_type == :xml
      # vals[:jsonmap]    = name          if data_type == :json

      vals[:label] = label || name.titleize
      vals[:resizable] = false if resizable==false
      vals[:fixed] = fixed_width unless fixed_width==false
      vals[:sortable] = false if sortable==false
      vals[:sort_type] = jqgrid_type if sortable
      vals[:search] = false if searchable==false
      vals[:editable] = true if editable
      vals[:align] = align if align
      #vals[:align]      = 'right'       if [:integer, :float, :currency].include?(value_type)
      case value_type
        when :datetime
          vals[:formatter] = 'date'
          vals[:formatoptions] = {:srcformat => 'UniversalSortableDateTime', :newformat => 'FullDateTime'}
      end
      vals[:hidden] = true if hidden
      vals[:width] = width if width
      vals[:formatter] = formatter if formatter
      vals[:formatoptions] = format_options if format_options
      vals[:edittype] = edit_type if editable && edit_type
      vals[:formoptions] = form_options if editable && form_options
      vals[:editoptions] = edit_options if editable && edit_options
      vals[:editrules] = validations if editable && validations

      vals[:sort_type] = sort_type if sort_type
      vals[:search_type] = search_type if search_type
      vals[:search_rules] = search_rules if search_rules
      vals[:summaryType] = summary_type if summary_type
      vals[:summaryTpl] = summary_tpl if summary_tpl
      # and more...

      vals
    end
note, we dont vals[:foo] = foo because dont want to bother generating key if its same as jqGrid default