groupdocs 1.6.0 → 1.7.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (171) hide show
  1. data/CHANGELOG.md +34 -0
  2. data/LICENSE.txt +21 -0
  3. data/README.md +3 -0
  4. data/examples/api-samples/public/docs/sample01.html +23 -23
  5. data/examples/api-samples/public/docs/sample02.html +27 -27
  6. data/examples/api-samples/public/docs/sample03.html +81 -69
  7. data/examples/api-samples/public/docs/sample04.html +29 -29
  8. data/examples/api-samples/public/docs/sample05.html +48 -48
  9. data/examples/api-samples/public/docs/sample06.html +47 -46
  10. data/examples/api-samples/public/docs/sample07.html +35 -35
  11. data/examples/api-samples/public/docs/sample08.html +45 -45
  12. data/examples/api-samples/public/docs/sample09.html +57 -57
  13. data/examples/api-samples/public/docs/sample10.html +41 -41
  14. data/examples/api-samples/public/docs/sample11.html +96 -118
  15. data/examples/api-samples/public/docs/sample12.html +29 -50
  16. data/examples/api-samples/public/docs/sample13.html +36 -44
  17. data/examples/api-samples/public/docs/sample14.html +29 -29
  18. data/examples/api-samples/public/docs/sample15.html +24 -24
  19. data/examples/api-samples/public/docs/sample16.html +32 -32
  20. data/examples/api-samples/public/docs/sample17.html +38 -38
  21. data/examples/api-samples/public/docs/sample18.html +105 -101
  22. data/examples/api-samples/public/docs/sample19.html +101 -101
  23. data/examples/api-samples/public/docs/sample20.html +42 -42
  24. data/examples/api-samples/public/docs/sample21.html +109 -109
  25. data/examples/api-samples/public/docs/sample22.html +56 -56
  26. data/examples/api-samples/public/docs/sample23.html +39 -39
  27. data/examples/api-samples/public/docs/sample24.html +36 -36
  28. data/examples/api-samples/public/docs/sample25.html +67 -67
  29. data/examples/api-samples/public/docs/sample26.html +23 -23
  30. data/examples/api-samples/public/docs/sample27.html +72 -72
  31. data/examples/api-samples/public/docs/sample28.html +46 -45
  32. data/examples/api-samples/public/docs/sample29.html +30 -30
  33. data/examples/api-samples/public/docs/sample30.html +30 -30
  34. data/examples/api-samples/public/docs/sample31.html +114 -114
  35. data/examples/api-samples/public/docs/sample32.html +96 -96
  36. data/examples/api-samples/public/docs/sample33.html +56 -56
  37. data/examples/api-samples/public/docs/sample34.html +27 -27
  38. data/examples/api-samples/public/docs/sample35.html +134 -135
  39. data/examples/api-samples/public/docs/sample36.html +32 -32
  40. data/examples/api-samples/public/docs/sample37.html +103 -103
  41. data/examples/api-samples/public/docs/sample38.html +76 -76
  42. data/examples/api-samples/public/docs/sample39.html +136 -136
  43. data/examples/api-samples/public/docs/sample40.html +104 -104
  44. data/examples/api-samples/public/docs/sample41.html +137 -137
  45. data/examples/api-samples/public/docs/sample42.html +61 -61
  46. data/examples/api-samples/public/docs/sample43.html +72 -72
  47. data/examples/api-samples/public/docs/sample44.html +751 -0
  48. data/examples/api-samples/public/docs/sample45.html +236 -0
  49. data/examples/api-samples/public/templates/merge_field3_doc.docx +0 -0
  50. data/examples/api-samples/samples/sample01.rb +2 -2
  51. data/examples/api-samples/samples/sample02.rb +2 -2
  52. data/examples/api-samples/samples/sample03.rb +2 -2
  53. data/examples/api-samples/samples/sample04.rb +2 -2
  54. data/examples/api-samples/samples/sample05.rb +2 -2
  55. data/examples/api-samples/samples/sample06.rb +2 -2
  56. data/examples/api-samples/samples/sample07.rb +2 -2
  57. data/examples/api-samples/samples/sample08.rb +2 -2
  58. data/examples/api-samples/samples/sample09.rb +2 -2
  59. data/examples/api-samples/samples/sample10.rb +2 -2
  60. data/examples/api-samples/samples/sample11.rb +2 -2
  61. data/examples/api-samples/samples/sample12.rb +2 -2
  62. data/examples/api-samples/samples/sample13.rb +2 -2
  63. data/examples/api-samples/samples/sample14.rb +2 -2
  64. data/examples/api-samples/samples/sample15.rb +2 -2
  65. data/examples/api-samples/samples/sample16.rb +2 -2
  66. data/examples/api-samples/samples/sample17.rb +2 -2
  67. data/examples/api-samples/samples/sample18.rb +2 -2
  68. data/examples/api-samples/samples/sample19.rb +2 -2
  69. data/examples/api-samples/samples/sample20.rb +2 -2
  70. data/examples/api-samples/samples/sample21.rb +2 -2
  71. data/examples/api-samples/samples/sample22.rb +2 -2
  72. data/examples/api-samples/samples/sample23.rb +2 -2
  73. data/examples/api-samples/samples/sample24.rb +2 -2
  74. data/examples/api-samples/samples/sample25.rb +2 -2
  75. data/examples/api-samples/samples/sample26.rb +2 -2
  76. data/examples/api-samples/samples/sample27.rb +2 -2
  77. data/examples/api-samples/samples/sample28.rb +2 -2
  78. data/examples/api-samples/samples/sample29.rb +2 -2
  79. data/examples/api-samples/samples/sample30.rb +2 -2
  80. data/examples/api-samples/samples/sample31.rb +2 -2
  81. data/examples/api-samples/samples/sample32.rb +2 -2
  82. data/examples/api-samples/samples/sample33.rb +2 -2
  83. data/examples/api-samples/samples/sample34.rb +2 -2
  84. data/examples/api-samples/samples/sample35.rb +4 -4
  85. data/examples/api-samples/samples/sample36.rb +2 -2
  86. data/examples/api-samples/samples/sample37.rb +2 -2
  87. data/examples/api-samples/samples/sample38.rb +2 -2
  88. data/examples/api-samples/samples/sample39.rb +2 -2
  89. data/examples/api-samples/samples/sample40.rb +2 -2
  90. data/examples/api-samples/samples/sample41.rb +2 -2
  91. data/examples/api-samples/samples/sample42.rb +2 -2
  92. data/examples/api-samples/samples/sample43.rb +2 -2
  93. data/examples/api-samples/samples/sample44.rb +188 -0
  94. data/examples/api-samples/samples/sample45.rb +74 -0
  95. data/examples/api-samples/views/_others_samples.haml +47 -43
  96. data/examples/api-samples/views/index.haml +55 -44
  97. data/examples/api-samples/views/layout.haml +1 -6
  98. data/examples/api-samples/views/sample01.haml +62 -57
  99. data/examples/api-samples/views/sample02.haml +52 -46
  100. data/examples/api-samples/views/sample03.haml +78 -73
  101. data/examples/api-samples/views/sample04.haml +51 -45
  102. data/examples/api-samples/views/sample05.haml +77 -71
  103. data/examples/api-samples/views/sample06.haml +58 -52
  104. data/examples/api-samples/views/sample07.haml +51 -45
  105. data/examples/api-samples/views/sample08.haml +90 -84
  106. data/examples/api-samples/views/sample09.haml +86 -80
  107. data/examples/api-samples/views/sample10.haml +83 -77
  108. data/examples/api-samples/views/sample11.haml +124 -120
  109. data/examples/api-samples/views/sample12.haml +65 -59
  110. data/examples/api-samples/views/sample13.haml +62 -56
  111. data/examples/api-samples/views/sample14.haml +57 -51
  112. data/examples/api-samples/views/sample15.haml +49 -43
  113. data/examples/api-samples/views/sample16.haml +49 -43
  114. data/examples/api-samples/views/sample17.haml +53 -47
  115. data/examples/api-samples/views/sample18.haml +140 -134
  116. data/examples/api-samples/views/sample19.haml +87 -81
  117. data/examples/api-samples/views/sample20.haml +53 -47
  118. data/examples/api-samples/views/sample21.haml +115 -111
  119. data/examples/api-samples/views/sample22.haml +94 -88
  120. data/examples/api-samples/views/sample23.haml +83 -78
  121. data/examples/api-samples/views/sample24.haml +54 -48
  122. data/examples/api-samples/views/sample25.haml +89 -83
  123. data/examples/api-samples/views/sample26.haml +62 -57
  124. data/examples/api-samples/views/sample27.haml +114 -109
  125. data/examples/api-samples/views/sample28.haml +55 -49
  126. data/examples/api-samples/views/sample29.haml +67 -69
  127. data/examples/api-samples/views/sample30.haml +54 -48
  128. data/examples/api-samples/views/sample31.haml +106 -100
  129. data/examples/api-samples/views/sample32.haml +90 -84
  130. data/examples/api-samples/views/sample33.haml +60 -54
  131. data/examples/api-samples/views/sample34.haml +51 -46
  132. data/examples/api-samples/views/sample35.haml +84 -78
  133. data/examples/api-samples/views/sample36.haml +63 -58
  134. data/examples/api-samples/views/sample37.haml +122 -116
  135. data/examples/api-samples/views/sample38.haml +104 -98
  136. data/examples/api-samples/views/sample39.haml +6 -2
  137. data/examples/api-samples/views/sample40.haml +94 -89
  138. data/examples/api-samples/views/sample41.haml +127 -123
  139. data/examples/api-samples/views/sample42.haml +60 -54
  140. data/examples/api-samples/views/sample43.haml +81 -77
  141. data/examples/api-samples/views/sample44.haml +85 -0
  142. data/examples/api-samples/views/sample45.haml +85 -0
  143. data/groupdocs.gemspec +2 -0
  144. data/lib/groupdocs/datasource/field.rb +9 -0
  145. data/lib/groupdocs/document.rb +66 -4
  146. data/lib/groupdocs/document/annotation.rb +11 -6
  147. data/lib/groupdocs/document/editor.rb +53 -0
  148. data/lib/groupdocs/document/field.rb +16 -0
  149. data/lib/groupdocs/document/style.rb +30 -0
  150. data/lib/groupdocs/job.rb +24 -0
  151. data/lib/groupdocs/questionnaire.rb +2 -0
  152. data/lib/groupdocs/questionnaire/collector.rb +52 -0
  153. data/lib/groupdocs/questionnaire/collector_style.rb +54 -0
  154. data/lib/groupdocs/questionnaire/question.rb +9 -0
  155. data/lib/groupdocs/questionnaire/style/base_font.rb +17 -0
  156. data/lib/groupdocs/questionnaire/style/question_title.rb +17 -0
  157. data/lib/groupdocs/questionnaire/style/title.rb +17 -0
  158. data/lib/groupdocs/signature/envelope.rb +43 -8
  159. data/lib/groupdocs/signature/form.rb +113 -12
  160. data/lib/groupdocs/signature/recipient.rb +38 -3
  161. data/lib/groupdocs/signature/shared/field_methods.rb +4 -2
  162. data/lib/groupdocs/signature/template.rb +20 -1
  163. data/lib/groupdocs/storage/file.rb +3 -2
  164. data/lib/groupdocs/user.rb +148 -0
  165. data/lib/groupdocs/version.rb +1 -1
  166. data/spec/groupdocs/api/helpers/access_rights_helper_spec.rb +5 -5
  167. data/spec/groupdocs/document/annotation_spec.rb +1 -1
  168. data/spec/groupdocs/signature/envelope_spec.rb +1 -1
  169. data/spec/groupdocs/user_spec.rb +4 -4
  170. data/spec/support/shared_examples/signature/shared/field_methods.rb +5 -4
  171. metadata +18 -3
