<commit_before>- iteration_label = @iteration == @iteration.project.current_iteration ? "Current Iteration" : "Old Iteration"
- iteration_label = "Future Iteration" if @iteration.start_date >= Date.today
- days_left = @iteration.current? ? " (#{@iteration.days_left} #{@iteration.days_left == 1 ? "day" : "days"} left)" : ""
%h1 
  = h("#{iteration_label} #{dates_interval(@iteration.start_date, @iteration.end_date)}#{days_left}")

= link_to 'Edit', edit_project_iteration_url(@iteration.project,@iteration)
= "|"
= link_to 'All Iterations', project_iterations_path(@iteration.project)
- if @previous_iteration
  = "|"
  = link_to 'Prev. Iteraion', iteration_stories_url(@previous_iteration)
- if @next_iteration
  = "|"
  = link_to 'Next Iteration', iteration_stories_url(@next_iteration)



%p
  %b Objectives:
  = (@iteration.objectives.strip == "") ? "N/A" : @iteration.objectives
%p
  %b Work units:
  Limit: 
  %b= @iteration.work_units
  , Planned: 
  %b= @iteration.work_units_planned
  , Done: 
  %b= @iteration.work_units_real

= burndown_chart(@iteration.burndown, @iteration.work_units_planned)
= velocity_chart(@project.velocity, @iteration.id)

