@@ -897,7 +897,7 class Issue < ActiveRecord::Base | |||||
897 | parent = current_issue.parent |
|
897 | parent = current_issue.parent | |
898 | parentStatus = issue_status[parent] |
|
898 | parentStatus = issue_status[parent] | |
899 |
|
899 | |||
900 |
if parent && (parentStatus == eNOT_DISCOVERED) && !except.include?(parent) |
|
900 | if parent && (parentStatus == eNOT_DISCOVERED) && !except.include?(parent) | |
901 |
|
901 | |||
902 | queue << parent |
|
902 | queue << parent | |
903 | issue_status[parent] = ePROCESS_RELATIONS_ONLY |
|
903 | issue_status[parent] = ePROCESS_RELATIONS_ONLY | |
@@ -906,7 +906,7 class Issue < ActiveRecord::Base | |||||
906 |
|
906 | |||
907 | # Add children to queue, but only if they are not already in it and |
|
907 | # Add children to queue, but only if they are not already in it and | |
908 | # the children of the current node need to be processed. |
|
908 | # the children of the current node need to be processed. | |
909 |
if current_issue.children && (current_issue_status == ePROCESS_CHILDREN_ONLY || current_issue_status == ePROCESS_ALL) |
|
909 | if current_issue.children && (current_issue_status == ePROCESS_CHILDREN_ONLY || current_issue_status == ePROCESS_ALL) | |
910 |
|
910 | |||
911 | current_issue.children.each do |child| |
|
911 | current_issue.children.each do |child| | |
912 |
|
912 | |||
@@ -928,25 +928,25 class Issue < ActiveRecord::Base | |||||
928 | # Add related issues to the queue, if they are not already in it. |
|
928 | # Add related issues to the queue, if they are not already in it. | |
929 | current_issue.relations_from.map(&:issue_to).each do |relatedIssue| |
|
929 | current_issue.relations_from.map(&:issue_to).each do |relatedIssue| | |
930 |
|
930 | |||
931 |
if (issue_status[relatedIssue] == eNOT_DISCOVERED) && !except.include?(relatedIssue) |
|
931 | if (issue_status[relatedIssue] == eNOT_DISCOVERED) && !except.include?(relatedIssue) | |
932 | queue << relatedIssue |
|
932 | queue << relatedIssue | |
933 | issue_status[relatedIssue] = ePROCESS_ALL |
|
933 | issue_status[relatedIssue] = ePROCESS_ALL | |
934 |
|
934 | |||
935 |
elsif (issue_status[relatedIssue] == eRELATIONS_PROCESSED) && !except.include?(relatedIssue) |
|
935 | elsif (issue_status[relatedIssue] == eRELATIONS_PROCESSED) && !except.include?(relatedIssue) | |
936 | queue << relatedIssue |
|
936 | queue << relatedIssue | |
937 | issue_status[relatedIssue] = ePROCESS_CHILDREN_ONLY |
|
937 | issue_status[relatedIssue] = ePROCESS_CHILDREN_ONLY | |
938 |
|
938 | |||
939 |
elsif (issue_status[relatedIssue] == ePROCESS_RELATIONS_ONLY) && !except.include?(relatedIssue) |
|
939 | elsif (issue_status[relatedIssue] == ePROCESS_RELATIONS_ONLY) && !except.include?(relatedIssue) | |
940 | queue << relatedIssue |
|
940 | queue << relatedIssue | |
941 | issue_status[relatedIssue] = ePROCESS_ALL |
|
941 | issue_status[relatedIssue] = ePROCESS_ALL | |
942 | end |
|
942 | end | |
943 | end |
|
943 | end | |
944 |
|
944 | |||
945 | # Set new status for current issue |
|
945 | # Set new status for current issue | |
946 |
if (current_issue_status == ePROCESS_ALL) || (current_issue_status == ePROCESS_CHILDREN_ONLY) |
|
946 | if (current_issue_status == ePROCESS_ALL) || (current_issue_status == ePROCESS_CHILDREN_ONLY) | |
947 | issue_status[current_issue] = eALL_PROCESSED |
|
947 | issue_status[current_issue] = eALL_PROCESSED | |
948 |
|
948 | |||
949 |
elsif (current_issue_status == ePROCESS_RELATIONS_ONLY) |
|
949 | elsif (current_issue_status == ePROCESS_RELATIONS_ONLY) | |
950 | issue_status[current_issue] = eRELATIONS_PROCESSED |
|
950 | issue_status[current_issue] = eRELATIONS_PROCESSED | |
951 | end |
|
951 | end | |
952 |
|
952 |
General Comments 0
You need to be logged in to leave comments.
Login now