@@ -29,8 +29,9 @@ module GroupDocs
29
29
  # @param [Hash] options
30
30
  # @option options [String] path Folder path to upload to
31
31
  # @option options [String] name Name of file to be renamed
32
- # @option options [String] description File description
33
- # @option options [String] callbackUrl will be called after file is uploaded
32
+ # @option options [String] :description File description
33
+ # @option options [String] :callbackUrl will be called after file is uploaded
34
+ # @option options [String] :isKeepBothMode
34
35
  # @param [Hash] access Access credentials
35
36
  # @option access [String] :client_id
36
37
  # @option access [String] :private_key
@@ -383,6 +383,154 @@ module GroupDocs
383
383
  # @attr [List] avatar
384
384
  attr_accessor :avatar
385
385
 
386
+ # added in release 1.7.0
387
+ # @attr [Boolean] trial
388
+ attr_accessor :trial
389
+ # @attr [Boolean] news_eanbled
390
+ attr_accessor :news_eanbled
391
+ # @attr [Boolean] alerts_eanbled
392
+ attr_accessor :alerts_eanbled
393
+ # @attr [Boolean] support_eanbled
394
+ attr_accessor :support_eanbled
395
+ # @attr [Boolean] support_email
396
+ attr_accessor :support_email
397
+ # @attr [String] apps
398
+ attr_accessor :apps
399
+ # @attr [Boolean] annotation_branded
400
+ attr_accessor :annotation_branded
401
+ # @attr [Boolean] viewer_branded
402
+ attr_accessor :viewer_branded
403
+ # @attr [Boolean] is_real_time_broadcast_enabled
404
+ attr_accessor :is_real_time_broadcast_enabled
405
+ # @attr [Boolean] is_scroll_broadcast_enabled
406
+ attr_accessor :is_scroll_broadcast_enabled
407
+ # @attr [Boolean] is_zoom_broadcast_enabled
408
+ attr_accessor :is_zoom_broadcast_enabled
409
+ # @attr [List] annotation_logo
410
+ attr_accessor :annotation_logo
411
+ # @attr [List] pointer_tool_cursor
412
+ attr_accessor :pointer_tool_cursor
413
+ # @attr [Integer] annotation_header_options
414
+ attr_accessor :annotation_header_options
415
+ # @attr [Boolean] is_annotation_navigation_widget_enabled
416
+ attr_accessor :is_annotation_navigation_widget_enabled
417
+ # @attr [Boolean] is_annotation_zoom_widget_enabled
418
+ attr_accessor :is_annotation_zoom_widget_enabled
419
+ # @attr [Boolean] is_annotation_download_widget_enabled
420
+ attr_accessor :is_annotation_download_widget_enabled
421
+ # @attr [Boolean] is_annotation_print_widget_enabled
422
+ attr_accessor :is_annotation_print_widget_enabled
423
+ # @attr [Boolean] is_annotation_help_widget_enabled
424
+ attr_accessor :is_annotation_help_widget_enabled
425
+ # @attr [Boolean] is_right_panel_enabled
426
+ attr_accessor :is_right_panel_enabled
427
+ # @attr [Boolean] is_thumbnails_panel_enabled
428
+ attr_accessor :is_thumbnails_panel_enabled
429
+ # @attr [Boolean] is_standard_header_always_shown
430
+ attr_accessor :is_standard_header_always_shown
431
+ # @attr [Boolean] is_toolbar_enabled
432
+ attr_accessor :is_toolbar_enabled
433
+ # @attr [Boolean] is_text_annotation_button_enabled
434
+ attr_accessor :is_text_annotation_button_enabled
435
+ # @attr [Boolean] is_rectangle_annotation_button_enabled
436
+ attr_accessor :is_rectangle_annotation_button_enabled
437
+ # @attr [Boolean] is_point_annotation_button_enabled
438
+ attr_accessor :is_point_annotation_button_enabled
439
+ # @attr [Boolean] is_strikeout_annotation_button_enabled
440
+ attr_accessor :is_strikeout_annotation_button_enabled
441
+ # @attr [Boolean] is_polyline_annotation_button_enabled
442
+ attr_accessor :is_polyline_annotation_button_enabled
443
+ # @attr [Boolean] is_typewriter_annotation_button_enabled
444
+ attr_accessor :is_typewriter_annotation_button_enabled
445
+ # @attr [Boolean] is_watermark_annotation_button_enabled
446
+ attr_accessor :is_watermark_annotation_button_enabled
447
+ # @attr [Boolean] is_annotation_document_name_shown
448
+ attr_accessor :is_annotation_document_name_shown
449
+ # @attr [List] annotation_navigation_icons
450
+ attr_accessor :annotation_navigation_icons
451
+ # @attr [List] annotation_tool_icons
452
+ attr_accessor :annotation_tool_icons
453
+ # @attr [Integer] annotation_background_color
454
+ attr_accessor :annotation_background_color
455
+ # @attr [Integer] viewer_logo
456
+ attr_accessor :viewer_logo
457
+ # @attr [Integer] viewer_options
458
+ attr_accessor :viewer_options
459
+ # @attr [Boolean] is_viewer_navigation_widget_enabled
460
+ attr_accessor :is_viewer_navigation_widget_enabled
461
+ # @attr [Boolean] is_viewer_zoom_widget_enabled
462
+ attr_accessor :is_viewer_zoom_widget_enabled
463
+ # @attr [Boolean] is_viewer_download_widget_enabled
464
+ attr_accessor :is_viewer_download_widget_enabled
465
+ # @attr [Boolean] is_viewer_print_widget_enabled
466
+ attr_accessor :is_viewer_print_widget_enabled
467
+ # @attr [Boolean] is_viewer_help_widget_enabled
468
+ attr_accessor :is_viewer_help_widget_enabled
469
+ # @attr [Boolean] is_viewer_document_name_shown
470
+ attr_accessor :is_viewer_document_name_shown
471
+ # @attr [Boolean] isviewer_right_mouse_button_menu_enabled
472
+ attr_accessor :isviewer_right_mouse_button_menu_enabled
473
+ # @attr [Time] signedinOn
474
+ attr_accessor :signedinOn
475
+ # @attr [Integer] signin_count
476
+ attr_accessor :signin_count
477
+ # @attr [Boolean] signature_watermark_enabled
478
+ attr_accessor :signature_watermark_enabled
479
+ # @attr [Boolean] signature_desktop_notifications
480
+ attr_accessor :signature_desktop_notifications
481
+ # @attr [Integer] webhook_notification_retries
482
+ attr_accessor :webhook_notification_retries
483
+ # @attr [String] webhook_notification_failed_recipients
484
+ attr_accessor :webhook_notification_failed_recipients
485
+ # @attr [String] signature_color
486
+ attr_accessor :signature_color
487
+ # @attr [Boolean] signature_save_field_changes_automatically
488
+ attr_accessor :signature_save_field_changes_automatically
489
+ # @attr [Boolean] signature_use_custom_email_templates
490
+ attr_accessor :signature_use_custom_email_templates
491
+ # @attr [String] signature_envelope_sent_owner_template
492
+ attr_accessor :signature_envelope_sent_owner_template
493
+ # @attr [String] signature_envelope_sent_other_template
494
+ attr_accessor :signature_envelope_sent_other_template
495
+ # @attr [String] signature_envelope_completed_template
496
+ attr_accessor :signature_envelope_completed_template
497
+ # @attr [String] signature_envelope_signed_template
498
+ attr_accessor :signature_envelope_signed_template
499
+ # @attr [String] signature_envelope_declined_template
500
+ attr_accessor :signature_envelope_declined_template
501
+ # @attr [String] signature_envelope_failed_template
502
+ attr_accessor :signature_envelope_failed_template
503
+ # @attr [String] signature_envelope_cancelled_template
504
+ attr_accessor :signature_envelope_cancelled_template
505
+ # @attr [String] signature_envelope_expired_template
506
+ attr_accessor :signature_envelope_expired_template
507
+ # @attr [String] signature_envelope_step_expired_template
508
+ attr_accessor :signature_envelope_step_expired_template
509
+ # @attr [String] signature_envelope_recipient_reminder_template
510
+ attr_accessor :signature_envelope_recipient_reminder_template
511
+ # @attr [String] signature_form_signed_template
512
+ attr_accessor :signature_form_signed_template
513
+ # @attr [Boolean] signature_form_require_user_auth_for_sign
514
+ attr_accessor :signature_form_require_user_auth_for_sign
515
+ # @attr [Boolean] signature_form_request_user_auth_by_photo
516
+ attr_accessor :signature_form_request_user_auth_by_photo
517
+ # @attr [Boolean] signature_form_require_user_identity_validation
518
+ attr_accessor :signature_form_require_user_identity_validation
519
+ # @attr [Boolean] signature_envelope_require_user_auth_for_sign
520
+ attr_accessor :signature_envelope_require_user_auth_for_sign
521
+ # @attr [Boolean] signature_envelope_request_user_auth_by_photo
522
+ attr_accessor :signature_envelope_request_user_auth_by_photo
523
+ # @attr [Boolean] signature_enable_uploaded_signature
524
+ attr_accessor :signature_enable_uploaded_signature
525
+ # @attr [Boolean] signature_enable_typed_signature
526
+ attr_accessor :signature_enable_typed_signature
527
+ # @attr [Boolean] signature_enable_envelope_comment
528
+ attr_accessor :signature_enable_envelope_comment
529
+ # @attr [Boolean] signature_enable_form_comment
530
+ attr_accessor :signature_enable_form_comment
531
+
532
+
533
+
386
534
  # Human-readable accessors
