parameters: (request, option)
docstring: Generate the jtable data for audit log entries.
  
      :param request: The request for this jtable.
      :type request: :class:`django.http.HttpRequest`
      :param option: Action to take.
      :type option: str of either 'jtlist', 'jtdelete', or 'inline'.
      :returns: :class:`django.http.HttpResponse`
docstring_summary: Generate the jtable data for audit log entries.
docstring_tokens: Generate the jtable data for audit log entries .
function: def generate_audit_jtable(request, option):
      """
      Generate the jtable data for audit log entries.
  
      :param request: The request for this jtable.
      :type request: :class:`django.http.HttpRequest`
      :param option: Action to take.
      :type option: str of either 'jtlist', 'jtdelete', or 'inline'.
      :returns: :class:`django.http.HttpResponse`
      """
  
      obj_type = AuditLog
      type_ = "audit"
      if option == "jtlist":
          # Sets display url
          details_url = 'crits-core-views-details'
          details_url_key = "target_id"
          response = jtable_ajax_list(obj_type,
                                      details_url,
                                      details_url_key,
                                      request)
          return HttpResponse(json.dumps(response,
                                         default=json_handler),
                              content_type="application/json")
      jtopts = {
          'title': "Audit Log Entries",
          'default_sort': "date DESC",
          'listurl': reverse('crits-core-views-%s_listing' % type_,
                             args=('jtlist',)),
          'deleteurl': '',
          'searchurl': reverse('crits-core-views-%s_listing' % type_),
          'fields': ["details",
                     "user",
                     "type",
                     "method",
                     "value",
                     "date",
                     "id"],
          'hidden_fields': ["id"],
          'linked_fields': [],
          'details_link': 'details',
          'no_sort': ['details', ],
      }
      jtable = build_jtable(jtopts, request)
      jtable['toolbar'] = []
      if option == "inline":
          return render(request, "jtable.html",
                                    {'jtable': jtable,
                                     'jtid': '%s_listing' % type_,
                                     'button': '%ss_tab' % type_})
      else:
          return render(request, "%s_listing.html" % type_,
                                    {'jtable': jtable,
                                     'jtid': '%s_listing' % type_})
function_tokens: def generate_audit_jtable ( request , option ) : obj_type = AuditLog type_ = "audit" if option == "jtlist" : # Sets display url details_url = 'crits-core-views-details' details_url_key = "target_id" response = jtable_ajax_list ( obj_type , details_url , details_url_key , request ) return HttpResponse ( json . dumps ( response , default = json_handler ) , content_type = "application/json" ) jtopts = { 'title' : "Audit Log Entries" , 'default_sort' : "date DESC" , 'listurl' : reverse ( 'crits-core-views-%s_listing' % type_ , args = ( 'jtlist' , ) ) , 'deleteurl' : '' , 'searchurl' : reverse ( 'crits-core-views-%s_listing' % type_ ) , 'fields' : [ "details" , "user" , "type" , "method" , "value" , "date" , "id" ] , 'hidden_fields' : [ "id" ] , 'linked_fields' : [ ] , 'details_link' : 'details' , 'no_sort' : [ 'details' , ] , } jtable = build_jtable ( jtopts , request ) jtable [ 'toolbar' ] = [ ] if option == "inline" : return render ( request , "jtable.html" , { 'jtable' : jtable , 'jtid' : '%s_listing' % type_ , 'button' : '%ss_tab' % type_ } ) else : return render ( request , "%s_listing.html" % type_ , { 'jtable' : jtable , 'jtid' : '%s_listing' % type_ } )