Class: Terjira::Client::Field
- Inherits:
-
Base
- Object
- Base
- Terjira::Client::Field
show all
- Defined in:
- lib/terjira/client/field.rb
Constant Summary
collapse
- CACHE_PATH =
"resource/fields".freeze
Constants inherited
from Base
Base::AGILE_API_PATH, Base::DEFAULT_API_PATH, Base::DEFAULT_CACHE_SEC
Constants included
from JQLBuilder
JQLBuilder::SEARCH_KEYS, JQLBuilder::STRICT_KEYS
AuthOptionBuilder::AUTH_CACHE_KEY
Class Method Summary
collapse
Methods inherited from Base
cache, class_name, client, parse_body, resource, site_url, username
Methods included from JQLBuilder
#build_jql
#auth_file_cache, #build_auth_options, #build_auth_options_by_cached, #build_auth_options_by_tty, #expire_auth_options
Class Method Details
.all ⇒ Object
9
10
11
12
13
|
# File 'lib/terjira/client/field.rb', line 9
def all
@all_fields ||= file_cache.fetch("all") do
resource.all
end
end
|
.epic_link ⇒ Object
27
28
29
|
# File 'lib/terjira/client/field.rb', line 27
def epic_link
find_by_name('Epic Link')
end
|
.epic_name ⇒ Object
23
24
25
|
# File 'lib/terjira/client/field.rb', line 23
def epic_name
find_by_name('Epic Name')
end
|
.find_by_key(key) ⇒ Object
15
16
17
|
# File 'lib/terjira/client/field.rb', line 15
def find_by_key(key)
all.find { |field| field.key == key }
end
|
.find_by_name(name) ⇒ Object
19
20
21
|
# File 'lib/terjira/client/field.rb', line 19
def find_by_name(name)
all.find { |field| field.name == name }
end
|
.story_points ⇒ Object
31
32
33
|
# File 'lib/terjira/client/field.rb', line 31
def story_points
find_by_name('Story Points')
end
|