387
535
  alias_accessor :first_name, :firstname
388
536
  alias_accessor :last_name, :lastname
@@ -1,3 +1,3 @@
1
1
  module GroupDocs
2
- VERSION = '1.6.0'
2
+ VERSION = '1.7.0'
3
3
  end # GroupDocs
@@ -6,10 +6,10 @@ describe GroupDocs::Api::Helpers::AccessRights do
6
6
  end
7
7
 
8
8
  describe '#convert_access_rights_to_byte' do
9
- let(:rights) { %w(export view proof download) }
9
+ let(:rights) { %w(view annotate download export all) }
10
10
 
11
11
  it 'raises error if rights is not an array' do
12
- lambda { subject.send(:convert_access_rights_to_byte, :export) }.should raise_error(ArgumentError)
12
+ lambda { subject.send(:convert_access_rights_to_byte, :view) }.should raise_error(ArgumentError)
13
13
  end
14
14
 
15
15
  it 'raises error if right is unknown' do
@@ -25,19 +25,19 @@ describe GroupDocs::Api::Helpers::AccessRights do
25
25
  end
26
26
 
27
27
  it 'returns correct byte flag' do
28
- subject.send(:convert_access_rights_to_byte, rights).should == 15
28
+ subject.send(:convert_access_rights_to_byte, rights).should == 46
29
29
  end
