ticketmaster 0.3.1 → 0.3.2
Sign up to get free protection for your applications and to get access to all the features.
- data/VERSION +1 -1
- data/lib/ticketmaster/cli/commands/ticket.rb +3 -3
- data/lib/ticketmaster/project.rb +6 -0
- data/lib/ticketmaster/ticket.rb +6 -0
- data/ticketmaster.gemspec +3 -4
- metadata +5 -6
- data/ticketmaster-0.3.0.gem +0 -0
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.3.
|
1
|
+
0.3.2
|
@@ -79,7 +79,7 @@ end
|
|
79
79
|
# The read subcommand
|
80
80
|
def read(options)
|
81
81
|
tm = TicketMaster.new(options[:provider], options[:authentication])
|
82
|
-
ticket = tm.ticket.find(options[:
|
82
|
+
ticket = tm.ticket.find(options[:project].to_i, options[:ticket].to_i)
|
83
83
|
read_ticket ticket
|
84
84
|
exit
|
85
85
|
end
|
@@ -87,7 +87,7 @@ end
|
|
87
87
|
# The update subcommand
|
88
88
|
def update(options)
|
89
89
|
tm = TicketMaster.new(options[:provider], options[:authentication])
|
90
|
-
ticket = tm.ticket.find(options[:
|
90
|
+
ticket = tm.ticket.find(options[:project].to_i, options[:ticket].to_i)
|
91
91
|
if ticket.update!(options[:ticket_attributes])
|
92
92
|
puts "Successfully updated Ticket #{ticket.title} (#{ticket.id})"
|
93
93
|
else
|
@@ -100,7 +100,7 @@ end
|
|
100
100
|
# The destroy subcommand.
|
101
101
|
def destroy(options)
|
102
102
|
tm = TicketMaster.new(options[:provider], options[:authentication])
|
103
|
-
ticket = tm.ticket.find(options[:
|
103
|
+
ticket = tm.ticket.find(options[:project].to_i, options[:ticket].to_i)
|
104
104
|
puts "Are you sure you want to delete Ticket #{ticket.title} (#{ticket.id})? (yes/no) [no]"
|
105
105
|
ARGV.clear
|
106
106
|
confirm = readline.chomp.downcase
|
data/lib/ticketmaster/project.rb
CHANGED
@@ -128,6 +128,12 @@ module TicketMaster::Provider
|
|
128
128
|
easy_finder(self.class.parent::Ticket, :first, options, 1)
|
129
129
|
end
|
130
130
|
|
131
|
+
# Create a ticket
|
132
|
+
def ticket!(*options)
|
133
|
+
options[0].merge!(:project_id => id) if options.first.is_a?(Hash)
|
134
|
+
self.class.parent::Ticket.create(*options)
|
135
|
+
end
|
136
|
+
|
131
137
|
# Define some provider specific initalizations
|
132
138
|
def initialize(*options)
|
133
139
|
# @system_data = {'some' => 'data}
|
data/lib/ticketmaster/ticket.rb
CHANGED
@@ -131,6 +131,12 @@ module TicketMaster::Provider
|
|
131
131
|
easy_finder(self.class.parent::Comment, :first, options, 2)
|
132
132
|
end
|
133
133
|
|
134
|
+
# Create a comment
|
135
|
+
def comment!(*options)
|
136
|
+
options[0].merge!(:project_id => project_id, :ticket_id => id) if options.first.is_a?(Hash)
|
137
|
+
self.class.parent::Comment.create(*options)
|
138
|
+
end
|
139
|
+
|
134
140
|
# Close this ticket
|
135
141
|
#
|
136
142
|
# On success it should return true, otherwise false
|
data/ticketmaster.gemspec
CHANGED
@@ -5,11 +5,11 @@
|
|
5
5
|
|
6
6
|
Gem::Specification.new do |s|
|
7
7
|
s.name = %q{ticketmaster}
|
8
|
-
s.version = "0.3.
|
8
|
+
s.version = "0.3.2"
|
9
9
|
|
10
10
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
11
11
|
s.authors = ["Sirupsen", "deadprogrammer"]
|
12
|
-
s.date = %q{2010-07-
|
12
|
+
s.date = %q{2010-07-05}
|
13
13
|
s.default_executable = %q{ticket}
|
14
14
|
s.description = %q{Ticketmaster provides a universal API to trouble ticket and project management systems.}
|
15
15
|
s.email = %q{simon@hybridgroup.com}
|
@@ -59,8 +59,7 @@ Gem::Specification.new do |s|
|
|
59
59
|
"spec/ticketmaster_spec.rb",
|
60
60
|
"test/helper.rb",
|
61
61
|
"test/test_ticketmaster.rb",
|
62
|
-
"ticketmaster-0.3.
|
63
|
-
"ticketmaster-0.3.1.gem",
|
62
|
+
"ticketmaster-0.3.2.gem",
|
64
63
|
"ticketmaster.gemspec"
|
65
64
|
]
|
66
65
|
s.homepage = %q{http://ticketrb.com}
|
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: ticketmaster
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash:
|
4
|
+
hash: 23
|
5
5
|
prerelease: false
|
6
6
|
segments:
|
7
7
|
- 0
|
8
8
|
- 3
|
9
|
-
-
|
10
|
-
version: 0.3.
|
9
|
+
- 2
|
10
|
+
version: 0.3.2
|
11
11
|
platform: ruby
|
12
12
|
authors:
|
13
13
|
- Sirupsen
|
@@ -16,7 +16,7 @@ autorequire:
|
|
16
16
|
bindir: bin
|
17
17
|
cert_chain: []
|
18
18
|
|
19
|
-
date: 2010-07-
|
19
|
+
date: 2010-07-05 00:00:00 -07:00
|
20
20
|
default_executable: ticket
|
21
21
|
dependencies:
|
22
22
|
- !ruby/object:Gem::Dependency
|
@@ -97,8 +97,7 @@ files:
|
|
97
97
|
- spec/ticketmaster_spec.rb
|
98
98
|
- test/helper.rb
|
99
99
|
- test/test_ticketmaster.rb
|
100
|
-
- ticketmaster-0.3.
|
101
|
-
- ticketmaster-0.3.1.gem
|
100
|
+
- ticketmaster-0.3.2.gem
|
102
101
|
- ticketmaster.gemspec
|
103
102
|
has_rdoc: true
|
104
103
|
homepage: http://ticketrb.com
|
data/ticketmaster-0.3.0.gem
DELETED
Binary file
|