%fieldset.subsection
  %legend.subsection Stories/Tasks
  %div{:style => "margin-bottom:1em"}
    %span= link_to '<strong>Add story</strong>', new_iteration_meeting_path(@iteration)
    = "|"
    %span#toggle_stories.hide_stories= link_to '<strong>Collapse Stories</strong>', "#toggle"
  - @stories.each do |story|
    .story{:id => "story_" + story.id.to_s}
      .story_title
        %table.story_info
          %tr
            %td{:style => "width:8em"}= story_completion(story)
            %td{:style => "width:25em"}
              %b= story.name.capitalize
            %td{:style => "width:5em"}==  (#{story.work_units_est} w.u.) 
            %td{:style => "width:3em"}= link_to "edit", edit_iteration_story_url(@iteration, story)
            %td{:style => "width:3em"}= link_to "delete", iteration_story_url(@iteration, story), :method => "delete", :confirm => "Are you sure?"
      .agile_tasks
        = link_to "<strong>Add task</strong>", new_story_agile_task_url(story)
        - if !story.agile_tasks.empty?
          %table{:class => "data bordered"}
            %thead
              %tr
                %th Task Name
                %th Bug?
                %th Done?
                %th Owners
                %th t.u.
                %th{:colspan => "2"} Actions

            - story.agile_tasks_sorted.each do |task|
              - tr_class = (!task.completion_date? && task.task_owners.size > 0) ? "task_active" : "task_inactive"
              - td_class = task.completion_date? ? "task_complete" : "task_incomplete"
              %tr{:id => "task_" + task.id.to_s, :class => tr_class}
                %td{:style => "width:35em;", :class => td_class}= link_to_task task.name, task
                %td{:style => "width:2em;"}= link_to_task((task.bug? ? '<span style="color:red">yes</span>' : '-'), task)
                %td{:style => "width:2em;"}= link_to_task((task.completion_date ? 'yes' : '-'), task)
                %td= link_to_task task_owners(task), task
                %td{:style => "width:2em;"}= link_to_task((task.task_units ? task.task_units : '-'), task)
                %td= link_to_task('edit', task)
                %td= link_to 'delete', story_agile_task_url(story, task), :method => "delete", :confirm => "Are you sure?"

  %div{:style => "margin-bottom:1em"}
    %span= link_to '<strong>Add story</strong>', new_iteration_meeting_path(@iteration)

%fieldset.subsection
  %legend.subsection Meetings
  = link_to 'Add meeting', new_iteration_meeting_path(@iteration) 
  
  - if !@meetings.empty?
    %table{:class => "data bordered"}
      %thead
        %tr
          %th Date
          %th Meeting
          %th length (w.u)
          %th{:style => "width: 30em"} Participants<commit_msg>bug add story returned meetins instead<commit_after>- iteration_label = @iteration == @iteration.project.current_iteration ? "Current Iteration" : "Old Iteration"
- iteration_label = "Future Iteration" if @iteration.start_date >= Date.today
- days_left = @iteration.current? ? " (#{@iteration.days_left} #{@iteration.days_left == 1 ? "day" : "days"} left)" : ""
%h1 
  = h("#{iteration_label} #{dates_interval(@iteration.start_date, @iteration.end_date)}#{days_left}")

= link_to 'Edit', edit_project_iteration_url(@iteration.project,@iteration)
= "|"
= link_to 'All Iterations', project_iterations_path(@iteration.project)
- if @previous_iteration
  = "|"
  = link_to 'Prev. Iteraion', iteration_stories_url(@previous_iteration)
- if @next_iteration
  = "|"
  = link_to 'Next Iteration', iteration_stories_url(@next_iteration)



%p
  %b Objectives:
  = (@iteration.objectives.strip == "") ? "N/A" : @iteration.objectives
%p
  %b Work units:
  Limit: 
  %b= @iteration.work_units
  , Planned: 
  %b= @iteration.work_units_planned
  , Done: 
  %b= @iteration.work_units_real

= burndown_chart(@iteration.burndown, @iteration.work_units_planned)
= velocity_chart(@project.velocity, @iteration.id)

%fieldset.subsection
  %legend.subsection Stories/Tasks
  %div{:style => "margin-bottom:1em"}
    %span= link_to '<strong>Add story</strong>', new_iteration_story_path(@iteration)
    = "|"
    %span#toggle_stories.hide_stories= link_to '<strong>Collapse Stories</strong>', "#toggle"
  - @stories.each do |story|
    .story{:id => "story_" + story.id.to_s}
      .story_title
        %table.story_info
          %tr
            %td{:style => "width:8em"}= story_completion(story)
            %td{:style => "width:25em"}
              %b= story.name.capitalize
            %td{:style => "width:5em"}==  (#{story.work_units_est} w.u.) 
            %td{:style => "width:3em"}= link_to "edit", edit_iteration_story_url(@iteration, story)
            %td{:style => "width:3em"}= link_to "delete", iteration_story_url(@iteration, story), :method => "delete", :confirm => "Are you sure?"
      .agile_tasks
        = link_to "<strong>Add task</strong>", new_story_agile_task_url(story)
        - if !story.agile_tasks.empty?
          %table{:class => "data bordered"}
            %thead
              %tr
                %th Task Name
                %th Bug?
                %th Done?
                %th Owners
                %th t.u.
                %th{:colspan => "2"} Actions

            - story.agile_tasks_sorted.each do |task|
              - tr_class = (!task.completion_date? && task.task_owners.size > 0) ? "task_active" : "task_inactive"
              - td_class = task.completion_date? ? "task_complete" : "task_incomplete"
              %tr{:id => "task_" + task.id.to_s, :class => tr_class}
                %td{:style => "width:35em;", :class => td_class}= link_to_task task.name, task
                %td{:style => "width:2em;"}= link_to_task((task.bug? ? '<span style="color:red">yes</span>' : '-'), task)
                %td{:style => "width:2em;"}= link_to_task((task.completion_date ? 'yes' : '-'), task)
                %td= link_to_task task_owners(task), task
                %td{:style => "width:2em;"}= link_to_task((task.task_units ? task.task_units : '-'), task)
                %td= link_to_task('edit', task)
                %td= link_to 'delete', story_agile_task_url(story, task), :method => "delete", :confirm => "Are you sure?"

  %div{:style => "margin-bottom:1em"}
    %span= link_to '<strong>Add story</strong>', new_iteration_story_path(@iteration)

%fieldset.subsection
  %legend.subsection Meetings
  = link_to 'Add meeting', new_iteration_meeting_path(@iteration) 
  
  - if !@meetings.empty?
    %table{:class => "data bordered"}
      %thead
        %tr
          %th Date
          %th Meeting
          %th length (w.u)
          %th{:style => "width: 30em"} Participants
{'fraction_non_alphanumeric': 0.1613441067077081, 'fraction_numerical': 0.00487366936001026, 'mean_word_length': 3.027892561983471, 'pattern_counts': {'":': 0, '<': 23, '<?xml version=': 0, '>': 73, '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': '4648084', 'n_tokens_mistral': 2741, 'n_tokens_neox': 2656, 'n_words': 480}