30
30
  end
31
31
 
32
32
  describe '#convert_byte_to_access_rights' do
33
- let(:rights) { %w(export view proof) }
33
+ let(:rights) { %w(view annotate download export) }
34
34
 
35
35
  it 'raises error if rights is not an integer' do
36
36
  lambda { subject.send(:convert_byte_to_access_rights, :export) }.should raise_error(ArgumentError)
37
37
  end
38
38
 
39
39
  it 'returns correct rights array flag' do
40
- subject.send(:convert_byte_to_access_rights, 13).should =~ rights.map(&:to_sym)
40
+ subject.send(:convert_byte_to_access_rights, 15).should =~ rights.map(&:to_sym)
41
41
  end
42
42
  end
43
43
  end
@@ -32,7 +32,7 @@ describe GroupDocs::Document::Annotation do
32
32
  # Annotation#created_on is overwritten
33
33
  it { should have_alias(:created_on=, :createdOn=) }
34
34
  it { should alias_accessor(:annotation_position, :annotationPosition) }
35
- it { should alias_accessor(:position, :annotationPosition) }
35
+
36
36
 
37
37
  it { should have_alias(:annotationGuid=, :guid=) }
38
38
 
@@ -206,7 +206,7 @@ describe GroupDocs::Signature::Envelope do
206
206
 
