ticketmaster-redmine 0.2.4 → 0.2.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.2.4
1
+ 0.2.5
@@ -7,37 +7,37 @@ module TicketMaster::Provider
7
7
  class Ticket < TicketMaster::Provider::Base::Ticket
8
8
  # declare needed overloaded methods here
9
9
 
10
- def initialize(*object)
11
- if object.first
12
- object = object.first
13
- @system_data = {:client => object}
14
- unless object.is_a? Hash
15
- hash = {:repository => object.id,
16
- :description => object.description,
17
- :title => object.subject,
18
- :status => object.status,
19
- :priority => object.priority,
20
- :project_id => object.id}
21
- else
22
- hash = object
23
- end
24
- super hash
25
- end
26
- end
27
-
28
- def self.find(*options)
29
- begin
30
- if options.first.is_a? Hash
31
- options[0].merge!(:params => {:project_id => id})
32
- super(*options)
33
- elsif options.empty?
34
- issues = RedmineAPI::Issue.find(:all, :params => {:project_id => id}).collect { |issue| TicketMaster::Provider::Redmine::Ticket.new issue }
35
- else
36
- super(*options)
37
- end
38
- rescue
39
- []
40
- end
10
+
11
+ def created_at
12
+ self[:created_on]
13
+ end
14
+
15
+ def updated_at
16
+ self[:updated_on]
17
+ end
18
+
19
+ def title
20
+ self[:subject]
21
+ end
22
+
23
+ def project_id
24
+ self[:project].id.to_i
25
+ end
26
+
27
+ def status
28
+ self[:status].name
29
+ end
30
+
31
+ def priority
32
+ self[:priority].name
33
+ end
34
+
35
+ def requestor
36
+ self[:author].name
37
+ end
38
+
39
+ def assignee
40
+ self[:author].name
41
41
  end
42
42
 
43
43
 
@@ -5,11 +5,11 @@
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = %q{ticketmaster-redmine}
8
- s.version = "0.2.4"
8
+ s.version = "0.2.5"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["Rafael George"]
12
- s.date = %q{2011-07-28}
12
+ s.date = %q{2011-07-29}
13
13
  s.description = %q{Allows ticketmaster to interact with Your System.}
14
14
  s.email = %q{rafael@hybridgroup.com}
15
15
  s.extra_rdoc_files = [
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ticketmaster-redmine
3
3
  version: !ruby/object:Gem::Version
4
- hash: 31
4
+ hash: 29
5
5
  prerelease:
6
6
  segments:
7
7
  - 0
8
8
  - 2
9
- - 4
10
- version: 0.2.4
9
+ - 5
10
+ version: 0.2.5
11
11
  platform: ruby
12
12
  authors:
13
13
  - Rafael George
@@ -15,7 +15,7 @@ autorequire:
15
15
  bindir: bin
16
16
  cert_chain: []
17
17
 
18
- date: 2011-07-28 00:00:00 -04:00
18
+ date: 2011-07-29 00:00:00 -04:00
19
19
  default_executable:
20
20
  dependencies:
21
21
  - !ruby/object:Gem::Dependency