<commit_before>-widget_title = "Related to " + instance.class.to_s.titleize if local_assigns[:widget_title].nil?

-near_model = instance.class.to_s
-near_model = "Process" if near_model == "System" && instance.is_biz_process?

-models = related_objects(instance)
-#left_models, right_models = arranged_related_objects(instance)

-content_for :widget_title do
  =widget_title

-content_for :widget_id, "related_widget"

-content_for :widget_help, 'related'
#related.open
  .row-fluid
    .span12
      .tabbable
        %ul.nav.nav-tabs
          -check_model_risk_authorization(models).each do |model|
            -table_name = model.underscore.pluralize #.table_name
            -icon = "grcicon-#{model.downcase}-color"
            %li{:class => "tab-btn text-#{model.downcase}"}
              %a{:href => "#related-#{table_name}-pane",
                "data-toggle" => 'tab',
                "data-source" => related_objects_flow_relationships_path(:oid => instance.id,
                  :otype => near_model,
                  :related_model => model),
                "data-template" => "/assets/related.mustache",
                "data-refresh-time" => 60 }
                %i{:class => icon }
                #{table_name.titleize}
  .tab-content
    -models.each do |model|
      .tab-pane{:id => "related-#{model.underscore.pluralize}-pane"}
        Data for #{model.titleize}<commit_msg>story 43112191: changing view code to reflect refactored count method<commit_after>-widget_title = "Related to " + instance.class.to_s.titleize if local_assigns[:widget_title].nil?

-near_model = instance.class.to_s
-near_model = "Process" if near_model == "System" && instance.is_biz_process?

-models = related_objects(instance)
-#left_models, right_models = arranged_related_objects(instance)

-content_for :widget_title do
  =widget_title

-content_for :widget_id, "related_widget"

-content_for :widget_help, 'related'
#related.open
  .row-fluid
    .span12
      .tabbable
        %ul.nav.nav-tabs
          -check_model_risk_authorization(models).each do |model|
            -table_name = model.underscore.pluralize #.table_name
            -icon = "grcicon-#{model.downcase}-color"
            %li{:class => "tab-btn text-#{model.downcase}"}
              %a{:href => "#related-#{table_name}-pane",
                "data-toggle" => 'tab',
                "data-source" => related_objects_flow_relationships_path(:oid => instance.id,
                  :otype => near_model,
                  :related_model => model),
                "data-template" => "/assets/related.mustache",
                "data-refresh-time" => 60 }
                %i{:class => icon }
                #{table_name.titleize + ' (' + instance.count_destination_objects(model).to_s + ')'}
  .tab-content
    -models.each do |model|
      .tab-pane{:id => "related-#{model.underscore.pluralize}-pane"}
        Data for #{model.titleize}
{'fraction_non_alphanumeric': 0.1401098901098901, 'fraction_numerical': 0.005494505494505495, 'mean_word_length': 2.6186335403726706, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 25, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4202770', 'n_tokens_mistral': 962, 'n_tokens_neox': 922, 'n_words': 153}