207
207
  it 'accepts access credentials hash' do
208
208
  lambda do
209
- subject.sign!(recipient, {}, :client_id => 'client_id', :private_key => 'private_key')
209
+ subject.sign!(recipient, {}, :client_id => 'client_id', :private_key => 'private_key')
210
210
  end.should_not raise_error(ArgumentError)
211
211
  end
212
212
 
@@ -176,15 +176,15 @@ describe GroupDocs::User do
176
176
 
177
177
  describe '#access_rights' do
178
178
  it 'returns rights in human-readable format' do
179
- subject.instance_variable_set(:@access_rights, 15)
180
- subject.access_rights.should =~ [:export, :view, :proof, :download]
179
+ subject.instance_variable_set(:@access_rights, 46)
180
+ subject.access_rights.should =~ [ :view, :annotate, :download, :export, :all]
181
181
  end
182
182
  end
183
183
 
184
184
  describe '#access_rights=' do
185
185
  it 'converts rights in machine-readable format if array is passed' do
186
- subject.access_rights = %w(export view proof download)
187
- subject.instance_variable_get(:@access_rights).should == 15
186
+ subject.access_rights = %w(view annotate download export all)
187
+ subject.instance_variable_get(:@access_rights).should == 46
188
188
  end
189
189
 
190
190
  it 'does nothing if not array is passed' do
