allscripts_unity_client 1.2.0 → 1.2.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.
@@ -499,18 +499,28 @@ module AllscriptsUnityClient
499
499
  magic(magic_parameters)
500
500
  end
501
501
 
502
- def save_task_status(userid, transaction_id = nil, status = nil, delegate_id = nil, comment = nil)
502
+ def save_task_status(userid, transaction_id = nil, status = nil, delegate_id = nil, comment = nil, taskchanges = nil)
503
503
  if transaction_id.nil? && param.nil? && delegate_id.nil? && comment.nil?
504
504
  raise ArugmentError, "task_type, target_user, work_object_id, and comments can not all be nil"
505
505
  end
506
506
 
507
+ # Generate XML structure for rxxml
508
+ builder = Nokogiri::XML::Builder.new do |xml|
509
+ xml.taskchanges {
510
+ xml.refills("value" => taskchanges[:refills]) unless taskchanges[:refills].nil?
511
+ xml.days("value" => taskchanges[:days]) unless taskchanges[:days].nil?
512
+ xml.qty("value" => taskchanges[:qty]) unless taskchanges[:qty].nil?
513
+ }
514
+ end
515
+
507
516
  magic_parameters = {
508
517
  :action => "SaveTaskStatus",
509
518
  :userid => userid,
510
519
  :parameter1 => transaction_id,
511
520
  :parameter2 => status,
512
521
  :parameter3 => delegate_id,
513
- :parameter4 => comment
522
+ :parameter4 => comment,
523
+ :parameter6 => nokogiri_to_string(builder)
514
524
  }
515
525
  magic(magic_parameters)
516
526
  end
@@ -1,3 +1,3 @@
1
1
  module AllscriptsUnityClient
2
- VERSION = "1.2.0"
2
+ VERSION = "1.2.1"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: allscripts_unity_client
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.2.0
4
+ version: 1.2.1
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -10,7 +10,7 @@ authors:
10
10
  autorequire:
11
11
  bindir: bin
12
12
  cert_chain: []
13
- date: 2013-11-19 00:00:00.000000000 Z
13
+ date: 2013-11-20 00:00:00.000000000 Z
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
16
16
  name: savon