lib/issue_graph/issue/collection.rb
# Load all of the epics into the graph
Load all of the epics into the graph
Load all of the epics into the graph
def load_epics
    result = zh_client.epics(repo_name)
    epics = []
    result["epic_issues"].each do |hash|
      issue = add_or_find(hash)
      issue[:is_epic] = true
      epics << issue
    end
    epics.each do |epic|
      result = zh_client.epic_data(repo_name, epic[:issue_number])
      result["issues"].each do |hash|
        issue = add_or_find(hash)
        add_edge(epic, issue)
      end
    end
  end
def load_epics result = zh_client . epics ( repo_name ) epics = [ ] result [ "epic_issues" ] . each do | hash | issue = add_or_find ( hash ) issue [ :is_epic ] = true epics << issue end epics . each do | epic | result = zh_client . epic_data ( repo_name , epic [ :issue_number ] ) result [ "issues" ] . each do | hash | issue = add_or_find ( hash ) add_edge ( epic , issue ) end end end
Load all of the epics into the graph
Load all of the epics into the graph
# Then add an edge for each of the issues contained in the epic