@@ -81,6 +81,7 @@ shared_examples_for GroupDocs::Signature::FieldMethods do
81
81
  describe '#modify_field!' do
82
82
  let(:field) { GroupDocs::Signature::Field.new }
83
83
  let(:document) { GroupDocs::Document.new(:file => GroupDocs::Storage::File.new) }
84
+ let(:recipient) { GroupDocs::Signature::Recipient.new }
84
85
 
85
86
  before(:each) do
86
87
  mock_api_server(load_json('signature_field_add'))
@@ -88,16 +89,16 @@ shared_examples_for GroupDocs::Signature::FieldMethods do
88
89
 
89
90
  it 'accepts access credentials hash' do
90
91
  lambda do
91
- subject.modify_field!(field, document, :client_id => 'client_id', :private_key => 'private_key')
92
+ subject.modify_field!(field, document, recipient, :client_id => 'client_id', :private_key => 'private_key')
92
93
  end.should_not raise_error(ArgumentError)
93
94
  end
94
95
 
95
96
  it 'raises error if field is not GroupDocs::Signature::Field object' do
96
- lambda { subject.modify_field!('Field', document) }.should raise_error(ArgumentError)
97
+ lambda { subject.modify_field!('Field', document, recipient) }.should raise_error(ArgumentError)
97
98
  end
