isurvey 0.1.0 → 0.1.1
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.
- checksums.yaml +8 -8
- data/README.md +12 -6
- data/lib/isurvey/answer.rb +6 -0
- data/lib/isurvey/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,15 +1,15 @@
|
|
1
1
|
---
|
2
2
|
!binary "U0hBMQ==":
|
3
3
|
metadata.gz: !binary |-
|
4
|
-
|
4
|
+
ZDNmZjAwZDllYjEzZjJlMTM2MDIzNWZhMWU5MDdlMzM2NTAzNmMxOA==
|
5
5
|
data.tar.gz: !binary |-
|
6
|
-
|
6
|
+
ZGNmMzA4NzkwNDJhY2NiOTEwMjIyYTFlOGY5ZTc3MzkxOTk2ODlhYw==
|
7
7
|
!binary "U0hBNTEy":
|
8
8
|
metadata.gz: !binary |-
|
9
|
-
|
10
|
-
|
11
|
-
|
9
|
+
YWNiYWM4NjA4ZjY1ZTc2NGM2YzdmNjIwMTEyZmI0NTQxNTFhYzg0NDdkYWVm
|
10
|
+
MmJjMzZjYmE4NWMwNzY4Y2QwY2EyY2QxMjY4MjQzMTdhM2IxNDgxN2ZmYTJi
|
11
|
+
ZTVmYTI5NmUxY2Y4MzBmOTRkNmFiOTg5MTI1MDQwODUwMGQxZDg=
|
12
12
|
data.tar.gz: !binary |-
|
13
|
-
|
14
|
-
|
15
|
-
|
13
|
+
YWRjNDNkMjJjYTIzZWE1MWJiYjY4OTE1NGQ5MWZjZmRmNzc4NWQ2ZTE3ODhk
|
14
|
+
YzQ2MDg5YjFmYmUxYTU5OWExNTRhMWNiZTYwNzhjOTMyNWQ1MDUyMDNlNGM1
|
15
|
+
NzU4NmE3NjNkNzMyYmEzMGU3MmI0Zjg3MjAyNWYxZWYwN2YyMzM=
|
data/README.md
CHANGED
@@ -37,7 +37,7 @@ To get a list of all answers:
|
|
37
37
|
|
38
38
|
Isurvey::Answer.all
|
39
39
|
|
40
|
-
All of the properties available through the iSurvey API are also available through the gem. You obtain a property value by calling for it on the appropriate class; for example, Isurvey::Answer.
|
40
|
+
All of the properties available through the iSurvey API are also available through the gem. You obtain a property value by calling for it on the appropriate class; for example, Isurvey::Answer.first.screen_id would give you the screen_id of the first Answer.
|
41
41
|
|
42
42
|
For questions, the available properties are:
|
43
43
|
|
@@ -52,14 +52,15 @@ Any property can also be used to find on either questions or answers. For examp
|
|
52
52
|
Isurvey::Question.find_by_screen_id(:id)
|
53
53
|
Isurvey::Answer.find_by_question_id(:id)
|
54
54
|
|
55
|
-
You can query a question for its answers, or an answer for its
|
55
|
+
You can query a question for its answers, or an answer for its question.
|
56
56
|
|
57
|
-
Isurvey::Question.answers
|
58
|
-
Isurvey::Answer.
|
57
|
+
Isurvey::Question.first.answers
|
58
|
+
Isurvey::Answer.first.question
|
59
59
|
|
60
|
-
You can also find answers by result id
|
60
|
+
You can also find answers by result id.
|
61
61
|
|
62
|
-
Isurvey::Question.answers_by_result_id(:id)
|
62
|
+
Isurvey::Question.first.answers_by_result_id(:id)
|
63
|
+
Isurvey::Answer.by_result_id(:id)
|
63
64
|
|
64
65
|
Questions and Answers have shortcut methods that allow you to query for the first or some index:
|
65
66
|
|
@@ -72,6 +73,11 @@ Get a list of the result ids:
|
|
72
73
|
|
73
74
|
Isurvey::API.result_ids
|
74
75
|
|
76
|
+
These are also available, though I advise against using them unless there is a good reason:
|
77
|
+
|
78
|
+
Isurvey::API.questions
|
79
|
+
Isurvey::API.answers
|
80
|
+
|
75
81
|
## Contributing
|
76
82
|
|
77
83
|
1. Fork it
|
data/lib/isurvey/answer.rb
CHANGED
data/lib/isurvey/version.rb
CHANGED