Skip to content

Commit

Permalink
Merge pull request #5 from XZzYassin/master
Browse files Browse the repository at this point in the history
FIXED: Issue #2
  • Loading branch information
noma4i committed May 5, 2016
2 parents a8f5b2a + 4040ff0 commit 40c5847
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion SubRed.py
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,9 @@ def on_done(i):
query_ids.append(query.id)
if hasattr(query, 'project_id'):
query_projects.append(query.project_id)
else:
query_projects.append(0)


self.view.window().show_quick_panel(query_names, on_done)

Expand Down Expand Up @@ -138,7 +141,10 @@ def run(self,edit,text):
class RedmineFetchQueryCommand(sublime_plugin.TextCommand):
def run(self,edit,project_id,query_id):
redmine = SubRedmine.connect()
issues = redmine.issue.filter(project_id=project_id,query_id=query_id)
if(project_id != 0):
issues = redmine.issue.filter(project_id=project_id,query_id=query_id)
else:
issues = redmine.issue.filter(query_id=query_id)
self.redmine_view(edit, issues, title="Redmine Query List")

def redmine_view(self, edit, issues, title):
Expand Down

0 comments on commit 40c5847

Please sign in to comment.