98
99
 
99
100
  it 'raises error if document is not GroupDocs::Document object' do
100
- lambda { subject.modify_field!(field, 'Document') }.should raise_error(ArgumentError)
101
+ lambda { subject.modify_field!(field, 'Document', recipient) }.should raise_error(ArgumentError)
101
102
  end
102
103
 
103
104
  it 'uses field and first field location as payload' do
@@ -109,7 +110,7 @@ shared_examples_for GroupDocs::Signature::FieldMethods do
109
110
  field.should_receive(:locations).and_return(locations)
110
111
  locations.should_receive(:first).and_return(location)
111
112
  payload.should_receive(:merge!).with(location).and_return(payload)
112
- subject.modify_field!(field, document)
113
+ subject.modify_field!(field, document, recipient)
113
114
  end
114
115
  end
115
116
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: groupdocs
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.6.0
4
+ version: 1.7.0
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2014-05-21 00:00:00.000000000 Z
12
+ date: 2014-08-08 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: rest-client
@@ -180,6 +180,7 @@ files:
180
180
  - .travis.yml
181
181
  - CHANGELOG.md
182
182
  - Gemfile
183
+ - LICENSE.txt
183
184
  - README.md
184
185
  - Rakefile
185
186
  - examples/README.md
@@ -234,12 +235,15 @@ files:
234
235
  - examples/api-samples/public/docs/sample41.html
