diff --git a/lib/syspro.rb b/lib/syspro.rb
index 3c1d79b..77f4b07 100644
--- a/lib/syspro.rb
+++ b/lib/syspro.rb
@@ -21,18 +21,24 @@ require 'syspro/version'
require 'syspro/api_operations/request'
require 'syspro/api_operations/query'
+require 'syspro/api_operations/transaction'
require 'syspro/business_objects/combrw'
require 'syspro/business_objects/comfch'
require 'syspro/business_objects/comfnd'
require 'syspro/business_objects/sorqry'
+require 'syspro/business_objects/portor'
+require 'syspro/business_objects/porqry'
+require 'syspro/business_objects/models/sor'
require 'syspro/business_objects/models/sor_detail'
+require 'syspro/business_objects/models/por'
require 'syspro/business_objects/parsers/combrw_parser'
require 'syspro/business_objects/parsers/comfch_parser'
require 'syspro/business_objects/parsers/comfnd_parser'
require 'syspro/business_objects/parsers/sorqry_parser'
+require 'syspro/business_objects/parsers/portor_parser'
# Main Module
module Syspro
diff --git a/lib/syspro/api_operations/transaction.rb b/lib/syspro/api_operations/transaction.rb
new file mode 100644
index 0000000..5cbb82e
--- /dev/null
+++ b/lib/syspro/api_operations/transaction.rb
@@ -0,0 +1,35 @@
+# frozen_string_literal: true
+
+module Syspro
+ module ApiOperations
+ module Transaction
+ module ClassMethods
+ def post(params)
+ request(:get, '/Transaction/Post', params)
+ end
+
+ private
+
+ def warn_on_opts_in_params(params)
+ Util::OPTS_USER_SPECIFIED.each do |opt|
+ if params.key?(opt)
+ warn("WARNING: #{opt} should be in opts instead of params.")
+ end
+ end
+ end
+ end # ClassMethods
+
+ def self.included(base)
+ base.extend(ClassMethods)
+ end
+
+ protected
+
+ def request(method, url, params = {}, opts ={})
+ opts = @opts.merge(Util.normalize_opts(opts))
+ Request.request(method, url, params, opts)
+ end
+ end
+ end
+end
+
diff --git a/lib/syspro/business_objects/models/por_detail.rb b/lib/syspro/business_objects/models/por_detail.rb
new file mode 100644
index 0000000..987c287
--- /dev/null
+++ b/lib/syspro/business_objects/models/por_detail.rb
@@ -0,0 +1,10 @@
+module Syspro
+ module BusinessObjects
+ module Models
+ class PorDetail
+ attr_accessor :grn, :lot_number, :purchase_order, :purchase_order_line
+ end
+ end
+ end
+end
+
diff --git a/lib/syspro/business_objects/parsers/porqry_parser.rb b/lib/syspro/business_objects/parsers/porqry_parser.rb
new file mode 100644
index 0000000..da0dbb9
--- /dev/null
+++ b/lib/syspro/business_objects/parsers/porqry_parser.rb
@@ -0,0 +1,58 @@
+# frozen_string_literal: true
+
+module Syspro
+ module BusinessObjects
+ module Parsers
+ class PorQryParser
+ attr_reader :doc
+
+ def initialize(doc)
+ @doc = doc
+ end
+
+ def parse
+ por = Syspro::BusinessObjects::Models::PorDetail.new()
+
+ por.purchase_order = doc.first_element_child.xpath('PurchaseOrder').text
+ por.supplier = doc.first_element_child.xpath('Supplier').text
+ por.supplier_name = doc.first_element_child.xpath('SupplierName').text
+ por.supplier_class = doc.first_element_child.xpath('SupplierClass').text
+ por.customer = doc.first_element_child.xpath('Customer').text
+ por.customer_name = doc.first_element_child.xpath('CustomerName').text
+ por.customer_po_number = doc.first_element_child.xpath('CustomerPoNumber').text
+ por.supplier_addr_1 = doc.first_element_child.xpath('SupplierAddr1').text
+ por.supplier_addr_2 = doc.first_element_child.xpath('SupplierAddr2').text
+ por.supplier_addr_3 = doc.first_element_child.xpath('SupplierAddr3').text
+ por.supplier_addr_3_locality = doc.first_element_child.xpath('SupplierAddr3Locality').text
+ por.supplier_addr_4 = doc.first_element_child.xpath('SupplierAddr4').text
+ por.supplier_addr_5 = doc.first_element_child.xpath('SupplierAddr5').text
+ por.sup_postal_code = doc.first_element_child.xpath('SupPostalCode').text
+ por.currency = doc.first_element_child.xpath('Currency').text
+ por.local_supplier = doc.first_element_child.xpath('LocalSupplier').text
+ por.description = doc.first_element_child.xpath('Description').text
+ por.delivery_name = doc.first_element_child.xpath('DeliveryName').text
+ por.delivery_addr_1 = doc.first_element_child.xpath('DeliveryAddr1').text
+ por.delivery_addr_2 = doc.first_element_child.xpath('DeliveryAddr2').text
+ por.delivery_addr_3 = doc.first_element_child.xpath('DeliveryAddr3').text
+ por.delivery_addr_3_locality = doc.first_element_child.xpath('DeliveryAddr3Locality').text
+ por.delivery_addr_4 = doc.first_element_child.xpath('DeliveryAddr4').text
+ por.delivery_addr_5 = doc.first_element_child.xpath('DeliveryAddr5').text
+ por.postal_code = doc.first_element_child.xpath('PostalCode').text
+ por.delivery_gps_lat = doc.first_element_child.xpath('DeliveryGpsLat').text
+ por.delivery_gps_long = doc.first_element_child.xpath('DeliveryGpsLong').text
+ por.order_status = doc.first_element_child.xpath('OrderStatus').text
+ por.order_status_description = doc.first_element_child.xpath('OrderStatusDescription').text
+ por.exchange_rate_fixed_flag = doc.first_element_child.xpath('ExchangeRateFixedFlag').text
+ por.po_exchange_rate = doc.first_element_child.xpath('PoExchangeRate').text
+ por.blanket_po_contract = doc.first_element_child.xpath('BlanketPoContract').text
+ por.ap_invoice_terms = doc.first_element_child.xpath('ApInvoiceTerms').text
+ por.ap_invoice_terms_description = doc.first_element_child.xpath('ApInvoiceTermsDescription').text
+ por.completed_date = doc.first_element_child.xpath('CompletedDate').text
+ por.warehouse = doc.first_element_child.xpath('Warehouse').text
+ por.warehouse_desc
+ end
+ end
+ end
+ end
+end
+
diff --git a/lib/syspro/business_objects/parsers/portor_parser.rb b/lib/syspro/business_objects/parsers/portor_parser.rb
new file mode 100644
index 0000000..e7b9a40
--- /dev/null
+++ b/lib/syspro/business_objects/parsers/portor_parser.rb
@@ -0,0 +1,61 @@
+# frozen_string_literal: true
+
+module Syspro
+ module BusinessObjects
+ module Parsers
+ class PorTorParser
+ attr_reader :doc
+
+ def initialize(doc)
+ @doc = doc
+ end
+
+ def parse
+ gl_journal = doc.first_element_child.xpath('GlJournal')
+ gl_journal_obj = gl_journal.children.map do |el|
+ next if el.name == 'text'
+ {
+ name: el.name,
+ text: el.text
+ }
+ end.compact
+
+ key = {}
+ key[:jnl_year] = doc.first_element_child.xpath('JnlYear')
+ key[:jnl_month] = doc.first_element_child.xpath('JnlMonth')
+ key[:journal] = doc.first_element_child.xpath('Journal')
+ key[:entry_number] = doc.first_element_child.xpath('EntryNumber')
+ key[:warehouse] = doc.first_element_child.xpath('Warehouse')
+ key[:gl_journal] = gl_journal_obj
+
+ binding.pry
+
+ receipts = doc.first_element_child.xpath('Receipt')
+ receipts_obj = receipts.flat_map do |el|
+ el.elements.map do |inner|
+ [inner.name,
+ inner.value]
+ end
+ end.compact.to_h
+
+ receipt_models = receipts_obj.map do |receipt|
+ Por.new(
+ grn: receipt.grn,
+ lot_number: receipt.lot_number,
+ purchase_order: receipt.purchase_order,
+ purchase_order_line: receipt.purchase_order_line
+ )
+ end
+
+ PorTorObject.new(
+ key,
+ receipt_models
+ )
+ end
+
+ PorTorObject = Struct.new(:key, :receipts)
+ end
+ end
+ end
+end
+
diff --git a/lib/syspro/business_objects/porqry.rb b/lib/syspro/business_objects/porqry.rb
new file mode 100644
index 0000000..f60e8d3
--- /dev/null
+++ b/lib/syspro/business_objects/porqry.rb
@@ -0,0 +1,48 @@
+# frozen_string_literal: true
+
+require 'syspro/business_objects/parsers/porqry_parser'
+require 'erb'
+
+module Syspro
+ module BusinessObjects
+ class PorQry < ApiResource
+ include Syspro::ApiOperations::Query
+ include Syspro::BusinessObjects::Parsers
+
+ attr_accessor :purchase_order, :include_stocked_lines, :include_non_stocked_lines,
+ :include_freight_lines, :include_miscellaneous_lines, :include_comment_lines,
+ :include_completed_lines, :include_grns, :include_history, :include_lct_details,
+ :include_requisition_details, :include_requisition_routing, :include_sales_orders,
+ :include_custom_forms, :filter_type, :filter_value
+
+ def call(user_id)
+ xml_in = template.result(binding)
+ business_object = 'PORQRY'
+ params = {
+ 'UserId' => user_id,
+ 'BusinessObject' => business_object,
+ 'XmlIn' => xml_in
+ }
+ resp = PorQry.query(params)
+
+ parse_response(resp)
+ end
+
+ def template
+ ERB.new File.read(File.expand_path('schemas/porqry.xml.erb', File.dirname(__FILE__))), nil, '%'
+ end
+
+ def parse_response(resp)
+ handle_errors(resp)
+ parser = PorQryParser.new(resp[0].data)
+ parser.parse
+ end
+
+ def handle_errors(resp)
+ body = resp[0].http_body
+ raise SysproError, body if body =~ /^(ERROR)/
+ end
+ end
+ end
+end
+
diff --git a/lib/syspro/business_objects/portor.rb b/lib/syspro/business_objects/portor.rb
new file mode 100644
index 0000000..12f1e0f
--- /dev/null
+++ b/lib/syspro/business_objects/portor.rb
@@ -0,0 +1,51 @@
+# frozen_string_literal: true
+
+require 'syspro/business_objects/parsers/portor_parser'
+require 'erb'
+
+module Syspro
+ module BusinessObjects
+ class PorTor < ApiResource
+ include Syspro::ApiOperations::Transaction
+ include Syspro::BusinessObjects::Parsers
+
+ attr_accessor :transaction_date, :ignore_warnings, :non_stocked_wh_to_use, :grn_matching_action,
+ :allow_blank_supplier, :apply_if_entire_document_valid, :validate_only,
+ :manual_serial_transfers_allowed, :ignore_analysis
+
+ def call(user_id)
+ raise NotImplementedError.new("PORTOR not implemented yet.")
+ #xml_parameters = params_template.result(binding)
+ #xml_in = template.result(binding)
+ #business_object = 'PORTOR'
+ #params = { 'UserId' => user_id,
+ #'BusinessObject' => business_object,
+ #'XmlParameters' => xml_parameters,
+ #'XmlIn' => xml_in }
+ #resp = PorTor.post(params)
+
+ #parse_response(resp)
+ end
+
+ def template
+ ERB.new File.read(File.expand_path('schemas/portor.xml.erb', File.dirname(__FILE__))), nil, '%'
+ end
+
+ def params_template
+ ERB.new File.read(File.expand_path('schemas/portor_doc.xml.erb', File.dirname(__FILE__))), nil, '%'
+ end
+
+ def parse_response(resp)
+ handle_errors(resp)
+ parser = PorTorParser.new(resp[0].data)
+ parser.parse
+ end
+
+ def handle_errors(resp)
+ body = resp[0].http_body
+ raise SysproError, body if body =~ /^(ERROR)/
+ end
+ end
+ end
+end
+
diff --git a/lib/syspro/business_objects/schemas/porqry.xml.erb b/lib/syspro/business_objects/schemas/porqry.xml.erb
new file mode 100644
index 0000000..3b331ed
--- /dev/null
+++ b/lib/syspro/business_objects/schemas/porqry.xml.erb
@@ -0,0 +1,26 @@
+
+
+
+ <%= @purchase_order %>
+
+
+
+
+
+
+
diff --git a/lib/syspro/business_objects/schemas/portor.xml.erb b/lib/syspro/business_objects/schemas/portor.xml.erb
new file mode 100644
index 0000000..0ed2c23
--- /dev/null
+++ b/lib/syspro/business_objects/schemas/portor.xml.erb
@@ -0,0 +1,227 @@
+
+
+
+
+ -
+
+
+ 436
+ 1
+
+
+ 750.000
+
+
+
+
+
+ P
+ N
+ 311
+
+ 1
+ N
+
+
+
+
+
+ A1
+ 750.000
+
+
+
+
+ 0205
+ 1
+
+
+
+
+
+
+ 999
+ 1
+
+ 8
+
+
+
+ N
+ N
+ N
+ Y
+
+ 150.00
+
+ Cost Ref
+ 00-1170
+ 0000026
+ 150.00
+
+
+ Air
+ Conf
+ East
+
+
+
+
+ 100
+ Analysis entry details
+
+
+
+ Air
+ Conf
+ East
+
+
+
+
+ 100
+ Analysis entry details
+
+
+ P/O Receipt note
+ 00-1540
+
+
+
+
+
+
+
+
+
+
+ N
+
+
+
+ Air
+ Conf
+ East
+
+
+
+
+ 100
+ Analysis entry details
+
+
+
+ Air
+ Conf
+ East
+
+
+
+
+ 100
+ Analysis entry details
+
+
+
+
+ -
+
+
+ 436
+ 2
+
+
+ 50.000
+
+
+
+ N
+
+
+
+
+ N
+ 301
+
+
+ N
+
+ 0205
+ 50
+
+
+
+
+
+
+ 98
+ 1
+
+ 8
+
+
+
+
+
+
+ -
+
+
+ 312
+ 10.000
+
+
+
+
+
+ P
+
+ 1
+ N
+
+ A1
+ 10.000
+
+
+
+ N
+
+ 0205
+ 1
+
+
+
+
+
+ N
+ N
+ Y
+
+ 150.00
+
+ Cost Ref
+ 30-4400
+
+ 150.00
+
+ P/O Receipt note
+ 00-1540
+
+
+
+
+
+
+
+
+
+
+ N
+
+
+
+
+
diff --git a/lib/syspro/business_objects/schemas/portor_doc.xml.erb b/lib/syspro/business_objects/schemas/portor_doc.xml.erb
new file mode 100644
index 0000000..21687fa
--- /dev/null
+++ b/lib/syspro/business_objects/schemas/portor_doc.xml.erb
@@ -0,0 +1,15 @@
+
+
+
+ <%= @transaction_date %>
+ <%= @ignore_warnings ? "N" : "Y"%>
+ <%= @non_stocked_wh_to_use %>
+ <%= @grn_matching_action %>
+ <%= @allow_blank_supplier ? "N" : "Y" %>
+ <%= @apply_if_entire_document_valid ? "N" : "Y" %>
+ <%= @validate_only ? "N" : "Y" %>
+ <%= @manual_serial_transfers_allowed ? "N" : "Y" %>
+ <%= @ignore_analysis ? "N" : "Y" %>
+
+
+
diff --git a/test/cassettes/test_client_block_execution.yml b/test/cassettes/test_client_block_execution.yml
index 963dbba..eda235d 100644
--- a/test/cassettes/test_client_block_execution.yml
+++ b/test/cassettes/test_client_block_execution.yml
@@ -27,10 +27,10 @@ http_interactions:
Server:
- Microsoft-HTTPAPI/2.0
Date:
- - Mon, 14 May 2018 20:17:40 GMT
+ - Tue, 15 May 2018 00:53:44 GMT
body:
encoding: UTF-8
string: 7.0.0.6
http_version:
- recorded_at: Mon, 14 May 2018 20:17:40 GMT
+ recorded_at: Tue, 15 May 2018 00:53:43 GMT
recorded_with: VCR 4.0.0
diff --git a/test/cassettes/test_get_syspro_version.yml b/test/cassettes/test_get_syspro_version.yml
index 963dbba..eda235d 100644
--- a/test/cassettes/test_get_syspro_version.yml
+++ b/test/cassettes/test_get_syspro_version.yml
@@ -27,10 +27,10 @@ http_interactions:
Server:
- Microsoft-HTTPAPI/2.0
Date:
- - Mon, 14 May 2018 20:17:40 GMT
+ - Tue, 15 May 2018 00:53:44 GMT
body:
encoding: UTF-8
string: 7.0.0.6
http_version:
- recorded_at: Mon, 14 May 2018 20:17:40 GMT
+ recorded_at: Tue, 15 May 2018 00:53:43 GMT
recorded_with: VCR 4.0.0
diff --git a/test/cassettes/test_logoff_error.yml b/test/cassettes/test_logoff_error.yml
index 3394f37..3d45574 100644
--- a/test/cassettes/test_logoff_error.yml
+++ b/test/cassettes/test_logoff_error.yml
@@ -27,10 +27,10 @@ http_interactions:
Server:
- Microsoft-HTTPAPI/2.0
Date:
- - Mon, 14 May 2018 20:17:51 GMT
+ - Tue, 15 May 2018 00:53:22 GMT
body:
encoding: UTF-8
string: 'ERROR: Unable to read the SYSPRO base directory registry string BaseDir8'
http_version:
- recorded_at: Mon, 14 May 2018 20:17:50 GMT
+ recorded_at: Tue, 15 May 2018 00:53:21 GMT
recorded_with: VCR 4.0.0
diff --git a/test/cassettes/test_logon.yml b/test/cassettes/test_logon.yml
index 64c8ba6..0278b94 100644
--- a/test/cassettes/test_logon.yml
+++ b/test/cassettes/test_logon.yml
@@ -27,10 +27,10 @@ http_interactions:
Server:
- Microsoft-HTTPAPI/2.0
Date:
- - Mon, 14 May 2018 20:17:49 GMT
+ - Tue, 15 May 2018 00:54:50 GMT
body:
encoding: UTF-8
- string: 'DC3EC6C004B7FF4B8BF56FF221315DAA00 '
+ string: 'B83836D0602F4447B5F1473EF76DFE8200 '
http_version:
- recorded_at: Mon, 14 May 2018 20:17:48 GMT
+ recorded_at: Tue, 15 May 2018 00:54:49 GMT
recorded_with: VCR 4.0.0
diff --git a/test/cassettes/test_logon_error.yml b/test/cassettes/test_logon_error.yml
index fe6764c..320c8f1 100644
--- a/test/cassettes/test_logon_error.yml
+++ b/test/cassettes/test_logon_error.yml
@@ -27,10 +27,10 @@ http_interactions:
Server:
- Microsoft-HTTPAPI/2.0
Date:
- - Mon, 14 May 2018 20:17:51 GMT
+ - Tue, 15 May 2018 00:54:41 GMT
body:
encoding: UTF-8
string: 'ERROR: Invalid operator password'
http_version:
- recorded_at: Mon, 14 May 2018 20:17:50 GMT
+ recorded_at: Tue, 15 May 2018 00:54:40 GMT
recorded_with: VCR 4.0.0
diff --git a/test/cassettes/test_por_query.yml b/test/cassettes/test_por_query.yml
new file mode 100644
index 0000000..15e85a6
--- /dev/null
+++ b/test/cassettes/test_por_query.yml
@@ -0,0 +1,150 @@
+---
+http_interactions:
+- request:
+ method: get
+ uri: http://syspro.wildlandlabs.com:90/SYSPROWCFService/Rest/logon?CompanyId=L&CompanyPassword=&Operator=wland&OperatorPassword=piperita2016
+ body:
+ encoding: US-ASCII
+ string: ''
+ headers:
+ User-Agent:
+ - Syspro/7 RubyBindings/1.0.0.alpha.1
+ Content-Type:
+ - application/x-www-form-urlencoded
+ Accept-Encoding:
+ - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
+ Accept:
+ - "*/*"
+ response:
+ status:
+ code: 200
+ message: OK
+ headers:
+ Content-Length:
+ - '36'
+ Content-Type:
+ - application/octet-stream
+ Server:
+ - Microsoft-HTTPAPI/2.0
+ Date:
+ - Tue, 15 May 2018 21:00:23 GMT
+ body:
+ encoding: UTF-8
+ string: '3087FDA601939146B2D8AD4FA1CD2F2600 '
+ http_version:
+ recorded_at: Tue, 15 May 2018 21:00:22 GMT
+- request:
+ method: get
+ uri: http://syspro.wildlandlabs.com:90/SYSPROWCFService/Rest/Query/Query?BusinessObject=PORQRY&UserId=3087FDA601939146B2D8AD4FA1CD2F2600%20%20&XmlIn=%3C?xml%20version=%221.0%22%20encoding=%22Windows-1252%22?%3E%0A%3CQuery%20xmlns:xsd=%22http://www.w3.org/2001/XMLSchema-instance%22%20xsd:noNamespaceSchemaLocation=%22PORQRY.XSD%22%3E%0A%20%20%3CKey%3E%0A%20%20%20%20%3CPurchaseOrder%3E%2000001%3C/PurchaseOrder%3E%0A%20%20%3C/Key%3E%0A%20%20%3COption%3E%0A%20%20%20%20%3CIncludeStockedLines%3EY%3C/IncludeStockedLines%3E%0A%20%20%20%20%3CIncludeNonStockedLines%3EY%3C/IncludeNonStockedLines%3E%0A%20%20%20%20%3CIncludeFreightLines%3EY%3C/IncludeFreightLines%3E%0A%20%20%20%20%3CIncludeMiscellaneousLines%3EY%3C/IncludeMiscellaneousLines%3E%0A%20%20%20%20%3CIncludeCommentLines%3EY%3C/IncludeCommentLines%3E%0A%20%20%20%20%3CIncludeCompletedLines%3EY%3C/IncludeCompletedLines%3E%0A%20%20%20%20%3CIncludeGrns%3EY%3C/IncludeGrns%3E%0A%20%20%20%20%3CIncludeHistory%3EY%3C/IncludeHistory%3E%0A%20%20%20%20%3CIncludeLctDetails%3EY%3C/IncludeLctDetails%3E%0A%20%20%20%20%3CIncludeRequisitionDetails%3EY%3C/IncludeRequisitionDetails%3E%0A%20%20%20%20%3CIncludeRequisitionRouting%3EY%3C/IncludeRequisitionRouting%3E%0A%20%20%20%20%3CIncludeSalesOrders%3EY%3C/IncludeSalesOrders%3E%0A%20%20%20%20%3CIncludeCustomForms%3EY%3C/IncludeCustomForms%3E%20%0A%20%20%20%20%3CXslStylesheet/%3E%0A%20%20%3C/Option%3E%0A%20%20%3CFilter%3E%0A%20%20%20%20%3CLineNo%20FilterType=%22A%22%20FilterValue=%22%22/%3E%20%20%20%20%20%0A%20%20%3C/Filter%3E%0A%3C/Query%3E%0A%0A
+ body:
+ encoding: US-ASCII
+ string: ''
+ headers:
+ User-Agent:
+ - Syspro/7 RubyBindings/1.0.0.alpha.1
+ Content-Type:
+ - application/x-www-form-urlencoded
+ Accept-Encoding:
+ - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
+ Accept:
+ - "*/*"
+ response:
+ status:
+ code: 200
+ message: OK
+ headers:
+ Content-Length:
+ - '20348'
+ Content-Type:
+ - application/octet-stream
+ Server:
+ - Microsoft-HTTPAPI/2.0
+ Date:
+ - Tue, 15 May 2018 21:00:28 GMT
+ body:
+ encoding: UTF-8
+ string: "\n\n 00001\nUTE002\nUTEXAM
+ LOGISTICS LIMITED(ZERO)\n\n\n\n\n\n\n\n\n\n\n\n$\nY\nDOLLAR\nULL
+ OWNED @ PDI\n\n\n\n\n\n\n\n
+ \ 0.000000\n 0.000000\n*\nCancelled\nNo\n
+ \ 1.000000\nNo\nA\nNET
+ 30\n\nU8\nULL
+ OWNED @ PDI\n2007-04-24\n2007-04-24\n2007-04-24\n\nLocal\n\nExempt
+ from tax\n\n\n2\nBRH\nBILL
+ HOLLOWAY\n0\nY\n\n\n1\nTempPO\nTemporary
+ PO\nTemporaryPo\nA\n1\n0\n{Spaces}\nY\n1\n\nN\n\n\n2\nBUY001\nBuyer
+ Order Number\nBuyerOrderNumber\nA\n15\n0\n{Spaces}\nY\n1\n1\nN\n\n\n\n\n1\n1\nStocked
+ line\n2804011COL\nSBL\nSPEARMINT
+ BLEND\nT\n1.000000\n0.000000\nI\nU8\nULL
+ OWNED @ PDI\n38,400.000\n
+ \ 38400.000000\n38,400.000\n
+ \ 38400.000000\n0.000\n
+ \ 0.000000\nLB\n\n\nY\n0.00000\n0.000\n0.00000\n
+ \ 0.00\n 0.00\n
+ \ 0.00\n 0.00\n\nLB\n2007-04-24\n\nSBL\nSPEARMINT
+ BLEND LAB-CP\nLB\n1\n1.000000\nM\n\n\n1.000000\nM\n1908-00\nHARRAH-CUSTOMER
+ OWNED\n2007-04-24\n\n00000\n\n\n\n\n\n\n\n1908-00\n\n\n\nNo\n\n\n\n\n$\nYes\nP\nN\nP\n0.00000\n0.000\nLB\n\nM\nManual
+ entry\n0.00000\n0.000\nLB\nV\nTotal
+ cost\n0.00000\n0.000\nLB\nP\nPurchase
+ price\n0.00000\n0.000\nLB\nT\nPrice+tax\n0.00000\n0.000\nLB\n\n\n\n\n\n2\n1\nStocked
+ line\n2804011COL\nSBL\nSPEARMINT
+ BLEND\nT\n1.000000\n0.000000\nI\nU8\nULL
+ OWNED @ PDI\n38,400.000\n
+ \ 38400.000000\n38,400.000\n
+ \ 38400.000000\n0.000\n
+ \ 0.000000\nLB\n\n\nY\n0.00000\n0.000\n0.00000\n
+ \ 0.00\n 0.00\n
+ \ 0.00\n 0.00\n\nLB\n2007-04-24\n\nSBL\nSPEARMINT
+ BLEND LAB-CP\nLB\n1\n1.000000\nM\n\n\n1.000000\nM\n1908-00\nHARRAH-CUSTOMER
+ OWNED\n2007-04-24\n\n00000\n\n\n\n\n\n\n\n1908-00\n\n\n\nNo\n\n\n\n\n$\nYes\nP\nN\nP\n0.00000\n0.000\nLB\n\nM\nManual
+ entry\n0.00000\n0.000\nLB\nV\nTotal
+ cost\n0.00000\n0.000\nLB\nP\nPurchase
+ price\n0.00000\n0.000\nLB\nT\nPrice+tax\n0.00000\n0.000\nLB\n\n\n\n\n\n3\n1\nStocked
+ line\n2804011COL\nSBL\nSPEARMINT
+ BLEND\nT\n1.000000\n0.000000\nI\nU8\nULL
+ OWNED @ PDI\n35,200.000\n
+ \ 35200.000000\n35,200.000\n
+ \ 35200.000000\n0.000\n
+ \ 0.000000\nLB\n\n\nY\n0.00000\n0.000\n0.00000\n
+ \ 0.00\n 0.00\n
+ \ 0.00\n 0.00\n\nLB\n2007-04-24\n\nSBL\nSPEARMINT
+ BLEND LAB-CP\nLB\n1\n1.000000\nM\n\n\n1.000000\nM\n1908-00\nHARRAH-CUSTOMER
+ OWNED\n2007-04-24\n\n00000\n\n\n\n\n\n\n\n1908-00\n\n\n\nNo\n\n\n\n\n$\nYes\nP\nN\nP\n0.00000\n0.000\nLB\n\nM\nManual
+ entry\n0.00000\n0.000\nLB\nV\nTotal
+ cost\n0.00000\n0.000\nLB\nP\nPurchase
+ price\n0.00000\n0.000\nLB\nT\nPrice+tax\n0.00000\n0.000\nLB\n\n\n\n\n\n4\n1\nStocked
+ line\n2804011COL\nSBL\nSPEARMINT
+ BLEND\nT\n1.000000\n0.000000\nI\nU8\nULL
+ OWNED @ PDI\n38,400.000\n
+ \ 38400.000000\n38,400.000\n
+ \ 38400.000000\n0.000\n
+ \ 0.000000\nLB\n\n\nY\n0.00000\n0.000\n0.00000\n
+ \ 0.00\n 0.00\n
+ \ 0.00\n 0.00\n\nLB\n2007-04-24\n\nSBL\nSPEARMINT
+ BLEND LAB-CP\nLB\n1\n1.000000\nM\n\n\n1.000000\nM\n1908-00\nHARRAH-CUSTOMER
+ OWNED\n2007-04-24\n\n00000\n\n\n\n\n\n\n\n1908-00\n\n\n\nNo\n\n\n\n\n$\nYes\nP\nN\nP\n0.00000\n0.000\nLB\n\nM\nManual
+ entry\n0.00000\n0.000\nLB\nV\nTotal
+ cost\n0.00000\n0.000\nLB\nP\nPurchase
+ price\n0.00000\n0.000\nLB\nT\nPrice+tax\n0.00000\n0.000\nLB\n\n\n\n\n\n5\n1\nStocked
+ line\n2804011COL\nSBL\nSPEARMINT
+ BLEND\nT\n1.000000\n0.000000\nI\nU8\nULL
+ OWNED @ PDI\n38,400.000\n
+ \ 38400.000000\n38,400.000\n
+ \ 38400.000000\n0.000\n
+ \ 0.000000\nLB\n\n\nY\n0.00000\n0.000\n0.00000\n
+ \ 0.00\n 0.00\n
+ \ 0.00\n 0.00\n\nLB\n2007-04-24\n\nSBL\nSPEARMINT
+ BLEND LAB-CP\nLB\n1\n1.000000\nM\n\n\n1.000000\nM\n1908-00\nHARRAH-CUSTOMER
+ OWNED\n2007-04-24\n\n00000\n\n\n\n\n\n\n\n1908-00\n\n\n\nNo\n\n\n\n\n$\nYes\nP\nN\nP\n0.00000\n0.000\nLB\n\nM\nManual
+ entry\n0.00000\n0.000\nLB\nV\nTotal
+ cost\n0.00000\n0.000\nLB\nP\nPurchase
+ price\n0.00000\n0.000\nLB\nT\nPrice+tax\n0.00000\n0.000\nLB\n\n\n\n\n\n
+ \ 0.00\n 0.00\n
+ \ 0.00\n0.00\n0.00\n0.00\n\n\n0.00\n
+ \ 0.00\n 0.00\n
+ \ 0.00\n0.00\n0.00\n\n\n\n\n\n "
+ http_version:
+ recorded_at: Tue, 15 May 2018 21:00:26 GMT
+recorded_with: VCR 4.0.0
diff --git a/test/cassettes/test_query_browse.yml b/test/cassettes/test_query_browse.yml
index 51feea7..7356a86 100644
--- a/test/cassettes/test_query_browse.yml
+++ b/test/cassettes/test_query_browse.yml
@@ -27,15 +27,15 @@ http_interactions:
Server:
- Microsoft-HTTPAPI/2.0
Date:
- - Mon, 14 May 2018 20:17:02 GMT
+ - Tue, 15 May 2018 00:54:01 GMT
body:
encoding: UTF-8
- string: 'B417B48864C0814DA59D1F349AEC8D8A00 '
+ string: '391E9C831A05AC4CAEE55E3092F4352D00 '
http_version:
- recorded_at: Mon, 14 May 2018 20:17:01 GMT
+ recorded_at: Tue, 15 May 2018 00:54:00 GMT
- request:
method: get
- uri: http://syspro.wildlandlabs.com:90/SYSPROWCFService/Rest/Query/Browse?UserId=B417B48864C0814DA59D1F349AEC8D8A00%20%20&XmlIn=%3C?xml%20version=%221.0%22%20encoding=%22Windows-1252%22?%3E%0A%3CBrowse%20xmlns:xsd=%22http://www.w3.org/2001/XMLSchema-instance%22%20xsd:noNamespaceSchemaLocation=%22COMBRW.XSD%22%3E%0A%20%20%3CBrowseName%3EInvMaster%3C/BrowseName%3E%0A%20%20%3CStartAtKey/%3E%0A%20%20%3CStartCondition%3E%3C/StartCondition%3E%0A%20%20%3CReturnRows%3E5%3C/ReturnRows%3E%0A%20%20%0A%20%20%3CBrowseDetails%3E%0A%20%20%20%20%3CTableName%3EInvMaster%3C/TableName%3E%0A%20%20%20%20%3CTitle%3EStockCodes%3C/Title%3E%0A%20%20%20%20%0A%20%20%20%20%20%20%3CColumn%3E%0A%20%20%20%20%20%20%20%20%3CColumnName%3EStockCode%3C/ColumnName%3E%0A%20%20%20%20%20%20%20%20%0A%20%20%20%20%20%20%20%20%0A%20%20%20%20%20%20%3C/Column%3E%0A%20%20%20%20%0A%20%20%3C/BrowseDetails%3E%0A%3C/Browse%3E%0A%0A
+ uri: http://syspro.wildlandlabs.com:90/SYSPROWCFService/Rest/Query/Browse?UserId=391E9C831A05AC4CAEE55E3092F4352D00%20%20&XmlIn=%3C?xml%20version=%221.0%22%20encoding=%22Windows-1252%22?%3E%0A%3CBrowse%20xmlns:xsd=%22http://www.w3.org/2001/XMLSchema-instance%22%20xsd:noNamespaceSchemaLocation=%22COMBRW.XSD%22%3E%0A%20%20%3CBrowseName%3EInvMaster%3C/BrowseName%3E%0A%20%20%3CStartAtKey/%3E%0A%20%20%3CStartCondition%3E%3C/StartCondition%3E%0A%20%20%3CReturnRows%3E5%3C/ReturnRows%3E%0A%20%20%0A%20%20%3CBrowseDetails%3E%0A%20%20%20%20%3CTableName%3EInvMaster%3C/TableName%3E%0A%20%20%20%20%3CTitle%3EStockCodes%3C/Title%3E%0A%20%20%20%20%0A%20%20%20%20%20%20%3CColumn%3E%0A%20%20%20%20%20%20%20%20%3CColumnName%3EStockCode%3C/ColumnName%3E%0A%20%20%20%20%20%20%20%20%0A%20%20%20%20%20%20%20%20%0A%20%20%20%20%20%20%3C/Column%3E%0A%20%20%20%20%0A%20%20%3C/BrowseDetails%3E%0A%3C/Browse%3E%0A%0A
body:
encoding: US-ASCII
string: ''
@@ -60,7 +60,7 @@ http_interactions:
Server:
- Microsoft-HTTPAPI/2.0
Date:
- - Mon, 14 May 2018 20:17:06 GMT
+ - Tue, 15 May 2018 00:54:06 GMT
body:
encoding: UTF-8
string: "\n\nStockCodes\n\n\n02\nAlphaNumeric\n\n
\n\n\n021\nAlphaNumeric\n\n
\n\n\n0214011IFF\nAlphaNumeric\n\n
\n\n\n022\nAlphaNumeric\n\n
\n\n\n023\nAlphaNumeric\n\n
\n\n02\n023\nTrue\nFalse\n\n\n\nStockCode\nStock code\n\n\n\n "
http_version:
- recorded_at: Mon, 14 May 2018 20:17:05 GMT
+ recorded_at: Tue, 15 May 2018 00:54:05 GMT
recorded_with: VCR 4.0.0
diff --git a/test/cassettes/test_query_fetch.yml b/test/cassettes/test_query_fetch.yml
index 840d7cc..d6c3422 100644
--- a/test/cassettes/test_query_fetch.yml
+++ b/test/cassettes/test_query_fetch.yml
@@ -27,15 +27,15 @@ http_interactions:
Server:
- Microsoft-HTTPAPI/2.0
Date:
- - Mon, 14 May 2018 20:17:15 GMT
+ - Tue, 15 May 2018 00:54:14 GMT
body:
encoding: UTF-8
- string: '9A5B2797B021A04DA9E933CBCF3CB59700 '
+ string: '18E80C621C869848B726D01FF3A134A100 '
http_version:
- recorded_at: Mon, 14 May 2018 20:17:14 GMT
+ recorded_at: Tue, 15 May 2018 00:54:13 GMT
- request:
method: get
- uri: http://syspro.wildlandlabs.com:90/SYSPROWCFService/Rest/Query/Fetch?UserId=9A5B2797B021A04DA9E933CBCF3CB59700%20%20&XmlIn=%3C?xml%20version=%221.0%22%20encoding=%22Windows-1252%22?%3E%0A%3CFetch%20xmlns:xsd=%22http://www.w3.org/2001/XMLSchema-instance%22%20xsd:noNamespaceSchemaLocation=%22COMFCH.XSD%22%3E%0A%20%20%3CTableName%3EInvMaster%3C/TableName%3E%0A%20%20%3CKey%3E02%3C/Key%3E%0A%20%20%0A%20%20%3CFullKeyProvided%3EY%3C/FullKeyProvided%3E%0A%20%20%3CDefaultType%3E%3C/DefaultType%3E%0A%20%20%3CEspressoFetch%3EN%3C/EspressoFetch%3E%0A%3C/Fetch%3E%0A%0A
+ uri: http://syspro.wildlandlabs.com:90/SYSPROWCFService/Rest/Query/Fetch?UserId=18E80C621C869848B726D01FF3A134A100%20%20&XmlIn=%3C?xml%20version=%221.0%22%20encoding=%22Windows-1252%22?%3E%0A%3CFetch%20xmlns:xsd=%22http://www.w3.org/2001/XMLSchema-instance%22%20xsd:noNamespaceSchemaLocation=%22COMFCH.XSD%22%3E%0A%20%20%3CTableName%3EInvMaster%3C/TableName%3E%0A%20%20%3CKey%3E02%3C/Key%3E%0A%20%20%0A%20%20%3CFullKeyProvided%3EY%3C/FullKeyProvided%3E%0A%20%20%3CDefaultType%3E%3C/DefaultType%3E%0A%20%20%3CEspressoFetch%3EN%3C/EspressoFetch%3E%0A%3C/Fetch%3E%0A%0A
body:
encoding: US-ASCII
string: ''
@@ -60,7 +60,7 @@ http_interactions:
Server:
- Microsoft-HTTPAPI/2.0
Date:
- - Mon, 14 May 2018 20:17:23 GMT
+ - Tue, 15 May 2018 00:54:23 GMT
body:
encoding: UTF-8
string: "\n\n\n\n\n\n
\ 0\n 0\n\n\n\n\n\n "
http_version:
- recorded_at: Mon, 14 May 2018 20:17:22 GMT
+ recorded_at: Tue, 15 May 2018 00:54:22 GMT
recorded_with: VCR 4.0.0
diff --git a/test/cassettes/test_query_query.yml b/test/cassettes/test_query_query.yml
index 6639629..97ecee4 100644
--- a/test/cassettes/test_query_query.yml
+++ b/test/cassettes/test_query_query.yml
@@ -27,15 +27,15 @@ http_interactions:
Server:
- Microsoft-HTTPAPI/2.0
Date:
- - Mon, 14 May 2018 20:17:32 GMT
+ - Tue, 15 May 2018 00:54:32 GMT
body:
encoding: UTF-8
- string: '34C603B5A0981D40BCB1B2E4111B1A5900 '
+ string: 'BE36CA1559EBC34985FC2D5EF166D75B00 '
http_version:
- recorded_at: Mon, 14 May 2018 20:17:31 GMT
+ recorded_at: Tue, 15 May 2018 00:54:31 GMT
- request:
method: get
- uri: http://syspro.wildlandlabs.com:90/SYSPROWCFService/Rest/Query/Query?BusinessObject=COMFND&UserId=34C603B5A0981D40BCB1B2E4111B1A5900%20%20&XmlIn=%3C?xml%20version=%221.0%22%20encoding=%22Windows-1252%22?%3E%0A%3CQuery%20xmlns:xsd=%22http://www.w3.org/2001/XMLSchema-instance%22%20xsd:noNamespaceSchemaLocation=%22COMFND.XSD%22%3E%0A%20%20%3CTableName%3EInvMaster%3C/TableName%3E%0A%20%20%3CReturnRows%3E5%3C/ReturnRows%3E%0A%20%20%3CColumns%3E%0A%20%20%20%20%0A%20%20%20%20%20%20%3CColumn%3EStockCode%3C/Column%3E%0A%20%20%20%20%0A%20%20%3C/Columns%3E%0A%20%20%0A%20%20%20%20%3CWhere%3E%0A%20%20%20%20%20%20%0A%20%20%20%20%20%20%20%20%3CExpression%3E%0A%20%20%20%20%20%20%20%20%20%20%3COpenBracket%3E(%3C/OpenBracket%3E%0A%20%20%20%20%20%20%20%20%20%20%0A%20%20%20%20%20%20%20%20%20%20%20%20%3CAndOr%3EAnd%3C/AndOr%3E%0A%20%20%20%20%20%20%20%20%20%20%0A%20%20%20%20%20%20%20%20%20%20%3CColumn%3EStockCode%3C/Column%3E%0A%20%20%20%20%20%20%20%20%20%20%3CCondition%3EEQ%3C/Condition%3E%0A%20%20%20%20%20%20%20%20%20%20%3CValue%3E02%3C/Value%3E%0A%20%20%20%20%20%20%20%20%20%20%3CCloseBracket%3E)%3C/CloseBracket%3E%0A%20%20%20%20%20%20%20%20%3C/Expression%3E%0A%20%20%20%20%20%20%0A%20%20%20%20%3C/Where%3E%0A%20%20%0A%20%20%3COrderBy%3E%0A%20%20%20%20%3CColumn%3EStockCode%3C/Column%3E%0A%20%20%3C/OrderBy%3E%0A%3C/Query%3E%0A
+ uri: http://syspro.wildlandlabs.com:90/SYSPROWCFService/Rest/Query/Query?BusinessObject=COMFND&UserId=BE36CA1559EBC34985FC2D5EF166D75B00%20%20&XmlIn=%3C?xml%20version=%221.0%22%20encoding=%22Windows-1252%22?%3E%0A%3CQuery%20xmlns:xsd=%22http://www.w3.org/2001/XMLSchema-instance%22%20xsd:noNamespaceSchemaLocation=%22COMFND.XSD%22%3E%0A%20%20%3CTableName%3EInvMaster%3C/TableName%3E%0A%20%20%3CReturnRows%3E5%3C/ReturnRows%3E%0A%20%20%3CColumns%3E%0A%20%20%20%20%0A%20%20%20%20%20%20%3CColumn%3EStockCode%3C/Column%3E%0A%20%20%20%20%0A%20%20%3C/Columns%3E%0A%20%20%0A%20%20%20%20%3CWhere%3E%0A%20%20%20%20%20%20%0A%20%20%20%20%20%20%20%20%3CExpression%3E%0A%20%20%20%20%20%20%20%20%20%20%3COpenBracket%3E(%3C/OpenBracket%3E%0A%20%20%20%20%20%20%20%20%20%20%0A%20%20%20%20%20%20%20%20%20%20%20%20%3CAndOr%3EAnd%3C/AndOr%3E%0A%20%20%20%20%20%20%20%20%20%20%0A%20%20%20%20%20%20%20%20%20%20%3CColumn%3EStockCode%3C/Column%3E%0A%20%20%20%20%20%20%20%20%20%20%3CCondition%3EEQ%3C/Condition%3E%0A%20%20%20%20%20%20%20%20%20%20%3CValue%3E02%3C/Value%3E%0A%20%20%20%20%20%20%20%20%20%20%3CCloseBracket%3E)%3C/CloseBracket%3E%0A%20%20%20%20%20%20%20%20%3C/Expression%3E%0A%20%20%20%20%20%20%0A%20%20%20%20%3C/Where%3E%0A%20%20%0A%20%20%3COrderBy%3E%0A%20%20%20%20%3CColumn%3EStockCode%3C/Column%3E%0A%20%20%3C/OrderBy%3E%0A%3C/Query%3E%0A
body:
encoding: US-ASCII
string: ''
@@ -60,7 +60,7 @@ http_interactions:
Server:
- Microsoft-HTTPAPI/2.0
Date:
- - Mon, 14 May 2018 20:17:40 GMT
+ - Tue, 15 May 2018 00:54:40 GMT
body:
encoding: UTF-8
string: "\n\n\nInvMaster\n\nStockCode\n\n\nStockCode\n\n\n\n02\n
\n
\ 1\n\n "
http_version:
- recorded_at: Mon, 14 May 2018 20:17:39 GMT
+ recorded_at: Tue, 15 May 2018 00:54:39 GMT
recorded_with: VCR 4.0.0
diff --git a/test/cassettes/test_sor_query.yml b/test/cassettes/test_sor_query.yml
index 4d735a4..3797ca3 100644
--- a/test/cassettes/test_sor_query.yml
+++ b/test/cassettes/test_sor_query.yml
@@ -27,15 +27,15 @@ http_interactions:
Server:
- Microsoft-HTTPAPI/2.0
Date:
- - Mon, 14 May 2018 20:16:48 GMT
+ - Tue, 15 May 2018 00:53:39 GMT
body:
encoding: UTF-8
- string: 'C525B53B5C1C0F4DA6A5DE07E7FE1D0000 '
+ string: '88B1144955783D4386011BDD954453CC00 '
http_version:
- recorded_at: Mon, 14 May 2018 20:16:48 GMT
+ recorded_at: Tue, 15 May 2018 00:53:38 GMT
- request:
method: get
- uri: http://syspro.wildlandlabs.com:90/SYSPROWCFService/Rest/Query/Query?BusinessObject=SORQRY&UserId=C525B53B5C1C0F4DA6A5DE07E7FE1D0000%20%20&XmlIn=%3C?xml%20version=%221.0%22%20encoding=%22Windows-1252%22?%3E%0A%3CQuery%20xmlns:xsd=%22http://www.w3.org/2001/XMLSchema-instance%22%20xsd:noNamespaceSchemaLocation=%22SORQRY.XSD%22%3E%0A%20%20%3CKey%3E%0A%20%20%20%20%3CSalesOrder%3E16R069%3C/SalesOrder%3E%0A%20%20%20%20%0A%20%20%3C/Key%3E%0A%20%20%3COption%3E%0A%20%20%20%20%3CIncludeStockedLines%3EN%3C/IncludeStockedLines%3E%0A%20%20%20%20%20%20%3CIncludeNonStockedLines%3EN%3C/IncludeNonStockedLines%3E%0A%20%20%20%20%20%20%3CIncludeFreightLines%3EN%3C/IncludeFreightLines%3E%0A%20%20%20%20%20%20%3CIncludeMiscLines%3EN%3C/IncludeMiscLines%3E%0A%20%20%20%20%20%20%3CIncludeCommentLines%3EN%3C/IncludeCommentLines%3E%0A%20%20%20%20%20%20%3CIncludeCompletedLines%3EN%3C/IncludeCompletedLines%3E%0A%20%20%20%20%20%20%3CIncludeSerials%3EN%3C/IncludeSerials%3E%0A%20%20%20%20%20%20%3CIncludeLots%3EN%3C/IncludeLots%3E%0A%20%20%20%20%20%20%3CIncludeBins%3EN%3C/IncludeBins%3E%0A%20%20%20%20%20%20%3CIncludeAttachedItems%3EN%3C/IncludeAttachedItems%3E%0A%20%20%20%20%20%20%3CIncludeCustomForms%3EN%3C/IncludeCustomForms%3E%0A%20%20%20%20%20%20%3CIncludeDetailLineCustomForms%3EN%3C/IncludeDetailLineCustomForms%3E%0A%20%20%20%20%20%20%3CIncludeValues%3EN%3C/IncludeValues%3E%0A%20%20%20%20%20%20%3CReturnLineShipDate%3EN%3C/ReturnLineShipDate%3E%0A%20%20%20%20%20%20%3CXslStylesheet/%3E%0A%20%20%3C/Option%3E%0A%3C/Query%3E%0A%0A
+ uri: http://syspro.wildlandlabs.com:90/SYSPROWCFService/Rest/Query/Query?BusinessObject=SORQRY&UserId=88B1144955783D4386011BDD954453CC00%20%20&XmlIn=%3C?xml%20version=%221.0%22%20encoding=%22Windows-1252%22?%3E%0A%3CQuery%20xmlns:xsd=%22http://www.w3.org/2001/XMLSchema-instance%22%20xsd:noNamespaceSchemaLocation=%22SORQRY.XSD%22%3E%0A%20%20%3CKey%3E%0A%20%20%20%20%3CSalesOrder%3E16R069%3C/SalesOrder%3E%0A%20%20%20%20%0A%20%20%3C/Key%3E%0A%20%20%3COption%3E%0A%20%20%20%20%3CIncludeStockedLines%3EN%3C/IncludeStockedLines%3E%0A%20%20%20%20%20%20%3CIncludeNonStockedLines%3EN%3C/IncludeNonStockedLines%3E%0A%20%20%20%20%20%20%3CIncludeFreightLines%3EN%3C/IncludeFreightLines%3E%0A%20%20%20%20%20%20%3CIncludeMiscLines%3EN%3C/IncludeMiscLines%3E%0A%20%20%20%20%20%20%3CIncludeCommentLines%3EN%3C/IncludeCommentLines%3E%0A%20%20%20%20%20%20%3CIncludeCompletedLines%3EN%3C/IncludeCompletedLines%3E%0A%20%20%20%20%20%20%3CIncludeSerials%3EN%3C/IncludeSerials%3E%0A%20%20%20%20%20%20%3CIncludeLots%3EN%3C/IncludeLots%3E%0A%20%20%20%20%20%20%3CIncludeBins%3EN%3C/IncludeBins%3E%0A%20%20%20%20%20%20%3CIncludeAttachedItems%3EN%3C/IncludeAttachedItems%3E%0A%20%20%20%20%20%20%3CIncludeCustomForms%3EN%3C/IncludeCustomForms%3E%0A%20%20%20%20%20%20%3CIncludeDetailLineCustomForms%3EN%3C/IncludeDetailLineCustomForms%3E%0A%20%20%20%20%20%20%3CIncludeValues%3EN%3C/IncludeValues%3E%0A%20%20%20%20%20%20%3CReturnLineShipDate%3EN%3C/ReturnLineShipDate%3E%0A%20%20%20%20%20%20%3CXslStylesheet/%3E%0A%20%20%3C/Option%3E%0A%3C/Query%3E%0A%0A
body:
encoding: US-ASCII
string: ''
@@ -60,7 +60,7 @@ http_interactions:
Server:
- Microsoft-HTTPAPI/2.0
Date:
- - Mon, 14 May 2018 20:16:53 GMT
+ - Tue, 15 May 2018 00:53:44 GMT
body:
encoding: UTF-8
string: "\n\n 0.000000\nN\n\nN\n
\ 1.000000\n1.000000\nM\n\nI\n\n\n\n\n\n\n\n000\n00\n0\n\n\n\n\n\n\n\nMATTB\n\n\n\n\n\n
\n\n\n0\nY\n\n\n\n\n\n "
http_version:
- recorded_at: Mon, 14 May 2018 20:16:52 GMT
+ recorded_at: Tue, 15 May 2018 00:53:43 GMT
recorded_with: VCR 4.0.0
diff --git a/test/cassettes/test_successful_logoff.yml b/test/cassettes/test_successful_logoff.yml
index 9ee8340..e8e9bff 100644
--- a/test/cassettes/test_successful_logoff.yml
+++ b/test/cassettes/test_successful_logoff.yml
@@ -27,15 +27,15 @@ http_interactions:
Server:
- Microsoft-HTTPAPI/2.0
Date:
- - Mon, 14 May 2018 20:17:59 GMT
+ - Tue, 15 May 2018 00:53:30 GMT
body:
encoding: UTF-8
- string: '305EC4843488A34FA16A50494B42BA7C00 '
+ string: 'BDEE07496905C3498683CDCAF0C7BB8100 '
http_version:
- recorded_at: Mon, 14 May 2018 20:17:58 GMT
+ recorded_at: Tue, 15 May 2018 00:53:30 GMT
- request:
method: get
- uri: http://syspro.wildlandlabs.com:90/SYSPROWCFService/Rest/logoff?UserId=305EC4843488A34FA16A50494B42BA7C00%20%20
+ uri: http://syspro.wildlandlabs.com:90/SYSPROWCFService/Rest/logoff?UserId=BDEE07496905C3498683CDCAF0C7BB8100%20%20
body:
encoding: US-ASCII
string: ''
@@ -60,10 +60,10 @@ http_interactions:
Server:
- Microsoft-HTTPAPI/2.0
Date:
- - Mon, 14 May 2018 20:17:59 GMT
+ - Tue, 15 May 2018 00:53:30 GMT
body:
encoding: UTF-8
string: '0'
http_version:
- recorded_at: Mon, 14 May 2018 20:17:59 GMT
+ recorded_at: Tue, 15 May 2018 00:53:30 GMT
recorded_with: VCR 4.0.0
diff --git a/test/por_test.rb b/test/por_test.rb
new file mode 100644
index 0000000..60dd405
--- /dev/null
+++ b/test/por_test.rb
@@ -0,0 +1,55 @@
+require 'test_helper'
+
+class PorTest < Minitest::Test
+ extend Minitest::Spec::DSL
+ before { VCR.insert_cassette name }
+ after { VCR.eject_cassette }
+
+ let(:username) { 'wland' }
+ let(:password) { 'piperita2016' }
+ let(:company) { 'L' }
+ let(:company_password) { '' }
+ let(:user_id) do
+ Syspro::Logon.logon(username, password, company, company_password)
+ end
+
+ #def test_por_transaction
+ #portor = Syspro::BusinessObjects::PorTor.new
+
+ #portor.transaction_date = "2006-04-08"
+ #portor.ignore_warnings = "N"
+ #portor.grn_matching_action = "A"
+ #portor.allow_blank_supplier = "N"
+ #portor.apply_if_entire_document_valid = "Y"
+ #portor.validate_only = "N"
+ #portor.manual_serial_transfers_allowed = "N"
+ #portor.ignore_analysis = "Y"
+
+ #por_result = portor.call(user_id.guid)
+ #assert_kind_of Syspro::BusinessObjects::Models::Por
+ #end
+
+ def test_por_query
+ porqry = Syspro::BusinessObjects::PorQry.new
+
+ porqry.purchase_order = " 00001"
+ porqry.include_stocked_lines = false
+ porqry.include_non_stocked_lines = false
+ porqry.include_freight_lines = false
+ porqry.include_miscellaneous_lines = false
+ porqry.include_comment_lines = false
+ porqry.include_completed_lines = false
+ porqry.include_grns = false
+ porqry.include_history = false
+ porqry.include_lct_details = false
+ porqry.include_requisition_details = false
+ porqry.include_requisition_routing = false
+ porqry.include_sales_orders = false
+ porqry.include_custom_forms = false
+ porqry.filter_type = "A"
+ porqry.filter_value = ""
+
+ por_result = porqry.call(user_id.guid)
+ assert_kind_of(Syspro::BusinessObjects::Models::Por, por_result)
+ end
+end
--
libgit2 0.21.4