235
236
  - examples/api-samples/public/docs/sample42.html
236
237
  - examples/api-samples/public/docs/sample43.html
238
+ - examples/api-samples/public/docs/sample44.html
239
+ - examples/api-samples/public/docs/sample45.html
237
240
  - examples/api-samples/public/images/help.png
238
241
  - examples/api-samples/public/images/info.png
239
242
  - examples/api-samples/public/templates/base-simple_source.html
240
243
  - examples/api-samples/public/templates/merge_feid_doc.docx
241
244
  - examples/api-samples/public/templates/merge_field1_doc.docx
242
245
  - examples/api-samples/public/templates/merge_field2_doc.docx
246
+ - examples/api-samples/public/templates/merge_field3_doc.docx
243
247
  - examples/api-samples/public/templates/test_all_fields2.pdf
244
248
  - examples/api-samples/public/templates/testdocument.html
245
249
  - examples/api-samples/public/templates/welcome.htm
@@ -288,6 +292,8 @@ files:
288
292
  - examples/api-samples/samples/sample41.rb
289
293
  - examples/api-samples/samples/sample42.rb
290
294
  - examples/api-samples/samples/sample43.rb
295
+ - examples/api-samples/samples/sample44.rb
296
+ - examples/api-samples/samples/sample45.rb
291
297
  - examples/api-samples/views/_others_samples.haml
292
298
  - examples/api-samples/views/annotation_sample.haml
293
299
  - examples/api-samples/views/envelope_sample.haml
@@ -337,6 +343,8 @@ files:
337
343
  - examples/api-samples/views/sample41.haml
338
344
  - examples/api-samples/views/sample42.haml
339
345
  - examples/api-samples/views/sample43.haml
346
+ - examples/api-samples/views/sample44.haml
347
+ - examples/api-samples/views/sample45.haml
340
348
  - examples/api-samples/web.rb
341
349
  - examples/viewer/Gemfile
342
350
  - examples/viewer/app.rb
@@ -365,20 +373,26 @@ files:
365
373
  - lib/groupdocs/document/annotation/reply.rb
366
374
  - lib/groupdocs/document/annotation/reviewer.rb
367
375
  - lib/groupdocs/document/change.rb
376
+ - lib/groupdocs/document/editor.rb
368
377
  - lib/groupdocs/document/field.rb
369
378
  - lib/groupdocs/document/metadata.rb
370
379
  - lib/groupdocs/document/rectangle.rb
380
+ - lib/groupdocs/document/style.rb
371
381
  - lib/groupdocs/document/view.rb
372
382
  - lib/groupdocs/errors.rb
373
383
  - lib/groupdocs/job.rb
374
384
  - lib/groupdocs/post.rb
375
385
  - lib/groupdocs/questionnaire.rb
376
386
  - lib/groupdocs/questionnaire/collector.rb
387
+ - lib/groupdocs/questionnaire/collector_style.rb
377
388
  - lib/groupdocs/questionnaire/execution.rb
378
389
  - lib/groupdocs/questionnaire/page.rb
379
390
  - lib/groupdocs/questionnaire/question.rb
380
391
  - lib/groupdocs/questionnaire/question/answer.rb
381
392
  - lib/groupdocs/questionnaire/question/conditions.rb
393
+ - lib/groupdocs/questionnaire/style/base_font.rb
394
+ - lib/groupdocs/questionnaire/style/question_title.rb
395
+ - lib/groupdocs/questionnaire/style/title.rb
382
396
  - lib/groupdocs/signature.rb
383
397
  - lib/groupdocs/signature/contact.rb
384
398
  - lib/groupdocs/signature/envelope.rb
@@ -598,7 +612,8 @@ files:
598
612
  - spec/support/shared_examples/signature/shared/recipient_methods.rb
599
613
  - spec/support/shared_examples/signature/shared/resource_methods.rb
600
614
  homepage: https://github.com/groupdocs/groupdocs-ruby
601
- licenses: []
615
+ licenses:
616
+ - MIT
602
617
  post_install_message:
603
618
  rdoc_options: []
604
619
  require_paths: