OnePica_AvaTax - Version 2.5.2

Version Notes

Fixed extension installation for versions below 1.6

Download this release

Release Info

Developer Astound Commerce
Extension OnePica_AvaTax
Version 2.5.2
Comparing to
See all releases


Code changes from version 2.5.0 to 2.5.2

Files changed (173) hide show
  1. app/code/community/OnePica/AvaTax/Block/Adminhtml/Export/Abstract/Grid.php +15 -11
  2. app/code/community/OnePica/AvaTax/Block/Adminhtml/Export/Log/Grid.php +9 -7
  3. app/code/community/OnePica/AvaTax/Block/Adminhtml/Export/Log/View.php +7 -5
  4. app/code/community/OnePica/AvaTax/Block/Adminhtml/Export/Queue/Grid.php +14 -12
  5. app/code/community/OnePica/AvaTax/Block/Adminhtml/Notification/Toolbar.php +1 -2
  6. app/code/community/OnePica/AvaTax/Block/Adminhtml/System/Config/Form/Field/Export.php +0 -0
  7. app/code/community/OnePica/AvaTax/Block/Adminhtml/Tax/Class/Edit/Form.php +3 -5
  8. app/code/community/OnePica/AvaTax/Block/Adminhtml/Tax/Class/Grid.php +2 -2
  9. app/code/community/OnePica/AvaTax/Block/Checkout/Onepage/Shipping/Method/Available.php +0 -0
  10. app/code/community/OnePica/AvaTax/{Model/Exception.php → Exception.php} +4 -6
  11. app/code/community/OnePica/AvaTax/Helper/Data.php +8 -29
  12. app/code/community/OnePica/AvaTax/Helper/Tax/Data.php +6 -3
  13. app/code/community/OnePica/AvaTax/Model/Abstract.php +2 -4
  14. app/code/community/OnePica/AvaTax/Model/Admin/Session.php +0 -0
  15. app/code/community/OnePica/AvaTax/Model/Adminhtml/Config.php +0 -0
  16. app/code/community/OnePica/AvaTax/Model/Adminhtml/Sales/Order/Create.php +2 -2
  17. app/code/community/OnePica/AvaTax/Model/Avatax/Abstract.php +23 -12
  18. app/code/community/OnePica/AvaTax/Model/Avatax/Address.php +114 -53
  19. app/code/community/OnePica/AvaTax/Model/Avatax/Estimate.php +8 -9
  20. app/code/community/OnePica/AvaTax/Model/Avatax/Exception/Address.php +3 -1
  21. app/code/community/OnePica/AvaTax/Model/Avatax/Exception/Commitfailure.php +3 -1
  22. app/code/community/OnePica/AvaTax/Model/Avatax/Exception/Unbalanced.php +3 -1
  23. app/code/community/OnePica/AvaTax/Model/Avatax/Invoice.php +30 -12
  24. app/code/community/OnePica/AvaTax/Model/Avatax/Ping.php +0 -0
  25. app/code/community/OnePica/AvaTax/Model/Config.php +12 -21
  26. app/code/community/OnePica/AvaTax/Model/Export.php +3 -3
  27. app/code/community/OnePica/AvaTax/Model/Export/Adapter/Abstract.php +0 -0
  28. app/code/community/OnePica/AvaTax/Model/Export/Adapter/Sql.php +21 -6
  29. app/code/community/OnePica/AvaTax/Model/Export/Entity/Abstract.php +3 -3
  30. app/code/community/OnePica/AvaTax/Model/Export/Entity/Log.php +0 -0
  31. app/code/community/OnePica/AvaTax/Model/Export/Entity/Queue.php +0 -0
  32. app/code/community/OnePica/AvaTax/Model/Observer.php +238 -98
  33. app/code/community/OnePica/AvaTax/Model/Records/Log.php +3 -2
  34. app/code/community/OnePica/AvaTax/Model/Records/Mysql4/Log.php +11 -1
  35. app/code/community/OnePica/AvaTax/Model/Records/Mysql4/Log/Collection.php +0 -0
  36. app/code/community/OnePica/AvaTax/Model/Records/Mysql4/Queue.php +12 -2
  37. app/code/community/OnePica/AvaTax/Model/Records/Mysql4/Queue/Collection.php +0 -0
  38. app/code/community/OnePica/AvaTax/Model/Records/Queue.php +0 -0
  39. app/code/community/OnePica/AvaTax/Model/Records/Queue/Process.php +24 -4
  40. app/code/community/OnePica/AvaTax/Model/Sales/Quote/Address.php +0 -0
  41. app/code/community/OnePica/AvaTax/Model/Sales/Quote/Address/Total/Grand.php +0 -0
  42. app/code/community/OnePica/AvaTax/Model/Sales/Quote/Address/Total/Tax.php +22 -17
  43. app/code/community/OnePica/AvaTax/Model/Session.php +1 -3
  44. app/code/community/OnePica/AvaTax/Model/Source/Actions.php +0 -0
  45. app/code/community/OnePica/AvaTax/Model/Source/Addressvalidation.php +0 -0
  46. app/code/community/OnePica/AvaTax/Model/Source/Customercodeformat.php +0 -0
  47. app/code/community/OnePica/AvaTax/Model/Source/Error.php +0 -0
  48. app/code/community/OnePica/AvaTax/Model/Source/Fieldlist.php +1 -1
  49. app/code/community/OnePica/AvaTax/Model/Source/Logmode.php +0 -0
  50. app/code/community/OnePica/AvaTax/Model/Source/Logtype.php +0 -0
  51. app/code/community/OnePica/AvaTax/Model/Source/Onerrorfrontend.php +0 -0
  52. app/code/community/OnePica/AvaTax/Model/Source/Regionfilter/List.php +0 -0
  53. app/code/community/OnePica/AvaTax/Model/Source/Regionfilter/Mode.php +0 -0
  54. app/code/community/OnePica/AvaTax/Model/Tax/Config.php +0 -0
  55. app/code/community/OnePica/AvaTax/controllers/Adminhtml/ExportController.php +15 -4
  56. app/code/community/OnePica/AvaTax/controllers/Adminhtml/GridController.php +0 -0
  57. app/code/community/OnePica/AvaTax/etc/adminhtml.xml +0 -0
  58. app/code/community/OnePica/AvaTax/etc/config.xml +1 -1
  59. app/code/community/OnePica/AvaTax/etc/system-disabled.xml +0 -0
  60. app/code/community/OnePica/AvaTax/etc/system.xml +0 -0
  61. app/code/community/OnePica/AvaTax/{data/avatax_records_setup/data-upgrade-2.2.0-2.2.1.php → sql/avatax_records_setup/mysql4-data-upgrade-2.2.0-2.2.1.php} +0 -0
  62. app/code/community/OnePica/AvaTax/sql/avatax_records_setup/mysql4-install-0.1.0.php +7 -14
  63. app/code/community/OnePica/AvaTax/sql/avatax_records_setup/mysql4-upgrade-0.1.4-0.1.5.php +22 -60
  64. app/code/community/OnePica/AvaTax/sql/avatax_records_setup/mysql4-upgrade-1.0.1-2.0.0.php +29 -103
  65. app/code/community/OnePica/AvaTax/sql/avatax_records_setup/mysql4-upgrade-2.5.0.0-2.5.0.1.php +39 -277
  66. app/design/adminhtml/default/default/layout/onepica/avatax.xml +0 -0
  67. app/design/adminhtml/default/default/template/onepica/avatax/log/view.phtml +9 -3
  68. app/design/adminhtml/default/default/template/onepica/avatax/notification/toolbar.phtml +3 -1
  69. app/design/frontend/base/default/layout/onepica/avatax.xml +0 -0
  70. app/etc/modules/OnePica_AvaTax.xml +0 -0
  71. app/locale/de_DE/OnePica_AvaTax.csv +0 -0
  72. app/locale/en_US/OnePica_AvaTax.csv +0 -0
  73. app/locale/es_ES/OnePica_AvaTax.csv +0 -0
  74. app/locale/fr_FR/OnePica_AvaTax.csv +0 -0
  75. app/locale/nl_NL/OnePica_AvaTax.csv +0 -0
  76. app/locale/pt_BR/OnePica_AvaTax.csv +0 -0
  77. app/locale/zh_CN/OnePica_AvaTax.csv +0 -0
  78. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/AvaTax.php +95 -95
  79. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/ATConfig.class.php +67 -67
  80. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/ATObject.class.php +52 -52
  81. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/AVObject.class.php +0 -0
  82. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/Address.class.php +226 -226
  83. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/AddressServiceSoap.class.php +153 -153
  84. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/AddressType.class.php +38 -38
  85. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/AdjustTaxRequest.class.php +74 -74
  86. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/AdjustTaxResult.class.php +260 -260
  87. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/ApplyPaymentRequest.class.php +76 -76
  88. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/ApplyPaymentResult.class.php +12 -12
  89. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/AvalaraSoapClient.class.php +32 -32
  90. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BaseResult.class.php +36 -36
  91. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/AuditMessage.class.php +13 -13
  92. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/AvaTaxBatchSvc.php +70 -70
  93. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/BaseResult.class.php +20 -20
  94. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/Batch.class.php +86 -86
  95. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/BatchDelete.class.php +12 -12
  96. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/BatchDeleteResponse.class.php +13 -13
  97. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/BatchFetch.class.php +13 -13
  98. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/BatchFetchResponse.class.php +13 -13
  99. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/BatchFetchResult.class.php +17 -17
  100. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/BatchFile.class.php +52 -52
  101. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/BatchFileDelete.class.php +13 -13
  102. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/BatchFileDeleteResponse.class.php +12 -12
  103. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/BatchFileFetch.class.php +13 -13
  104. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/BatchFileFetchResponse.class.php +13 -13
  105. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/BatchFileFetchResult.class.php +17 -17
  106. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/BatchFileSave.class.php +12 -12
  107. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/BatchFileSaveResponse.class.php +12 -12
  108. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/BatchFileSaveResult.class.php +13 -13
  109. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/BatchProcess.class.php +13 -13
  110. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/BatchProcessRequest.class.php +24 -24
  111. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/BatchProcessResponse.class.php +13 -13
  112. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/BatchProcessResult.class.php +9 -9
  113. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/BatchSave.class.php +13 -13
  114. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/BatchSaveResponse.class.php +13 -13
  115. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/BatchSaveResult.class.php +17 -17
  116. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/BatchSvc.class.php +173 -173
  117. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/DeleteRequest.class.php +24 -24
  118. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/DeleteResult.class.php +8 -8
  119. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/FetchRequest.class.php +45 -45
  120. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/FilterRequest.class.php +22 -22
  121. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/FilterResult.class.php +12 -12
  122. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/IsAuthorized.class.php +13 -13
  123. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/IsAuthorizedResponse.class.php +12 -12
  124. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/IsAuthorizedResult.class.php +17 -17
  125. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/Message.class.php +37 -37
  126. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/Ping.class.php +13 -13
  127. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/PingResponse.class.php +13 -13
  128. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/PingResult.class.php +26 -26
  129. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/Profile.class.php +24 -24
  130. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/SeverityLevel.class.php +12 -12
  131. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BoundaryLevel.class.php +56 -56
  132. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/CancelCode.class.php +71 -71
  133. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/CancelTaxRequest.class.php +54 -54
  134. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/CancelTaxResult.class.php +55 -55
  135. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/CommitTaxRequest.class.php +42 -42
  136. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/CommitTaxResult.class.php +51 -51
  137. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/DetailLevel.class.php +54 -54
  138. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/DocStatus.class.php +84 -84
  139. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/DocumentType.class.php +87 -87
  140. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/DynamicSoapClient.class.php +61 -61
  141. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/Enum.class.php +29 -29
  142. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/GetTaxHistoryRequest.class.php +51 -51
  143. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/GetTaxHistoryResult.class.php +69 -69
  144. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/GetTaxRequest.class.php +528 -528
  145. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/GetTaxResult.class.php +260 -260
  146. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/IsAuthorizedResult.class.php +78 -78
  147. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/JurisdictionType.class.php +72 -72
  148. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/Line.class.php +263 -263
  149. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/Message.class.php +85 -85
  150. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/PingResult.class.php +73 -73
  151. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/PostTaxRequest.class.php +78 -78
  152. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/PostTaxResult.class.php +51 -51
  153. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/ReconcileTaxHistoryRequest.class.php +88 -88
  154. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/ReconcileTaxHistoryResult.class.php +109 -109
  155. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/SearchTaxHistoryResult.class.php +99 -99
  156. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/ServiceMode.class.php +45 -45
  157. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/SeverityLevel.class.php +37 -37
  158. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/TaxDetail.class.php +189 -189
  159. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/TaxLine.class.php +132 -132
  160. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/TaxOverride.class.php +39 -39
  161. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/TaxOverrideType.class.php +13 -13
  162. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/TaxRequest.class.php +160 -160
  163. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/TaxServiceSoap.class.php +306 -306
  164. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/TaxType.class.php +34 -34
  165. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/TextCase.class.php +31 -31
  166. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/ValidAddress.class.php +475 -475
  167. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/ValidateRequest.class.php +190 -190
  168. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/ValidateResult.class.php +86 -86
  169. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/wsdl/Address.wsdl +511 -511
  170. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/wsdl/BatchSvc.wsdl +658 -658
  171. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/wsdl/Tax.wsdl +1279 -1279
  172. {app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/functions.php +74 -74
  173. package.xml +5 -21
app/code/community/OnePica/AvaTax/Block/Adminhtml/Export/Abstract/Grid.php CHANGED
@@ -49,18 +49,22 @@ abstract class OnePica_AvaTax_Block_Adminhtml_Export_Abstract_Grid extends Mage_
49
  {
50
  foreach ($columns as $name => $type) {
51
  if (is_array($type)) {
52
- $this->addColumn($name, array(
53
- 'header' => Mage::helper('avatax')->__(ucwords(str_replace('_', ' ', $name))),
54
- 'index' => $name,
55
- 'type' => 'options',
56
- 'options' => $type
57
- ));
 
 
58
  } else {
59
- $this->addColumn($name, array(
60
- 'header' => Mage::helper('avatax')->__(ucwords(str_replace('_', ' ', $name))),
61
- 'index' => $name,
62
- 'type' => $type
63
- ));
 
 
64
  }
65
  }
66
  return $this;
49
  {
50
  foreach ($columns as $name => $type) {
51
  if (is_array($type)) {
52
+ $this->addColumn(
53
+ $name, array(
54
+ 'header' => Mage::helper('avatax')->__(ucwords(str_replace('_', ' ', $name))),
55
+ 'index' => $name,
56
+ 'type' => 'options',
57
+ 'options' => $type
58
+ )
59
+ );
60
  } else {
61
+ $this->addColumn(
62
+ $name, array(
63
+ 'header' => Mage::helper('avatax')->__(ucwords(str_replace('_', ' ', $name))),
64
+ 'index' => $name,
65
+ 'type' => $type
66
+ )
67
+ );
68
  }
69
  }
70
  return $this;
app/code/community/OnePica/AvaTax/Block/Adminhtml/Export/Log/Grid.php CHANGED
@@ -45,13 +45,15 @@ class OnePica_AvaTax_Block_Adminhtml_Export_Log_Grid extends OnePica_AvaTax_Bloc
45
  */
46
  protected function _prepareColumns()
47
  {
48
- return $this->_addColumns(array(
49
- 'log_id' => 'number',
50
- 'store_id' => 'number',
51
- 'level' => Mage::getModel('avatax_records/log')->getLevelOptions(),
52
- 'type' => Mage::getModel('avatax_records/log')->getTypeOptions(),
53
- 'created_at' => 'datetime',
54
- ));
 
 
55
  }
56
 
57
  /**
45
  */
46
  protected function _prepareColumns()
47
  {
48
+ return $this->_addColumns(
49
+ array(
50
+ 'log_id' => 'number',
51
+ 'store_id' => 'number',
52
+ 'level' => Mage::getModel('avatax_records/log')->getLevelOptions(),
53
+ 'type' => Mage::getModel('avatax_records/log')->getTypeOptions(),
54
+ 'created_at' => 'datetime',
55
+ )
56
+ );
57
  }
58
 
59
  /**
app/code/community/OnePica/AvaTax/Block/Adminhtml/Export/Log/View.php CHANGED
@@ -38,11 +38,13 @@ class OnePica_AvaTax_Block_Adminhtml_Export_Log_View extends Mage_Adminhtml_Bloc
38
  {
39
  parent::__construct();
40
 
41
- $this->_addButton('back', array(
42
- 'label' => Mage::helper('avatax')->__('Back'),
43
- 'onclick' => "setLocation('" . Mage::getSingleton('adminhtml/url')->getUrl('*/*/log'). "')",
44
- 'class' => 'back'
45
- ));
 
 
46
  }
47
 
48
  /**
38
  {
39
  parent::__construct();
40
 
41
+ $this->_addButton(
42
+ 'back', array(
43
+ 'label' => Mage::helper('avatax')->__('Back'),
44
+ 'onclick' => "setLocation('" . Mage::getSingleton('adminhtml/url')->getUrl('*/*/log') . "')",
45
+ 'class' => 'back'
46
+ )
47
+ );
48
  }
49
 
50
  /**
app/code/community/OnePica/AvaTax/Block/Adminhtml/Export/Queue/Grid.php CHANGED
@@ -65,18 +65,20 @@ class OnePica_AvaTax_Block_Adminhtml_Export_Queue_Grid extends OnePica_AvaTax_Bl
65
  */
66
  protected function _prepareColumns()
67
  {
68
- return $this->_addColumns(array(
69
- 'queue_id' => 'number',
70
- 'store_id' => 'number',
71
- 'entity_id' => 'number',
72
- 'entity_increment_id' => 'number',
73
- 'type' => Mage::getModel('avatax/records_queue')->getTypeOptions(),
74
- 'status' => Mage::getModel('avatax/records_queue')->getStatusOptions(),
75
- 'attempt' => 'number',
76
- 'message' => 'default',
77
- 'created_at' => 'datetime',
78
- 'updated_at' => 'datetime'
79
- ));
 
 
80
  }
81
 
82
  /**
65
  */
66
  protected function _prepareColumns()
67
  {
68
+ return $this->_addColumns(
69
+ array(
70
+ 'queue_id' => 'number',
71
+ 'store_id' => 'number',
72
+ 'entity_id' => 'number',
73
+ 'entity_increment_id' => 'number',
74
+ 'type' => Mage::getModel('avatax/records_queue')->getTypeOptions(),
75
+ 'status' => Mage::getModel('avatax/records_queue')->getStatusOptions(),
76
+ 'attempt' => 'number',
77
+ 'message' => 'default',
78
+ 'created_at' => 'datetime',
79
+ 'updated_at' => 'datetime'
80
+ )
81
+ );
82
  }
83
 
84
  /**
app/code/community/OnePica/AvaTax/Block/Adminhtml/Notification/Toolbar.php CHANGED
@@ -33,8 +33,7 @@ class OnePica_AvaTax_Block_Adminhtml_Notification_Toolbar extends Mage_Adminhtml
33
  {
34
  return Mage::getModel('avatax_records/queue')->getCollection()
35
  ->addFieldToFilter('status', OnePica_AvaTax_Model_Records_Queue::QUEUE_STATUS_RETRY)
36
- ->load()
37
- ->count();
38
  }
39
 
40
  /**
33
  {
34
  return Mage::getModel('avatax_records/queue')->getCollection()
35
  ->addFieldToFilter('status', OnePica_AvaTax_Model_Records_Queue::QUEUE_STATUS_RETRY)
36
+ ->getSize();
 
37
  }
38
 
39
  /**
app/code/community/OnePica/AvaTax/Block/Adminhtml/System/Config/Form/Field/Export.php CHANGED
File without changes
app/code/community/OnePica/AvaTax/Block/Adminhtml/Tax/Class/Edit/Form.php CHANGED
@@ -1,9 +1,7 @@
1
  <?php
2
  /**
3
  * OnePica_AvaTax
4
- *
5
  * NOTICE OF LICENSE
6
- *
7
  * This source file is subject to the Open Software License (OSL 3.0), a
8
  * copy of which is available through the world-wide-web at this URL:
9
  * http://opensource.org/licenses/osl-3.0.php
@@ -33,9 +31,9 @@ class OnePica_AvaTax_Block_Adminhtml_Tax_Class_Edit_Form extends Mage_Adminhtml_
33
  {
34
  parent::_prepareForm();
35
  $fieldset = $this->getForm()->getElement('base_fieldset');
36
- $model = Mage::registry('tax_class');
37
- $fieldset->addField('op_avatax_code', 'text',
38
- array(
39
  'name' => 'op_avatax_code',
40
  'label' => Mage::helper('avatax')->__('AvaTax Code'),
41
  'value' => $model->getOpAvataxCode(),
1
  <?php
2
  /**
3
  * OnePica_AvaTax
 
4
  * NOTICE OF LICENSE
 
5
  * This source file is subject to the Open Software License (OSL 3.0), a
6
  * copy of which is available through the world-wide-web at this URL:
7
  * http://opensource.org/licenses/osl-3.0.php
31
  {
32
  parent::_prepareForm();
33
  $fieldset = $this->getForm()->getElement('base_fieldset');
34
+ $model = Mage::registry('tax_class');
35
+ $fieldset->addField(
36
+ 'op_avatax_code', 'text', array(
37
  'name' => 'op_avatax_code',
38
  'label' => Mage::helper('avatax')->__('AvaTax Code'),
39
  'value' => $model->getOpAvataxCode(),
app/code/community/OnePica/AvaTax/Block/Adminhtml/Tax/Class/Grid.php CHANGED
@@ -42,8 +42,8 @@ class OnePica_AvaTax_Block_Adminhtml_Tax_Class_Grid extends Mage_Adminhtml_Block
42
  */
43
  protected function _prepareColumns()
44
  {
45
- $this->addColumn('op_avatax_code',
46
- array(
47
  'header' => Mage::helper('avatax')->__('AvaTax Code'),
48
  'align' => 'left',
49
  'index' => 'op_avatax_code',
42
  */
43
  protected function _prepareColumns()
44
  {
45
+ $this->addColumn(
46
+ 'op_avatax_code', array(
47
  'header' => Mage::helper('avatax')->__('AvaTax Code'),
48
  'align' => 'left',
49
  'index' => 'op_avatax_code',
app/code/community/OnePica/AvaTax/Block/Checkout/Onepage/Shipping/Method/Available.php CHANGED
File without changes
app/code/community/OnePica/AvaTax/{Model/Exception.php → Exception.php} RENAMED
@@ -16,10 +16,8 @@
16
  */
17
 
18
  /**
19
- * The AvaTax Exception class
20
- *
21
- * @category OnePica
22
- * @package OnePica_AvaTax
23
- * @author OnePica Codemaster <codemaster@onepica.com>
24
  */
25
- class OnePica_AvaTax_Model_Exception extends Mage_Core_Exception {}
 
 
16
  */
17
 
18
  /**
19
+ * Class OnePica_AvaTax_Exception
 
 
 
 
20
  */
21
+ class OnePica_AvaTax_Exception extends Mage_Core_Exception
22
+ {
23
+ }
app/code/community/OnePica/AvaTax/Helper/Data.php CHANGED
@@ -58,21 +58,8 @@ class OnePica_AvaTax_Helper_Data extends Mage_Core_Helper_Abstract
58
  */
59
  public function loadClass($className)
60
  {
61
- require_once $this->getLibPath() . DS . 'classes' . DS . $className . '.class.php';
62
- return $this;
63
- }
64
-
65
- /**
66
- * Loads an array of AvaTax classes.
67
- *
68
- * @param array $classes
69
- * @return OnePica_AvaTax_Helper_Data
70
- */
71
- public function loadClasses(array $classes)
72
- {
73
- foreach ($classes as $class) {
74
- $this->loadClass($class);
75
- }
76
  return $this;
77
  }
78
 
@@ -83,7 +70,8 @@ class OnePica_AvaTax_Helper_Data extends Mage_Core_Helper_Abstract
83
  */
84
  public function loadFunctions()
85
  {
86
- require_once $this->getLibPath() . DS . 'functions.php';
 
87
  return $this;
88
  }
89
 
@@ -102,19 +90,9 @@ class OnePica_AvaTax_Helper_Data extends Mage_Core_Helper_Abstract
102
  *
103
  * @return string
104
  */
105
- public function getLibPath ()
106
- {
107
- return Mage::getModuleDir('', 'OnePica_AvaTax') . DS . 'lib';
108
- }
109
-
110
- /**
111
- * Returns the path to the AvaTax SDK WSDL directory.
112
- *
113
- * @return string
114
- */
115
- public function getWsdlPath ()
116
  {
117
- return $this->getLibPath() . DS . 'wsdl';
118
  }
119
 
120
  /**
@@ -368,7 +346,8 @@ class OnePica_AvaTax_Helper_Data extends Mage_Core_Helper_Abstract
368
 
369
  foreach ($storeCollection as $store) {
370
  //@startSkipCommitHooks
371
- $disabled |= Mage::getStoreConfig('tax/avatax/action', $store->getId()) == OnePica_AvaTax_Model_Config::ACTION_DISABLE;
 
372
  //@finishSkipCommitHooks
373
  }
374
 
58
  */
59
  public function loadClass($className)
60
  {
61
+ $classFile = $this->getLibPath() . DS . 'classes' . DS . $className . '.class.php';
62
+ require_once $classFile;
 
 
 
 
 
 
 
 
 
 
 
 
 
63
  return $this;
64
  }
65
 
70
  */
71
  public function loadFunctions()
72
  {
73
+ $functionsFile = $this->getLibPath() . DS . 'functions.php';
74
+ require_once $functionsFile;
75
  return $this;
76
  }
77
 
90
  *
91
  * @return string
92
  */
93
+ public function getLibPath()
 
 
 
 
 
 
 
 
 
 
94
  {
95
+ return Mage::getBaseDir('lib') . DS . 'AvaTax';
96
  }
97
 
98
  /**
346
 
347
  foreach ($storeCollection as $store) {
348
  //@startSkipCommitHooks
349
+ $disabled |= Mage::getStoreConfig('tax/avatax/action', $store->getId())
350
+ == OnePica_AvaTax_Model_Config::ACTION_DISABLE;
351
  //@finishSkipCommitHooks
352
  }
353
 
app/code/community/OnePica/AvaTax/Helper/Tax/Data.php CHANGED
@@ -91,7 +91,8 @@ class OnePica_AvaTax_Helper_Tax_Data extends Mage_Tax_Helper_Data
91
  * @param null|bool|int|Mage_Core_Model_Store $store
92
  * @return bool
93
  */
94
- public function applyTaxOnCustomPrice($store = null) {
 
95
  if (Mage::helper('avatax')->isAvataxEnabled($store)) {
96
  return true;
97
  }
@@ -104,7 +105,8 @@ class OnePica_AvaTax_Helper_Tax_Data extends Mage_Tax_Helper_Data
104
  * @param null|bool|int|Mage_Core_Model_Store $store
105
  * @return bool
106
  */
107
- public function applyTaxOnOriginalPrice($store = null) {
 
108
  if (Mage::helper('avatax')->isAvataxEnabled($store)) {
109
  return false;
110
  }
@@ -117,7 +119,8 @@ class OnePica_AvaTax_Helper_Tax_Data extends Mage_Tax_Helper_Data
117
  * @param null|bool|int|Mage_Core_Model_Store $store
118
  * @return bool
119
  */
120
- public function applyTaxAfterDiscount($store = null) {
 
121
  if (Mage::helper('avatax')->isAvataxEnabled($store)) {
122
  return true;
123
  }
91
  * @param null|bool|int|Mage_Core_Model_Store $store
92
  * @return bool
93
  */
94
+ public function applyTaxOnCustomPrice($store = null)
95
+ {
96
  if (Mage::helper('avatax')->isAvataxEnabled($store)) {
97
  return true;
98
  }
105
  * @param null|bool|int|Mage_Core_Model_Store $store
106
  * @return bool
107
  */
108
+ public function applyTaxOnOriginalPrice($store = null)
109
+ {
110
  if (Mage::helper('avatax')->isAvataxEnabled($store)) {
111
  return false;
112
  }
119
  * @param null|bool|int|Mage_Core_Model_Store $store
120
  * @return bool
121
  */
122
+ public function applyTaxAfterDiscount($store = null)
123
+ {
124
  if (Mage::helper('avatax')->isAvataxEnabled($store)) {
125
  return true;
126
  }
app/code/community/OnePica/AvaTax/Model/Abstract.php CHANGED
@@ -46,7 +46,7 @@ abstract class OnePica_AvaTax_Model_Abstract extends Varien_Object
46
  if ($result->getResultCode() == SeverityLevel::$Success) {
47
  switch (Mage::helper('avatax')->getLogMode($storeId)) {
48
  case OnePica_AvaTax_Model_Source_Logmode::ERRORS:
49
- return;
50
  break;
51
  case OnePica_AvaTax_Model_Source_Logmode::NORMAL:
52
  $additional = null;
@@ -94,11 +94,9 @@ abstract class OnePica_AvaTax_Model_Abstract extends Varien_Object
94
  /**
95
  * Alias to the helper translate method.
96
  *
97
- * @param string $message
98
- * @param string var number of replacement vars
99
  * @return string
100
  */
101
- public function __($message)
102
  {
103
  $args = func_get_args();
104
  return call_user_func_array(array($this->getHelper(), '__'), $args);
46
  if ($result->getResultCode() == SeverityLevel::$Success) {
47
  switch (Mage::helper('avatax')->getLogMode($storeId)) {
48
  case OnePica_AvaTax_Model_Source_Logmode::ERRORS:
49
+ return $this;
50
  break;
51
  case OnePica_AvaTax_Model_Source_Logmode::NORMAL:
52
  $additional = null;
94
  /**
95
  * Alias to the helper translate method.
96
  *
 
 
97
  * @return string
98
  */
99
+ public function __()
100
  {
101
  $args = func_get_args();
102
  return call_user_func_array(array($this->getHelper(), '__'), $args);
app/code/community/OnePica/AvaTax/Model/Admin/Session.php CHANGED
File without changes
app/code/community/OnePica/AvaTax/Model/Adminhtml/Config.php CHANGED
File without changes
app/code/community/OnePica/AvaTax/Model/Adminhtml/Sales/Order/Create.php CHANGED
@@ -36,7 +36,7 @@ class OnePica_AvaTax_Model_Adminhtml_Sales_Order_Create extends Mage_Adminhtml_M
36
  *
37
  * @param array $address
38
  * @return $this
39
- * @throws Mage_Core_Exception
40
  */
41
  public function setShippingAddress($address)
42
  {
@@ -55,7 +55,7 @@ class OnePica_AvaTax_Model_Adminhtml_Sales_Order_Create extends Mage_Adminhtml_M
55
  foreach ($result as $error) {
56
  $this->getSession()->addError($error);
57
  }
58
- throw new Mage_Core_Exception(implode('<br />', $result));
59
  }
60
  } elseif ($this->getShippingAddress()->getAddressNormalized() && !$this->_messageAdded) {
61
  Mage::getSingleton('avatax/session')->addNotice(Mage::helper('avatax')->__('The shipping address has been modified during the validation process. Please confirm the address below is accurate.'));
36
  *
37
  * @param array $address
38
  * @return $this
39
+ * @throws OnePica_AvaTax_Exception
40
  */
41
  public function setShippingAddress($address)
42
  {
55
  foreach ($result as $error) {
56
  $this->getSession()->addError($error);
57
  }
58
+ throw new OnePica_AvaTax_Exception(implode('<br />', $result));
59
  }
60
  } elseif ($this->getShippingAddress()->getAddressNormalized() && !$this->_messageAdded) {
61
  Mage::getSingleton('avatax/session')->addNotice(Mage::helper('avatax')->__('The shipping address has been modified during the validation process. Please confirm the address below is accurate.'));
app/code/community/OnePica/AvaTax/Model/Avatax/Abstract.php CHANGED
@@ -125,13 +125,13 @@ abstract class OnePica_AvaTax_Model_Avatax_Abstract extends OnePica_AvaTax_Model
125
  $storeId = $object->getStoreId();
126
  $this->_setCompanyCode($storeId);
127
  $this->_request->setDetailLevel(DetailLevel::$Document);
128
- $this->_request->setDocDate(date('Y-m-d'));
129
  $this->_request->setExemptionNo('');
130
  $this->_request->setDiscount(0.00); //cannot be used in Magento
131
  $this->_request->setSalespersonCode(Mage::helper('avatax')->getSalesPersonCode($storeId));
132
  $this->_request->setLocationCode(Mage::helper('avatax')->getLocationCode($storeId));
133
  $this->_request->setCountry(Mage::getStoreConfig('shipping/origin/country_id', $storeId));
134
- $this->_request->setCurrencyCode(Mage::app()->getStore()->getBaseCurrencyCode());
135
  $this->_addCustomer($object);
136
  if ($object instanceof Mage_Sales_Model_Order && $object->getIncrementId()) {
137
  $this->_request->setReferenceCode('Magento Order #' . $object->getIncrementId());
@@ -251,7 +251,6 @@ abstract class OnePica_AvaTax_Model_Avatax_Abstract extends OnePica_AvaTax_Model
251
  public function isProductCalculated($item)
252
  {
253
  // check if item has methods as far as shipping, gift wrapping, printed card item comes as Varien_Object
254
- // TODO: Refactor OnePica_AvaTax_Model_Sales_Quote_Address_Total_Tax::collect method
255
  if (method_exists($item, 'isChildrenCalculated') && method_exists($item, 'getParentItem')) {
256
  if ($item->isChildrenCalculated() && !$item->getParentItem()) {
257
  return true;
@@ -304,7 +303,7 @@ abstract class OnePica_AvaTax_Model_Avatax_Abstract extends OnePica_AvaTax_Model
304
  * Init tax class collection for items to be calculated
305
  *
306
  * @return $this
307
- * @throws OnePica_AvaTax_Model_Exception
308
  */
309
  protected function _initTaxClassCollection()
310
  {
@@ -317,6 +316,7 @@ abstract class OnePica_AvaTax_Model_Avatax_Abstract extends OnePica_AvaTax_Model
317
  $this->_taxClassCollection = Mage::getModel('tax/class')->getCollection()
318
  ->addFieldToSelect(array('class_id', 'op_avatax_code'))
319
  ->addFieldToFilter('class_id', array('in' => $taxClassIds));
 
320
  return $this;
321
  }
322
 
@@ -324,12 +324,12 @@ abstract class OnePica_AvaTax_Model_Avatax_Abstract extends OnePica_AvaTax_Model
324
  * Get product collection for items to be calculated
325
  *
326
  * @return Mage_Catalog_Model_Resource_Product_Collection
327
- * @throws OnePica_AvaTax_Model_Exception
328
  */
329
  protected function _getProductCollection()
330
  {
331
  if (!$this->_productCollection) {
332
- throw new OnePica_AvaTax_Model_Exception('Product collection should be set before usage');
333
  }
334
 
335
  return $this->_productCollection;
@@ -339,12 +339,12 @@ abstract class OnePica_AvaTax_Model_Avatax_Abstract extends OnePica_AvaTax_Model
339
  * Get tax class collection for items to be calculated
340
  *
341
  * @return Mage_Tax_Model_Resource_Class_Collection
342
- * @throws OnePica_AvaTax_Model_Exception
343
  */
344
  protected function _getTaxClassCollection()
345
  {
346
  if (!$this->_taxClassCollection) {
347
- throw new OnePica_AvaTax_Model_Exception('Tax class collection should be set before usage');
348
  }
349
 
350
  return $this->_taxClassCollection;
@@ -372,7 +372,7 @@ abstract class OnePica_AvaTax_Model_Avatax_Abstract extends OnePica_AvaTax_Model
372
  *
373
  * @param int $productId
374
  * @return Mage_Catalog_Model_Product
375
- * @throws OnePica_AvaTax_Model_Exception
376
  */
377
  protected function _getProductByProductId($productId)
378
  {
@@ -383,14 +383,15 @@ abstract class OnePica_AvaTax_Model_Avatax_Abstract extends OnePica_AvaTax_Model
383
  * Get proper ref value for given product
384
  *
385
  * @param Mage_Catalog_Model_Product $product
386
- * @param int $refNumber
 
387
  * @return null|string
388
  */
389
- protected function _getRefValueByProductAndNumber($product, $refNumber)
390
  {
391
  $value = null;
392
  $helperMethod = 'getRef' . $refNumber . 'AttributeCode';
393
- $refCode = Mage::helper('avatax')->{$helperMethod}($product->getStoreId());
394
  if ($refCode && $product->getResource()->getAttribute($refCode)) {
395
  try {
396
  $value = (string)$product->getResource()->getAttribute($refCode)->getFrontend()->getValue($product);
@@ -417,4 +418,14 @@ abstract class OnePica_AvaTax_Model_Avatax_Abstract extends OnePica_AvaTax_Model
417
  $taxOverride->setTaxAmount($taxAmount);
418
  return $taxOverride;
419
  }
 
 
 
 
 
 
 
 
 
 
420
  }
125
  $storeId = $object->getStoreId();
126
  $this->_setCompanyCode($storeId);
127
  $this->_request->setDetailLevel(DetailLevel::$Document);
128
+ $this->_request->setDocDate($this->_getDateModel()->date('Y-m-d'));
129
  $this->_request->setExemptionNo('');
130
  $this->_request->setDiscount(0.00); //cannot be used in Magento
131
  $this->_request->setSalespersonCode(Mage::helper('avatax')->getSalesPersonCode($storeId));
132
  $this->_request->setLocationCode(Mage::helper('avatax')->getLocationCode($storeId));
133
  $this->_request->setCountry(Mage::getStoreConfig('shipping/origin/country_id', $storeId));
134
+ $this->_request->setCurrencyCode(Mage::app()->getStore($storeId)->getBaseCurrencyCode());
135
  $this->_addCustomer($object);
136
  if ($object instanceof Mage_Sales_Model_Order && $object->getIncrementId()) {
137
  $this->_request->setReferenceCode('Magento Order #' . $object->getIncrementId());
251
  public function isProductCalculated($item)
252
  {
253
  // check if item has methods as far as shipping, gift wrapping, printed card item comes as Varien_Object
 
254
  if (method_exists($item, 'isChildrenCalculated') && method_exists($item, 'getParentItem')) {
255
  if ($item->isChildrenCalculated() && !$item->getParentItem()) {
256
  return true;
303
  * Init tax class collection for items to be calculated
304
  *
305
  * @return $this
306
+ * @throws OnePica_AvaTax_Exception
307
  */
308
  protected function _initTaxClassCollection()
309
  {
316
  $this->_taxClassCollection = Mage::getModel('tax/class')->getCollection()
317
  ->addFieldToSelect(array('class_id', 'op_avatax_code'))
318
  ->addFieldToFilter('class_id', array('in' => $taxClassIds));
319
+
320
  return $this;
321
  }
322
 
324
  * Get product collection for items to be calculated
325
  *
326
  * @return Mage_Catalog_Model_Resource_Product_Collection
327
+ * @throws OnePica_AvaTax_Exception
328
  */
329
  protected function _getProductCollection()
330
  {
331
  if (!$this->_productCollection) {
332
+ throw new OnePica_AvaTax_Exception('Product collection should be set before usage');
333
  }
334
 
335
  return $this->_productCollection;
339
  * Get tax class collection for items to be calculated
340
  *
341
  * @return Mage_Tax_Model_Resource_Class_Collection
342
+ * @throws OnePica_AvaTax_Exception
343
  */
344
  protected function _getTaxClassCollection()
345
  {
346
  if (!$this->_taxClassCollection) {
347
+ throw new OnePica_AvaTax_Exception('Tax class collection should be set before usage');
348
  }
349
 
350
  return $this->_taxClassCollection;
372
  *
373
  * @param int $productId
374
  * @return Mage_Catalog_Model_Product
375
+ * @throws OnePica_AvaTax_Exception
376
  */
377
  protected function _getProductByProductId($productId)
378
  {
383
  * Get proper ref value for given product
384
  *
385
  * @param Mage_Catalog_Model_Product $product
386
+ * @param int $refNumber
387
+ * @param int $storeId
388
  * @return null|string
389
  */
390
+ protected function _getRefValueByProductAndNumber($product, $refNumber, $storeId)
391
  {
392
  $value = null;
393
  $helperMethod = 'getRef' . $refNumber . 'AttributeCode';
394
+ $refCode = Mage::helper('avatax')->{$helperMethod}($storeId);
395
  if ($refCode && $product->getResource()->getAttribute($refCode)) {
396
  try {
397
  $value = (string)$product->getResource()->getAttribute($refCode)->getFrontend()->getValue($product);
418
  $taxOverride->setTaxAmount($taxAmount);
419
  return $taxOverride;
420
  }
421
+
422
+ /**
423
+ * Get date model
424
+ *
425
+ * @return Mage_Core_Model_Date
426
+ */
427
+ protected function _getDateModel()
428
+ {
429
+ return Mage::getSingleton('core/date');
430
+ }
431
  }
app/code/community/OnePica/AvaTax/Model/Avatax/Address.php CHANGED
@@ -156,13 +156,12 @@ class OnePica_AvaTax_Model_Avatax_Address extends OnePica_AvaTax_Model_Abstract
156
  );
157
  }
158
 
159
- /** @var OnePica_AvaTax_Model_Config $config */
160
- $config = Mage::getSingleton('avatax/config')->init($this->_storeId);
161
  /** @var Mage_Sales_Model_Quote $quote */
162
  $quote = $this->_mageAddress->getQuote();
163
  $isAddressValidationOn = $this->_getDataHelper()->isAddressValidationOn($this->_mageAddress, $this->_storeId);
164
- $isAddressNormalizationOn = $this->_getDataHelper()
165
- ->isAddressNormalizationOn($this->_mageAddress, $this->_storeId);
 
166
  $isAddressActionable = $this->_getDataHelper()->isAddressActionable($this->_mageAddress, $quote->getStoreId());
167
  //if there is no use cases for AvaTax services, return address as valid without doing a lookup
168
  if (!$isAddressValidationOn && !$isAddressNormalizationOn && !$isAddressActionable) {
@@ -171,45 +170,15 @@ class OnePica_AvaTax_Model_Avatax_Address extends OnePica_AvaTax_Model_Abstract
171
 
172
  //lookup in AvaTax (with caching)
173
  $key = $this->_mageAddress->getCacheHashKey();
 
174
  if (array_key_exists($key, $this->_cache)) {
175
  $result = unserialize($this->_cache[$key]);
176
  } elseif ($this->_mageAddress->getPostcode() && $this->_mageAddress->getPostcode() != '-') {
177
- $session = Mage::getSingleton('checkout/session');
178
- if ($session->getPostType() == 'onepage') {
179
- $requiredFields = explode(",", $this->getHelper()->getFieldRequiredList());
180
- $fieldRules = explode(",", $this->getHelper()->getFieldRule());
181
- foreach ($requiredFields as $field) {
182
- $requiredFlag = 0;
183
- foreach ($fieldRules as $rule) {
184
- if (preg_match("/street\d/", $field)) {
185
- $field = "street";
186
- }
187
- if ($field == "country") {
188
- $field = "country_id";
189
- }
190
- if ($this->_mageAddress->getData($field) == $rule || !$this->_mageAddress->getData($field)) {
191
- $requiredFlag = 1;
192
- }
193
- }
194
- if ($requiredFlag) {
195
- $errors = array();
196
- $errors[] = $this->__('Invalid ') . $this->__($field);
197
- return $errors;
198
- }
199
- }
200
  }
201
-
202
- $client = $config->getAddressConnection();
203
- $request = new ValidateRequest($this->_requestAddress, TextCase::$Mixed, 0);
204
- $request->setTaxability(true);
205
- $result = $client->Validate($request);
206
- $this->_log(
207
- OnePica_AvaTax_Model_Source_Logtype::VALIDATE,
208
- $request,
209
- $result,
210
- $this->_storeId,
211
- $config->getParams()
212
- );
213
  $this->_cache[$key] = serialize($result);
214
  } else {
215
  $errors = array();
@@ -217,20 +186,27 @@ class OnePica_AvaTax_Model_Avatax_Address extends OnePica_AvaTax_Model_Abstract
217
  return $errors;
218
  }
219
 
220
- //normalization
221
- if ($isAddressNormalizationOn && $result->getResultCode() == SeverityLevel::$Success) {
222
- $responseAddress = $result->getValidAddresses();
223
- $responseAddress = array_pop($responseAddress);
224
- if ($responseAddress instanceof ValidAddress) {
225
- $this->_responseAddress = $responseAddress;
226
- $this->_convertResponseAddress();
227
- } else {
228
- throw new OnePica_AvaTax_Model_Avatax_Address_Exception($this->__('Invalid response address type.'));
229
- }
230
  }
231
 
232
- //validation
233
- if ($isAddressValidationOn == 1) {
 
 
 
 
 
 
 
 
 
 
 
 
234
  if ($result->getResultCode() == SeverityLevel::$Success) {
235
  $this->_mageAddress->setAddressValidated(true);
236
  return true;
@@ -241,7 +217,7 @@ class OnePica_AvaTax_Model_Avatax_Address extends OnePica_AvaTax_Model_Abstract
241
  }
242
  return $errors;
243
  }
244
- } elseif ($isAddressValidationOn == 2) {
245
  $this->_mageAddress->setAddressValidated(true);
246
  if ($result->getResultCode() == SeverityLevel::$Success) {
247
  return true;
@@ -269,7 +245,44 @@ class OnePica_AvaTax_Model_Avatax_Address extends OnePica_AvaTax_Model_Abstract
269
  return $errors;
270
  }
271
  }
272
- return true;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
273
  }
274
 
275
  /**
@@ -281,4 +294,52 @@ class OnePica_AvaTax_Model_Avatax_Address extends OnePica_AvaTax_Model_Abstract
281
  {
282
  return Mage::helper('avatax');
283
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
284
  }
156
  );
157
  }
158
 
 
 
159
  /** @var Mage_Sales_Model_Quote $quote */
160
  $quote = $this->_mageAddress->getQuote();
161
  $isAddressValidationOn = $this->_getDataHelper()->isAddressValidationOn($this->_mageAddress, $this->_storeId);
162
+ $isAddressNormalizationOn = $this->_getDataHelper()->isAddressNormalizationOn(
163
+ $this->_mageAddress, $this->_storeId
164
+ );
165
  $isAddressActionable = $this->_getDataHelper()->isAddressActionable($this->_mageAddress, $quote->getStoreId());
166
  //if there is no use cases for AvaTax services, return address as valid without doing a lookup
167
  if (!$isAddressValidationOn && !$isAddressNormalizationOn && !$isAddressActionable) {
170
 
171
  //lookup in AvaTax (with caching)
172
  $key = $this->_mageAddress->getCacheHashKey();
173
+
174
  if (array_key_exists($key, $this->_cache)) {
175
  $result = unserialize($this->_cache[$key]);
176
  } elseif ($this->_mageAddress->getPostcode() && $this->_mageAddress->getPostcode() != '-') {
177
+ $checkFieldsResult = $this->_checkFields();
178
+ if ($checkFieldsResult) {
179
+ return $checkFieldsResult;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
180
  }
181
+ $result = $this->_sendAddressValidationRequest();
 
 
 
 
 
 
 
 
 
 
 
182
  $this->_cache[$key] = serialize($result);
183
  } else {
184
  $errors = array();
186
  return $errors;
187
  }
188
 
189
+ $this->_addressNormalization($isAddressNormalizationOn, $result);
190
+
191
+ $addressValidationResult = $this->_addressValidation($isAddressValidationOn, $isAddressActionable, $result);
192
+ if ($addressValidationResult) {
193
+ return $addressValidationResult;
 
 
 
 
 
194
  }
195
 
196
+ return true;
197
+ }
198
+
199
+ /**
200
+ * Address validation
201
+ *
202
+ * @param int $isAddressValidationOn
203
+ * @param int $isAddressActionable
204
+ * @param ValidateResult $result
205
+ * @return array|bool|null
206
+ */
207
+ protected function _addressValidation($isAddressValidationOn, $isAddressActionable, $result)
208
+ {
209
+ if ($isAddressValidationOn == OnePica_AvaTax_Model_Source_Addressvalidation::ENABLED_PREVENT_ORDER) {
210
  if ($result->getResultCode() == SeverityLevel::$Success) {
211
  $this->_mageAddress->setAddressValidated(true);
212
  return true;
217
  }
218
  return $errors;
219
  }
220
+ } elseif ($isAddressValidationOn == OnePica_AvaTax_Model_Source_Addressvalidation::ENABLED_ALLOW_ORDER) {
221
  $this->_mageAddress->setAddressValidated(true);
222
  if ($result->getResultCode() == SeverityLevel::$Success) {
223
  return true;
245
  return $errors;
246
  }
247
  }
248
+
249
+ return null;
250
+ }
251
+
252
+ /**
253
+ * Check fields
254
+ *
255
+ * @return array|null
256
+ */
257
+ protected function _checkFields()
258
+ {
259
+ /** @var Mage_Checkout_Model_Session $session */
260
+ $session = Mage::getSingleton('checkout/session');
261
+ if ($session->getPostType() == 'onepage') {
262
+ $requiredFields = explode(",", $this->getHelper()->getFieldRequiredList());
263
+ $fieldRules = explode(",", $this->getHelper()->getFieldRule());
264
+ foreach ($requiredFields as $field) {
265
+ $requiredFlag = 0;
266
+ foreach ($fieldRules as $rule) {
267
+ if (preg_match("/street\d/", $field)) {
268
+ $field = "street";
269
+ }
270
+ if ($field == "country") {
271
+ $field = "country_id";
272
+ }
273
+ if ($this->_mageAddress->getData($field) == $rule || !$this->_mageAddress->getData($field)) {
274
+ $requiredFlag = 1;
275
+ }
276
+ }
277
+ if ($requiredFlag) {
278
+ $errors = array();
279
+ $errors[] = $this->__('Invalid ') . $this->__($field);
280
+ return $errors;
281
+ }
282
+ }
283
+ }
284
+
285
+ return null;
286
  }
287
 
288
  /**
294
  {
295
  return Mage::helper('avatax');
296
  }
297
+
298
+ /**
299
+ * Validate address
300
+ *
301
+ * @return ValidateResult
302
+ */
303
+ protected function _sendAddressValidationRequest()
304
+ {
305
+ /** @var OnePica_AvaTax_Model_Config $config */
306
+ $config = Mage::getSingleton('avatax/config')->init($this->_storeId);
307
+ $client = $config->getAddressConnection();
308
+ $request = new ValidateRequest($this->_requestAddress, TextCase::$Mixed, 0);
309
+ $request->setTaxability(true);
310
+ $result = $client->Validate($request);
311
+ $this->_log(
312
+ OnePica_AvaTax_Model_Source_Logtype::VALIDATE,
313
+ $request,
314
+ $result,
315
+ $this->_storeId,
316
+ $config->getParams()
317
+ );
318
+
319
+ return $result;
320
+ }
321
+
322
+ /**
323
+ * Address normalization
324
+ *
325
+ * @param $isAddressNormalizationOn
326
+ * @param ValidateResult $result
327
+ * @return $this
328
+ * @throws \OnePica_AvaTax_Model_Avatax_Address_Exception
329
+ */
330
+ protected function _addressNormalization($isAddressNormalizationOn, $result)
331
+ {
332
+ if ($isAddressNormalizationOn && $result->getResultCode() == SeverityLevel::$Success) {
333
+ $responseAddress = $result->getValidAddresses();
334
+ $responseAddress = array_pop($responseAddress);
335
+ if ($responseAddress instanceof ValidAddress) {
336
+ $this->_responseAddress = $responseAddress;
337
+ $this->_convertResponseAddress();
338
+ } else {
339
+ throw new OnePica_AvaTax_Model_Avatax_Address_Exception($this->__('Invalid response address type.'));
340
+ }
341
+ }
342
+
343
+ return $this;
344
+ }
345
  }
app/code/community/OnePica/AvaTax/Model/Avatax/Estimate.php CHANGED
@@ -73,7 +73,7 @@ class OnePica_AvaTax_Model_Avatax_Estimate extends OnePica_AvaTax_Model_Avatax_A
73
  $rates = Mage::getSingleton('avatax/session')->getRates();
74
  if (is_array($rates)) {
75
  foreach ($rates as $key => $rate) {
76
- if ($rate['timestamp'] < strtotime('-' . self::CACHE_TTL . ' minutes')) {
77
  unset($rates[$key]);
78
  }
79
  }
@@ -176,7 +176,6 @@ class OnePica_AvaTax_Model_Avatax_Estimate extends OnePica_AvaTax_Model_Avatax_A
176
  $this->_setOriginAddress($address->getStoreId());
177
  $this->_setDestinationAddress($address);
178
  $this->_request->setDetailLevel(DetailLevel::$Line);
179
- $this->_addCustomer($address);
180
  $this->_addItemsInCart($item);
181
  $this->_addShipping($address);
182
  //Added code for calculating tax for giftwrap items
@@ -200,7 +199,7 @@ class OnePica_AvaTax_Model_Avatax_Estimate extends OnePica_AvaTax_Model_Avatax_A
200
  //success
201
  if ($result->getResultCode() == SeverityLevel::$Success) {
202
  $this->_rates[$requestKey] = array(
203
- 'timestamp' => time(),
204
  'address_id' => $address->getId(),
205
  'summary' => array(),
206
  'items' => array()
@@ -224,7 +223,7 @@ class OnePica_AvaTax_Model_Avatax_Estimate extends OnePica_AvaTax_Model_Avatax_A
224
  //failure
225
  } else {
226
  $this->_rates[$requestKey] = array(
227
- 'timestamp' => time(),
228
  'address_id' => $address->getId(),
229
  'summary' => array(),
230
  'items' => array(),
@@ -409,7 +408,7 @@ class OnePica_AvaTax_Model_Avatax_Estimate extends OnePica_AvaTax_Model_Avatax_A
409
  /**
410
  * Makes a Line object from a product item object
411
  *
412
- * @param Varien_Object $item
413
  * @return int|bool
414
  */
415
  protected function _newLine($item)
@@ -423,19 +422,19 @@ class OnePica_AvaTax_Model_Avatax_Estimate extends OnePica_AvaTax_Model_Avatax_A
423
  $lineNumber = count($this->_lines);
424
  $line = new Line();
425
  $line->setNo($lineNumber);
426
- $line->setItemCode(substr($product->getSku(), 0, 50));
427
- $line->setDescription($product->getName());
428
  $line->setQty($item->getQty());
429
  $line->setAmount($price);
430
  $line->setDiscounted($item->getDiscountAmount() ? true : false);
431
  if ($taxClass) {
432
  $line->setTaxCode($taxClass);
433
  }
434
- $ref1Value = $this->_getRefValueByProductAndNumber($product, 1);
435
  if ($ref1Value) {
436
  $line->setRef1($ref1Value);
437
  }
438
- $ref2Value = $this->_getRefValueByProductAndNumber($product, 2);
439
  if ($ref2Value) {
440
  $line->setRef2($ref2Value);
441
  }
73
  $rates = Mage::getSingleton('avatax/session')->getRates();
74
  if (is_array($rates)) {
75
  foreach ($rates as $key => $rate) {
76
+ if ($rate['timestamp'] < $this->_getDateModel()->timestamp('-' . self::CACHE_TTL . ' minutes')) {
77
  unset($rates[$key]);
78
  }
79
  }
176
  $this->_setOriginAddress($address->getStoreId());
177
  $this->_setDestinationAddress($address);
178
  $this->_request->setDetailLevel(DetailLevel::$Line);
 
179
  $this->_addItemsInCart($item);
180
  $this->_addShipping($address);
181
  //Added code for calculating tax for giftwrap items
199
  //success
200
  if ($result->getResultCode() == SeverityLevel::$Success) {
201
  $this->_rates[$requestKey] = array(
202
+ 'timestamp' => $this->_getDateModel()->timestamp(),
203
  'address_id' => $address->getId(),
204
  'summary' => array(),
205
  'items' => array()
223
  //failure
224
  } else {
225
  $this->_rates[$requestKey] = array(
226
+ 'timestamp' => $this->_getDateModel()->timestamp(),
227
  'address_id' => $address->getId(),
228
  'summary' => array(),
229
  'items' => array(),
408
  /**
409
  * Makes a Line object from a product item object
410
  *
411
+ * @param Varien_Object|Mage_Sales_Model_Quote_Item $item
412
  * @return int|bool
413
  */
414
  protected function _newLine($item)
422
  $lineNumber = count($this->_lines);
423
  $line = new Line();
424
  $line->setNo($lineNumber);
425
+ $line->setItemCode(substr($item->getSku(), 0, 50));
426
+ $line->setDescription($item->getName());
427
  $line->setQty($item->getQty());
428
  $line->setAmount($price);
429
  $line->setDiscounted($item->getDiscountAmount() ? true : false);
430
  if ($taxClass) {
431
  $line->setTaxCode($taxClass);
432
  }
433
+ $ref1Value = $this->_getRefValueByProductAndNumber($product, 1, $item->getStoreId());
434
  if ($ref1Value) {
435
  $line->setRef1($ref1Value);
436
  }
437
+ $ref2Value = $this->_getRefValueByProductAndNumber($product, 2, $item->getStoreId());
438
  if ($ref2Value) {
439
  $line->setRef2($ref2Value);
440
  }
app/code/community/OnePica/AvaTax/Model/Avatax/Exception/Address.php CHANGED
@@ -22,4 +22,6 @@
22
  * @package OnePica_AvaTax
23
  * @author OnePica Codemaster <codemaster@onepica.com>
24
  */
25
- class OnePica_AvaTax_Model_Avatax_Address_Exception extends Exception {}
 
 
22
  * @package OnePica_AvaTax
23
  * @author OnePica Codemaster <codemaster@onepica.com>
24
  */
25
+ class OnePica_AvaTax_Model_Avatax_Address_Exception extends Exception
26
+ {
27
+ }
app/code/community/OnePica/AvaTax/Model/Avatax/Exception/Commitfailure.php CHANGED
@@ -22,4 +22,6 @@
22
  * @package OnePica_AvaTax
23
  * @author OnePica Codemaster <codemaster@onepica.com>
24
  */
25
- class OnePica_AvaTax_Model_Avatax_Exception_Commitfailure extends Exception {}
 
 
22
  * @package OnePica_AvaTax
23
  * @author OnePica Codemaster <codemaster@onepica.com>
24
  */
25
+ class OnePica_AvaTax_Model_Avatax_Exception_Commitfailure extends Exception
26
+ {
27
+ }
app/code/community/OnePica/AvaTax/Model/Avatax/Exception/Unbalanced.php CHANGED
@@ -22,4 +22,6 @@
22
  * @package OnePica_AvaTax
23
  * @author OnePica Codemaster <codemaster@onepica.com>
24
  */
25
- class OnePica_AvaTax_Model_Avatax_Exception_Unbalanced extends Exception {}
 
 
22
  * @package OnePica_AvaTax
23
  * @author OnePica Codemaster <codemaster@onepica.com>
24
  */
25
+ class OnePica_AvaTax_Model_Avatax_Exception_Unbalanced extends Exception
26
+ {
27
+ }
app/code/community/OnePica/AvaTax/Model/Avatax/Invoice.php CHANGED
@@ -45,20 +45,20 @@ class OnePica_AvaTax_Model_Avatax_Invoice extends OnePica_AvaTax_Model_Avatax_Ab
45
  * @param Mage_Sales_Model_Order_Invoice $invoice
46
  * @param OnePica_AvaTax_Model_Records_Queue $queue
47
  * @return bool
48
- * @throws Exception
49
  * @throws OnePica_AvaTax_Model_Avatax_Exception_Commitfailure
50
  * @throws OnePica_AvaTax_Model_Avatax_Exception_Unbalanced
51
  */
52
  public function invoice($invoice, $queue)
53
  {
54
  $order = $invoice->getOrder();
55
- $invoiceDate = $order->getInvoiceCollection()->getFirstItem()->getCreatedAt();
56
  $orderDate = $order->getCreatedAt();
57
  $statusDate = $queue->getUpdatedAt();
58
 
59
  $shippingAddress = ($order->getShippingAddress()) ? $order->getShippingAddress() : $order->getBillingAddress();
60
  if (!$shippingAddress) {
61
- throw new Exception($this->__('There is no address attached to this order'));
62
  }
63
 
64
  $this->_request = new GetTaxRequest();
@@ -74,7 +74,7 @@ class OnePica_AvaTax_Model_Avatax_Invoice extends OnePica_AvaTax_Model_Avatax_Ab
74
 
75
  $this->_setOriginAddress($order->getStoreId());
76
  $this->_setDestinationAddress($shippingAddress);
77
- //$this->_request->setPaymentDate(date('Y-m-d'));
78
  $this->_request->setDocDate(substr($invoiceDate, 0, 10));
79
  $this->_request->setPaymentDate(substr($invoiceDate, 0, 10));
80
  $this->_request->setTaxDate(substr($orderDate, 0, 10));
@@ -126,7 +126,7 @@ class OnePica_AvaTax_Model_Avatax_Invoice extends OnePica_AvaTax_Model_Avatax_Ab
126
  * @param Mage_Sales_Model_Order_Creditmemo $creditmemo
127
  * @param OnePica_AvaTax_Model_Records_Queue $queue
128
  * @return mixed
129
- * @throws Exception
130
  * @throws OnePica_AvaTax_Model_Avatax_Exception_Commitfailure
131
  * @throws OnePica_AvaTax_Model_Avatax_Exception_Unbalanced
132
  */
@@ -135,11 +135,11 @@ class OnePica_AvaTax_Model_Avatax_Invoice extends OnePica_AvaTax_Model_Avatax_Ab
135
  $order = $creditmemo->getOrder();
136
  $orderDate = $order->getCreatedAt();
137
  $statusDate = $queue->getUpdatedAt();
138
- $creditmemoDate = $order->getCreditmemosCollection()->getFirstItem()->getCreatedAt();
139
 
140
  $shippingAddress = ($order->getShippingAddress()) ? $order->getShippingAddress() : $order->getBillingAddress();
141
  if (!$shippingAddress) {
142
- throw new Exception($this->__('There is no address attached to this order'));
143
  }
144
 
145
  $this->_request = new GetTaxRequest();
@@ -158,9 +158,7 @@ class OnePica_AvaTax_Model_Avatax_Invoice extends OnePica_AvaTax_Model_Avatax_Ab
158
  $this->_setDestinationAddress($shippingAddress);
159
 
160
  // Set the tax date for calculation.
161
- //$invoiceDate = $order->getInvoiceCollection()->getFirstItem()->getCreatedAt();
162
  $override = new TaxOverride();
163
- //$override->setTaxDate(substr($invoiceDate, 0, 10));
164
  $override->setTaxDate(substr($orderDate, 0, 10));
165
  $override->setTaxOverrideType(TaxOverrideType::$TaxDate);
166
  $override->setReason('Credit memo - refund');
@@ -255,7 +253,8 @@ class OnePica_AvaTax_Model_Avatax_Invoice extends OnePica_AvaTax_Model_Avatax_Ab
255
  * @param bool $credit
256
  * @return int|bool
257
  */
258
- protected function _addGwOrderAmount($object, $credit = false) {
 
259
  if ($object->getGwPrice() == 0) {
260
  return false;
261
  }
@@ -425,6 +424,7 @@ class OnePica_AvaTax_Model_Avatax_Invoice extends OnePica_AvaTax_Model_Avatax_Ab
425
  return false;
426
  }
427
 
 
428
  $product = $this->_getProductByProductId($item->getProductId());
429
  $taxClass = $this->_getTaxClassByProduct($product);
430
  $price = $item->getBaseRowTotal() - $item->getBaseDiscountAmount();
@@ -444,11 +444,11 @@ class OnePica_AvaTax_Model_Avatax_Invoice extends OnePica_AvaTax_Model_Avatax_Ab
444
  if ($taxClass) {
445
  $line->setTaxCode($taxClass);
446
  }
447
- $ref1Value = $this->_getRefValueByProductAndNumber($product, 1);
448
  if ($ref1Value) {
449
  $line->setRef1($ref1Value);
450
  }
451
- $ref2Value = $this->_getRefValueByProductAndNumber($product, 2);
452
  if ($ref2Value) {
453
  $line->setRef2($ref2Value);
454
  }
@@ -456,4 +456,22 @@ class OnePica_AvaTax_Model_Avatax_Invoice extends OnePica_AvaTax_Model_Avatax_Ab
456
  $this->_lineToItemId[count($this->_lines)] = $item->getOrderItemId();
457
  $this->_lines[] = $line;
458
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
459
  }
45
  * @param Mage_Sales_Model_Order_Invoice $invoice
46
  * @param OnePica_AvaTax_Model_Records_Queue $queue
47
  * @return bool
48
+ * @throws OnePica_AvaTax_Exception
49
  * @throws OnePica_AvaTax_Model_Avatax_Exception_Commitfailure
50
  * @throws OnePica_AvaTax_Model_Avatax_Exception_Unbalanced
51
  */
52
  public function invoice($invoice, $queue)
53
  {
54
  $order = $invoice->getOrder();
55
+ $invoiceDate = $invoice->getCreatedAt();
56
  $orderDate = $order->getCreatedAt();
57
  $statusDate = $queue->getUpdatedAt();
58
 
59
  $shippingAddress = ($order->getShippingAddress()) ? $order->getShippingAddress() : $order->getBillingAddress();
60
  if (!$shippingAddress) {
61
+ throw new OnePica_AvaTax_Exception($this->__('There is no address attached to this order'));
62
  }
63
 
64
  $this->_request = new GetTaxRequest();
74
 
75
  $this->_setOriginAddress($order->getStoreId());
76
  $this->_setDestinationAddress($shippingAddress);
77
+
78
  $this->_request->setDocDate(substr($invoiceDate, 0, 10));
79
  $this->_request->setPaymentDate(substr($invoiceDate, 0, 10));
80
  $this->_request->setTaxDate(substr($orderDate, 0, 10));
126
  * @param Mage_Sales_Model_Order_Creditmemo $creditmemo
127
  * @param OnePica_AvaTax_Model_Records_Queue $queue
128
  * @return mixed
129
+ * @throws OnePica_AvaTax_Exception
130
  * @throws OnePica_AvaTax_Model_Avatax_Exception_Commitfailure
131
  * @throws OnePica_AvaTax_Model_Avatax_Exception_Unbalanced
132
  */
135
  $order = $creditmemo->getOrder();
136
  $orderDate = $order->getCreatedAt();
137
  $statusDate = $queue->getUpdatedAt();
138
+ $creditmemoDate = $creditmemo->getCreatedAt();
139
 
140
  $shippingAddress = ($order->getShippingAddress()) ? $order->getShippingAddress() : $order->getBillingAddress();
141
  if (!$shippingAddress) {
142
+ throw new OnePica_AvaTax_Exception($this->__('There is no address attached to this order'));
143
  }
144
 
145
  $this->_request = new GetTaxRequest();
158
  $this->_setDestinationAddress($shippingAddress);
159
 
160
  // Set the tax date for calculation.
 
161
  $override = new TaxOverride();
 
162
  $override->setTaxDate(substr($orderDate, 0, 10));
163
  $override->setTaxOverrideType(TaxOverrideType::$TaxDate);
164
  $override->setReason('Credit memo - refund');
253
  * @param bool $credit
254
  * @return int|bool
255
  */
256
+ protected function _addGwOrderAmount($object, $credit = false)
257
+ {
258
  if ($object->getGwPrice() == 0) {
259
  return false;
260
  }
424
  return false;
425
  }
426
 
427
+ $storeId = $this->_retrieveStoreIdFromItem($item);
428
  $product = $this->_getProductByProductId($item->getProductId());
429
  $taxClass = $this->_getTaxClassByProduct($product);
430
  $price = $item->getBaseRowTotal() - $item->getBaseDiscountAmount();
444
  if ($taxClass) {
445
  $line->setTaxCode($taxClass);
446
  }
447
+ $ref1Value = $this->_getRefValueByProductAndNumber($product, 1, $storeId);
448
  if ($ref1Value) {
449
  $line->setRef1($ref1Value);
450
  }
451
+ $ref2Value = $this->_getRefValueByProductAndNumber($product, 2, $storeId);
452
  if ($ref2Value) {
453
  $line->setRef2($ref2Value);
454
  }
456
  $this->_lineToItemId[count($this->_lines)] = $item->getOrderItemId();
457
  $this->_lines[] = $line;
458
  }
459
+
460
+ /**
461
+ * Retrieve store id from item
462
+ *
463
+ * @param Mage_Sales_Model_Order_Invoice_Item|Mage_Sales_Model_Order_Creditmemo_Item $item
464
+ * @return int
465
+ */
466
+ protected function _retrieveStoreIdFromItem($item)
467
+ {
468
+ $storeId = null;
469
+ if ($item instanceof Mage_Sales_Model_Order_Invoice_Item) {
470
+ $storeId = $item->getInvoice()->getStoreId();
471
+ } else {
472
+ $storeId = $item->getCreditmemo()->getStoreId();
473
+ }
474
+
475
+ return $storeId;
476
+ }
477
  }
app/code/community/OnePica/AvaTax/Model/Avatax/Ping.php CHANGED
File without changes
app/code/community/OnePica/AvaTax/Model/Config.php CHANGED
@@ -15,8 +15,6 @@
15
  * @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
16
  */
17
 
18
- require_once(Mage::getModuleDir('', 'OnePica_AvaTax') . DS . 'lib' . DS.'functions.php');
19
-
20
  /**
21
  * The AvaTax Config Model, which registers config settings with the AvaTax SDK
22
  *
@@ -106,15 +104,19 @@ class OnePica_AvaTax_Model_Config extends Varien_Object
106
  public function init($storeId)
107
  {
108
  if (!$this->_config) {
109
- $this->_config = new ATConfig(self::CONFIG_KEY, array(
110
- 'url' => $this->getConfig('url', $storeId),
111
- 'account' => $this->getConfig('account', $storeId),
112
- 'license' => $this->getConfig('license', $storeId),
113
- 'trace' => (Mage::helper('avatax')
114
- ->getLogMode($storeId) == OnePica_AvaTax_Model_Source_Logmode::DEBUG) ? true : false,
115
- 'client' => $this->getClientName()
116
- ));
 
 
 
117
  }
 
118
  return $this;
119
  }
120
 
@@ -176,17 +178,6 @@ class OnePica_AvaTax_Model_Config extends Varien_Object
176
  return $this->_taxConnection;
177
  }
178
 
179
- /**
180
- * Returns a parameter from the AvaTax ATConfig object.
181
- *
182
- * @param string $param
183
- * @return string
184
- */
185
- public function getParam($param)
186
- {
187
- return $this->_config->$param;
188
- }
189
-
190
  /**
191
  * Returns the AvaTax ATConfig object
192
  *
15
  * @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
16
  */
17
 
 
 
18
  /**
19
  * The AvaTax Config Model, which registers config settings with the AvaTax SDK
20
  *
104
  public function init($storeId)
105
  {
106
  if (!$this->_config) {
107
+ $this->_config = new ATConfig(
108
+ self::CONFIG_KEY,
109
+ array(
110
+ 'url' => $this->getConfig('url', $storeId),
111
+ 'account' => $this->getConfig('account', $storeId),
112
+ 'license' => $this->getConfig('license', $storeId),
113
+ 'trace' => (Mage::helper('avatax')
114
+ ->getLogMode($storeId) == OnePica_AvaTax_Model_Source_Logmode::DEBUG) ? true : false,
115
+ 'client' => $this->getClientName()
116
+ )
117
+ );
118
  }
119
+
120
  return $this;
121
  }
122
 
178
  return $this->_taxConnection;
179
  }
180
 
 
 
 
 
 
 
 
 
 
 
 
181
  /**
182
  * Returns the AvaTax ATConfig object
183
  *
app/code/community/OnePica/AvaTax/Model/Export.php CHANGED
@@ -86,16 +86,16 @@ class OnePica_AvaTax_Model_Export
86
  * Get export content
87
  *
88
  * @return string
89
- * @throws OnePica_AvaTax_Model_Exception
90
  */
91
  public function getContent()
92
  {
93
  if (!$this->getEntity()) {
94
- throw new OnePica_AvaTax_Model_Exception('Entity should be set before export process');
95
  }
96
 
97
  if (!$this->getAdapter()) {
98
- throw new OnePica_AvaTax_Model_Exception('Adapter should be set before export process');
99
  }
100
 
101
  return $this->getEntity()
86
  * Get export content
87
  *
88
  * @return string
89
+ * @throws OnePica_AvaTax_Exception
90
  */
91
  public function getContent()
92
  {
93
  if (!$this->getEntity()) {
94
+ throw new OnePica_AvaTax_Exception('Entity should be set before export process');
95
  }
96
 
97
  if (!$this->getAdapter()) {
98
+ throw new OnePica_AvaTax_Exception('Adapter should be set before export process');
99
  }
100
 
101
  return $this->getEntity()
app/code/community/OnePica/AvaTax/Model/Export/Adapter/Abstract.php CHANGED
File without changes
app/code/community/OnePica/AvaTax/Model/Export/Adapter/Sql.php CHANGED
@@ -35,16 +35,17 @@ class OnePica_AvaTax_Model_Export_Adapter_Sql extends OnePica_AvaTax_Model_Expor
35
  * Get content
36
  *
37
  * @return string
38
- * @throws OnePica_AvaTax_Model_Exception
39
  */
40
  public function getContent()
41
  {
42
  if (!$this->getCollection()) {
43
- throw new OnePica_AvaTax_Model_Exception('Collection should be set before export process');
44
  }
45
 
46
  $content = $this->_getExportHeader();
47
  $content .= $this->_getExportQueries();
 
48
  return $content;
49
  }
50
 
@@ -58,10 +59,11 @@ class OnePica_AvaTax_Model_Export_Adapter_Sql extends OnePica_AvaTax_Model_Expor
58
  $version = Mage::getResourceModel('core/resource')->getDbVersion('avatax_records_setup');
59
  $stores = count(Mage::app()->getStores());
60
  $content = '-- ' . strtoupper($this->getCollection()->getMainTable()) . " EXPORT\n";
61
- $content .= '-- Created at: ' . gmdate(DATE_W3C) . "\n";
62
  $content .= '-- Created by: ' . Mage::getUrl('/') . "\n";
63
- $content .= '-- Magento v' . Mage::getVersion() . ' // OP_AvaTax v' . $version . ' // Stores: ' . $stores . "\n";
64
- $content .= '-- Total rows: ' . $this->getCollection()->count() . "\n\n";
 
65
  return $content;
66
  }
67
 
@@ -73,8 +75,11 @@ class OnePica_AvaTax_Model_Export_Adapter_Sql extends OnePica_AvaTax_Model_Expor
73
  protected function _getColumns()
74
  {
75
  if ($this->_columns === null) {
76
- $this->_columns = array_keys($this->getCollection()->getFirstItem()->getData());
 
 
77
  }
 
78
  return $this->_columns;
79
  }
80
 
@@ -114,4 +119,14 @@ class OnePica_AvaTax_Model_Export_Adapter_Sql extends OnePica_AvaTax_Model_Expor
114
  }
115
  return $rows;
116
  }
 
 
 
 
 
 
 
 
 
 
117
  }
35
  * Get content
36
  *
37
  * @return string
38
+ * @throws OnePica_AvaTax_Exception
39
  */
40
  public function getContent()
41
  {
42
  if (!$this->getCollection()) {
43
+ throw new OnePica_AvaTax_Exception('Collection should be set before export process');
44
  }
45
 
46
  $content = $this->_getExportHeader();
47
  $content .= $this->_getExportQueries();
48
+
49
  return $content;
50
  }
51
 
59
  $version = Mage::getResourceModel('core/resource')->getDbVersion('avatax_records_setup');
60
  $stores = count(Mage::app()->getStores());
61
  $content = '-- ' . strtoupper($this->getCollection()->getMainTable()) . " EXPORT\n";
62
+ $content .= '-- Created at: ' . $this->_getDateModel()->gmtDate(DATE_W3C) . "\n";
63
  $content .= '-- Created by: ' . Mage::getUrl('/') . "\n";
64
+ $content .= '-- Magento v' . Mage::getVersion() . ' // OP_AvaTax v' . $version
65
+ . ' // Stores: ' . $stores . "\n";
66
+ $content .= '-- Total rows: ' . $this->getCollection()->getSize() . "\n\n";
67
  return $content;
68
  }
69
 
75
  protected function _getColumns()
76
  {
77
  if ($this->_columns === null) {
78
+ $this->_columns = array_keys(
79
+ $this->getCollection()->setPageSize(1)->setCurPage(1)->getFirstItem()->getData()
80
+ );
81
  }
82
+
83
  return $this->_columns;
84
  }
85
 
119
  }
120
  return $rows;
121
  }
122
+
123
+ /**
124
+ * Get core date model
125
+ *
126
+ * @return \Mage_Core_Model_Date
127
+ */
128
+ protected function _getDateModel()
129
+ {
130
+ return Mage::getSingleton('core/date');
131
+ }
132
  }
app/code/community/OnePica/AvaTax/Model/Export/Entity/Abstract.php CHANGED
@@ -90,16 +90,16 @@ abstract class OnePica_AvaTax_Model_Export_Entity_Abstract
90
  * Get content
91
  *
92
  * @return string
93
- * @throws OnePica_AvaTax_Model_Exception
94
  */
95
  public function getContent()
96
  {
97
  if (!$this->getAdapter()) {
98
- throw new OnePica_AvaTax_Model_Exception('Adapter should be set before export process');
99
  }
100
 
101
  if (!$this->getCollection()) {
102
- throw new OnePica_AvaTax_Model_Exception('Collection should be set before export process');
103
  }
104
 
105
  $collection = $this->getCollection()
90
  * Get content
91
  *
92
  * @return string
93
+ * @throws OnePica_AvaTax_Exception
94
  */
95
  public function getContent()
96
  {
97
  if (!$this->getAdapter()) {
98
+ throw new OnePica_AvaTax_Exception('Adapter should be set before export process');
99
  }
100
 
101
  if (!$this->getCollection()) {
102
+ throw new OnePica_AvaTax_Exception('Collection should be set before export process');
103
  }
104
 
105
  $collection = $this->getCollection()
app/code/community/OnePica/AvaTax/Model/Export/Entity/Log.php CHANGED
File without changes
app/code/community/OnePica/AvaTax/Model/Export/Entity/Queue.php CHANGED
File without changes
app/code/community/OnePica/AvaTax/Model/Observer.php CHANGED
@@ -98,20 +98,16 @@ class OnePica_AvaTax_Model_Observer extends Mage_Core_Model_Abstract
98
  return $this;
99
  }
100
 
101
- /* do not post pending or cancelled invoices */
102
- if ($invoice->getState() != Mage_Sales_Model_Order_Invoice::STATE_PAID) {
103
- return $this;
104
- }
105
- /* if the previous state was unpaid, process now */
106
- if (!$invoice->getOrigData($invoice->getIdFieldName()
107
- && $invoice->getOrigData('state') != Mage_Sales_Model_Order_Invoice::STATE_OPEN)
108
- && Mage::helper('avatax')->isObjectActionable($invoice)) {
109
  Mage::getModel('avatax_records/queue')
110
  ->setEntity($invoice)
111
  ->setType(OnePica_AvaTax_Model_Records_Queue::QUEUE_TYPE_INVOICE)
112
  ->setStatus(OnePica_AvaTax_Model_Records_Queue::QUEUE_STATUS_PENDING)
113
  ->save();
114
  }
 
115
  return $this;
116
  }
117
 
@@ -125,8 +121,9 @@ class OnePica_AvaTax_Model_Observer extends Mage_Core_Model_Abstract
125
  {
126
  /* @var $creditmemo Mage_Sales_Model_Order_Creditmemo */
127
  $creditmemo = $observer->getEvent()->getCreditmemo();
128
- if(!$creditmemo->getOrigData($creditmemo->getIdFieldName())
129
- && Mage::helper('avatax')->isObjectActionable($creditmemo)) {
 
130
  Mage::getModel('avatax_records/queue')
131
  ->setEntity($creditmemo)
132
  ->setType(OnePica_AvaTax_Model_Records_Queue::QUEUE_TYPE_CREDITMEMEO)
@@ -141,18 +138,19 @@ class OnePica_AvaTax_Model_Observer extends Mage_Core_Model_Abstract
141
  *
142
  * @param Varien_Event_Observer $observer
143
  * @return $this
144
- * @throws Mage_Core_Exception
145
  */
146
  public function multishippingSetShippingItems(Varien_Event_Observer $observer)
147
  {
148
  /* @var $quote Mage_Sales_Model_Quote */
149
  $quote = $observer->getEvent()->getQuote();
 
150
 
151
  $errors = array();
152
  $normalized = false;
153
- $store = Mage::getModel('core/store')->load($quote->getStoreId());
154
  $addresses = $quote->getAllShippingAddresses();
155
- $message = Mage::getStoreConfig('tax/avatax/validate_address_message', $store);
156
  foreach ($addresses as $address) {
157
  /* @var $address OnePica_AvaTax_Model_Sales_Quote_Address */
158
  if ($address->validate() !== true) {
@@ -165,11 +163,11 @@ class OnePica_AvaTax_Model_Observer extends Mage_Core_Model_Abstract
165
 
166
  $session = Mage::getSingleton('checkout/session');
167
  if ($normalized) {
168
- $session->addNotice(Mage::getStoreConfig('tax/avatax/multiaddress_normalize_message', $store));
169
  }
170
 
171
  if (!empty($errors)) {
172
- throw new Mage_Core_Exception(implode('<br />', $errors));
173
  }
174
  return $this;
175
  }
@@ -177,10 +175,9 @@ class OnePica_AvaTax_Model_Observer extends Mage_Core_Model_Abstract
177
  /**
178
  * Observer push data to Avalara
179
  *
180
- * @param Mage_Cron_Model_Schedule $schedule
181
  * @return $this;
182
  */
183
- public function processQueue($schedule)
184
  {
185
  Mage::getModel('avatax_records/queue_process')->run();
186
  return $this;
@@ -195,93 +192,17 @@ class OnePica_AvaTax_Model_Observer extends Mage_Core_Model_Abstract
195
  public function adminSystemConfigChangedSectionTax(Varien_Event_Observer $observer)
196
  {
197
  Mage::app()->cleanCache('block_html');
198
-
199
- $session = Mage::getSingleton('adminhtml/session');
200
- $storeId = Mage::getModel('core/store')->load($observer->getEvent()->getStore())->getStoreId();
201
- $warnings = array();
202
- $errors = array();
203
-
204
- if (strpos(Mage::getStoreConfig('tax/avatax/url', $storeId), 'development.avalara.net') !== false) {
205
- $warnings[] = Mage::helper('avatax')->__('You are using the AvaTax development connection URL. If you are receiving errors about authentication, please ensure that you have a development account.');
206
- }
207
- if (Mage::getStoreConfig('tax/avatax/action', $storeId) == OnePica_AvaTax_Model_Config::ACTION_DISABLE) {
208
- $warnings[] = Mage::helper('avatax')->__('All AvaTax services are disabled');
209
- }
210
- if (Mage::getStoreConfig('tax/avatax/action', $storeId) == OnePica_AvaTax_Model_Config::ACTION_CALC) {
211
- $warnings[] = Mage::helper('avatax')->__('Orders will not be sent to the AvaTax system');
212
- }
213
- if (Mage::getStoreConfig('tax/avatax/action', $storeId) == OnePica_AvaTax_Model_Config::ACTION_CALC_SUBMIT) {
214
- $warnings[] = Mage::helper('avatax')->__('Orders will be sent but never committed to the AvaTax system');
215
- }
216
-
217
- $ping = Mage::getSingleton('avatax/avatax_ping')->ping($storeId);
218
- if ($ping !== true) {
219
- $errors[] = $ping;
220
- }
221
- if (!Mage::getStoreConfig('tax/avatax/url', $storeId)) {
222
- $errors[] = Mage::helper('avatax')->__('You must enter a connection URL');
223
- }
224
- if (!Mage::getStoreConfig('tax/avatax/account', $storeId)) {
225
- $errors[] = Mage::helper('avatax')->__('You must enter an account number');
226
- }
227
- if (!Mage::getStoreConfig('tax/avatax/license', $storeId)) {
228
- $errors[] = Mage::helper('avatax')->__('You must enter a license key');
229
- }
230
- if (!is_numeric(Mage::getStoreConfig('tax/avatax/log_lifetime'))) {
231
- $errors[] = Mage::helper('avatax')->__('You must enter the number of days to keep log entries');
232
- }
233
- if (!Mage::getStoreConfig('tax/avatax/company_code', $storeId)) {
234
- $errors[] = Mage::helper('avatax')->__('You must enter a company code');
235
- }
236
- if (!Mage::getStoreConfig('tax/avatax/shipping_sku', $storeId)) {
237
- $errors[] = Mage::helper('avatax')->__('You must enter a shipping sku');
238
- }
239
- if (!Mage::getStoreConfig('tax/avatax/adjustment_positive_sku', $storeId)) {
240
- $errors[] = Mage::helper('avatax')->__('You must enter an adjustment refund sku');
241
- }
242
- if (!Mage::getStoreConfig('tax/avatax/adjustment_negative_sku', $storeId)) {
243
- $errors[] = Mage::helper('avatax')->__('You must enter an adjustment fee sku');
244
- }
245
-
246
- if (!class_exists('SoapClient')) {
247
- $errors[] = Mage::helper('avatax')->__('The PHP class SoapClient is missing. It must be enabled to use this extension. See %s for details.', '<a href="http://www.php.net/manual/en/book.soap.php" target="_blank">http://www.php.net/manual/en/book.soap.php</a>');
248
- }
249
-
250
- if (!function_exists('openssl_sign') && count($errors)) {
251
- $key = array_search(Mage::helper('avatax')->__('SSL support is not available in this build'), $errors);
252
- if (isset($errors[$key])) {
253
- unset($errors[$key]);
254
- }
255
- $errors[] = Mage::helper('avatax')->__('SSL must be enabled in PHP to use this extension. Typically, OpenSSL is used but it is not enabled on your server. This may not be a problem if you have some other form of SSL in place. For more information about OpenSSL, see %s.', '<a href="http://www.php.net/manual/en/book.openssl.php" target="_blank">http://www.php.net/manual/en/book.openssl.php</a>');
256
- }
257
-
258
- if (!Mage::getResourceModel('cron/schedule_collection')->count()) {
259
- $warnings[] = Mage::helper('avatax')->__('It appears that Magento\'s cron scheduler is not running. For more information, see %s.', '<a href="http://www.magentocommerce.com/wiki/how_to_setup_a_cron_job" target="_black">How to Set Up a Cron Job</a>');
260
- }
261
-
262
- if (count($errors) == 1) {
263
- $session->addError(implode('', $errors));
264
- } elseif (count($errors)) {
265
- $session->addError(Mage::helper('avatax')->__('Please fix the following issues:') . '<br /> - '
266
- . implode('<br /> - ', $errors));
267
- }
268
-
269
- if (count($warnings) == 1) {
270
- $session->addWarning(implode('', $warnings));
271
- } elseif (count($warnings)) {
272
- $session->addWarning(Mage::helper('avatax')->__('Please be aware of the following warnings:')
273
- . '<br /> - '
274
- . implode('<br /> - ', $warnings));
275
- }
276
  }
277
 
278
  /**
279
  * Observer to clean the log every so often so it does not get too big.
280
  *
281
- * @param Mage_Cron_Model_Schedule $schedule
282
  * @return $this
283
  */
284
- public function cleanLog($schedule)
285
  {
286
  $days = floatval(Mage::getStoreConfig('tax/avatax/log_lifetime'));
287
  Mage::getModel('avatax_records/log')->deleteLogsByInterval($days);
@@ -314,7 +235,6 @@ class OnePica_AvaTax_Model_Observer extends Mage_Core_Model_Abstract
314
  $helper->loadFunctions();
315
  $helper->loadClass($class);
316
  }
317
- return;
318
  }
319
 
320
  /**
@@ -342,4 +262,224 @@ class OnePica_AvaTax_Model_Observer extends Mage_Core_Model_Abstract
342
  $session->setPostType('onepage');
343
  return $this;
344
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
345
  }
98
  return $this;
99
  }
100
 
101
+ if (!$invoice->getOrigData($invoice->getIdFieldName())
102
+ && Mage::helper('avatax')->isObjectActionable($invoice)
103
+ ) {
 
 
 
 
 
104
  Mage::getModel('avatax_records/queue')
105
  ->setEntity($invoice)
106
  ->setType(OnePica_AvaTax_Model_Records_Queue::QUEUE_TYPE_INVOICE)
107
  ->setStatus(OnePica_AvaTax_Model_Records_Queue::QUEUE_STATUS_PENDING)
108
  ->save();
109
  }
110
+
111
  return $this;
112
  }
113
 
121
  {
122
  /* @var $creditmemo Mage_Sales_Model_Order_Creditmemo */
123
  $creditmemo = $observer->getEvent()->getCreditmemo();
124
+ if (!$creditmemo->getOrigData($creditmemo->getIdFieldName())
125
+ && Mage::helper('avatax')->isObjectActionable($creditmemo)
126
+ ) {
127
  Mage::getModel('avatax_records/queue')
128
  ->setEntity($creditmemo)
129
  ->setType(OnePica_AvaTax_Model_Records_Queue::QUEUE_TYPE_CREDITMEMEO)
138
  *
139
  * @param Varien_Event_Observer $observer
140
  * @return $this
141
+ * @throws OnePica_AvaTax_Exception
142
  */
143
  public function multishippingSetShippingItems(Varien_Event_Observer $observer)
144
  {
145
  /* @var $quote Mage_Sales_Model_Quote */
146
  $quote = $observer->getEvent()->getQuote();
147
+ $storeId = $quote->getStoreId();
148
 
149
  $errors = array();
150
  $normalized = false;
151
+
152
  $addresses = $quote->getAllShippingAddresses();
153
+ $message = Mage::getStoreConfig('tax/avatax/validate_address_message', $storeId);
154
  foreach ($addresses as $address) {
155
  /* @var $address OnePica_AvaTax_Model_Sales_Quote_Address */
156
  if ($address->validate() !== true) {
163
 
164
  $session = Mage::getSingleton('checkout/session');
165
  if ($normalized) {
166
+ $session->addNotice(Mage::getStoreConfig('tax/avatax/multiaddress_normalize_message', $storeId));
167
  }
168
 
169
  if (!empty($errors)) {
170
+ throw new OnePica_AvaTax_Exception(implode('<br />', $errors));
171
  }
172
  return $this;
173
  }
175
  /**
176
  * Observer push data to Avalara
177
  *
 
178
  * @return $this;
179
  */
180
+ public function processQueue()
181
  {
182
  Mage::getModel('avatax_records/queue_process')->run();
183
  return $this;
192
  public function adminSystemConfigChangedSectionTax(Varien_Event_Observer $observer)
193
  {
194
  Mage::app()->cleanCache('block_html');
195
+ $storeId = $observer->getEvent()->getStore();
196
+ $this->_addErrorsToSession($storeId);
197
+ $this->_addWarningsToSession($storeId);
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
198
  }
199
 
200
  /**
201
  * Observer to clean the log every so often so it does not get too big.
202
  *
 
203
  * @return $this
204
  */
205
+ public function cleanLog()
206
  {
207
  $days = floatval(Mage::getStoreConfig('tax/avatax/log_lifetime'));
208
  Mage::getModel('avatax_records/log')->deleteLogsByInterval($days);
235
  $helper->loadFunctions();
236
  $helper->loadClass($class);
237
  }
 
238
  }
239
 
240
  /**
262
  $session->setPostType('onepage');
263
  return $this;
264
  }
265
+
266
+ /**
267
+ * Prepare warnings array
268
+ *
269
+ * @param int $storeId
270
+ * @return array
271
+ */
272
+ protected function _prepareWarnings($storeId)
273
+ {
274
+ $warnings = array();
275
+ if (strpos(Mage::getStoreConfig('tax/avatax/url', $storeId), 'development.avalara.net') !== false) {
276
+ $warnings[] = Mage::helper('avatax')->__(
277
+ 'You are using the AvaTax development connection URL. If you are receiving errors about authentication, please ensure that you have a development account.'
278
+ );
279
+ }
280
+ if (Mage::getStoreConfig('tax/avatax/action', $storeId) == OnePica_AvaTax_Model_Config::ACTION_DISABLE) {
281
+ $warnings[] = Mage::helper('avatax')->__('All AvaTax services are disabled');
282
+ }
283
+ if (Mage::getStoreConfig('tax/avatax/action', $storeId) == OnePica_AvaTax_Model_Config::ACTION_CALC) {
284
+ $warnings[] = Mage::helper('avatax')->__('Orders will not be sent to the AvaTax system');
285
+ }
286
+ if (Mage::getStoreConfig('tax/avatax/action', $storeId) == OnePica_AvaTax_Model_Config::ACTION_CALC_SUBMIT) {
287
+ $warnings[] = Mage::helper('avatax')->__('Orders will be sent but never committed to the AvaTax system');
288
+ }
289
+ if (!Mage::getResourceModel('cron/schedule_collection')->count()) {
290
+ $warnings[] = Mage::helper('avatax')->__(
291
+ 'It appears that Magento\'s cron scheduler is not running. For more information, see %s.',
292
+ '<a href="http://www.magentocommerce.com/wiki/how_to_setup_a_cron_job" target="_black">How to Set Up a Cron Job</a>'
293
+ );
294
+
295
+ return $warnings;
296
+ }
297
+
298
+ return $warnings;
299
+ }
300
+
301
+ /**
302
+ * Prepare errors array
303
+ *
304
+ * @param int $storeId
305
+ * @return array
306
+ */
307
+ protected function _prepareErrors($storeId)
308
+ {
309
+ $errors = array();
310
+ $errors = array_merge(
311
+ $errors,
312
+ $this->_sendPing($storeId),
313
+ $this->_checkConnectionFields($storeId),
314
+ $this->_checkSkuFields($storeId),
315
+ $this->_checkSoapSupport(),
316
+ $this->_checkSslSupport()
317
+ );
318
+
319
+ return $errors;
320
+ }
321
+
322
+ /**
323
+ * Get adminhtml model session
324
+ *
325
+ * @return \Mage_Adminhtml_Model_Session
326
+ */
327
+ protected function _getAdminhtmlSession()
328
+ {
329
+ return Mage::getSingleton('adminhtml/session');
330
+ }
331
+
332
+ /**
333
+ * Add error messages to session
334
+ *
335
+ * @param int $storeId
336
+ * @return $this
337
+ */
338
+ protected function _addErrorsToSession($storeId)
339
+ {
340
+ $session = $this->_getAdminhtmlSession();
341
+ $errors = $this->_prepareErrors($storeId);
342
+ if (count($errors) == 1) {
343
+ $session->addError(implode('', $errors));
344
+ } elseif (count($errors)) {
345
+ $session->addError(
346
+ Mage::helper('avatax')->__('Please fix the following issues:') . '<br /> - '
347
+ . implode('<br /> - ', $errors)
348
+ );
349
+ }
350
+
351
+ return $this;
352
+ }
353
+
354
+ /**
355
+ * Add warning messages to session
356
+ *
357
+ * @param int $storeId
358
+ * @return $this
359
+ */
360
+ protected function _addWarningsToSession($storeId)
361
+ {
362
+ $session = $this->_getAdminhtmlSession();
363
+ $warnings = $this->_prepareWarnings($storeId);
364
+ if (count($warnings) == 1) {
365
+ $session->addWarning(implode('', $warnings));
366
+ } elseif (count($warnings)) {
367
+ $session->addWarning(
368
+ Mage::helper('avatax')->__('Please be aware of the following warnings:')
369
+ . '<br /> - '
370
+ . implode('<br /> - ', $warnings)
371
+ );
372
+ }
373
+
374
+ return $this;
375
+ }
376
+
377
+ /**
378
+ * Send ping request
379
+ *
380
+ * @param int $storeId
381
+ * @return array
382
+ */
383
+ protected function _sendPing($storeId)
384
+ {
385
+ $errors = array();
386
+ $ping = Mage::getSingleton('avatax/avatax_ping')->ping($storeId);
387
+ if ($ping !== true) {
388
+ $errors[] = $ping;
389
+ }
390
+
391
+ return $errors;
392
+ }
393
+
394
+ /**
395
+ * Check connection fields
396
+ *
397
+ * @param int $storeId
398
+ * @return array
399
+ */
400
+ protected function _checkConnectionFields($storeId)
401
+ {
402
+ $errors = array();
403
+ if (!Mage::getStoreConfig('tax/avatax/url', $storeId)) {
404
+ $errors[] = Mage::helper('avatax')->__('You must enter a connection URL');
405
+ }
406
+ if (!Mage::getStoreConfig('tax/avatax/account', $storeId)) {
407
+ $errors[] = Mage::helper('avatax')->__('You must enter an account number');
408
+ }
409
+ if (!Mage::getStoreConfig('tax/avatax/license', $storeId)) {
410
+ $errors[] = Mage::helper('avatax')->__('You must enter a license key');
411
+ }
412
+ if (!is_numeric(Mage::getStoreConfig('tax/avatax/log_lifetime'))) {
413
+ $errors[] = Mage::helper('avatax')->__('You must enter the number of days to keep log entries');
414
+ }
415
+ if (!Mage::getStoreConfig('tax/avatax/company_code', $storeId)) {
416
+ $errors[] = Mage::helper('avatax')->__('You must enter a company code');
417
+ }
418
+
419
+ return $errors;
420
+ }
421
+
422
+ /**
423
+ * Check Sku fields
424
+ *
425
+ * @param int $storeId
426
+ * @return array
427
+ */
428
+ protected function _checkSkuFields($storeId)
429
+ {
430
+ $errors = array();
431
+ if (!Mage::getStoreConfig('tax/avatax/shipping_sku', $storeId)) {
432
+ $errors[] = Mage::helper('avatax')->__('You must enter a shipping sku');
433
+ }
434
+ if (!Mage::getStoreConfig('tax/avatax/adjustment_positive_sku', $storeId)) {
435
+ $errors[] = Mage::helper('avatax')->__('You must enter an adjustment refund sku');
436
+ }
437
+ if (!Mage::getStoreConfig('tax/avatax/adjustment_negative_sku', $storeId)) {
438
+ $errors[] = Mage::helper('avatax')->__('You must enter an adjustment fee sku');
439
+
440
+ return $errors;
441
+ }
442
+
443
+ return $errors;
444
+ }
445
+
446
+ /**
447
+ * Check SOAP support
448
+ *
449
+ * @return array
450
+ */
451
+ protected function _checkSoapSupport()
452
+ {
453
+ $errors = array();
454
+ if (!class_exists('SoapClient')) {
455
+ $errors[] = Mage::helper('avatax')->__(
456
+ 'The PHP class SoapClient is missing. It must be enabled to use this extension. See %s for details.',
457
+ '<a href="http://www.php.net/manual/en/book.soap.php" target="_blank">http://www.php.net/manual/en/book.soap.php</a>'
458
+ );
459
+ }
460
+
461
+ return $errors;
462
+ }
463
+
464
+ /**
465
+ * Check SSL support
466
+ *
467
+ * @return array
468
+ */
469
+ protected function _checkSslSupport()
470
+ {
471
+ $errors = array();
472
+ if (!function_exists('openssl_sign') && count($errors)) {
473
+ $key = array_search(Mage::helper('avatax')->__('SSL support is not available in this build'), $errors);
474
+ if (isset($errors[$key])) {
475
+ unset($errors[$key]);
476
+ }
477
+ $errors[] = Mage::helper('avatax')->__(
478
+ 'SSL must be enabled in PHP to use this extension. Typically, OpenSSL is used but it is not enabled on your server. This may not be a problem if you have some other form of SSL in place. For more information about OpenSSL, see %s.',
479
+ '<a href="http://www.php.net/manual/en/book.openssl.php" target="_blank">http://www.php.net/manual/en/book.openssl.php</a>'
480
+ );
481
+ }
482
+
483
+ return $errors;
484
+ }
485
  }
app/code/community/OnePica/AvaTax/Model/Records/Log.php CHANGED
@@ -72,7 +72,7 @@ class OnePica_AvaTax_Model_Records_Log extends Mage_Core_Model_Abstract
72
  $result = array();
73
  $storeId = Mage::app()->getStore()->getId();
74
  $types = Mage::helper('avatax')->getLogType($storeId);
75
- foreach ($types as $key => $value) {
76
  $result[$value] = $value;
77
  }
78
  return $result;
@@ -83,7 +83,8 @@ class OnePica_AvaTax_Model_Records_Log extends Mage_Core_Model_Abstract
83
  *
84
  * @return array
85
  */
86
- public function getLevelOptions() {
 
87
  return array(
88
  self::LOG_LEVEL_SUCCESS => self::LOG_LEVEL_SUCCESS,
89
  self::LOG_LEVEL_ERROR => self::LOG_LEVEL_ERROR
72
  $result = array();
73
  $storeId = Mage::app()->getStore()->getId();
74
  $types = Mage::helper('avatax')->getLogType($storeId);
75
+ foreach ($types as $value) {
76
  $result[$value] = $value;
77
  }
78
  return $result;
83
  *
84
  * @return array
85
  */
86
+ public function getLevelOptions()
87
+ {
88
  return array(
89
  self::LOG_LEVEL_SUCCESS => self::LOG_LEVEL_SUCCESS,
90
  self::LOG_LEVEL_ERROR => self::LOG_LEVEL_ERROR
app/code/community/OnePica/AvaTax/Model/Records/Mysql4/Log.php CHANGED
@@ -40,7 +40,7 @@ class OnePica_AvaTax_Model_Records_Mysql4_Log extends Mage_Core_Model_Mysql4_Abs
40
  */
41
  protected function _beforeSave(Mage_Core_Model_Abstract $object)
42
  {
43
- $object->setCreatedAt(gmdate('Y-m-d H:i:s'));
44
  if ($object->getLevel() != OnePica_AvaTax_Model_Records_Log::LOG_LEVEL_SUCCESS) {
45
  $object->setLevel(OnePica_AvaTax_Model_Records_Log::LOG_LEVEL_ERROR);
46
  }
@@ -60,4 +60,14 @@ class OnePica_AvaTax_Model_Records_Mysql4_Log extends Mage_Core_Model_Mysql4_Abs
60
  $this->_getWriteAdapter()->quoteInto('created_at < DATE_SUB(UTC_DATE(), INTERVAL ? DAY)', $days)
61
  );
62
  }
 
 
 
 
 
 
 
 
 
 
63
  }
40
  */
41
  protected function _beforeSave(Mage_Core_Model_Abstract $object)
42
  {
43
+ $object->setCreatedAt($this->_getDateModel()->gmtDate('Y-m-d H:i:s'));
44
  if ($object->getLevel() != OnePica_AvaTax_Model_Records_Log::LOG_LEVEL_SUCCESS) {
45
  $object->setLevel(OnePica_AvaTax_Model_Records_Log::LOG_LEVEL_ERROR);
46
  }
60
  $this->_getWriteAdapter()->quoteInto('created_at < DATE_SUB(UTC_DATE(), INTERVAL ? DAY)', $days)
61
  );
62
  }
63
+
64
+ /**
65
+ * Get core date model
66
+ *
67
+ * @return \Mage_Core_Model_Date
68
+ */
69
+ protected function _getDateModel()
70
+ {
71
+ return Mage::getSingleton('core/date');
72
+ }
73
  }
app/code/community/OnePica/AvaTax/Model/Records/Mysql4/Log/Collection.php CHANGED
File without changes
app/code/community/OnePica/AvaTax/Model/Records/Mysql4/Queue.php CHANGED
@@ -51,9 +51,9 @@ class OnePica_AvaTax_Model_Records_Mysql4_Queue extends Mage_Core_Model_Mysql4_A
51
  protected function _beforeSave(Mage_Core_Model_Abstract $object)
52
  {
53
  if (!$object->hasCreatedAt()) {
54
- $object->setCreatedAt(gmdate('Y-m-d H:i:s'));
55
  }
56
- $object->setUpdatedAt(gmdate('Y-m-d H:i:s'));
57
  return $this;
58
  }
59
 
@@ -127,4 +127,14 @@ class OnePica_AvaTax_Model_Records_Mysql4_Queue extends Mage_Core_Model_Mysql4_A
127
 
128
  return $this;
129
  }
 
 
 
 
 
 
 
 
 
 
130
  }
51
  protected function _beforeSave(Mage_Core_Model_Abstract $object)
52
  {
53
  if (!$object->hasCreatedAt()) {
54
+ $object->setCreatedAt($this->_getDateModel()->gmtDate('Y-m-d H:i:s'));
55
  }
56
+ $object->setUpdatedAt($this->_getDateModel()->gmtDate('Y-m-d H:i:s'));
57
  return $this;
58
  }
59
 
127
 
128
  return $this;
129
  }
130
+
131
+ /**
132
+ * Get core date model
133
+ *
134
+ * @return Mage_Core_Model_Date
135
+ */
136
+ protected function _getDateModel()
137
+ {
138
+ return Mage::getSingleton('core/date');
139
+ }
140
  }
app/code/community/OnePica/AvaTax/Model/Records/Mysql4/Queue/Collection.php CHANGED
File without changes
app/code/community/OnePica/AvaTax/Model/Records/Queue.php CHANGED
File without changes
app/code/community/OnePica/AvaTax/Model/Records/Queue/Process.php CHANGED
@@ -33,7 +33,8 @@ class OnePica_AvaTax_Model_Records_Queue_Process extends OnePica_AvaTax_Model_Ab
33
  {
34
  /** @var OnePica_AvaTax_Model_Records_Mysql4_Queue_Collection $queue */
35
  $queue = Mage::getModel('avatax_records/queue')->getCollection()
36
- ->addFieldToFilter('status', array(
 
37
  'in' => array(
38
  OnePica_AvaTax_Model_Records_Queue::QUEUE_STATUS_FAILED,
39
  OnePica_AvaTax_Model_Records_Queue::QUEUE_STATUS_UNBALANCED,
@@ -78,7 +79,10 @@ class OnePica_AvaTax_Model_Records_Queue_Process extends OnePica_AvaTax_Model_Ab
78
  /** @var OnePica_AvaTax_Model_Records_Mysql4_Queue_Collection $queue */
79
  $queue = Mage::getModel('avatax_records/queue')->getCollection()
80
  ->addFieldToFilter('status', OnePica_AvaTax_Model_Records_Queue::QUEUE_STATUS_COMPLETE)
81
- ->addFieldToFilter('updated_at', array('lt' => gmdate('Y-m-d H:i:s', strtotime('-' . $days . ' days'))));
 
 
 
82
 
83
  foreach ($queue as $item) {
84
  $item->delete();
@@ -99,7 +103,10 @@ class OnePica_AvaTax_Model_Records_Queue_Process extends OnePica_AvaTax_Model_Ab
99
  /** @var OnePica_AvaTax_Model_Records_Mysql4_Queue_Collection $queue */
100
  $queue = Mage::getModel('avatax_records/queue')->getCollection()
101
  ->addFieldToFilter('status', OnePica_AvaTax_Model_Records_Queue::QUEUE_STATUS_FAILED)
102
- ->addFieldToFilter('updated_at', array('lt' => gmdate('Y-m-d H:i:s', strtotime('-' . $days . ' days'))));
 
 
 
103
 
104
  foreach ($queue as $item) {
105
  $item->delete();
@@ -120,7 +127,10 @@ class OnePica_AvaTax_Model_Records_Queue_Process extends OnePica_AvaTax_Model_Ab
120
  /** @var OnePica_AvaTax_Model_Records_Mysql4_Queue_Collection $queue */
121
  $queue = Mage::getModel('avatax_records/queue')->getCollection()
122
  ->addFieldToFilter('status', OnePica_AvaTax_Model_Records_Queue::QUEUE_STATUS_UNBALANCED)
123
- ->addFieldToFilter('updated_at', array('lt' => gmdate('Y-m-d H:i:s', strtotime('-' . $days . ' days'))));
 
 
 
124
 
125
  /** @var OnePica_AvaTax_Model_Records_Queue $item */
126
  foreach ($queue as $item) {
@@ -207,4 +217,14 @@ class OnePica_AvaTax_Model_Records_Queue_Process extends OnePica_AvaTax_Model_Ab
207
 
208
  return $this;
209
  }
 
 
 
 
 
 
 
 
 
 
210
  }
33
  {
34
  /** @var OnePica_AvaTax_Model_Records_Mysql4_Queue_Collection $queue */
35
  $queue = Mage::getModel('avatax_records/queue')->getCollection()
36
+ ->addFieldToFilter(
37
+ 'status', array(
38
  'in' => array(
39
  OnePica_AvaTax_Model_Records_Queue::QUEUE_STATUS_FAILED,
40
  OnePica_AvaTax_Model_Records_Queue::QUEUE_STATUS_UNBALANCED,
79
  /** @var OnePica_AvaTax_Model_Records_Mysql4_Queue_Collection $queue */
80
  $queue = Mage::getModel('avatax_records/queue')->getCollection()
81
  ->addFieldToFilter('status', OnePica_AvaTax_Model_Records_Queue::QUEUE_STATUS_COMPLETE)
82
+ ->addFieldToFilter(
83
+ 'updated_at',
84
+ array('lt' => $this->_getDateModel()->gmtDate('Y-m-d H:i:s', strtotime('-' . $days . ' days')))
85
+ );
86
 
87
  foreach ($queue as $item) {
88
  $item->delete();
103
  /** @var OnePica_AvaTax_Model_Records_Mysql4_Queue_Collection $queue */
104
  $queue = Mage::getModel('avatax_records/queue')->getCollection()
105
  ->addFieldToFilter('status', OnePica_AvaTax_Model_Records_Queue::QUEUE_STATUS_FAILED)
106
+ ->addFieldToFilter(
107
+ 'updated_at',
108
+ array('lt' => $this->_getDateModel()->gmtDate('Y-m-d H:i:s', strtotime('-' . $days . ' days')))
109
+ );
110
 
111
  foreach ($queue as $item) {
112
  $item->delete();
127
  /** @var OnePica_AvaTax_Model_Records_Mysql4_Queue_Collection $queue */
128
  $queue = Mage::getModel('avatax_records/queue')->getCollection()
129
  ->addFieldToFilter('status', OnePica_AvaTax_Model_Records_Queue::QUEUE_STATUS_UNBALANCED)
130
+ ->addFieldToFilter(
131
+ 'updated_at',
132
+ array('lt' => $this->_getDateModel()->gmtDate('Y-m-d H:i:s', strtotime('-' . $days . ' days')))
133
+ );
134
 
135
  /** @var OnePica_AvaTax_Model_Records_Queue $item */
136
  foreach ($queue as $item) {
217
 
218
  return $this;
219
  }
220
+
221
+ /**
222
+ * Get core date model
223
+ *
224
+ * @return Mage_Core_Model_Date
225
+ */
226
+ protected function _getDateModel()
227
+ {
228
+ return Mage::getSingleton('core/date');
229
+ }
230
  }
app/code/community/OnePica/AvaTax/Model/Sales/Quote/Address.php CHANGED
File without changes
app/code/community/OnePica/AvaTax/Model/Sales/Quote/Address/Total/Grand.php CHANGED
File without changes
app/code/community/OnePica/AvaTax/Model/Sales/Quote/Address/Total/Tax.php CHANGED
@@ -208,30 +208,35 @@ class OnePica_AvaTax_Model_Sales_Quote_Address_Total_Tax extends Mage_Sales_Mode
208
  }
209
 
210
  if (($amount != 0) || (Mage::helper('tax')->displayZeroTax($store))) {
211
- $address->addTotal(array(
212
- 'code' => $this->getCode(),
213
- 'title' => Mage::helper('tax')->__('Tax'),
214
- 'full_info' => $fullInfo,
215
- 'value' => $amount,
216
- 'area' => null
217
- ));
 
 
218
  }
219
 
220
  /**
221
  * Modify subtotal
222
  */
223
  if (method_exists($config, "displayCartSubtotalBoth") && method_exists($config, "displayCartSubtotalInclTax")
224
- && ($config->displayCartSubtotalBoth($store) || $config->displayCartSubtotalInclTax($store))) {
 
225
  $subtotalInclTax = $address->getSubtotal() + $address->getTaxAmount() - $address->getShippingTaxAmount();
226
  $address->setSubtotalInclTax($subtotalInclTax);
227
 
228
- $address->addTotal(array(
229
- 'code' => 'subtotal',
230
- 'title' => Mage::helper('sales')->__('Subtotal'),
231
- 'value' => $subtotalInclTax,
232
- 'value_incl_tax' => $subtotalInclTax,
233
- 'value_excl_tax' => $address->getSubtotal(),
234
- ));
 
 
235
  }
236
 
237
  return $this;
@@ -293,12 +298,12 @@ class OnePica_AvaTax_Model_Sales_Quote_Address_Total_Tax extends Mage_Sales_Mode
293
  * Get quote address object
294
  *
295
  * @return Mage_Sales_Model_Quote_Address
296
- * @throws Mage_Core_Exception
297
  */
298
  protected function _getAddress()
299
  {
300
  if ($this->_address === null) {
301
- throw new Mage_Core_Exception(Mage::helper('sales')->__('Address model is not defined'));
302
  }
303
  return $this->_address;
304
  }
208
  }
209
 
210
  if (($amount != 0) || (Mage::helper('tax')->displayZeroTax($store))) {
211
+ $address->addTotal(
212
+ array(
213
+ 'code' => $this->getCode(),
214
+ 'title' => Mage::helper('tax')->__('Tax'),
215
+ 'full_info' => $fullInfo,
216
+ 'value' => $amount,
217
+ 'area' => null
218
+ )
219
+ );
220
  }
221
 
222
  /**
223
  * Modify subtotal
224
  */
225
  if (method_exists($config, "displayCartSubtotalBoth") && method_exists($config, "displayCartSubtotalInclTax")
226
+ && ($config->displayCartSubtotalBoth($store) || $config->displayCartSubtotalInclTax($store))
227
+ ) {
228
  $subtotalInclTax = $address->getSubtotal() + $address->getTaxAmount() - $address->getShippingTaxAmount();
229
  $address->setSubtotalInclTax($subtotalInclTax);
230
 
231
+ $address->addTotal(
232
+ array(
233
+ 'code' => 'subtotal',
234
+ 'title' => Mage::helper('sales')->__('Subtotal'),
235
+ 'value' => $subtotalInclTax,
236
+ 'value_incl_tax' => $subtotalInclTax,
237
+ 'value_excl_tax' => $address->getSubtotal(),
238
+ )
239
+ );
240
  }
241
 
242
  return $this;
298
  * Get quote address object
299
  *
300
  * @return Mage_Sales_Model_Quote_Address
301
+ * @throws OnePica_AvaTax_Exception
302
  */
303
  protected function _getAddress()
304
  {
305
  if ($this->_address === null) {
306
+ throw new OnePica_AvaTax_Exception(Mage::helper('sales')->__('Address model is not defined'));
307
  }
308
  return $this->_address;
309
  }
app/code/community/OnePica/AvaTax/Model/Session.php CHANGED
@@ -26,10 +26,8 @@ class OnePica_AvaTax_Model_Session extends Mage_Core_Model_Session_Abstract
26
  {
27
  /**
28
  * Construct
29
- *
30
- * @param array $data
31
  */
32
- public function __construct($data = array())
33
  {
34
  $this->init('avatax');
35
  }
26
  {
27
  /**
28
  * Construct
 
 
29
  */
30
+ public function __construct()
31
  {
32
  $this->init('avatax');
33
  }
app/code/community/OnePica/AvaTax/Model/Source/Actions.php CHANGED
File without changes
app/code/community/OnePica/AvaTax/Model/Source/Addressvalidation.php CHANGED
File without changes
app/code/community/OnePica/AvaTax/Model/Source/Customercodeformat.php CHANGED
File without changes
app/code/community/OnePica/AvaTax/Model/Source/Error.php CHANGED
File without changes
app/code/community/OnePica/AvaTax/Model/Source/Fieldlist.php CHANGED
@@ -33,7 +33,7 @@ class OnePica_AvaTax_Model_Source_Fieldlist
33
  {
34
  $obj = Mage::getConfig()->getNode('admin/fieldsets/customer_dataflow');
35
 
36
- foreach ($obj as $key => $obj2) {
37
  foreach ($obj2 as $key2 => $obj3) {
38
  if ($obj3->shipping) {
39
  $arr[] = array(
33
  {
34
  $obj = Mage::getConfig()->getNode('admin/fieldsets/customer_dataflow');
35
 
36
+ foreach ($obj as $obj2) {
37
  foreach ($obj2 as $key2 => $obj3) {
38
  if ($obj3->shipping) {
39
  $arr[] = array(
app/code/community/OnePica/AvaTax/Model/Source/Logmode.php CHANGED
File without changes
app/code/community/OnePica/AvaTax/Model/Source/Logtype.php CHANGED
File without changes
app/code/community/OnePica/AvaTax/Model/Source/Onerrorfrontend.php CHANGED
File without changes
app/code/community/OnePica/AvaTax/Model/Source/Regionfilter/List.php CHANGED
File without changes
app/code/community/OnePica/AvaTax/Model/Source/Regionfilter/Mode.php CHANGED
File without changes
app/code/community/OnePica/AvaTax/Model/Tax/Config.php CHANGED
File without changes
app/code/community/OnePica/AvaTax/controllers/Adminhtml/ExportController.php CHANGED
@@ -39,8 +39,9 @@ class OnePica_AvaTax_Adminhtml_ExportController extends Mage_Adminhtml_Controlle
39
  *
40
  * @return $this
41
  */
42
- public function logAction() {
43
- $fileName = 'avatax-log-' . gmdate('U') . '.sql';
 
44
  $content = Mage::getModel('avatax/export')
45
  ->setAdapter(Mage::getModel('avatax/export_adapter_sql'))
46
  ->setEntity(Mage::getModel('avatax/export_entity_log'))
@@ -56,7 +57,7 @@ class OnePica_AvaTax_Adminhtml_ExportController extends Mage_Adminhtml_Controlle
56
  */
57
  public function queueAction()
58
  {
59
- $fileName = 'avatax-queue-' . gmdate('U') . '.sql';
60
  $content = Mage::getModel('avatax/export')
61
  ->setAdapter(Mage::getModel('avatax/export_adapter_sql'))
62
  ->setEntity(Mage::getModel('avatax/export_entity_queue'))
@@ -80,11 +81,21 @@ class OnePica_AvaTax_Adminhtml_ExportController extends Mage_Adminhtml_Controlle
80
  $response->setHeader('Pragma', 'public', true);
81
  $response->setHeader('Cache-Control', 'must-revalidate, post-check=0, pre-check=0', true);
82
  $response->setHeader('Content-Disposition', 'attachment; filename=' . $fileName);
83
- $response->setHeader('Last-Modified', date('r'));
84
  $response->setHeader('Accept-Ranges', 'bytes');
85
  $response->setHeader('Content-Length', strlen($content));
86
  $response->setHeader('Content-type', $contentType);
87
  $response->setBody($content);
88
  return $this;
89
  }
 
 
 
 
 
 
 
 
 
 
90
  }
39
  *
40
  * @return $this
41
  */
42
+ public function logAction()
43
+ {
44
+ $fileName = 'avatax-log-' . $this->_getDateModel()->gmtDate('U') . '.sql';
45
  $content = Mage::getModel('avatax/export')
46
  ->setAdapter(Mage::getModel('avatax/export_adapter_sql'))
47
  ->setEntity(Mage::getModel('avatax/export_entity_log'))
57
  */
58
  public function queueAction()
59
  {
60
+ $fileName = 'avatax-queue-' . $this->_getDateModel()->gmtDate('U') . '.sql';
61
  $content = Mage::getModel('avatax/export')
62
  ->setAdapter(Mage::getModel('avatax/export_adapter_sql'))
63
  ->setEntity(Mage::getModel('avatax/export_entity_queue'))
81
  $response->setHeader('Pragma', 'public', true);
82
  $response->setHeader('Cache-Control', 'must-revalidate, post-check=0, pre-check=0', true);
83
  $response->setHeader('Content-Disposition', 'attachment; filename=' . $fileName);
84
+ $response->setHeader('Last-Modified', $this->_getDateModel()->date('r'));
85
  $response->setHeader('Accept-Ranges', 'bytes');
86
  $response->setHeader('Content-Length', strlen($content));
87
  $response->setHeader('Content-type', $contentType);
88
  $response->setBody($content);
89
  return $this;
90
  }
91
+
92
+ /**
93
+ * Get core date model
94
+ *
95
+ * @return Mage_Core_Model_Date
96
+ */
97
+ protected function _getDateModel()
98
+ {
99
+ return Mage::getSingleton('core/date');
100
+ }
101
  }
app/code/community/OnePica/AvaTax/controllers/Adminhtml/GridController.php CHANGED
File without changes
app/code/community/OnePica/AvaTax/etc/adminhtml.xml CHANGED
File without changes
app/code/community/OnePica/AvaTax/etc/config.xml CHANGED
@@ -19,7 +19,7 @@
19
  <config>
20
  <modules>
21
  <OnePica_AvaTax>
22
- <version>2.5.0.2</version>
23
  </OnePica_AvaTax>
24
  </modules>
25
  <global>
19
  <config>
20
  <modules>
21
  <OnePica_AvaTax>
22
+ <version>2.5.2.0</version>
23
  </OnePica_AvaTax>
24
  </modules>
25
  <global>
app/code/community/OnePica/AvaTax/etc/system-disabled.xml CHANGED
File without changes
app/code/community/OnePica/AvaTax/etc/system.xml CHANGED
File without changes
app/code/community/OnePica/AvaTax/{data/avatax_records_setup/data-upgrade-2.2.0-2.2.1.php → sql/avatax_records_setup/mysql4-data-upgrade-2.2.0-2.2.1.php} RENAMED
File without changes
app/code/community/OnePica/AvaTax/sql/avatax_records_setup/mysql4-install-0.1.0.php CHANGED
@@ -16,21 +16,14 @@
16
  */
17
  $installer = $this;
18
  $installer->startSetup();
19
- /* @var $this Mage_Core_Model_Resource_Setup */
20
- $adapter = $this->getConnection();
21
  try {
22
- $adapter->addColumn(
23
- $this->getTable('tax/tax_class'),
24
- 'op_avatax_code',
25
- array(
26
- 'type' => Varien_Db_Ddl_Table::TYPE_TEXT,
27
- 'length' => 255,
28
- 'default' => '',
29
- 'nullable' => false,
30
- 'comment' => 'Used by One Pica AvaTax extension',
31
- 'after' => 'class_name'
32
- )
33
- );
34
  } catch (Exception $e) {
35
  Mage::logException($e);
36
  }
16
  */
17
  $installer = $this;
18
  $installer->startSetup();
 
 
19
  try {
20
+ $installer->run("
21
+
22
+ ALTER TABLE `" . $this->getTable('tax/tax_class') . "`
23
+ ADD `op_avatax_code` VARCHAR(255) DEFAULT '' NOT NULL COMMENT 'Used by One Pica AvaTax extension'
24
+ AFTER `class_name`;
25
+
26
+ ");
 
 
 
 
 
27
  } catch (Exception $e) {
28
  Mage::logException($e);
29
  }
app/code/community/OnePica/AvaTax/sql/avatax_records_setup/mysql4-upgrade-0.1.4-0.1.5.php CHANGED
@@ -17,65 +17,27 @@
17
 
18
  $installer = $this;
19
  $this->startSetup();
20
- /* @var $this Mage_Core_Model_Resource_Setup */
21
- $adapter = $this->getConnection();
22
- $table = $adapter->newTable($this->getTable('avatax_records/log'))
23
- ->addColumn('log_id', Varien_Db_Ddl_Table::TYPE_INTEGER, null, array(
24
- 'identity' => true,
25
- 'nullable' => false,
26
- 'primary' => true,
27
- 'unsigned' => true
28
- ))
29
- ->addColumn('store_id', Varien_Db_Ddl_Table::TYPE_SMALLINT, null, array(
30
- 'unsigned' => true
31
- ))
32
- ->addColumn('level', Varien_Db_Ddl_Table::TYPE_VARCHAR, 50)
33
- ->addColumn('type', Varien_Db_Ddl_Table::TYPE_VARCHAR, 50)
34
- ->addColumn('request', Varien_Db_Ddl_Table::TYPE_TEXT, null)
35
- ->addColumn('result', Varien_Db_Ddl_Table::TYPE_TEXT, null)
36
- ->addColumn('additional', Varien_Db_Ddl_Table::TYPE_TEXT, null)
37
- ->addColumn('created_at', Varien_Db_Ddl_Table::TYPE_DATETIME, null)
38
- ->addForeignKey(
39
- $this->getFkName(
40
- $this->getTable('avatax_records/log'),
41
- 'store_id',
42
- $this->getTable('core/store'),
43
- 'store_id'
44
- ),
45
- 'store_id',
46
- $this->getTable('core/store'),
47
- 'store_id',
48
- Varien_Db_Ddl_Table::ACTION_CASCADE,
49
- Varien_Db_Ddl_Table::ACTION_CASCADE
50
- )
51
- ->addIndex(
52
- $this->getIdxName(
53
- $this->getTable('avatax_records/log'),
54
- array('level'),
55
- Varien_Db_Adapter_Interface::INDEX_TYPE_INDEX
56
- ),
57
- array('level'),
58
- array('type' => Varien_Db_Adapter_Interface::INDEX_TYPE_INDEX)
59
- )
60
- ->addIndex(
61
- $this->getIdxName(
62
- $this->getTable('avatax_records/log'),
63
- array('type'),
64
- Varien_Db_Adapter_Interface::INDEX_TYPE_INDEX
65
- ),
66
- array('type'),
67
- array('type' => Varien_Db_Adapter_Interface::INDEX_TYPE_INDEX)
68
- )
69
- ->addIndex(
70
- $this->getIdxName(
71
- $this->getTable('avatax_records/log'),
72
- array('created_at'),
73
- Varien_Db_Adapter_Interface::INDEX_TYPE_INDEX
74
- ),
75
- array('created_at'),
76
- array('type' => Varien_Db_Adapter_Interface::INDEX_TYPE_INDEX)
77
- )
78
- ->setComment('Used by One Pica AvaTax extension');
79
 
80
- $adapter->createTable($table);
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
81
  $this->endSetup();
17
 
18
  $installer = $this;
19
  $this->startSetup();
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
20
 
21
+ $installer->run("
22
+
23
+ CREATE TABLE `" . $this->getTable('avatax_records/log') . "` (
24
+ `log_id` int(10) unsigned NOT NULL AUTO_INCREMENT,
25
+ `store_id` smallint(5) unsigned DEFAULT NULL,
26
+ `level` varchar(50) DEFAULT NULL,
27
+ `type` varchar(50) DEFAULT NULL,
28
+ `request` text,
29
+ `result` text,
30
+ `additional` text,
31
+ `created_at` datetime DEFAULT NULL,
32
+ PRIMARY KEY (`log_id`),
33
+ KEY `FK_OP_AVATAX_LOG_STORE_ID_CORE_STORE_STORE_ID` (`store_id`),
34
+ KEY `IDX_OP_AVATAX_LOG_LEVEL` (`level`),
35
+ KEY `IDX_OP_AVATAX_LOG_TYPE` (`type`),
36
+ KEY `IDX_OP_AVATAX_LOG_CREATED_AT` (`created_at`),
37
+ CONSTRAINT `FK_OP_AVATAX_LOG_STORE_ID_CORE_STORE_STORE_ID` FOREIGN KEY (`store_id`)
38
+ REFERENCES `" . $this->getTable('core/store') . "` (`store_id`) ON DELETE CASCADE ON UPDATE CASCADE
39
+ ) ENGINE=InnoDB COMMENT='Used by One Pica AvaTax extension';
40
+
41
+ ");
42
+
43
  $this->endSetup();
app/code/community/OnePica/AvaTax/sql/avatax_records_setup/mysql4-upgrade-1.0.1-2.0.0.php CHANGED
@@ -16,107 +16,33 @@
16
  */
17
  $installer = $this;
18
  $this->startSetup();
19
- /* @var $this Mage_Core_Model_Resource_Setup */
20
- $adapter = $this->getConnection();
21
- $table = $adapter->newTable($this->getTable('avatax_records/queue'))
22
- ->addColumn('queue_id', Varien_Db_Ddl_Table::TYPE_INTEGER, null, array(
23
- 'identity' => true,
24
- 'nullable' => false,
25
- 'primary' => true,
26
- 'unsigned' => true
27
- ))
28
- ->addColumn('store_id', Varien_Db_Ddl_Table::TYPE_SMALLINT, null, array(
29
- 'unsigned' => true
30
- ))
31
- ->addColumn('entity_id', Varien_Db_Ddl_Table::TYPE_INTEGER, null, array(
32
- 'unsigned' => true
33
- ))
34
- ->addColumn('entity_increment_id', Varien_Db_Ddl_Table::TYPE_VARCHAR, 50)
35
- ->addColumn('type', Varien_Db_Ddl_Table::TYPE_VARCHAR, 50)
36
- ->addColumn('status', Varien_Db_Ddl_Table::TYPE_VARCHAR, 50)
37
- ->addColumn('attempt', Varien_Db_Ddl_Table::TYPE_SMALLINT, null, array(
38
- 'unsigned' => true,
39
- 'default' => 0
40
- ))
41
- ->addColumn('message', Varien_Db_Ddl_Table::TYPE_VARCHAR, 255)
42
- ->addColumn('created_at', Varien_Db_Ddl_Table::TYPE_DATETIME, null)
43
- ->addColumn('updated_at', Varien_Db_Ddl_Table::TYPE_DATETIME, null)
44
- ->addForeignKey(
45
- $this->getFkName(
46
- $this->getTable('avatax_records/queue'),
47
- 'store_id',
48
- $this->getTable('core/store'),
49
- 'store_id'
50
- ),
51
- 'store_id',
52
- $this->getTable('core/store'),
53
- 'store_id',
54
- Varien_Db_Ddl_Table::ACTION_CASCADE,
55
- Varien_Db_Ddl_Table::ACTION_CASCADE
56
- )
57
- ->addIndex(
58
- $this->getIdxName(
59
- $this->getTable('avatax_records/queue'),
60
- array('entity_id'),
61
- Varien_Db_Adapter_Interface::INDEX_TYPE_INDEX
62
- ),
63
- array('entity_id'),
64
- array('type' => Varien_Db_Adapter_Interface::INDEX_TYPE_INDEX)
65
- )
66
- ->addIndex(
67
- $this->getIdxName(
68
- $this->getTable('avatax_records/queue'),
69
- array('entity_increment_id'),
70
- Varien_Db_Adapter_Interface::INDEX_TYPE_INDEX
71
- ),
72
- array('entity_increment_id'),
73
- array('type' => Varien_Db_Adapter_Interface::INDEX_TYPE_INDEX)
74
- )
75
- ->addIndex(
76
- $this->getIdxName(
77
- $this->getTable('avatax_records/queue'),
78
- array('type'),
79
- Varien_Db_Adapter_Interface::INDEX_TYPE_INDEX
80
- ),
81
- array('type'),
82
- array('type' => Varien_Db_Adapter_Interface::INDEX_TYPE_INDEX)
83
- )
84
- ->addIndex(
85
- $this->getIdxName(
86
- $this->getTable('avatax_records/queue'),
87
- array('status'),
88
- Varien_Db_Adapter_Interface::INDEX_TYPE_INDEX
89
- ),
90
- array('status'),
91
- array('type' => Varien_Db_Adapter_Interface::INDEX_TYPE_INDEX)
92
- )
93
- ->addIndex(
94
- $this->getIdxName(
95
- $this->getTable('avatax_records/queue'),
96
- array('attempt'),
97
- Varien_Db_Adapter_Interface::INDEX_TYPE_INDEX
98
- ),
99
- array('attempt'),
100
- array('type' => Varien_Db_Adapter_Interface::INDEX_TYPE_INDEX)
101
- )
102
- ->addIndex(
103
- $this->getIdxName(
104
- $this->getTable('avatax_records/queue'),
105
- array('created_at'),
106
- Varien_Db_Adapter_Interface::INDEX_TYPE_INDEX
107
- ),
108
- array('created_at'),
109
- array('type' => Varien_Db_Adapter_Interface::INDEX_TYPE_INDEX)
110
- )
111
- ->addIndex(
112
- $this->getIdxName(
113
- $this->getTable('avatax_records/queue'),
114
- array('updated_at'),
115
- Varien_Db_Adapter_Interface::INDEX_TYPE_INDEX
116
- ),
117
- array('updated_at'),
118
- array('type' => Varien_Db_Adapter_Interface::INDEX_TYPE_INDEX)
119
- )
120
- ->setComment('Used by One Pica AvaTax extension');
121
- $adapter->createTable($table);
122
  $this->endSetup();
16
  */
17
  $installer = $this;
18
  $this->startSetup();
19
+
20
+ $installer->run("
21
+
22
+ CREATE TABLE `" . $this->getTable('avatax_records/queue') . "` (
23
+ `queue_id` int(10) unsigned NOT NULL AUTO_INCREMENT,
24
+ `store_id` smallint(5) unsigned DEFAULT NULL,
25
+ `entity_id` int(10) unsigned DEFAULT NULL,
26
+ `entity_increment_id` varchar(50) DEFAULT NULL,
27
+ `type` varchar(50) DEFAULT NULL,
28
+ `status` varchar(50) DEFAULT NULL,
29
+ `attempt` smallint(5) unsigned DEFAULT '0',
30
+ `message` varchar(255) DEFAULT NULL,
31
+ `created_at` datetime DEFAULT NULL,
32
+ `updated_at` datetime DEFAULT NULL,
33
+ PRIMARY KEY (`queue_id`),
34
+ KEY `FK_OP_AVATAX_QUEUE_STORE_ID_CORE_STORE_STORE_ID` (`store_id`),
35
+ KEY `IDX_OP_AVATAX_QUEUE_ENTITY_ID` (`entity_id`),
36
+ KEY `IDX_OP_AVATAX_QUEUE_ENTITY_INCREMENT_ID` (`entity_increment_id`),
37
+ KEY `IDX_OP_AVATAX_QUEUE_TYPE` (`type`),
38
+ KEY `IDX_OP_AVATAX_QUEUE_STATUS` (`status`),
39
+ KEY `IDX_OP_AVATAX_QUEUE_ATTEMPT` (`attempt`),
40
+ KEY `IDX_OP_AVATAX_QUEUE_CREATED_AT` (`created_at`),
41
+ KEY `IDX_OP_AVATAX_QUEUE_UPDATED_AT` (`updated_at`),
42
+ CONSTRAINT `FK_OP_AVATAX_QUEUE_STORE_ID_CORE_STORE_STORE_ID` FOREIGN KEY (`store_id`)
43
+ REFERENCES `" . $this->getTable('core/store') . "` (`store_id`) ON DELETE CASCADE ON UPDATE CASCADE
44
+ ) ENGINE=InnoDB COMMENT='Used by One Pica AvaTax extension';
45
+
46
+ ");
47
+
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
48
  $this->endSetup();
app/code/community/OnePica/AvaTax/sql/avatax_records_setup/mysql4-upgrade-2.5.0.0-2.5.0.1.php CHANGED
@@ -22,285 +22,47 @@ $adapter = $this->getConnection();
22
  // check if current process is install from scratch or update from 2.4.3.3-stable
23
  $queueColumns = array_keys($adapter->describeTable($this->getTable('avatax_records/queue')));
24
  if (!in_array('queue_id', $queueColumns)) {
25
- $adapter
26
- ->modifyColumn(
27
- $this->getTable('avatax_records/log'),
28
- 'log_id',
29
- array(
30
- 'type' => Varien_Db_Ddl_Table::TYPE_INTEGER,
31
- 'identity' => true,
32
- 'nullable' => false,
33
- 'primary' => true,
34
- 'unsigned' => true
35
- )
36
- )
37
- ->modifyColumn(
38
- $this->getTable('avatax_records/log'),
39
- 'store_id',
40
- array(
41
- 'type' => Varien_Db_Ddl_Table::TYPE_SMALLINT,
42
- 'unsigned' => true
43
- )
44
- )
45
- ->modifyColumn(
46
- $this->getTable('avatax_records/log'),
47
- 'level',
48
- array(
49
- 'type' => Varien_Db_Ddl_Table::TYPE_TEXT,
50
- 'length' => 50
51
- )
52
- )
53
- ->modifyColumn(
54
- $this->getTable('avatax_records/log'),
55
- 'type',
56
- array(
57
- 'type' => Varien_Db_Ddl_Table::TYPE_TEXT,
58
- 'length' => 50
59
- )
60
- )
61
- ->modifyColumn(
62
- $this->getTable('avatax_records/log'),
63
- 'request',
64
- array(
65
- 'type' => Varien_Db_Ddl_Table::TYPE_TEXT,
66
- )
67
- )
68
- ->modifyColumn(
69
- $this->getTable('avatax_records/log'),
70
- 'result',
71
- array(
72
- 'type' => Varien_Db_Ddl_Table::TYPE_TEXT,
73
- )
74
- )
75
- ->modifyColumn(
76
- $this->getTable('avatax_records/log'),
77
- 'additional',
78
- array(
79
- 'type' => Varien_Db_Ddl_Table::TYPE_TEXT,
80
- )
81
- )
82
- ->modifyColumn(
83
- $this->getTable('avatax_records/log'),
84
- 'created_at',
85
- array(
86
- 'type' => Varien_Db_Ddl_Table::TYPE_DATETIME,
87
- )
88
- );
89
- $adapter
90
- ->addForeignKey(
91
- $this->getFkName(
92
- $this->getTable('avatax_records/log'),
93
- 'store_id',
94
- $this->getTable('core/store'),
95
- 'store_id'
96
- ),
97
- $this->getTable('avatax_records/log'),
98
- 'store_id',
99
- $this->getTable('core/store'),
100
- 'store_id',
101
- Varien_Db_Ddl_Table::ACTION_CASCADE,
102
- Varien_Db_Ddl_Table::ACTION_CASCADE
103
- );
104
- $adapter->addIndex(
105
- $this->getTable('avatax_records/log'),
106
- $this->getIdxName(
107
- $this->getTable('avatax_records/log'),
108
- array('level'),
109
- Varien_Db_Adapter_Interface::INDEX_TYPE_INDEX
110
- ),
111
- array('level'),
112
- Varien_Db_Adapter_Interface::INDEX_TYPE_INDEX
113
- );
114
- $adapter->addIndex(
115
- $this->getTable('avatax_records/log'),
116
- $this->getIdxName(
117
- $this->getTable('avatax_records/log'),
118
- array('type'),
119
- Varien_Db_Adapter_Interface::INDEX_TYPE_INDEX
120
- ),
121
- array('type'),
122
- Varien_Db_Adapter_Interface::INDEX_TYPE_INDEX
123
- );
124
- $adapter->addIndex(
125
- $this->getTable('avatax_records/log'),
126
- $this->getIdxName(
127
- $this->getTable('avatax_records/log'),
128
- array('created_at'),
129
- Varien_Db_Adapter_Interface::INDEX_TYPE_INDEX
130
- ),
131
- array('created_at'),
132
- Varien_Db_Adapter_Interface::INDEX_TYPE_INDEX
133
- );
134
 
135
- $result = $adapter->changeColumn(
136
- $this->getTable('avatax_records/queue'),
137
- 'id',
138
- 'queue_id',
139
- array(
140
- 'type' => Varien_Db_Ddl_Table::TYPE_INTEGER,
141
- 'identity' => true,
142
- 'nullable' => false,
143
- 'primary' => true,
144
- 'unsigned' => true
145
- )
146
- );
 
 
 
147
 
148
- $adapter
149
- ->modifyColumn(
150
- $this->getTable('avatax_records/queue'),
151
- 'store_id',
152
- array(
153
- 'type' => Varien_Db_Ddl_Table::TYPE_SMALLINT,
154
- 'unsigned' => true
155
- )
156
- )
157
- ->modifyColumn(
158
- $this->getTable('avatax_records/queue'),
159
- 'entity_id',
160
- array(
161
- 'type' => Varien_Db_Ddl_Table::TYPE_INTEGER,
162
- 'unsigned' => true
163
- )
164
- )
165
- ->modifyColumn(
166
- $this->getTable('avatax_records/queue'),
167
- 'entity_increment_id',
168
- array(
169
- 'type' => Varien_Db_Ddl_Table::TYPE_TEXT,
170
- 'length' => 50
171
- )
172
- )
173
- ->modifyColumn(
174
- $this->getTable('avatax_records/queue'),
175
- 'type',
176
- array(
177
- 'type' => Varien_Db_Ddl_Table::TYPE_TEXT,
178
- 'length' => 50
179
- )
180
- )
181
- ->modifyColumn(
182
- $this->getTable('avatax_records/queue'),
183
- 'status',
184
- array(
185
- 'type' => Varien_Db_Ddl_Table::TYPE_TEXT,
186
- 'length' => 50
187
- )
188
- )
189
- ->modifyColumn(
190
- $this->getTable('avatax_records/queue'),
191
- 'attempt',
192
- array(
193
- 'type' => Varien_Db_Ddl_Table::TYPE_SMALLINT,
194
- 'unsigned' => true,
195
- 'default' => 0
196
- )
197
- )
198
- ->modifyColumn(
199
- $this->getTable('avatax_records/queue'),
200
- 'message',
201
- array(
202
- 'type' => Varien_Db_Ddl_Table::TYPE_TEXT,
203
- 'length' => 255
204
- )
205
- )
206
- ->modifyColumn(
207
- $this->getTable('avatax_records/queue'),
208
- 'created_at',
209
- array(
210
- 'type' => Varien_Db_Ddl_Table::TYPE_DATETIME,
211
- )
212
- )
213
- ->modifyColumn(
214
- $this->getTable('avatax_records/queue'),
215
- 'updated_at',
216
- array(
217
- 'type' => Varien_Db_Ddl_Table::TYPE_DATETIME,
218
- )
219
- );
220
- $adapter->addForeignKey(
221
- $this->getFkName(
222
- $this->getTable('avatax_records/queue'),
223
- 'store_id',
224
- $this->getTable('core/store'),
225
- 'store_id'
226
- ),
227
- $this->getTable('avatax_records/queue'),
228
- 'store_id',
229
- $this->getTable('core/store'),
230
- 'store_id',
231
- Varien_Db_Ddl_Table::ACTION_CASCADE,
232
- Varien_Db_Ddl_Table::ACTION_CASCADE
233
- );
234
- $adapter->addIndex(
235
- $this->getTable('avatax_records/queue'),
236
- $this->getIdxName(
237
- $this->getTable('avatax_records/queue'),
238
- array('entity_id'),
239
- Varien_Db_Adapter_Interface::INDEX_TYPE_INDEX
240
- ),
241
- array('entity_id'),
242
- Varien_Db_Adapter_Interface::INDEX_TYPE_INDEX
243
- );
244
- $adapter->addIndex(
245
- $this->getTable('avatax_records/queue'),
246
- $this->getIdxName(
247
- $this->getTable('avatax_records/queue'),
248
- array('entity_increment_id'),
249
- Varien_Db_Adapter_Interface::INDEX_TYPE_INDEX
250
- ),
251
- array('entity_increment_id'),
252
- Varien_Db_Adapter_Interface::INDEX_TYPE_INDEX
253
- );
254
- $adapter->addIndex(
255
- $this->getTable('avatax_records/queue'),
256
- $this->getIdxName(
257
- $this->getTable('avatax_records/queue'),
258
- array('type'),
259
- Varien_Db_Adapter_Interface::INDEX_TYPE_INDEX
260
- ),
261
- array('type'),
262
- Varien_Db_Adapter_Interface::INDEX_TYPE_INDEX
263
- );
264
- $adapter->addIndex(
265
- $this->getTable('avatax_records/queue'),
266
- $this->getIdxName(
267
- $this->getTable('avatax_records/queue'),
268
- array('status'),
269
- Varien_Db_Adapter_Interface::INDEX_TYPE_INDEX
270
- ),
271
- array('status'),
272
- Varien_Db_Adapter_Interface::INDEX_TYPE_INDEX
273
- );
274
- $adapter->addIndex(
275
- $this->getTable('avatax_records/queue'),
276
- $this->getIdxName(
277
- $this->getTable('avatax_records/queue'),
278
- array('attempt'),
279
- Varien_Db_Adapter_Interface::INDEX_TYPE_INDEX
280
- ),
281
- array('attempt'),
282
- Varien_Db_Adapter_Interface::INDEX_TYPE_INDEX
283
- );
284
- $adapter->addIndex(
285
- $this->getTable('avatax_records/queue'),
286
- $this->getIdxName(
287
- $this->getTable('avatax_records/queue'),
288
- array('created_at'),
289
- Varien_Db_Adapter_Interface::INDEX_TYPE_INDEX
290
- ),
291
- array('created_at'),
292
- Varien_Db_Adapter_Interface::INDEX_TYPE_INDEX
293
- );
294
- $adapter->addIndex(
295
- $this->getTable('avatax_records/queue'),
296
- $this->getIdxName(
297
- $this->getTable('avatax_records/queue'),
298
- array('updated_at'),
299
- Varien_Db_Adapter_Interface::INDEX_TYPE_INDEX
300
- ),
301
- array('updated_at'),
302
- Varien_Db_Adapter_Interface::INDEX_TYPE_INDEX
303
- );
304
  }
305
 
306
  $this->endSetup();
22
  // check if current process is install from scratch or update from 2.4.3.3-stable
23
  $queueColumns = array_keys($adapter->describeTable($this->getTable('avatax_records/queue')));
24
  if (!in_array('queue_id', $queueColumns)) {
25
+ $installer->run("
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
26
 
27
+ ALTER TABLE `" . $this->getTable('avatax_records/log') . "`
28
+ CHANGE COLUMN `log_id` `log_id` int(10) unsigned NOT NULL AUTO_INCREMENT,
29
+ CHANGE COLUMN `store_id` `store_id` smallint(5) unsigned DEFAULT NULL,
30
+ CHANGE COLUMN `level` `level` varchar(50) DEFAULT NULL,
31
+ CHANGE COLUMN `type` `type` varchar(50) DEFAULT NULL,
32
+ CHANGE COLUMN `request` `request` text,
33
+ CHANGE COLUMN `result` `result` text,
34
+ CHANGE COLUMN `additional` `additional` text,
35
+ CHANGE COLUMN `created_at` `created_at` datetime DEFAULT NULL,
36
+ ADD KEY `FK_OP_AVATAX_LOG_STORE_ID_CORE_STORE_STORE_ID` (`store_id`),
37
+ ADD KEY `IDX_OP_AVATAX_LOG_LEVEL` (`level`),
38
+ ADD KEY `IDX_OP_AVATAX_LOG_TYPE` (`type`),
39
+ ADD KEY `IDX_OP_AVATAX_LOG_CREATED_AT` (`created_at`),
40
+ ADD CONSTRAINT `FK_OP_AVATAX_LOG_STORE_ID_CORE_STORE_STORE_ID` FOREIGN KEY (`store_id`)
41
+ REFERENCES `" . $this->getTable('core/store') . "` (`store_id`) ON DELETE CASCADE ON UPDATE CASCADE;
42
 
43
+ ALTER TABLE `" . $this->getTable('avatax_records/queue') . "`
44
+ CHANGE COLUMN `id` `queue_id` int(10) unsigned NOT NULL AUTO_INCREMENT,
45
+ CHANGE COLUMN `store_id` `store_id` smallint(5) unsigned DEFAULT NULL,
46
+ CHANGE COLUMN `entity_id` `entity_id` int(10) unsigned DEFAULT NULL,
47
+ CHANGE COLUMN `entity_increment_id` `entity_increment_id` varchar(50) DEFAULT NULL,
48
+ CHANGE COLUMN `type` `type` varchar(50) DEFAULT NULL,
49
+ CHANGE COLUMN `status` `status` varchar(50) DEFAULT NULL,
50
+ CHANGE COLUMN `attempt` `attempt` smallint(5) unsigned DEFAULT '0',
51
+ CHANGE COLUMN `message` `message` varchar(255) DEFAULT NULL,
52
+ CHANGE COLUMN `created_at` `created_at` datetime DEFAULT NULL,
53
+ CHANGE COLUMN `updated_at` `updated_at` datetime DEFAULT NULL,
54
+ ADD KEY `FK_OP_AVATAX_QUEUE_STORE_ID_CORE_STORE_STORE_ID` (`store_id`),
55
+ ADD KEY `IDX_OP_AVATAX_QUEUE_ENTITY_ID` (`entity_id`),
56
+ ADD KEY `IDX_OP_AVATAX_QUEUE_ENTITY_INCREMENT_ID` (`entity_increment_id`),
57
+ ADD KEY `IDX_OP_AVATAX_QUEUE_TYPE` (`type`),
58
+ ADD KEY `IDX_OP_AVATAX_QUEUE_STATUS` (`status`),
59
+ ADD KEY `IDX_OP_AVATAX_QUEUE_ATTEMPT` (`attempt`),
60
+ ADD KEY `IDX_OP_AVATAX_QUEUE_CREATED_AT` (`created_at`),
61
+ ADD KEY `IDX_OP_AVATAX_QUEUE_UPDATED_AT` (`updated_at`),
62
+ ADD CONSTRAINT `FK_OP_AVATAX_QUEUE_STORE_ID_CORE_STORE_STORE_ID` FOREIGN KEY (`store_id`)
63
+ REFERENCES `" . $this->getTable('core/store') . "` (`store_id`) ON DELETE CASCADE ON UPDATE CASCADE;
64
+
65
+ ");
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
66
  }
67
 
68
  $this->endSetup();
app/design/adminhtml/default/default/layout/onepica/avatax.xml CHANGED
File without changes
app/design/adminhtml/default/default/template/onepica/avatax/log/view.phtml CHANGED
@@ -32,19 +32,25 @@
32
  <h4 class="icon-head head-edit-form fieldset-legend"><?php echo $this->__('Request'); ?></h4>
33
  </div>
34
  <div id="log_details_fieldset" class="log-details">
35
- <textarea readonly style="width:100%; height:300px"><?php echo $this->escapeHtml($event->getRequest()); ?></textarea>
 
 
36
  </div>
37
  <div class="entry-edit-head">
38
  <h4 class="icon-head head-edit-form fieldset-legend"><?php echo $this->__('Response'); ?></h4>
39
  </div>
40
  <div id="log_details_fieldset" class="log-details">
41
- <textarea readonly style="width:100%; height:300px"><?php echo $this->escapeHtml($event->getResult()); ?></textarea>
 
 
42
  </div>
43
  <div class="entry-edit-head">
44
  <h4 class="icon-head head-edit-form fieldset-legend"><?php echo $this->__('Additional'); ?></h4>
45
  </div>
46
  <div id="log_details_fieldset" class="log-details">
47
- <textarea readonly style="width:100%; height:300px"><?php echo $this->escapeHtml($event->getAdditional()); ?></textarea>
 
 
48
  </div>
49
  </div>
50
  </div>
32
  <h4 class="icon-head head-edit-form fieldset-legend"><?php echo $this->__('Request'); ?></h4>
33
  </div>
34
  <div id="log_details_fieldset" class="log-details">
35
+ <textarea readonly style="width:100%; height:300px"><?php echo $this->escapeHtml(
36
+ $event->getRequest()
37
+ ); ?></textarea>
38
  </div>
39
  <div class="entry-edit-head">
40
  <h4 class="icon-head head-edit-form fieldset-legend"><?php echo $this->__('Response'); ?></h4>
41
  </div>
42
  <div id="log_details_fieldset" class="log-details">
43
+ <textarea readonly style="width:100%; height:300px"><?php echo $this->escapeHtml(
44
+ $event->getResult()
45
+ ); ?></textarea>
46
  </div>
47
  <div class="entry-edit-head">
48
  <h4 class="icon-head head-edit-form fieldset-legend"><?php echo $this->__('Additional'); ?></h4>
49
  </div>
50
  <div id="log_details_fieldset" class="log-details">
51
+ <textarea readonly style="width:100%; height:300px"><?php echo $this->escapeHtml(
52
+ $event->getAdditional()
53
+ ); ?></textarea>
54
  </div>
55
  </div>
56
  </div>
app/design/adminhtml/default/default/template/onepica/avatax/notification/toolbar.phtml CHANGED
@@ -21,7 +21,9 @@
21
  <?php if ($count):?>
22
  <div class="notification-global">
23
  <?php if ($this->isAllowed()):?>
24
- <span class="f-right"><?php echo $this->__('Go to the <a href="%s">AvaTax Order Sync Queue</a>', $this->getQueueGridUrl());?></span>
 
 
25
  <?php endif;?>
26
  <strong class="label"><?php echo $this->__('AvaTax:');?></strong>
27
  <?php if ($count == 1):?>
21
  <?php if ($count):?>
22
  <div class="notification-global">
23
  <?php if ($this->isAllowed()):?>
24
+ <span class="f-right">
25
+ <?php echo $this->__('Go to the <a href="%s">AvaTax Order Sync Queue</a>', $this->getQueueGridUrl());?>
26
+ </span>
27
  <?php endif;?>
28
  <strong class="label"><?php echo $this->__('AvaTax:');?></strong>
29
  <?php if ($count == 1):?>
app/design/frontend/base/default/layout/onepica/avatax.xml CHANGED
File without changes
app/etc/modules/OnePica_AvaTax.xml CHANGED
File without changes
app/locale/de_DE/OnePica_AvaTax.csv CHANGED
File without changes
app/locale/en_US/OnePica_AvaTax.csv CHANGED
File without changes
app/locale/es_ES/OnePica_AvaTax.csv CHANGED
File without changes
app/locale/fr_FR/OnePica_AvaTax.csv CHANGED
File without changes
app/locale/nl_NL/OnePica_AvaTax.csv CHANGED
File without changes
app/locale/pt_BR/OnePica_AvaTax.csv CHANGED
File without changes
app/locale/zh_CN/OnePica_AvaTax.csv CHANGED
File without changes
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/AvaTax.php RENAMED
@@ -1,96 +1,96 @@
1
- <?php
2
- /**
3
- * AvaTax.php
4
- *
5
- * @package Base
6
- */
7
-
8
- /**
9
- * Defines class loading search path.
10
- */
11
-
12
- function __autoload($class_name)
13
- {
14
-
15
- $path=dirname(__FILE__).'/classes/'.$class_name . '.class.php';
16
-
17
- if(!file_exists($path))
18
- {
19
- $path=dirname(__FILE__).'/classes/BatchSvc/'.$class_name . '.class.php';
20
-
21
- }
22
-
23
- require_once $path;
24
-
25
-
26
- }
27
-
28
- function EnsureIsArray( $obj )
29
- {
30
- if( is_object($obj))
31
- {
32
- $item[0] = $obj;
33
- }
34
- else
35
- {
36
- $item = (array)$obj;
37
- }
38
- return $item;
39
- }
40
-
41
-
42
-
43
- /**
44
- * Takes xml as a string and returns it nicely indented
45
- *
46
- * @param string $xml The xml to beautify
47
- * @param boolean $html_output If the xml should be formatted for display on an html page
48
- * @return string The beautified xml
49
- */
50
-
51
- function xml_pretty_printer($xml, $html_output=FALSE)
52
- {
53
- $xml_obj = new SimpleXMLElement($xml);
54
- $xml_lines = explode("n", $xml_obj->asXML());
55
- $indent_level = 0;
56
-
57
- $new_xml_lines = array();
58
- foreach ($xml_lines as $xml_line) {
59
- if (preg_match('#(<[a-z0-9:-]+((s+[a-z0-9:-]+="[^"]+")*)?>.*<s*/s*[^>]+>)|(<[a-z0-9:-]+((s+[a-z0-9:-]+="[^"]+")*)?s*/s*>)#i', $xml_line)) {
60
- $new_line = str_pad('', $indent_level*4) . $xml_line;
61
- $new_xml_lines[] = $new_line;
62
- } elseif (preg_match('#<[a-z0-9:-]+((s+[a-z0-9:-]+="[^"]+")*)?>#i', $xml_line)) {
63
- $new_line = str_pad('', $indent_level*4) . $xml_line;
64
- $indent_level++;
65
- $new_xml_lines[] = $new_line;
66
- } elseif (preg_match('#<s*/s*[^>/]+>#i', $xml_line)) {
67
- $indent_level--;
68
- if (trim($new_xml_lines[sizeof($new_xml_lines)-1]) == trim(str_replace("/", "", $xml_line))) {
69
- $new_xml_lines[sizeof($new_xml_lines)-1] .= $xml_line;
70
- } else {
71
- $new_line = str_pad('', $indent_level*4) . $xml_line;
72
- $new_xml_lines[] = $new_line;
73
- }
74
- } else {
75
- $new_line = str_pad('', $indent_level*4) . $xml_line;
76
- $new_xml_lines[] = $new_line;
77
- }
78
- }
79
-
80
- $xml = join("n", $new_xml_lines);
81
- return ($html_output) ? '<pre>' . htmlentities($xml) . '</pre>' : $xml;
82
- }
83
-
84
- function getDefaultDate()
85
- {
86
- $dateTime=new DateTime();
87
- $dateTime->setDate(1900,01,01);
88
-
89
- return $dateTime->format("Y-m-d");
90
- }
91
-
92
- function getCurrentDate()
93
- {
94
- $dateTime=new DateTime();
95
- return $dateTime->format("Y-m-d");
96
  }
1
+ <?php
2
+ /**
3
+ * AvaTax.php
4
+ *
5
+ * @package Base
6
+ */
7
+
8
+ /**
9
+ * Defines class loading search path.
10
+ */
11
+
12
+ function __autoload($class_name)
13
+ {
14
+
15
+ $path=dirname(__FILE__).'/classes/'.$class_name . '.class.php';
16
+
17
+ if(!file_exists($path))
18
+ {
19
+ $path=dirname(__FILE__).'/classes/BatchSvc/'.$class_name . '.class.php';
20
+
21
+ }
22
+
23
+ require_once $path;
24
+
25
+
26
+ }
27
+
28
+ function EnsureIsArray( $obj )
29
+ {
30
+ if( is_object($obj))
31
+ {
32
+ $item[0] = $obj;
33
+ }
34
+ else
35
+ {
36
+ $item = (array)$obj;
37
+ }
38
+ return $item;
39
+ }
40
+
41
+
42
+
43
+ /**
44
+ * Takes xml as a string and returns it nicely indented
45
+ *
46
+ * @param string $xml The xml to beautify
47
+ * @param boolean $html_output If the xml should be formatted for display on an html page
48
+ * @return string The beautified xml
49
+ */
50
+
51
+ function xml_pretty_printer($xml, $html_output=FALSE)
52
+ {
53
+ $xml_obj = new SimpleXMLElement($xml);
54
+ $xml_lines = explode("n", $xml_obj->asXML());
55
+ $indent_level = 0;
56
+
57
+ $new_xml_lines = array();
58
+ foreach ($xml_lines as $xml_line) {
59
+ if (preg_match('#(<[a-z0-9:-]+((s+[a-z0-9:-]+="[^"]+")*)?>.*<s*/s*[^>]+>)|(<[a-z0-9:-]+((s+[a-z0-9:-]+="[^"]+")*)?s*/s*>)#i', $xml_line)) {
60
+ $new_line = str_pad('', $indent_level*4) . $xml_line;
61
+ $new_xml_lines[] = $new_line;
62
+ } elseif (preg_match('#<[a-z0-9:-]+((s+[a-z0-9:-]+="[^"]+")*)?>#i', $xml_line)) {
63
+ $new_line = str_pad('', $indent_level*4) . $xml_line;
64
+ $indent_level++;
65
+ $new_xml_lines[] = $new_line;
66
+ } elseif (preg_match('#<s*/s*[^>/]+>#i', $xml_line)) {
67
+ $indent_level--;
68
+ if (trim($new_xml_lines[sizeof($new_xml_lines)-1]) == trim(str_replace("/", "", $xml_line))) {
69
+ $new_xml_lines[sizeof($new_xml_lines)-1] .= $xml_line;
70
+ } else {
71
+ $new_line = str_pad('', $indent_level*4) . $xml_line;
72
+ $new_xml_lines[] = $new_line;
73
+ }
74
+ } else {
75
+ $new_line = str_pad('', $indent_level*4) . $xml_line;
76
+ $new_xml_lines[] = $new_line;
77
+ }
78
+ }
79
+
80
+ $xml = join("n", $new_xml_lines);
81
+ return ($html_output) ? '<pre>' . htmlentities($xml) . '</pre>' : $xml;
82
+ }
83
+
84
+ function getDefaultDate()
85
+ {
86
+ $dateTime=new DateTime();
87
+ $dateTime->setDate(1900,01,01);
88
+
89
+ return $dateTime->format("Y-m-d");
90
+ }
91
+
92
+ function getCurrentDate()
93
+ {
94
+ $dateTime=new DateTime();
95
+ return $dateTime->format("Y-m-d");
96
  }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/ATConfig.class.php RENAMED
@@ -1,67 +1,67 @@
1
- <?php
2
- /**
3
- * ATConfig.class.php
4
- *
5
- * @package Base
6
- */
7
-
8
- /**
9
- * Contains various service configuration parameters as class static variables.
10
- *
11
- * {@link AddressServiceSoap} and {@link TaxServiceSoap} read this file during initialization.
12
- *
13
- * @package Base
14
- */
15
-
16
- class ATConfig
17
- {
18
- private static $Configurations = array();
19
- private $_ivars;
20
-
21
- public function __construct($name, $values = null)
22
- {
23
- if($values)
24
- {
25
- ATConfig::$Configurations[$name] = $values;
26
- }
27
- $this->_ivars = ATConfig::$Configurations[$name];
28
- }
29
-
30
- public function __get($n)
31
- {
32
- if($n == '_ivars') { return parent::__get($n); }
33
- if(isset($this->_ivars[$n]))
34
- {
35
- return $this->_ivars[$n];
36
- }
37
- else if(isset(ATConfig::$Configurations['Default'][$n])) // read missing values from default
38
- {
39
- return ATConfig::$Configurations['Default'][$n];
40
- }
41
- else
42
- {
43
- return null;
44
- }
45
- }
46
- }
47
- /* Specify configurations by name here. You can specify as many as you like */
48
-
49
-
50
- $__wsdldir = dirname(__FILE__)."/wsdl";
51
-
52
- /* This is the default configuration - it is used if no other configuration is specified */
53
- new ATConfig('Default', array(
54
- 'url' => 'no url specified',
55
- 'addressService' => '/Address/AddressSvc.asmx',
56
- 'taxService' => '/Tax/TaxSvc.asmx',
57
- 'batchService'=> '/Batch/BatchSvc.asmx',
58
- 'addressWSDL' => 'file://'.$__wsdldir.'/Address.wsdl',
59
- 'taxWSDL' => 'file://'.$__wsdldir.'/Tax.wsdl',
60
- 'batchWSDL' => 'file://'.$__wsdldir.'/BatchSvc.wsdl',
61
- 'account' => '<your account number here>',
62
- 'license' => '<your license key here>',
63
- 'adapter' => 'avatax4php,5.7.3.0',
64
- 'client' => 'AvalaraPHPInterface,1.0',
65
- 'name' => 'PHPAdapter',
66
- 'trace' => true) // change to false for production
67
- );
1
+ <?php
2
+ /**
3
+ * ATConfig.class.php
4
+ *
5
+ * @package Base
6
+ */
7
+
8
+ /**
9
+ * Contains various service configuration parameters as class static variables.
10
+ *
11
+ * {@link AddressServiceSoap} and {@link TaxServiceSoap} read this file during initialization.
12
+ *
13
+ * @package Base
14
+ */
15
+
16
+ class ATConfig
17
+ {
18
+ private static $Configurations = array();
19
+ private $_ivars;
20
+
21
+ public function __construct($name, $values = null)
22
+ {
23
+ if($values)
24
+ {
25
+ ATConfig::$Configurations[$name] = $values;
26
+ }
27
+ $this->_ivars = ATConfig::$Configurations[$name];
28
+ }
29
+
30
+ public function __get($n)
31
+ {
32
+ if($n == '_ivars') { return parent::__get($n); }
33
+ if(isset($this->_ivars[$n]))
34
+ {
35
+ return $this->_ivars[$n];
36
+ }
37
+ else if(isset(ATConfig::$Configurations['Default'][$n])) // read missing values from default
38
+ {
39
+ return ATConfig::$Configurations['Default'][$n];
40
+ }
41
+ else
42
+ {
43
+ return null;
44
+ }
45
+ }
46
+ }
47
+ /* Specify configurations by name here. You can specify as many as you like */
48
+
49
+
50
+ $__wsdldir = dirname(__FILE__)."/wsdl";
51
+
52
+ /* This is the default configuration - it is used if no other configuration is specified */
53
+ new ATConfig('Default', array(
54
+ 'url' => 'no url specified',
55
+ 'addressService' => '/Address/AddressSvc.asmx',
56
+ 'taxService' => '/Tax/TaxSvc.asmx',
57
+ 'batchService'=> '/Batch/BatchSvc.asmx',
58
+ 'addressWSDL' => 'file://'.$__wsdldir.'/Address.wsdl',
59
+ 'taxWSDL' => 'file://'.$__wsdldir.'/Tax.wsdl',
60
+ 'batchWSDL' => 'file://'.$__wsdldir.'/BatchSvc.wsdl',
61
+ 'account' => '<your account number here>',
62
+ 'license' => '<your license key here>',
63
+ 'adapter' => 'avatax4php,5.7.3.0',
64
+ 'client' => 'AvalaraPHPInterface,1.0',
65
+ 'name' => 'PHPAdapter',
66
+ 'trace' => true) // change to false for production
67
+ );
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/ATObject.class.php RENAMED
@@ -1,53 +1,53 @@
1
- <?php
2
- /**
3
- * ATObject.class.php
4
- *
5
- * @package Base
6
- */
7
-
8
- /**
9
- * Generic Dynamic Object
10
- *
11
- * @package Base
12
- */
13
- class ATObject
14
- {
15
- private $_ivars = array();
16
- public function __get($n)
17
- {
18
- if(isset($this->_ivars[$n]))
19
- {
20
- return $this->_ivars[$n];
21
- }
22
- else
23
- {
24
- return null;
25
- }
26
- }
27
- public function __set($n,$v)
28
- {
29
- if($v == null)
30
- {
31
- unset($this->_ivars[$n]);
32
- }
33
- else
34
- {
35
- $this->_ivars[$n] = $v;
36
- }
37
- }
38
- public function __isset($n) { return isset($ivars[$n]); }
39
- public function __unset($n) { unset($this->_ivars[$n]); }
40
- public function __call($n,$args)
41
- {
42
- if(sizeof($args) == 1)
43
- {
44
- $this->__set($n,$args[0]);
45
- return null;
46
- }
47
- else if(sizeof($args) == 0)
48
- {
49
- return $this->__get($n);
50
- }
51
- }
52
- public function ivars() { return $this->_ivars; }
53
  }
1
+ <?php
2
+ /**
3
+ * ATObject.class.php
4
+ *
5
+ * @package Base
6
+ */
7
+
8
+ /**
9
+ * Generic Dynamic Object
10
+ *
11
+ * @package Base
12
+ */
13
+ class ATObject
14
+ {
15
+ private $_ivars = array();
16
+ public function __get($n)
17
+ {
18
+ if(isset($this->_ivars[$n]))
19
+ {
20
+ return $this->_ivars[$n];
21
+ }
22
+ else
23
+ {
24
+ return null;
25
+ }
26
+ }
27
+ public function __set($n,$v)
28
+ {
29
+ if($v == null)
30
+ {
31
+ unset($this->_ivars[$n]);
32
+ }
33
+ else
34
+ {
35
+ $this->_ivars[$n] = $v;
36
+ }
37
+ }
38
+ public function __isset($n) { return isset($ivars[$n]); }
39
+ public function __unset($n) { unset($this->_ivars[$n]); }
40
+ public function __call($n,$args)
41
+ {
42
+ if(sizeof($args) == 1)
43
+ {
44
+ $this->__set($n,$args[0]);
45
+ return null;
46
+ }
47
+ else if(sizeof($args) == 0)
48
+ {
49
+ return $this->__get($n);
50
+ }
51
+ }
52
+ public function ivars() { return $this->_ivars; }
53
  }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/AVObject.class.php RENAMED
File without changes
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/Address.class.php RENAMED
@@ -1,227 +1,227 @@
1
- <?php
2
- /**
3
- * Address.class.php
4
- *
5
- * @package Address
6
- */
7
-
8
- /**
9
- * Contains address data; Can be passed to {@link AddressServiceSoap#validate};
10
- * Also part of the {@link GetTaxRequest}
11
- * result returned from the {@link TaxServiceSoap#getTax} tax calculation service;
12
- * No behavior - basically a glorified struct.
13
- *
14
- * <b>Example:</b>
15
- * <pre>
16
- * $port = new AddressServiceSoap();
17
- *
18
- * $address = new Address();
19
- * $address->setLine1("900 Winslow Way");
20
- * $address->setLine2("Suite 130");
21
- * $address->setCity("Bainbridge Is");
22
- * $address->setRegion("WA");
23
- * $address->setPostalCode("98110-2450");
24
- *
25
- * $result = $port->validate($address,TextCase::$Upper);
26
- * $addresses = $result->ValidAddresses;
27
- * print("Number of addresses returned is ". sizseof($addresses));
28
- *
29
- * </pre>
30
- * @package Address
31
- * @author tblanchard
32
- * Copyright (c) 2007, Avalara. All rights reserved.
33
- */
34
-
35
- class Address
36
- {
37
-
38
- private $AddressCode;
39
- private $Line1;
40
- private $Line2;
41
- private $Line3;
42
- private $City;
43
- private $Region;
44
- private $PostalCode;
45
- private $Country = 'USA';
46
- private $TaxRegionId = 0;
47
-
48
- /**
49
- * Construct a new Address.
50
- *
51
- * Constructs a new instance of Address.
52
- * <pre>
53
- * $address = new Address();
54
- * </pre>
55
- *
56
- * @param string $line1
57
- * @param string $line2
58
- * @param string $line3
59
- * @param string $city
60
- * @param string $region
61
- * @param string $postalCode
62
- * @param string $country
63
- * @param integer $taxRegionId
64
- */
65
-
66
- public function __construct($line1=null,$line2=null,$line3=null,$city=null,$region=null,$postalCode=null,$country='USA',$taxRegionId=0)
67
- {
68
- $this->Line1 = $line1;
69
- $this->Line2 = $line2;
70
- $this->Line3 = $line3;
71
- $this->City = $city;
72
- $this->Region = $region;
73
- $this->PostalCode = $postalCode;
74
- $this->Country = $country;
75
- $this->TaxRegionId = $taxRegionId;
76
- }
77
-
78
- /**
79
- * Programmatically determined value used internally by the adapter.
80
- *
81
- * @param string $value
82
- *
83
- */
84
- public function setAddressCode($value) { $this->AddressCode = $value; }
85
-
86
- /**
87
- * Address line 1
88
- *
89
- * @param string $value
90
- */
91
- public function setLine1($value) { $this->Line1 = $value; }
92
-
93
- /**
94
- * Address line 2
95
- *
96
- * @param string $value
97
- */
98
- public function setLine2($value) { $this->Line2 = $value; }
99
-
100
- /**
101
- * Address line 3
102
- *
103
- * @param string $value
104
- */
105
- public function setLine3($value) { $this->Line3 = $value; }
106
-
107
- /**
108
- * City name
109
- *
110
- * @param string $value
111
- */
112
- public function setCity($value) { $this->City = $value; }
113
-
114
- /**
115
- * State or province name or abbreviation
116
- *
117
- * @param string $value
118
- */
119
- public function setRegion($value) { $this->Region = $value; }
120
-
121
- /**
122
- * Postal or ZIP code
123
- *
124
- * @param string $value
125
- */
126
- public function setPostalCode($value) { $this->PostalCode = $value; }
127
-
128
- /**
129
- * Country name
130
- *
131
- * @param string $value
132
- */
133
- public function setCountry($value) { $this->Country = $value; }
134
-
135
-
136
- /**
137
- * TaxRegionId provides the ability to override the tax region assignment for an address.
138
- *
139
- * @param string $value
140
- */
141
- public function setTaxRegionId($value) { $this->TaxRegionId = $value; }
142
-
143
- /**
144
- * Programmatically determined value used internally by the adapter.
145
- *
146
- * @return string $value
147
- */
148
- public function getAddressCode() { return $this->AddressCode; }
149
-
150
- /**
151
- * Address line 1
152
- *
153
- * @return string $value
154
- */
155
- public function getLine1() { return $this->Line1; }
156
-
157
- /**
158
- * Address line 2
159
- *
160
- * @return string $value
161
- */
162
- public function getLine2() { return $this->Line2; }
163
-
164
- /**
165
- * Address line 3
166
- *
167
- * @return string $value
168
- */
169
- public function getLine3() { return $this->Line3; }
170
-
171
- /**
172
- * City name
173
- *
174
- * @return string $value
175
- */
176
- public function getCity() { return $this->City; }
177
-
178
- /**
179
- * State or province name or abbreviation
180
- *
181
- * @return string $value
182
- */
183
- public function getRegion() { return $this->Region; }
184
-
185
- /**
186
- * Postal or ZIP code
187
- *
188
- * @return string $value
189
- */
190
- public function getPostalCode() { return $this->PostalCode; }
191
-
192
- /**
193
- * Country name
194
- *
195
- * @return string $value
196
- */
197
- public function getCountry() { return $this->AddressCode; }
198
-
199
- /**
200
- * TaxRegionId provides the ability to override the tax region assignment for an address.
201
- *
202
- * @return string $value
203
- */
204
- public function getTaxRegionId() { return $this->TaxRegionId; }
205
-
206
-
207
- /**
208
- * Compares Addresses
209
- * @access public
210
- * @param Address
211
- * @return boolean
212
- */
213
- public function equals(&$other) // fix me after replace
214
- {
215
- return $this === $other || (
216
- strcmp($this->AddressCode , $other->AddressCode) == 0 &&
217
- strcmp($this->Line1 , $other->Line1) == 0 &&
218
- strcmp($this->Line2 , $other->Line2) == 0 &&
219
- strcmp($this->Line3 , $other->Line3) == 0 &&
220
- strcmp($this->City , $other->City) == 0 &&
221
- strcmp($this->Region , $other->Region) == 0 &&
222
- strcmp($this->PostalCode , $other->PostalCode) == 0 &&
223
- strcmp($this->Country , $other->Country) == 0 &&
224
- $this->TaxRegionId === $other->TaxRegionId
225
- );
226
- }
227
  }
1
+ <?php
2
+ /**
3
+ * Address.class.php
4
+ *
5
+ * @package Address
6
+ */
7
+
8
+ /**
9
+ * Contains address data; Can be passed to {@link AddressServiceSoap#validate};
10
+ * Also part of the {@link GetTaxRequest}
11
+ * result returned from the {@link TaxServiceSoap#getTax} tax calculation service;
12
+ * No behavior - basically a glorified struct.
13
+ *
14
+ * <b>Example:</b>
15
+ * <pre>
16
+ * $port = new AddressServiceSoap();
17
+ *
18
+ * $address = new Address();
19
+ * $address->setLine1("900 Winslow Way");
20
+ * $address->setLine2("Suite 130");
21
+ * $address->setCity("Bainbridge Is");
22
+ * $address->setRegion("WA");
23
+ * $address->setPostalCode("98110-2450");
24
+ *
25
+ * $result = $port->validate($address,TextCase::$Upper);
26
+ * $addresses = $result->ValidAddresses;
27
+ * print("Number of addresses returned is ". sizseof($addresses));
28
+ *
29
+ * </pre>
30
+ * @package Address
31
+ * @author tblanchard
32
+ * Copyright (c) 2007, Avalara. All rights reserved.
33
+ */
34
+
35
+ class Address
36
+ {
37
+
38
+ private $AddressCode;
39
+ private $Line1;
40
+ private $Line2;
41
+ private $Line3;
42
+ private $City;
43
+ private $Region;
44
+ private $PostalCode;
45
+ private $Country = 'USA';
46
+ private $TaxRegionId = 0;
47
+
48
+ /**
49
+ * Construct a new Address.
50
+ *
51
+ * Constructs a new instance of Address.
52
+ * <pre>
53
+ * $address = new Address();
54
+ * </pre>
55
+ *
56
+ * @param string $line1
57
+ * @param string $line2
58
+ * @param string $line3
59
+ * @param string $city
60
+ * @param string $region
61
+ * @param string $postalCode
62
+ * @param string $country
63
+ * @param integer $taxRegionId
64
+ */
65
+
66
+ public function __construct($line1=null,$line2=null,$line3=null,$city=null,$region=null,$postalCode=null,$country='USA',$taxRegionId=0)
67
+ {
68
+ $this->Line1 = $line1;
69
+ $this->Line2 = $line2;
70
+ $this->Line3 = $line3;
71
+ $this->City = $city;
72
+ $this->Region = $region;
73
+ $this->PostalCode = $postalCode;
74
+ $this->Country = $country;
75
+ $this->TaxRegionId = $taxRegionId;
76
+ }
77
+
78
+ /**
79
+ * Programmatically determined value used internally by the adapter.
80
+ *
81
+ * @param string $value
82
+ *
83
+ */
84
+ public function setAddressCode($value) { $this->AddressCode = $value; }
85
+
86
+ /**
87
+ * Address line 1
88
+ *
89
+ * @param string $value
90
+ */
91
+ public function setLine1($value) { $this->Line1 = $value; }
92
+
93
+ /**
94
+ * Address line 2
95
+ *
96
+ * @param string $value
97
+ */
98
+ public function setLine2($value) { $this->Line2 = $value; }
99
+
100
+ /**
101
+ * Address line 3
102
+ *
103
+ * @param string $value
104
+ */
105
+ public function setLine3($value) { $this->Line3 = $value; }
106
+
107
+ /**
108
+ * City name
109
+ *
110
+ * @param string $value
111
+ */
112
+ public function setCity($value) { $this->City = $value; }
113
+
114
+ /**
115
+ * State or province name or abbreviation
116
+ *
117
+ * @param string $value
118
+ */
119
+ public function setRegion($value) { $this->Region = $value; }
120
+
121
+ /**
122
+ * Postal or ZIP code
123
+ *
124
+ * @param string $value
125
+ */
126
+ public function setPostalCode($value) { $this->PostalCode = $value; }
127
+
128
+ /**
129
+ * Country name
130
+ *
131
+ * @param string $value
132
+ */
133
+ public function setCountry($value) { $this->Country = $value; }
134
+
135
+
136
+ /**
137
+ * TaxRegionId provides the ability to override the tax region assignment for an address.
138
+ *
139
+ * @param string $value
140
+ */
141
+ public function setTaxRegionId($value) { $this->TaxRegionId = $value; }
142
+
143
+ /**
144
+ * Programmatically determined value used internally by the adapter.
145
+ *
146
+ * @return string $value
147
+ */
148
+ public function getAddressCode() { return $this->AddressCode; }
149
+
150
+ /**
151
+ * Address line 1
152
+ *
153
+ * @return string $value
154
+ */
155
+ public function getLine1() { return $this->Line1; }
156
+
157
+ /**
158
+ * Address line 2
159
+ *
160
+ * @return string $value
161
+ */
162
+ public function getLine2() { return $this->Line2; }
163
+
164
+ /**
165
+ * Address line 3
166
+ *
167
+ * @return string $value
168
+ */
169
+ public function getLine3() { return $this->Line3; }
170
+
171
+ /**
172
+ * City name
173
+ *
174
+ * @return string $value
175
+ */
176
+ public function getCity() { return $this->City; }
177
+
178
+ /**
179
+ * State or province name or abbreviation
180
+ *
181
+ * @return string $value
182
+ */
183
+ public function getRegion() { return $this->Region; }
184
+
185
+ /**
186
+ * Postal or ZIP code
187
+ *
188
+ * @return string $value
189
+ */
190
+ public function getPostalCode() { return $this->PostalCode; }
191
+
192
+ /**
193
+ * Country name
194
+ *
195
+ * @return string $value
196
+ */
197
+ public function getCountry() { return $this->AddressCode; }
198
+
199
+ /**
200
+ * TaxRegionId provides the ability to override the tax region assignment for an address.
201
+ *
202
+ * @return string $value
203
+ */
204
+ public function getTaxRegionId() { return $this->TaxRegionId; }
205
+
206
+
207
+ /**
208
+ * Compares Addresses
209
+ * @access public
210
+ * @param Address
211
+ * @return boolean
212
+ */
213
+ public function equals(&$other) // fix me after replace
214
+ {
215
+ return $this === $other || (
216
+ strcmp($this->AddressCode , $other->AddressCode) == 0 &&
217
+ strcmp($this->Line1 , $other->Line1) == 0 &&
218
+ strcmp($this->Line2 , $other->Line2) == 0 &&
219
+ strcmp($this->Line3 , $other->Line3) == 0 &&
220
+ strcmp($this->City , $other->City) == 0 &&
221
+ strcmp($this->Region , $other->Region) == 0 &&
222
+ strcmp($this->PostalCode , $other->PostalCode) == 0 &&
223
+ strcmp($this->Country , $other->Country) == 0 &&
224
+ $this->TaxRegionId === $other->TaxRegionId
225
+ );
226
+ }
227
  }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/AddressServiceSoap.class.php RENAMED
@@ -1,153 +1,153 @@
1
- <?php
2
-
3
- /**
4
- * AddressServiceSoap.class.php
5
- *
6
- * Proxy for Avalara Address Service.
7
- *
8
- * @package Address
9
- */
10
-
11
- /**
12
- * Proxy interface for the Avalara Address Web Service.
13
- *
14
- * AddressServiceSoap reads its configuration values from static variables defined
15
- * in ATConfig.class.php. This file must be properly configured with your security credentials.
16
- *
17
- * <p>
18
- * <b>Example:</b>
19
- * <pre>
20
- * $addressService = new AddressServiceSoap();
21
- * </pre>
22
- *
23
- * @package Address
24
- * @author tblanchard
25
- * Copyright (c) 2007, Avalara. All rights reserved.
26
- */
27
-
28
- class AddressServiceSoap extends AvalaraSoapClient
29
- {
30
- static private $servicePath = '/Address/AddressSvc.asmx';
31
- static protected $classmap = array(
32
- 'Validate' => 'Validate',
33
- 'BaseRequest' => 'BaseRequest',
34
- 'ValidateRequest' => 'ValidateRequest',
35
- 'BaseAddress' => 'BaseAddress',
36
- 'ValidAddress' => 'ValidAddress',
37
- 'TextCase' => 'TextCase',
38
- 'ValidateResult' => 'ValidateResult',
39
- 'BaseResult' => 'BaseResult',
40
- 'SeverityLevel' => 'SeverityLevel',
41
- 'Message' => 'Message',
42
- 'Profile' => 'Profile',
43
- 'Ping' => 'Ping',
44
- 'PingResult' => 'PingResult',
45
- 'IsAuthorized' => 'IsAuthorized',
46
- 'IsAuthorizedResult' => 'IsAuthorizedResult');
47
-
48
- /**
49
- * Construct a proxy for Avalara's Address Web Service using the default URL as coded in the class or programatically set.
50
- *
51
- * <b>Example:</b>
52
- * <pre>
53
- * $port = new AddressServiceSoap();
54
- * $port->ping();
55
- * </pre>
56
- *
57
- * @see AvalaraSoapClient
58
- * @see TaxServiceSoap
59
- */
60
-
61
- public function __construct($configurationName = 'Default')
62
- {
63
- $config = new ATConfig($configurationName);
64
- $this->client = new DynamicSoapClient (
65
- $config->addressWSDL,
66
- array
67
- (
68
- 'location' => $config->url.$config->addressService,
69
- 'trace' => $config->trace,
70
- 'classmap' => AddressServiceSoap::$classmap
71
- ),
72
- $config
73
- );
74
- }
75
-
76
- /**
77
- * Checks authentication of and authorization to one or more
78
- * operations on the service.
79
- *
80
- * This operation allows pre-authorization checking of any
81
- * or all operations. It will return a comma delimited set of
82
- * operation names which will be all or a subset of the requested
83
- * operation names. For security, it will never return operation
84
- * names other than those requested (no phishing allowed).
85
- *
86
- * <b>Example:</b><br>
87
- * <code> isAuthorized("GetTax,PostTax")</code>
88
- *
89
- * @param string $operations a comma-delimited list of operation names
90
- *
91
- * @return IsAuthorizedResult
92
- * @throws SoapFault
93
- */
94
-
95
- public function isAuthorized($operations)
96
- {
97
- return $this->client->IsAuthorized(array('Operations' => $operations))->IsAuthorizedResult;
98
- }
99
-
100
- /**
101
- * Verifies connectivity to the web service and returns version
102
- * information about the service.
103
- *
104
- * <b>NOTE:</b>This replaces TestConnection and is available on
105
- * every service.
106
- *
107
- * @param string $message for future use
108
- * @return PingResult
109
- * @throws SoapFault
110
- */
111
-
112
- public function ping($message = '')
113
- {
114
- return $this->client->Ping(array('Message' => $message))->PingResult;
115
- }
116
-
117
- /**
118
- * Validates an address and returns a collection of possible
119
- * {@link ValidAddress} objects in a {@link ValidateResult} object.
120
- *
121
- * Takes an {@link Address}, an optional {@link TextCase}
122
- * property that determines the casing applied to a validated
123
- * address. It defaults to TextCase::$Default.
124
- * <b>Example:</b><br>
125
- * <pre>
126
- * $port = new AddressServiceSoap();
127
- *
128
- * $address = new Address();
129
- * $address->setLine1("900 Winslow Way");
130
- * $address->setLine2("Suite 130");
131
- * $address->setCity("Bainbridge Is");
132
- * $address->setRegion("WA");
133
- * $address->setPostalCode("98110-2450");
134
- *
135
- * $result = $port->validate(new ValidateRequest($address,TextCase::$Upper));
136
- * $addresses = $result->validAddresses();
137
- * print('Number of addresses returned is: '.sizeof($addresses));
138
- * </pre>
139
- *
140
- * @param ValidateRequest
141
- * @return ValidateResult
142
- *
143
- * @throws SoapFault
144
- */
145
-
146
-
147
- public function validate($validateRequest)
148
- {
149
- return $this->client->Validate(array('ValidateRequest' => $validateRequest))->ValidateResult;
150
- }
151
-
152
-
153
- }
1
+ <?php
2
+
3
+ /**
4
+ * AddressServiceSoap.class.php
5
+ *
6
+ * Proxy for Avalara Address Service.
7
+ *
8
+ * @package Address
9
+ */
10
+
11
+ /**
12
+ * Proxy interface for the Avalara Address Web Service.
13
+ *
14
+ * AddressServiceSoap reads its configuration values from static variables defined
15
+ * in ATConfig.class.php. This file must be properly configured with your security credentials.
16
+ *
17
+ * <p>
18
+ * <b>Example:</b>
19
+ * <pre>
20
+ * $addressService = new AddressServiceSoap();
21
+ * </pre>
22
+ *
23
+ * @package Address
24
+ * @author tblanchard
25
+ * Copyright (c) 2007, Avalara. All rights reserved.
26
+ */
27
+
28
+ class AddressServiceSoap extends AvalaraSoapClient
29
+ {
30
+ static private $servicePath = '/Address/AddressSvc.asmx';
31
+ static protected $classmap = array(
32
+ 'Validate' => 'Validate',
33
+ 'BaseRequest' => 'BaseRequest',
34
+ 'ValidateRequest' => 'ValidateRequest',
35
+ 'BaseAddress' => 'BaseAddress',
36
+ 'ValidAddress' => 'ValidAddress',
37
+ 'TextCase' => 'TextCase',
38
+ 'ValidateResult' => 'ValidateResult',
39
+ 'BaseResult' => 'BaseResult',
40
+ 'SeverityLevel' => 'SeverityLevel',
41
+ 'Message' => 'Message',
42
+ 'Profile' => 'Profile',
43
+ 'Ping' => 'Ping',
44
+ 'PingResult' => 'PingResult',
45
+ 'IsAuthorized' => 'IsAuthorized',
46
+ 'IsAuthorizedResult' => 'IsAuthorizedResult');
47
+
48
+ /**
49
+ * Construct a proxy for Avalara's Address Web Service using the default URL as coded in the class or programatically set.
50
+ *
51
+ * <b>Example:</b>
52
+ * <pre>
53
+ * $port = new AddressServiceSoap();
54
+ * $port->ping();
55
+ * </pre>
56
+ *
57
+ * @see AvalaraSoapClient
58
+ * @see TaxServiceSoap
59
+ */
60
+
61
+ public function __construct($configurationName = 'Default')
62
+ {
63
+ $config = new ATConfig($configurationName);
64
+ $this->client = new DynamicSoapClient (
65
+ $config->addressWSDL,
66
+ array
67
+ (
68
+ 'location' => $config->url.$config->addressService,
69
+ 'trace' => $config->trace,
70
+ 'classmap' => AddressServiceSoap::$classmap
71
+ ),
72
+ $config
73
+ );
74
+ }
75
+
76
+ /**
77
+ * Checks authentication of and authorization to one or more
78
+ * operations on the service.
79
+ *
80
+ * This operation allows pre-authorization checking of any
81
+ * or all operations. It will return a comma delimited set of
82
+ * operation names which will be all or a subset of the requested
83
+ * operation names. For security, it will never return operation
84
+ * names other than those requested (no phishing allowed).
85
+ *
86
+ * <b>Example:</b><br>
87
+ * <code> isAuthorized("GetTax,PostTax")</code>
88
+ *
89
+ * @param string $operations a comma-delimited list of operation names
90
+ *
91
+ * @return IsAuthorizedResult
92
+ * @throws SoapFault
93
+ */
94
+
95
+ public function isAuthorized($operations)
96
+ {
97
+ return $this->client->IsAuthorized(array('Operations' => $operations))->IsAuthorizedResult;
98
+ }
99
+
100
+ /**
101
+ * Verifies connectivity to the web service and returns version
102
+ * information about the service.
103
+ *
104
+ * <b>NOTE:</b>This replaces TestConnection and is available on
105
+ * every service.
106
+ *
107
+ * @param string $message for future use
108
+ * @return PingResult
109
+ * @throws SoapFault
110
+ */
111
+
112
+ public function ping($message = '')
113
+ {
114
+ return $this->client->Ping(array('Message' => $message))->PingResult;
115
+ }
116
+
117
+ /**
118
+ * Validates an address and returns a collection of possible
119
+ * {@link ValidAddress} objects in a {@link ValidateResult} object.
120
+ *
121
+ * Takes an {@link Address}, an optional {@link TextCase}
122
+ * property that determines the casing applied to a validated
123
+ * address. It defaults to TextCase::$Default.
124
+ * <b>Example:</b><br>
125
+ * <pre>
126
+ * $port = new AddressServiceSoap();
127
+ *
128
+ * $address = new Address();
129
+ * $address->setLine1("900 Winslow Way");
130
+ * $address->setLine2("Suite 130");
131
+ * $address->setCity("Bainbridge Is");
132
+ * $address->setRegion("WA");
133
+ * $address->setPostalCode("98110-2450");
134
+ *
135
+ * $result = $port->validate(new ValidateRequest($address,TextCase::$Upper));
136
+ * $addresses = $result->validAddresses();
137
+ * print('Number of addresses returned is: '.sizeof($addresses));
138
+ * </pre>
139
+ *
140
+ * @param ValidateRequest
141
+ * @return ValidateResult
142
+ *
143
+ * @throws SoapFault
144
+ */
145
+
146
+
147
+ public function validate($validateRequest)
148
+ {
149
+ return $this->client->Validate(array('ValidateRequest' => $validateRequest))->ValidateResult;
150
+ }
151
+
152
+
153
+ }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/AddressType.class.php RENAMED
@@ -1,38 +1,38 @@
1
- <?php
2
- /**
3
- * AddressType.class.php
4
- * @package Address
5
- */
6
-
7
- /**
8
- * The type of the address(es) returned in the validation result.
9
- *
10
- * @package Address
11
- * @author tblanchard
12
- * Copyright (c) 2007, Avalara. All rights reserved.
13
- */
14
-
15
- class AddressType extends Enum
16
- {
17
- public static $FirmOrCompany = 'F';
18
- public static $GeneralDelivery = 'G';
19
- public static $HighRise = 'H';
20
- public static $POBox = 'P';
21
- public static $RuralRoute = 'R';
22
- public static $StreetOrResidential = 'S';
23
-
24
- public static function Values()
25
- {
26
- return array(
27
- 'FirmOrCompany' => AddressType::$FirmOrCompany,
28
- 'GeneralDelivery' => AddressType::$GeneralDelivery,
29
- 'HighRise' => AddressType::$HighRise,
30
- 'POBox' => AddressType::$POBox,
31
- 'RuralRoute' => AddressType::$RuralRoute,
32
- 'StreetOrResidential' => AddressType::$StreetOrResidential
33
- );
34
- }
35
-
36
- // Unfortunate boiler plate due to polymorphism issues on static functions
37
- public static function Validate($value) { self::__Validate($value,self::Values(),__CLASS__); }
38
- }
1
+ <?php
2
+ /**
3
+ * AddressType.class.php
4
+ * @package Address
5
+ */
6
+
7
+ /**
8
+ * The type of the address(es) returned in the validation result.
9
+ *
10
+ * @package Address
11
+ * @author tblanchard
12
+ * Copyright (c) 2007, Avalara. All rights reserved.
13
+ */
14
+
15
+ class AddressType extends Enum
16
+ {
17
+ public static $FirmOrCompany = 'F';
18
+ public static $GeneralDelivery = 'G';
19
+ public static $HighRise = 'H';
20
+ public static $POBox = 'P';
21
+ public static $RuralRoute = 'R';
22
+ public static $StreetOrResidential = 'S';
23
+
24
+ public static function Values()
25
+ {
26
+ return array(
27
+ 'FirmOrCompany' => AddressType::$FirmOrCompany,
28
+ 'GeneralDelivery' => AddressType::$GeneralDelivery,
29
+ 'HighRise' => AddressType::$HighRise,
30
+ 'POBox' => AddressType::$POBox,
31
+ 'RuralRoute' => AddressType::$RuralRoute,
32
+ 'StreetOrResidential' => AddressType::$StreetOrResidential
33
+ );
34
+ }
35
+
36
+ // Unfortunate boiler plate due to polymorphism issues on static functions
37
+ public static function Validate($value) { self::__Validate($value,self::Values(),__CLASS__); }
38
+ }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/AdjustTaxRequest.class.php RENAMED
@@ -1,75 +1,75 @@
1
- <?php
2
- /**
3
- * AdjustTaxRequest.class.php
4
- * @package Tax
5
- */
6
-
7
- /**
8
- * Data to pass to {@link TaxServiceSoap#adjustTax}.
9
- *
10
- * @see AdjustTaxRequest
11
- * @package Tax
12
- * @author tblanchard
13
- * Copyright (c) 2008, Avalara. All rights reserved.
14
- */
15
-
16
-
17
-
18
- class AdjustTaxRequest
19
- {
20
- private $AdjustmentReason; //int
21
- private $AdjustmentDescription; //string
22
- private $GetTaxRequest; //string
23
-
24
-
25
- /**
26
- * Adjustment Description is required when AdjustmentReason is "Other" for enhanced tracability.
27
- *
28
- * @param string $value
29
- */
30
- public function setAdjustmentDescription($value) { $this->AdjustmentDescription = $value; }
31
-
32
-
33
-
34
- /**
35
- * Reason for Adjusting document.
36
- * <pre>
37
- * Sets a valid reason for the given AdjustTax call. Adjustment Reason is a high level classification of why an Original Document is being modified.
38
- * 0 Not Adjusted
39
- * 1 Sourcing Issue
40
- * 2 Reconciled with General Ledger
41
- * 3 Exemption Certificate Applied
42
- * 4 Price or Quantity Adjusted
43
- * 5 Item Returned
44
- * 6 Item Exchanged
45
- * 7 Bad Debt
46
- * 8 Other (Explain)
47
- Must provide AdjustmentDescription
48
- <pre>
49
- *
50
- * Please visit Avalara's Administrative Console's transaction adjustment section for latest AdjustmentReasonList.
51
- *
52
- * @param int $value
53
- */
54
- public function setAdjustmentReason($value) { $this->AdjustmentReason = $value;}
55
-
56
-
57
- /**
58
- * Holds the data for Adjust Tax call. It takes the information needed for GetTax call.
59
- *
60
- * @param GetTaxRequest $value
61
- */
62
- public function setGetTaxRequest($value) { $this->GetTaxRequest = $value;}
63
-
64
- public function getAdjustmentReason() { return $this->AdjustmentReason;} //int
65
-
66
- public function getAdjustmentDescription() { return $this->AdjustmentDescription;}
67
-
68
-
69
- public function getGetTaxRequest() { return $this->GetTaxRequest;} //string invoice number
70
-
71
-
72
-
73
-
74
-
75
  }
1
+ <?php
2
+ /**
3
+ * AdjustTaxRequest.class.php
4
+ * @package Tax
5
+ */
6
+
7
+ /**
8
+ * Data to pass to {@link TaxServiceSoap#adjustTax}.
9
+ *
10
+ * @see AdjustTaxRequest
11
+ * @package Tax
12
+ * @author tblanchard
13
+ * Copyright (c) 2008, Avalara. All rights reserved.
14
+ */
15
+
16
+
17
+
18
+ class AdjustTaxRequest
19
+ {
20
+ private $AdjustmentReason; //int
21
+ private $AdjustmentDescription; //string
22
+ private $GetTaxRequest; //string
23
+
24
+
25
+ /**
26
+ * Adjustment Description is required when AdjustmentReason is "Other" for enhanced tracability.
27
+ *
28
+ * @param string $value
29
+ */
30
+ public function setAdjustmentDescription($value) { $this->AdjustmentDescription = $value; }
31
+
32
+
33
+
34
+ /**
35
+ * Reason for Adjusting document.
36
+ * <pre>
37
+ * Sets a valid reason for the given AdjustTax call. Adjustment Reason is a high level classification of why an Original Document is being modified.
38
+ * 0 Not Adjusted
39
+ * 1 Sourcing Issue
40
+ * 2 Reconciled with General Ledger
41
+ * 3 Exemption Certificate Applied
42
+ * 4 Price or Quantity Adjusted
43
+ * 5 Item Returned
44
+ * 6 Item Exchanged
45
+ * 7 Bad Debt
46
+ * 8 Other (Explain)
47
+ Must provide AdjustmentDescription
48
+ <pre>
49
+ *
50
+ * Please visit Avalara's Administrative Console's transaction adjustment section for latest AdjustmentReasonList.
51
+ *
52
+ * @param int $value
53
+ */
54
+ public function setAdjustmentReason($value) { $this->AdjustmentReason = $value;}
55
+
56
+
57
+ /**
58
+ * Holds the data for Adjust Tax call. It takes the information needed for GetTax call.
59
+ *
60
+ * @param GetTaxRequest $value
61
+ */
62
+ public function setGetTaxRequest($value) { $this->GetTaxRequest = $value;}
63
+
64
+ public function getAdjustmentReason() { return $this->AdjustmentReason;} //int
65
+
66
+ public function getAdjustmentDescription() { return $this->AdjustmentDescription;}
67
+
68
+
69
+ public function getGetTaxRequest() { return $this->GetTaxRequest;} //string invoice number
70
+
71
+
72
+
73
+
74
+
75
  }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/AdjustTaxResult.class.php RENAMED
@@ -1,261 +1,261 @@
1
- <?php
2
- /**
3
- * AdjustTaxResult.class.php
4
- * @package Tax
5
- */
6
-
7
-
8
- /**
9
- * Result data returned from {@link TaxServiceSoap#getTax}.
10
- *
11
- * @see AdjustTaxRequest
12
- * @package Tax
13
- * @author tblanchard
14
- * Copyright (c) 2008, Avalara. All rights reserved.
15
- */
16
-
17
- class AdjustTaxResult //extends GetTaxResult
18
- {
19
-
20
-
21
- ///From GetTaxResult- Bug in soapclient requires this copy
22
- private $DocCode; //string
23
- private $AdjustmentDescription; //string
24
- private $DocDate; //date
25
- private $TaxDate; //date
26
- private $DocType; //DocumentType
27
- private $DocStatus; //DocStatus
28
- private $Reconciled; //boolean
29
- private $Locked; //boolean
30
- private $Timestamp; //dateTime
31
- private $TotalAmount; //decimal
32
- private $TotalDiscount; //decimal
33
- private $TotalExemption; //decimal
34
- private $TotalTaxable; //decimal
35
- private $TotalTax; //decimal
36
- private $HashCode; //int
37
- private $AdjustmentReason; //int
38
- private $Version; //int
39
- private $TaxLines; //ArrayOfTaxLine
40
-
41
- //@author:swetal
42
- //Added new properties to upgrade to 5.3 interface
43
- private $TotalTaxCalculated; //decimal
44
- private $TaxSummary; //ArrayOfTaxDetail
45
-
46
-
47
-
48
- /**
49
- * Gets the internal reference code used by the client application. This is used for operations such as Post and GetTaxHistory.
50
- * <p>
51
- * See {@link GetTaxRequest#getDocCode} on <b>GetTaxRequest</b> for more information about this member.
52
- * </p>
53
- *
54
- * @return string
55
- */
56
- public function getDocCode() {return $this->DocCode; }
57
-
58
- /**
59
- * AdjustmentDescription set while making AdjustTax call.
60
- *
61
- * @return string
62
- */
63
- public function getAdjustmentDescription() { return $this->AdjustmentDescription; }
64
-
65
- /**
66
- * AdjustmentReason set while making AdjustTax call. It is a high level classification of why an Original Document is being modified.
67
- *
68
- * @return int
69
- */
70
- public function getAdjustmentReason(){ return $this->AdjustmentReason; }
71
-
72
- /**
73
- * Gets the date on the invoice, purchase order, etc.
74
- * <p>
75
- * See {@link GetTaxRequest#getDocDate} on <b>GetTaxRequest</b> for more information about this member.
76
- * </p>
77
- *
78
- * @return date
79
- */
80
- public function getDocDate() {return $this->DocDate; }
81
-
82
- /**
83
- * Tax Date is the date used to calculate tax on the Document.
84
- * <p>
85
- * See {@link GetTaxRequest#taxDate} on <b>GetTaxRequest</b> for more information about this member.
86
- * </p>
87
- *
88
- * @return date
89
- */
90
- public function getTaxDate() {return $this->TaxDate; }
91
-
92
- /**
93
- * Gets the Document Type.
94
- * <p>
95
- * See {@link GetTaxRequest#DocType} on <b>GetTaxRequest</b> for more information about this member.
96
- * </p>
97
- *
98
- * @return DocumentType
99
- */
100
- public function getDocType() {return $this->DocType; }
101
-
102
- /**
103
- * Gets the document's status after the tax calculation.
104
- *
105
- * @return DocStatus
106
- */
107
- public function getDocStatus() {return $this->DocStatus; }
108
-
109
- /**
110
- * True if the document has been reconciled; Only committed documents can be reconciled.
111
- * <p>
112
- * For information on committing documents, see the <b>TaxSvc</b>'s
113
- * {@link TaxSvcSoap#commitTax} method. For information
114
- * on reconciling documents, see the {@link TaxSvcSoap#reconcileTaxHistory} method.
115
- * </p>
116
- *
117
- * @return boolean
118
- */
119
- public function getIsReconciled() {return $this->Reconciled; }
120
-
121
- /**
122
- * Flag indicating if a Document has been locked by Avalara's MRS process. Locked documents can not be modified and can not be cancelled because they have been reported on Tax Return.
123
- *
124
- * @return boolean
125
- */
126
- public function getLocked() {return $this->Locked; }
127
-
128
- /**
129
- * Date of the last status change on the document (i.e. Save date, Post date, Commit date, Cancel date).
130
- *
131
- * @return dateTime
132
- */
133
- public function getTimestamp() {return $this->Timestamp; }
134
-
135
- /**
136
- * The sum of all line {@link Line#getAmount} values.
137
- *
138
- * @param decimal
139
- */
140
- public function getTotalAmount() {return $this->TotalAmount; }
141
-
142
- /**
143
- * Gets the sum of all <b>TaxLine</b> {@link TaxLine#getDiscount} amounts; Typically it
144
- * will equal the requested Discount, but, but it is possible that no lines were marked as discounted.
145
- *
146
- * @return decimal
147
- */
148
- public function getTotalDiscount() {return $this->TotalDiscount; }
149
-
150
- /**
151
- * Gets the sum of all <b>TaxLine</b> {@link TaxLine#getExemption} amounts.
152
- *
153
- * @return decimal
154
- * @deprecated See {@link TaxDetail#getExemption}.
155
- */
156
- public function getTotalExemption() {return $this->TotalExemption; }
157
-
158
- /**
159
- * Gets the amount the tax is based on; This is the total of all {@link Line} <b>Base</b> amounts;
160
- * Typically it will be equal to the document
161
- * {@link GetTaxResult#getTotalAmount} - {@link GetTaxRequest#getDiscount} - {@link #getTotalExemption}.
162
- *
163
- * @return decimal
164
- * @deprecated See {@link TaxDetail#getTaxable}.
165
- */
166
- public function getTotalTaxable() {return $this->TotalTaxable; }
167
-
168
- /**
169
- * Gets the total tax for the document.
170
- *
171
- * @return decimal
172
- */
173
- public function getTotalTax() {return $this->TotalTax; }
174
-
175
- /**
176
- * HashCode to support Reconciliation.
177
- *
178
- * @return hashCode
179
- */
180
- public function getHashCode() {return $this->HashCode; }
181
-
182
- /**
183
- * Current version of the document.
184
- *
185
- * @return int
186
- */
187
- public function getVersion() {return $this->Version; }
188
-
189
- /**
190
- * Gets the Tax broken down by individual {@link TaxLine}.
191
- *
192
- * @return taxLines
193
- */
194
- public function getTaxLines() {return EnsureIsArray($this->TaxLines->TaxLine); }
195
-
196
- /**
197
- * TotalTaxCalculated indicates the total tax calculated by AvaTax. This is usually the same as the TotalTax, except when a tax override amount is specified.
198
- * This is for informational purposes.The TotalTax will still be used for reporting
199
- *
200
- * @return unknown
201
- */
202
- public function getTotalTaxCalculated(){ return $this->TotalTaxCalculated;}
203
-
204
- /**
205
- * TaxSummary is now returned when GetTaxRequest.DetailLevel == DetailLevel.Line in addition to DetailLevel.Summary.
206
- * It is not returned for DetailLevel.Document or DetailLevel.TaxDetail.
207
- *
208
- * @return ArrayOfTaxDetail
209
- */
210
- public function getTaxSummary() {return EnsureIsArray($this->TaxSummary->TaxDetail);}
211
-
212
- public function getTaxLine($lineNo)
213
- {
214
- if($this->getTaxLines() != null)
215
- {
216
- foreach($this->getTaxLines() as $taxLine)
217
- {
218
- if($lineNo == $taxLine->getNo())
219
- {
220
- return $taxLine;
221
- }
222
-
223
- }
224
- }
225
- }
226
-
227
-
228
- /////////////////////////////////////////////PHP bug requires this copy from BaseResult ///////////
229
- /**
230
- * @var string
231
- */
232
- private $TransactionId;
233
- /**
234
- * @var string must be one of the values defined in {@link SeverityLevel}.
235
- */
236
- private $ResultCode = 'Success';
237
- /**
238
- * @var array of Message.
239
- */
240
- private $Messages = array();
241
-
242
- /**
243
- * Accessor
244
- * @return string
245
- */
246
- public function getTransactionId() { return $this->TransactionId; }
247
- /**
248
- * Accessor
249
- * @return string
250
- */
251
- public function getResultCode() { return $this->ResultCode; }
252
- /**
253
- * Accessor
254
- * @return array
255
- */
256
- public function getMessages() { return EnsureIsArray($this->Messages->Message); }
257
-
258
-
259
-
260
-
261
  }
1
+ <?php
2
+ /**
3
+ * AdjustTaxResult.class.php
4
+ * @package Tax
5
+ */
6
+
7
+
8
+ /**
9
+ * Result data returned from {@link TaxServiceSoap#getTax}.
10
+ *
11
+ * @see AdjustTaxRequest
12
+ * @package Tax
13
+ * @author tblanchard
14
+ * Copyright (c) 2008, Avalara. All rights reserved.
15
+ */
16
+
17
+ class AdjustTaxResult //extends GetTaxResult
18
+ {
19
+
20
+
21
+ ///From GetTaxResult- Bug in soapclient requires this copy
22
+ private $DocCode; //string
23
+ private $AdjustmentDescription; //string
24
+ private $DocDate; //date
25
+ private $TaxDate; //date
26
+ private $DocType; //DocumentType
27
+ private $DocStatus; //DocStatus
28
+ private $Reconciled; //boolean
29
+ private $Locked; //boolean
30
+ private $Timestamp; //dateTime
31
+ private $TotalAmount; //decimal
32
+ private $TotalDiscount; //decimal
33
+ private $TotalExemption; //decimal
34
+ private $TotalTaxable; //decimal
35
+ private $TotalTax; //decimal
36
+ private $HashCode; //int
37
+ private $AdjustmentReason; //int
38
+ private $Version; //int
39
+ private $TaxLines; //ArrayOfTaxLine
40
+
41
+ //@author:swetal
42
+ //Added new properties to upgrade to 5.3 interface
43
+ private $TotalTaxCalculated; //decimal
44
+ private $TaxSummary; //ArrayOfTaxDetail
45
+
46
+
47
+
48
+ /**
49
+ * Gets the internal reference code used by the client application. This is used for operations such as Post and GetTaxHistory.
50
+ * <p>
51
+ * See {@link GetTaxRequest#getDocCode} on <b>GetTaxRequest</b> for more information about this member.
52
+ * </p>
53
+ *
54
+ * @return string
55
+ */
56
+ public function getDocCode() {return $this->DocCode; }
57
+
58
+ /**
59
+ * AdjustmentDescription set while making AdjustTax call.
60
+ *
61
+ * @return string
62
+ */
63
+ public function getAdjustmentDescription() { return $this->AdjustmentDescription; }
64
+
65
+ /**
66
+ * AdjustmentReason set while making AdjustTax call. It is a high level classification of why an Original Document is being modified.
67
+ *
68
+ * @return int
69
+ */
70
+ public function getAdjustmentReason(){ return $this->AdjustmentReason; }
71
+
72
+ /**
73
+ * Gets the date on the invoice, purchase order, etc.
74
+ * <p>
75
+ * See {@link GetTaxRequest#getDocDate} on <b>GetTaxRequest</b> for more information about this member.
76
+ * </p>
77
+ *
78
+ * @return date
79
+ */
80
+ public function getDocDate() {return $this->DocDate; }
81
+
82
+ /**
83
+ * Tax Date is the date used to calculate tax on the Document.
84
+ * <p>
85
+ * See {@link GetTaxRequest#taxDate} on <b>GetTaxRequest</b> for more information about this member.
86
+ * </p>
87
+ *
88
+ * @return date
89
+ */
90
+ public function getTaxDate() {return $this->TaxDate; }
91
+
92
+ /**
93
+ * Gets the Document Type.
94
+ * <p>
95
+ * See {@link GetTaxRequest#DocType} on <b>GetTaxRequest</b> for more information about this member.
96
+ * </p>
97
+ *
98
+ * @return DocumentType
99
+ */
100
+ public function getDocType() {return $this->DocType; }
101
+
102
+ /**
103
+ * Gets the document's status after the tax calculation.
104
+ *
105
+ * @return DocStatus
106
+ */
107
+ public function getDocStatus() {return $this->DocStatus; }
108
+
109
+ /**
110
+ * True if the document has been reconciled; Only committed documents can be reconciled.
111
+ * <p>
112
+ * For information on committing documents, see the <b>TaxSvc</b>'s
113
+ * {@link TaxSvcSoap#commitTax} method. For information
114
+ * on reconciling documents, see the {@link TaxSvcSoap#reconcileTaxHistory} method.
115
+ * </p>
116
+ *
117
+ * @return boolean
118
+ */
119
+ public function getIsReconciled() {return $this->Reconciled; }
120
+
121
+ /**
122
+ * Flag indicating if a Document has been locked by Avalara's MRS process. Locked documents can not be modified and can not be cancelled because they have been reported on Tax Return.
123
+ *
124
+ * @return boolean
125
+ */
126
+ public function getLocked() {return $this->Locked; }
127
+
128
+ /**
129
+ * Date of the last status change on the document (i.e. Save date, Post date, Commit date, Cancel date).
130
+ *
131
+ * @return dateTime
132
+ */
133
+ public function getTimestamp() {return $this->Timestamp; }
134
+
135
+ /**
136
+ * The sum of all line {@link Line#getAmount} values.
137
+ *
138
+ * @param decimal
139
+ */
140
+ public function getTotalAmount() {return $this->TotalAmount; }
141
+
142
+ /**
143
+ * Gets the sum of all <b>TaxLine</b> {@link TaxLine#getDiscount} amounts; Typically it
144
+ * will equal the requested Discount, but, but it is possible that no lines were marked as discounted.
145
+ *
146
+ * @return decimal
147
+ */
148
+ public function getTotalDiscount() {return $this->TotalDiscount; }
149
+
150
+ /**
151
+ * Gets the sum of all <b>TaxLine</b> {@link TaxLine#getExemption} amounts.
152
+ *
153
+ * @return decimal
154
+ * @deprecated See {@link TaxDetail#getExemption}.
155
+ */
156
+ public function getTotalExemption() {return $this->TotalExemption; }
157
+
158
+ /**
159
+ * Gets the amount the tax is based on; This is the total of all {@link Line} <b>Base</b> amounts;
160
+ * Typically it will be equal to the document
161
+ * {@link GetTaxResult#getTotalAmount} - {@link GetTaxRequest#getDiscount} - {@link #getTotalExemption}.
162
+ *
163
+ * @return decimal
164
+ * @deprecated See {@link TaxDetail#getTaxable}.
165
+ */
166
+ public function getTotalTaxable() {return $this->TotalTaxable; }
167
+
168
+ /**
169
+ * Gets the total tax for the document.
170
+ *
171
+ * @return decimal
172
+ */
173
+ public function getTotalTax() {return $this->TotalTax; }
174
+
175
+ /**
176
+ * HashCode to support Reconciliation.
177
+ *
178
+ * @return hashCode
179
+ */
180
+ public function getHashCode() {return $this->HashCode; }
181
+
182
+ /**
183
+ * Current version of the document.
184
+ *
185
+ * @return int
186
+ */
187
+ public function getVersion() {return $this->Version; }
188
+
189
+ /**
190
+ * Gets the Tax broken down by individual {@link TaxLine}.
191
+ *
192
+ * @return taxLines
193
+ */
194
+ public function getTaxLines() {return EnsureIsArray($this->TaxLines->TaxLine); }
195
+
196
+ /**
197
+ * TotalTaxCalculated indicates the total tax calculated by AvaTax. This is usually the same as the TotalTax, except when a tax override amount is specified.
198
+ * This is for informational purposes.The TotalTax will still be used for reporting
199
+ *
200
+ * @return unknown
201
+ */
202
+ public function getTotalTaxCalculated(){ return $this->TotalTaxCalculated;}
203
+
204
+ /**
205
+ * TaxSummary is now returned when GetTaxRequest.DetailLevel == DetailLevel.Line in addition to DetailLevel.Summary.
206
+ * It is not returned for DetailLevel.Document or DetailLevel.TaxDetail.
207
+ *
208
+ * @return ArrayOfTaxDetail
209
+ */
210
+ public function getTaxSummary() {return EnsureIsArray($this->TaxSummary->TaxDetail);}
211
+
212
+ public function getTaxLine($lineNo)
213
+ {
214
+ if($this->getTaxLines() != null)
215
+ {
216
+ foreach($this->getTaxLines() as $taxLine)
217
+ {
218
+ if($lineNo == $taxLine->getNo())
219
+ {
220
+ return $taxLine;
221
+ }
222
+
223
+ }
224
+ }
225
+ }
226
+
227
+
228
+ /////////////////////////////////////////////PHP bug requires this copy from BaseResult ///////////
229
+ /**
230
+ * @var string
231
+ */
232
+ private $TransactionId;
233
+ /**
234
+ * @var string must be one of the values defined in {@link SeverityLevel}.
235
+ */
236
+ private $ResultCode = 'Success';
237
+ /**
238
+ * @var array of Message.
239
+ */
240
+ private $Messages = array();
241
+
242
+ /**
243
+ * Accessor
244
+ * @return string
245
+ */
246
+ public function getTransactionId() { return $this->TransactionId; }
247
+ /**
248
+ * Accessor
249
+ * @return string
250
+ */
251
+ public function getResultCode() { return $this->ResultCode; }
252
+ /**
253
+ * Accessor
254
+ * @return array
255
+ */
256
+ public function getMessages() { return EnsureIsArray($this->Messages->Message); }
257
+
258
+
259
+
260
+
261
  }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/ApplyPaymentRequest.class.php RENAMED
@@ -1,77 +1,77 @@
1
- <?php
2
- /**
3
- * ApplyPaymentRequest.class.php
4
- *
5
- * @package Tax
6
- */
7
-
8
- class ApplyPaymentRequest
9
- {
10
- private $CompanyCode; //string
11
- private $DocType; //DocumentType
12
- private $DocCode; //string
13
- private $PaymentDate; //date
14
-
15
-
16
- public function __construct()
17
- {
18
- $this->DocType=DocumentType::$SalesOrder;
19
- }
20
-
21
- /**
22
- * Sets the companyCode value for this ApplyPaymentRequest.
23
- *
24
- * @param string $value
25
- */
26
- public function setCompanyCode($value){ $this->CompanyCode=$value;} //string
27
-
28
- /**
29
- * Sets the docCode value for this ApplyPaymentRequest.
30
- *
31
- * @param DocumentType $value
32
- */
33
- public function setDocType($value){ $this->DocType=$value;} //DocumentType
34
-
35
- /**
36
- * Sets the docType value for this ApplyPaymentRequest.
37
- *
38
- * @param string $value
39
- */
40
- public function setDocCode($value){ $this->DocCode=$value;} //string
41
-
42
- /**
43
- * PaymentDate should be in the format yyyy-mm-dd
44
- *
45
- * @param date $value
46
- */
47
- public function setPaymentDate($value){ $this->PaymentDate=$value;} //date
48
-
49
-
50
- /**
51
- * Gets the companyCode value for this ApplyPaymentRequest.
52
- *
53
- * @return string
54
- */
55
- public function getCompanyCode(){ return $this->CompanyCode;} //string
56
-
57
- /**
58
- * Gets the docType value for this ApplyPaymentRequest.
59
- *
60
- * @return DocumentType
61
- */
62
- public function getDocType(){ return $this->DocType;} //DocumentType
63
-
64
- /**
65
- * Gets the docCode value for this ApplyPaymentRequest.
66
- *
67
- * @return unknown
68
- */
69
- public function getDocCode(){ return $this->DocCode;} //string
70
- /**
71
- * PaymentDate should be in the format yyyy-mm-dd
72
- *
73
- * @param date $value
74
- */
75
- public function getPaymentDate(){ return $this->PaymentDate;} //date
76
-
77
  }
1
+ <?php
2
+ /**
3
+ * ApplyPaymentRequest.class.php
4
+ *
5
+ * @package Tax
6
+ */
7
+
8
+ class ApplyPaymentRequest
9
+ {
10
+ private $CompanyCode; //string
11
+ private $DocType; //DocumentType
12
+ private $DocCode; //string
13
+ private $PaymentDate; //date
14
+
15
+
16
+ public function __construct()
17
+ {
18
+ $this->DocType=DocumentType::$SalesOrder;
19
+ }
20
+
21
+ /**
22
+ * Sets the companyCode value for this ApplyPaymentRequest.
23
+ *
24
+ * @param string $value
25
+ */
26
+ public function setCompanyCode($value){ $this->CompanyCode=$value;} //string
27
+
28
+ /**
29
+ * Sets the docCode value for this ApplyPaymentRequest.
30
+ *
31
+ * @param DocumentType $value
32
+ */
33
+ public function setDocType($value){ $this->DocType=$value;} //DocumentType
34
+
35
+ /**
36
+ * Sets the docType value for this ApplyPaymentRequest.
37
+ *
38
+ * @param string $value
39
+ */
40
+ public function setDocCode($value){ $this->DocCode=$value;} //string
41
+
42
+ /**
43
+ * PaymentDate should be in the format yyyy-mm-dd
44
+ *
45
+ * @param date $value
46
+ */
47
+ public function setPaymentDate($value){ $this->PaymentDate=$value;} //date
48
+
49
+
50
+ /**
51
+ * Gets the companyCode value for this ApplyPaymentRequest.
52
+ *
53
+ * @return string
54
+ */
55
+ public function getCompanyCode(){ return $this->CompanyCode;} //string
56
+
57
+ /**
58
+ * Gets the docType value for this ApplyPaymentRequest.
59
+ *
60
+ * @return DocumentType
61
+ */
62
+ public function getDocType(){ return $this->DocType;} //DocumentType
63
+
64
+ /**
65
+ * Gets the docCode value for this ApplyPaymentRequest.
66
+ *
67
+ * @return unknown
68
+ */
69
+ public function getDocCode(){ return $this->DocCode;} //string
70
+ /**
71
+ * PaymentDate should be in the format yyyy-mm-dd
72
+ *
73
+ * @param date $value
74
+ */
75
+ public function getPaymentDate(){ return $this->PaymentDate;} //date
76
+
77
  }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/ApplyPaymentResult.class.php RENAMED
@@ -1,13 +1,13 @@
1
- <?php
2
- /**
3
- * ApplyPaymentResult.class.php
4
- *
5
- * @package Tax
6
- */
7
-
8
- class ApplyPaymentResult extends BaseResult
9
- {
10
-
11
-
12
-
13
  }
1
+ <?php
2
+ /**
3
+ * ApplyPaymentResult.class.php
4
+ *
5
+ * @package Tax
6
+ */
7
+
8
+ class ApplyPaymentResult extends BaseResult
9
+ {
10
+
11
+
12
+
13
  }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/AvalaraSoapClient.class.php RENAMED
@@ -1,32 +1,32 @@
1
- <?php
2
-
3
- /**
4
- * AvalaraSoapClient.class.php
5
- *
6
- * @package Base
7
- */
8
-
9
- /**
10
- * Abstract base class for all Avalara web service clients.
11
- *
12
- * Users should never create instances of this class.
13
- *
14
- * @package Base
15
- * @abstract
16
- * @see AddressServiceSoap
17
- * @see TaxServiceSoap
18
- * @author tblanchard
19
- *
20
- * Copyright (c) 2007, Avalara. All rights reserved.
21
- */
22
-
23
- class AvalaraSoapClient
24
- {
25
- protected $client;
26
-
27
- public function __getLastRequest() { return $this->client->__getLastRequest(); }
28
- public function __getLastResponse() { return $this->client->__getLastResponse(); }
29
- public function __getLastRequestHeaders() { return $this->client->__getLastRequestHeaders(); }
30
- public function __getLastResponseHeaders() { return $this->client->__getLastResponseHeaders(); }
31
-
32
- }
1
+ <?php
2
+
3
+ /**
4
+ * AvalaraSoapClient.class.php
5
+ *
6
+ * @package Base
7
+ */
8
+
9
+ /**
10
+ * Abstract base class for all Avalara web service clients.
11
+ *
12
+ * Users should never create instances of this class.
13
+ *
14
+ * @package Base
15
+ * @abstract
16
+ * @see AddressServiceSoap
17
+ * @see TaxServiceSoap
18
+ * @author tblanchard
19
+ *
20
+ * Copyright (c) 2007, Avalara. All rights reserved.
21
+ */
22
+
23
+ class AvalaraSoapClient
24
+ {
25
+ protected $client;
26
+
27
+ public function __getLastRequest() { return $this->client->__getLastRequest(); }
28
+ public function __getLastResponse() { return $this->client->__getLastResponse(); }
29
+ public function __getLastRequestHeaders() { return $this->client->__getLastRequestHeaders(); }
30
+ public function __getLastResponseHeaders() { return $this->client->__getLastResponseHeaders(); }
31
+
32
+ }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BaseResult.class.php RENAMED
@@ -1,37 +1,37 @@
1
- <?php
2
- /**
3
- * BaseResult.class.php
4
- * @package Base
5
- */
6
-
7
- /**
8
- * The base class for result objects that return a ResultCode and Messages collection -- There is no reason for clients to create these.
9
- * @package Base
10
- * @author tblanchard
11
- * Copyright (c) 2005, Avalara. All rights reserved.
12
- */
13
-
14
-
15
- class BaseResult
16
- {
17
-
18
- //@author:swetal
19
- //Removed declarations of variable as it was creating problem due to bug in SoapClient
20
-
21
- /**
22
- * A unique Transaction ID identifying a specific request/response set.
23
- * @return string
24
- */
25
- public function getTransactionId() { return $this->TransactionId; }
26
- /**
27
- * Indicates whether operation was successfully completed or not.
28
- * @return string
29
- */
30
- public function getResultCode() { return $this->ResultCode; }
31
- /**
32
- * Accessor
33
- * @return array
34
- */
35
- public function getMessages() { return EnsureIsArray($this->Messages->Message); }
36
-
37
  }
1
+ <?php
2
+ /**
3
+ * BaseResult.class.php
4
+ * @package Base
5
+ */
6
+
7
+ /**
8
+ * The base class for result objects that return a ResultCode and Messages collection -- There is no reason for clients to create these.
9
+ * @package Base
10
+ * @author tblanchard
11
+ * Copyright (c) 2005, Avalara. All rights reserved.
12
+ */
13
+
14
+
15
+ class BaseResult
16
+ {
17
+
18
+ //@author:swetal
19
+ //Removed declarations of variable as it was creating problem due to bug in SoapClient
20
+
21
+ /**
22
+ * A unique Transaction ID identifying a specific request/response set.
23
+ * @return string
24
+ */
25
+ public function getTransactionId() { return $this->TransactionId; }
26
+ /**
27
+ * Indicates whether operation was successfully completed or not.
28
+ * @return string
29
+ */
30
+ public function getResultCode() { return $this->ResultCode; }
31
+ /**
32
+ * Accessor
33
+ * @return array
34
+ */
35
+ public function getMessages() { return EnsureIsArray($this->Messages->Message); }
36
+
37
  }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/AuditMessage.class.php RENAMED
@@ -1,13 +1,13 @@
1
- <?php
2
- /**
3
- * AuditMessage.class.php
4
- *
5
- * @package Batch
6
- */
7
- class AuditMessage {
8
- private $Message; // string
9
-
10
- public function setMessage($value){$this->Message=$value;} // string
11
- public function getMessage(){return $this->Message;} // string
12
-
13
- }
1
+ <?php
2
+ /**
3
+ * AuditMessage.class.php
4
+ *
5
+ * @package Batch
6
+ */
7
+ class AuditMessage {
8
+ private $Message; // string
9
+
10
+ public function setMessage($value){$this->Message=$value;} // string
11
+ public function getMessage(){return $this->Message;} // string
12
+
13
+ }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/AvaTaxBatchSvc.php RENAMED
@@ -1,71 +1,71 @@
1
- <?php
2
- /**
3
- * AvaTax.php
4
- *
5
- * @package Base
6
- */
7
-
8
- /**
9
- * Defines class loading search path.
10
- */
11
-
12
- function __autoload($class_name)
13
- {
14
- require_once $class_name . '.class.php';
15
- }
16
-
17
- function EnsureIsArray( $obj )
18
- {
19
- if( is_object($obj))
20
- {
21
- $item[0] = $obj;
22
- }
23
- else
24
- {
25
- $item = (array)$obj;
26
- }
27
- return $item;
28
- }
29
-
30
-
31
-
32
- /**
33
- * Takes xml as a string and returns it nicely indented
34
- *
35
- * @param string $xml The xml to beautify
36
- * @param boolean $html_output If the xml should be formatted for display on an html page
37
- * @return string The beautified xml
38
- */
39
-
40
- function xml_pretty_printer($xml, $html_output=FALSE)
41
- {
42
- $xml_obj = new SimpleXMLElement($xml);
43
- $xml_lines = explode("n", $xml_obj->asXML());
44
- $indent_level = 0;
45
-
46
- $new_xml_lines = array();
47
- foreach ($xml_lines as $xml_line) {
48
- if (preg_match('#(<[a-z0-9:-]+((s+[a-z0-9:-]+="[^"]+")*)?>.*<s*/s*[^>]+>)|(<[a-z0-9:-]+((s+[a-z0-9:-]+="[^"]+")*)?s*/s*>)#i', $xml_line)) {
49
- $new_line = str_pad('', $indent_level*4) . $xml_line;
50
- $new_xml_lines[] = $new_line;
51
- } elseif (preg_match('#<[a-z0-9:-]+((s+[a-z0-9:-]+="[^"]+")*)?>#i', $xml_line)) {
52
- $new_line = str_pad('', $indent_level*4) . $xml_line;
53
- $indent_level++;
54
- $new_xml_lines[] = $new_line;
55
- } elseif (preg_match('#<s*/s*[^>/]+>#i', $xml_line)) {
56
- $indent_level--;
57
- if (trim($new_xml_lines[sizeof($new_xml_lines)-1]) == trim(str_replace("/", "", $xml_line))) {
58
- $new_xml_lines[sizeof($new_xml_lines)-1] .= $xml_line;
59
- } else {
60
- $new_line = str_pad('', $indent_level*4) . $xml_line;
61
- $new_xml_lines[] = $new_line;
62
- }
63
- } else {
64
- $new_line = str_pad('', $indent_level*4) . $xml_line;
65
- $new_xml_lines[] = $new_line;
66
- }
67
- }
68
-
69
- $xml = join("n", $new_xml_lines);
70
- return ($html_output) ? '<pre>' . htmlentities($xml) . '</pre>' : $xml;
71
  }
1
+ <?php
2
+ /**
3
+ * AvaTax.php
4
+ *
5
+ * @package Base
6
+ */
7
+
8
+ /**
9
+ * Defines class loading search path.
10
+ */
11
+
12
+ function __autoload($class_name)
13
+ {
14
+ require_once $class_name . '.class.php';
15
+ }
16
+
17
+ function EnsureIsArray( $obj )
18
+ {
19
+ if( is_object($obj))
20
+ {
21
+ $item[0] = $obj;
22
+ }
23
+ else
24
+ {
25
+ $item = (array)$obj;
26
+ }
27
+ return $item;
28
+ }
29
+
30
+
31
+
32
+ /**
33
+ * Takes xml as a string and returns it nicely indented
34
+ *
35
+ * @param string $xml The xml to beautify
36
+ * @param boolean $html_output If the xml should be formatted for display on an html page
37
+ * @return string The beautified xml
38
+ */
39
+
40
+ function xml_pretty_printer($xml, $html_output=FALSE)
41
+ {
42
+ $xml_obj = new SimpleXMLElement($xml);
43
+ $xml_lines = explode("n", $xml_obj->asXML());
44
+ $indent_level = 0;
45
+
46
+ $new_xml_lines = array();
47
+ foreach ($xml_lines as $xml_line) {
48
+ if (preg_match('#(<[a-z0-9:-]+((s+[a-z0-9:-]+="[^"]+")*)?>.*<s*/s*[^>]+>)|(<[a-z0-9:-]+((s+[a-z0-9:-]+="[^"]+")*)?s*/s*>)#i', $xml_line)) {
49
+ $new_line = str_pad('', $indent_level*4) . $xml_line;
50
+ $new_xml_lines[] = $new_line;
51
+ } elseif (preg_match('#<[a-z0-9:-]+((s+[a-z0-9:-]+="[^"]+")*)?>#i', $xml_line)) {
52
+ $new_line = str_pad('', $indent_level*4) . $xml_line;
53
+ $indent_level++;
54
+ $new_xml_lines[] = $new_line;
55
+ } elseif (preg_match('#<s*/s*[^>/]+>#i', $xml_line)) {
56
+ $indent_level--;
57
+ if (trim($new_xml_lines[sizeof($new_xml_lines)-1]) == trim(str_replace("/", "", $xml_line))) {
58
+ $new_xml_lines[sizeof($new_xml_lines)-1] .= $xml_line;
59
+ } else {
60
+ $new_line = str_pad('', $indent_level*4) . $xml_line;
61
+ $new_xml_lines[] = $new_line;
62
+ }
63
+ } else {
64
+ $new_line = str_pad('', $indent_level*4) . $xml_line;
65
+ $new_xml_lines[] = $new_line;
66
+ }
67
+ }
68
+
69
+ $xml = join("n", $new_xml_lines);
70
+ return ($html_output) ? '<pre>' . htmlentities($xml) . '</pre>' : $xml;
71
  }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/BaseResult.class.php RENAMED
@@ -1,21 +1,21 @@
1
- <?php
2
- /**
3
- * BaseResult.class.php
4
- *
5
- * @package Batch
6
- */
7
- class BaseResult {
8
- private $TransactionId; // string
9
- private $ResultCode; // SeverityLevel
10
- private $Messages; // ArrayOfMessage
11
-
12
- public function setTransactionId($value){$this->TransactionId=$value;} // string
13
- public function getTransactionId(){return $this->TransactionId;} // string
14
-
15
- public function setResultCode($value){$this->ResultCode=$value;} // SeverityLevel
16
- public function getResultCode(){return $this->ResultCode;} // SeverityLevel
17
-
18
- public function setMessages($value){$this->Messages=$value;} // ArrayOfMessage
19
- public function getMessages(){return $this->Messages;} // ArrayOfMessage
20
-
21
  }
1
+ <?php
2
+ /**
3
+ * BaseResult.class.php
4
+ *
5
+ * @package Batch
6
+ */
7
+ class BaseResult {
8
+ private $TransactionId; // string
9
+ private $ResultCode; // SeverityLevel
10
+ private $Messages; // ArrayOfMessage
11
+
12
+ public function setTransactionId($value){$this->TransactionId=$value;} // string
13
+ public function getTransactionId(){return $this->TransactionId;} // string
14
+
15
+ public function setResultCode($value){$this->ResultCode=$value;} // SeverityLevel
16
+ public function getResultCode(){return $this->ResultCode;} // SeverityLevel
17
+
18
+ public function setMessages($value){$this->Messages=$value;} // ArrayOfMessage
19
+ public function getMessages(){return $this->Messages;} // ArrayOfMessage
20
+
21
  }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/Batch.class.php RENAMED
@@ -1,86 +1,86 @@
1
- <?php
2
- /**
3
- * Batch.class.php
4
- *
5
- * @package Batch
6
- */
7
- class Batch {
8
- private $AccountId; // int
9
- private $BatchId; // int
10
- private $BatchStatusId; // string
11
- private $BatchTypeId; // string
12
- private $CompanyId; // int
13
- private $CreatedDate; // dateTime
14
- private $CreatedUserId; // int
15
- private $CompletedDate; // dateTime
16
- private $Files; // ArrayOfBatchFile
17
- private $ModifiedDate; // dateTime
18
- private $ModifiedUserId; // int
19
- private $Name; // string
20
- private $Options; // string
21
- private $RecordCount; // int
22
- private $CurrentRecord; // int
23
-
24
- function __construct()
25
- {
26
- $this->AccountId=0;
27
- $this->BatchId=0;
28
- $this->CreatedUserId=0;
29
- $this->ModifiedUserId=0;
30
- $this->RecordCount=0;
31
- $this->CurrentRecord=0;
32
-
33
- $this->CreatedDate=getCurrentDate();
34
- $this->CompletedDate=getCurrentDate();
35
- $this->ModifiedDate=getCurrentDate();
36
-
37
-
38
-
39
- }
40
-
41
- public function setAccountId($value){$this->AccountId=$value;} // int
42
- public function getAccountId(){return $this->AccountId;} // int
43
-
44
- public function setBatchId($value){$this->BatchId=$value;} // int
45
- public function getBatchId(){return $this->BatchId;} // int
46
-
47
- public function setBatchStatusId($value){$this->BatchStatusId=$value;} // string
48
- public function getBatchStatusId(){return $this->BatchStatusId;} // string
49
-
50
- public function setBatchTypeId($value){$this->BatchTypeId=$value;} // string
51
- public function getBatchTypeId(){return $this->BatchTypeId;} // string
52
-
53
- public function setCompanyId($value){$this->CompanyId=$value;} // int
54
- public function getCompanyId(){return $this->CompanyId;} // int
55
-
56
- public function setCreatedDate($value){$this->CreatedDate=$value;} // dateTime
57
- public function getCreatedDate(){return $this->CreatedDate;} // dateTime
58
-
59
- public function setCreatedUserId($value){$this->CreatedUserId=$value;} // int
60
- public function getCreatedUserId(){return $this->CreatedUserId;} // int
61
-
62
- public function setCompletedDate($value){$this->CompletedDate=$value;} // dateTime
63
- public function getCompletedDate(){return $this->CompletedDate;} // dateTime
64
-
65
- public function setFiles($value){$this->Files=$value;} // ArrayOfBatchFile
66
- public function getFiles(){return $this->Files;} // ArrayOfBatchFile
67
-
68
- public function setModifiedDate($value){$this->ModifiedDate=$value;} // dateTime
69
- public function getModifiedDate(){return $this->ModifiedDate;} // dateTime
70
-
71
- public function setModifiedUserId($value){$this->ModifiedUserId=$value;} // int
72
- public function getModifiedUserId(){return $this->ModifiedUserId;} // int
73
-
74
- public function setName($value){$this->Name=$value;} // string
75
- public function getName(){return $this->Name;} // string
76
-
77
- public function setOptions($value){$this->Options=$value;} // string
78
- public function getOptions(){return $this->Options;} // string
79
-
80
- public function setRecordCount($value){$this->RecordCount=$value;} // int
81
- public function getRecordCount(){return $this->RecordCount;} // int
82
-
83
- public function setCurrentRecord($value){$this->CurrentRecord=$value;} // int
84
- public function getCurrentRecord(){return $this->CurrentRecord;} // int
85
-
86
- }
1
+ <?php
2
+ /**
3
+ * Batch.class.php
4
+ *
5
+ * @package Batch
6
+ */
7
+ class Batch {
8
+ private $AccountId; // int
9
+ private $BatchId; // int
10
+ private $BatchStatusId; // string
11
+ private $BatchTypeId; // string
12
+ private $CompanyId; // int
13
+ private $CreatedDate; // dateTime
14
+ private $CreatedUserId; // int
15
+ private $CompletedDate; // dateTime
16
+ private $Files; // ArrayOfBatchFile
17
+ private $ModifiedDate; // dateTime
18
+ private $ModifiedUserId; // int
19
+ private $Name; // string
20
+ private $Options; // string
21
+ private $RecordCount; // int
22
+ private $CurrentRecord; // int
23
+
24
+ function __construct()
25
+ {
26
+ $this->AccountId=0;
27
+ $this->BatchId=0;
28
+ $this->CreatedUserId=0;
29
+ $this->ModifiedUserId=0;
30
+ $this->RecordCount=0;
31
+ $this->CurrentRecord=0;
32
+
33
+ $this->CreatedDate=getCurrentDate();
34
+ $this->CompletedDate=getCurrentDate();
35
+ $this->ModifiedDate=getCurrentDate();
36
+
37
+
38
+
39
+ }
40
+
41
+ public function setAccountId($value){$this->AccountId=$value;} // int
42
+ public function getAccountId(){return $this->AccountId;} // int
43
+
44
+ public function setBatchId($value){$this->BatchId=$value;} // int
45
+ public function getBatchId(){return $this->BatchId;} // int
46
+
47
+ public function setBatchStatusId($value){$this->BatchStatusId=$value;} // string
48
+ public function getBatchStatusId(){return $this->BatchStatusId;} // string
49
+
50
+ public function setBatchTypeId($value){$this->BatchTypeId=$value;} // string
51
+ public function getBatchTypeId(){return $this->BatchTypeId;} // string
52
+
53
+ public function setCompanyId($value){$this->CompanyId=$value;} // int
54
+ public function getCompanyId(){return $this->CompanyId;} // int
55
+
56
+ public function setCreatedDate($value){$this->CreatedDate=$value;} // dateTime
57
+ public function getCreatedDate(){return $this->CreatedDate;} // dateTime
58
+
59
+ public function setCreatedUserId($value){$this->CreatedUserId=$value;} // int
60
+ public function getCreatedUserId(){return $this->CreatedUserId;} // int
61
+
62
+ public function setCompletedDate($value){$this->CompletedDate=$value;} // dateTime
63
+ public function getCompletedDate(){return $this->CompletedDate;} // dateTime
64
+
65
+ public function setFiles($value){$this->Files=$value;} // ArrayOfBatchFile
66
+ public function getFiles(){return $this->Files;} // ArrayOfBatchFile
67
+
68
+ public function setModifiedDate($value){$this->ModifiedDate=$value;} // dateTime
69
+ public function getModifiedDate(){return $this->ModifiedDate;} // dateTime
70
+
71
+ public function setModifiedUserId($value){$this->ModifiedUserId=$value;} // int
72
+ public function getModifiedUserId(){return $this->ModifiedUserId;} // int
73
+
74
+ public function setName($value){$this->Name=$value;} // string
75
+ public function getName(){return $this->Name;} // string
76
+
77
+ public function setOptions($value){$this->Options=$value;} // string
78
+ public function getOptions(){return $this->Options;} // string
79
+
80
+ public function setRecordCount($value){$this->RecordCount=$value;} // int
81
+ public function getRecordCount(){return $this->RecordCount;} // int
82
+
83
+ public function setCurrentRecord($value){$this->CurrentRecord=$value;} // int
84
+ public function getCurrentRecord(){return $this->CurrentRecord;} // int
85
+
86
+ }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/BatchDelete.class.php RENAMED
@@ -1,13 +1,13 @@
1
- <?php
2
- /**
3
- * BatchDelete.class.php
4
- *
5
- * @package Batch
6
- */
7
- class BatchDelete {
8
- private $DeleteRequest; // DeleteRequest
9
-
10
- public function setDeleteRequest($value){$this->DeleteRequest=$value;} // DeleteRequest
11
- public function getDeleteRequest(){return $this->DeleteRequest;} // DeleteRequest
12
-
13
  }
1
+ <?php
2
+ /**
3
+ * BatchDelete.class.php
4
+ *
5
+ * @package Batch
6
+ */
7
+ class BatchDelete {
8
+ private $DeleteRequest; // DeleteRequest
9
+
10
+ public function setDeleteRequest($value){$this->DeleteRequest=$value;} // DeleteRequest
11
+ public function getDeleteRequest(){return $this->DeleteRequest;} // DeleteRequest
12
+
13
  }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/BatchDeleteResponse.class.php RENAMED
@@ -1,13 +1,13 @@
1
- <?php
2
- /**
3
- * BatchDeleteResponse.class.php
4
- *
5
- * @package Batch
6
- */
7
- class BatchDeleteResponse {
8
- private $BatchDeleteResult; // DeleteResult
9
-
10
- public function setBatchDeleteResult($value){$this->BatchDeleteResult=$value;} // DeleteResult
11
- public function getBatchDeleteResult(){return $this->BatchDeleteResult;} // DeleteResult
12
-
13
- }
1
+ <?php
2
+ /**
3
+ * BatchDeleteResponse.class.php
4
+ *
5
+ * @package Batch
6
+ */
7
+ class BatchDeleteResponse {
8
+ private $BatchDeleteResult; // DeleteResult
9
+
10
+ public function setBatchDeleteResult($value){$this->BatchDeleteResult=$value;} // DeleteResult
11
+ public function getBatchDeleteResult(){return $this->BatchDeleteResult;} // DeleteResult
12
+
13
+ }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/BatchFetch.class.php RENAMED
@@ -1,13 +1,13 @@
1
- <?php
2
- /**
3
- * BatchFetch.class.php
4
- *
5
- * @package Batch
6
- */
7
- class BatchFetch {
8
- private $FetchRequest; // FetchRequest
9
-
10
- public function setFetchRequest($value){$this->FetchRequest=$value;} // FetchRequest
11
- public function getFetchRequest(){return $this->FetchRequest;} // FetchRequest
12
-
13
- }
1
+ <?php
2
+ /**
3
+ * BatchFetch.class.php
4
+ *
5
+ * @package Batch
6
+ */
7
+ class BatchFetch {
8
+ private $FetchRequest; // FetchRequest
9
+
10
+ public function setFetchRequest($value){$this->FetchRequest=$value;} // FetchRequest
11
+ public function getFetchRequest(){return $this->FetchRequest;} // FetchRequest
12
+
13
+ }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/BatchFetchResponse.class.php RENAMED
@@ -1,13 +1,13 @@
1
- <?php
2
- /**
3
- * BatchFetchResponse.class.php
4
- *
5
- * @package Batch
6
- */
7
- class BatchFetchResponse {
8
- private $BatchFetchResult; // BatchFetchResult
9
-
10
- public function setBatchFetchResult($value){$this->BatchFetchResult=$value;} // BatchFetchResult
11
- public function getBatchFetchResult(){return $this->BatchFetchResult;} // BatchFetchResult
12
-
13
- }
1
+ <?php
2
+ /**
3
+ * BatchFetchResponse.class.php
4
+ *
5
+ * @package Batch
6
+ */
7
+ class BatchFetchResponse {
8
+ private $BatchFetchResult; // BatchFetchResult
9
+
10
+ public function setBatchFetchResult($value){$this->BatchFetchResult=$value;} // BatchFetchResult
11
+ public function getBatchFetchResult(){return $this->BatchFetchResult;} // BatchFetchResult
12
+
13
+ }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/BatchFetchResult.class.php RENAMED
@@ -1,17 +1,17 @@
1
- <?php
2
- /**
3
- * BatchFetchResult.class.php
4
- *
5
- * @package Batch
6
- */
7
- class BatchFetchResult extends BaseResult {
8
- private $Batches; // ArrayOfBatch
9
- private $RecordCount; // int
10
-
11
- public function setBatches($value){$this->Batches=$value;} // ArrayOfBatch
12
- public function getBatches(){return $this->Batches;} // ArrayOfBatch
13
-
14
- public function setRecordCount($value){$this->RecordCount=$value;} // int
15
- public function getRecordCount(){return $this->RecordCount;} // int
16
-
17
- }
1
+ <?php
2
+ /**
3
+ * BatchFetchResult.class.php
4
+ *
5
+ * @package Batch
6
+ */
7
+ class BatchFetchResult extends BaseResult {
8
+ private $Batches; // ArrayOfBatch
9
+ private $RecordCount; // int
10
+
11
+ public function setBatches($value){$this->Batches=$value;} // ArrayOfBatch
12
+ public function getBatches(){return $this->Batches;} // ArrayOfBatch
13
+
14
+ public function setRecordCount($value){$this->RecordCount=$value;} // int
15
+ public function getRecordCount(){return $this->RecordCount;} // int
16
+
17
+ }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/BatchFile.class.php RENAMED
@@ -1,52 +1,52 @@
1
- <?php
2
- /**
3
- * BatchFile.class.php
4
- *
5
- * @package Batch
6
- */
7
- class BatchFile {
8
- private $BatchFileId; // int
9
- private $BatchId; // int
10
- private $Content; // base64Binary
11
- private $ContentType; // string
12
- private $Ext; // string
13
- private $FilePath; // string
14
- private $Name; // string
15
- private $Size; // int
16
- private $ErrorCount; // int
17
-
18
- function __construct()
19
- {
20
- $this->BatchFileId=0;
21
- $this->BatchId=0;
22
- $this->ErrorCount=0;
23
- }
24
-
25
- public function setBatchFileId($value){$this->BatchFileId=$value;} // int
26
- public function getBatchFileId(){return $this->BatchFileId;} // int
27
-
28
- public function setBatchId($value){$this->BatchId=$value;} // int
29
- public function getBatchId(){return $this->BatchId;} // int
30
-
31
- public function setContent($value){$this->Content=$value;} // base64Binary
32
- public function getContent(){return $this->Content;} // base64Binary
33
-
34
- public function setContentType($value){$this->ContentType=$value;} // string
35
- public function getContentType(){return $this->ContentType;} // string
36
-
37
- public function setExt($value){$this->Ext=$value;} // string
38
- public function getExt(){return $this->Ext;} // string
39
-
40
- public function setFilePath($value){$this->FilePath=$value;} // string
41
- public function getFilePath(){return $this->FilePath;} // string
42
-
43
- public function setName($value){$this->Name=$value;} // string
44
- public function getName(){return $this->Name;} // string
45
-
46
- public function setSize($value){$this->Size=$value;} // int
47
- public function getSize(){return $this->Size;} // int
48
-
49
- public function setErrorCount($value){$this->ErrorCount=$value;} // int
50
- public function getErrorCount(){return $this->ErrorCount;} // int
51
-
52
- }
1
+ <?php
2
+ /**
3
+ * BatchFile.class.php
4
+ *
5
+ * @package Batch
6
+ */
7
+ class BatchFile {
8
+ private $BatchFileId; // int
9
+ private $BatchId; // int
10
+ private $Content; // base64Binary
11
+ private $ContentType; // string
12
+ private $Ext; // string
13
+ private $FilePath; // string
14
+ private $Name; // string
15
+ private $Size; // int
16
+ private $ErrorCount; // int
17
+
18
+ function __construct()
19
+ {
20
+ $this->BatchFileId=0;
21
+ $this->BatchId=0;
22
+ $this->ErrorCount=0;
23
+ }
24
+
25
+ public function setBatchFileId($value){$this->BatchFileId=$value;} // int
26
+ public function getBatchFileId(){return $this->BatchFileId;} // int
27
+
28
+ public function setBatchId($value){$this->BatchId=$value;} // int
29
+ public function getBatchId(){return $this->BatchId;} // int
30
+
31
+ public function setContent($value){$this->Content=$value;} // base64Binary
32
+ public function getContent(){return $this->Content;} // base64Binary
33
+
34
+ public function setContentType($value){$this->ContentType=$value;} // string
35
+ public function getContentType(){return $this->ContentType;} // string
36
+
37
+ public function setExt($value){$this->Ext=$value;} // string
38
+ public function getExt(){return $this->Ext;} // string
39
+
40
+ public function setFilePath($value){$this->FilePath=$value;} // string
41
+ public function getFilePath(){return $this->FilePath;} // string
42
+
43
+ public function setName($value){$this->Name=$value;} // string
44
+ public function getName(){return $this->Name;} // string
45
+
46
+ public function setSize($value){$this->Size=$value;} // int
47
+ public function getSize(){return $this->Size;} // int
48
+
49
+ public function setErrorCount($value){$this->ErrorCount=$value;} // int
50
+ public function getErrorCount(){return $this->ErrorCount;} // int
51
+
52
+ }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/BatchFileDelete.class.php RENAMED
@@ -1,13 +1,13 @@
1
- <?php
2
- /**
3
- * BatchFileDelete.class.php
4
- *
5
- * @package Batch
6
- */
7
- class BatchFileDelete {
8
- private $DeleteRequest; // DeleteRequest
9
-
10
- public function setDeleteRequest($value){$this->DeleteRequest=$value;} // DeleteRequest
11
- public function getDeleteRequest(){return $this->DeleteRequest;} // DeleteRequest
12
-
13
- }
1
+ <?php
2
+ /**
3
+ * BatchFileDelete.class.php
4
+ *
5
+ * @package Batch
6
+ */
7
+ class BatchFileDelete {
8
+ private $DeleteRequest; // DeleteRequest
9
+
10
+ public function setDeleteRequest($value){$this->DeleteRequest=$value;} // DeleteRequest
11
+ public function getDeleteRequest(){return $this->DeleteRequest;} // DeleteRequest
12
+
13
+ }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/BatchFileDeleteResponse.class.php RENAMED
@@ -1,13 +1,13 @@
1
- <?php
2
- /**
3
- * BatchFileDeleteResponse.class.php
4
- *
5
- * @package Batch
6
- */
7
- class BatchFileDeleteResponse {
8
- private $BatchFileDeleteResult; // DeleteResult
9
-
10
- public function setBatchFileDeleteResult($value){$this->BatchFileDeleteResult=$value;} // DeleteResult
11
- public function getBatchFileDeleteResult(){return $this->BatchFileDeleteResult;} // DeleteResult
12
-
13
  }
1
+ <?php
2
+ /**
3
+ * BatchFileDeleteResponse.class.php
4
+ *
5
+ * @package Batch
6
+ */
7
+ class BatchFileDeleteResponse {
8
+ private $BatchFileDeleteResult; // DeleteResult
9
+
10
+ public function setBatchFileDeleteResult($value){$this->BatchFileDeleteResult=$value;} // DeleteResult
11
+ public function getBatchFileDeleteResult(){return $this->BatchFileDeleteResult;} // DeleteResult
12
+
13
  }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/BatchFileFetch.class.php RENAMED
@@ -1,13 +1,13 @@
1
- <?php
2
- /**
3
- * BatchFileFetch.class.php
4
- *
5
- * @package Batch
6
- */
7
- class BatchFileFetch {
8
- private $FetchRequest; // FetchRequest
9
-
10
- public function setFetchRequest($value){$this->FetchRequest=$value;} // FetchRequest
11
- public function getFetchRequest(){return $this->FetchRequest;} // FetchRequest
12
-
13
- }
1
+ <?php
2
+ /**
3
+ * BatchFileFetch.class.php
4
+ *
5
+ * @package Batch
6
+ */
7
+ class BatchFileFetch {
8
+ private $FetchRequest; // FetchRequest
9
+
10
+ public function setFetchRequest($value){$this->FetchRequest=$value;} // FetchRequest
11
+ public function getFetchRequest(){return $this->FetchRequest;} // FetchRequest
12
+
13
+ }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/BatchFileFetchResponse.class.php RENAMED
@@ -1,13 +1,13 @@
1
- <?php
2
- /**
3
- * BatchFileFetchResponse.class.php
4
- *
5
- * @package Batch
6
- */
7
- class BatchFileFetchResponse {
8
- private $BatchFileFetchResult; // BatchFileFetchResult
9
-
10
- public function setBatchFileFetchResult($value){$this->BatchFileFetchResult=$value;} // BatchFileFetchResult
11
- public function getBatchFileFetchResult(){return $this->BatchFileFetchResult;} // BatchFileFetchResult
12
-
13
- }
1
+ <?php
2
+ /**
3
+ * BatchFileFetchResponse.class.php
4
+ *
5
+ * @package Batch
6
+ */
7
+ class BatchFileFetchResponse {
8
+ private $BatchFileFetchResult; // BatchFileFetchResult
9
+
10
+ public function setBatchFileFetchResult($value){$this->BatchFileFetchResult=$value;} // BatchFileFetchResult
11
+ public function getBatchFileFetchResult(){return $this->BatchFileFetchResult;} // BatchFileFetchResult
12
+
13
+ }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/BatchFileFetchResult.class.php RENAMED
@@ -1,17 +1,17 @@
1
- <?php
2
- /**
3
- * BatchFileFetchResult.class.php
4
- *
5
- * @package Batch
6
- */
7
- class BatchFileFetchResult extends BaseResult {
8
- private $BatchFiles; // ArrayOfBatchFile
9
- private $RecordCount; // int
10
-
11
- public function setBatchFiles($value){$this->BatchFiles=$value;} // ArrayOfBatchFile
12
- public function getBatchFiles(){return $this->BatchFiles;} // ArrayOfBatchFile
13
-
14
- public function setRecordCount($value){$this->RecordCount=$value;} // int
15
- public function getRecordCount(){return $this->RecordCount;} // int
16
-
17
- }
1
+ <?php
2
+ /**
3
+ * BatchFileFetchResult.class.php
4
+ *
5
+ * @package Batch
6
+ */
7
+ class BatchFileFetchResult extends BaseResult {
8
+ private $BatchFiles; // ArrayOfBatchFile
9
+ private $RecordCount; // int
10
+
11
+ public function setBatchFiles($value){$this->BatchFiles=$value;} // ArrayOfBatchFile
12
+ public function getBatchFiles(){return $this->BatchFiles;} // ArrayOfBatchFile
13
+
14
+ public function setRecordCount($value){$this->RecordCount=$value;} // int
15
+ public function getRecordCount(){return $this->RecordCount;} // int
16
+
17
+ }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/BatchFileSave.class.php RENAMED
@@ -1,13 +1,13 @@
1
- <?php
2
- /**
3
- * BatchFileSave.class.php
4
- *
5
- * @package Batch
6
- */
7
- class BatchFileSave {
8
- private $BatchFile; // BatchFile
9
-
10
- public function setBatchFile($value){$this->BatchFile=$value;} // BatchFile
11
- public function getBatchFile(){return $this->BatchFile;} // BatchFile
12
-
13
  }
1
+ <?php
2
+ /**
3
+ * BatchFileSave.class.php
4
+ *
5
+ * @package Batch
6
+ */
7
+ class BatchFileSave {
8
+ private $BatchFile; // BatchFile
9
+
10
+ public function setBatchFile($value){$this->BatchFile=$value;} // BatchFile
11
+ public function getBatchFile(){return $this->BatchFile;} // BatchFile
12
+
13
  }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/BatchFileSaveResponse.class.php RENAMED
@@ -1,13 +1,13 @@
1
- <?php
2
- /**
3
- * BatchFileSaveResponse.class.php
4
- *
5
- * @package Batch
6
- */
7
- class BatchFileSaveResponse {
8
- private $BatchFileSaveResult; // BatchFileSaveResult
9
-
10
- public function setBatchFileSaveResult($value){$this->BatchFileSaveResult=$value;} // BatchFileSaveResult
11
- public function getBatchFileSaveResult(){return $this->BatchFileSaveResult;} // BatchFileSaveResult
12
-
13
  }
1
+ <?php
2
+ /**
3
+ * BatchFileSaveResponse.class.php
4
+ *
5
+ * @package Batch
6
+ */
7
+ class BatchFileSaveResponse {
8
+ private $BatchFileSaveResult; // BatchFileSaveResult
9
+
10
+ public function setBatchFileSaveResult($value){$this->BatchFileSaveResult=$value;} // BatchFileSaveResult
11
+ public function getBatchFileSaveResult(){return $this->BatchFileSaveResult;} // BatchFileSaveResult
12
+
13
  }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/BatchFileSaveResult.class.php RENAMED
@@ -1,13 +1,13 @@
1
- <?php
2
- /**
3
- * BatchFileSaveResult.class.php
4
- *
5
- * @package Batch
6
- */
7
- class BatchFileSaveResult extends BaseResult {
8
- private $BatchFileId; // int
9
-
10
- public function setBatchFileId($value){$this->BatchFileId=$value;} // int
11
- public function getBatchFileId(){return $this->BatchFileId;} // int
12
-
13
- }
1
+ <?php
2
+ /**
3
+ * BatchFileSaveResult.class.php
4
+ *
5
+ * @package Batch
6
+ */
7
+ class BatchFileSaveResult extends BaseResult {
8
+ private $BatchFileId; // int
9
+
10
+ public function setBatchFileId($value){$this->BatchFileId=$value;} // int
11
+ public function getBatchFileId(){return $this->BatchFileId;} // int
12
+
13
+ }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/BatchProcess.class.php RENAMED
@@ -1,13 +1,13 @@
1
- <?php
2
- /**
3
- * BatchProcess.class.php
4
- *
5
- * @package Batch
6
- */
7
- class BatchProcess {
8
- private $BatchProcessRequest; // BatchProcessRequest
9
-
10
- public function setBatchProcessRequest($value){$this->BatchProcessRequest=$value;} // BatchProcessRequest
11
- public function getBatchProcessRequest(){return $this->BatchProcessRequest;} // BatchProcessRequest
12
-
13
- }
1
+ <?php
2
+ /**
3
+ * BatchProcess.class.php
4
+ *
5
+ * @package Batch
6
+ */
7
+ class BatchProcess {
8
+ private $BatchProcessRequest; // BatchProcessRequest
9
+
10
+ public function setBatchProcessRequest($value){$this->BatchProcessRequest=$value;} // BatchProcessRequest
11
+ public function getBatchProcessRequest(){return $this->BatchProcessRequest;} // BatchProcessRequest
12
+
13
+ }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/BatchProcessRequest.class.php RENAMED
@@ -1,24 +1,24 @@
1
- <?php
2
- /**
3
- * BatchProcessRequest.class.php
4
- *
5
- * @package Batch
6
- */
7
- class BatchProcessRequest //extends FilterRequest
8
- {
9
- private $Filters; // string
10
- private $MaxCount; // int
11
-
12
- function __construct()
13
- {
14
- $this->MaxCount=0;
15
-
16
- }
17
-
18
- public function setFilters($value){$this->Filters=$value;} // string
19
- public function getFilters(){return $this->Filters;} // string
20
-
21
- public function setMaxCount($value){$this->MaxCount=$value;} // int
22
- public function getMaxCount(){return $this->MaxCount;} // int
23
-
24
- }
1
+ <?php
2
+ /**
3
+ * BatchProcessRequest.class.php
4
+ *
5
+ * @package Batch
6
+ */
7
+ class BatchProcessRequest //extends FilterRequest
8
+ {
9
+ private $Filters; // string
10
+ private $MaxCount; // int
11
+
12
+ function __construct()
13
+ {
14
+ $this->MaxCount=0;
15
+
16
+ }
17
+
18
+ public function setFilters($value){$this->Filters=$value;} // string
19
+ public function getFilters(){return $this->Filters;} // string
20
+
21
+ public function setMaxCount($value){$this->MaxCount=$value;} // int
22
+ public function getMaxCount(){return $this->MaxCount;} // int
23
+
24
+ }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/BatchProcessResponse.class.php RENAMED
@@ -1,13 +1,13 @@
1
- <?php
2
- /**
3
- * BatchProcessResponse.class.php
4
- *
5
- * @package Batch
6
- */
7
- class BatchProcessResponse {
8
- private $BatchProcessResult; // BatchProcessResult
9
-
10
- public function setBatchProcessResult($value){$this->BatchProcessResult=$value;} // BatchProcessResult
11
- public function getBatchProcessResult(){return $this->BatchProcessResult;} // BatchProcessResult
12
-
13
- }
1
+ <?php
2
+ /**
3
+ * BatchProcessResponse.class.php
4
+ *
5
+ * @package Batch
6
+ */
7
+ class BatchProcessResponse {
8
+ private $BatchProcessResult; // BatchProcessResult
9
+
10
+ public function setBatchProcessResult($value){$this->BatchProcessResult=$value;} // BatchProcessResult
11
+ public function getBatchProcessResult(){return $this->BatchProcessResult;} // BatchProcessResult
12
+
13
+ }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/BatchProcessResult.class.php RENAMED
@@ -1,9 +1,9 @@
1
- <?php
2
- /**
3
- * BatchProcessResult.class.php
4
- *
5
- * @package Batch
6
- */
7
- class BatchProcessResult extends BaseResult {
8
-
9
- }
1
+ <?php
2
+ /**
3
+ * BatchProcessResult.class.php
4
+ *
5
+ * @package Batch
6
+ */
7
+ class BatchProcessResult extends BaseResult {
8
+
9
+ }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/BatchSave.class.php RENAMED
@@ -1,13 +1,13 @@
1
- <?php
2
- /**
3
- * BatchSave.class.php
4
- *
5
- * @package Batch
6
- */
7
- class BatchSave {
8
- private $Batch; // Batch
9
-
10
- public function setBatch($value){$this->Batch=$value;} // Batch
11
- public function getBatch(){return $this->Batch;} // Batch
12
-
13
- }
1
+ <?php
2
+ /**
3
+ * BatchSave.class.php
4
+ *
5
+ * @package Batch
6
+ */
7
+ class BatchSave {
8
+ private $Batch; // Batch
9
+
10
+ public function setBatch($value){$this->Batch=$value;} // Batch
11
+ public function getBatch(){return $this->Batch;} // Batch
12
+
13
+ }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/BatchSaveResponse.class.php RENAMED
@@ -1,13 +1,13 @@
1
- <?php
2
- /**
3
- * BatchSaveResponse.class.php
4
- *
5
- * @package Batch
6
- */
7
- class BatchSaveResponse {
8
- private $BatchSaveResult; // BatchSaveResult
9
-
10
- public function setBatchSaveResult($value){$this->BatchSaveResult=$value;} // BatchSaveResult
11
- public function getBatchSaveResult(){return $this->BatchSaveResult;} // BatchSaveResult
12
-
13
- }
1
+ <?php
2
+ /**
3
+ * BatchSaveResponse.class.php
4
+ *
5
+ * @package Batch
6
+ */
7
+ class BatchSaveResponse {
8
+ private $BatchSaveResult; // BatchSaveResult
9
+
10
+ public function setBatchSaveResult($value){$this->BatchSaveResult=$value;} // BatchSaveResult
11
+ public function getBatchSaveResult(){return $this->BatchSaveResult;} // BatchSaveResult
12
+
13
+ }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/BatchSaveResult.class.php RENAMED
@@ -1,17 +1,17 @@
1
- <?php
2
- /**
3
- * BatchSaveResult.class.php
4
- *
5
- * @package Batch
6
- */
7
- class BatchSaveResult extends BaseResult {
8
- private $BatchId; // int
9
- private $EstimatedCompletion; // dateTime
10
-
11
- public function setBatchId($value){$this->BatchId=$value;} // int
12
- public function getBatchId(){return $this->BatchId;} // int
13
-
14
- public function setEstimatedCompletion($value){$this->EstimatedCompletion=$value;} // dateTime
15
- public function getEstimatedCompletion(){return $this->EstimatedCompletion;} // dateTime
16
-
17
- }
1
+ <?php
2
+ /**
3
+ * BatchSaveResult.class.php
4
+ *
5
+ * @package Batch
6
+ */
7
+ class BatchSaveResult extends BaseResult {
8
+ private $BatchId; // int
9
+ private $EstimatedCompletion; // dateTime
10
+
11
+ public function setBatchId($value){$this->BatchId=$value;} // int
12
+ public function getBatchId(){return $this->BatchId;} // int
13
+
14
+ public function setEstimatedCompletion($value){$this->EstimatedCompletion=$value;} // dateTime
15
+ public function getEstimatedCompletion(){return $this->EstimatedCompletion;} // dateTime
16
+
17
+ }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/BatchSvc.class.php RENAMED
@@ -1,173 +1,173 @@
1
- <?php
2
- /**
3
- * BatchSvc.class.php
4
- *
5
- * @package Batch
6
- */
7
-
8
-
9
- class BatchSvc extends SoapClient {
10
-
11
- private $client;
12
- private static $classmap = array(
13
- 'BatchFetch' => 'BatchFetch',
14
- 'FetchRequest' => 'FetchRequest',
15
- 'BatchFetchResponse' => 'BatchFetchResponse',
16
- 'BatchFetchResult' => 'BatchFetchResult',
17
- 'BaseResult' => 'BaseResult',
18
- 'SeverityLevel' => 'SeverityLevel',
19
- 'Message' => 'Message',
20
- 'Batch' => 'Batch',
21
- 'BatchFile' => 'BatchFile',
22
- 'Profile' => 'Profile',
23
- 'BatchSave' => 'BatchSave',
24
- 'BatchSaveResponse' => 'BatchSaveResponse',
25
- 'BatchSaveResult' => 'BatchSaveResult',
26
- 'AuditMessage' => 'AuditMessage',
27
- 'BatchDelete' => 'BatchDelete',
28
- 'DeleteRequest' => 'DeleteRequest',
29
- 'FilterRequest' => 'FilterRequest',
30
- 'BatchDeleteResponse' => 'BatchDeleteResponse',
31
- 'DeleteResult' => 'DeleteResult',
32
- 'FilterResult' => 'FilterResult',
33
- 'BatchProcess' => 'BatchProcess',
34
- 'BatchProcessRequest' => 'BatchProcessRequest',
35
- 'BatchProcessResponse' => 'BatchProcessResponse',
36
- 'BatchProcessResult' => 'BatchProcessResult',
37
- 'BatchFileFetch' => 'BatchFileFetch',
38
- 'BatchFileFetchResponse' => 'BatchFileFetchResponse',
39
- 'BatchFileFetchResult' => 'BatchFileFetchResult',
40
- 'BatchFileSave' => 'BatchFileSave',
41
- 'BatchFileSaveResponse' => 'BatchFileSaveResponse',
42
- 'BatchFileSaveResult' => 'BatchFileSaveResult',
43
- 'BatchFileDelete' => 'BatchFileDelete',
44
- 'BatchFileDeleteResponse' => 'BatchFileDeleteResponse',
45
- 'Ping' => 'Ping',
46
- 'PingResponse' => 'PingResponse',
47
- 'PingResult' => 'PingResult',
48
- 'IsAuthorized' => 'IsAuthorized',
49
- 'IsAuthorizedResponse' => 'IsAuthorizedResponse',
50
- 'IsAuthorizedResult' => 'IsAuthorizedResult',
51
- );
52
-
53
- public function __construct($configurationName = 'Default')
54
- {
55
- $config = new ATConfig($configurationName);
56
-
57
- $this->client = new DynamicSoapClient (
58
- $config->batchWSDL,
59
- array
60
- (
61
- 'location' => $config->url.$config->batchService,
62
- 'trace' => $config->trace,
63
- 'classmap' => BatchSvc::$classmap
64
- ),
65
- $config
66
- );
67
- }
68
-
69
- /**
70
- * Fetches one or more Batch
71
- *
72
- * @param BatchFetch $parameters
73
- * @return BatchFetchResponse
74
- */
75
- public function BatchFetch(&$fetchRequest) {
76
-
77
- return $this->client->BatchFetch(array('FetchRequest' => $fetchRequest))->getBatchFetchResult();
78
- }
79
-
80
- /**
81
- * Saves a Batch entry
82
- *
83
- * @param BatchSave $parameters
84
- * @return BatchSaveResponse
85
- */
86
- public function BatchSave(&$batch) {
87
-
88
- return $this->client->BatchSave(array('Batch' => $batch))->getBatchSaveResult();
89
-
90
- }
91
-
92
- /**
93
- * Deletes one or more Batches
94
- *
95
- * @param BatchDelete $parameters
96
- * @return BatchDeleteResponse
97
- */
98
- public function BatchDelete(&$deleteRequest) {
99
-
100
- return $this->client->BatchDelete(array('DeleteRequest' => $deleteRequest))->getBatchDeleteResult();
101
-
102
- }
103
-
104
- /**
105
- * Processes one or more Batches
106
- *
107
- * @param BatchProcess $parameters
108
- * @return BatchProcessResponse
109
- */
110
- public function BatchProcess(&$batchProcessRequest) {
111
-
112
- return $this->client->BatchProcess(array('BatchProcessRequest' => $batchProcessRequest))->getBatchProcessResult();
113
-
114
- }
115
-
116
- /**
117
- * Fetches one or more BatchFiles
118
- *
119
- * @param BatchFileFetch $parameters
120
- * @return BatchFileFetchResponse
121
- */
122
- public function BatchFileFetch(&$fetchRequest) {
123
-
124
- return $this->client->BatchFileFetch(array('FetchRequest' => $fetchRequest))->getBatchFileFetchResult();
125
-
126
- }
127
-
128
- /**
129
- * Saves a Batch File
130
- *
131
- * @param BatchFileSave $parameters
132
- * @return BatchFileSaveResponse
133
- */
134
- public function BatchFileSave(&$batchFile) {
135
-
136
- return $this->client->BatchFileSave(array('BatchFile' => $batchFile))->getBatchFileSaveResult();
137
-
138
- }
139
-
140
- /**
141
- * Deletes one or more BatchFiles
142
- *
143
- * @param BatchFileDelete $parameters
144
- * @return BatchFileDeleteResponse
145
- */
146
- public function BatchFileDelete(&$deleteRequest) {
147
-
148
- return $this->client->BatchFileDelete(array('DeleteRequest' => $deleteRequest))->getBatchFileDeleteResult();
149
-
150
- }
151
-
152
- /**
153
- * Tests connectivity and version of the service
154
- *
155
- * @param Ping $parameters
156
- * @return PingResponse
157
- */
158
- public function Ping($message = '') {
159
- return $this->client->Ping(array('Message' => $message))->getPingResult();
160
- }
161
-
162
- /**
163
- * Checks authentication and authorization to one or more operations on the service.
164
- *
165
- * @param IsAuthorized $parameters
166
- * @return IsAuthorizedResponse
167
- */
168
- public function IsAuthorized($operations)
169
- {
170
- return $this->client->IsAuthorized(array('Operations' => $operations))->getIsAuthorizedResult();
171
- }
172
-
173
- }
1
+ <?php
2
+ /**
3
+ * BatchSvc.class.php
4
+ *
5
+ * @package Batch
6
+ */
7
+
8
+
9
+ class BatchSvc extends SoapClient {
10
+
11
+ private $client;
12
+ private static $classmap = array(
13
+ 'BatchFetch' => 'BatchFetch',
14
+ 'FetchRequest' => 'FetchRequest',
15
+ 'BatchFetchResponse' => 'BatchFetchResponse',
16
+ 'BatchFetchResult' => 'BatchFetchResult',
17
+ 'BaseResult' => 'BaseResult',
18
+ 'SeverityLevel' => 'SeverityLevel',
19
+ 'Message' => 'Message',
20
+ 'Batch' => 'Batch',
21
+ 'BatchFile' => 'BatchFile',
22
+ 'Profile' => 'Profile',
23
+ 'BatchSave' => 'BatchSave',
24
+ 'BatchSaveResponse' => 'BatchSaveResponse',
25
+ 'BatchSaveResult' => 'BatchSaveResult',
26
+ 'AuditMessage' => 'AuditMessage',
27
+ 'BatchDelete' => 'BatchDelete',
28
+ 'DeleteRequest' => 'DeleteRequest',
29
+ 'FilterRequest' => 'FilterRequest',
30
+ 'BatchDeleteResponse' => 'BatchDeleteResponse',
31
+ 'DeleteResult' => 'DeleteResult',
32
+ 'FilterResult' => 'FilterResult',
33
+ 'BatchProcess' => 'BatchProcess',
34
+ 'BatchProcessRequest' => 'BatchProcessRequest',
35
+ 'BatchProcessResponse' => 'BatchProcessResponse',
36
+ 'BatchProcessResult' => 'BatchProcessResult',
37
+ 'BatchFileFetch' => 'BatchFileFetch',
38
+ 'BatchFileFetchResponse' => 'BatchFileFetchResponse',
39
+ 'BatchFileFetchResult' => 'BatchFileFetchResult',
40
+ 'BatchFileSave' => 'BatchFileSave',
41
+ 'BatchFileSaveResponse' => 'BatchFileSaveResponse',
42
+ 'BatchFileSaveResult' => 'BatchFileSaveResult',
43
+ 'BatchFileDelete' => 'BatchFileDelete',
44
+ 'BatchFileDeleteResponse' => 'BatchFileDeleteResponse',
45
+ 'Ping' => 'Ping',
46
+ 'PingResponse' => 'PingResponse',
47
+ 'PingResult' => 'PingResult',
48
+ 'IsAuthorized' => 'IsAuthorized',
49
+ 'IsAuthorizedResponse' => 'IsAuthorizedResponse',
50
+ 'IsAuthorizedResult' => 'IsAuthorizedResult',
51
+ );
52
+
53
+ public function __construct($configurationName = 'Default')
54
+ {
55
+ $config = new ATConfig($configurationName);
56
+
57
+ $this->client = new DynamicSoapClient (
58
+ $config->batchWSDL,
59
+ array
60
+ (
61
+ 'location' => $config->url.$config->batchService,
62
+ 'trace' => $config->trace,
63
+ 'classmap' => BatchSvc::$classmap
64
+ ),
65
+ $config
66
+ );
67
+ }
68
+
69
+ /**
70
+ * Fetches one or more Batch
71
+ *
72
+ * @param BatchFetch $parameters
73
+ * @return BatchFetchResponse
74
+ */
75
+ public function BatchFetch(&$fetchRequest) {
76
+
77
+ return $this->client->BatchFetch(array('FetchRequest' => $fetchRequest))->getBatchFetchResult();
78
+ }
79
+
80
+ /**
81
+ * Saves a Batch entry
82
+ *
83
+ * @param BatchSave $parameters
84
+ * @return BatchSaveResponse
85
+ */
86
+ public function BatchSave(&$batch) {
87
+
88
+ return $this->client->BatchSave(array('Batch' => $batch))->getBatchSaveResult();
89
+
90
+ }
91
+
92
+ /**
93
+ * Deletes one or more Batches
94
+ *
95
+ * @param BatchDelete $parameters
96
+ * @return BatchDeleteResponse
97
+ */
98
+ public function BatchDelete(&$deleteRequest) {
99
+
100
+ return $this->client->BatchDelete(array('DeleteRequest' => $deleteRequest))->getBatchDeleteResult();
101
+
102
+ }
103
+
104
+ /**
105
+ * Processes one or more Batches
106
+ *
107
+ * @param BatchProcess $parameters
108
+ * @return BatchProcessResponse
109
+ */
110
+ public function BatchProcess(&$batchProcessRequest) {
111
+
112
+ return $this->client->BatchProcess(array('BatchProcessRequest' => $batchProcessRequest))->getBatchProcessResult();
113
+
114
+ }
115
+
116
+ /**
117
+ * Fetches one or more BatchFiles
118
+ *
119
+ * @param BatchFileFetch $parameters
120
+ * @return BatchFileFetchResponse
121
+ */
122
+ public function BatchFileFetch(&$fetchRequest) {
123
+
124
+ return $this->client->BatchFileFetch(array('FetchRequest' => $fetchRequest))->getBatchFileFetchResult();
125
+
126
+ }
127
+
128
+ /**
129
+ * Saves a Batch File
130
+ *
131
+ * @param BatchFileSave $parameters
132
+ * @return BatchFileSaveResponse
133
+ */
134
+ public function BatchFileSave(&$batchFile) {
135
+
136
+ return $this->client->BatchFileSave(array('BatchFile' => $batchFile))->getBatchFileSaveResult();
137
+
138
+ }
139
+
140
+ /**
141
+ * Deletes one or more BatchFiles
142
+ *
143
+ * @param BatchFileDelete $parameters
144
+ * @return BatchFileDeleteResponse
145
+ */
146
+ public function BatchFileDelete(&$deleteRequest) {
147
+
148
+ return $this->client->BatchFileDelete(array('DeleteRequest' => $deleteRequest))->getBatchFileDeleteResult();
149
+
150
+ }
151
+
152
+ /**
153
+ * Tests connectivity and version of the service
154
+ *
155
+ * @param Ping $parameters
156
+ * @return PingResponse
157
+ */
158
+ public function Ping($message = '') {
159
+ return $this->client->Ping(array('Message' => $message))->getPingResult();
160
+ }
161
+
162
+ /**
163
+ * Checks authentication and authorization to one or more operations on the service.
164
+ *
165
+ * @param IsAuthorized $parameters
166
+ * @return IsAuthorizedResponse
167
+ */
168
+ public function IsAuthorized($operations)
169
+ {
170
+ return $this->client->IsAuthorized(array('Operations' => $operations))->getIsAuthorizedResult();
171
+ }
172
+
173
+ }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/DeleteRequest.class.php RENAMED
@@ -1,24 +1,24 @@
1
- <?php
2
- /**
3
- * DeleteRequest.class.php
4
- *
5
- * @package Batch
6
- */
7
- class DeleteRequest //extends FilterRequest
8
- {
9
- private $Filters; // string
10
- private $MaxCount; // int
11
-
12
- function __construct()
13
- {
14
- $this->MaxCount=0;
15
-
16
- }
17
-
18
- public function setFilters($value){$this->Filters=$value;} // string
19
- public function getFilters(){return $this->Filters;} // string
20
-
21
- public function setMaxCount($value){$this->MaxCount=$value;} // int
22
- public function getMaxCount(){return $this->MaxCount;} // int
23
-
24
- }
1
+ <?php
2
+ /**
3
+ * DeleteRequest.class.php
4
+ *
5
+ * @package Batch
6
+ */
7
+ class DeleteRequest //extends FilterRequest
8
+ {
9
+ private $Filters; // string
10
+ private $MaxCount; // int
11
+
12
+ function __construct()
13
+ {
14
+ $this->MaxCount=0;
15
+
16
+ }
17
+
18
+ public function setFilters($value){$this->Filters=$value;} // string
19
+ public function getFilters(){return $this->Filters;} // string
20
+
21
+ public function setMaxCount($value){$this->MaxCount=$value;} // int
22
+ public function getMaxCount(){return $this->MaxCount;} // int
23
+
24
+ }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/DeleteResult.class.php RENAMED
@@ -1,9 +1,9 @@
1
- <?php
2
- /**
3
- * DeleteResult.class.php
4
- *
5
- * @package Batch
6
- */
7
- class DeleteResult extends BaseResult {
8
-
9
  }
1
+ <?php
2
+ /**
3
+ * DeleteResult.class.php
4
+ *
5
+ * @package Batch
6
+ */
7
+ class DeleteResult extends BaseResult {
8
+
9
  }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/FetchRequest.class.php RENAMED
@@ -1,45 +1,45 @@
1
- <?php
2
- /**
3
- * FetchRequest.class.php
4
- *
5
- * @package Batch
6
- */
7
- class FetchRequest {
8
- private $Fields; // string
9
- private $Filters; // string
10
- private $Sort; // string
11
- private $MaxCount; // int
12
- private $PageIndex; // int
13
- private $PageSize; // int
14
- private $RecordCount; // int
15
-
16
- function __construct()
17
- {
18
- $this->MaxCount=0;
19
- $this->PageIndex=0;
20
- $this->PageSize=0;
21
- $this->RecordCount=0;
22
- }
23
-
24
- public function setFields($value){$this->Fields=$value;} // string
25
- public function getFields(){return $this->Fields;} // string
26
-
27
- public function setFilters($value){$this->Filters=$value;} // string
28
- public function getFilters(){return $this->Filters;} // string
29
-
30
- public function setSort($value){$this->Sort=$value;} // string
31
- public function getSort(){return $this->Sort;} // string
32
-
33
- public function setMaxCount($value){$this->MaxCount=$value;} // int
34
- public function getMaxCount(){return $this->MaxCount;} // int
35
-
36
- public function setPageIndex($value){$this->PageIndex=$value;} // int
37
- public function getPageIndex(){return $this->PageIndex;} // int
38
-
39
- public function setPageSize($value){$this->PageSize=$value;} // int
40
- public function getPageSize(){return $this->PageSize;} // int
41
-
42
- public function setRecordCount($value){$this->RecordCount=$value;} // int
43
- public function getRecordCount(){return $this->RecordCount;} // int
44
-
45
- }
1
+ <?php
2
+ /**
3
+ * FetchRequest.class.php
4
+ *
5
+ * @package Batch
6
+ */
7
+ class FetchRequest {
8
+ private $Fields; // string
9
+ private $Filters; // string
10
+ private $Sort; // string
11
+ private $MaxCount; // int
12
+ private $PageIndex; // int
13
+ private $PageSize; // int
14
+ private $RecordCount; // int
15
+
16
+ function __construct()
17
+ {
18
+ $this->MaxCount=0;
19
+ $this->PageIndex=0;
20
+ $this->PageSize=0;
21
+ $this->RecordCount=0;
22
+ }
23
+
24
+ public function setFields($value){$this->Fields=$value;} // string
25
+ public function getFields(){return $this->Fields;} // string
26
+
27
+ public function setFilters($value){$this->Filters=$value;} // string
28
+ public function getFilters(){return $this->Filters;} // string
29
+
30
+ public function setSort($value){$this->Sort=$value;} // string
31
+ public function getSort(){return $this->Sort;} // string
32
+
33
+ public function setMaxCount($value){$this->MaxCount=$value;} // int
34
+ public function getMaxCount(){return $this->MaxCount;} // int
35
+
36
+ public function setPageIndex($value){$this->PageIndex=$value;} // int
37
+ public function getPageIndex(){return $this->PageIndex;} // int
38
+
39
+ public function setPageSize($value){$this->PageSize=$value;} // int
40
+ public function getPageSize(){return $this->PageSize;} // int
41
+
42
+ public function setRecordCount($value){$this->RecordCount=$value;} // int
43
+ public function getRecordCount(){return $this->RecordCount;} // int
44
+
45
+ }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/FilterRequest.class.php RENAMED
@@ -1,23 +1,23 @@
1
- <?php
2
- /**
3
- * FilterRequest.class.php
4
- *
5
- * @package Batch
6
- */
7
- class FilterRequest {
8
- private $Filters; // string
9
- private $MaxCount; // int
10
-
11
- function __construct()
12
- {
13
- $this->MaxCount=0;
14
-
15
- }
16
-
17
- public function setFilters($value){$this->Filters=$value;} // string
18
- public function getFilters(){return $this->Filters;} // string
19
-
20
- public function setMaxCount($value){$this->MaxCount=$value;} // int
21
- public function getMaxCount(){return $this->MaxCount;} // int
22
-
23
  }
1
+ <?php
2
+ /**
3
+ * FilterRequest.class.php
4
+ *
5
+ * @package Batch
6
+ */
7
+ class FilterRequest {
8
+ private $Filters; // string
9
+ private $MaxCount; // int
10
+
11
+ function __construct()
12
+ {
13
+ $this->MaxCount=0;
14
+
15
+ }
16
+
17
+ public function setFilters($value){$this->Filters=$value;} // string
18
+ public function getFilters(){return $this->Filters;} // string
19
+
20
+ public function setMaxCount($value){$this->MaxCount=$value;} // int
21
+ public function getMaxCount(){return $this->MaxCount;} // int
22
+
23
  }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/FilterResult.class.php RENAMED
@@ -1,13 +1,13 @@
1
- <?php
2
- /**
3
- * FilterResult.class.php
4
- *
5
- * @package Batch
6
- */
7
- class FilterResult {
8
- private $Count; // int
9
-
10
- public function setCount($value){$this->Count=$value;} // int
11
- public function getCount(){return $this->Count;} // int
12
-
13
  }
1
+ <?php
2
+ /**
3
+ * FilterResult.class.php
4
+ *
5
+ * @package Batch
6
+ */
7
+ class FilterResult {
8
+ private $Count; // int
9
+
10
+ public function setCount($value){$this->Count=$value;} // int
11
+ public function getCount(){return $this->Count;} // int
12
+
13
  }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/IsAuthorized.class.php RENAMED
@@ -1,13 +1,13 @@
1
- <?php
2
- /**
3
- * IsAuthorized.class.php
4
- *
5
- * @package Batch
6
- */
7
- class IsAuthorized {
8
- private $Operations; // string
9
-
10
- public function setOperations($value){$this->Operations=$value;} // string
11
- public function getOperations(){return $this->Operations;} // string
12
-
13
- }
1
+ <?php
2
+ /**
3
+ * IsAuthorized.class.php
4
+ *
5
+ * @package Batch
6
+ */
7
+ class IsAuthorized {
8
+ private $Operations; // string
9
+
10
+ public function setOperations($value){$this->Operations=$value;} // string
11
+ public function getOperations(){return $this->Operations;} // string
12
+
13
+ }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/IsAuthorizedResponse.class.php RENAMED
@@ -1,13 +1,13 @@
1
- <?php
2
- /**
3
- * IsAuthorizedResponse.class.php
4
- *
5
- * @package Batch
6
- */
7
- class IsAuthorizedResponse {
8
- private $IsAuthorizedResult; // IsAuthorizedResult
9
-
10
- public function setIsAuthorizedResult($value){$this->IsAuthorizedResult=$value;} // IsAuthorizedResult
11
- public function getIsAuthorizedResult(){return $this->IsAuthorizedResult;} // IsAuthorizedResult
12
-
13
  }
1
+ <?php
2
+ /**
3
+ * IsAuthorizedResponse.class.php
4
+ *
5
+ * @package Batch
6
+ */
7
+ class IsAuthorizedResponse {
8
+ private $IsAuthorizedResult; // IsAuthorizedResult
9
+
10
+ public function setIsAuthorizedResult($value){$this->IsAuthorizedResult=$value;} // IsAuthorizedResult
11
+ public function getIsAuthorizedResult(){return $this->IsAuthorizedResult;} // IsAuthorizedResult
12
+
13
  }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/IsAuthorizedResult.class.php RENAMED
@@ -1,17 +1,17 @@
1
- <?php
2
- /**
3
- * IsAuthorizedResult.class.php
4
- *
5
- * @package Batch
6
- */
7
- class IsAuthorizedResult {
8
- private $Operations; // string
9
- private $Expires; // dateTime
10
-
11
- public function setOperations($value){$this->Operations=$value;} // string
12
- public function getOperations(){return $this->Operations;} // string
13
-
14
- public function setExpires($value){$this->Expires=$value;} // dateTime
15
- public function getExpires(){return $this->Expires;} // dateTime
16
-
17
- }
1
+ <?php
2
+ /**
3
+ * IsAuthorizedResult.class.php
4
+ *
5
+ * @package Batch
6
+ */
7
+ class IsAuthorizedResult {
8
+ private $Operations; // string
9
+ private $Expires; // dateTime
10
+
11
+ public function setOperations($value){$this->Operations=$value;} // string
12
+ public function getOperations(){return $this->Operations;} // string
13
+
14
+ public function setExpires($value){$this->Expires=$value;} // dateTime
15
+ public function getExpires(){return $this->Expires;} // dateTime
16
+
17
+ }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/Message.class.php RENAMED
@@ -1,37 +1,37 @@
1
- <?php
2
- /**
3
- * Message.class.php
4
- *
5
- * @package Batch
6
- */
7
- class Message {
8
- private $Summary; // string
9
- private $Details; // string
10
- private $HelpLink; // string
11
- private $RefersTo; // string
12
- private $Severity; // SeverityLevel
13
- private $Source; // string
14
- private $Name; // string
15
-
16
- public function setSummary($value){$this->Summary=$value;} // string
17
- public function getSummary(){return $this->Summary;} // string
18
-
19
- public function setDetails($value){$this->Details=$value;} // string
20
- public function getDetails(){return $this->Details;} // string
21
-
22
- public function setHelpLink($value){$this->HelpLink=$value;} // string
23
- public function getHelpLink(){return $this->HelpLink;} // string
24
-
25
- public function setRefersTo($value){$this->RefersTo=$value;} // string
26
- public function getRefersTo(){return $this->RefersTo;} // string
27
-
28
- public function setSeverity($value){$this->Severity=$value;} // SeverityLevel
29
- public function getSeverity(){return $this->Severity;} // SeverityLevel
30
-
31
- public function setSource($value){$this->Source=$value;} // string
32
- public function getSource(){return $this->Source;} // string
33
-
34
- public function setName($value){$this->Name=$value;} // string
35
- public function getName(){return $this->Name;} // string
36
-
37
- }
1
+ <?php
2
+ /**
3
+ * Message.class.php
4
+ *
5
+ * @package Batch
6
+ */
7
+ class Message {
8
+ private $Summary; // string
9
+ private $Details; // string
10
+ private $HelpLink; // string
11
+ private $RefersTo; // string
12
+ private $Severity; // SeverityLevel
13
+ private $Source; // string
14
+ private $Name; // string
15
+
16
+ public function setSummary($value){$this->Summary=$value;} // string
17
+ public function getSummary(){return $this->Summary;} // string
18
+
19
+ public function setDetails($value){$this->Details=$value;} // string
20
+ public function getDetails(){return $this->Details;} // string
21
+
22
+ public function setHelpLink($value){$this->HelpLink=$value;} // string
23
+ public function getHelpLink(){return $this->HelpLink;} // string
24
+
25
+ public function setRefersTo($value){$this->RefersTo=$value;} // string
26
+ public function getRefersTo(){return $this->RefersTo;} // string
27
+
28
+ public function setSeverity($value){$this->Severity=$value;} // SeverityLevel
29
+ public function getSeverity(){return $this->Severity;} // SeverityLevel
30
+
31
+ public function setSource($value){$this->Source=$value;} // string
32
+ public function getSource(){return $this->Source;} // string
33
+
34
+ public function setName($value){$this->Name=$value;} // string
35
+ public function getName(){return $this->Name;} // string
36
+
37
+ }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/Ping.class.php RENAMED
@@ -1,13 +1,13 @@
1
- <?php
2
- /**
3
- * Ping.class.php
4
- *
5
- * @package Batch
6
- */
7
- class Ping {
8
- private $Message; // string
9
-
10
- public function setMessage($value){$this->Message=$value;} // string
11
- public function getMessage(){return $this->Message;} // string
12
-
13
- }
1
+ <?php
2
+ /**
3
+ * Ping.class.php
4
+ *
5
+ * @package Batch
6
+ */
7
+ class Ping {
8
+ private $Message; // string
9
+
10
+ public function setMessage($value){$this->Message=$value;} // string
11
+ public function getMessage(){return $this->Message;} // string
12
+
13
+ }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/PingResponse.class.php RENAMED
@@ -1,13 +1,13 @@
1
- <?php
2
- /**
3
- * PingResponse.class.php
4
- *
5
- * @package Batch
6
- */
7
- class PingResponse {
8
- private $PingResult; // PingResult
9
-
10
- public function setPingResult($value){$this->PingResult=$value;} // PingResult
11
- public function getPingResult(){return $this->PingResult;} // PingResult
12
-
13
- }
1
+ <?php
2
+ /**
3
+ * PingResponse.class.php
4
+ *
5
+ * @package Batch
6
+ */
7
+ class PingResponse {
8
+ private $PingResult; // PingResult
9
+
10
+ public function setPingResult($value){$this->PingResult=$value;} // PingResult
11
+ public function getPingResult(){return $this->PingResult;} // PingResult
12
+
13
+ }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/PingResult.class.php RENAMED
@@ -1,26 +1,26 @@
1
- <?php
2
- /**
3
- * PingResult.class.php
4
- *
5
- * @package Batch
6
- */
7
- class PingResult extends BaseResult
8
- {
9
- private $Version; // string
10
-
11
- public function setVersion($value){$this->Version=$value;} // string
12
- public function getVersion(){return $this->Version;} // string
13
-
14
- //public function getTransactionId() { return $this->TransactionId; }
15
- /**
16
- * Accessor
17
- * @return string
18
- */
19
- //public function getResultCode() { return $this->ResultCode; }
20
- /**
21
- * Accessor
22
- * @return array
23
- */
24
- //public function getMessages() { return EnsureIsArray($this->Messages->Message);}
25
-
26
- }
1
+ <?php
2
+ /**
3
+ * PingResult.class.php
4
+ *
5
+ * @package Batch
6
+ */
7
+ class PingResult extends BaseResult
8
+ {
9
+ private $Version; // string
10
+
11
+ public function setVersion($value){$this->Version=$value;} // string
12
+ public function getVersion(){return $this->Version;} // string
13
+
14
+ //public function getTransactionId() { return $this->TransactionId; }
15
+ /**
16
+ * Accessor
17
+ * @return string
18
+ */
19
+ //public function getResultCode() { return $this->ResultCode; }
20
+ /**
21
+ * Accessor
22
+ * @return array
23
+ */
24
+ //public function getMessages() { return EnsureIsArray($this->Messages->Message);}
25
+
26
+ }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/Profile.class.php RENAMED
@@ -1,25 +1,25 @@
1
- <?php
2
- /**
3
- * Profile.class.php
4
- *
5
- * @package Batch
6
- */
7
- class Profile {
8
- private $Name; // string
9
- private $Client; // string
10
- private $Adapter; // string
11
- private $Machine; // string
12
-
13
- public function setName($value){$this->Name=$value;} // string
14
- public function getName(){return $this->Name;} // string
15
-
16
- public function setClient($value){$this->Client=$value;} // string
17
- public function getClient(){return $this->Client;} // string
18
-
19
- public function setAdapter($value){$this->Adapter=$value;} // string
20
- public function getAdapter(){return $this->Adapter;} // string
21
-
22
- public function setMachine($value){$this->Machine=$value;} // string
23
- public function getMachine(){return $this->Machine;} // string
24
-
25
  }
1
+ <?php
2
+ /**
3
+ * Profile.class.php
4
+ *
5
+ * @package Batch
6
+ */
7
+ class Profile {
8
+ private $Name; // string
9
+ private $Client; // string
10
+ private $Adapter; // string
11
+ private $Machine; // string
12
+
13
+ public function setName($value){$this->Name=$value;} // string
14
+ public function getName(){return $this->Name;} // string
15
+
16
+ public function setClient($value){$this->Client=$value;} // string
17
+ public function getClient(){return $this->Client;} // string
18
+
19
+ public function setAdapter($value){$this->Adapter=$value;} // string
20
+ public function getAdapter(){return $this->Adapter;} // string
21
+
22
+ public function setMachine($value){$this->Machine=$value;} // string
23
+ public function getMachine(){return $this->Machine;} // string
24
+
25
  }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BatchSvc/SeverityLevel.class.php RENAMED
@@ -1,13 +1,13 @@
1
- <?php
2
- /**
3
- * SeverityLevel.class.php
4
- *
5
- * @package Batch
6
- */
7
- class SeverityLevel {
8
- const Success = 'Success';
9
- const Warning = 'Warning';
10
- const Error = 'Error';
11
- const Exception = 'Exception';
12
-
13
  }
1
+ <?php
2
+ /**
3
+ * SeverityLevel.class.php
4
+ *
5
+ * @package Batch
6
+ */
7
+ class SeverityLevel {
8
+ const Success = 'Success';
9
+ const Warning = 'Warning';
10
+ const Error = 'Error';
11
+ const Exception = 'Exception';
12
+
13
  }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/BoundaryLevel.class.php RENAMED
@@ -1,57 +1,57 @@
1
- <?php
2
- /**
3
- * BoundaryLevel.class.php
4
- * @package Tax
5
- */
6
-
7
- /**
8
- * BoundaryLevel.class.php
9
- *
10
- * Jurisdiction boundary precision level found for address;
11
- * This depends on the accuracy of the address as well as the
12
- * precision level of the state provided jurisdiction boundaries.
13
- * @package Tax
14
- * @see TaxLine
15
- * @author tblanchard
16
- * Copyright (c) 2008, Avalara. All rights reserved.
17
- */
18
-
19
- class BoundaryLevel extends Enum
20
- {
21
-
22
- /**
23
- * Street address precision
24
- *
25
- * @var unknown_type
26
- */
27
- public static $Address = 'Address'; //enum
28
-
29
- /**
30
- *5-digit zip precision
31
- *
32
- * @var unknown_type
33
- */
34
- public static $Zip9 = 'Zip9'; //enum
35
-
36
- /**
37
- *9-digit zip precision
38
- *
39
- * @var unknown_type
40
- */
41
- public static $Zip5 = 'Zip5'; //enum
42
-
43
-
44
-
45
- public static function Values()
46
- {
47
- return array(
48
- BoundaryLevel::$Address,
49
- BoundaryLevel::$Zip9,
50
- BoundaryLevel::$Zip5
51
- );
52
- }
53
-
54
-
55
- // Unfortunate boiler plate due to polymorphism issues on static functions
56
- public static function Validate($value) { self::__Validate($value,self::Values(),__CLASS__); }
57
  }
1
+ <?php
2
+ /**
3
+ * BoundaryLevel.class.php
4
+ * @package Tax
5
+ */
6
+
7
+ /**
8
+ * BoundaryLevel.class.php
9
+ *
10
+ * Jurisdiction boundary precision level found for address;
11
+ * This depends on the accuracy of the address as well as the
12
+ * precision level of the state provided jurisdiction boundaries.
13
+ * @package Tax
14
+ * @see TaxLine
15
+ * @author tblanchard
16
+ * Copyright (c) 2008, Avalara. All rights reserved.
17
+ */
18
+
19
+ class BoundaryLevel extends Enum
20
+ {
21
+
22
+ /**
23
+ * Street address precision
24
+ *
25
+ * @var unknown_type
26
+ */
27
+ public static $Address = 'Address'; //enum
28
+
29
+ /**
30
+ *5-digit zip precision
31
+ *
32
+ * @var unknown_type
33
+ */
34
+ public static $Zip9 = 'Zip9'; //enum
35
+
36
+ /**
37
+ *9-digit zip precision
38
+ *
39
+ * @var unknown_type
40
+ */
41
+ public static $Zip5 = 'Zip5'; //enum
42
+
43
+
44
+
45
+ public static function Values()
46
+ {
47
+ return array(
48
+ BoundaryLevel::$Address,
49
+ BoundaryLevel::$Zip9,
50
+ BoundaryLevel::$Zip5
51
+ );
52
+ }
53
+
54
+
55
+ // Unfortunate boiler plate due to polymorphism issues on static functions
56
+ public static function Validate($value) { self::__Validate($value,self::Values(),__CLASS__); }
57
  }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/CancelCode.class.php RENAMED
@@ -1,72 +1,72 @@
1
- <?php
2
- /**
3
- * CancelCode.class.php
4
- *
5
- * @package Tax
6
- */
7
-
8
- /**
9
- * CancelCode.class.php
10
-
11
- * A cancel code is set on a {@link CancelTaxRequest} and specifies the reason the
12
- * tax calculation is being canceled (or in the case of posting, returned to its prior state).
13
- * @author tblanchard
14
- * @package Tax
15
- * @see CancelTaxRequest
16
- * Copyright (c) 2008, Avalara. All rights reserved.
17
-
18
- */
19
- class CancelCode extends Enum
20
- {
21
-
22
-
23
- /**
24
- * The operation failed for an unknown reason.
25
- */
26
-
27
- public static $Unspecified = 'Unspecified';
28
-
29
- /**
30
- * Specifies the post operation failed when attempting to post an invoice within
31
- * a client's application, for example, to the client's General Ledger; The
32
- * document's status will be changed to <b>Saved</b>.
33
- */
34
-
35
- public static $PostFailed = 'PostFailed';
36
-
37
- /**
38
- * Specifies the document was deleted within the client's application and
39
- * should be removed from the AvaTax records; If the document within AvaTax
40
- * is already committed, the document status will be changed to <b>Cancelled</b>
41
- * and retained for historical records; If the document was not committed,
42
- * (was <b>Saved</b> or <b>Posted</b>) the document will be deleted within AvaTax.
43
- */
44
-
45
- public static $DocDeleted = 'DocDeleted';
46
-
47
- /**
48
- * Specifies the document was voided within the client's application and
49
- * should be removed from the AvaTax records; If the document within AvaTax
50
- * is already committed, the document status will be changed to <b>Cancelled</b>
51
- * and retained for historical records; If the document was not committed,
52
- * (was <b>Saved</b> or <b>Posted</b>) the document will be deleted within AvaTax.
53
- */
54
- public static $DocVoided = 'DocVoided';
55
- public static $AdjustmentCancelled = 'AdjustmentCancelled';
56
-
57
-
58
- public static function Values()
59
- {
60
- return array(
61
- CancelCode::$Unspecified,
62
- CancelCode::$PostFailed,
63
- CancelCode::$DocDeleted,
64
- CancelCode::$DocVoided,
65
- CancelCode::$AdjustmentCancelled
66
- );
67
- }
68
-
69
- // Unfortunate boiler plate due to polymorphism issues on static functions
70
- public static function Validate($value) { self::__Validate($value,self::Values(),__CLASS__); }
71
-
72
  }
1
+ <?php
2
+ /**
3
+ * CancelCode.class.php
4
+ *
5
+ * @package Tax
6
+ */
7
+
8
+ /**
9
+ * CancelCode.class.php
10
+
11
+ * A cancel code is set on a {@link CancelTaxRequest} and specifies the reason the
12
+ * tax calculation is being canceled (or in the case of posting, returned to its prior state).
13
+ * @author tblanchard
14
+ * @package Tax
15
+ * @see CancelTaxRequest
16
+ * Copyright (c) 2008, Avalara. All rights reserved.
17
+
18
+ */
19
+ class CancelCode extends Enum
20
+ {
21
+
22
+
23
+ /**
24
+ * The operation failed for an unknown reason.
25
+ */
26
+
27
+ public static $Unspecified = 'Unspecified';
28
+
29
+ /**
30
+ * Specifies the post operation failed when attempting to post an invoice within
31
+ * a client's application, for example, to the client's General Ledger; The
32
+ * document's status will be changed to <b>Saved</b>.
33
+ */
34
+
35
+ public static $PostFailed = 'PostFailed';
36
+
37
+ /**
38
+ * Specifies the document was deleted within the client's application and
39
+ * should be removed from the AvaTax records; If the document within AvaTax
40
+ * is already committed, the document status will be changed to <b>Cancelled</b>
41
+ * and retained for historical records; If the document was not committed,
42
+ * (was <b>Saved</b> or <b>Posted</b>) the document will be deleted within AvaTax.
43
+ */
44
+
45
+ public static $DocDeleted = 'DocDeleted';
46
+
47
+ /**
48
+ * Specifies the document was voided within the client's application and
49
+ * should be removed from the AvaTax records; If the document within AvaTax
50
+ * is already committed, the document status will be changed to <b>Cancelled</b>
51
+ * and retained for historical records; If the document was not committed,
52
+ * (was <b>Saved</b> or <b>Posted</b>) the document will be deleted within AvaTax.
53
+ */
54
+ public static $DocVoided = 'DocVoided';
55
+ public static $AdjustmentCancelled = 'AdjustmentCancelled';
56
+
57
+
58
+ public static function Values()
59
+ {
60
+ return array(
61
+ CancelCode::$Unspecified,
62
+ CancelCode::$PostFailed,
63
+ CancelCode::$DocDeleted,
64
+ CancelCode::$DocVoided,
65
+ CancelCode::$AdjustmentCancelled
66
+ );
67
+ }
68
+
69
+ // Unfortunate boiler plate due to polymorphism issues on static functions
70
+ public static function Validate($value) { self::__Validate($value,self::Values(),__CLASS__); }
71
+
72
  }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/CancelTaxRequest.class.php RENAMED
@@ -1,55 +1,55 @@
1
- <?php
2
- /**
3
- * CancelTaxRequest.class.php
4
- * @package Tax
5
- */
6
-
7
-
8
- /**
9
- * Data to pass to CancelTax indicating
10
- * the document that should be cancelled and the reason for the operation.
11
- * <p>
12
- * A document can be indicated solely by the DocId if it is known.
13
- * Otherwise the request must specify all of CompanyCode,
14
- * DocCode, and
15
- * DocType in order to uniquely identify the document.
16
- * </p>
17
- *
18
- * @package Tax
19
- * @see CancelTaxResult, DocumentType
20
- * @author tblanchard
21
- * Copyright (c) 2008, Avalara. All rights reserved.
22
- *
23
- */
24
-
25
- class CancelTaxRequest extends TaxRequest
26
- {
27
- private $CancelCode; //Unspecified or PostFailed or DocDeleted or DocVoided or AdjustmentCancelled
28
-
29
- public function __construct()
30
- {
31
- $this->DocType = DocumentType::$SalesInvoice; // this is right Document
32
- $this->CancelCode = CancelCode::$Unspecified;
33
- }
34
-
35
-
36
- /**
37
- * A code indicating the reason the document is getting canceled.
38
- *
39
- * @return string
40
- * @see CancelCode
41
- */
42
-
43
- public function getCancelCode() { return $this->CancelCode; }
44
-
45
-
46
- /**
47
- * A code indicating the reason the document is getting canceled.
48
- *
49
- * @var string
50
- * @see CancelCode
51
- */
52
-
53
- public function setCancelCode($value) { CancelCode::Validate($value); $this->CancelCode = $value; return $this; }
54
-
55
  }
1
+ <?php
2
+ /**
3
+ * CancelTaxRequest.class.php
4
+ * @package Tax
5
+ */
6
+
7
+
8
+ /**
9
+ * Data to pass to CancelTax indicating
10
+ * the document that should be cancelled and the reason for the operation.
11
+ * <p>
12
+ * A document can be indicated solely by the DocId if it is known.
13
+ * Otherwise the request must specify all of CompanyCode,
14
+ * DocCode, and
15
+ * DocType in order to uniquely identify the document.
16
+ * </p>
17
+ *
18
+ * @package Tax
19
+ * @see CancelTaxResult, DocumentType
20
+ * @author tblanchard
21
+ * Copyright (c) 2008, Avalara. All rights reserved.
22
+ *
23
+ */
24
+
25
+ class CancelTaxRequest extends TaxRequest
26
+ {
27
+ private $CancelCode; //Unspecified or PostFailed or DocDeleted or DocVoided or AdjustmentCancelled
28
+
29
+ public function __construct()
30
+ {
31
+ $this->DocType = DocumentType::$SalesInvoice; // this is right Document
32
+ $this->CancelCode = CancelCode::$Unspecified;
33
+ }
34
+
35
+
36
+ /**
37
+ * A code indicating the reason the document is getting canceled.
38
+ *
39
+ * @return string
40
+ * @see CancelCode
41
+ */
42
+
43
+ public function getCancelCode() { return $this->CancelCode; }
44
+
45
+
46
+ /**
47
+ * A code indicating the reason the document is getting canceled.
48
+ *
49
+ * @var string
50
+ * @see CancelCode
51
+ */
52
+
53
+ public function setCancelCode($value) { CancelCode::Validate($value); $this->CancelCode = $value; return $this; }
54
+
55
  }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/CancelTaxResult.class.php RENAMED
@@ -1,56 +1,56 @@
1
- <?php
2
- /**
3
- * CancelTaxResult.class.php
4
- *
5
- * @package Tax
6
- */
7
-
8
- /**
9
- * CancelTaxResult.class.php
10
- *
11
- **
12
- * Result data returned from {@link TaxSvcSoap#cancelTax}
13
- * @see CancelTaxRequest
14
- * @author tblanchard
15
- * @package Tax
16
- * Copyright (c) 2008, Avalara. All rights reserved.
17
- */
18
-
19
- class CancelTaxResult // extends BaseResult
20
- {
21
-
22
-
23
- // BaseResult innards - workaround a bug in SoapClient
24
-
25
- /**
26
- * @var string
27
- */
28
- private $TransactionId;
29
- /**
30
- * @var string must be one of the values defined in {@link SeverityLevel}.
31
- */
32
- private $ResultCode = 'Success';
33
- /**
34
- * @var array of Message.
35
- */
36
- private $Messages = array();
37
-
38
- /**
39
- * Accessor
40
- * @return string
41
- */
42
- public function getTransactionId() { return $this->TransactionId; }
43
- /**
44
- * Accessor
45
- * @return string
46
- */
47
- public function getResultCode() { return $this->ResultCode; }
48
- /**
49
- * Accessor
50
- * @return array
51
- */
52
- public function getMessages() { return EnsureIsArray($this->Messages->Message); }
53
-
54
-
55
-
56
  }
1
+ <?php
2
+ /**
3
+ * CancelTaxResult.class.php
4
+ *
5
+ * @package Tax
6
+ */
7
+
8
+ /**
9
+ * CancelTaxResult.class.php
10
+ *
11
+ **
12
+ * Result data returned from {@link TaxSvcSoap#cancelTax}
13
+ * @see CancelTaxRequest
14
+ * @author tblanchard
15
+ * @package Tax
16
+ * Copyright (c) 2008, Avalara. All rights reserved.
17
+ */
18
+
19
+ class CancelTaxResult // extends BaseResult
20
+ {
21
+
22
+
23
+ // BaseResult innards - workaround a bug in SoapClient
24
+
25
+ /**
26
+ * @var string
27
+ */
28
+ private $TransactionId;
29
+ /**
30
+ * @var string must be one of the values defined in {@link SeverityLevel}.
31
+ */
32
+ private $ResultCode = 'Success';
33
+ /**
34
+ * @var array of Message.
35
+ */
36
+ private $Messages = array();
37
+
38
+ /**
39
+ * Accessor
40
+ * @return string
41
+ */
42
+ public function getTransactionId() { return $this->TransactionId; }
43
+ /**
44
+ * Accessor
45
+ * @return string
46
+ */
47
+ public function getResultCode() { return $this->ResultCode; }
48
+ /**
49
+ * Accessor
50
+ * @return array
51
+ */
52
+ public function getMessages() { return EnsureIsArray($this->Messages->Message); }
53
+
54
+
55
+
56
  }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/CommitTaxRequest.class.php RENAMED
@@ -1,43 +1,43 @@
1
- <?php
2
- /**
3
- * CommitTaxRequest.class.php
4
- * @package Tax
5
- */
6
-
7
- /**
8
- * Data to pass to {@link TaxServiceSoap#commitTax}.
9
- * <p>
10
- * A document can be indicated solely by the {@link CommitTaxRequest#DocId} if it is known.
11
- * Otherwise the request must specify all of {@link CommitTaxRequest#CompanyCode},
12
- * {@link CommitTaxRequest#DocCode}, and
13
- * {@link CommitTaxRequest#tDocType} in order to uniquely identify the document.
14
- * </p>
15
- *
16
- * @package Tax
17
- * @see CommitTaxResult
18
- * @author tblanchard
19
- * Copyright (c) 2007, Avalara. All rights reserved.
20
- */
21
-
22
- class CommitTaxRequest extends TaxRequest
23
- {
24
- private $NewDocCode; //string
25
-
26
- /**
27
- * As on this version of SDK DocCode can be changed during commit using NewDocCode.
28
- *
29
- * @return string
30
- */
31
- public function getNewDocCode() { return $this->NewDocCode; }
32
-
33
- /**
34
- * As on this version of SDK DocCode can be changed during commit using NewDocCode.
35
- *
36
- * @param string $value
37
- */
38
- public function setNewDocCode($value) { $this->NewDocCode = $value; }
39
-
40
-
41
-
42
-
43
  }
1
+ <?php
2
+ /**
3
+ * CommitTaxRequest.class.php
4
+ * @package Tax
5
+ */
6
+
7
+ /**
8
+ * Data to pass to {@link TaxServiceSoap#commitTax}.
9
+ * <p>
10
+ * A document can be indicated solely by the {@link CommitTaxRequest#DocId} if it is known.
11
+ * Otherwise the request must specify all of {@link CommitTaxRequest#CompanyCode},
12
+ * {@link CommitTaxRequest#DocCode}, and
13
+ * {@link CommitTaxRequest#tDocType} in order to uniquely identify the document.
14
+ * </p>
15
+ *
16
+ * @package Tax
17
+ * @see CommitTaxResult
18
+ * @author tblanchard
19
+ * Copyright (c) 2007, Avalara. All rights reserved.
20
+ */
21
+
22
+ class CommitTaxRequest extends TaxRequest
23
+ {
24
+ private $NewDocCode; //string
25
+
26
+ /**
27
+ * As on this version of SDK DocCode can be changed during commit using NewDocCode.
28
+ *
29
+ * @return string
30
+ */
31
+ public function getNewDocCode() { return $this->NewDocCode; }
32
+
33
+ /**
34
+ * As on this version of SDK DocCode can be changed during commit using NewDocCode.
35
+ *
36
+ * @param string $value
37
+ */
38
+ public function setNewDocCode($value) { $this->NewDocCode = $value; }
39
+
40
+
41
+
42
+
43
  }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/CommitTaxResult.class.php RENAMED
@@ -1,52 +1,52 @@
1
- <?php
2
- /**
3
- * CommitTaxResult.class.php
4
- * @package Tax
5
- */
6
-
7
- /**
8
- * Result data returned from {@link TaxServiceSoap#commitTax}.
9
- *
10
- * @package Tax
11
- * @see CommitTaxRequest
12
- * @author tblanchard
13
- * Copyright (c) 2008, Avalara. All rights reserved.
14
- */
15
-
16
- class CommitTaxResult //extends BaseResult
17
- {
18
-
19
-
20
- // BaseResult innards - workaround a bug in SoapClient
21
-
22
- /**
23
- * @var string
24
- */
25
- private $TransactionId;
26
- /**
27
- * @var string must be one of the values defined in {@link SeverityLevel}.
28
- */
29
- private $ResultCode = 'Success';
30
- /**
31
- * @var array of Message.
32
- */
33
- private $Messages = array();
34
-
35
- /**
36
- * Accessor
37
- * @return string
38
- */
39
- public function getTransactionId() { return $this->TransactionId; }
40
- /**
41
- * Accessor
42
- * @return string
43
- */
44
- public function getResultCode() { return $this->ResultCode; }
45
- /**
46
- * Accessor
47
- * @return array
48
- */
49
- public function getMessages() { return EnsureIsArray($this->Messages->Message); }
50
-
51
-
52
  }
1
+ <?php
2
+ /**
3
+ * CommitTaxResult.class.php
4
+ * @package Tax
5
+ */
6
+
7
+ /**
8
+ * Result data returned from {@link TaxServiceSoap#commitTax}.
9
+ *
10
+ * @package Tax
11
+ * @see CommitTaxRequest
12
+ * @author tblanchard
13
+ * Copyright (c) 2008, Avalara. All rights reserved.
14
+ */
15
+
16
+ class CommitTaxResult //extends BaseResult
17
+ {
18
+
19
+
20
+ // BaseResult innards - workaround a bug in SoapClient
21
+
22
+ /**
23
+ * @var string
24
+ */
25
+ private $TransactionId;
26
+ /**
27
+ * @var string must be one of the values defined in {@link SeverityLevel}.
28
+ */
29
+ private $ResultCode = 'Success';
30
+ /**
31
+ * @var array of Message.
32
+ */
33
+ private $Messages = array();
34
+
35
+ /**
36
+ * Accessor
37
+ * @return string
38
+ */
39
+ public function getTransactionId() { return $this->TransactionId; }
40
+ /**
41
+ * Accessor
42
+ * @return string
43
+ */
44
+ public function getResultCode() { return $this->ResultCode; }
45
+ /**
46
+ * Accessor
47
+ * @return array
48
+ */
49
+ public function getMessages() { return EnsureIsArray($this->Messages->Message); }
50
+
51
+
52
  }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/DetailLevel.class.php RENAMED
@@ -1,55 +1,55 @@
1
- <?php
2
- /**
3
- * DetailLevel.class.php
4
- * @package Tax
5
- */
6
-
7
- /**
8
- * Specifies the level of tax detail to return to the client application following a tax calculation.
9
- *
10
- * @package Tax
11
- * @see GetTaxRequest, GetTaxHistoryRequest
12
- * @author tblanchard
13
- * Copyright (c) 2007, Avalara. All rights reserved. */
14
-
15
-
16
- class DetailLevel extends Enum
17
- {
18
- /**
19
- * Reserved for future use.
20
- */
21
- public static $Summary = 'Summary';
22
-
23
- /**
24
- * Document ({@link GetTaxResult}) level details; {@link ArrayOfTaxLine} will not be returned.
25
- */
26
- public static $Document = 'Document';
27
-
28
- /**
29
- * Line level details (includes Document details). {@link ArrayOfTaxLine} will
30
- * be returned but {@link ArrayOfTaxDetail} will not be returned.
31
- */
32
- public static $Line = 'Line';
33
-
34
- /**
35
- * Tax jurisdiction level details (includes Document, {@link ArrayOfTaxLine},
36
- * and {@link ArrayOfTaxDetail})
37
- */
38
- public static $Tax = 'Tax';
39
- public static $Diagnostic = 'Diagnostic';
40
-
41
-
42
- public static function Values()
43
- {
44
- return array(
45
- DetailLevel::$Summary,
46
- DetailLevel::$Document,
47
- DetailLevel::$Line,
48
- DetailLevel::$Tax,
49
- DetailLevel::$Diagnostic
50
- );
51
- }
52
-
53
- // Unfortunate boiler plate due to polymorphism issues on static functions
54
- public static function Validate($value) { self::__Validate($value,self::Values(),__CLASS__); }
55
  }
1
+ <?php
2
+ /**
3
+ * DetailLevel.class.php
4
+ * @package Tax
5
+ */
6
+
7
+ /**
8
+ * Specifies the level of tax detail to return to the client application following a tax calculation.
9
+ *
10
+ * @package Tax
11
+ * @see GetTaxRequest, GetTaxHistoryRequest
12
+ * @author tblanchard
13
+ * Copyright (c) 2007, Avalara. All rights reserved. */
14
+
15
+
16
+ class DetailLevel extends Enum
17
+ {
18
+ /**
19
+ * Reserved for future use.
20
+ */
21
+ public static $Summary = 'Summary';
22
+
23
+ /**
24
+ * Document ({@link GetTaxResult}) level details; {@link ArrayOfTaxLine} will not be returned.
25
+ */
26
+ public static $Document = 'Document';
27
+
28
+ /**
29
+ * Line level details (includes Document details). {@link ArrayOfTaxLine} will
30
+ * be returned but {@link ArrayOfTaxDetail} will not be returned.
31
+ */
32
+ public static $Line = 'Line';
33
+
34
+ /**
35
+ * Tax jurisdiction level details (includes Document, {@link ArrayOfTaxLine},
36
+ * and {@link ArrayOfTaxDetail})
37
+ */
38
+ public static $Tax = 'Tax';
39
+ public static $Diagnostic = 'Diagnostic';
40
+
41
+
42
+ public static function Values()
43
+ {
44
+ return array(
45
+ DetailLevel::$Summary,
46
+ DetailLevel::$Document,
47
+ DetailLevel::$Line,
48
+ DetailLevel::$Tax,
49
+ DetailLevel::$Diagnostic
50
+ );
51
+ }
52
+
53
+ // Unfortunate boiler plate due to polymorphism issues on static functions
54
+ public static function Validate($value) { self::__Validate($value,self::Values(),__CLASS__); }
55
  }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/DocStatus.class.php RENAMED
@@ -1,85 +1,85 @@
1
- <?php
2
- /**
3
- * DocStatus.class.php
4
- * @package Tax
5
- */
6
-
7
- /**
8
- * The document's status is returned in the GetTaxResult (except for <b>DocStatus::$Any</b>)
9
- * and indicates the state of the document in tax history.
10
- *
11
- * @package Tax
12
- * @author tblanchard
13
- * Copyright (c) 2007, Avalara. All rights reserved.
14
- */
15
-
16
-
17
- class DocStatus extends Enum
18
- {
19
-
20
- /**
21
- * A temporary document not saved (DocumentType was SalesOrder, PurchaseOrder, ReturnOrder)
22
- *
23
- * @var unknown_type
24
- */
25
- public static $Temporary= 'Temporary';
26
-
27
- /**
28
- * A saved document (DocumentType was SalesInvoice, PurchaseInvoice, ReturnInvoice) ready to be posted.
29
- *
30
- * @var DocStatus
31
- */
32
- public static $Saved = 'Saved';
33
-
34
- /**
35
- * A posted document (not committed).
36
- *
37
- * @var DocStatus
38
- */
39
- public static $Posted = 'Posted';
40
-
41
- /**
42
- * A posted document that has been committed.
43
- *
44
- * @var DocStatus
45
- */
46
- public static $Committed = 'Committed';
47
-
48
- /**
49
- * A committed document that has been cancelled.
50
- *
51
- * @var DocStatus
52
- */
53
- public static $Cancelled = 'Cancelled';
54
-
55
- /**
56
- * Enter description here...
57
- *
58
- * @var DocStatus
59
- */
60
- public static $Adjusted = 'Adjusted';
61
-
62
- /**
63
- * Any status (used for searching)
64
- *
65
- * @var DocStatus
66
- */
67
- public static $Any = 'Any';
68
-
69
-
70
- public static function Values()
71
- {
72
- return array(
73
- DocStatus::$Temporary,
74
- DocStatus::$Saved,
75
- DocStatus::$Posted,
76
- DocStatus::$Committed,
77
- DocStatus::$Cancelled,
78
- DocStatus::$Adjusted,
79
- DocStatus::$Any
80
- );
81
- }
82
- // Unfortunate boiler plate due to polymorphism issues on static functions
83
- public static function Validate($value) { self::__Validate($value,self::Values(),__CLASS__); }
84
-
85
  }
1
+ <?php
2
+ /**
3
+ * DocStatus.class.php
4
+ * @package Tax
5
+ */
6
+
7
+ /**
8
+ * The document's status is returned in the GetTaxResult (except for <b>DocStatus::$Any</b>)
9
+ * and indicates the state of the document in tax history.
10
+ *
11
+ * @package Tax
12
+ * @author tblanchard
13
+ * Copyright (c) 2007, Avalara. All rights reserved.
14
+ */
15
+
16
+
17
+ class DocStatus extends Enum
18
+ {
19
+
20
+ /**
21
+ * A temporary document not saved (DocumentType was SalesOrder, PurchaseOrder, ReturnOrder)
22
+ *
23
+ * @var unknown_type
24
+ */
25
+ public static $Temporary= 'Temporary';
26
+
27
+ /**
28
+ * A saved document (DocumentType was SalesInvoice, PurchaseInvoice, ReturnInvoice) ready to be posted.
29
+ *
30
+ * @var DocStatus
31
+ */
32
+ public static $Saved = 'Saved';
33
+
34
+ /**
35
+ * A posted document (not committed).
36
+ *
37
+ * @var DocStatus
38
+ */
39
+ public static $Posted = 'Posted';
40
+
41
+ /**
42
+ * A posted document that has been committed.
43
+ *
44
+ * @var DocStatus
45
+ */
46
+ public static $Committed = 'Committed';
47
+
48
+ /**
49
+ * A committed document that has been cancelled.
50
+ *
51
+ * @var DocStatus
52
+ */
53
+ public static $Cancelled = 'Cancelled';
54
+
55
+ /**
56
+ * Enter description here...
57
+ *
58
+ * @var DocStatus
59
+ */
60
+ public static $Adjusted = 'Adjusted';
61
+
62
+ /**
63
+ * Any status (used for searching)
64
+ *
65
+ * @var DocStatus
66
+ */
67
+ public static $Any = 'Any';
68
+
69
+
70
+ public static function Values()
71
+ {
72
+ return array(
73
+ DocStatus::$Temporary,
74
+ DocStatus::$Saved,
75
+ DocStatus::$Posted,
76
+ DocStatus::$Committed,
77
+ DocStatus::$Cancelled,
78
+ DocStatus::$Adjusted,
79
+ DocStatus::$Any
80
+ );
81
+ }
82
+ // Unfortunate boiler plate due to polymorphism issues on static functions
83
+ public static function Validate($value) { self::__Validate($value,self::Values(),__CLASS__); }
84
+
85
  }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/DocumentType.class.php RENAMED
@@ -1,88 +1,88 @@
1
- <?php
2
- /**
3
- * DocumentType.class.php
4
- *
5
- * @package Tax
6
- */
7
-
8
- /**
9
- * The document type specifies the category of the document and affects how the document
10
- * is treated after a tax calculation. Specified when constructing a {@link GetTaxRequest}.
11
- *
12
- * @package Tax
13
- * @author tblanchard
14
- * Copyright (c) 2008, Avalara. All rights reserved.
15
- */
16
-
17
-
18
- class DocumentType extends Enum
19
- {
20
-
21
- /**
22
- * Sales Order, estimate or quote.
23
- *
24
- * @var DocumentType
25
- */
26
- public static $SalesOrder = 'SalesOrder';
27
-
28
- /**
29
- * The document is a permanent invoice; document and tax calculation results are saved in the tax history.
30
- *
31
- * @var DocumentType
32
- */
33
- public static $SalesInvoice = 'SalesInvoice';
34
-
35
- /**
36
- * Purchase order, estimate, or quote.
37
- *
38
- * @var DocumentType
39
- */
40
- public static $PurchaseOrder = 'PurchaseOrder';
41
-
42
- /**
43
- * The document is a permanent invoice; document and tax calculation results are saved in the tax history.
44
- *
45
- * @var DocumentType
46
- */
47
- public static $PurchaseInvoice = 'PurchaseInvoice';
48
-
49
- /**
50
- *Sales Return Order.
51
- *
52
- * @var DocumentType
53
- */
54
- public static $ReturnOrder = 'ReturnOrder';
55
-
56
- /**
57
- * The document is a permanent sales return invoice; document and tax calculation results are saved in the tax history GetTaxResult will return with a DocStatus of Saved.
58
- *
59
- * @var DocumentType
60
- */
61
- public static $ReturnInvoice = 'ReturnInvoice';
62
-
63
- /**
64
- * This will return all types of documents.
65
- *
66
- * @var DocumentType
67
- */
68
- public static $Any = 'Any';
69
-
70
- public static function Values()
71
- {
72
- return array(
73
- DocumentType::$SalesOrder,
74
- DocumentType::$SalesInvoice,
75
- DocumentType::$PurchaseOrder,
76
- DocumentType::$PurchaseInvoice,
77
- DocumentType::$ReturnOrder,
78
- DocumentType::$ReturnInvoice,
79
- DocumentType::$Any
80
- );
81
- }
82
- // Unfortunate boiler plate due to polymorphism issues on static functions
83
- public static function Validate($value) { self::__Validate($value,self::Values(),__CLASS__); }
84
-
85
-
86
-
87
-
88
  }
1
+ <?php
2
+ /**
3
+ * DocumentType.class.php
4
+ *
5
+ * @package Tax
6
+ */
7
+
8
+ /**
9
+ * The document type specifies the category of the document and affects how the document
10
+ * is treated after a tax calculation. Specified when constructing a {@link GetTaxRequest}.
11
+ *
12
+ * @package Tax
13
+ * @author tblanchard
14
+ * Copyright (c) 2008, Avalara. All rights reserved.
15
+ */
16
+
17
+
18
+ class DocumentType extends Enum
19
+ {
20
+
21
+ /**
22
+ * Sales Order, estimate or quote.
23
+ *
24
+ * @var DocumentType
25
+ */
26
+ public static $SalesOrder = 'SalesOrder';
27
+
28
+ /**
29
+ * The document is a permanent invoice; document and tax calculation results are saved in the tax history.
30
+ *
31
+ * @var DocumentType
32
+ */
33
+ public static $SalesInvoice = 'SalesInvoice';
34
+
35
+ /**
36
+ * Purchase order, estimate, or quote.
37
+ *
38
+ * @var DocumentType
39
+ */
40
+ public static $PurchaseOrder = 'PurchaseOrder';
41
+
42
+ /**
43
+ * The document is a permanent invoice; document and tax calculation results are saved in the tax history.
44
+ *
45
+ * @var DocumentType
46
+ */
47
+ public static $PurchaseInvoice = 'PurchaseInvoice';
48
+
49
+ /**
50
+ *Sales Return Order.
51
+ *
52
+ * @var DocumentType
53
+ */
54
+ public static $ReturnOrder = 'ReturnOrder';
55
+
56
+ /**
57
+ * The document is a permanent sales return invoice; document and tax calculation results are saved in the tax history GetTaxResult will return with a DocStatus of Saved.
58
+ *
59
+ * @var DocumentType
60
+ */
61
+ public static $ReturnInvoice = 'ReturnInvoice';
62
+
63
+ /**
64
+ * This will return all types of documents.
65
+ *
66
+ * @var DocumentType
67
+ */
68
+ public static $Any = 'Any';
69
+
70
+ public static function Values()
71
+ {
72
+ return array(
73
+ DocumentType::$SalesOrder,
74
+ DocumentType::$SalesInvoice,
75
+ DocumentType::$PurchaseOrder,
76
+ DocumentType::$PurchaseInvoice,
77
+ DocumentType::$ReturnOrder,
78
+ DocumentType::$ReturnInvoice,
79
+ DocumentType::$Any
80
+ );
81
+ }
82
+ // Unfortunate boiler plate due to polymorphism issues on static functions
83
+ public static function Validate($value) { self::__Validate($value,self::Values(),__CLASS__); }
84
+
85
+
86
+
87
+
88
  }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/DynamicSoapClient.class.php RENAMED
@@ -1,61 +1,61 @@
1
- <?php
2
- /**
3
- * DynamicSoapClient.class.php
4
- * @package Base
5
- */
6
-
7
- /**
8
- * Private implementation class for all Avalara web service clients.
9
- *
10
- * Users should never need to create instances of this class. This class provides the underlying implementation
11
- * for instances of {@link AvalaraSoapClient} and it's subclasses.
12
- *
13
- * @package Base
14
- * @see AvalaraSoapClient
15
- * @see AddressServiceSoap
16
- * @see TaxServiceSoap
17
- * @author tblanchard
18
- *
19
- * Copyright (c) 2007, Avalara. All rights reserved.
20
- */
21
-
22
- class DynamicSoapClient extends SoapClient
23
- {
24
- private $config;
25
- public function __construct($wsdl,$options,&$config)
26
- {
27
- parent::__construct($wsdl,$options);
28
- $this->config = $config;
29
- }
30
-
31
- public function __call($n,$args)
32
- {
33
- $profileHeader = new SoapHeader('http://avatax.avalara.com/services','Profile',new SoapVar($this->profileXML(),XSD_ANYXML));
34
- $securityHeader = new SoapHeader('http://avatax.avalara.com/services','Security',new SoapVar($this->securityXML(),XSD_ANYXML));
35
- $result = $this->__soapCall($n,$args,NULL,array($securityHeader,$profileHeader));
36
- return $result;
37
- }
38
-
39
- private function securityXML()
40
- {
41
- return
42
- '<wsse:Security xmlns:wsse="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd" SOAP-ENV:mustUnderstand="1">'.
43
- '<wsse:UsernameToken>'.
44
- '<wsse:Username>'.$this->config->account.'</wsse:Username>'.
45
- '<wsse:Password Type="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-username-token-profile-1.0#PasswordText">'.$this->config->license.'</wsse:Password>'.
46
- //<wsu:Created xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd">2005-11-22T06:33:26.203Z</wsu:Created>
47
- '</wsse:UsernameToken>'.
48
- '</wsse:Security>';
49
- }
50
-
51
- private function profileXML()
52
- {
53
- return
54
- '<Profile xmlns="http://avatax.avalara.com/services" SOAP-ENV:actor="http://schemas.xmlsoap.org/soap/actor/next" SOAP-ENV:mustUnderstand="0">'.
55
- '<Name>'.$this->config->name.'</Name>'.
56
- '<Client>'.$this->config->client.'</Client>'.
57
- '<Adapter>'.$this->config->adapter.'</Adapter>'.
58
- '</Profile>';
59
- }
60
-
61
- }
1
+ <?php
2
+ /**
3
+ * DynamicSoapClient.class.php
4
+ * @package Base
5
+ */
6
+
7
+ /**
8
+ * Private implementation class for all Avalara web service clients.
9
+ *
10
+ * Users should never need to create instances of this class. This class provides the underlying implementation
11
+ * for instances of {@link AvalaraSoapClient} and it's subclasses.
12
+ *
13
+ * @package Base
14
+ * @see AvalaraSoapClient
15
+ * @see AddressServiceSoap
16
+ * @see TaxServiceSoap
17
+ * @author tblanchard
18
+ *
19
+ * Copyright (c) 2007, Avalara. All rights reserved.
20
+ */
21
+
22
+ class DynamicSoapClient extends SoapClient
23
+ {
24
+ private $config;
25
+ public function __construct($wsdl,$options,&$config)
26
+ {
27
+ parent::__construct($wsdl,$options);
28
+ $this->config = $config;
29
+ }
30
+
31
+ public function __call($n,$args)
32
+ {
33
+ $profileHeader = new SoapHeader('http://avatax.avalara.com/services','Profile',new SoapVar($this->profileXML(),XSD_ANYXML));
34
+ $securityHeader = new SoapHeader('http://avatax.avalara.com/services','Security',new SoapVar($this->securityXML(),XSD_ANYXML));
35
+ $result = $this->__soapCall($n,$args,NULL,array($securityHeader,$profileHeader));
36
+ return $result;
37
+ }
38
+
39
+ private function securityXML()
40
+ {
41
+ return
42
+ '<wsse:Security xmlns:wsse="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd" SOAP-ENV:mustUnderstand="1">'.
43
+ '<wsse:UsernameToken>'.
44
+ '<wsse:Username>'.$this->config->account.'</wsse:Username>'.
45
+ '<wsse:Password Type="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-username-token-profile-1.0#PasswordText">'.$this->config->license.'</wsse:Password>'.
46
+ //<wsu:Created xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd">2005-11-22T06:33:26.203Z</wsu:Created>
47
+ '</wsse:UsernameToken>'.
48
+ '</wsse:Security>';
49
+ }
50
+
51
+ private function profileXML()
52
+ {
53
+ return
54
+ '<Profile xmlns="http://avatax.avalara.com/services" SOAP-ENV:actor="http://schemas.xmlsoap.org/soap/actor/next" SOAP-ENV:mustUnderstand="0">'.
55
+ '<Name>'.$this->config->name.'</Name>'.
56
+ '<Client>'.$this->config->client.'</Client>'.
57
+ '<Adapter>'.$this->config->adapter.'</Adapter>'.
58
+ '</Profile>';
59
+ }
60
+
61
+ }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/Enum.class.php RENAMED
@@ -1,30 +1,30 @@
1
- <?php
2
- /**
3
- * Enum.class.php
4
- * @package Base
5
- */
6
-
7
- /**
8
- * Abstract class for enumerated types - provides validation.
9
- *
10
- * @package Base
11
- * @author tblanchard
12
- * Copyright (c) 2008, Avalara. All rights reserved.
13
- */
14
-
15
- class Enum
16
- {
17
- // Basic implementation - check and throw
18
- protected static function __Validate($value,$values,$class=__CLASS__)
19
- {
20
- foreach($values as $valid)
21
- {
22
- if($value == $valid)
23
- {
24
- return true;
25
- }
26
- }
27
-
28
- throw new Exception('Invalid '.$class.' "'.$value.'" - must be one of "'.implode('"|"',$values).'"');
29
- }
30
  }
1
+ <?php
2
+ /**
3
+ * Enum.class.php
4
+ * @package Base
5
+ */
6
+
7
+ /**
8
+ * Abstract class for enumerated types - provides validation.
9
+ *
10
+ * @package Base
11
+ * @author tblanchard
12
+ * Copyright (c) 2008, Avalara. All rights reserved.
13
+ */
14
+
15
+ class Enum
16
+ {
17
+ // Basic implementation - check and throw
18
+ protected static function __Validate($value,$values,$class=__CLASS__)
19
+ {
20
+ foreach($values as $valid)
21
+ {
22
+ if($value == $valid)
23
+ {
24
+ return true;
25
+ }
26
+ }
27
+
28
+ throw new Exception('Invalid '.$class.' "'.$value.'" - must be one of "'.implode('"|"',$values).'"');
29
+ }
30
  }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/GetTaxHistoryRequest.class.php RENAMED
@@ -1,52 +1,52 @@
1
- <?php
2
- /**
3
- * GetTaxHistoryRequest.class.php
4
- *
5
- * @package Tax
6
- */
7
-
8
-
9
- /**
10
- * Data to pass to {@link TaxServiceSoap#getTaxHistory}.
11
- * <p>
12
- * The request must specify all of CompanyCode, DocCode, and DocType in order to uniquely identify the document.
13
- * </p>
14
- *
15
- * @see GetTaxHistoryResult
16
- * @package Tax
17
- * @author tblanchard
18
- * Copyright (c) 2008, Avalara. All rights reserved.
19
- */
20
-
21
- class GetTaxHistoryRequest extends TaxRequest
22
- {
23
- private $DetailLevel;
24
-
25
- public function __construct()
26
- {
27
- parent::__construct();
28
- $this->DetailLevel = DetailLevel::$Document; // this is right Document
29
- $this->DocType = DocumentType::$SalesOrder; // this is right Document
30
-
31
- }
32
-
33
- /**
34
- * Specifies the level of detail to return.
35
- *
36
- * @return detailLevel
37
- * @var string
38
- * @see DetailLevel
39
- */
40
-
41
- public function getDetailLevel() { return $this->DetailLevel; }
42
-
43
- /**
44
- * Specifies the level of detail to return.
45
- *
46
- * @see DetailLevel
47
- * @return string
48
- */
49
-
50
- public function setDetailLevel($value) { DetailLevel::Validate($value); $this->DetailLevel = $value; return $this; } //Summary or Document or Line or Tax or Diagnostic - enum
51
-
52
  }
1
+ <?php
2
+ /**
3
+ * GetTaxHistoryRequest.class.php
4
+ *
5
+ * @package Tax
6
+ */
7
+
8
+
9
+ /**
10
+ * Data to pass to {@link TaxServiceSoap#getTaxHistory}.
11
+ * <p>
12
+ * The request must specify all of CompanyCode, DocCode, and DocType in order to uniquely identify the document.
13
+ * </p>
14
+ *
15
+ * @see GetTaxHistoryResult
16
+ * @package Tax
17
+ * @author tblanchard
18
+ * Copyright (c) 2008, Avalara. All rights reserved.
19
+ */
20
+
21
+ class GetTaxHistoryRequest extends TaxRequest
22
+ {
23
+ private $DetailLevel;
24
+
25
+ public function __construct()
26
+ {
27
+ parent::__construct();
28
+ $this->DetailLevel = DetailLevel::$Document; // this is right Document
29
+ $this->DocType = DocumentType::$SalesOrder; // this is right Document
30
+
31
+ }
32
+
33
+ /**
34
+ * Specifies the level of detail to return.
35
+ *
36
+ * @return detailLevel
37
+ * @var string
38
+ * @see DetailLevel
39
+ */
40
+
41
+ public function getDetailLevel() { return $this->DetailLevel; }
42
+
43
+ /**
44
+ * Specifies the level of detail to return.
45
+ *
46
+ * @see DetailLevel
47
+ * @return string
48
+ */
49
+
50
+ public function setDetailLevel($value) { DetailLevel::Validate($value); $this->DetailLevel = $value; return $this; } //Summary or Document or Line or Tax or Diagnostic - enum
51
+
52
  }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/GetTaxHistoryResult.class.php RENAMED
@@ -1,70 +1,70 @@
1
- <?php
2
- /**
3
- * GetTaxHistoryResult.class.php
4
- * @package Tax
5
- */
6
-
7
- /**
8
- * Result data returned from {@link TaxServiceSoap#getTaxHistory} for a previously calculated tax document.
9
- *
10
- * @package Tax
11
- * @see GetTaxHistoryRequest
12
- * @author tblanchard
13
- * Copyright (c) 2007, Avalara. All rights reserved.
14
- */
15
-
16
- class GetTaxHistoryResult //extends BaseResult
17
- {
18
- private $GetTaxRequest;
19
- private $GetTaxResult;
20
-
21
- /**
22
- * Gets the original {@link GetTaxRequest} for the document.
23
- *
24
- * @return GetTaxRequest
25
- */
26
-
27
- public function getGetTaxRequest() { return $this->GetTaxRequest; }
28
-
29
- /**
30
- * Gets the original {@link GetTaxResult} for the document.
31
- *
32
- * @return GetTaxResult
33
- */
34
-
35
- public function getGetTaxResult() { return $this->GetTaxResult; }
36
-
37
-
38
- // BaseResult innards - work around a bug in SoapClient
39
-
40
- /**
41
- * @var string
42
- */
43
- private $TransactionId;
44
- /**
45
- * @var string must be one of the values defined in {@link SeverityLevel}.
46
- */
47
- private $ResultCode = 'Success';
48
- /**
49
- * @var array of Message.
50
- */
51
- private $Messages = array();
52
-
53
- /**
54
- * Accessor
55
- * @return string
56
- */
57
- public function getTransactionId() { return $this->TransactionId; }
58
- /**
59
- * Accessor
60
- * @return string
61
- */
62
- public function getResultCode() { return $this->ResultCode; }
63
- /**
64
- * Accessor
65
- * @return array
66
- */
67
- public function getMessages() { return EnsureIsArray($this->Messages->Message); }
68
-
69
-
70
  }
1
+ <?php
2
+ /**
3
+ * GetTaxHistoryResult.class.php
4
+ * @package Tax
5
+ */
6
+
7
+ /**
8
+ * Result data returned from {@link TaxServiceSoap#getTaxHistory} for a previously calculated tax document.
9
+ *
10
+ * @package Tax
11
+ * @see GetTaxHistoryRequest
12
+ * @author tblanchard
13
+ * Copyright (c) 2007, Avalara. All rights reserved.
14
+ */
15
+
16
+ class GetTaxHistoryResult //extends BaseResult
17
+ {
18
+ private $GetTaxRequest;
19
+ private $GetTaxResult;
20
+
21
+ /**
22
+ * Gets the original {@link GetTaxRequest} for the document.
23
+ *
24
+ * @return GetTaxRequest
25
+ */
26
+
27
+ public function getGetTaxRequest() { return $this->GetTaxRequest; }
28
+
29
+ /**
30
+ * Gets the original {@link GetTaxResult} for the document.
31
+ *
32
+ * @return GetTaxResult
33
+ */
34
+
35
+ public function getGetTaxResult() { return $this->GetTaxResult; }
36
+
37
+
38
+ // BaseResult innards - work around a bug in SoapClient
39
+
40
+ /**
41
+ * @var string
42
+ */
43
+ private $TransactionId;
44
+ /**
45
+ * @var string must be one of the values defined in {@link SeverityLevel}.
46
+ */
47
+ private $ResultCode = 'Success';
48
+ /**
49
+ * @var array of Message.
50
+ */
51
+ private $Messages = array();
52
+
53
+ /**
54
+ * Accessor
55
+ * @return string
56
+ */
57
+ public function getTransactionId() { return $this->TransactionId; }
58
+ /**
59
+ * Accessor
60
+ * @return string
61
+ */
62
+ public function getResultCode() { return $this->ResultCode; }
63
+ /**
64
+ * Accessor
65
+ * @return array
66
+ */
67
+ public function getMessages() { return EnsureIsArray($this->Messages->Message); }
68
+
69
+
70
  }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/GetTaxRequest.class.php RENAMED
@@ -1,529 +1,529 @@
1
- <?php
2
- /**
3
- * GetTaxRequest.class.php
4
- * @package Tax
5
- */
6
-
7
- /**
8
- * Data to pass to {@link TaxServiceSoap#getTax}.
9
- *
10
- * @see GetTaxResult
11
- * @package Tax
12
- * @author tblanchard
13
- * Copyright (c) 2007, Avalara. All rights reserved.
14
- */
15
-
16
-
17
-
18
- class GetTaxRequest
19
- {
20
- private $CompanyCode; // string
21
- private $DocCode;
22
- private $DocType;
23
- private $DocDate; //date
24
- private $SalespersonCode; //string
25
- private $CustomerCode; //string
26
- private $CustomerUsageType; //string Entity Usage
27
- private $Discount; //decimal
28
- private $PurchaseOrderNo; //string
29
- private $ExemptionNo; //string if not using ECMS which keys on customer code
30
- private $OriginCode; //string
31
- private $DestinationCode; //string
32
- private $Addresses; //array
33
- private $Lines; //array
34
- private $DetailLevel; //Summary or Document or Line or Tax or Diagnostic
35
- private $ReferenceCode; // string
36
- private $LocationCode; //string
37
- private $Commit=false; //boolean
38
- private $BatchCode; //string
39
- private $OriginAddress; //address
40
- private $DestinationAddress; //address
41
-
42
-
43
- //@author: Swetal
44
- //Added new properties to upgrade to 5.3 interface
45
- private $TaxOverride; //TaxOverride
46
- private $CurrencyCode; //string
47
- private $ServiceMode; //type: ServiceMode
48
- private $PaymentDate; //date
49
- private $ExchangeRate; //decimal
50
- private $ExchangeRateEffDate; //date
51
-
52
-
53
- //@author: Rapshtynska Svitlana
54
- //Added new properties
55
- private $TaxDate; //date
56
- private $StatusDate; //date
57
-
58
-
59
-
60
-
61
- public function __construct()
62
- {
63
-
64
- $this->DocDate = date("Y-m-d");
65
- $this->Commit=false;
66
- $this->HashCode=0;
67
- $this->Discount=0.0;
68
- $this->DocType=DocumentType::$SalesInvoice;
69
- $this->DetailLevel=DetailLevel::$Document;
70
- $this->DocCode = date("Y-m-d-H-i-s.u");
71
- $this->CustomerCode='CustomerCodeString';
72
- $this->Lines=array(new Line());
73
-
74
- $this->ServiceMode=ServiceMode::$Automatic;
75
- $this->ExchangeRate=1.0;
76
-
77
- $dateTime=new DateTime();
78
- $dateTime->setDate(1900,01,01);
79
- $this->ExchangeRateEffDate=$dateTime->format("Y-m-d");
80
- $this->PaymentDate=$dateTime->format("Y-m-d");
81
-
82
-
83
- }
84
-
85
- public function prepare()
86
- {
87
- $this->Addresses = array();
88
- $this->OriginCode = $this->registerAddress($this->OriginAddress);
89
- $this->DestinationCode = $this->registerAddress($this->DestinationAddress);
90
- foreach($this->Lines as &$line)
91
- {
92
- $line->registerAddressesIn($this);
93
- }
94
- return $this;
95
- }
96
-
97
- public function registerAddress(&$address)
98
- {
99
- if($address == null) { return null; }
100
- $index = sizeof($this->Addresses);
101
- foreach($this->Addresses as $index=>$a)
102
- {
103
- if($address->equals($a))
104
- {
105
- return $index;
106
- }
107
- }
108
- $index = sizeof($this->Addresses);
109
- $this->Addresses[] = $address;
110
- $address->setAddressCode ( $index);
111
- return $index;
112
- }
113
-
114
- public function postFetch()
115
- {
116
- $addresses = $this->getAddresses();
117
- $this->OriginAddress = $addresses[$this->OriginCode];
118
- $this->DestinationAddress = $addresses[$this->DestinationCode];
119
-
120
- //@author: Swetal
121
- //Commenting following foreach loop
122
- //Reason is postFetch function is called after getTaxHistory to populate origin and destination address
123
- //but taxHistory does not return origin and destination code so with followign loop we can not retrive origin
124
- //and destination adress for line. This gives invalid index error if not commented
125
- /*foreach($this->getLines() as $line)
126
- {
127
- $line->postFetchWithAddresses($addresses);
128
- }*/
129
-
130
- return $this;
131
- }
132
-
133
-
134
- /**
135
- * Enter description here...
136
- *
137
- * @param string $value
138
- */
139
- public function setAddressCode($value) { $this->AddressCode = $value; return $this; }
140
-
141
- /**
142
- * Enter description here...
143
- *
144
- * @param string $value
145
- */
146
- public function setLine1($value) { $this->Line1 = $value; return $this; }
147
-
148
- /**
149
- * Enter description here...
150
- *
151
- * @param string $value
152
- */
153
- public function setLine2($value) { $this->Line2 = $value; return $this; }
154
-
155
- /**
156
- * Enter description here...
157
- *
158
- * @param string $value
159
- */
160
- public function setLine3($value) { $this->Line3 = $value; return $this; }
161
-
162
- /**
163
- * Enter description here...
164
- *
165
- * @param string $value
166
- */
167
- public function setCity($value) { $this->City = $value; return $this; }
168
-
169
- /**
170
- * Enter description here...
171
- *
172
- * @param string $value
173
- */
174
- public function setRegion($value) { $this->Region = $value; return $this; }
175
-
176
- /**
177
- * Enter description here...
178
- *
179
- * @param string $value
180
- */
181
- public function setPostalCode($value) { $this->PostalCode = $value; return $this; }
182
-
183
- /**
184
- * Enter description here...
185
- *
186
- * @param string $value
187
- */
188
- public function setCountry($value) { $this->Country = $value; return $this; }
189
-
190
- /**
191
- * Mutator
192
- * @access public
193
- * @param integer
194
- */
195
-
196
-
197
- /**
198
- * DocDate should be in the format yyyy-mm-dd
199
- *
200
- * @param date $value
201
- */
202
- public function setDocDate($value) { $this->DocDate = $value; return $this; } //date
203
-
204
-
205
- /**
206
- * Sets the client application company reference code.
207
- *
208
- * @param string $value
209
- *
210
- */
211
- public function setCompanyCode($value) { $this->CompanyCode = $value; return $this; } //string
212
-
213
- /**
214
- * The document type specifies the category of the document and affects how the document is treated after a tax calculation; see DocumentType for more information about the specific document types.
215
- *
216
- * @param DocumentType $value
217
- *
218
- */
219
- public function setDocType($value) { DocumentType::Validate($value); $this->DocType = $value; return $this; } //SalesOrder or SalesInvoice or PurchaseOrder or PurchaseInvoice or ReturnOrder or ReturnInvoice
220
-
221
- /**
222
- * Specifies the level of detail to return.
223
- *
224
- * @param DetailLevel $value
225
-
226
- */
227
- public function setDetailLevel($value) { DetailLevel::Validate($value); $this->DetailLevel = $value; return $this; } //Summary or Document or Line or Tax or Diagnostic - enum
228
-
229
- /**
230
- * Sets the Document Code, i.e. the internal reference code used by the client application.
231
- *
232
- * @param string $value
233
-
234
- */
235
- public function setDocCode($value) { $this->DocCode = $value; return $this; } //string invoice number
236
-
237
- /**
238
- * The client application salesperson reference code.
239
- *
240
- * @param string $value
241
-
242
- */
243
- public function setSalespersonCode($value) { $this->SalespersonCode = $value; return $this; } //string
244
-
245
- /**
246
- * The client application customer reference code.
247
- *
248
- * @param string $value
249
-
250
- */
251
- public function setCustomerCode($value) { $this->CustomerCode = $value; return $this; } //string
252
-
253
- /**
254
- * The client application customer or usage type.
255
- * <p>
256
- * This is used to determine the exempt status of the transaction based on the exemption tax rules for the
257
- * jurisdictions involved. This may also be set at the line level.
258
- * </p>
259
- * <p>
260
- * The standard values for the CustomerUsageType (A-L).<br/>
261
- A � Federal Government<br/>
262
- B � State/Local Govt.<br/>
263
- C � Tribal Government<br/>
264
- D � Foreign Diplomat<br/>
265
- E � Charitable Organization<br/>
266
- F � Religious/Education<br/>
267
- G � Resale<br/>
268
- H � Agricultural Production<br/>
269
- I � Industrial Prod/Mfg.<br/>
270
- J � Direct Pay Permit<br/>
271
- K � Direct Mail<br/>
272
- L - Other<br/>
273
- * </p>
274
- * @param customerUsageType
275
- */
276
- public function setCustomerUsageType($value) { $this->CustomerUsageType = $value; return $this; } //string Entity Usage
277
-
278
- /**
279
- *Purchase Order Number for this document.
280
- *
281
- * @param string $value
282
-
283
- */
284
- public function setPurchaseOrderNo($value) { $this->PurchaseOrderNo = $value; return $this; } //string
285
-
286
- /**
287
- * Exemption Number for this document
288
- *
289
- * @param string $value
290
-
291
- */
292
- public function setExemptionNo($value) { $this->ExemptionNo = $value; return $this; } //string if not using ECMS which keys on customer code
293
-
294
-
295
-
296
- /**
297
- * Also referred to as a Store Location, Outlet Id, or Outlet code is a number assigned by the State which identifies a Store location. Some state returns require taxes are broken out separatly for Store Locations.
298
- *
299
- * @param string $value
300
-
301
- */
302
- public function setLocationCode($value) { $this->LocationCode = $value; return $this; } //string
303
-
304
-
305
- public function setBatchCode($value) { $this->BatchCode = $value; return $this; } //string
306
-
307
- /**
308
- * The discount amount to apply to the document.
309
- *
310
- * @param decimal $value
311
-
312
- */
313
- public function setDiscount($value) { $this->Discount = $value; return $this; } //decimal
314
- //public function setTotalTaxOverride($value) { $this->TotalTaxOverride = $value; return $this; } //decimal
315
-
316
- /**
317
- * Set addresses
318
- *
319
- * @param array $value
320
-
321
- */
322
- public function setAddresses($value) { $this->Addresses = $value; return $this; } //array
323
-
324
- /**
325
- * Set tax lines
326
- *
327
- * @param array $value
328
-
329
- */
330
- public function setLines($value) { $this->Lines = $value; return $this; } //array
331
-
332
- public function setHashCode($value) { $this->HashCode = $value; return $this; } //int
333
-
334
- /**
335
- * This has been defaulted to False ; invoice will be committed if this flag has been set to True.
336
- *
337
- * @param boolean $value
338
- *
339
- */
340
- public function setCommit($value) { $this->Commit = $value; return $this; } //boolean
341
- //public function setIsTotalTaxOverriden($value) { $this->IsTotalTaxOverriden = ($value ? true : false); return $this; } //boolean
342
-
343
- /**
344
- * Set ship from address
345
- *
346
- * @param Address $value
347
-
348
- */
349
- public function setOriginAddress($value) { $this->OriginAddress = $value; return $this; } //address
350
-
351
- /**
352
- * set ship to address
353
- *
354
- * @param Address $value
355
-
356
- */
357
- public function setDestinationAddress($value) { $this->DestinationAddress = $value; return $this; } //address
358
-
359
- //@author:swetal
360
-
361
- /**
362
- * ExchangeRate indicates the currency exchange rate from the transaction currency (indicated by CurrencyCode) to the company base currency.
363
- * This only needs to be set if the transaction currency is different than the company base currency. It defaults to 1.0.
364
- *
365
- * @param decimal $value
366
-
367
- */
368
- public function setExchangeRate($value) { $this->ExchangeRate = $value; return $this; } //decimal
369
-
370
- /**
371
- * 3 character ISO 4217 currency code.
372
- *
373
- * @param string $value
374
-
375
- */
376
- public function setCurrencyCode($value) { $this->CurrencyCode = $value; return $this; } //string
377
-
378
- /**
379
- * It provides the ability to controls whether tax is calculated locally or remotely when using an AvaLocal server.
380
- * The default is Automatic which calculates locally unless remote is necessary for non-local addresses.
381
- *
382
- * @param ServiceMode $value
383
- */
384
- public function setServiceMode($value) { $this->ServiceMode = $value; return $this; } //type: ServiceMode
385
-
386
- /**
387
- * PaymentDate indicates the date when payment was received for the document. It is only applicable for cash-basis accounting and does not need to be set otherwise.
388
- * It defaults to 1/1/1900 which indicates no payment. The new TaxSvc.ApplyPayment method may be used to apply a payment to an existing invoice.
389
- *
390
- * @param date $value
391
-
392
- */
393
- public function setPaymentDate($value) { $this->PaymentDate = $value; return $this; } //date
394
-
395
- /**
396
- * ExchangeRateEffDate indicates the effective date of the exchange rate.
397
- * It should be set in conjunction with ExchangeRate. It will default to the DocDate if not set.
398
- *
399
- * @param date $value
400
-
401
- */
402
- public function setExchangeRateEffDate($value){ $this->ExchangeRateEffDate = $value; return $this; } //date
403
-
404
-
405
- /**
406
- *TaxOverride for the document.
407
- *
408
- * @param TaxOverride $value
409
-
410
- */
411
- public function setTaxOverride($value){ $this->TaxOverride=$value;} //tax override
412
-
413
- public function setReferenceCode($value)
414
- {
415
- $this->ReferenceCode=$value;
416
- }
417
-
418
-
419
- //@author: Rapshtynska Svitlana
420
- /**
421
- * TaxDate should be in the format yyyy-mm-dd
422
- *
423
- * @param date $value
424
- */
425
- public function setTaxDate($value) { $this->TaxDate = $value; return $this; } //date
426
-
427
- /**
428
- * StatusDate should be in the format yyyy-mm-dd
429
- *
430
- * @param date $value
431
- */
432
- public function setStatusDate($value) { $this->StatusDate = $value; return $this; } //date
433
-
434
-
435
-
436
- /**#@+
437
- * Accessor
438
- * @access public
439
- * @return string
440
- */
441
-
442
- public function getCompanyCode() { return $this->CompanyCode;} //string
443
- public function getDocType() { return $this->DocType;} //SalesOrder or SalesInvoice or PurchaseOrder or PurchaseInvoice or ReturnOrder or ReturnInvoice
444
- public function getDocCode() { return $this->DocCode;} //string invoice number
445
- public function getDocDate() { return $this->DocDate;} //date
446
- public function salespersonCode() { return $this->SalespersonCode;} //string
447
- public function getCustomerCode() { return $this->CustomerCode;} //string
448
- public function getCustomerUsageType() { return $this->CustomerUsageType;} //string Entity Usage
449
-
450
- public function getDiscount() { return $this->Discount;} //decimal
451
- //public function getTotalTaxOverride() { return $this->TotalTaxOverride;} //decimal
452
-
453
- public function getPurchaseOrderNo() { return $this->PurchaseOrderNo;} //string
454
- public function getExemptionNo() { return $this->ExemptionNo;} //string if not using ECMS which keys on customer code
455
- public function getAddresses()
456
- {
457
- // this is kind of icky
458
- // when we build one of these to send, it is an array of Address
459
- // however, when it is fetched, there is an extra std::Object stuck in place to represent the array
460
- // which contains the array in an ivar called Address. Such are the vagaries of
461
- // the php SoapClient.
462
-
463
- //@swetal
464
- //Changed from $this->Addresses to $this->Addresses->BaseAddress
465
- return is_array($this->Addresses) ? $this->Addresses : EnsureIsArray($this->Addresses->BaseAddress);
466
-
467
-
468
-
469
-
470
-
471
-
472
- } //array
473
- public function getLines()
474
- {
475
- return is_array($this->Lines) ? $this->Lines : EnsureIsArray($this->Lines->Line);
476
- } //array
477
- public function getDetailLevel() { return $this->DetailLevel;} //Summary or Document or Line or Tax or Diagnostic ********************************** make class
478
-
479
- public function getHashCode() { return $this->HashCode;} //int
480
- public function getLocationCode() { return $this->LocationCode;} //string
481
- public function getBatchCode() { return $this->BatchCode;} //string
482
-
483
- public function getCommit() { return $this->Commit;} //boolean
484
- //public function getIsTotalTaxOverriden() { return $this->IsTotalTaxOverriden;} //boolean
485
-
486
-
487
- public function getOriginAddress() { return $this->OriginAddress;} //address
488
- public function getDestinationAddress() { return $this->DestinationAddress;} //address
489
-
490
- //@author:swetal
491
- public function getExchangeRate() { return $this->ExchangeRate; } //decimal
492
- public function getCurrencyCode() { return $this->CurrencyCode; } //string
493
- public function getServiceMode() { return $this->ServiceMode; } //type: ServiceMode
494
- public function getPaymentDate() { return $this->PaymentDate; } //date
495
- public function getExchangeRateEffDate(){ return $this->ExchangeRateEffDate; } //date
496
- public function getTaxOverride(){ return $this->TaxOverride;}
497
-
498
- public function getReferenceCode()
499
- {
500
- return $this->ReferenceCode;
501
- }
502
-
503
- //@author:swetal
504
- //Adding getLine function which returns line based on line number
505
- public function getLine($lineNo)
506
- {
507
- if($this->Lines != null)
508
- {
509
- foreach($this->getLines() as $line)
510
- {
511
- if($lineNo == $line->getNo())
512
- {
513
- return $line;
514
- }
515
-
516
- }
517
- }
518
- }
519
-
520
- //@author: Rapshtynska Svitlana
521
- public function getTaxDate() { return $this->TaxDate; } //date
522
- public function getStatusDate() { return $this->StatusDate; } //date
523
-
524
-
525
- /**#@-*/
526
-
527
-
528
-
529
  }
1
+ <?php
2
+ /**
3
+ * GetTaxRequest.class.php
4
+ * @package Tax
5
+ */
6
+
7
+ /**
8
+ * Data to pass to {@link TaxServiceSoap#getTax}.
9
+ *
10
+ * @see GetTaxResult
11
+ * @package Tax
12
+ * @author tblanchard
13
+ * Copyright (c) 2007, Avalara. All rights reserved.
14
+ */
15
+
16
+
17
+
18
+ class GetTaxRequest
19
+ {
20
+ private $CompanyCode; // string
21
+ private $DocCode;
22
+ private $DocType;
23
+ private $DocDate; //date
24
+ private $SalespersonCode; //string
25
+ private $CustomerCode; //string
26
+ private $CustomerUsageType; //string Entity Usage
27
+ private $Discount; //decimal
28
+ private $PurchaseOrderNo; //string
29
+ private $ExemptionNo; //string if not using ECMS which keys on customer code
30
+ private $OriginCode; //string
31
+ private $DestinationCode; //string
32
+ private $Addresses; //array
33
+ private $Lines; //array
34
+ private $DetailLevel; //Summary or Document or Line or Tax or Diagnostic
35
+ private $ReferenceCode; // string
36
+ private $LocationCode; //string
37
+ private $Commit=false; //boolean
38
+ private $BatchCode; //string
39
+ private $OriginAddress; //address
40
+ private $DestinationAddress; //address
41
+
42
+
43
+ //@author: Swetal
44
+ //Added new properties to upgrade to 5.3 interface
45
+ private $TaxOverride; //TaxOverride
46
+ private $CurrencyCode; //string
47
+ private $ServiceMode; //type: ServiceMode
48
+ private $PaymentDate; //date
49
+ private $ExchangeRate; //decimal
50
+ private $ExchangeRateEffDate; //date
51
+
52
+
53
+ //@author: Rapshtynska Svitlana
54
+ //Added new properties
55
+ private $TaxDate; //date
56
+ private $StatusDate; //date
57
+
58
+
59
+
60
+
61
+ public function __construct()
62
+ {
63
+
64
+ $this->DocDate = date("Y-m-d");
65
+ $this->Commit=false;
66
+ $this->HashCode=0;
67
+ $this->Discount=0.0;
68
+ $this->DocType=DocumentType::$SalesInvoice;
69
+ $this->DetailLevel=DetailLevel::$Document;
70
+ $this->DocCode = date("Y-m-d-H-i-s.u");
71
+ $this->CustomerCode='CustomerCodeString';
72
+ $this->Lines=array(new Line());
73
+
74
+ $this->ServiceMode=ServiceMode::$Automatic;
75
+ $this->ExchangeRate=1.0;
76
+
77
+ $dateTime=new DateTime();
78
+ $dateTime->setDate(1900,01,01);
79
+ $this->ExchangeRateEffDate=$dateTime->format("Y-m-d");
80
+ $this->PaymentDate=$dateTime->format("Y-m-d");
81
+
82
+
83
+ }
84
+
85
+ public function prepare()
86
+ {
87
+ $this->Addresses = array();
88
+ $this->OriginCode = $this->registerAddress($this->OriginAddress);
89
+ $this->DestinationCode = $this->registerAddress($this->DestinationAddress);
90
+ foreach($this->Lines as &$line)
91
+ {
92
+ $line->registerAddressesIn($this);
93
+ }
94
+ return $this;
95
+ }
96
+
97
+ public function registerAddress(&$address)
98
+ {
99
+ if($address == null) { return null; }
100
+ $index = sizeof($this->Addresses);
101
+ foreach($this->Addresses as $index=>$a)
102
+ {
103
+ if($address->equals($a))
104
+ {
105
+ return $index;
106
+ }
107
+ }
108
+ $index = sizeof($this->Addresses);
109
+ $this->Addresses[] = $address;
110
+ $address->setAddressCode ( $index);
111
+ return $index;
112
+ }
113
+
114
+ public function postFetch()
115
+ {
116
+ $addresses = $this->getAddresses();
117
+ $this->OriginAddress = $addresses[$this->OriginCode];
118
+ $this->DestinationAddress = $addresses[$this->DestinationCode];
119
+
120
+ //@author: Swetal
121
+ //Commenting following foreach loop
122
+ //Reason is postFetch function is called after getTaxHistory to populate origin and destination address
123
+ //but taxHistory does not return origin and destination code so with followign loop we can not retrive origin
124
+ //and destination adress for line. This gives invalid index error if not commented
125
+ /*foreach($this->getLines() as $line)
126
+ {
127
+ $line->postFetchWithAddresses($addresses);
128
+ }*/
129
+
130
+ return $this;
131
+ }
132
+
133
+
134
+ /**
135
+ * Enter description here...
136
+ *
137
+ * @param string $value
138
+ */
139
+ public function setAddressCode($value) { $this->AddressCode = $value; return $this; }
140
+
141
+ /**
142
+ * Enter description here...
143
+ *
144
+ * @param string $value
145
+ */
146
+ public function setLine1($value) { $this->Line1 = $value; return $this; }
147
+
148
+ /**
149
+ * Enter description here...
150
+ *
151
+ * @param string $value
152
+ */
153
+ public function setLine2($value) { $this->Line2 = $value; return $this; }
154
+
155
+ /**
156
+ * Enter description here...
157
+ *
158
+ * @param string $value
159
+ */
160
+ public function setLine3($value) { $this->Line3 = $value; return $this; }
161
+
162
+ /**
163
+ * Enter description here...
164
+ *
165
+ * @param string $value
166
+ */
167
+ public function setCity($value) { $this->City = $value; return $this; }
168
+
169
+ /**
170
+ * Enter description here...
171
+ *
172
+ * @param string $value
173
+ */
174
+ public function setRegion($value) { $this->Region = $value; return $this; }
175
+
176
+ /**
177
+ * Enter description here...
178
+ *
179
+ * @param string $value
180
+ */
181
+ public function setPostalCode($value) { $this->PostalCode = $value; return $this; }
182
+
183
+ /**
184
+ * Enter description here...
185
+ *
186
+ * @param string $value
187
+ */
188
+ public function setCountry($value) { $this->Country = $value; return $this; }
189
+
190
+ /**
191
+ * Mutator
192
+ * @access public
193
+ * @param integer
194
+ */
195
+
196
+
197
+ /**
198
+ * DocDate should be in the format yyyy-mm-dd
199
+ *
200
+ * @param date $value
201
+ */
202
+ public function setDocDate($value) { $this->DocDate = $value; return $this; } //date
203
+
204
+
205
+ /**
206
+ * Sets the client application company reference code.
207
+ *
208
+ * @param string $value
209
+ *
210
+ */
211
+ public function setCompanyCode($value) { $this->CompanyCode = $value; return $this; } //string
212
+
213
+ /**
214
+ * The document type specifies the category of the document and affects how the document is treated after a tax calculation; see DocumentType for more information about the specific document types.
215
+ *
216
+ * @param DocumentType $value
217
+ *
218
+ */
219
+ public function setDocType($value) { DocumentType::Validate($value); $this->DocType = $value; return $this; } //SalesOrder or SalesInvoice or PurchaseOrder or PurchaseInvoice or ReturnOrder or ReturnInvoice
220
+
221
+ /**
222
+ * Specifies the level of detail to return.
223
+ *
224
+ * @param DetailLevel $value
225
+
226
+ */
227
+ public function setDetailLevel($value) { DetailLevel::Validate($value); $this->DetailLevel = $value; return $this; } //Summary or Document or Line or Tax or Diagnostic - enum
228
+
229
+ /**
230
+ * Sets the Document Code, i.e. the internal reference code used by the client application.
231
+ *
232
+ * @param string $value
233
+
234
+ */
235
+ public function setDocCode($value) { $this->DocCode = $value; return $this; } //string invoice number
236
+
237
+ /**
238
+ * The client application salesperson reference code.
239
+ *
240
+ * @param string $value
241
+
242
+ */
243
+ public function setSalespersonCode($value) { $this->SalespersonCode = $value; return $this; } //string
244
+
245
+ /**
246
+ * The client application customer reference code.
247
+ *
248
+ * @param string $value
249
+
250
+ */
251
+ public function setCustomerCode($value) { $this->CustomerCode = $value; return $this; } //string
252
+
253
+ /**
254
+ * The client application customer or usage type.
255
+ * <p>
256
+ * This is used to determine the exempt status of the transaction based on the exemption tax rules for the
257
+ * jurisdictions involved. This may also be set at the line level.
258
+ * </p>
259
+ * <p>
260
+ * The standard values for the CustomerUsageType (A-L).<br/>
261
+ A � Federal Government<br/>
262
+ B � State/Local Govt.<br/>
263
+ C � Tribal Government<br/>
264
+ D � Foreign Diplomat<br/>
265
+ E � Charitable Organization<br/>
266
+ F � Religious/Education<br/>
267
+ G � Resale<br/>
268
+ H � Agricultural Production<br/>
269
+ I � Industrial Prod/Mfg.<br/>
270
+ J � Direct Pay Permit<br/>
271
+ K � Direct Mail<br/>
272
+ L - Other<br/>
273
+ * </p>
274
+ * @param customerUsageType
275
+ */
276
+ public function setCustomerUsageType($value) { $this->CustomerUsageType = $value; return $this; } //string Entity Usage
277
+
278
+ /**
279
+ *Purchase Order Number for this document.
280
+ *
281
+ * @param string $value
282
+
283
+ */
284
+ public function setPurchaseOrderNo($value) { $this->PurchaseOrderNo = $value; return $this; } //string
285
+
286
+ /**
287
+ * Exemption Number for this document
288
+ *
289
+ * @param string $value
290
+
291
+ */
292
+ public function setExemptionNo($value) { $this->ExemptionNo = $value; return $this; } //string if not using ECMS which keys on customer code
293
+
294
+
295
+
296
+ /**
297
+ * Also referred to as a Store Location, Outlet Id, or Outlet code is a number assigned by the State which identifies a Store location. Some state returns require taxes are broken out separatly for Store Locations.
298
+ *
299
+ * @param string $value
300
+
301
+ */
302
+ public function setLocationCode($value) { $this->LocationCode = $value; return $this; } //string
303
+
304
+
305
+ public function setBatchCode($value) { $this->BatchCode = $value; return $this; } //string
306
+
307
+ /**
308
+ * The discount amount to apply to the document.
309
+ *
310
+ * @param decimal $value
311
+
312
+ */
313
+ public function setDiscount($value) { $this->Discount = $value; return $this; } //decimal
314
+ //public function setTotalTaxOverride($value) { $this->TotalTaxOverride = $value; return $this; } //decimal
315
+
316
+ /**
317
+ * Set addresses
318
+ *
319
+ * @param array $value
320
+
321
+ */
322
+ public function setAddresses($value) { $this->Addresses = $value; return $this; } //array
323
+
324
+ /**
325
+ * Set tax lines
326
+ *
327
+ * @param array $value
328
+
329
+ */
330
+ public function setLines($value) { $this->Lines = $value; return $this; } //array
331
+
332
+ public function setHashCode($value) { $this->HashCode = $value; return $this; } //int
333
+
334
+ /**
335
+ * This has been defaulted to False ; invoice will be committed if this flag has been set to True.
336
+ *
337
+ * @param boolean $value
338
+ *
339
+ */
340
+ public function setCommit($value) { $this->Commit = $value; return $this; } //boolean
341
+ //public function setIsTotalTaxOverriden($value) { $this->IsTotalTaxOverriden = ($value ? true : false); return $this; } //boolean
342
+
343
+ /**
344
+ * Set ship from address
345
+ *
346
+ * @param Address $value
347
+
348
+ */
349
+ public function setOriginAddress($value) { $this->OriginAddress = $value; return $this; } //address
350
+
351
+ /**
352
+ * set ship to address
353
+ *
354
+ * @param Address $value
355
+
356
+ */
357
+ public function setDestinationAddress($value) { $this->DestinationAddress = $value; return $this; } //address
358
+
359
+ //@author:swetal
360
+
361
+ /**
362
+ * ExchangeRate indicates the currency exchange rate from the transaction currency (indicated by CurrencyCode) to the company base currency.
363
+ * This only needs to be set if the transaction currency is different than the company base currency. It defaults to 1.0.
364
+ *
365
+ * @param decimal $value
366
+
367
+ */
368
+ public function setExchangeRate($value) { $this->ExchangeRate = $value; return $this; } //decimal
369
+
370
+ /**
371
+ * 3 character ISO 4217 currency code.
372
+ *
373
+ * @param string $value
374
+
375
+ */
376
+ public function setCurrencyCode($value) { $this->CurrencyCode = $value; return $this; } //string
377
+
378
+ /**
379
+ * It provides the ability to controls whether tax is calculated locally or remotely when using an AvaLocal server.
380
+ * The default is Automatic which calculates locally unless remote is necessary for non-local addresses.
381
+ *
382
+ * @param ServiceMode $value
383
+ */
384
+ public function setServiceMode($value) { $this->ServiceMode = $value; return $this; } //type: ServiceMode
385
+
386
+ /**
387
+ * PaymentDate indicates the date when payment was received for the document. It is only applicable for cash-basis accounting and does not need to be set otherwise.
388
+ * It defaults to 1/1/1900 which indicates no payment. The new TaxSvc.ApplyPayment method may be used to apply a payment to an existing invoice.
389
+ *
390
+ * @param date $value
391
+
392
+ */
393
+ public function setPaymentDate($value) { $this->PaymentDate = $value; return $this; } //date
394
+
395
+ /**
396
+ * ExchangeRateEffDate indicates the effective date of the exchange rate.
397
+ * It should be set in conjunction with ExchangeRate. It will default to the DocDate if not set.
398
+ *
399
+ * @param date $value
400
+
401
+ */
402
+ public function setExchangeRateEffDate($value){ $this->ExchangeRateEffDate = $value; return $this; } //date
403
+
404
+
405
+ /**
406
+ *TaxOverride for the document.
407
+ *
408
+ * @param TaxOverride $value
409
+
410
+ */
411
+ public function setTaxOverride($value){ $this->TaxOverride=$value;} //tax override
412
+
413
+ public function setReferenceCode($value)
414
+ {
415
+ $this->ReferenceCode=$value;
416
+ }
417
+
418
+
419
+ //@author: Rapshtynska Svitlana
420
+ /**
421
+ * TaxDate should be in the format yyyy-mm-dd
422
+ *
423
+ * @param date $value
424
+ */
425
+ public function setTaxDate($value) { $this->TaxDate = $value; return $this; } //date
426
+
427
+ /**
428
+ * StatusDate should be in the format yyyy-mm-dd
429
+ *
430
+ * @param date $value
431
+ */
432
+ public function setStatusDate($value) { $this->StatusDate = $value; return $this; } //date
433
+
434
+
435
+
436
+ /**#@+
437
+ * Accessor
438
+ * @access public
439
+ * @return string
440
+ */
441
+
442
+ public function getCompanyCode() { return $this->CompanyCode;} //string
443
+ public function getDocType() { return $this->DocType;} //SalesOrder or SalesInvoice or PurchaseOrder or PurchaseInvoice or ReturnOrder or ReturnInvoice
444
+ public function getDocCode() { return $this->DocCode;} //string invoice number
445
+ public function getDocDate() { return $this->DocDate;} //date
446
+ public function salespersonCode() { return $this->SalespersonCode;} //string
447
+ public function getCustomerCode() { return $this->CustomerCode;} //string
448
+ public function getCustomerUsageType() { return $this->CustomerUsageType;} //string Entity Usage
449
+
450
+ public function getDiscount() { return $this->Discount;} //decimal
451
+ //public function getTotalTaxOverride() { return $this->TotalTaxOverride;} //decimal
452
+
453
+ public function getPurchaseOrderNo() { return $this->PurchaseOrderNo;} //string
454
+ public function getExemptionNo() { return $this->ExemptionNo;} //string if not using ECMS which keys on customer code
455
+ public function getAddresses()
456
+ {
457
+ // this is kind of icky
458
+ // when we build one of these to send, it is an array of Address
459
+ // however, when it is fetched, there is an extra std::Object stuck in place to represent the array
460
+ // which contains the array in an ivar called Address. Such are the vagaries of
461
+ // the php SoapClient.
462
+
463
+ //@swetal
464
+ //Changed from $this->Addresses to $this->Addresses->BaseAddress
465
+ return is_array($this->Addresses) ? $this->Addresses : EnsureIsArray($this->Addresses->BaseAddress);
466
+
467
+
468
+
469
+
470
+
471
+
472
+ } //array
473
+ public function getLines()
474
+ {
475
+ return is_array($this->Lines) ? $this->Lines : EnsureIsArray($this->Lines->Line);
476
+ } //array
477
+ public function getDetailLevel() { return $this->DetailLevel;} //Summary or Document or Line or Tax or Diagnostic ********************************** make class
478
+
479
+ public function getHashCode() { return $this->HashCode;} //int
480
+ public function getLocationCode() { return $this->LocationCode;} //string
481
+ public function getBatchCode() { return $this->BatchCode;} //string
482
+
483
+ public function getCommit() { return $this->Commit;} //boolean
484
+ //public function getIsTotalTaxOverriden() { return $this->IsTotalTaxOverriden;} //boolean
485
+
486
+
487
+ public function getOriginAddress() { return $this->OriginAddress;} //address
488
+ public function getDestinationAddress() { return $this->DestinationAddress;} //address
489
+
490
+ //@author:swetal
491
+ public function getExchangeRate() { return $this->ExchangeRate; } //decimal
492
+ public function getCurrencyCode() { return $this->CurrencyCode; } //string
493
+ public function getServiceMode() { return $this->ServiceMode; } //type: ServiceMode
494
+ public function getPaymentDate() { return $this->PaymentDate; } //date
495
+ public function getExchangeRateEffDate(){ return $this->ExchangeRateEffDate; } //date
496
+ public function getTaxOverride(){ return $this->TaxOverride;}
497
+
498
+ public function getReferenceCode()
499
+ {
500
+ return $this->ReferenceCode;
501
+ }
502
+
503
+ //@author:swetal
504
+ //Adding getLine function which returns line based on line number
505
+ public function getLine($lineNo)
506
+ {
507
+ if($this->Lines != null)
508
+ {
509
+ foreach($this->getLines() as $line)
510
+ {
511
+ if($lineNo == $line->getNo())
512
+ {
513
+ return $line;
514
+ }
515
+
516
+ }
517
+ }
518
+ }
519
+
520
+ //@author: Rapshtynska Svitlana
521
+ public function getTaxDate() { return $this->TaxDate; } //date
522
+ public function getStatusDate() { return $this->StatusDate; } //date
523
+
524
+
525
+ /**#@-*/
526
+
527
+
528
+
529
  }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/GetTaxResult.class.php RENAMED
@@ -1,261 +1,261 @@
1
- <?php
2
- /**
3
- * GetTaxResult.class.php
4
- * @package Tax
5
- */
6
-
7
-
8
- /**
9
- * Result data returned from {@link TaxServiceSoap#getTax}.
10
- *
11
- * @see GetTaxRequest
12
- * @package Tax
13
- * @author tblanchard
14
- * Copyright (c) 2007, Avalara. All rights reserved.
15
- */
16
-
17
- class GetTaxResult // extends BaseResult
18
- {
19
-
20
- private $DocCode; //string
21
- private $AdjustmentDescription; //string
22
- private $DocDate; //date
23
- private $TaxDate; //date
24
- private $DocType; //DocumentType
25
- private $DocStatus; //DocStatus
26
- private $Reconciled; //boolean
27
- private $Locked; //boolean
28
- private $Timestamp; //dateTime
29
- private $TotalAmount; //decimal
30
- private $TotalDiscount; //decimal
31
- private $TotalExemption; //decimal
32
- private $TotalTaxable; //decimal
33
- private $TotalTax; //decimal
34
- private $AdjustmentReason; //int
35
- private $Version; //int
36
- private $TaxLines; //ArrayOfTaxLine
37
-
38
- //@author:swetal
39
- //Added new properties to upgrade to 5.3 interface
40
- private $TotalTaxCalculated; //decimal
41
- private $TaxSummary; //ArrayOfTaxDetail
42
-
43
-
44
-
45
- /**
46
- * Gets the internal reference code used by the client application. This is used for operations such as Post and GetTaxHistory.
47
- * <p>
48
- * See {@link GetTaxRequest#getDocCode} on <b>GetTaxRequest</b> for more information about this member.
49
- * </p>
50
- *
51
- * @return string
52
- */
53
- public function getDocCode() {return $this->DocCode; }
54
-
55
- /**
56
- * AdjustmentDescription set while making AdjustTax call.
57
- *
58
- * @return string
59
- */
60
- public function getAdjustmentDescription() { return $this->AdjustmentDescription; }
61
-
62
- /**
63
- * AdjustmentReason set while making AdjustTax call. It is a high level classification of why an Original Document is being modified.
64
- *
65
- * @return int
66
- */
67
- public function getAdjustmentReason(){ return $this->AdjustmentReason; }
68
-
69
- /**
70
- * Gets the date on the invoice, purchase order, etc.
71
- * <p>
72
- * See {@link GetTaxRequest#getDocDate} on <b>GetTaxRequest</b> for more information about this member.
73
- * </p>
74
- *
75
- * @return date
76
- */
77
- public function getDocDate() {return $this->DocDate; }
78
-
79
- /**
80
- * Tax Date is the date used to calculate tax on the Document.
81
- * <p>
82
- * See {@link GetTaxRequest#taxDate} on <b>GetTaxRequest</b> for more information about this member.
83
- * </p>
84
- *
85
- * @return date
86
- */
87
- public function getTaxDate() {return $this->TaxDate; }
88
-
89
- /**
90
- * Gets the Document Type.
91
- * <p>
92
- * See {@link GetTaxRequest#DocType} on <b>GetTaxRequest</b> for more information about this member.
93
- * </p>
94
- *
95
- * @return DocumentType
96
- */
97
- public function getDocType() {return $this->DocType; }
98
-
99
- /**
100
- * Gets the document's status after the tax calculation.
101
- *
102
- * @return DocStatus
103
- */
104
- public function getDocStatus() {return $this->DocStatus; }
105
-
106
- /**
107
- * True if the document has been reconciled; Only committed documents can be reconciled.
108
- * <p>
109
- * For information on committing documents, see the <b>TaxSvc</b>'s
110
- * {@link TaxSvcSoap#commitTax} method. For information
111
- * on reconciling documents, see the {@link TaxSvcSoap#reconcileTaxHistory} method.
112
- * </p>
113
- *
114
- * @return boolean
115
- */
116
- public function getIsReconciled() {return $this->Reconciled; }
117
-
118
- /**
119
- * Flag indicating if a Document has been locked by Avalara's MRS process. Locked documents can not be modified and can not be cancelled because they have been reported on Tax Return.
120
- *
121
- * @return boolean
122
- */
123
- public function getLocked() {return $this->Locked; }
124
-
125
- /**
126
- * Date of the last status change on the document (i.e. Save date, Post date, Commit date, Cancel date).
127
- *
128
- * @return dateTime
129
- */
130
- public function getTimestamp() {return $this->Timestamp; }
131
-
132
- /**
133
- * The sum of all line {@link Line#getAmount} values.
134
- *
135
- * @param decimal
136
- */
137
- public function getTotalAmount() {return $this->TotalAmount; }
138
-
139
- /**
140
- * Gets the sum of all <b>TaxLine</b> {@link TaxLine#getDiscount} amounts; Typically it
141
- * will equal the requested Discount, but, but it is possible that no lines were marked as discounted.
142
- *
143
- * @return decimal
144
- */
145
- public function getTotalDiscount() {return $this->TotalDiscount; }
146
-
147
- /**
148
- * Gets the sum of all <b>TaxLine</b> {@link TaxLine#getExemption} amounts.
149
- *
150
- * @return decimal
151
- * @deprecated See {@link TaxDetail#getExemption}.
152
- */
153
- public function getTotalExemption() {return $this->TotalExemption; }
154
-
155
- /**
156
- * Gets the amount the tax is based on; This is the total of all {@link Line} <b>Base</b> amounts;
157
- * Typically it will be equal to the document
158
- * {@link GetTaxResult#getTotalAmount} - {@link GetTaxRequest#getDiscount} - {@link #getTotalExemption}.
159
- *
160
- * @return decimal
161
- * @deprecated See {@link TaxDetail#getTaxable}.
162
- */
163
- public function getTotalTaxable() {return $this->TotalTaxable; }
164
-
165
- /**
166
- * Gets the total tax for the document.
167
- *
168
- * @return decimal
169
- */
170
- public function getTotalTax() {return $this->TotalTax; }
171
-
172
- /**
173
- * HashCode to support Reconciliation.
174
- *
175
- * @return hashCode
176
- */
177
- public function getHashCode() {return $this->HashCode; }
178
-
179
- /**
180
- * Current version of the document.
181
- *
182
- * @return int
183
- */
184
- public function getVersion() {return $this->Version; }
185
-
186
- /**
187
- * Gets the Tax broken down by individual {@link TaxLine}.
188
- *
189
- * @return taxLines
190
- */
191
- public function getTaxLines() {return EnsureIsArray($this->TaxLines->TaxLine); }
192
-
193
- /**
194
- * TotalTaxCalculated indicates the total tax calculated by AvaTax. This is usually the same as the TotalTax, except when a tax override amount is specified.
195
- * This is for informational purposes.The TotalTax will still be used for reporting
196
- *
197
- * @return unknown
198
- */
199
- public function getTotalTaxCalculated(){ return $this->TotalTaxCalculated;}
200
-
201
- /**
202
- * TaxSummary is now returned when GetTaxRequest.DetailLevel == DetailLevel.Line in addition to DetailLevel.Summary.
203
- * It is not returned for DetailLevel.Document or DetailLevel.TaxDetail.
204
- *
205
- * @return ArrayOfTaxDetail
206
- */
207
- public function getTaxSummary() {return EnsureIsArray($this->TaxSummary->TaxDetail);}
208
-
209
- public function getTaxLine($lineNo)
210
- {
211
- if($this->getTaxLines() != null)
212
- {
213
- foreach($this->getTaxLines() as $taxLine)
214
- {
215
- if($lineNo == $taxLine->getNo())
216
- {
217
- return $taxLine;
218
- }
219
-
220
- }
221
- }
222
- }
223
-
224
-
225
-
226
- /////////////////////////////////////////////PHP bug requires this copy from BaseResult ///////////
227
- /**
228
- * @var string
229
- */
230
- private $TransactionId;
231
- /**
232
- * @var string must be one of the values defined in {@link SeverityLevel}.
233
- */
234
- private $ResultCode = 'Success';
235
- /**
236
- * @var array of Message.
237
- */
238
- private $Messages = array();
239
-
240
- /**
241
- * Accessor
242
- * @return string
243
- */
244
- public function getTransactionId() { return $this->TransactionId; }
245
- /**
246
- * Accessor
247
- * @return string
248
- */
249
- public function getResultCode() { return $this->ResultCode; }
250
- /**
251
- * Accessor
252
- * @return array
253
- */
254
- public function getMessages() { return EnsureIsArray($this->Messages->Message); }
255
-
256
-
257
-
258
-
259
-
260
-
261
  }
1
+ <?php
2
+ /**
3
+ * GetTaxResult.class.php
4
+ * @package Tax
5
+ */
6
+
7
+
8
+ /**
9
+ * Result data returned from {@link TaxServiceSoap#getTax}.
10
+ *
11
+ * @see GetTaxRequest
12
+ * @package Tax
13
+ * @author tblanchard
14
+ * Copyright (c) 2007, Avalara. All rights reserved.
15
+ */
16
+
17
+ class GetTaxResult // extends BaseResult
18
+ {
19
+
20
+ private $DocCode; //string
21
+ private $AdjustmentDescription; //string
22
+ private $DocDate; //date
23
+ private $TaxDate; //date
24
+ private $DocType; //DocumentType
25
+ private $DocStatus; //DocStatus
26
+ private $Reconciled; //boolean
27
+ private $Locked; //boolean
28
+ private $Timestamp; //dateTime
29
+ private $TotalAmount; //decimal
30
+ private $TotalDiscount; //decimal
31
+ private $TotalExemption; //decimal
32
+ private $TotalTaxable; //decimal
33
+ private $TotalTax; //decimal
34
+ private $AdjustmentReason; //int
35
+ private $Version; //int
36
+ private $TaxLines; //ArrayOfTaxLine
37
+
38
+ //@author:swetal
39
+ //Added new properties to upgrade to 5.3 interface
40
+ private $TotalTaxCalculated; //decimal
41
+ private $TaxSummary; //ArrayOfTaxDetail
42
+
43
+
44
+
45
+ /**
46
+ * Gets the internal reference code used by the client application. This is used for operations such as Post and GetTaxHistory.
47
+ * <p>
48
+ * See {@link GetTaxRequest#getDocCode} on <b>GetTaxRequest</b> for more information about this member.
49
+ * </p>
50
+ *
51
+ * @return string
52
+ */
53
+ public function getDocCode() {return $this->DocCode; }
54
+
55
+ /**
56
+ * AdjustmentDescription set while making AdjustTax call.
57
+ *
58
+ * @return string
59
+ */
60
+ public function getAdjustmentDescription() { return $this->AdjustmentDescription; }
61
+
62
+ /**
63
+ * AdjustmentReason set while making AdjustTax call. It is a high level classification of why an Original Document is being modified.
64
+ *
65
+ * @return int
66
+ */
67
+ public function getAdjustmentReason(){ return $this->AdjustmentReason; }
68
+
69
+ /**
70
+ * Gets the date on the invoice, purchase order, etc.
71
+ * <p>
72
+ * See {@link GetTaxRequest#getDocDate} on <b>GetTaxRequest</b> for more information about this member.
73
+ * </p>
74
+ *
75
+ * @return date
76
+ */
77
+ public function getDocDate() {return $this->DocDate; }
78
+
79
+ /**
80
+ * Tax Date is the date used to calculate tax on the Document.
81
+ * <p>
82
+ * See {@link GetTaxRequest#taxDate} on <b>GetTaxRequest</b> for more information about this member.
83
+ * </p>
84
+ *
85
+ * @return date
86
+ */
87
+ public function getTaxDate() {return $this->TaxDate; }
88
+
89
+ /**
90
+ * Gets the Document Type.
91
+ * <p>
92
+ * See {@link GetTaxRequest#DocType} on <b>GetTaxRequest</b> for more information about this member.
93
+ * </p>
94
+ *
95
+ * @return DocumentType
96
+ */
97
+ public function getDocType() {return $this->DocType; }
98
+
99
+ /**
100
+ * Gets the document's status after the tax calculation.
101
+ *
102
+ * @return DocStatus
103
+ */
104
+ public function getDocStatus() {return $this->DocStatus; }
105
+
106
+ /**
107
+ * True if the document has been reconciled; Only committed documents can be reconciled.
108
+ * <p>
109
+ * For information on committing documents, see the <b>TaxSvc</b>'s
110
+ * {@link TaxSvcSoap#commitTax} method. For information
111
+ * on reconciling documents, see the {@link TaxSvcSoap#reconcileTaxHistory} method.
112
+ * </p>
113
+ *
114
+ * @return boolean
115
+ */
116
+ public function getIsReconciled() {return $this->Reconciled; }
117
+
118
+ /**
119
+ * Flag indicating if a Document has been locked by Avalara's MRS process. Locked documents can not be modified and can not be cancelled because they have been reported on Tax Return.
120
+ *
121
+ * @return boolean
122
+ */
123
+ public function getLocked() {return $this->Locked; }
124
+
125
+ /**
126
+ * Date of the last status change on the document (i.e. Save date, Post date, Commit date, Cancel date).
127
+ *
128
+ * @return dateTime
129
+ */
130
+ public function getTimestamp() {return $this->Timestamp; }
131
+
132
+ /**
133
+ * The sum of all line {@link Line#getAmount} values.
134
+ *
135
+ * @param decimal
136
+ */
137
+ public function getTotalAmount() {return $this->TotalAmount; }
138
+
139
+ /**
140
+ * Gets the sum of all <b>TaxLine</b> {@link TaxLine#getDiscount} amounts; Typically it
141
+ * will equal the requested Discount, but, but it is possible that no lines were marked as discounted.
142
+ *
143
+ * @return decimal
144
+ */
145
+ public function getTotalDiscount() {return $this->TotalDiscount; }
146
+
147
+ /**
148
+ * Gets the sum of all <b>TaxLine</b> {@link TaxLine#getExemption} amounts.
149
+ *
150
+ * @return decimal
151
+ * @deprecated See {@link TaxDetail#getExemption}.
152
+ */
153
+ public function getTotalExemption() {return $this->TotalExemption; }
154
+
155
+ /**
156
+ * Gets the amount the tax is based on; This is the total of all {@link Line} <b>Base</b> amounts;
157
+ * Typically it will be equal to the document
158
+ * {@link GetTaxResult#getTotalAmount} - {@link GetTaxRequest#getDiscount} - {@link #getTotalExemption}.
159
+ *
160
+ * @return decimal
161
+ * @deprecated See {@link TaxDetail#getTaxable}.
162
+ */
163
+ public function getTotalTaxable() {return $this->TotalTaxable; }
164
+
165
+ /**
166
+ * Gets the total tax for the document.
167
+ *
168
+ * @return decimal
169
+ */
170
+ public function getTotalTax() {return $this->TotalTax; }
171
+
172
+ /**
173
+ * HashCode to support Reconciliation.
174
+ *
175
+ * @return hashCode
176
+ */
177
+ public function getHashCode() {return $this->HashCode; }
178
+
179
+ /**
180
+ * Current version of the document.
181
+ *
182
+ * @return int
183
+ */
184
+ public function getVersion() {return $this->Version; }
185
+
186
+ /**
187
+ * Gets the Tax broken down by individual {@link TaxLine}.
188
+ *
189
+ * @return taxLines
190
+ */
191
+ public function getTaxLines() {return EnsureIsArray($this->TaxLines->TaxLine); }
192
+
193
+ /**
194
+ * TotalTaxCalculated indicates the total tax calculated by AvaTax. This is usually the same as the TotalTax, except when a tax override amount is specified.
195
+ * This is for informational purposes.The TotalTax will still be used for reporting
196
+ *
197
+ * @return unknown
198
+ */
199
+ public function getTotalTaxCalculated(){ return $this->TotalTaxCalculated;}
200
+
201
+ /**
202
+ * TaxSummary is now returned when GetTaxRequest.DetailLevel == DetailLevel.Line in addition to DetailLevel.Summary.
203
+ * It is not returned for DetailLevel.Document or DetailLevel.TaxDetail.
204
+ *
205
+ * @return ArrayOfTaxDetail
206
+ */
207
+ public function getTaxSummary() {return EnsureIsArray($this->TaxSummary->TaxDetail);}
208
+
209
+ public function getTaxLine($lineNo)
210
+ {
211
+ if($this->getTaxLines() != null)
212
+ {
213
+ foreach($this->getTaxLines() as $taxLine)
214
+ {
215
+ if($lineNo == $taxLine->getNo())
216
+ {
217
+ return $taxLine;
218
+ }
219
+
220
+ }
221
+ }
222
+ }
223
+
224
+
225
+
226
+ /////////////////////////////////////////////PHP bug requires this copy from BaseResult ///////////
227
+ /**
228
+ * @var string
229
+ */
230
+ private $TransactionId;
231
+ /**
232
+ * @var string must be one of the values defined in {@link SeverityLevel}.
233
+ */
234
+ private $ResultCode = 'Success';
235
+ /**
236
+ * @var array of Message.
237
+ */
238
+ private $Messages = array();
239
+
240
+ /**
241
+ * Accessor
242
+ * @return string
243
+ */
244
+ public function getTransactionId() { return $this->TransactionId; }
245
+ /**
246
+ * Accessor
247
+ * @return string
248
+ */
249
+ public function getResultCode() { return $this->ResultCode; }
250
+ /**
251
+ * Accessor
252
+ * @return array
253
+ */
254
+ public function getMessages() { return EnsureIsArray($this->Messages->Message); }
255
+
256
+
257
+
258
+
259
+
260
+
261
  }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/IsAuthorizedResult.class.php RENAMED
@@ -1,79 +1,79 @@
1
- <?php
2
- /**
3
- * IsAuthorizedResult.class.php
4
- * @package Address
5
- */
6
-
7
- /**
8
- * Result information returned from the AddressSvc's
9
- * {@link AddressServiceSoap#isAuthorized} method and the TaxSvc's
10
- * {@link TaxServiceSoap#isAuthorized}
11
- * method.
12
- * <p><b>Example:</b><br>
13
- * <pre>
14
- * $port = new AddressServiceSoap();
15
- *
16
- * $result = port->ping("");
17
- * $numMessages = sizeof($result->Messages);
18
- * print('Ping Result # of messages is '.$numMessages);
19
- * </pre>
20
- *
21
- * @package Address
22
- * @author tblanchard
23
- * Copyright (c) 2007, Avalara. All rights reserved.
24
- */
25
-
26
- class IsAuthorizedResult //extends BaseResult
27
- {
28
- private $Operations;
29
- private $Expires;
30
-
31
- /**
32
- * Authorized operations for the user.
33
- *
34
- * @return string
35
- */
36
- public function getOperations() { return $this->Operations; }
37
-
38
- /**
39
- * Indicates the subscription expiration date in yyyy-mm-dd format
40
- *
41
- * @return date
42
- */
43
- public function getExpires() { return $this->Expires; }
44
-
45
- public function setOperations($value) { $this->Operations = $value; return $this; }
46
- public function setExpires($value) { $this->Expires = $value; return $this; }
47
-
48
- //BaseResult innards - workaround for SoapClient bug
49
- /**
50
- * @var string
51
- */
52
- private $TransactionId;
53
- /**
54
- * @var string must be one of the values defined in {@link SeverityLevel}.
55
- */
56
- private $ResultCode = 'Success';
57
- /**
58
- * @var array of Message.
59
- */
60
- private $Messages = array();
61
-
62
- /**
63
- * Accessor
64
- * @return string
65
- */
66
- public function getTransactionId() { return $this->TransactionId; }
67
- /**
68
- * Accessor
69
- * @return string
70
- */
71
- public function getResultCode() { return $this->ResultCode; }
72
- /**
73
- * Accessor
74
- * @return array
75
- */
76
- public function getMessages() { return EnsureIsArray($this->Messages->Message); }
77
-
78
-
79
  }
1
+ <?php
2
+ /**
3
+ * IsAuthorizedResult.class.php
4
+ * @package Address
5
+ */
6
+
7
+ /**
8
+ * Result information returned from the AddressSvc's
9
+ * {@link AddressServiceSoap#isAuthorized} method and the TaxSvc's
10
+ * {@link TaxServiceSoap#isAuthorized}
11
+ * method.
12
+ * <p><b>Example:</b><br>
13
+ * <pre>
14
+ * $port = new AddressServiceSoap();
15
+ *
16
+ * $result = port->ping("");
17
+ * $numMessages = sizeof($result->Messages);
18
+ * print('Ping Result # of messages is '.$numMessages);
19
+ * </pre>
20
+ *
21
+ * @package Address
22
+ * @author tblanchard
23
+ * Copyright (c) 2007, Avalara. All rights reserved.
24
+ */
25
+
26
+ class IsAuthorizedResult //extends BaseResult
27
+ {
28
+ private $Operations;
29
+ private $Expires;
30
+
31
+ /**
32
+ * Authorized operations for the user.
33
+ *
34
+ * @return string
35
+ */
36
+ public function getOperations() { return $this->Operations; }
37
+
38
+ /**
39
+ * Indicates the subscription expiration date in yyyy-mm-dd format
40
+ *
41
+ * @return date
42
+ */
43
+ public function getExpires() { return $this->Expires; }
44
+
45
+ public function setOperations($value) { $this->Operations = $value; return $this; }
46
+ public function setExpires($value) { $this->Expires = $value; return $this; }
47
+
48
+ //BaseResult innards - workaround for SoapClient bug
49
+ /**
50
+ * @var string
51
+ */
52
+ private $TransactionId;
53
+ /**
54
+ * @var string must be one of the values defined in {@link SeverityLevel}.
55
+ */
56
+ private $ResultCode = 'Success';
57
+ /**
58
+ * @var array of Message.
59
+ */
60
+ private $Messages = array();
61
+
62
+ /**
63
+ * Accessor
64
+ * @return string
65
+ */
66
+ public function getTransactionId() { return $this->TransactionId; }
67
+ /**
68
+ * Accessor
69
+ * @return string
70
+ */
71
+ public function getResultCode() { return $this->ResultCode; }
72
+ /**
73
+ * Accessor
74
+ * @return array
75
+ */
76
+ public function getMessages() { return EnsureIsArray($this->Messages->Message); }
77
+
78
+
79
  }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/JurisdictionType.class.php RENAMED
@@ -1,73 +1,73 @@
1
- <?php
2
-
3
- /**
4
- * JurisdictionType.class.php
5
- * @package Tax
6
- */
7
-
8
- /**
9
- * A Jurisdiction Type describes the jurisdiction for which a particular tax is applied to a document.
10
- * Jurisdiction is determined by the GetTaxRequest#getDestinationAddress or GetTaxRequest#getOriginAddress of a GetTaxRequest.
11
- * Multiple jurisdictions might be applied to a single Line during a tax calcuation.
12
- * Details are available in the TaxDetail of the GetTaxResult.
13
- *
14
- * @package Tax
15
- * @see TaxDetail
16
- * @author tblanchard
17
- * Copyright (c) 2008, Avalara. All rights reserved.
18
- */
19
- class JurisdictionType
20
- {
21
- /**
22
- * Unspecified Jurisdiction
23
- *
24
- * @var JurisdictionType
25
- */
26
- public static $Composite = 'Composite';
27
-
28
- /**
29
- * State
30
- *
31
- * @var JurisdictionType
32
- */
33
- public static $State = 'State';
34
-
35
- /**
36
- * County
37
- *
38
- * @var JurisdictionType
39
- */
40
- public static $County = 'County';
41
-
42
- /**
43
- * City
44
- *
45
- * @var JurisdictionType
46
- */
47
- public static $City = 'City';
48
-
49
- /**
50
- * Special Tax Jurisdiction
51
- *
52
- * @var JurisdictionType
53
- */
54
- public static $Special = 'Special';
55
- /*
56
-
57
- public static function Values()
58
- {
59
- return array(
60
- JurisdictionType::$Composite,
61
- JurisdictionType::$State,
62
- JurisdictionType::$County,
63
- JurisdictionType::$City,
64
- JurisdictionType::$Special
65
- );
66
- }
67
-
68
- // Unfortunate boiler plate due to polymorphism issues on static functions
69
- public static function Validate($value) { self::__Validate($value,self::Values(),__CLASS__); }
70
-
71
- */
72
-
73
  }
1
+ <?php
2
+
3
+ /**
4
+ * JurisdictionType.class.php
5
+ * @package Tax
6
+ */
7
+
8
+ /**
9
+ * A Jurisdiction Type describes the jurisdiction for which a particular tax is applied to a document.
10
+ * Jurisdiction is determined by the GetTaxRequest#getDestinationAddress or GetTaxRequest#getOriginAddress of a GetTaxRequest.
11
+ * Multiple jurisdictions might be applied to a single Line during a tax calcuation.
12
+ * Details are available in the TaxDetail of the GetTaxResult.
13
+ *
14
+ * @package Tax
15
+ * @see TaxDetail
16
+ * @author tblanchard
17
+ * Copyright (c) 2008, Avalara. All rights reserved.
18
+ */
19
+ class JurisdictionType
20
+ {
21
+ /**
22
+ * Unspecified Jurisdiction
23
+ *
24
+ * @var JurisdictionType
25
+ */
26
+ public static $Composite = 'Composite';
27
+
28
+ /**
29
+ * State
30
+ *
31
+ * @var JurisdictionType
32
+ */
33
+ public static $State = 'State';
34
+
35
+ /**
36
+ * County
37
+ *
38
+ * @var JurisdictionType
39
+ */
40
+ public static $County = 'County';
41
+
42
+ /**
43
+ * City
44
+ *
45
+ * @var JurisdictionType
46
+ */
47
+ public static $City = 'City';
48
+
49
+ /**
50
+ * Special Tax Jurisdiction
51
+ *
52
+ * @var JurisdictionType
53
+ */
54
+ public static $Special = 'Special';
55
+ /*
56
+
57
+ public static function Values()
58
+ {
59
+ return array(
60
+ JurisdictionType::$Composite,
61
+ JurisdictionType::$State,
62
+ JurisdictionType::$County,
63
+ JurisdictionType::$City,
64
+ JurisdictionType::$Special
65
+ );
66
+ }
67
+
68
+ // Unfortunate boiler plate due to polymorphism issues on static functions
69
+ public static function Validate($value) { self::__Validate($value,self::Values(),__CLASS__); }
70
+
71
+ */
72
+
73
  }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/Line.class.php RENAMED
@@ -1,264 +1,264 @@
1
- <?php
2
- /**
3
- * Line.class.php
4
- * @package Tax
5
- */
6
-
7
- /**
8
- * A single line within a document containing data used for calculating tax.
9
-
10
- *
11
- * @see GetTaxRequest
12
- * @package Tax
13
- * @author tblanchard
14
- * Copyright (c) 2007, Avalara. All rights reserved.
15
- */
16
-
17
- class Line
18
- {
19
- private $No; //string // line Number of invoice
20
- private $OriginCode; //string Line#getOriginAddress.
21
- private $DestinationCode; //string Line#getDestinationAddress.
22
- private $ItemCode; //string
23
- private $Description; //string
24
- private $TaxCode; //string
25
- private $Qty; //decimal
26
- private $Amount; //decimal // TotalAmmount
27
- private $Discounted; //boolean is discount applied to this item
28
- private $RevAcct; //string
29
- private $Ref1; //string
30
- private $Ref2; //string
31
- private $ExemptionNo; //string //zero tax will result if filled in
32
- private $CustomerUsageType; //string
33
- private $BatchCode; //string
34
-
35
- private $TaxOverride; //TaxOverride
36
- private $OriginAddress; //Address
37
- private $DestinationAddress; //Address
38
- private $TaxIncluded; //boolean
39
-
40
-
41
-
42
- public function __construct($no=1,$qty=1,$amount=100.00)
43
- {
44
- $this->No=$no;
45
- $this->Qty=$qty;
46
- $this->Amount=$amount;
47
-
48
-
49
- $this->Discounted=false;
50
-
51
-
52
- }
53
-
54
-
55
- /*
56
- * Mutator
57
- * @access public
58
- * @param integer
59
- */
60
-
61
- /**
62
- * Line Number.
63
- *
64
- * @param string $value
65
- */
66
- public function setNo($value) { $this->No = $value; return $this; } //string // line Number of invoice
67
-
68
- /**
69
- * Item Code (SKU)
70
- *
71
- * @param string $value
72
- */
73
- public function setItemCode($value) { $this->ItemCode = $value; return $this; } //string
74
-
75
- /**
76
- * Sets the description which defines the description for the product or item.
77
- *
78
- * @param string $value
79
- */
80
- public function setDescription($value) { $this->Description = $value; return $this; } //string
81
-
82
- /**
83
- * System or Custom Tax Code.
84
- *
85
- * @param string $value
86
- */
87
- public function setTaxCode($value) { $this->TaxCode = $value; return $this; } //string
88
-
89
- /**
90
- * Revenue Account.
91
- *
92
- * @param string $value
93
- */
94
- public function setRevAcct($value) { $this->RevAcct = $value; return $this; } //string
95
-
96
- /**
97
- * Client specific reference field.
98
- *
99
- * @param string $value
100
- */
101
- public function setRef1($value) { $this->Ref1 = $value; return $this; } //string
102
-
103
- /**
104
- * Client specific reference field.
105
- *
106
- * @param string $value
107
- */
108
- public function setRef2($value) { $this->Ref2 = $value; return $this; } //string
109
-
110
- /**
111
- * Exemption number for this line
112
- *
113
- * @param string $value
114
- */
115
- public function setExemptionNo($value) { $this->ExemptionNo = $value; return $this; } //string //zero tax will result if filled in
116
-
117
- /**
118
- * The client application customer or usage type.
119
- * <p>
120
- * This is used to determine the exempt status of the transaction based on the exemption tax rules for the
121
- * jurisdictions involved. This may also be set at the line level.
122
- * </p>
123
- * <p>
124
- * The standard values for the CustomerUsageType (A-L).<br/>
125
- A � Federal Government<br/>
126
- B � State/Local Govt.<br/>
127
- C � Tribal Government<br/>
128
- D � Foreign Diplomat<br/>
129
- E � Charitable Organization<br/>
130
- F � Religious/Education<br/>
131
- G � Resale<br/>
132
- H � Agricultural Production<br/>
133
- I � Industrial Prod/Mfg.<br/>
134
- J � Direct Pay Permit<br/>
135
- K � Direct Mail<br/>
136
- L - Other<br/>
137
- * </p>
138
- * @param string $value
139
- */
140
- public function setCustomerUsageType($value) { $this->CustomerUsageType = $value; return $this; } //string
141
-
142
- /**
143
- * Enter description here...
144
- *
145
- * @param string $value
146
- */
147
- public function setBatchCode($value) { $this->BatchCode = $value; return $this; } //string
148
-
149
- /**
150
- * The quantity represented by this line.
151
- *
152
- * @param string $value
153
- */
154
- public function setQty($value) { $this->Qty = $value; return $this; } //decimal
155
-
156
- /**
157
- * The total amount for this line item (Qty * UnitPrice).
158
- *
159
- * @param string $value
160
- */
161
- public function setAmount($value) { $this->Amount = $value; return $this; } //decimal // TotalAmmount
162
-
163
- /**
164
- * TaxOverride for the document at line level.
165
- *
166
- * @param string $value
167
- */
168
- public function setTaxOverride($value) { $this->TaxOverride = $value; return $this; } //decimal
169
-
170
- /**
171
- * True if the document discount should be applied to this line
172
- *
173
- * @param string $value
174
- */
175
- public function setDiscounted( $value) { $this->Discounted = ($value ? true : false); return $this; } //boolean is discount applied to this item
176
-
177
- /**
178
- * Sets the Address used as the "Ship From" location for a specific line item.
179
- *
180
- * @param string $value
181
- */
182
- public function setOriginAddress(&$value) { $this->OriginAddress = $value; return $this; } //Address
183
-
184
- /**
185
- * Sets the Address used as the "Ship To" location for a specific line item.
186
- *
187
- * @param string $value
188
- */
189
- public function setDestinationAddress(&$value) { $this->DestinationAddress = $value; return $this; } //Address
190
-
191
- /**
192
- * True if tax is included in the line.
193
- * @param boolean
194
- */
195
- public function setTaxIncluded($value)
196
- {
197
- $this->TaxIncluded=$value;
198
- }
199
-
200
- /**
201
- * True if tax is included in the line.
202
- * @return boolean
203
- */
204
- public function getTaxIncluded($value)
205
- {
206
- return $this->TaxIncluded;
207
- }
208
-
209
- public function registerAddressesIn(&$getTaxRequest)
210
- {
211
- if(is_null($this->OriginAddress))
212
- {
213
- $this->OriginAddress = $getTaxRequest->getOriginAddress();
214
-
215
- }
216
- if(is_null($this->DestinationAddress))
217
- {
218
- $this->DestinationAddress = $getTaxRequest->getDestinationAddress();
219
-
220
- }
221
- $this->OriginCode = $getTaxRequest->registerAddress($this->OriginAddress);
222
- $this->DestinationCode = $getTaxRequest->registerAddress($this->DestinationAddress);
223
- }
224
-
225
- public function postFetchWithAddresses($addresses)
226
- {
227
- $this->OriginAddress = $addresses[$this->OriginCode];
228
- $this->DestinationAddress = $addresses[$this->DestinationCode];
229
- }
230
-
231
- //accessors
232
- /**#@+
233
- * Accessor
234
- * @access public
235
- * @return string
236
- */
237
-
238
-
239
- public function getNo () { return $this->No; } //string // line Number of invoice
240
- public function getItemCode() { return $this->ItemCode; } //string
241
- public function getDescription() { return $this->Description; } //string
242
- public function getTaxCode() { return $this->TaxCode; } //string
243
- public function getRevAcct() { return $this->RevAcct; } //string
244
- public function getRef1() { return $this->Ref1; } //string
245
- public function getRef2() { return $this->Ref2; } //string
246
- public function getExemptionNo() { return $this->ExemptionNo; } //string //zero tax will result if filled in
247
- public function getCustomerUsageType() { return $this->CustomerUsageType; } //string
248
- public function getBatchCode() { return $this->BatchCode; } //string
249
-
250
- public function getQty() { return $this->Qty; } //decimal
251
- public function getAmount() { return $this->Amount; } //decimal // TotalAmmount
252
- public function getTaxOverride() { return $this->TaxOverride; } //decimal
253
-
254
- public function getDiscounted() { return $this->Discounted; } //boolean is discount applied to this item
255
-
256
-
257
- public function getOriginAddress() { return $this->OriginAddress; } //Address
258
- public function getDestinationAddress() { return $this->DestinationAddress; } //Address
259
-
260
-
261
-
262
- /**#@-*/
263
-
264
  }
1
+ <?php
2
+ /**
3
+ * Line.class.php
4
+ * @package Tax
5
+ */
6
+
7
+ /**
8
+ * A single line within a document containing data used for calculating tax.
9
+
10
+ *
11
+ * @see GetTaxRequest
12
+ * @package Tax
13
+ * @author tblanchard
14
+ * Copyright (c) 2007, Avalara. All rights reserved.
15
+ */
16
+
17
+ class Line
18
+ {
19
+ private $No; //string // line Number of invoice
20
+ private $OriginCode; //string Line#getOriginAddress.
21
+ private $DestinationCode; //string Line#getDestinationAddress.
22
+ private $ItemCode; //string
23
+ private $Description; //string
24
+ private $TaxCode; //string
25
+ private $Qty; //decimal
26
+ private $Amount; //decimal // TotalAmmount
27
+ private $Discounted; //boolean is discount applied to this item
28
+ private $RevAcct; //string
29
+ private $Ref1; //string
30
+ private $Ref2; //string
31
+ private $ExemptionNo; //string //zero tax will result if filled in
32
+ private $CustomerUsageType; //string
33
+ private $BatchCode; //string
34
+
35
+ private $TaxOverride; //TaxOverride
36
+ private $OriginAddress; //Address
37
+ private $DestinationAddress; //Address
38
+ private $TaxIncluded; //boolean
39
+
40
+
41
+
42
+ public function __construct($no=1,$qty=1,$amount=100.00)
43
+ {
44
+ $this->No=$no;
45
+ $this->Qty=$qty;
46
+ $this->Amount=$amount;
47
+
48
+
49
+ $this->Discounted=false;
50
+
51
+
52
+ }
53
+
54
+
55
+ /*
56
+ * Mutator
57
+ * @access public
58
+ * @param integer
59
+ */
60
+
61
+ /**
62
+ * Line Number.
63
+ *
64
+ * @param string $value
65
+ */
66
+ public function setNo($value) { $this->No = $value; return $this; } //string // line Number of invoice
67
+
68
+ /**
69
+ * Item Code (SKU)
70
+ *
71
+ * @param string $value
72
+ */
73
+ public function setItemCode($value) { $this->ItemCode = $value; return $this; } //string
74
+
75
+ /**
76
+ * Sets the description which defines the description for the product or item.
77
+ *
78
+ * @param string $value
79
+ */
80
+ public function setDescription($value) { $this->Description = $value; return $this; } //string
81
+
82
+ /**
83
+ * System or Custom Tax Code.
84
+ *
85
+ * @param string $value
86
+ */
87
+ public function setTaxCode($value) { $this->TaxCode = $value; return $this; } //string
88
+
89
+ /**
90
+ * Revenue Account.
91
+ *
92
+ * @param string $value
93
+ */
94
+ public function setRevAcct($value) { $this->RevAcct = $value; return $this; } //string
95
+
96
+ /**
97
+ * Client specific reference field.
98
+ *
99
+ * @param string $value
100
+ */
101
+ public function setRef1($value) { $this->Ref1 = $value; return $this; } //string
102
+
103
+ /**
104
+ * Client specific reference field.
105
+ *
106
+ * @param string $value
107
+ */
108
+ public function setRef2($value) { $this->Ref2 = $value; return $this; } //string
109
+
110
+ /**
111
+ * Exemption number for this line
112
+ *
113
+ * @param string $value
114
+ */
115
+ public function setExemptionNo($value) { $this->ExemptionNo = $value; return $this; } //string //zero tax will result if filled in
116
+
117
+ /**
118
+ * The client application customer or usage type.
119
+ * <p>
120
+ * This is used to determine the exempt status of the transaction based on the exemption tax rules for the
121
+ * jurisdictions involved. This may also be set at the line level.
122
+ * </p>
123
+ * <p>
124
+ * The standard values for the CustomerUsageType (A-L).<br/>
125
+ A � Federal Government<br/>
126
+ B � State/Local Govt.<br/>
127
+ C � Tribal Government<br/>
128
+ D � Foreign Diplomat<br/>
129
+ E � Charitable Organization<br/>
130
+ F � Religious/Education<br/>
131
+ G � Resale<br/>
132
+ H � Agricultural Production<br/>
133
+ I � Industrial Prod/Mfg.<br/>
134
+ J � Direct Pay Permit<br/>
135
+ K � Direct Mail<br/>
136
+ L - Other<br/>
137
+ * </p>
138
+ * @param string $value
139
+ */
140
+ public function setCustomerUsageType($value) { $this->CustomerUsageType = $value; return $this; } //string
141
+
142
+ /**
143
+ * Enter description here...
144
+ *
145
+ * @param string $value
146
+ */
147
+ public function setBatchCode($value) { $this->BatchCode = $value; return $this; } //string
148
+
149
+ /**
150
+ * The quantity represented by this line.
151
+ *
152
+ * @param string $value
153
+ */
154
+ public function setQty($value) { $this->Qty = $value; return $this; } //decimal
155
+
156
+ /**
157
+ * The total amount for this line item (Qty * UnitPrice).
158
+ *
159
+ * @param string $value
160
+ */
161
+ public function setAmount($value) { $this->Amount = $value; return $this; } //decimal // TotalAmmount
162
+
163
+ /**
164
+ * TaxOverride for the document at line level.
165
+ *
166
+ * @param string $value
167
+ */
168
+ public function setTaxOverride($value) { $this->TaxOverride = $value; return $this; } //decimal
169
+
170
+ /**
171
+ * True if the document discount should be applied to this line
172
+ *
173
+ * @param string $value
174
+ */
175
+ public function setDiscounted( $value) { $this->Discounted = ($value ? true : false); return $this; } //boolean is discount applied to this item
176
+
177
+ /**
178
+ * Sets the Address used as the "Ship From" location for a specific line item.
179
+ *
180
+ * @param string $value
181
+ */
182
+ public function setOriginAddress(&$value) { $this->OriginAddress = $value; return $this; } //Address
183
+
184
+ /**
185
+ * Sets the Address used as the "Ship To" location for a specific line item.
186
+ *
187
+ * @param string $value
188
+ */
189
+ public function setDestinationAddress(&$value) { $this->DestinationAddress = $value; return $this; } //Address
190
+
191
+ /**
192
+ * True if tax is included in the line.
193
+ * @param boolean
194
+ */
195
+ public function setTaxIncluded($value)
196
+ {
197
+ $this->TaxIncluded=$value;
198
+ }
199
+
200
+ /**
201
+ * True if tax is included in the line.
202
+ * @return boolean
203
+ */
204
+ public function getTaxIncluded($value)
205
+ {
206
+ return $this->TaxIncluded;
207
+ }
208
+
209
+ public function registerAddressesIn(&$getTaxRequest)
210
+ {
211
+ if(is_null($this->OriginAddress))
212
+ {
213
+ $this->OriginAddress = $getTaxRequest->getOriginAddress();
214
+
215
+ }
216
+ if(is_null($this->DestinationAddress))
217
+ {
218
+ $this->DestinationAddress = $getTaxRequest->getDestinationAddress();
219
+
220
+ }
221
+ $this->OriginCode = $getTaxRequest->registerAddress($this->OriginAddress);
222
+ $this->DestinationCode = $getTaxRequest->registerAddress($this->DestinationAddress);
223
+ }
224
+
225
+ public function postFetchWithAddresses($addresses)
226
+ {
227
+ $this->OriginAddress = $addresses[$this->OriginCode];
228
+ $this->DestinationAddress = $addresses[$this->DestinationCode];
229
+ }
230
+
231
+ //accessors
232
+ /**#@+
233
+ * Accessor
234
+ * @access public
235
+ * @return string
236
+ */
237
+
238
+
239
+ public function getNo () { return $this->No; } //string // line Number of invoice
240
+ public function getItemCode() { return $this->ItemCode; } //string
241
+ public function getDescription() { return $this->Description; } //string
242
+ public function getTaxCode() { return $this->TaxCode; } //string
243
+ public function getRevAcct() { return $this->RevAcct; } //string
244
+ public function getRef1() { return $this->Ref1; } //string
245
+ public function getRef2() { return $this->Ref2; } //string
246
+ public function getExemptionNo() { return $this->ExemptionNo; } //string //zero tax will result if filled in
247
+ public function getCustomerUsageType() { return $this->CustomerUsageType; } //string
248
+ public function getBatchCode() { return $this->BatchCode; } //string
249
+
250
+ public function getQty() { return $this->Qty; } //decimal
251
+ public function getAmount() { return $this->Amount; } //decimal // TotalAmmount
252
+ public function getTaxOverride() { return $this->TaxOverride; } //decimal
253
+
254
+ public function getDiscounted() { return $this->Discounted; } //boolean is discount applied to this item
255
+
256
+
257
+ public function getOriginAddress() { return $this->OriginAddress; } //Address
258
+ public function getDestinationAddress() { return $this->DestinationAddress; } //Address
259
+
260
+
261
+
262
+ /**#@-*/
263
+
264
  }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/Message.class.php RENAMED
@@ -1,86 +1,86 @@
1
- <?php
2
- /**
3
- * Message.class.php
4
- *
5
- * @package Address
6
- */
7
-
8
- /**
9
- * Message class used in results and exceptions.
10
- *
11
- * Contains status detail about call results.
12
- *
13
- * @package Address
14
- * @author tblanchard
15
- * Copyright (c) 2007, Avalara. All rights reserved.
16
- */
17
-
18
- class Message
19
- {
20
- private $Summary;
21
- private $Details;
22
- private $HelpLink;
23
- private $RefersTo;
24
- private $Severity;
25
- private $Source;
26
- private $Name;
27
-
28
- /**
29
- * Gets the concise summary of the message.
30
- *
31
- * @return string
32
- */
33
- public function getSummary() { return $this->Summary; }
34
-
35
- /**
36
- * Gets the details of the message.
37
- *
38
- * @return string
39
- */
40
- public function getDetails() { return $this->Details; }
41
-
42
- /**
43
- *Gets the URL to help page for this message.
44
- *
45
- * @return unknown
46
- */
47
- public function getHelpLink() { return $this->HelpLink; }
48
-
49
- /**
50
- * Gets the item the message refers to, if applicable. Used to indicate a missing or incorrect value.
51
- *
52
- * @return unknown
53
- */
54
- public function getRefersTo() { return $this->RefersTo; }
55
-
56
- /**
57
- * Gets the Severity Level of the message.
58
- *
59
- * @return unknown
60
- */
61
- public function getSeverity() { return $this->Severity; }
62
-
63
- /**
64
- * Gets the source of the message.
65
- *
66
- * @return unknown
67
- */
68
- public function getSource() { return $this->Source; }
69
-
70
- /**
71
- * Gets the name of the message.
72
- *
73
- * @return unknown
74
- */
75
- public function getName() { return $this->Name; }
76
-
77
- // mutators
78
- public function setSummary($value) { $this->Summary = $value; return $this; }
79
- public function setDetails($value) { $this->Details = $value; return $this; }
80
- public function setHelpLink($value) { $this->HelpLink = $value; return $this; }
81
- public function setRefersTo($value) { $this->RefersTo = $value; return $this; }
82
- public function setSeverity($value) { SeverityLevel::Validate($value); $this->Severity = $value; return $this; }
83
- public function setSource($value) { $this->Source = $value; return $this; }
84
- public function setName($value) { $this->Name = $value; return $this; }
85
-
86
  }
1
+ <?php
2
+ /**
3
+ * Message.class.php
4
+ *
5
+ * @package Address
6
+ */
7
+
8
+ /**
9
+ * Message class used in results and exceptions.
10
+ *
11
+ * Contains status detail about call results.
12
+ *
13
+ * @package Address
14
+ * @author tblanchard
15
+ * Copyright (c) 2007, Avalara. All rights reserved.
16
+ */
17
+
18
+ class Message
19
+ {
20
+ private $Summary;
21
+ private $Details;
22
+ private $HelpLink;
23
+ private $RefersTo;
24
+ private $Severity;
25
+ private $Source;
26
+ private $Name;
27
+
28
+ /**
29
+ * Gets the concise summary of the message.
30
+ *
31
+ * @return string
32
+ */
33
+ public function getSummary() { return $this->Summary; }
34
+
35
+ /**
36
+ * Gets the details of the message.
37
+ *
38
+ * @return string
39
+ */
40
+ public function getDetails() { return $this->Details; }
41
+
42
+ /**
43
+ *Gets the URL to help page for this message.
44
+ *
45
+ * @return unknown
46
+ */
47
+ public function getHelpLink() { return $this->HelpLink; }
48
+
49
+ /**
50
+ * Gets the item the message refers to, if applicable. Used to indicate a missing or incorrect value.
51
+ *
52
+ * @return unknown
53
+ */
54
+ public function getRefersTo() { return $this->RefersTo; }
55
+
56
+ /**
57
+ * Gets the Severity Level of the message.
58
+ *
59
+ * @return unknown
60
+ */
61
+ public function getSeverity() { return $this->Severity; }
62
+
63
+ /**
64
+ * Gets the source of the message.
65
+ *
66
+ * @return unknown
67
+ */
68
+ public function getSource() { return $this->Source; }
69
+
70
+ /**
71
+ * Gets the name of the message.
72
+ *
73
+ * @return unknown
74
+ */
75
+ public function getName() { return $this->Name; }
76
+
77
+ // mutators
78
+ public function setSummary($value) { $this->Summary = $value; return $this; }
79
+ public function setDetails($value) { $this->Details = $value; return $this; }
80
+ public function setHelpLink($value) { $this->HelpLink = $value; return $this; }
81
+ public function setRefersTo($value) { $this->RefersTo = $value; return $this; }
82
+ public function setSeverity($value) { SeverityLevel::Validate($value); $this->Severity = $value; return $this; }
83
+ public function setSource($value) { $this->Source = $value; return $this; }
84
+ public function setName($value) { $this->Name = $value; return $this; }
85
+
86
  }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/PingResult.class.php RENAMED
@@ -1,74 +1,74 @@
1
- <?php
2
- /**
3
- * PingResult.class.php
4
- *
5
- * @package Base
6
- */
7
-
8
- /**
9
- * Result information returned from the {@link AddressServiceSoap}'s
10
- * {@link AddressServiceSoap#ping} method and the {@link TaxServiceSoap}'s
11
- * {@link TaxServiceSoap#ping} method.
12
- * <b>Example:</b><br>
13
- * <pre>
14
- * $svc = new AddressServiceSoap();
15
- *
16
- * $result = svc->ping();
17
- * $numMessages = sizeof($result->getMessages());
18
- *
19
- * </pre>
20
- *
21
- * @package Base
22
- * @author tblanchard
23
- * Copyright (c) 2007, Avalara. All rights reserved.
24
- */
25
-
26
-
27
- class PingResult //extends BaseResult
28
- {
29
- /**
30
- * Version string of the pinged service.
31
- * @var string
32
- */
33
- private $Version;
34
-
35
- /**
36
- * Method returning version string of the pinged service.
37
- * @return string
38
- */
39
- public function getVersion() { return $this->Version; }
40
-
41
- // BaseResult innards - workaround a bug in SoapClient
42
-
43
- /**
44
- * @var string
45
- */
46
- private $TransactionId;
47
- /**
48
- * @var string must be one of the values defined in {@link SeverityLevel}.
49
- */
50
- private $ResultCode = 'Success';
51
- /**
52
- * @var array of Message.
53
- */
54
- private $Messages = array();
55
-
56
- /**
57
- * Accessor
58
- * @return string
59
- */
60
- public function getTransactionId() { return $this->TransactionId; }
61
- /**
62
- * Accessor
63
- * @return string
64
- */
65
- public function getResultCode() { return $this->ResultCode; }
66
- /**
67
- * Accessor
68
- * @return array
69
- */
70
- public function getMessages() { return EnsureIsArray($this->Messages->Message); }
71
-
72
-
73
-
74
  }
1
+ <?php
2
+ /**
3
+ * PingResult.class.php
4
+ *
5
+ * @package Base
6
+ */
7
+
8
+ /**
9
+ * Result information returned from the {@link AddressServiceSoap}'s
10
+ * {@link AddressServiceSoap#ping} method and the {@link TaxServiceSoap}'s
11
+ * {@link TaxServiceSoap#ping} method.
12
+ * <b>Example:</b><br>
13
+ * <pre>
14
+ * $svc = new AddressServiceSoap();
15
+ *
16
+ * $result = svc->ping();
17
+ * $numMessages = sizeof($result->getMessages());
18
+ *
19
+ * </pre>
20
+ *
21
+ * @package Base
22
+ * @author tblanchard
23
+ * Copyright (c) 2007, Avalara. All rights reserved.
24
+ */
25
+
26
+
27
+ class PingResult //extends BaseResult
28
+ {
29
+ /**
30
+ * Version string of the pinged service.
31
+ * @var string
32
+ */
33
+ private $Version;
34
+
35
+ /**
36
+ * Method returning version string of the pinged service.
37
+ * @return string
38
+ */
39
+ public function getVersion() { return $this->Version; }
40
+
41
+ // BaseResult innards - workaround a bug in SoapClient
42
+
43
+ /**
44
+ * @var string
45
+ */
46
+ private $TransactionId;
47
+ /**
48
+ * @var string must be one of the values defined in {@link SeverityLevel}.
49
+ */
50
+ private $ResultCode = 'Success';
51
+ /**
52
+ * @var array of Message.
53
+ */
54
+ private $Messages = array();
55
+
56
+ /**
57
+ * Accessor
58
+ * @return string
59
+ */
60
+ public function getTransactionId() { return $this->TransactionId; }
61
+ /**
62
+ * Accessor
63
+ * @return string
64
+ */
65
+ public function getResultCode() { return $this->ResultCode; }
66
+ /**
67
+ * Accessor
68
+ * @return array
69
+ */
70
+ public function getMessages() { return EnsureIsArray($this->Messages->Message); }
71
+
72
+
73
+
74
  }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/PostTaxRequest.class.php RENAMED
@@ -1,79 +1,79 @@
1
- <?php
2
- /**
3
- * PostTaxRequest.class.php
4
- * @package Tax
5
- */
6
-
7
- /**
8
- * Data to pass to {@link TaxServiceSoap#commitTax}.
9
- * <p>
10
- * The request must specify all of CompanyCode, DocCode, and DocType in order to uniquely identify the document.
11
- * </p>
12
- *
13
- * @package Tax
14
- * @see PostTaxResult
15
- * @author tblanchard
16
- * Copyright (c) 2007, Avalara. All rights reserved.
17
- */
18
-
19
- class PostTaxRequest extends TaxRequest
20
- {
21
- private $DocDate; //date
22
- private $TotalAmount; // decimal
23
- private $TotalTax; // decimal
24
- private $Commit=false; // boolean
25
- private $NewDocCode; //string
26
-
27
-
28
- public function __construct()
29
- {
30
- parent::__construct();
31
-
32
-
33
- }
34
-
35
- public function getDocDate() { return $this->DocDate; }
36
- public function getTotalAmount() { return $this->TotalAmount; }
37
- public function getTotalTax() { return $this->TotalTax; }
38
- public function getCommit() { return $this->Commit; }
39
- public function getNewDocCode() { return $this->NewDocCode; }
40
-
41
-
42
- /**
43
- * DocDate should be in the format yyyy-mm-dd
44
- *
45
- * @param date $value
46
- */
47
- public function setDocDate($value) { $this->DocDate = $value; return $this; }
48
-
49
- /**
50
- *The total amount (not including tax) for the document.
51
- *
52
- * @param decimal $value
53
- */
54
- public function setTotalAmount($value) { $this->TotalAmount = $value; return $this; }
55
-
56
- /**
57
- * The total tax for the document.
58
- *
59
- * @param decimal $value
60
- */
61
- public function setTotalTax($value) { $this->TotalTax = $value; return $this; }
62
-
63
- /**
64
- * If this is set to True, AvaTax will Post and Commit the document in one call.
65
- * A very useful feature if you want to Post/Commit the document in one call this avoides one round trip to AvaTax server.
66
- *
67
- * @param string $value
68
- */
69
- public function setCommit($value) { $this->Commit = ($value ? true : false); return $this; }
70
-
71
- /**
72
- * New Document Code for the document.
73
- * As on this version of SDK DocCode can be changed during post using NewDocCode.
74
-
75
- * @param string $value
76
- */
77
- public function setNewDocCode($value) { $this->NewDocCode = $value; }
78
-
79
  }
1
+ <?php
2
+ /**
3
+ * PostTaxRequest.class.php
4
+ * @package Tax
5
+ */
6
+
7
+ /**
8
+ * Data to pass to {@link TaxServiceSoap#commitTax}.
9
+ * <p>
10
+ * The request must specify all of CompanyCode, DocCode, and DocType in order to uniquely identify the document.
11
+ * </p>
12
+ *
13
+ * @package Tax
14
+ * @see PostTaxResult
15
+ * @author tblanchard
16
+ * Copyright (c) 2007, Avalara. All rights reserved.
17
+ */
18
+
19
+ class PostTaxRequest extends TaxRequest
20
+ {
21
+ private $DocDate; //date
22
+ private $TotalAmount; // decimal
23
+ private $TotalTax; // decimal
24
+ private $Commit=false; // boolean
25
+ private $NewDocCode; //string
26
+
27
+
28
+ public function __construct()
29
+ {
30
+ parent::__construct();
31
+
32
+
33
+ }
34
+
35
+ public function getDocDate() { return $this->DocDate; }
36
+ public function getTotalAmount() { return $this->TotalAmount; }
37
+ public function getTotalTax() { return $this->TotalTax; }
38
+ public function getCommit() { return $this->Commit; }
39
+ public function getNewDocCode() { return $this->NewDocCode; }
40
+
41
+
42
+ /**
43
+ * DocDate should be in the format yyyy-mm-dd
44
+ *
45
+ * @param date $value
46
+ */
47
+ public function setDocDate($value) { $this->DocDate = $value; return $this; }
48
+
49
+ /**
50
+ *The total amount (not including tax) for the document.
51
+ *
52
+ * @param decimal $value
53
+ */
54
+ public function setTotalAmount($value) { $this->TotalAmount = $value; return $this; }
55
+
56
+ /**
57
+ * The total tax for the document.
58
+ *
59
+ * @param decimal $value
60
+ */
61
+ public function setTotalTax($value) { $this->TotalTax = $value; return $this; }
62
+
63
+ /**
64
+ * If this is set to True, AvaTax will Post and Commit the document in one call.
65
+ * A very useful feature if you want to Post/Commit the document in one call this avoides one round trip to AvaTax server.
66
+ *
67
+ * @param string $value
68
+ */
69
+ public function setCommit($value) { $this->Commit = ($value ? true : false); return $this; }
70
+
71
+ /**
72
+ * New Document Code for the document.
73
+ * As on this version of SDK DocCode can be changed during post using NewDocCode.
74
+
75
+ * @param string $value
76
+ */
77
+ public function setNewDocCode($value) { $this->NewDocCode = $value; }
78
+
79
  }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/PostTaxResult.class.php RENAMED
@@ -1,52 +1,52 @@
1
- <?php
2
- /**
3
- * PostTaxResult.class.php
4
- * @package Tax
5
- */
6
-
7
- /**
8
- * Result data returned from {@link TaxServiceSoap#postTax}.
9
- *
10
- * @package Tax
11
- * @see PostTaxRequest
12
- * @author tblanchard
13
- * Copyright (c) 2007, Avalara. All rights reserved.
14
- */
15
-
16
- class PostTaxResult //extends BaseResult
17
- {
18
-
19
-
20
- // BaseResult innards - work around a bug in SoapClient
21
-
22
- /**
23
- * @var string
24
- */
25
- private $TransactionId;
26
- /**
27
- * @var string must be one of the values defined in {@link SeverityLevel}.
28
- */
29
- private $ResultCode = 'Success';
30
- /**
31
- * @var array of Message.
32
- */
33
- private $Messages = array();
34
-
35
- /**
36
- * Accessor
37
- * @return string
38
- */
39
- public function getTransactionId() { return $this->TransactionId; }
40
- /**
41
- * Accessor
42
- * @return string
43
- */
44
- public function getResultCode() { return $this->ResultCode; }
45
- /**
46
- * Accessor
47
- * @return array
48
- */
49
- public function getMessages() { return EnsureIsArray($this->Messages->Message); }
50
-
51
-
52
  }
1
+ <?php
2
+ /**
3
+ * PostTaxResult.class.php
4
+ * @package Tax
5
+ */
6
+
7
+ /**
8
+ * Result data returned from {@link TaxServiceSoap#postTax}.
9
+ *
10
+ * @package Tax
11
+ * @see PostTaxRequest
12
+ * @author tblanchard
13
+ * Copyright (c) 2007, Avalara. All rights reserved.
14
+ */
15
+
16
+ class PostTaxResult //extends BaseResult
17
+ {
18
+
19
+
20
+ // BaseResult innards - work around a bug in SoapClient
21
+
22
+ /**
23
+ * @var string
24
+ */
25
+ private $TransactionId;
26
+ /**
27
+ * @var string must be one of the values defined in {@link SeverityLevel}.
28
+ */
29
+ private $ResultCode = 'Success';
30
+ /**
31
+ * @var array of Message.
32
+ */
33
+ private $Messages = array();
34
+
35
+ /**
36
+ * Accessor
37
+ * @return string
38
+ */
39
+ public function getTransactionId() { return $this->TransactionId; }
40
+ /**
41
+ * Accessor
42
+ * @return string
43
+ */
44
+ public function getResultCode() { return $this->ResultCode; }
45
+ /**
46
+ * Accessor
47
+ * @return array
48
+ */
49
+ public function getMessages() { return EnsureIsArray($this->Messages->Message); }
50
+
51
+
52
  }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/ReconcileTaxHistoryRequest.class.php RENAMED
@@ -1,89 +1,89 @@
1
- <?php
2
-
3
- /**
4
- * ReconcileTaxHistoryRequest.class.php
5
- * @package Tax
6
- */
7
-
8
- /**
9
- * Data to pass to {@link TaxServiceSoap#reconcileTaxHistory(ReconcileTaxHistoryRequest)}
10
- *
11
- * @package Tax
12
- * @see ReconcileTaxHistoryResult
13
- * @author tblanchard
14
- * Copyright (c) 2007, Avalara. All rights reserved.
15
- */
16
-
17
-
18
- class ReconcileTaxHistoryRequest// extends TaxRequest
19
- {
20
- private $CompanyCode; //string
21
- private $StartDate; //date
22
- private $EndDate; //date
23
- private $DocStatus; //int
24
-
25
- private $DocType; // DocType
26
- private $LastDocCode; // string
27
- private $PageSize; // int
28
-
29
- private $Reconciled=true;
30
-
31
- public function __construct()
32
- {
33
- //parent::__construct();
34
- $this->EndDate = date("Y-m-d");
35
- $this->DocStatus =DocStatus::$Any;
36
-
37
- }
38
-
39
-
40
-
41
- public function getCompanyCode() { return $this->CompanyCode;}
42
-
43
-
44
- public function getstartDate() { return $this->StartDate; }
45
- public function getEndDate() { return $this->EndDate; }
46
- public function getDocStatus() { return $this->DocStatus; }
47
-
48
- /**
49
- * Sets the client application company reference code.
50
- *
51
- * @param string $value
52
- */
53
- public function setCompanyCode($value) { $this->CompanyCode = $value; return $this; }
54
-
55
-
56
-
57
- /**
58
- * Set this to retrieve data FROM a specific date.
59
- *
60
- * @param date $value
61
- */
62
- public function setStartDate($value) { $this->StartDate = $value; return $this; }
63
-
64
- /**
65
- * Set this to retrieve data TO a specific date.
66
- *
67
- * @param date $value
68
- */
69
- public function setEndDate($value) { $this->EndDate = $value; return $this; }
70
-
71
- /**
72
- * Set this to retrieve data with a specific DocStatus.
73
- *
74
- * @param string $value
75
- */
76
- public function setDocStatus($value) { DocStatus::Validate($value); $this->DocStatus = $value; return $this; }
77
-
78
-
79
- public function setDocType($value){$this->DocType=$value;} // DocType
80
- public function getDocType(){return $this->DocType;} // DocType
81
-
82
- public function setLastDocCode($value){$this->LastDocCode=$value;} // string
83
- public function getLastDocCode(){return $this->LastDocCode;} // string
84
-
85
- public function setPageSize($value){$this->PageSize=$value;} // int
86
- public function getPageSize(){return $this->PageSize;} // int
87
-
88
-
89
  }
1
+ <?php
2
+
3
+ /**
4
+ * ReconcileTaxHistoryRequest.class.php
5
+ * @package Tax
6
+ */
7
+
8
+ /**
9
+ * Data to pass to {@link TaxServiceSoap#reconcileTaxHistory(ReconcileTaxHistoryRequest)}
10
+ *
11
+ * @package Tax
12
+ * @see ReconcileTaxHistoryResult
13
+ * @author tblanchard
14
+ * Copyright (c) 2007, Avalara. All rights reserved.
15
+ */
16
+
17
+
18
+ class ReconcileTaxHistoryRequest// extends TaxRequest
19
+ {
20
+ private $CompanyCode; //string
21
+ private $StartDate; //date
22
+ private $EndDate; //date
23
+ private $DocStatus; //int
24
+
25
+ private $DocType; // DocType
26
+ private $LastDocCode; // string
27
+ private $PageSize; // int
28
+
29
+ private $Reconciled=true;
30
+
31
+ public function __construct()
32
+ {
33
+ //parent::__construct();
34
+ $this->EndDate = date("Y-m-d");
35
+ $this->DocStatus =DocStatus::$Any;
36
+
37
+ }
38
+
39
+
40
+
41
+ public function getCompanyCode() { return $this->CompanyCode;}
42
+
43
+
44
+ public function getstartDate() { return $this->StartDate; }
45
+ public function getEndDate() { return $this->EndDate; }
46
+ public function getDocStatus() { return $this->DocStatus; }
47
+
48
+ /**
49
+ * Sets the client application company reference code.
50
+ *
51
+ * @param string $value
52
+ */
53
+ public function setCompanyCode($value) { $this->CompanyCode = $value; return $this; }
54
+
55
+
56
+
57
+ /**
58
+ * Set this to retrieve data FROM a specific date.
59
+ *
60
+ * @param date $value
61
+ */
62
+ public function setStartDate($value) { $this->StartDate = $value; return $this; }
63
+
64
+ /**
65
+ * Set this to retrieve data TO a specific date.
66
+ *
67
+ * @param date $value
68
+ */
69
+ public function setEndDate($value) { $this->EndDate = $value; return $this; }
70
+
71
+ /**
72
+ * Set this to retrieve data with a specific DocStatus.
73
+ *
74
+ * @param string $value
75
+ */
76
+ public function setDocStatus($value) { DocStatus::Validate($value); $this->DocStatus = $value; return $this; }
77
+
78
+
79
+ public function setDocType($value){$this->DocType=$value;} // DocType
80
+ public function getDocType(){return $this->DocType;} // DocType
81
+
82
+ public function setLastDocCode($value){$this->LastDocCode=$value;} // string
83
+ public function getLastDocCode(){return $this->LastDocCode;} // string
84
+
85
+ public function setPageSize($value){$this->PageSize=$value;} // int
86
+ public function getPageSize(){return $this->PageSize;} // int
87
+
88
+
89
  }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/ReconcileTaxHistoryResult.class.php RENAMED
@@ -1,110 +1,110 @@
1
- <?php
2
- /**
3
- * ReconcileTaxHistoryResult.class.php
4
- * @package Tax
5
- */
6
-
7
- /**
8
- * Result data returned from {@link TaxServiceSoap#reconcileTaxHistory}.
9
- *
10
- * @package Tax
11
- * @see ReconcileTaxHistoryRequest
12
- * @author tblanchard
13
- * Copyright (c) 2007, Avalara. All rights reserved.
14
- */
15
-
16
- class ReconcileTaxHistoryResult //extends SearchTaxHistoryResult
17
- {
18
- // SearchTaxHistoryResult innards - work around a bug in SoapClient
19
-
20
- public $GetTaxResults; // array of GetTaxResult
21
- private $RecordCount; // int
22
- private $LastDocCode; //string
23
-
24
-
25
-
26
- /**
27
- * Gets zero or more {@link GetTaxResult} summaries matching search criteria.
28
- * <p>
29
- * If <b>LastDocId</b> was not specified by the {@link ReconcileTaxHistoryRequest},
30
- * then this is the first set of records that need reconciliation. If <b>LastDocId</b> was specified,
31
- * the collection represents the next set of records after <b>LastDocId</b>. If the collection is
32
- * empty, then all records have been reconciled and the result's <b>LastDocId</b> will be set to the
33
- * last record of the last result set.
34
- * <br>
35
- * The GetTaxResults are returned in an Axis wrapper {@link ArrayOfGetTaxResult}, which has a
36
- * raw GetTaxResult[] array accessible via its {@link ArrayOfGetTaxResult#getGetTaxResult} method.
37
- * <pre>
38
- * <b>Example:</b>
39
- * $result = $taxSvc->reconcileTaxHistory($request);
40
- * foreach($result->getTaxResults() as $taxResult)
41
- * {
42
- * ...
43
- * }
44
- *
45
- * </pre>
46
- * @see GetTaxResult
47
- * @return array
48
- */
49
-
50
- public function getGetTaxResults()
51
- {
52
-
53
- if(isset($this->GetTaxResults->GetTaxResult))
54
- {
55
- return EnsureIsArray($this->GetTaxResults->GetTaxResult);
56
- }
57
- else
58
- {
59
- return null;
60
- }
61
- }
62
-
63
- public function setRecordCount($value){$this->RecordCount=$value;} // int
64
- public function getRecordCount(){return $this->RecordCount;} // int
65
-
66
- public function setLastDocCode($value)
67
- {
68
- $this->LastDocCode=$value;
69
- }
70
- public function getLastDocCode()
71
- {
72
- return $this->LastDocCode;
73
- }
74
-
75
-
76
-
77
- // BaseResult innards - work around a bug in SoapClient
78
-
79
- /**
80
- * @var string
81
- */
82
- private $TransactionId;
83
- /**
84
- * @var string must be one of the values defined in {@link SeverityLevel}.
85
- */
86
- private $ResultCode = 'Success';
87
- /**
88
- * @var array of Message.
89
- */
90
- private $Messages = array();
91
-
92
- /**
93
- * Accessor
94
- * @return string
95
- */
96
- public function getTransactionId() { return $this->TransactionId; }
97
- /**
98
- * Accessor
99
- * @return string
100
- */
101
- public function getResultCode() { return $this->ResultCode; }
102
- /**
103
- * Accessor
104
- * @return array
105
- */
106
- public function getMessages() { return EnsureIsArray($this->Messages->Message); }
107
-
108
-
109
-
110
  }
1
+ <?php
2
+ /**
3
+ * ReconcileTaxHistoryResult.class.php
4
+ * @package Tax
5
+ */
6
+
7
+ /**
8
+ * Result data returned from {@link TaxServiceSoap#reconcileTaxHistory}.
9
+ *
10
+ * @package Tax
11
+ * @see ReconcileTaxHistoryRequest
12
+ * @author tblanchard
13
+ * Copyright (c) 2007, Avalara. All rights reserved.
14
+ */
15
+
16
+ class ReconcileTaxHistoryResult //extends SearchTaxHistoryResult
17
+ {
18
+ // SearchTaxHistoryResult innards - work around a bug in SoapClient
19
+
20
+ public $GetTaxResults; // array of GetTaxResult
21
+ private $RecordCount; // int
22
+ private $LastDocCode; //string
23
+
24
+
25
+
26
+ /**
27
+ * Gets zero or more {@link GetTaxResult} summaries matching search criteria.
28
+ * <p>
29
+ * If <b>LastDocId</b> was not specified by the {@link ReconcileTaxHistoryRequest},
30
+ * then this is the first set of records that need reconciliation. If <b>LastDocId</b> was specified,
31
+ * the collection represents the next set of records after <b>LastDocId</b>. If the collection is
32
+ * empty, then all records have been reconciled and the result's <b>LastDocId</b> will be set to the
33
+ * last record of the last result set.
34
+ * <br>
35
+ * The GetTaxResults are returned in an Axis wrapper {@link ArrayOfGetTaxResult}, which has a
36
+ * raw GetTaxResult[] array accessible via its {@link ArrayOfGetTaxResult#getGetTaxResult} method.
37
+ * <pre>
38
+ * <b>Example:</b>
39
+ * $result = $taxSvc->reconcileTaxHistory($request);
40
+ * foreach($result->getTaxResults() as $taxResult)
41
+ * {
42
+ * ...
43
+ * }
44
+ *
45
+ * </pre>
46
+ * @see GetTaxResult
47
+ * @return array
48
+ */
49
+
50
+ public function getGetTaxResults()
51
+ {
52
+
53
+ if(isset($this->GetTaxResults->GetTaxResult))
54
+ {
55
+ return EnsureIsArray($this->GetTaxResults->GetTaxResult);
56
+ }
57
+ else
58
+ {
59
+ return null;
60
+ }
61
+ }
62
+
63
+ public function setRecordCount($value){$this->RecordCount=$value;} // int
64
+ public function getRecordCount(){return $this->RecordCount;} // int
65
+
66
+ public function setLastDocCode($value)
67
+ {
68
+ $this->LastDocCode=$value;
69
+ }
70
+ public function getLastDocCode()
71
+ {
72
+ return $this->LastDocCode;
73
+ }
74
+
75
+
76
+
77
+ // BaseResult innards - work around a bug in SoapClient
78
+
79
+ /**
80
+ * @var string
81
+ */
82
+ private $TransactionId;
83
+ /**
84
+ * @var string must be one of the values defined in {@link SeverityLevel}.
85
+ */
86
+ private $ResultCode = 'Success';
87
+ /**
88
+ * @var array of Message.
89
+ */
90
+ private $Messages = array();
91
+
92
+ /**
93
+ * Accessor
94
+ * @return string
95
+ */
96
+ public function getTransactionId() { return $this->TransactionId; }
97
+ /**
98
+ * Accessor
99
+ * @return string
100
+ */
101
+ public function getResultCode() { return $this->ResultCode; }
102
+ /**
103
+ * Accessor
104
+ * @return array
105
+ */
106
+ public function getMessages() { return EnsureIsArray($this->Messages->Message); }
107
+
108
+
109
+
110
  }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/SearchTaxHistoryResult.class.php RENAMED
@@ -1,100 +1,100 @@
1
- <?php
2
- /**
3
- * SearchTaxHistoryResult.class.php
4
- * @package Tax
5
- */
6
-
7
- /**
8
- * Result data returned from {@link TaxSvcSoap#reconcileTaxHistory}.
9
- * This class encapsulates the data and methods used by {@link ReconcileTaxHistoryResult}.
10
- *
11
- * @package Tax
12
- * @see ReconcileTaxHistoryRequest
13
- * @author tblanchard
14
- * Copyright (c) 2007, Avalara. All rights reserved.
15
- */
16
-
17
- class SearchTaxHistoryResult //extends BaseResult
18
- {
19
-
20
- private $GetTaxResults; // array of GetTaxResult
21
- private $LastDocId; // string
22
-
23
-
24
- /**
25
- * Gets zero or more {@link GetTaxResult} summaries matching search criteria.
26
- * <p>
27
- * If <b>LastDocId</b> was not specified by the {@link ReconcileTaxHistoryRequest},
28
- * then this is the first set of records that need reconciliation. If <b>LastDocId</b> was specified,
29
- * the collection represents the next set of records after <b>LastDocId</b>. If the collection is
30
- * empty, then all records have been reconciled and the result's <b>LastDocId</b> will be set to the
31
- * last record of the last result set.
32
- * <br>
33
- * The GetTaxResults are returned in an Axis wrapper {@link ArrayOfGetTaxResult}, which has a
34
- * raw GetTaxResult[] array accessible via its {@link ArrayOfGetTaxResult#getGetTaxResult} method.
35
- * <pre>
36
- * <b>Example:</b>
37
- * $result = $taxSvc->reconcileTaxHistory($request);
38
- * foreach($result->getTaxResults() as $taxResult)
39
- * {
40
- * ...
41
- * }
42
- *
43
- * </pre>
44
- * @see GetTaxResult
45
- * @return array
46
- */
47
-
48
- public function getTaxResults() { return EnsureIsArray($this->GetTaxResults->GetTaxResult); }
49
-
50
- /**
51
- * Indicates the last Document Code ({@link GetTaxResult#getDocId}) the results list.
52
- * <p>
53
- * If {@link #getGetTaxResults} is not empty, then this
54
- * <b>LastDocId</b> should be passed to the next {@link ReconcileTaxHistoryRequest}.
55
- * If {@link #getGetTaxResults} is empty, then this <b>LastDocId</b> can be
56
- * passed to {@link ReconcileTaxHistoryRequest} with the request's
57
- * {@link ReconcileTaxHistoryRequest#isReconciled} flag
58
- * set to true in order to reconcile all documents up to and including the LastDocId.
59
- * </p>
60
- *
61
- * @see ReconcileTaxHistoryResult
62
- * @return string
63
- */
64
-
65
- public function getLastDocId() { return $this->LastDocId; }
66
-
67
- // BaseResult innards - work around a bug in SoapClient
68
-
69
- /**
70
- * @var string
71
- */
72
- private $TransactionId;
73
- /**
74
- * @var string must be one of the values defined in {@link SeverityLevel}.
75
- */
76
- private $ResultCode = 'Success';
77
- /**
78
- * @var array of Message.
79
- */
80
- private $Messages = array();
81
-
82
- /**
83
- * Accessor
84
- * @return string
85
- */
86
- public function getTransactionId() { return $this->TransactionId; }
87
- /**
88
- * Accessor
89
- * @return string
90
- */
91
- public function getResultCode() { return $this->ResultCode; }
92
- /**
93
- * Accessor
94
- * @return array
95
- */
96
- public function getMessages() { return EnsureIsArray($this->Messages->Message); }
97
-
98
-
99
-
100
  }
1
+ <?php
2
+ /**
3
+ * SearchTaxHistoryResult.class.php
4
+ * @package Tax
5
+ */
6
+
7
+ /**
8
+ * Result data returned from {@link TaxSvcSoap#reconcileTaxHistory}.
9
+ * This class encapsulates the data and methods used by {@link ReconcileTaxHistoryResult}.
10
+ *
11
+ * @package Tax
12
+ * @see ReconcileTaxHistoryRequest
13
+ * @author tblanchard
14
+ * Copyright (c) 2007, Avalara. All rights reserved.
15
+ */
16
+
17
+ class SearchTaxHistoryResult //extends BaseResult
18
+ {
19
+
20
+ private $GetTaxResults; // array of GetTaxResult
21
+ private $LastDocId; // string
22
+
23
+
24
+ /**
25
+ * Gets zero or more {@link GetTaxResult} summaries matching search criteria.
26
+ * <p>
27
+ * If <b>LastDocId</b> was not specified by the {@link ReconcileTaxHistoryRequest},
28
+ * then this is the first set of records that need reconciliation. If <b>LastDocId</b> was specified,
29
+ * the collection represents the next set of records after <b>LastDocId</b>. If the collection is
30
+ * empty, then all records have been reconciled and the result's <b>LastDocId</b> will be set to the
31
+ * last record of the last result set.
32
+ * <br>
33
+ * The GetTaxResults are returned in an Axis wrapper {@link ArrayOfGetTaxResult}, which has a
34
+ * raw GetTaxResult[] array accessible via its {@link ArrayOfGetTaxResult#getGetTaxResult} method.
35
+ * <pre>
36
+ * <b>Example:</b>
37
+ * $result = $taxSvc->reconcileTaxHistory($request);
38
+ * foreach($result->getTaxResults() as $taxResult)
39
+ * {
40
+ * ...
41
+ * }
42
+ *
43
+ * </pre>
44
+ * @see GetTaxResult
45
+ * @return array
46
+ */
47
+
48
+ public function getTaxResults() { return EnsureIsArray($this->GetTaxResults->GetTaxResult); }
49
+
50
+ /**
51
+ * Indicates the last Document Code ({@link GetTaxResult#getDocId}) the results list.
52
+ * <p>
53
+ * If {@link #getGetTaxResults} is not empty, then this
54
+ * <b>LastDocId</b> should be passed to the next {@link ReconcileTaxHistoryRequest}.
55
+ * If {@link #getGetTaxResults} is empty, then this <b>LastDocId</b> can be
56
+ * passed to {@link ReconcileTaxHistoryRequest} with the request's
57
+ * {@link ReconcileTaxHistoryRequest#isReconciled} flag
58
+ * set to true in order to reconcile all documents up to and including the LastDocId.
59
+ * </p>
60
+ *
61
+ * @see ReconcileTaxHistoryResult
62
+ * @return string
63
+ */
64
+
65
+ public function getLastDocId() { return $this->LastDocId; }
66
+
67
+ // BaseResult innards - work around a bug in SoapClient
68
+
69
+ /**
70
+ * @var string
71
+ */
72
+ private $TransactionId;
73
+ /**
74
+ * @var string must be one of the values defined in {@link SeverityLevel}.
75
+ */
76
+ private $ResultCode = 'Success';
77
+ /**
78
+ * @var array of Message.
79
+ */
80
+ private $Messages = array();
81
+
82
+ /**
83
+ * Accessor
84
+ * @return string
85
+ */
86
+ public function getTransactionId() { return $this->TransactionId; }
87
+ /**
88
+ * Accessor
89
+ * @return string
90
+ */
91
+ public function getResultCode() { return $this->ResultCode; }
92
+ /**
93
+ * Accessor
94
+ * @return array
95
+ */
96
+ public function getMessages() { return EnsureIsArray($this->Messages->Message); }
97
+
98
+
99
+
100
  }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/ServiceMode.class.php RENAMED
@@ -1,46 +1,46 @@
1
- <?php
2
- /**
3
- * ServiceMode.class.php
4
- * @package Tax
5
- */
6
-
7
- /**
8
- * Specifies the ServiceMode.
9
- *
10
- * @package Tax
11
- * @see GetTaxRequest, GetTaxHistoryRequest
12
- * @author swetal
13
- * Copyright (c) 2008, Avalara. All rights reserved.
14
- * This is only supported by AvaLocal servers. It provides the ability to controls whether tax is calculated locally or remotely when using an AvaLocal server.
15
- * The default is Automatic which calculates locally unless remote is necessary for non-local addresses*/
16
-
17
- class ServiceMode extends Enum
18
- {
19
- /**
20
- * Automated handling by local and/or remote server.
21
- */
22
- public static $Automatic = "Automatic";
23
-
24
-
25
- /**
26
- * AvaLocal server only. Lines requiring remote will not be calculated.
27
- */
28
- public static $Local = "Local";
29
-
30
- /**
31
- * All lines are calculated by AvaTax remote server.
32
- */
33
- public static $Remote = "Remote";
34
-
35
- public static function Values()
36
- {
37
- return array(
38
- ServiceMode::$Automatic,
39
- ServiceMode::$Local,
40
- ServiceMode::$Remote
41
- );
42
- }
43
-
44
- // Unfortunate boiler plate due to polymorphism issues on static functions
45
- public static function Validate($value) { self::__Validate($value,self::Values(),__CLASS__); }
46
  }
1
+ <?php
2
+ /**
3
+ * ServiceMode.class.php
4
+ * @package Tax
5
+ */
6
+
7
+ /**
8
+ * Specifies the ServiceMode.
9
+ *
10
+ * @package Tax
11
+ * @see GetTaxRequest, GetTaxHistoryRequest
12
+ * @author swetal
13
+ * Copyright (c) 2008, Avalara. All rights reserved.
14
+ * This is only supported by AvaLocal servers. It provides the ability to controls whether tax is calculated locally or remotely when using an AvaLocal server.
15
+ * The default is Automatic which calculates locally unless remote is necessary for non-local addresses*/
16
+
17
+ class ServiceMode extends Enum
18
+ {
19
+ /**
20
+ * Automated handling by local and/or remote server.
21
+ */
22
+ public static $Automatic = "Automatic";
23
+
24
+
25
+ /**
26
+ * AvaLocal server only. Lines requiring remote will not be calculated.
27
+ */
28
+ public static $Local = "Local";
29
+
30
+ /**
31
+ * All lines are calculated by AvaTax remote server.
32
+ */
33
+ public static $Remote = "Remote";
34
+
35
+ public static function Values()
36
+ {
37
+ return array(
38
+ ServiceMode::$Automatic,
39
+ ServiceMode::$Local,
40
+ ServiceMode::$Remote
41
+ );
42
+ }
43
+
44
+ // Unfortunate boiler plate due to polymorphism issues on static functions
45
+ public static function Validate($value) { self::__Validate($value,self::Values(),__CLASS__); }
46
  }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/SeverityLevel.class.php RENAMED
@@ -1,38 +1,38 @@
1
- <?php
2
- /**
3
- * SeverityLevel.class.php
4
- *
5
- * @package Address
6
- */
7
-
8
- /**
9
- * Severity of the result {@link Message}.
10
- *
11
- * Defines the constants used to specify SeverityLevel in {@link Message}
12
- *
13
- * @package Address
14
- * @author tblanchard
15
- * Copyright (c) 2007, Avalara. All rights reserved.
16
- */
17
-
18
- class SeverityLevel extends Enum
19
- {
20
- public static $Success = 'Success';
21
- public static $Warning = 'Warning';
22
- public static $Error = 'Error';
23
- public static $Exception = 'Exception';
24
-
25
-
26
- public static function Values()
27
- {
28
- return array(
29
- SeverityLevel::$Success,
30
- SeverityLevel::$Warning,
31
- SeverityLevel::$Error,
32
- SeverityLevel::$Tax
33
- );
34
- }
35
-
36
- // Unfortunate boiler plate due to polymorphism issues on static functions
37
- public static function Validate($value) { self::__Validate($value,self::Values(),__CLASS__); }
38
  }
1
+ <?php
2
+ /**
3
+ * SeverityLevel.class.php
4
+ *
5
+ * @package Address
6
+ */
7
+
8
+ /**
9
+ * Severity of the result {@link Message}.
10
+ *
11
+ * Defines the constants used to specify SeverityLevel in {@link Message}
12
+ *
13
+ * @package Address
14
+ * @author tblanchard
15
+ * Copyright (c) 2007, Avalara. All rights reserved.
16
+ */
17
+
18
+ class SeverityLevel extends Enum
19
+ {
20
+ public static $Success = 'Success';
21
+ public static $Warning = 'Warning';
22
+ public static $Error = 'Error';
23
+ public static $Exception = 'Exception';
24
+
25
+
26
+ public static function Values()
27
+ {
28
+ return array(
29
+ SeverityLevel::$Success,
30
+ SeverityLevel::$Warning,
31
+ SeverityLevel::$Error,
32
+ SeverityLevel::$Tax
33
+ );
34
+ }
35
+
36
+ // Unfortunate boiler plate due to polymorphism issues on static functions
37
+ public static function Validate($value) { self::__Validate($value,self::Values(),__CLASS__); }
38
  }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/TaxDetail.class.php RENAMED
@@ -1,190 +1,190 @@
1
- <?php
2
- /**
3
- * TaxDetail.class.php
4
- * @package Tax
5
- */
6
-
7
- /**
8
- * Holds calculated tax information by jurisdiction.
9
- *
10
- * @package Tax
11
- * @see ArrayOfTaxDetail
12
- * @see TaxLine
13
- * @see GetTaxResult
14
- * @author tblanchard
15
- * Copyright (c) 2008, Avalara. All rights reserved.
16
- */
17
-
18
- class TaxDetail
19
- {
20
-
21
- private $JurisType; //JurisdictionType
22
- private $JurisCode; //string
23
- private $TaxType; //TaxType
24
-
25
- private $Base; //decimal // See Taxable
26
- private $Taxable; //decimal
27
- private $Rate; //decimal
28
-
29
- private $Tax; //decimal
30
- private $NonTaxable; //decimal
31
- private $Exemption; //decimal
32
- private $JurisName; //string
33
- private $TaxName; //string
34
- private $TaxAuthorityType; // int
35
-
36
- //@author:swetal
37
- //Added new properties to upgrade it to 5.3 interface
38
- private $Country; //string
39
- private $Region; //string
40
- private $TaxCalculated; //decimal
41
- private $TaxGroup; //string
42
-
43
- //Task# 25610
44
- private $StateAssignedNo;
45
-
46
- public function getStateAssignedNo()
47
- {
48
- return $this->StateAssignedNo;
49
- }
50
-
51
-
52
-
53
- /**
54
- * Gets the JurisdictionType.
55
- * <p>
56
- *
57
-
58
- * </p>
59
- * @see JurisdictionType
60
- @see GetTaxResults
61
- * @return JurisdictionType
62
- */
63
-
64
- public function getJurisType() {return $this->JurisType; }
65
-
66
- /**
67
- * Gets the JurisCode.
68
- * <p>
69
- * </p>
70
- * @see JurisCode
71
- @see GetTaxResults
72
- * @return string
73
- */
74
-
75
- public function getJurisCode() {return $this->JurisCode; }
76
-
77
- /**
78
- * Gets the TaxType.
79
- * <p>
80
- * </p>
81
- @see GetTaxResults
82
- * @return TaxType
83
- */
84
-
85
- public function getTaxType() {return $this->TaxType; }
86
-
87
- /**
88
- * Gets the Taxable amount.
89
- * <p>
90
- * </p>
91
- @see GetTaxResults
92
- * @return decimal
93
- */
94
-
95
- public function getTaxable() {return $this->Taxable; }
96
-
97
- /**
98
- * Gets the Taxable amount.
99
- * <p>
100
- * </p>
101
- @see GetTaxResults
102
- * @return decimal
103
- */
104
-
105
- public function getBase() {return $this->Base; }
106
-
107
-
108
- /**
109
- * Gets the Rate amount.
110
- * <p>
111
- * </p>
112
- @see GetTaxResults
113
- * @return decimal
114
- */
115
-
116
- public function getRate() {return $this->Rate; }
117
-
118
- /**
119
- * Gets the Tax amount.
120
- * <p>
121
- The tax amount, i.e. the calculated tax (base() * rate())
122
- * </p>
123
- @see GetTaxResults
124
- * @return decimal
125
- */
126
-
127
- public function getTax() {return $this->Tax; }
128
-
129
- /**
130
- * Gets the non-taxable amount..
131
- * <p>
132
- The non-taxable amount.
133
- * </p>
134
- @see GetTaxResults
135
- * @return decimal
136
- */
137
-
138
- public function getNonTaxable() {return $this->NonTaxable; }
139
-
140
-
141
- /**
142
- * Gets theExemption amount..
143
- * <p>
144
- The exempt amount for this TaxDetail.
145
- * </p>
146
- @see GetTaxResults
147
- * @return decimal
148
- */
149
-
150
- public function getExemption() {return $this->Exemption; }
151
- /**
152
- * Gets the jurisdiction name for this TaxDetail.
153
-
154
- * <p>
155
- Gets the jurisdiction name for this TaxDetail.
156
- * </p>
157
- @see GetTaxResults
158
- * @return decimal
159
- */
160
-
161
- public function getJurisName() {return $this->JurisName; }
162
- /**
163
- *
164
- * <p>
165
- Gets the taxName value.
166
- It further defines tax and jurisdiction. * </p>
167
- @see GetTaxResults
168
- * @return decimal
169
- */
170
-
171
- public function getTaxName() {return $this->TaxName; }
172
- /**
173
- * Gets the taxAuthorityType value for this TaxDetail.
174
- * <p>
175
- Gets the taxAuthorityType value for this TaxDetail.
176
- * </p>
177
- @see GetTaxResults
178
- * @return decimal
179
- */
180
-
181
- public function getTaxAuthorityType() {return $this->TaxAuthorityType; }
182
-
183
- //@author:swetal
184
- public function getCountry(){ return $this->Country;}
185
- public function getRegion(){ return $this->Region;}
186
- public function getTaxCalculated(){ return $this->TaxCalculated;}
187
- public function getTaxGroup(){ return $this->TaxGroup;}
188
-
189
-
190
  }
1
+ <?php
2
+ /**
3
+ * TaxDetail.class.php
4
+ * @package Tax
5
+ */
6
+
7
+ /**
8
+ * Holds calculated tax information by jurisdiction.
9
+ *
10
+ * @package Tax
11
+ * @see ArrayOfTaxDetail
12
+ * @see TaxLine
13
+ * @see GetTaxResult
14
+ * @author tblanchard
15
+ * Copyright (c) 2008, Avalara. All rights reserved.
16
+ */
17
+
18
+ class TaxDetail
19
+ {
20
+
21
+ private $JurisType; //JurisdictionType
22
+ private $JurisCode; //string
23
+ private $TaxType; //TaxType
24
+
25
+ private $Base; //decimal // See Taxable
26
+ private $Taxable; //decimal
27
+ private $Rate; //decimal
28
+
29
+ private $Tax; //decimal
30
+ private $NonTaxable; //decimal
31
+ private $Exemption; //decimal
32
+ private $JurisName; //string
33
+ private $TaxName; //string
34
+ private $TaxAuthorityType; // int
35
+
36
+ //@author:swetal
37
+ //Added new properties to upgrade it to 5.3 interface
38
+ private $Country; //string
39
+ private $Region; //string
40
+ private $TaxCalculated; //decimal
41
+ private $TaxGroup; //string
42
+
43
+ //Task# 25610
44
+ private $StateAssignedNo;
45
+
46
+ public function getStateAssignedNo()
47
+ {
48
+ return $this->StateAssignedNo;
49
+ }
50
+
51
+
52
+
53
+ /**
54
+ * Gets the JurisdictionType.
55
+ * <p>
56
+ *
57
+
58
+ * </p>
59
+ * @see JurisdictionType
60
+ @see GetTaxResults
61
+ * @return JurisdictionType
62
+ */
63
+
64
+ public function getJurisType() {return $this->JurisType; }
65
+
66
+ /**
67
+ * Gets the JurisCode.
68
+ * <p>
69
+ * </p>
70
+ * @see JurisCode
71
+ @see GetTaxResults
72
+ * @return string
73
+ */
74
+
75
+ public function getJurisCode() {return $this->JurisCode; }
76
+
77
+ /**
78
+ * Gets the TaxType.
79
+ * <p>
80
+ * </p>
81
+ @see GetTaxResults
82
+ * @return TaxType
83
+ */
84
+
85
+ public function getTaxType() {return $this->TaxType; }
86
+
87
+ /**
88
+ * Gets the Taxable amount.
89
+ * <p>
90
+ * </p>
91
+ @see GetTaxResults
92
+ * @return decimal
93
+ */
94
+
95
+ public function getTaxable() {return $this->Taxable; }
96
+
97
+ /**
98
+ * Gets the Taxable amount.
99
+ * <p>
100
+ * </p>
101
+ @see GetTaxResults
102
+ * @return decimal
103
+ */
104
+
105
+ public function getBase() {return $this->Base; }
106
+
107
+
108
+ /**
109
+ * Gets the Rate amount.
110
+ * <p>
111
+ * </p>
112
+ @see GetTaxResults
113
+ * @return decimal
114
+ */
115
+
116
+ public function getRate() {return $this->Rate; }
117
+
118
+ /**
119
+ * Gets the Tax amount.
120
+ * <p>
121
+ The tax amount, i.e. the calculated tax (base() * rate())
122
+ * </p>
123
+ @see GetTaxResults
124
+ * @return decimal
125
+ */
126
+
127
+ public function getTax() {return $this->Tax; }
128
+
129
+ /**
130
+ * Gets the non-taxable amount..
131
+ * <p>
132
+ The non-taxable amount.
133
+ * </p>
134
+ @see GetTaxResults
135
+ * @return decimal
136
+ */
137
+
138
+ public function getNonTaxable() {return $this->NonTaxable; }
139
+
140
+
141
+ /**
142
+ * Gets theExemption amount..
143
+ * <p>
144
+ The exempt amount for this TaxDetail.
145
+ * </p>
146
+ @see GetTaxResults
147
+ * @return decimal
148
+ */
149
+
150
+ public function getExemption() {return $this->Exemption; }
151
+ /**
152
+ * Gets the jurisdiction name for this TaxDetail.
153
+
154
+ * <p>
155
+ Gets the jurisdiction name for this TaxDetail.
156
+ * </p>
157
+ @see GetTaxResults
158
+ * @return decimal
159
+ */
160
+
161
+ public function getJurisName() {return $this->JurisName; }
162
+ /**
163
+ *
164
+ * <p>
165
+ Gets the taxName value.
166
+ It further defines tax and jurisdiction. * </p>
167
+ @see GetTaxResults
168
+ * @return decimal
169
+ */
170
+
171
+ public function getTaxName() {return $this->TaxName; }
172
+ /**
173
+ * Gets the taxAuthorityType value for this TaxDetail.
174
+ * <p>
175
+ Gets the taxAuthorityType value for this TaxDetail.
176
+ * </p>
177
+ @see GetTaxResults
178
+ * @return decimal
179
+ */
180
+
181
+ public function getTaxAuthorityType() {return $this->TaxAuthorityType; }
182
+
183
+ //@author:swetal
184
+ public function getCountry(){ return $this->Country;}
185
+ public function getRegion(){ return $this->Region;}
186
+ public function getTaxCalculated(){ return $this->TaxCalculated;}
187
+ public function getTaxGroup(){ return $this->TaxGroup;}
188
+
189
+
190
  }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/TaxLine.class.php RENAMED
@@ -1,133 +1,133 @@
1
- <?php
2
- /**
3
- * TaxLine.class.php
4
- *
5
- * @package Tax
6
- */
7
-
8
- /**
9
- * Contains Tax data; Retunded form {@link AddressServiceSoap#getTax};
10
- * Also part of the {@link GetTaxRequest}
11
- * result returned from the {@link TaxServiceSoap#getTax} tax calculation service;
12
- * @package Tax
13
- * @author tblanchard
14
- * Copyright (c) 2008, Avalara. All rights reserved.
15
- */
16
- /*
17
- */
18
-
19
- class TaxLine
20
- {
21
-
22
- private $No; //string
23
- private $TaxCode; //string
24
- private $Taxability; //boolean
25
- private $BoundaryLevel; //BoundaryLevel
26
- private $Exemption; //decimal
27
- private $Discount; //decimal
28
- private $Taxable; //decimal
29
- private $Rate; //decimal
30
- private $Tax; //decimal
31
- private $ExemptCertId; //int
32
- private $TaxDetails; //ArrayOfTaxDetail
33
-
34
- //@author:swetal
35
- //added following properties to upgrade to 5.3 interface
36
- private $TaxCalculated; //decimal
37
- private $ReportingDate; //date
38
- private $AccountingMethod;//String
39
-
40
- private $TaxIncluded; //boolean
41
-
42
- /**
43
- * Accessor
44
- * @return string
45
- */
46
- public function getNo() { return $this->No; }
47
-
48
-
49
- /**
50
- * Accessor
51
- * @return string
52
- */
53
- public function getTaxCode() { return $this->TaxCode; }
54
- /**
55
- * Accessor
56
- * @return boolean
57
- */
58
- public function getTaxability() { return $this->Taxability; }
59
- /**
60
- * Accessor
61
- * @see BoundaryLevel
62
- * @return string
63
- */
64
- public function getBoundaryLevel() { return $this->BoundaryLevel; }
65
- /**
66
- * Accessor
67
- * @return decimal
68
- */
69
- public function getExemption() { return $this->Exemption; }
70
- /**
71
- * Accessor
72
- * @return decimal
73
- */
74
- public function getDiscount() { return $this->Discount; }
75
- /**
76
- * Accessor
77
- * @return decimal
78
- */
79
- public function getTaxable() { return $this->Taxable; }
80
- /**
81
- * Accessor
82
- * @return decimal
83
- */
84
- public function getRate() { return $this->Rate; }
85
- /**
86
- * Accessor
87
- * @return string
88
- */
89
- public function getTax() { return $this->Tax; }
90
-
91
-
92
- /**
93
- * Accessor
94
- * @return decimal
95
- */
96
- public function getTaxDetails() { return EnsureIsArray($this->TaxDetails->TaxDetail); }
97
-
98
-
99
- /**
100
- * Accessor
101
- * @return int
102
- */
103
- public function getExemptCertId() { return $this->ExemptCertId; }
104
-
105
- /**
106
- * Accessor
107
- * @return decimal
108
- */
109
- public function getTaxCalculated(){ return $this->TaxCalculated; } //decimalt
110
- public function getReportingDate(){ return $this->ReportingDate;} //date
111
- public function getAccountingMethod(){ return $this->AccountingMethod;}//String
112
-
113
- /**
114
- * True if tax is included in the line.
115
- * @param boolean
116
- */
117
- public function setTaxIncluded($value)
118
- {
119
- $this->TaxIncluded=$value;
120
- }
121
-
122
- /**
123
- * True if tax is included in the line.
124
- * @return boolean
125
- */
126
- public function getTaxIncluded()
127
- {
128
- return $this->TaxIncluded;
129
- }
130
-
131
-
132
-
133
  }
1
+ <?php
2
+ /**
3
+ * TaxLine.class.php
4
+ *
5
+ * @package Tax
6
+ */
7
+
8
+ /**
9
+ * Contains Tax data; Retunded form {@link AddressServiceSoap#getTax};
10
+ * Also part of the {@link GetTaxRequest}
11
+ * result returned from the {@link TaxServiceSoap#getTax} tax calculation service;
12
+ * @package Tax
13
+ * @author tblanchard
14
+ * Copyright (c) 2008, Avalara. All rights reserved.
15
+ */
16
+ /*
17
+ */
18
+
19
+ class TaxLine
20
+ {
21
+
22
+ private $No; //string
23
+ private $TaxCode; //string
24
+ private $Taxability; //boolean
25
+ private $BoundaryLevel; //BoundaryLevel
26
+ private $Exemption; //decimal
27
+ private $Discount; //decimal
28
+ private $Taxable; //decimal
29
+ private $Rate; //decimal
30
+ private $Tax; //decimal
31
+ private $ExemptCertId; //int
32
+ private $TaxDetails; //ArrayOfTaxDetail
33
+
34
+ //@author:swetal
35
+ //added following properties to upgrade to 5.3 interface
36
+ private $TaxCalculated; //decimal
37
+ private $ReportingDate; //date
38
+ private $AccountingMethod;//String
39
+
40
+ private $TaxIncluded; //boolean
41
+
42
+ /**
43
+ * Accessor
44
+ * @return string
45
+ */
46
+ public function getNo() { return $this->No; }
47
+
48
+
49
+ /**
50
+ * Accessor
51
+ * @return string
52
+ */
53
+ public function getTaxCode() { return $this->TaxCode; }
54
+ /**
55
+ * Accessor
56
+ * @return boolean
57
+ */
58
+ public function getTaxability() { return $this->Taxability; }
59
+ /**
60
+ * Accessor
61
+ * @see BoundaryLevel
62
+ * @return string
63
+ */
64
+ public function getBoundaryLevel() { return $this->BoundaryLevel; }
65
+ /**
66
+ * Accessor
67
+ * @return decimal
68
+ */
69
+ public function getExemption() { return $this->Exemption; }
70
+ /**
71
+ * Accessor
72
+ * @return decimal
73
+ */
74
+ public function getDiscount() { return $this->Discount; }
75
+ /**
76
+ * Accessor
77
+ * @return decimal
78
+ */
79
+ public function getTaxable() { return $this->Taxable; }
80
+ /**
81
+ * Accessor
82
+ * @return decimal
83
+ */
84
+ public function getRate() { return $this->Rate; }
85
+ /**
86
+ * Accessor
87
+ * @return string
88
+ */
89
+ public function getTax() { return $this->Tax; }
90
+
91
+
92
+ /**
93
+ * Accessor
94
+ * @return decimal
95
+ */
96
+ public function getTaxDetails() { return EnsureIsArray($this->TaxDetails->TaxDetail); }
97
+
98
+
99
+ /**
100
+ * Accessor
101
+ * @return int
102
+ */
103
+ public function getExemptCertId() { return $this->ExemptCertId; }
104
+
105
+ /**
106
+ * Accessor
107
+ * @return decimal
108
+ */
109
+ public function getTaxCalculated(){ return $this->TaxCalculated; } //decimalt
110
+ public function getReportingDate(){ return $this->ReportingDate;} //date
111
+ public function getAccountingMethod(){ return $this->AccountingMethod;}//String
112
+
113
+ /**
114
+ * True if tax is included in the line.
115
+ * @param boolean
116
+ */
117
+ public function setTaxIncluded($value)
118
+ {
119
+ $this->TaxIncluded=$value;
120
+ }
121
+
122
+ /**
123
+ * True if tax is included in the line.
124
+ * @return boolean
125
+ */
126
+ public function getTaxIncluded()
127
+ {
128
+ return $this->TaxIncluded;
129
+ }
130
+
131
+
132
+
133
  }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/TaxOverride.class.php RENAMED
@@ -1,40 +1,40 @@
1
- <?php
2
-
3
- /**
4
- * TaxOverride.class.php
5
- *
6
- * @package Tax
7
- */
8
-
9
- class TaxOverride
10
- {
11
- private $TaxOverrideType; //TaxOverrideType
12
- private $TaxAmount; //decimal
13
- private $TaxDate; //date
14
- private $Reason; //string
15
-
16
-
17
-
18
- public function __construct()
19
- {
20
- $this->TaxAmount=0.0;
21
-
22
- $dateTime=new DateTime();
23
- $dateTime->setDate(1900,01,01);
24
-
25
- $this->TaxDate=$dateTime->format("Y-m-d");
26
- }
27
-
28
- public function setTaxOverrideType($value){ $this->TaxOverrideType=$value; } //TaxOverrideType
29
- public function setTaxAmount($value){$this->TaxAmount=$value;} //decimal
30
- public function setTaxDate($value){$this->TaxDate=$value;} //date
31
- public function setReason($value){$this->Reason=$value;} //string
32
-
33
-
34
- public function getTaxOverrideType(){ return $this->TaxOverrideType; } //TaxOverrideType
35
- public function getTaxAmount(){return $this->TaxAmount;} //decimal
36
- public function getTaxDate(){return $this->TaxDate;} //date
37
- public function getReason(){return $this->Reason;} //string
38
-
39
-
40
  }
1
+ <?php
2
+
3
+ /**
4
+ * TaxOverride.class.php
5
+ *
6
+ * @package Tax
7
+ */
8
+
9
+ class TaxOverride
10
+ {
11
+ private $TaxOverrideType; //TaxOverrideType
12
+ private $TaxAmount; //decimal
13
+ private $TaxDate; //date
14
+ private $Reason; //string
15
+
16
+
17
+
18
+ public function __construct()
19
+ {
20
+ $this->TaxAmount=0.0;
21
+
22
+ $dateTime=new DateTime();
23
+ $dateTime->setDate(1900,01,01);
24
+
25
+ $this->TaxDate=$dateTime->format("Y-m-d");
26
+ }
27
+
28
+ public function setTaxOverrideType($value){ $this->TaxOverrideType=$value; } //TaxOverrideType
29
+ public function setTaxAmount($value){$this->TaxAmount=$value;} //decimal
30
+ public function setTaxDate($value){$this->TaxDate=$value;} //date
31
+ public function setReason($value){$this->Reason=$value;} //string
32
+
33
+
34
+ public function getTaxOverrideType(){ return $this->TaxOverrideType; } //TaxOverrideType
35
+ public function getTaxAmount(){return $this->TaxAmount;} //decimal
36
+ public function getTaxDate(){return $this->TaxDate;} //date
37
+ public function getReason(){return $this->Reason;} //string
38
+
39
+
40
  }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/TaxOverrideType.class.php RENAMED
@@ -1,14 +1,14 @@
1
- <?php
2
- /**
3
- * TaxOverrideType.class.php
4
- *
5
- * @package Tax
6
- */
7
- class TaxOverrideType
8
- {
9
- public static $None = "None";
10
- public static $TaxAmount = "TaxAmount";
11
- public static $Exemption = "Exemption";
12
- public static $TaxDate = "TaxDate";
13
-
14
  }
1
+ <?php
2
+ /**
3
+ * TaxOverrideType.class.php
4
+ *
5
+ * @package Tax
6
+ */
7
+ class TaxOverrideType
8
+ {
9
+ public static $None = "None";
10
+ public static $TaxAmount = "TaxAmount";
11
+ public static $Exemption = "Exemption";
12
+ public static $TaxDate = "TaxDate";
13
+
14
  }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/TaxRequest.class.php RENAMED
@@ -1,161 +1,161 @@
1
- <?php
2
- /**
3
- * TaxRequest.class.php
4
- * @package Tax
5
- */
6
-
7
- /**
8
- * Abstract base class for all CancelTax,GetTaxHistory,PostTax, Service Requests.
9
- * Tax Requests require either a DocId, or CompanyCode, DocType, and DocCode.
10
- *
11
- * @see TaxServiceSoap
12
- * @package Tax
13
- * @author tblanchard
14
- * Copyright (c) 2007, Avalara. All rights reserved.
15
- */
16
-
17
- class TaxRequest
18
- {
19
-
20
- /**
21
- * @access public
22
- * @var string
23
- */
24
- protected $CompanyCode;
25
- /**
26
- * Must be one of SalesOrder or SalesInvoice or PurchaseOrder or PurchaseInvoice or ReturnOrder or ReturnInvoice
27
- * Constants defined in DocumentType.
28
- *
29
- * @see DocumentType
30
- * @access public
31
- * @var string
32
- */
33
- protected $DocType;
34
- /**
35
- * Invoice Number
36
- *
37
- * @access public
38
- * @var string
39
- */
40
- protected $DocCode;
41
-
42
- /**
43
- * A unique document ID.
44
- * <p>
45
- * This is a unique AvaTax identifier for this document. If known, the
46
- * <b>CompanyCode</b>, <b>DocCode</b>, and <b>DocType</b> are not needed.
47
- *
48
- * @access public
49
- * @var string
50
- */
51
- //protected $DocId;
52
-
53
- /**
54
- * Sets the client application company reference code.
55
- * <br>If docId is specified, this is not needed.
56
- *
57
- * @param string
58
- */
59
-
60
- protected $HashCode;
61
-
62
- public function setCompanyCode($value) { $this->CompanyCode = $value; return $this; }
63
-
64
- /**
65
- * The original document's type, such as Sales Invoice or Purchase Invoice.
66
- *
67
- * @var string
68
- * @see DocumentType
69
- */
70
- public function setDocType($value) { DocumentType::Validate($value); $this->DocType=$value; return $this; }
71
-
72
- /**
73
- * Sets the Document Code, that is the internal reference code used by the client application.
74
- * <br>If docId is specified, this is not needed.
75
- *
76
- * @var string
77
- */
78
- public function setDocCode($value) { $this->DocCode = $value; return $this; }
79
-
80
- /**
81
- * A unique document ID.
82
- * <p>
83
- * This is a unique AvaTax identifier for this document. If known, the
84
- * <b>CompanyCode</b>, <b>DocCode</b>, and <b>DocType</b> are not needed.
85
- *
86
- * @var string
87
- * @see GetTaxResult#DocId
88
- */
89
-
90
- //public function setDocId($value) { $this->DocId = $value; return $this; }
91
-
92
- /**
93
- * Sets the hashCode value for this GetTaxRequest.
94
- * <p>
95
- * This should be computed by an SDK developer using some standard algorithm out of the content of the object. This value gets stored in the system and can be retrieved for the cross checking [Internal Reconciliation purpose].
96
- * See sample code for more details
97
- * </p>
98
- * @var int
99
- */
100
-
101
- public function setHashCode($value) { $this->HashCode = $value; return $this; }
102
- // Accessors
103
- /**
104
- * Gets the client application company reference code.
105
- *
106
- * @return string
107
- */
108
-
109
- public function getCompanyCode() { return $this->CompanyCode; }
110
-
111
-
112
- /**
113
- * Gets the hashCode value for this GetTaxRequest.
114
- * <p>
115
- * This should be computed by an SDK developer using some standard algorithm out of the content of the object. This value gets stored in the system and can be retrieved for the cross checking [Internal Reconciliation purpose].
116
- * See sample code for more details
117
- * </p>
118
- * @return int
119
- */
120
-
121
- public function getHashCode() { return $this->HashCode; }
122
-
123
- /**
124
- * The original document's type, such as Sales Invoice or Purchase Invoice.
125
- *
126
- * @return string
127
- * @see DocumentType
128
- */
129
-
130
-
131
- public function getDocType() { return $this->DocType; }
132
-
133
- /**
134
- * Gets the Document Code, that is the internal reference code used by the client application.
135
- * <br>If docId is specified, this is not needed.
136
- *
137
- * @return string
138
- */
139
-
140
- public function getDocCode() { return $this->DocCode; }
141
-
142
- /**
143
- * A unique document ID.
144
- * <p>
145
- * This is a unique AvaTax identifier for this document. If known, the
146
- * <b>CompanyCode</b>, <b>DocCode</b>, and <b>DocType</b> are not needed.
147
- *
148
- * @return string
149
- * @see GetTaxResult#DocId
150
- */
151
-
152
- //public function getDocId() { return $this->DocId; }
153
-
154
- public function __construct()
155
- {
156
- $this->DocType = DocumentType::$SalesOrder; // this is right Document
157
- $this->HashCode= 0;
158
-
159
- }
160
-
161
  }
1
+ <?php
2
+ /**
3
+ * TaxRequest.class.php
4
+ * @package Tax
5
+ */
6
+
7
+ /**
8
+ * Abstract base class for all CancelTax,GetTaxHistory,PostTax, Service Requests.
9
+ * Tax Requests require either a DocId, or CompanyCode, DocType, and DocCode.
10
+ *
11
+ * @see TaxServiceSoap
12
+ * @package Tax
13
+ * @author tblanchard
14
+ * Copyright (c) 2007, Avalara. All rights reserved.
15
+ */
16
+
17
+ class TaxRequest
18
+ {
19
+
20
+ /**
21
+ * @access public
22
+ * @var string
23
+ */
24
+ protected $CompanyCode;
25
+ /**
26
+ * Must be one of SalesOrder or SalesInvoice or PurchaseOrder or PurchaseInvoice or ReturnOrder or ReturnInvoice
27
+ * Constants defined in DocumentType.
28
+ *
29
+ * @see DocumentType
30
+ * @access public
31
+ * @var string
32
+ */
33
+ protected $DocType;
34
+ /**
35
+ * Invoice Number
36
+ *
37
+ * @access public
38
+ * @var string
39
+ */
40
+ protected $DocCode;
41
+
42
+ /**
43
+ * A unique document ID.
44
+ * <p>
45
+ * This is a unique AvaTax identifier for this document. If known, the
46
+ * <b>CompanyCode</b>, <b>DocCode</b>, and <b>DocType</b> are not needed.
47
+ *
48
+ * @access public
49
+ * @var string
50
+ */
51
+ //protected $DocId;
52
+
53
+ /**
54
+ * Sets the client application company reference code.
55
+ * <br>If docId is specified, this is not needed.
56
+ *
57
+ * @param string
58
+ */
59
+
60
+ protected $HashCode;
61
+
62
+ public function setCompanyCode($value) { $this->CompanyCode = $value; return $this; }
63
+
64
+ /**
65
+ * The original document's type, such as Sales Invoice or Purchase Invoice.
66
+ *
67
+ * @var string
68
+ * @see DocumentType
69
+ */
70
+ public function setDocType($value) { DocumentType::Validate($value); $this->DocType=$value; return $this; }
71
+
72
+ /**
73
+ * Sets the Document Code, that is the internal reference code used by the client application.
74
+ * <br>If docId is specified, this is not needed.
75
+ *
76
+ * @var string
77
+ */
78
+ public function setDocCode($value) { $this->DocCode = $value; return $this; }
79
+
80
+ /**
81
+ * A unique document ID.
82
+ * <p>
83
+ * This is a unique AvaTax identifier for this document. If known, the
84
+ * <b>CompanyCode</b>, <b>DocCode</b>, and <b>DocType</b> are not needed.
85
+ *
86
+ * @var string
87
+ * @see GetTaxResult#DocId
88
+ */
89
+
90
+ //public function setDocId($value) { $this->DocId = $value; return $this; }
91
+
92
+ /**
93
+ * Sets the hashCode value for this GetTaxRequest.
94
+ * <p>
95
+ * This should be computed by an SDK developer using some standard algorithm out of the content of the object. This value gets stored in the system and can be retrieved for the cross checking [Internal Reconciliation purpose].
96
+ * See sample code for more details
97
+ * </p>
98
+ * @var int
99
+ */
100
+
101
+ public function setHashCode($value) { $this->HashCode = $value; return $this; }
102
+ // Accessors
103
+ /**
104
+ * Gets the client application company reference code.
105
+ *
106
+ * @return string
107
+ */
108
+
109
+ public function getCompanyCode() { return $this->CompanyCode; }
110
+
111
+
112
+ /**
113
+ * Gets the hashCode value for this GetTaxRequest.
114
+ * <p>
115
+ * This should be computed by an SDK developer using some standard algorithm out of the content of the object. This value gets stored in the system and can be retrieved for the cross checking [Internal Reconciliation purpose].
116
+ * See sample code for more details
117
+ * </p>
118
+ * @return int
119
+ */
120
+
121
+ public function getHashCode() { return $this->HashCode; }
122
+
123
+ /**
124
+ * The original document's type, such as Sales Invoice or Purchase Invoice.
125
+ *
126
+ * @return string
127
+ * @see DocumentType
128
+ */
129
+
130
+
131
+ public function getDocType() { return $this->DocType; }
132
+
133
+ /**
134
+ * Gets the Document Code, that is the internal reference code used by the client application.
135
+ * <br>If docId is specified, this is not needed.
136
+ *
137
+ * @return string
138
+ */
139
+
140
+ public function getDocCode() { return $this->DocCode; }
141
+
142
+ /**
143
+ * A unique document ID.
144
+ * <p>
145
+ * This is a unique AvaTax identifier for this document. If known, the
146
+ * <b>CompanyCode</b>, <b>DocCode</b>, and <b>DocType</b> are not needed.
147
+ *
148
+ * @return string
149
+ * @see GetTaxResult#DocId
150
+ */
151
+
152
+ //public function getDocId() { return $this->DocId; }
153
+
154
+ public function __construct()
155
+ {
156
+ $this->DocType = DocumentType::$SalesOrder; // this is right Document
157
+ $this->HashCode= 0;
158
+
159
+ }
160
+
161
  }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/TaxServiceSoap.class.php RENAMED
@@ -1,306 +1,306 @@
1
- <?php
2
-
3
- /**
4
- * TaxServiceSoap.class.php
5
- *
6
- * This is a proxy for the Avalara Tax service. It contains methods that perform remote calls
7
- * to the Avalara Tax Service.
8
- *
9
- * @package Tax
10
- */
11
-
12
- /**
13
- * Proxy interface for the Avalara Tax Web Service.
14
- *
15
- * TaxServiceSoap reads its configuration values from static variables defined
16
- * in ATConfig.class.php. This file must be properly configured with your security credentials.
17
- *
18
- * <p>
19
- * <b>Example:</b>
20
- * <pre>
21
- * $taxService = new TaxServiceSoap();
22
- * $result = $taxService->ping();
23
- * </pre>
24
- *
25
- * @package Tax
26
- * @author tblanchard
27
- * Copyright (c) 2007, Avalara. All rights reserved.
28
- */
29
-
30
-
31
- class TaxServiceSoap extends AvalaraSoapClient
32
- {
33
- static $servicePath = '/Tax/TaxSvc.asmx';
34
- static protected $classmap = array(
35
- 'BaseAddress' => 'Address',
36
- 'ValidAddress' => 'ValidAddress',
37
- 'Message' => 'Message',
38
- 'ValidateRequest' => 'ValidateRequest',
39
- 'IsAuthorizedResult' => 'IsAuthorizedResult',
40
- 'PingResult' => 'PingResult',
41
- 'ValidateResult' => 'ValidateResult',
42
- 'Line'=>'Line',
43
- 'AdjustTaxRequest'=>'AdjustTaxRequest',
44
- 'AdjustTaxResult'=>'AdjustTaxResult',
45
- 'CancelTaxRequest'=>'CancelTaxRequest',
46
- 'CancelTaxResult'=>'CancelTaxResult',
47
- 'CommitTaxRequest'=>'CommitTaxRequest',
48
- 'CommitTaxResult'=>'CommitTaxResult',
49
- 'GetTaxRequest'=>'GetTaxRequest',
50
- 'GetTaxResult'=>'GetTaxResult',
51
- 'GetTaxHistoryRequest'=>'GetTaxHistoryRequest',
52
- 'GetTaxHistoryResult'=>'GetTaxHistoryResult',
53
- 'PostTaxRequest'=>'PostTaxRequest',
54
- 'PostTaxResult'=>'PostTaxResult',
55
- 'ReconcileTaxHistoryRequest'=>'ReconcileTaxHistoryRequest',
56
- 'ReconcileTaxHistoryResult'=>'ReconcileTaxHistoryResult',
57
- 'TaxLine'=>'TaxLine',
58
- 'TaxDetail' => 'TaxDetail',
59
- 'ApplyPaymentRequest'=>'ApplyPaymentRequest',
60
- 'ApplyPaymentResult'=>'ApplyPaymentResult',
61
- 'BaseResult'=>'BaseResult',
62
- 'TaxOverride'=>'TaxOverride'
63
- );
64
-
65
- public function __construct($configurationName = 'Default')
66
- {
67
- $config = new ATConfig($configurationName);
68
-
69
- $this->client = new DynamicSoapClient (
70
- $config->taxWSDL,
71
- array
72
- (
73
- 'location' => $config->url.$config->taxService,
74
- 'trace' => $config->trace,
75
- 'classmap' => TaxServiceSoap::$classmap
76
- ),
77
- $config
78
- );
79
- }
80
-
81
-
82
-
83
- /**
84
- * Calculates taxes on a document such as a sales order, sales invoice, purchase order, purchase invoice, or credit memo.
85
- * <br>The tax data is saved Sales Invoice and Purchase Invoice document types {@link GetTaxRequest#getDocType}.
86
- *
87
- * @param getTaxRequest -- Tax calculation request
88
- *
89
- * @return GetTaxResult
90
- * @throws SoapFault
91
- */
92
- public function getTax(&$getTaxRequest)
93
- {
94
- $getTaxRequest->prepare();
95
- return $this->client->GetTax(array('GetTaxRequest' => $getTaxRequest))->GetTaxResult;
96
- }
97
-
98
- /**
99
- * Retrieves a previously calculated tax document.
100
- * <p>
101
- * This is only available for saved tax documents (Sales Invoices, Purchase Invoices).
102
- * </p>
103
- * <p>
104
- * A document can be indicated solely by the {@link PostTaxRequest#getDocId} if it is known.
105
- * Otherwise the request must specify all of {@link PostTaxRequest#getCompanyCode}, see {@link PostTaxRequest#getDocCode}
106
- * and {@link PostTaxRequest#getDocType} in order to uniquely identify the document.
107
- * </p>
108
- *
109
- * @param getTaxHistoryRequest a {@link GetTaxHistoryRequest} object indicating the document for which history should be retrieved.
110
- * @return a {@link GetTaxHistoryResult} object
111
- * @throws SoapFault
112
- */
113
- /*public com.avalara.avatax.services.tax.GetTaxHistoryResult getTaxHistory(com.avalara.avatax.services.tax.GetTaxHistoryRequest getTaxHistoryRequest) throws SoapFault;
114
- */
115
- public function getTaxHistory(&$getTaxHistoryRequest)
116
- {
117
- $result = $this->client->GetTaxHistory(array('GetTaxHistoryRequest'=>$getTaxHistoryRequest))->GetTaxHistoryResult;
118
- $result->getGetTaxRequest()->postFetch();
119
- return $result;
120
- }
121
-
122
- /**
123
- * Posts a previously calculated tax
124
- * <p>
125
- * This is only available for saved tax documents (Sales Invoices, Purchase Invoices).
126
- * </p>
127
- * <p>
128
- * A document can be indicated solely by the {@link PostTaxRequest#getDocId} if it is known.
129
- * Otherwise the request must specify all of {@link PostTaxRequest#getCompanyCode}, {@link PostTaxRequest#getDocCode}, and
130
- * {@link PostTaxRequest#getDocType} in order to uniquely identify the document.
131
- * </p>
132
- *
133
- * @param postTaxRequest a {@link PostTaxRequest} object indicating the document that should be posted.
134
- * @return a {@link PostTaxResult} object
135
- * @throws SoapFault
136
- */
137
-
138
- /*public com.avalara.avatax.services.tax.PostTaxResult postTax(com.avalara.avatax.services.tax.PostTaxRequest postTaxRequest) throws SoapFault;
139
- */
140
- public function postTax(&$postTaxRequest)
141
- {
142
- return $this->client->PostTax(array('PostTaxRequest'=>$postTaxRequest))->PostTaxResult;
143
- }
144
-
145
- /**
146
- * Commits a previously posted tax.
147
- * <p>
148
- * This is only available for posted tax documents (Sales Invoices, Purchase Invoices). Committed documents cannot
149
- * be changed or deleted.
150
- * </p>
151
- * <p>
152
- * A document can be indicated solely by the {@link CommitTaxRequest#getDocId} if it is known. Otherwise the
153
- * request must specify all of {@link CommitTaxRequest#getCompanyCode}, {@link CommitTaxRequest#getDocCode}, and
154
- * {@link CommitTaxRequest#getDocType} in order to uniquely identify the document.
155
- * </p>
156
- *
157
- * @param commitTaxRequest a {@link CommitTaxRequest} object indicating the document that should be committed.
158
- * @return a {@link CommitTaxResult} object
159
- * @throws SoapFault
160
- */
161
-
162
- /*public com.avalara.avatax.services.tax.CommitTaxResult commitTax(com.avalara.avatax.services.tax.CommitTaxRequest commitTaxRequest) throws SoapFault;
163
- */
164
- public function commitTax(&$commitTaxRequest)
165
- {
166
- return $this->client->CommitTax(array('CommitTaxRequest'=>$commitTaxRequest))->CommitTaxResult;
167
- }
168
- /**
169
- * Cancels a previously calculated tax; This is for use as a
170
- * compensating action when posting on the client fails to complete.
171
- * <p>
172
- * This is only available for saved tax document types (Sales Invoices, Purchase Invoices). A document that is saved
173
- * but not posted will be deleted if canceled. A document that has been posted will revert to a saved state if canceled
174
- * (in this case <b>CancelTax</b> should be called with a {@link CancelTaxRequest#getCancelCode} of
175
- * <i>PostFailed</i>). A document that has been committed cannot be reverted to a posted state or deleted. In the case
176
- * that a document on the client side no longer exists, a committed document can be virtually removed by calling
177
- * <b>CancelTax</b> with a <b>CancelCode</b> of <i>DocDeleted</i>. The record will be retained in history but removed
178
- * from all reports.
179
- * </p>
180
- * <p>
181
- * A document can be indicated solely by the {@link CancelTaxRequest#getDocId} if it is known. Otherwise the request
182
- * must specify all of {@link CancelTaxRequest#getCompanyCode}, {@link CancelTaxRequest#getDocCode}, and
183
- * {@link CancelTaxRequest#getDocType} in order to uniquely identify the document.
184
- *
185
- * @param cancelTaxRequest a {@link CancelTaxRequest} object indicating the document that should be canceled.
186
- * @return a {@link CancelTaxResult} object
187
- * @throws SoapFault
188
- */
189
- /* public com.avalara.avatax.services.tax.CancelTaxResult cancelTax(com.avalara.avatax.services.tax.CancelTaxRequest cancelTaxRequest) throws SoapFault;
190
- */
191
- public function cancelTax(&$cancelTaxRequest)
192
- {
193
- return $this->client->CancelTax(array('CancelTaxRequest'=>$cancelTaxRequest))->CancelTaxResult;
194
- }
195
-
196
- /**
197
- * Reconciles tax history to ensure the client data matches the
198
- * AvaTax history.
199
- * <p>The Reconcile operation allows reconciliation of the AvaTax history with the client accounting system.
200
- * It must be used periodically according to your service contract.
201
- * </p>
202
- * <p>
203
- * Because there may be a large number of documents to reconcile, it is designed to be called repetitively
204
- * until all documents have been reconciled. It should be called until no more documents are returned.
205
- * Each subsequent call should pass the previous results {@link ReconcileTaxHistoryRequest#getLastDocId}.
206
- * </p>
207
- * <p>
208
- * When all results have been reconciled, Reconcile should be called once more with
209
- * {@link ReconcileTaxHistoryRequest#getLastDocId}
210
- * equal to the last document code processed and {@link ReconcileTaxHistoryRequest#isReconciled} set to true to indicate
211
- * that all items have been reconciled. If desired, this may be done incrementally with each result set. Just send
212
- * Reconciled as true when requesting the next result set and the prior results will be marked as reconciled.
213
- * </p>
214
- * <p>
215
- * The {@link #postTax}, {@link #commitTax}, and {@link #cancelTax} operations can be used to correct any differences.
216
- * {@link #getTax} should be called if any committed documents are out of balance
217
- * ({@link GetTaxResult#getTotalAmount} or {@link GetTaxResult#getTotalTax}
218
- * don't match the accounting system records). This is to make sure the correct tax is reported.
219
- * </p>
220
- *
221
- * @param reconcileTaxHistoryRequest a Reconciliation request
222
- * @return A collection of documents that have been posted or committed since the last reconciliation.
223
- * @throws SoapFault
224
- */
225
- /*public com.avalara.avatax.services.tax.ReconcileTaxHistoryResult reconcileTaxHistory(com.avalara.avatax.services.tax.ReconcileTaxHistoryRequest reconcileTaxHistoryRequest) throws SoapFault;
226
- */
227
- public function reconcileTaxHistory(&$reconcileTaxHistoryRequest)
228
- {
229
- return $this->client->ReconcileTaxHistory(array('ReconcileTaxHistoryRequest'=>$reconcileTaxHistoryRequest))->ReconcileTaxHistoryResult;
230
- }
231
-
232
- /**
233
- * Adjusts a previously calculated tax.
234
- * <p>
235
- * This is only available for unlocked tax documents (Sales Invoices, Purchase Invoices). * </p>
236
- * <p>
237
- * </p>
238
- *
239
- * @param adjustTaxRequest a {@link AdjustTaxRequest} object indicating the document that should be edited.
240
- * @return a {@link AdjustTaxResult} object
241
- * @throws SoapFault
242
- */
243
-
244
- /*public com.avalara.avatax.services.tax.CommitTaxResult commitTax(com.avalara.avatax.services.tax.CommitTaxRequest commitTaxRequest) throws SoapFault;
245
- */
246
- public function adjustTax(&$adjustTaxRequest)
247
- {
248
- $adjustTaxRequest->getGetTaxRequest()->prepare();
249
- return $this->client->AdjustTax(array('AdjustTaxRequest'=>$adjustTaxRequest))->AdjustTaxResult;
250
- }
251
- /**
252
- * Checks authentication of and authorization to one or more
253
- * operations on the service.
254
- *
255
- * This operation allows pre-authorization checking of any
256
- * or all operations. It will return a comma delimited set of
257
- * operation names which will be all or a subset of the requested
258
- * operation names. For security, it will never return operation
259
- * names other than those requested (no phishing allowed).
260
- *
261
- * <b>Example:</b><br>
262
- * <code> isAuthorized("GetTax,PostTax")</code>
263
- *
264
- * @param string $operations a comma-delimited list of operation names
265
- *
266
- * @return IsAuthorizedResult
267
- * @throws SoapFault
268
- */
269
-
270
-
271
- public function isAuthorized($operations)
272
- {
273
- return $this->client->IsAuthorized(array('Operations' => $operations))->IsAuthorizedResult;
274
- }
275
-
276
- /**
277
- * Verifies connectivity to the web service and returns version
278
- * information about the service.
279
- *
280
- * <b>NOTE:</b>This replaces TestConnection and is available on
281
- * every service.
282
- *
283
- * @param string $message for future use
284
- * @return PingResult
285
- * @throws SoapFault
286
- */
287
-
288
- public function ping($message = '')
289
- {
290
- return $this->client->Ping(array('Message' => $message))->PingResult;
291
- }
292
-
293
- /**
294
- * This method is used to apply a payment to a document for cash basis accounting. Applies a payment date to an existing invoice
295
- * It sets the document PaymentDate and changes the reporting date from the DocDate default. It may be called before or after a document is committed. It should not be used for accrual basis accounting
296
- *
297
- * @param ApplyPaymentRequest $applyPaymentRequest
298
- * @return ApplyPaymentResult
299
- */
300
-
301
- public function applyPayment(&$applyPaymentRequest)
302
- {
303
- return $this->client->ApplyPayment(array('ApplyPaymentRequest' => $applyPaymentRequest))->ApplyPaymentResult;
304
- }
305
-
306
- }
1
+ <?php
2
+
3
+ /**
4
+ * TaxServiceSoap.class.php
5
+ *
6
+ * This is a proxy for the Avalara Tax service. It contains methods that perform remote calls
7
+ * to the Avalara Tax Service.
8
+ *
9
+ * @package Tax
10
+ */
11
+
12
+ /**
13
+ * Proxy interface for the Avalara Tax Web Service.
14
+ *
15
+ * TaxServiceSoap reads its configuration values from static variables defined
16
+ * in ATConfig.class.php. This file must be properly configured with your security credentials.
17
+ *
18
+ * <p>
19
+ * <b>Example:</b>
20
+ * <pre>
21
+ * $taxService = new TaxServiceSoap();
22
+ * $result = $taxService->ping();
23
+ * </pre>
24
+ *
25
+ * @package Tax
26
+ * @author tblanchard
27
+ * Copyright (c) 2007, Avalara. All rights reserved.
28
+ */
29
+
30
+
31
+ class TaxServiceSoap extends AvalaraSoapClient
32
+ {
33
+ static $servicePath = '/Tax/TaxSvc.asmx';
34
+ static protected $classmap = array(
35
+ 'BaseAddress' => 'Address',
36
+ 'ValidAddress' => 'ValidAddress',
37
+ 'Message' => 'Message',
38
+ 'ValidateRequest' => 'ValidateRequest',
39
+ 'IsAuthorizedResult' => 'IsAuthorizedResult',
40
+ 'PingResult' => 'PingResult',
41
+ 'ValidateResult' => 'ValidateResult',
42
+ 'Line'=>'Line',
43
+ 'AdjustTaxRequest'=>'AdjustTaxRequest',
44
+ 'AdjustTaxResult'=>'AdjustTaxResult',
45
+ 'CancelTaxRequest'=>'CancelTaxRequest',
46
+ 'CancelTaxResult'=>'CancelTaxResult',
47
+ 'CommitTaxRequest'=>'CommitTaxRequest',
48
+ 'CommitTaxResult'=>'CommitTaxResult',
49
+ 'GetTaxRequest'=>'GetTaxRequest',
50
+ 'GetTaxResult'=>'GetTaxResult',
51
+ 'GetTaxHistoryRequest'=>'GetTaxHistoryRequest',
52
+ 'GetTaxHistoryResult'=>'GetTaxHistoryResult',
53
+ 'PostTaxRequest'=>'PostTaxRequest',
54
+ 'PostTaxResult'=>'PostTaxResult',
55
+ 'ReconcileTaxHistoryRequest'=>'ReconcileTaxHistoryRequest',
56
+ 'ReconcileTaxHistoryResult'=>'ReconcileTaxHistoryResult',
57
+ 'TaxLine'=>'TaxLine',
58
+ 'TaxDetail' => 'TaxDetail',
59
+ 'ApplyPaymentRequest'=>'ApplyPaymentRequest',
60
+ 'ApplyPaymentResult'=>'ApplyPaymentResult',
61
+ 'BaseResult'=>'BaseResult',
62
+ 'TaxOverride'=>'TaxOverride'
63
+ );
64
+
65
+ public function __construct($configurationName = 'Default')
66
+ {
67
+ $config = new ATConfig($configurationName);
68
+
69
+ $this->client = new DynamicSoapClient (
70
+ $config->taxWSDL,
71
+ array
72
+ (
73
+ 'location' => $config->url.$config->taxService,
74
+ 'trace' => $config->trace,
75
+ 'classmap' => TaxServiceSoap::$classmap
76
+ ),
77
+ $config
78
+ );
79
+ }
80
+
81
+
82
+
83
+ /**
84
+ * Calculates taxes on a document such as a sales order, sales invoice, purchase order, purchase invoice, or credit memo.
85
+ * <br>The tax data is saved Sales Invoice and Purchase Invoice document types {@link GetTaxRequest#getDocType}.
86
+ *
87
+ * @param getTaxRequest -- Tax calculation request
88
+ *
89
+ * @return GetTaxResult
90
+ * @throws SoapFault
91
+ */
92
+ public function getTax(&$getTaxRequest)
93
+ {
94
+ $getTaxRequest->prepare();
95
+ return $this->client->GetTax(array('GetTaxRequest' => $getTaxRequest))->GetTaxResult;
96
+ }
97
+
98
+ /**
99
+ * Retrieves a previously calculated tax document.
100
+ * <p>
101
+ * This is only available for saved tax documents (Sales Invoices, Purchase Invoices).
102
+ * </p>
103
+ * <p>
104
+ * A document can be indicated solely by the {@link PostTaxRequest#getDocId} if it is known.
105
+ * Otherwise the request must specify all of {@link PostTaxRequest#getCompanyCode}, see {@link PostTaxRequest#getDocCode}
106
+ * and {@link PostTaxRequest#getDocType} in order to uniquely identify the document.
107
+ * </p>
108
+ *
109
+ * @param getTaxHistoryRequest a {@link GetTaxHistoryRequest} object indicating the document for which history should be retrieved.
110
+ * @return a {@link GetTaxHistoryResult} object
111
+ * @throws SoapFault
112
+ */
113
+ /*public com.avalara.avatax.services.tax.GetTaxHistoryResult getTaxHistory(com.avalara.avatax.services.tax.GetTaxHistoryRequest getTaxHistoryRequest) throws SoapFault;
114
+ */
115
+ public function getTaxHistory(&$getTaxHistoryRequest)
116
+ {
117
+ $result = $this->client->GetTaxHistory(array('GetTaxHistoryRequest'=>$getTaxHistoryRequest))->GetTaxHistoryResult;
118
+ $result->getGetTaxRequest()->postFetch();
119
+ return $result;
120
+ }
121
+
122
+ /**
123
+ * Posts a previously calculated tax
124
+ * <p>
125
+ * This is only available for saved tax documents (Sales Invoices, Purchase Invoices).
126
+ * </p>
127
+ * <p>
128
+ * A document can be indicated solely by the {@link PostTaxRequest#getDocId} if it is known.
129
+ * Otherwise the request must specify all of {@link PostTaxRequest#getCompanyCode}, {@link PostTaxRequest#getDocCode}, and
130
+ * {@link PostTaxRequest#getDocType} in order to uniquely identify the document.
131
+ * </p>
132
+ *
133
+ * @param postTaxRequest a {@link PostTaxRequest} object indicating the document that should be posted.
134
+ * @return a {@link PostTaxResult} object
135
+ * @throws SoapFault
136
+ */
137
+
138
+ /*public com.avalara.avatax.services.tax.PostTaxResult postTax(com.avalara.avatax.services.tax.PostTaxRequest postTaxRequest) throws SoapFault;
139
+ */
140
+ public function postTax(&$postTaxRequest)
141
+ {
142
+ return $this->client->PostTax(array('PostTaxRequest'=>$postTaxRequest))->PostTaxResult;
143
+ }
144
+
145
+ /**
146
+ * Commits a previously posted tax.
147
+ * <p>
148
+ * This is only available for posted tax documents (Sales Invoices, Purchase Invoices). Committed documents cannot
149
+ * be changed or deleted.
150
+ * </p>
151
+ * <p>
152
+ * A document can be indicated solely by the {@link CommitTaxRequest#getDocId} if it is known. Otherwise the
153
+ * request must specify all of {@link CommitTaxRequest#getCompanyCode}, {@link CommitTaxRequest#getDocCode}, and
154
+ * {@link CommitTaxRequest#getDocType} in order to uniquely identify the document.
155
+ * </p>
156
+ *
157
+ * @param commitTaxRequest a {@link CommitTaxRequest} object indicating the document that should be committed.
158
+ * @return a {@link CommitTaxResult} object
159
+ * @throws SoapFault
160
+ */
161
+
162
+ /*public com.avalara.avatax.services.tax.CommitTaxResult commitTax(com.avalara.avatax.services.tax.CommitTaxRequest commitTaxRequest) throws SoapFault;
163
+ */
164
+ public function commitTax(&$commitTaxRequest)
165
+ {
166
+ return $this->client->CommitTax(array('CommitTaxRequest'=>$commitTaxRequest))->CommitTaxResult;
167
+ }
168
+ /**
169
+ * Cancels a previously calculated tax; This is for use as a
170
+ * compensating action when posting on the client fails to complete.
171
+ * <p>
172
+ * This is only available for saved tax document types (Sales Invoices, Purchase Invoices). A document that is saved
173
+ * but not posted will be deleted if canceled. A document that has been posted will revert to a saved state if canceled
174
+ * (in this case <b>CancelTax</b> should be called with a {@link CancelTaxRequest#getCancelCode} of
175
+ * <i>PostFailed</i>). A document that has been committed cannot be reverted to a posted state or deleted. In the case
176
+ * that a document on the client side no longer exists, a committed document can be virtually removed by calling
177
+ * <b>CancelTax</b> with a <b>CancelCode</b> of <i>DocDeleted</i>. The record will be retained in history but removed
178
+ * from all reports.
179
+ * </p>
180
+ * <p>
181
+ * A document can be indicated solely by the {@link CancelTaxRequest#getDocId} if it is known. Otherwise the request
182
+ * must specify all of {@link CancelTaxRequest#getCompanyCode}, {@link CancelTaxRequest#getDocCode}, and
183
+ * {@link CancelTaxRequest#getDocType} in order to uniquely identify the document.
184
+ *
185
+ * @param cancelTaxRequest a {@link CancelTaxRequest} object indicating the document that should be canceled.
186
+ * @return a {@link CancelTaxResult} object
187
+ * @throws SoapFault
188
+ */
189
+ /* public com.avalara.avatax.services.tax.CancelTaxResult cancelTax(com.avalara.avatax.services.tax.CancelTaxRequest cancelTaxRequest) throws SoapFault;
190
+ */
191
+ public function cancelTax(&$cancelTaxRequest)
192
+ {
193
+ return $this->client->CancelTax(array('CancelTaxRequest'=>$cancelTaxRequest))->CancelTaxResult;
194
+ }
195
+
196
+ /**
197
+ * Reconciles tax history to ensure the client data matches the
198
+ * AvaTax history.
199
+ * <p>The Reconcile operation allows reconciliation of the AvaTax history with the client accounting system.
200
+ * It must be used periodically according to your service contract.
201
+ * </p>
202
+ * <p>
203
+ * Because there may be a large number of documents to reconcile, it is designed to be called repetitively
204
+ * until all documents have been reconciled. It should be called until no more documents are returned.
205
+ * Each subsequent call should pass the previous results {@link ReconcileTaxHistoryRequest#getLastDocId}.
206
+ * </p>
207
+ * <p>
208
+ * When all results have been reconciled, Reconcile should be called once more with
209
+ * {@link ReconcileTaxHistoryRequest#getLastDocId}
210
+ * equal to the last document code processed and {@link ReconcileTaxHistoryRequest#isReconciled} set to true to indicate
211
+ * that all items have been reconciled. If desired, this may be done incrementally with each result set. Just send
212
+ * Reconciled as true when requesting the next result set and the prior results will be marked as reconciled.
213
+ * </p>
214
+ * <p>
215
+ * The {@link #postTax}, {@link #commitTax}, and {@link #cancelTax} operations can be used to correct any differences.
216
+ * {@link #getTax} should be called if any committed documents are out of balance
217
+ * ({@link GetTaxResult#getTotalAmount} or {@link GetTaxResult#getTotalTax}
218
+ * don't match the accounting system records). This is to make sure the correct tax is reported.
219
+ * </p>
220
+ *
221
+ * @param reconcileTaxHistoryRequest a Reconciliation request
222
+ * @return A collection of documents that have been posted or committed since the last reconciliation.
223
+ * @throws SoapFault
224
+ */
225
+ /*public com.avalara.avatax.services.tax.ReconcileTaxHistoryResult reconcileTaxHistory(com.avalara.avatax.services.tax.ReconcileTaxHistoryRequest reconcileTaxHistoryRequest) throws SoapFault;
226
+ */
227
+ public function reconcileTaxHistory(&$reconcileTaxHistoryRequest)
228
+ {
229
+ return $this->client->ReconcileTaxHistory(array('ReconcileTaxHistoryRequest'=>$reconcileTaxHistoryRequest))->ReconcileTaxHistoryResult;
230
+ }
231
+
232
+ /**
233
+ * Adjusts a previously calculated tax.
234
+ * <p>
235
+ * This is only available for unlocked tax documents (Sales Invoices, Purchase Invoices). * </p>
236
+ * <p>
237
+ * </p>
238
+ *
239
+ * @param adjustTaxRequest a {@link AdjustTaxRequest} object indicating the document that should be edited.
240
+ * @return a {@link AdjustTaxResult} object
241
+ * @throws SoapFault
242
+ */
243
+
244
+ /*public com.avalara.avatax.services.tax.CommitTaxResult commitTax(com.avalara.avatax.services.tax.CommitTaxRequest commitTaxRequest) throws SoapFault;
245
+ */
246
+ public function adjustTax(&$adjustTaxRequest)
247
+ {
248
+ $adjustTaxRequest->getGetTaxRequest()->prepare();
249
+ return $this->client->AdjustTax(array('AdjustTaxRequest'=>$adjustTaxRequest))->AdjustTaxResult;
250
+ }
251
+ /**
252
+ * Checks authentication of and authorization to one or more
253
+ * operations on the service.
254
+ *
255
+ * This operation allows pre-authorization checking of any
256
+ * or all operations. It will return a comma delimited set of
257
+ * operation names which will be all or a subset of the requested
258
+ * operation names. For security, it will never return operation
259
+ * names other than those requested (no phishing allowed).
260
+ *
261
+ * <b>Example:</b><br>
262
+ * <code> isAuthorized("GetTax,PostTax")</code>
263
+ *
264
+ * @param string $operations a comma-delimited list of operation names
265
+ *
266
+ * @return IsAuthorizedResult
267
+ * @throws SoapFault
268
+ */
269
+
270
+
271
+ public function isAuthorized($operations)
272
+ {
273
+ return $this->client->IsAuthorized(array('Operations' => $operations))->IsAuthorizedResult;
274
+ }
275
+
276
+ /**
277
+ * Verifies connectivity to the web service and returns version
278
+ * information about the service.
279
+ *
280
+ * <b>NOTE:</b>This replaces TestConnection and is available on
281
+ * every service.
282
+ *
283
+ * @param string $message for future use
284
+ * @return PingResult
285
+ * @throws SoapFault
286
+ */
287
+
288
+ public function ping($message = '')
289
+ {
290
+ return $this->client->Ping(array('Message' => $message))->PingResult;
291
+ }
292
+
293
+ /**
294
+ * This method is used to apply a payment to a document for cash basis accounting. Applies a payment date to an existing invoice
295
+ * It sets the document PaymentDate and changes the reporting date from the DocDate default. It may be called before or after a document is committed. It should not be used for accrual basis accounting
296
+ *
297
+ * @param ApplyPaymentRequest $applyPaymentRequest
298
+ * @return ApplyPaymentResult
299
+ */
300
+
301
+ public function applyPayment(&$applyPaymentRequest)
302
+ {
303
+ return $this->client->ApplyPayment(array('ApplyPaymentRequest' => $applyPaymentRequest))->ApplyPaymentResult;
304
+ }
305
+
306
+ }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/TaxType.class.php RENAMED
@@ -1,35 +1,35 @@
1
- <?php
2
- /**
3
- * TaxType.class.php
4
- * @package Tax
5
- */
6
-
7
- /**
8
- * The Type of the tax.
9
- *
10
- * @package Tax
11
- * @author tblanchard
12
- * Copyright (c) 2008, Avalara. All rights reserved.
13
- */
14
-
15
- class TaxType// extends Enum
16
- {
17
- public static $Sales = 'Sales';
18
- public static $Use = 'Use';
19
- public static $ConsumerUse = 'ConsumerUse';
20
- /*
21
- public static function Values()
22
- {
23
- return array(
24
- $TaxType::$Sales,
25
- $TaxType::$Use,
26
- $TaxType::$ConsumerUse
27
- );
28
- }
29
-
30
- // Unfortunate boiler plate due to polymorphism issues on static functions
31
- public static function Validate($value) { self::__Validate($value,self::Values(),__CLASS__); }
32
-
33
- */
34
-
35
  }
1
+ <?php
2
+ /**
3
+ * TaxType.class.php
4
+ * @package Tax
5
+ */
6
+
7
+ /**
8
+ * The Type of the tax.
9
+ *
10
+ * @package Tax
11
+ * @author tblanchard
12
+ * Copyright (c) 2008, Avalara. All rights reserved.
13
+ */
14
+
15
+ class TaxType// extends Enum
16
+ {
17
+ public static $Sales = 'Sales';
18
+ public static $Use = 'Use';
19
+ public static $ConsumerUse = 'ConsumerUse';
20
+ /*
21
+ public static function Values()
22
+ {
23
+ return array(
24
+ $TaxType::$Sales,
25
+ $TaxType::$Use,
26
+ $TaxType::$ConsumerUse
27
+ );
28
+ }
29
+
30
+ // Unfortunate boiler plate due to polymorphism issues on static functions
31
+ public static function Validate($value) { self::__Validate($value,self::Values(),__CLASS__); }
32
+
33
+ */
34
+
35
  }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/TextCase.class.php RENAMED
@@ -1,32 +1,32 @@
1
- <?php
2
- /**
3
- * TextCase.class.php
4
- * @package Address
5
- */
6
-
7
- /**
8
- * The casing to apply to the valid address(es) returned in the validation result.
9
- *
10
- * @package Address
11
- * @author tblanchard
12
- * Copyright (c) 2007, Avalara. All rights reserved.
13
- */
14
-
15
- class TextCase extends Enum
16
- {
17
- public static $Default = 'Default';
18
- public static $Upper = 'Upper';
19
- public static $Mixed = 'Mixed';
20
-
21
- public static function Values()
22
- {
23
- return array(
24
- TextCase::$Default,
25
- TextCase::$Upper,
26
- TextCase::$Mixed,
27
- );
28
- }
29
-
30
- // Unfortunate boiler plate due to polymorphism issues on static functions
31
- public static function Validate($value) { self::__Validate($value,self::Values(),__CLASS__); }
32
  }
1
+ <?php
2
+ /**
3
+ * TextCase.class.php
4
+ * @package Address
5
+ */
6
+
7
+ /**
8
+ * The casing to apply to the valid address(es) returned in the validation result.
9
+ *
10
+ * @package Address
11
+ * @author tblanchard
12
+ * Copyright (c) 2007, Avalara. All rights reserved.
13
+ */
14
+
15
+ class TextCase extends Enum
16
+ {
17
+ public static $Default = 'Default';
18
+ public static $Upper = 'Upper';
19
+ public static $Mixed = 'Mixed';
20
+
21
+ public static function Values()
22
+ {
23
+ return array(
24
+ TextCase::$Default,
25
+ TextCase::$Upper,
26
+ TextCase::$Mixed,
27
+ );
28
+ }
29
+
30
+ // Unfortunate boiler plate due to polymorphism issues on static functions
31
+ public static function Validate($value) { self::__Validate($value,self::Values(),__CLASS__); }
32
  }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/ValidAddress.class.php RENAMED
@@ -1,476 +1,476 @@
1
- <?php
2
- /**
3
- * ValidAddress.class.php
4
- * @package Address
5
- */
6
-
7
- /**
8
- * A fully validated address based on initial {@link Address}
9
- * data passed to {@link AddressServiceSoap#validate}.
10
- * <pre>
11
- * <b>Example:</b>
12
- * $address = new Address();
13
- * $address->setLine1("900 Winslow Way");
14
- * $address->setLine2("Suite 130");
15
- * $address->setCity("Bainbridge Is");
16
- * $address->setRegion("WA");
17
- * $address->setPostalCode("98110-2450");
18
- *
19
- * $result = svc->validate($address,TextCase::$Upper);
20
- *
21
- * if ($result->getResultCode() == SeverityLevel::$Success)
22
- * {
23
- * $addresses = result->validAddresses();
24
- * if (sizeof($addresses) > 0)
25
- * {
26
- * $validAddress = $addresses[0];
27
- * print($validAddress->getLine1()); // "900 WINSLOW WAY E STE 130",
28
- * print($validAddress->getLine4()); // "BAINBRIDGE IS WA 98110-2450"
29
- * print($validAddress->getFipsCode()); // "5303500000"
30
- * print($validAddress->getCounty()); // "KITSAP"
31
- * }
32
- * }
33
- * </pre>
34
- *
35
- * @see Address
36
- * @package Address
37
- * @author tblanchard
38
- * Copyright (c) 2007, Avalara. All rights reserved.
39
- */
40
-
41
- class ValidAddress //extends Address - or it should - SoapClient has issues mapping attributes in superclasses
42
- {
43
- /**#@+
44
- * @access private
45
- * @var string
46
- */
47
- private $AddressCode;
48
- private $Line1;
49
- private $Line2;
50
- private $Line3;
51
- private $City;
52
- private $Region;
53
- private $PostalCode;
54
- private $Country = 'USA';
55
-
56
- private $Line4;
57
- private $County;
58
- private $FipsCode;
59
- private $CarrierRoute;
60
- private $PostNet;
61
- private $AddressType;
62
- private $Latitude;
63
- private $Longitude;
64
- /**#@-*/
65
-
66
- /**
67
- * @access private
68
- * @var integer
69
- */
70
- private $TaxRegionId = 0;
71
-
72
-
73
- /**#@+
74
- * Accessor
75
- * @access public
76
- * @return string
77
- */
78
- public function getAddressCode() { return $this->AddressCode; }
79
- public function getLine1() { return $this->Line1; }
80
- public function getLine2() { return $this->Line2; }
81
- public function getLine3() { return $this->Line3; }
82
- public function getCity() { return $this->City; }
83
- public function getRegion() { return $this->Region; }
84
- public function getPostalCode() { return $this->PostalCode; }
85
- public function getCountry() { return $this->Country; }
86
- /**#@-*/
87
-
88
- /**
89
- * Accessor
90
- * @access public
91
- * @return integer
92
- */
93
- public function getTaxRegionId() { return $this->TaxRegionId; }
94
-
95
- /**
96
- * Compare Addresses
97
- * @access public
98
- * @param Address
99
- * @return boolean
100
- */
101
-
102
- public function equals(&$other)
103
- {
104
- return $this === $other || (
105
- strcmp($this->AddressCode , $other->AddressCode) == 0 &&
106
- strcmp($this->Line1 , $other->Line1) == 0 &&
107
- strcmp($this->Line2 , $other->Line2) == 0 &&
108
- strcmp($this->Line3 , $other->Line3) == 0 &&
109
- strcmp($this->City , $other->City) == 0 &&
110
- strcmp($this->Region , $other->Region) == 0 &&
111
- strcmp($this->PostalCode , $other->PostalCode) == 0 &&
112
- strcmp($this->Country , $other->Country) == 0 &&
113
- $this->TaxRegionId === $other->TaxRegionId
114
- );
115
- }
116
-
117
-
118
-
119
- /**
120
- * Address line 4.
121
- *
122
- * @return line4 - Address line 4
123
- */
124
-
125
- public function getLine4() { return $this->Line4; }
126
-
127
- /**
128
- * County Name.
129
- *
130
- * @return county - County Name
131
- */
132
-
133
- public function getCounty() { return $this->County; }
134
-
135
- /**
136
- * Federal Information Processing Standards Code (USA).
137
- * <p> This is a unique code representing each geographic combination of state, county, and city.
138
- * The code is made up of the Federal Information Processing Code (FIPS) that uniquely identifies each state, county, and city in the U.S.
139
- * See <a href="http://www.census.gov/geo/www/fips/fips.html">Federal Information Processing Standards (FIPS) Codes</a> for more details.
140
- * <table>
141
- * <tr>
142
- * <th>Digits</th>
143
- * <th>Description</th>
144
- * </tr>
145
- * <tr>
146
- * <td>1-2</td>
147
- * <td>State code</td>
148
- * </tr>
149
- * <tr>
150
- * <td>3-5</td><td>County code</td>
151
- * </tr>
152
- * <tr>
153
- * <td>6-10</td><td>City code</td>
154
- * </tr>
155
- * </table>
156
- *
157
- * @return fipsCode
158
- */
159
-
160
- public function getFipsCode() { return $this->FipsCode; }
161
-
162
- /**
163
- * The carrier route associated with the input address (USA).
164
- * <p>The CarrierRoute Property is a 4 character string set
165
- * after a successful return from the VerifyAddress Method.
166
- * <p>The first character of this property is always alphabetic,
167
- * and the last three characters are numeric. For example,
168
- * "R001" or "C027" would be typical carrier routes. The
169
- * alphabetic letter indicates the type of delivery associated
170
- * with this address.
171
- * <table>
172
- * <tr>
173
- * <th>Term</th>
174
- *
175
- * <th>Description</th>
176
- * </tr>
177
- * <tr>
178
- * <td>B</td>
179
- * <td>PO Box</td>
180
- * </tr>
181
- * <tr>
182
- * <td>C</td>
183
- * <td>City Delivery</td>
184
- * </tr>
185
- * <tr>
186
- * <td>G</td>
187
- * <td>General Delivery</td>
188
- * </tr>
189
- * <tr>
190
- * <td>H</td>
191
- * <td>Highway Contract</td>
192
- * </tr>
193
- * <tr>
194
- * <td>R</td>
195
- * <td>Rural Route</td>
196
- * </tr>
197
- * </table>
198
- *
199
- * @return carrierRoute
200
- */
201
-
202
- public function getCarrierRoute() { return $this->CarrierRoute; }
203
-
204
- /**
205
- * A 12-digit POSTNet barcode (USA).
206
- * <table>
207
- * <tr>
208
- * <th>Digits</th>
209
- * <th>Description</th>
210
- * </tr>
211
- * <tr>
212
- * <td>1-5<td><td>ZIP Code</td>
213
- * </tr>
214
- * <tr>
215
- * <td>6-9<td><td>Plus4 code</td>
216
- * </tr>
217
- * <tr>
218
- * <td>10-11<td><td>Delivery point</td>
219
- * </tr>
220
- * <tr>
221
- * <td>12<td><td>Check digit</td>
222
- * </tr>
223
- * </table>
224
- *
225
- * @return postNet
226
- */
227
-
228
- public function getPostNet() { return $this->PostNet; }
229
-
230
- /**
231
- * Address Type - The type of address that was coded
232
- * (PO Box, Rural Route, and so on), using the input address.
233
- *
234
- * <table>
235
- * <tr>
236
- * <th>Code</th>
237
- * <th>Type</th>
238
- * </tr>
239
- * <tr>
240
- * <td>F<td><td>Firm or company address</td>
241
- * </tr>
242
- * <tr>
243
- * <td>G<td><td>General Delivery address</td>
244
- * </tr>
245
- * <tr>
246
- * <td>H<td><td>High-rise or business complexs</td>
247
- * </tr>
248
- * <tr>
249
- * <td>P<td><td>PO Box address</td>
250
- * </tr>
251
- * <tr>
252
- * <td>R<td><td>Rural route address</td>
253
- * </tr>
254
- * <tr>
255
- * <td>S<td><td>Street or residential address</td>
256
- * </tr>
257
- * </table>
258
- *
259
- * @see AddressType
260
- * @return string
261
- */
262
-
263
- public function getAddressType() { return $this->AddressType; }
264
-
265
- /**
266
- * Gets the latitude value for this ValidAddress.
267
- *
268
- * @return latitude
269
- */
270
-
271
- public function getLatitude() { return $this->Latitude; }
272
-
273
- /**
274
- * Gets the longitude value for this ValidAddress.
275
- *
276
- * @return longitude
277
- */
278
-
279
- public function getLongitude() { return $this->Longitude; }
280
-
281
- // mutators
282
-
283
- /**#@+
284
- * Mutator
285
- * @access public
286
- * @var string
287
- * @return Address
288
- */
289
- public function setAddressCode($value) { $this->AddressCode = $value; return $this; }
290
- public function setLine1($value) { $this->Line1 = $value; return $this; }
291
- public function setLine2($value) { $this->Line2 = $value; return $this; }
292
- public function setLine3($value) { $this->Line3 = $value; return $this; }
293
- public function setCity($value) { $this->City = $value; return $this; }
294
- public function setRegion($value) { $this->Region = $value; return $this; }
295
- public function setPostalCode($value) { $this->PostalCode = $value; return $this; }
296
- public function setCountry($value) { $this->Country = $value; return $this; }
297
- /**#@-*/
298
-
299
- /**
300
- * Mutator
301
- * @access public
302
- * @param integer
303
- * @return Address
304
- */
305
- public function setTaxRegionId($value) { $this->TaxRegionId = $value; return $this; }
306
- /**
307
- * Address line 4.
308
- *
309
- * @param line4 - Address line 4
310
- * @var string
311
- */
312
-
313
- public function setLine4($value) { $this->Line4 = $value; return $this; }
314
-
315
- /**
316
- * County Name.
317
- *
318
- * @param county - County Name
319
- * @var string
320
- */
321
-
322
- public function setCounty($value) { $this->County= $value; return $this; }
323
-
324
- /**
325
- * Federal Information Processing Standards Code (USA).
326
- * <p> This is a unique code representing each geographic combination of state, county, and city.
327
- * The code is made up of the Federal Information Processing Code (FIPS) that uniquely identifies each state, county, and city in the U.S.
328
- * See <a href="http://www.census.gov/geo/www/fips/fips.html">Federal Information Processing Standards (FIPS) Codes</a> for more details.
329
- * <table>
330
- * <tr>
331
- * <th>Digits</th>
332
- * <th>Description</th>
333
- * </tr>
334
- * <tr>
335
- * <td>1-2</td>
336
- * <td>State code</td>
337
- * </tr>
338
- * <tr>
339
- * <td>3-5</td><td>County code</td>
340
- * </tr>
341
- * <tr>
342
- * <td>6-10</td><td>City code</td>
343
- * </tr>
344
- * </table>
345
- *
346
- * @param fipsCode
347
- * @var string
348
- */
349
-
350
- public function setFipsCode($value) { $this->FipsCode= $value; return $this; }
351
-
352
- /**
353
- * The carrier route associated with the input address (USA).
354
- * <p>The CarrierRoute Property is a 4 character string set
355
- * after a successful return from the VerifyAddress Method.
356
- * <p>The first character of this property is always alphabetic,
357
- * and the last three characters are numeric. For example,
358
- * "R001" or "C027" would be typical carrier routes. The
359
- * alphabetic letter indicates the type of delivery associated
360
- * with this address.
361
- * <table>
362
- * <tr>
363
- * <th>Term</th>
364
- *
365
- * <th>Description</th>
366
- * </tr>
367
- * <tr>
368
- * <td>B</td>
369
- * <td>PO Box</td>
370
- * </tr>
371
- * <tr>
372
- * <td>C</td>
373
- * <td>City Delivery</td>
374
- * </tr>
375
- * <tr>
376
- * <td>G</td>
377
- * <td>General Delivery</td>
378
- * </tr>
379
- * <tr>
380
- * <td>H</td>
381
- * <td>Highway Contract</td>
382
- * </tr>
383
- * <tr>
384
- * <td>R</td>
385
- * <td>Rural Route</td>
386
- * </tr>
387
- * </table>
388
- *
389
- * @param carrierRoute
390
- * @var string
391
- */
392
-
393
- public function setCarrierRoute($value) { $this->CarrierRoute= $value; return $this; }
394
-
395
- /**
396
- * A 12-digit POSTNet barcode (USA).
397
- * <table>
398
- * <tr>
399
- * <th>Digits</th>
400
- * <th>Description</th>
401
- * </tr>
402
- * <tr>
403
- * <td>1-5<td><td>ZIP Code</td>
404
- * </tr>
405
- * <tr>
406
- * <td>6-9<td><td>Plus4 code</td>
407
- * </tr>
408
- * <tr>
409
- * <td>10-11<td><td>Delivery point</td>
410
- * </tr>
411
- * <tr>
412
- * <td>12<td><td>Check digit</td>
413
- * </tr>
414
- * </table>
415
- *
416
- * @param postNet
417
- * @var string
418
- */
419
-
420
- public function setPostNet($value) { $this->PostNet= $value; return $this; }
421
-
422
- /**
423
- * Address Type - The type of address that was coded
424
- * (PO Box, Rural Route, and so on), using the input address.
425
- *
426
- * <table>
427
- * <tr>
428
- * <th>Code</th>
429
- * <th>Type</th>
430
- * </tr>
431
- * <tr>
432
- * <td>F<td><td>Firm or company address</td>
433
- * </tr>
434
- * <tr>
435
- * <td>G<td><td>General Delivery address</td>
436
- * </tr>
437
- * <tr>
438
- * <td>H<td><td>High-rise or business complexs</td>
439
- * </tr>
440
- * <tr>
441
- * <td>P<td><td>PO Box address</td>
442
- * </tr>
443
- * <tr>
444
- * <td>R<td><td>Rural route address</td>
445
- * </tr>
446
- * <tr>
447
- * <td>S<td><td>Street or residential address</td>
448
- * </tr>
449
- * </table>
450
- *
451
- * @see AddressType
452
- * @param addressType
453
- * @var string
454
- */
455
-
456
- public function setAddressType($value) { $this->AddressType= $value; return $this; }
457
-
458
- /**
459
- * Sets the latitude value for this ValidAddress.
460
- *
461
- * @param latitude
462
- */
463
-
464
- public function setLatitude($value) { $this->Latitude= $value; return $this;}
465
-
466
- /**
467
- * Sets the longitude value for this ValidAddress.
468
- *
469
- * @param longitude
470
- */
471
-
472
- public function setLongitude($value) { $this->Longitude= $value; return $this; }
473
-
474
-
475
-
476
  }
1
+ <?php
2
+ /**
3
+ * ValidAddress.class.php
4
+ * @package Address
5
+ */
6
+
7
+ /**
8
+ * A fully validated address based on initial {@link Address}
9
+ * data passed to {@link AddressServiceSoap#validate}.
10
+ * <pre>
11
+ * <b>Example:</b>
12
+ * $address = new Address();
13
+ * $address->setLine1("900 Winslow Way");
14
+ * $address->setLine2("Suite 130");
15
+ * $address->setCity("Bainbridge Is");
16
+ * $address->setRegion("WA");
17
+ * $address->setPostalCode("98110-2450");
18
+ *
19
+ * $result = svc->validate($address,TextCase::$Upper);
20
+ *
21
+ * if ($result->getResultCode() == SeverityLevel::$Success)
22
+ * {
23
+ * $addresses = result->validAddresses();
24
+ * if (sizeof($addresses) > 0)
25
+ * {
26
+ * $validAddress = $addresses[0];
27
+ * print($validAddress->getLine1()); // "900 WINSLOW WAY E STE 130",
28
+ * print($validAddress->getLine4()); // "BAINBRIDGE IS WA 98110-2450"
29
+ * print($validAddress->getFipsCode()); // "5303500000"
30
+ * print($validAddress->getCounty()); // "KITSAP"
31
+ * }
32
+ * }
33
+ * </pre>
34
+ *
35
+ * @see Address
36
+ * @package Address
37
+ * @author tblanchard
38
+ * Copyright (c) 2007, Avalara. All rights reserved.
39
+ */
40
+
41
+ class ValidAddress //extends Address - or it should - SoapClient has issues mapping attributes in superclasses
42
+ {
43
+ /**#@+
44
+ * @access private
45
+ * @var string
46
+ */
47
+ private $AddressCode;
48
+ private $Line1;
49
+ private $Line2;
50
+ private $Line3;
51
+ private $City;
52
+ private $Region;
53
+ private $PostalCode;
54
+ private $Country = 'USA';
55
+
56
+ private $Line4;
57
+ private $County;
58
+ private $FipsCode;
59
+ private $CarrierRoute;
60
+ private $PostNet;
61
+ private $AddressType;
62
+ private $Latitude;
63
+ private $Longitude;
64
+ /**#@-*/
65
+
66
+ /**
67
+ * @access private
68
+ * @var integer
69
+ */
70
+ private $TaxRegionId = 0;
71
+
72
+
73
+ /**#@+
74
+ * Accessor
75
+ * @access public
76
+ * @return string
77
+ */
78
+ public function getAddressCode() { return $this->AddressCode; }
79
+ public function getLine1() { return $this->Line1; }
80
+ public function getLine2() { return $this->Line2; }
81
+ public function getLine3() { return $this->Line3; }
82
+ public function getCity() { return $this->City; }
83
+ public function getRegion() { return $this->Region; }
84
+ public function getPostalCode() { return $this->PostalCode; }
85
+ public function getCountry() { return $this->Country; }
86
+ /**#@-*/
87
+
88
+ /**
89
+ * Accessor
90
+ * @access public
91
+ * @return integer
92
+ */
93
+ public function getTaxRegionId() { return $this->TaxRegionId; }
94
+
95
+ /**
96
+ * Compare Addresses
97
+ * @access public
98
+ * @param Address
99
+ * @return boolean
100
+ */
101
+
102
+ public function equals(&$other)
103
+ {
104
+ return $this === $other || (
105
+ strcmp($this->AddressCode , $other->AddressCode) == 0 &&
106
+ strcmp($this->Line1 , $other->Line1) == 0 &&
107
+ strcmp($this->Line2 , $other->Line2) == 0 &&
108
+ strcmp($this->Line3 , $other->Line3) == 0 &&
109
+ strcmp($this->City , $other->City) == 0 &&
110
+ strcmp($this->Region , $other->Region) == 0 &&
111
+ strcmp($this->PostalCode , $other->PostalCode) == 0 &&
112
+ strcmp($this->Country , $other->Country) == 0 &&
113
+ $this->TaxRegionId === $other->TaxRegionId
114
+ );
115
+ }
116
+
117
+
118
+
119
+ /**
120
+ * Address line 4.
121
+ *
122
+ * @return line4 - Address line 4
123
+ */
124
+
125
+ public function getLine4() { return $this->Line4; }
126
+
127
+ /**
128
+ * County Name.
129
+ *
130
+ * @return county - County Name
131
+ */
132
+
133
+ public function getCounty() { return $this->County; }
134
+
135
+ /**
136
+ * Federal Information Processing Standards Code (USA).
137
+ * <p> This is a unique code representing each geographic combination of state, county, and city.
138
+ * The code is made up of the Federal Information Processing Code (FIPS) that uniquely identifies each state, county, and city in the U.S.
139
+ * See <a href="http://www.census.gov/geo/www/fips/fips.html">Federal Information Processing Standards (FIPS) Codes</a> for more details.
140
+ * <table>
141
+ * <tr>
142
+ * <th>Digits</th>
143
+ * <th>Description</th>
144
+ * </tr>
145
+ * <tr>
146
+ * <td>1-2</td>
147
+ * <td>State code</td>
148
+ * </tr>
149
+ * <tr>
150
+ * <td>3-5</td><td>County code</td>
151
+ * </tr>
152
+ * <tr>
153
+ * <td>6-10</td><td>City code</td>
154
+ * </tr>
155
+ * </table>
156
+ *
157
+ * @return fipsCode
158
+ */
159
+
160
+ public function getFipsCode() { return $this->FipsCode; }
161
+
162
+ /**
163
+ * The carrier route associated with the input address (USA).
164
+ * <p>The CarrierRoute Property is a 4 character string set
165
+ * after a successful return from the VerifyAddress Method.
166
+ * <p>The first character of this property is always alphabetic,
167
+ * and the last three characters are numeric. For example,
168
+ * "R001" or "C027" would be typical carrier routes. The
169
+ * alphabetic letter indicates the type of delivery associated
170
+ * with this address.
171
+ * <table>
172
+ * <tr>
173
+ * <th>Term</th>
174
+ *
175
+ * <th>Description</th>
176
+ * </tr>
177
+ * <tr>
178
+ * <td>B</td>
179
+ * <td>PO Box</td>
180
+ * </tr>
181
+ * <tr>
182
+ * <td>C</td>
183
+ * <td>City Delivery</td>
184
+ * </tr>
185
+ * <tr>
186
+ * <td>G</td>
187
+ * <td>General Delivery</td>
188
+ * </tr>
189
+ * <tr>
190
+ * <td>H</td>
191
+ * <td>Highway Contract</td>
192
+ * </tr>
193
+ * <tr>
194
+ * <td>R</td>
195
+ * <td>Rural Route</td>
196
+ * </tr>
197
+ * </table>
198
+ *
199
+ * @return carrierRoute
200
+ */
201
+
202
+ public function getCarrierRoute() { return $this->CarrierRoute; }
203
+
204
+ /**
205
+ * A 12-digit POSTNet barcode (USA).
206
+ * <table>
207
+ * <tr>
208
+ * <th>Digits</th>
209
+ * <th>Description</th>
210
+ * </tr>
211
+ * <tr>
212
+ * <td>1-5<td><td>ZIP Code</td>
213
+ * </tr>
214
+ * <tr>
215
+ * <td>6-9<td><td>Plus4 code</td>
216
+ * </tr>
217
+ * <tr>
218
+ * <td>10-11<td><td>Delivery point</td>
219
+ * </tr>
220
+ * <tr>
221
+ * <td>12<td><td>Check digit</td>
222
+ * </tr>
223
+ * </table>
224
+ *
225
+ * @return postNet
226
+ */
227
+
228
+ public function getPostNet() { return $this->PostNet; }
229
+
230
+ /**
231
+ * Address Type - The type of address that was coded
232
+ * (PO Box, Rural Route, and so on), using the input address.
233
+ *
234
+ * <table>
235
+ * <tr>
236
+ * <th>Code</th>
237
+ * <th>Type</th>
238
+ * </tr>
239
+ * <tr>
240
+ * <td>F<td><td>Firm or company address</td>
241
+ * </tr>
242
+ * <tr>
243
+ * <td>G<td><td>General Delivery address</td>
244
+ * </tr>
245
+ * <tr>
246
+ * <td>H<td><td>High-rise or business complexs</td>
247
+ * </tr>
248
+ * <tr>
249
+ * <td>P<td><td>PO Box address</td>
250
+ * </tr>
251
+ * <tr>
252
+ * <td>R<td><td>Rural route address</td>
253
+ * </tr>
254
+ * <tr>
255
+ * <td>S<td><td>Street or residential address</td>
256
+ * </tr>
257
+ * </table>
258
+ *
259
+ * @see AddressType
260
+ * @return string
261
+ */
262
+
263
+ public function getAddressType() { return $this->AddressType; }
264
+
265
+ /**
266
+ * Gets the latitude value for this ValidAddress.
267
+ *
268
+ * @return latitude
269
+ */
270
+
271
+ public function getLatitude() { return $this->Latitude; }
272
+
273
+ /**
274
+ * Gets the longitude value for this ValidAddress.
275
+ *
276
+ * @return longitude
277
+ */
278
+
279
+ public function getLongitude() { return $this->Longitude; }
280
+
281
+ // mutators
282
+
283
+ /**#@+
284
+ * Mutator
285
+ * @access public
286
+ * @var string
287
+ * @return Address
288
+ */
289
+ public function setAddressCode($value) { $this->AddressCode = $value; return $this; }
290
+ public function setLine1($value) { $this->Line1 = $value; return $this; }
291
+ public function setLine2($value) { $this->Line2 = $value; return $this; }
292
+ public function setLine3($value) { $this->Line3 = $value; return $this; }
293
+ public function setCity($value) { $this->City = $value; return $this; }
294
+ public function setRegion($value) { $this->Region = $value; return $this; }
295
+ public function setPostalCode($value) { $this->PostalCode = $value; return $this; }
296
+ public function setCountry($value) { $this->Country = $value; return $this; }
297
+ /**#@-*/
298
+
299
+ /**
300
+ * Mutator
301
+ * @access public
302
+ * @param integer
303
+ * @return Address
304
+ */
305
+ public function setTaxRegionId($value) { $this->TaxRegionId = $value; return $this; }
306
+ /**
307
+ * Address line 4.
308
+ *
309
+ * @param line4 - Address line 4
310
+ * @var string
311
+ */
312
+
313
+ public function setLine4($value) { $this->Line4 = $value; return $this; }
314
+
315
+ /**
316
+ * County Name.
317
+ *
318
+ * @param county - County Name
319
+ * @var string
320
+ */
321
+
322
+ public function setCounty($value) { $this->County= $value; return $this; }
323
+
324
+ /**
325
+ * Federal Information Processing Standards Code (USA).
326
+ * <p> This is a unique code representing each geographic combination of state, county, and city.
327
+ * The code is made up of the Federal Information Processing Code (FIPS) that uniquely identifies each state, county, and city in the U.S.
328
+ * See <a href="http://www.census.gov/geo/www/fips/fips.html">Federal Information Processing Standards (FIPS) Codes</a> for more details.
329
+ * <table>
330
+ * <tr>
331
+ * <th>Digits</th>
332
+ * <th>Description</th>
333
+ * </tr>
334
+ * <tr>
335
+ * <td>1-2</td>
336
+ * <td>State code</td>
337
+ * </tr>
338
+ * <tr>
339
+ * <td>3-5</td><td>County code</td>
340
+ * </tr>
341
+ * <tr>
342
+ * <td>6-10</td><td>City code</td>
343
+ * </tr>
344
+ * </table>
345
+ *
346
+ * @param fipsCode
347
+ * @var string
348
+ */
349
+
350
+ public function setFipsCode($value) { $this->FipsCode= $value; return $this; }
351
+
352
+ /**
353
+ * The carrier route associated with the input address (USA).
354
+ * <p>The CarrierRoute Property is a 4 character string set
355
+ * after a successful return from the VerifyAddress Method.
356
+ * <p>The first character of this property is always alphabetic,
357
+ * and the last three characters are numeric. For example,
358
+ * "R001" or "C027" would be typical carrier routes. The
359
+ * alphabetic letter indicates the type of delivery associated
360
+ * with this address.
361
+ * <table>
362
+ * <tr>
363
+ * <th>Term</th>
364
+ *
365
+ * <th>Description</th>
366
+ * </tr>
367
+ * <tr>
368
+ * <td>B</td>
369
+ * <td>PO Box</td>
370
+ * </tr>
371
+ * <tr>
372
+ * <td>C</td>
373
+ * <td>City Delivery</td>
374
+ * </tr>
375
+ * <tr>
376
+ * <td>G</td>
377
+ * <td>General Delivery</td>
378
+ * </tr>
379
+ * <tr>
380
+ * <td>H</td>
381
+ * <td>Highway Contract</td>
382
+ * </tr>
383
+ * <tr>
384
+ * <td>R</td>
385
+ * <td>Rural Route</td>
386
+ * </tr>
387
+ * </table>
388
+ *
389
+ * @param carrierRoute
390
+ * @var string
391
+ */
392
+
393
+ public function setCarrierRoute($value) { $this->CarrierRoute= $value; return $this; }
394
+
395
+ /**
396
+ * A 12-digit POSTNet barcode (USA).
397
+ * <table>
398
+ * <tr>
399
+ * <th>Digits</th>
400
+ * <th>Description</th>
401
+ * </tr>
402
+ * <tr>
403
+ * <td>1-5<td><td>ZIP Code</td>
404
+ * </tr>
405
+ * <tr>
406
+ * <td>6-9<td><td>Plus4 code</td>
407
+ * </tr>
408
+ * <tr>
409
+ * <td>10-11<td><td>Delivery point</td>
410
+ * </tr>
411
+ * <tr>
412
+ * <td>12<td><td>Check digit</td>
413
+ * </tr>
414
+ * </table>
415
+ *
416
+ * @param postNet
417
+ * @var string
418
+ */
419
+
420
+ public function setPostNet($value) { $this->PostNet= $value; return $this; }
421
+
422
+ /**
423
+ * Address Type - The type of address that was coded
424
+ * (PO Box, Rural Route, and so on), using the input address.
425
+ *
426
+ * <table>
427
+ * <tr>
428
+ * <th>Code</th>
429
+ * <th>Type</th>
430
+ * </tr>
431
+ * <tr>
432
+ * <td>F<td><td>Firm or company address</td>
433
+ * </tr>
434
+ * <tr>
435
+ * <td>G<td><td>General Delivery address</td>
436
+ * </tr>
437
+ * <tr>
438
+ * <td>H<td><td>High-rise or business complexs</td>
439
+ * </tr>
440
+ * <tr>
441
+ * <td>P<td><td>PO Box address</td>
442
+ * </tr>
443
+ * <tr>
444
+ * <td>R<td><td>Rural route address</td>
445
+ * </tr>
446
+ * <tr>
447
+ * <td>S<td><td>Street or residential address</td>
448
+ * </tr>
449
+ * </table>
450
+ *
451
+ * @see AddressType
452
+ * @param addressType
453
+ * @var string
454
+ */
455
+
456
+ public function setAddressType($value) { $this->AddressType= $value; return $this; }
457
+
458
+ /**
459
+ * Sets the latitude value for this ValidAddress.
460
+ *
461
+ * @param latitude
462
+ */
463
+
464
+ public function setLatitude($value) { $this->Latitude= $value; return $this;}
465
+
466
+ /**
467
+ * Sets the longitude value for this ValidAddress.
468
+ *
469
+ * @param longitude
470
+ */
471
+
472
+ public function setLongitude($value) { $this->Longitude= $value; return $this; }
473
+
474
+
475
+
476
  }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/ValidateRequest.class.php RENAMED
@@ -1,190 +1,190 @@
1
- <?php
2
- /**
3
- * ValidateRequest.class.php
4
- * @package Address
5
- */
6
-
7
- /**
8
- * Data wrapper used internally to pass arguments within {@link AddressServiceSoap#validate}. End users should not need to use this class.
9
- *
10
- * <pre>
11
- * <b>Example:</b>
12
- * $svc = new AddressServiceSoap();
13
- *
14
- * $address = new Address();
15
- * $address->setLine1("900 Winslow Way");
16
- * $address->setCity("Bainbridge Island");
17
- * $address->setRegion("WA");
18
- * $address->setPostalCode("98110");
19
- *
20
- * ValidateRequest validateRequest = new ValidateRequest();
21
- * validateRequest.setAddress(address);
22
- * validateRequest.setTextCase(TextCase.Upper);
23
- *
24
- * ValidateResult result = svc.validate(validateRequest);
25
- * ArrayOfValidAddress arrValids = result.getValidAddresses();
26
- * int numAddresses = (arrValids == null ||
27
- * arrValids.getValidAddress() == null ? 0 :
28
- * arrValids.getValidAddress().length);
29
- * System.out.println("Number of Addresses is " + numAddresses);
30
- * </pre>
31
- *
32
- * @package Address
33
- * @author tblanchard
34
- * Copyright (c) 2006, Avalara. All rights reserved.
35
- */
36
-
37
- //public function validate($address, $textCase = 'Default', $coordinates = false)
38
- //{
39
- // $request = new ValidateRequest($address, ($textCase ? $textCase : TextCase::$Default), $coordinates);
40
- // return $this->client->Validate(array('ValidateRequest' => $request))->ValidateResult;
41
- //}
42
-
43
-
44
- class ValidateRequest
45
- {
46
- private $Address;
47
- private $TextCase = 'Default';
48
- private $Coordinates = false;
49
- private $Taxability=false;
50
-
51
- public function __construct($address = null, $textCase = 'Default', $coordinates = false)
52
- {
53
- $this->setAddress($address);
54
- $this->setTextCase($textCase);
55
- $this->setCoordinates($coordinates);
56
- }
57
-
58
- // mutators
59
- /**
60
- * The address to Validate.
61
- * <pre>
62
- * <b>Example:</b>
63
- * $address = new Address();
64
- * $address->setLine1("900 Winslow Way");
65
- * $address->setCity("Bainbridge Island");
66
- * $address->setRegion("WA");
67
- * $address->setPostalCode("98110");
68
- *
69
- * $validateRequest = new ValidateRequest();
70
- * $validateRequest->setAddress(address);
71
- * $validateRequest->setTextCase(TextCase::$Upper);
72
- *
73
- * $result = svc->validate(validateRequest);
74
- * </pre>
75
- *
76
- * @var Address
77
- */
78
-
79
- public function setAddress(&$value) { $this->Address = $value; return $this; }
80
-
81
- /**
82
- * The casing to apply to the validated address(es).
83
- * <pre>
84
- * <b>Example:</b>
85
- * <b>Example:</b>
86
- * $address = new Address();
87
- * $address->setLine1("900 Winslow Way");
88
- * $address->setCity("Bainbridge Island");
89
- * $address->setRegion("WA");
90
- * $address->setPostalCode("98110");
91
- *
92
- * $validateRequest = new ValidateRequest();
93
- * $validateRequest->setAddress(address);
94
- * $validateRequest->setTextCase(TextCase::$Upper);
95
- *
96
- * $result = svc->validate(validateRequest);
97
- * </pre>
98
- *
99
- * @var string
100
- * @see TextCase
101
- */
102
-
103
- public function setTextCase($value)
104
- {
105
- if($value)
106
- {
107
- TextCase::Validate($value);
108
- $this->TextCase = $value;
109
- }
110
- else
111
- {
112
- $this->TextCase = TextCase::$Default;
113
- }
114
- return $this;
115
- }
116
-
117
- /**
118
- * Sets whether to fetch the coordinates value for this ValidateRequest.
119
- * <p>
120
- * True will return the @see ValidAddress#Latitude and @see ValidAddress#Longitude values for the @see ValidAddresses
121
- * Default value is <b>false</b>
122
- * </p>
123
- * @var boolean
124
- */
125
- public function setCoordinates($value) { $this->Coordinates = ($value ? true : false); return $this; }
126
-
127
-
128
- //@author:swetal
129
- public function setTaxability($value)
130
- {
131
- $this->Taxability=$value;
132
- }
133
- // accessors
134
- /**
135
- * The address to Validate.
136
- * <pre>
137
- * <b>Example:</b>
138
- * $address = new Address();
139
- * $address->setLine1("900 Winslow Way");
140
- * $address->setCity("Bainbridge Island");
141
- * $address->setRegion("WA");
142
- * $address->setPostalCode("98110");
143
- *
144
- * $validateRequest = new ValidateRequest();
145
- * $validateRequest->setAddress(address);
146
- * $validateRequest->setTextCase(TextCase::$Upper);
147
- *
148
- * $result = svc->validate(validateRequest);
149
- * </pre>
150
- *
151
- * @return Address
152
- */
153
-
154
- public function getAddress() { return $this->Address; }
155
-
156
- /**
157
- * The casing to apply to the validated address(es).
158
- * <pre>
159
- * <b>Example:</b>
160
- * <b>Example:</b>
161
- * $address = new Address();
162
- * $address->setLine1("900 Winslow Way");
163
- * $address->setCity("Bainbridge Island");
164
- * $address->setRegion("WA");
165
- * $address->setPostalCode("98110");
166
- *
167
- * $validateRequest = new ValidateRequest();
168
- * $validateRequest->setAddress(address);
169
- * $validateRequest->setTextCase(TextCase::$Upper);
170
- *
171
- * $result = svc->validate(validateRequest);
172
- * </pre>
173
- *
174
- * @return string
175
- * @see TextCase
176
- */
177
-
178
- public function getTextCase() { return $this->TextCase; }
179
-
180
- /**
181
- * Returns whether to return the coordinates value for this ValidateRequest.
182
- * <p>
183
- * True will return the @see ValidAddress#Latitude and @see ValidAddress#Longitude values for the @see ValidAddresses
184
- * Default value is <b>false</b>
185
- * </p>
186
- * @return boolean
187
- */
188
-
189
- public function getCoordinates() { return $this->Coordinates; }
190
- }
1
+ <?php
2
+ /**
3
+ * ValidateRequest.class.php
4
+ * @package Address
5
+ */
6
+
7
+ /**
8
+ * Data wrapper used internally to pass arguments within {@link AddressServiceSoap#validate}. End users should not need to use this class.
9
+ *
10
+ * <pre>
11
+ * <b>Example:</b>
12
+ * $svc = new AddressServiceSoap();
13
+ *
14
+ * $address = new Address();
15
+ * $address->setLine1("900 Winslow Way");
16
+ * $address->setCity("Bainbridge Island");
17
+ * $address->setRegion("WA");
18
+ * $address->setPostalCode("98110");
19
+ *
20
+ * ValidateRequest validateRequest = new ValidateRequest();
21
+ * validateRequest.setAddress(address);
22
+ * validateRequest.setTextCase(TextCase.Upper);
23
+ *
24
+ * ValidateResult result = svc.validate(validateRequest);
25
+ * ArrayOfValidAddress arrValids = result.getValidAddresses();
26
+ * int numAddresses = (arrValids == null ||
27
+ * arrValids.getValidAddress() == null ? 0 :
28
+ * arrValids.getValidAddress().length);
29
+ * System.out.println("Number of Addresses is " + numAddresses);
30
+ * </pre>
31
+ *
32
+ * @package Address
33
+ * @author tblanchard
34
+ * Copyright (c) 2006, Avalara. All rights reserved.
35
+ */
36
+
37
+ //public function validate($address, $textCase = 'Default', $coordinates = false)
38
+ //{
39
+ // $request = new ValidateRequest($address, ($textCase ? $textCase : TextCase::$Default), $coordinates);
40
+ // return $this->client->Validate(array('ValidateRequest' => $request))->ValidateResult;
41
+ //}
42
+
43
+
44
+ class ValidateRequest
45
+ {
46
+ private $Address;
47
+ private $TextCase = 'Default';
48
+ private $Coordinates = false;
49
+ private $Taxability=false;
50
+
51
+ public function __construct($address = null, $textCase = 'Default', $coordinates = false)
52
+ {
53
+ $this->setAddress($address);
54
+ $this->setTextCase($textCase);
55
+ $this->setCoordinates($coordinates);
56
+ }
57
+
58
+ // mutators
59
+ /**
60
+ * The address to Validate.
61
+ * <pre>
62
+ * <b>Example:</b>
63
+ * $address = new Address();
64
+ * $address->setLine1("900 Winslow Way");
65
+ * $address->setCity("Bainbridge Island");
66
+ * $address->setRegion("WA");
67
+ * $address->setPostalCode("98110");
68
+ *
69
+ * $validateRequest = new ValidateRequest();
70
+ * $validateRequest->setAddress(address);
71
+ * $validateRequest->setTextCase(TextCase::$Upper);
72
+ *
73
+ * $result = svc->validate(validateRequest);
74
+ * </pre>
75
+ *
76
+ * @var Address
77
+ */
78
+
79
+ public function setAddress(&$value) { $this->Address = $value; return $this; }
80
+
81
+ /**
82
+ * The casing to apply to the validated address(es).
83
+ * <pre>
84
+ * <b>Example:</b>
85
+ * <b>Example:</b>
86
+ * $address = new Address();
87
+ * $address->setLine1("900 Winslow Way");
88
+ * $address->setCity("Bainbridge Island");
89
+ * $address->setRegion("WA");
90
+ * $address->setPostalCode("98110");
91
+ *
92
+ * $validateRequest = new ValidateRequest();
93
+ * $validateRequest->setAddress(address);
94
+ * $validateRequest->setTextCase(TextCase::$Upper);
95
+ *
96
+ * $result = svc->validate(validateRequest);
97
+ * </pre>
98
+ *
99
+ * @var string
100
+ * @see TextCase
101
+ */
102
+
103
+ public function setTextCase($value)
104
+ {
105
+ if($value)
106
+ {
107
+ TextCase::Validate($value);
108
+ $this->TextCase = $value;
109
+ }
110
+ else
111
+ {
112
+ $this->TextCase = TextCase::$Default;
113
+ }
114
+ return $this;
115
+ }
116
+
117
+ /**
118
+ * Sets whether to fetch the coordinates value for this ValidateRequest.
119
+ * <p>
120
+ * True will return the @see ValidAddress#Latitude and @see ValidAddress#Longitude values for the @see ValidAddresses
121
+ * Default value is <b>false</b>
122
+ * </p>
123
+ * @var boolean
124
+ */
125
+ public function setCoordinates($value) { $this->Coordinates = ($value ? true : false); return $this; }
126
+
127
+
128
+ //@author:swetal
129
+ public function setTaxability($value)
130
+ {
131
+ $this->Taxability=$value;
132
+ }
133
+ // accessors
134
+ /**
135
+ * The address to Validate.
136
+ * <pre>
137
+ * <b>Example:</b>
138
+ * $address = new Address();
139
+ * $address->setLine1("900 Winslow Way");
140
+ * $address->setCity("Bainbridge Island");
141
+ * $address->setRegion("WA");
142
+ * $address->setPostalCode("98110");
143
+ *
144
+ * $validateRequest = new ValidateRequest();
145
+ * $validateRequest->setAddress(address);
146
+ * $validateRequest->setTextCase(TextCase::$Upper);
147
+ *
148
+ * $result = svc->validate(validateRequest);
149
+ * </pre>
150
+ *
151
+ * @return Address
152
+ */
153
+
154
+ public function getAddress() { return $this->Address; }
155
+
156
+ /**
157
+ * The casing to apply to the validated address(es).
158
+ * <pre>
159
+ * <b>Example:</b>
160
+ * <b>Example:</b>
161
+ * $address = new Address();
162
+ * $address->setLine1("900 Winslow Way");
163
+ * $address->setCity("Bainbridge Island");
164
+ * $address->setRegion("WA");
165
+ * $address->setPostalCode("98110");
166
+ *
167
+ * $validateRequest = new ValidateRequest();
168
+ * $validateRequest->setAddress(address);
169
+ * $validateRequest->setTextCase(TextCase::$Upper);
170
+ *
171
+ * $result = svc->validate(validateRequest);
172
+ * </pre>
173
+ *
174
+ * @return string
175
+ * @see TextCase
176
+ */
177
+
178
+ public function getTextCase() { return $this->TextCase; }
179
+
180
+ /**
181
+ * Returns whether to return the coordinates value for this ValidateRequest.
182
+ * <p>
183
+ * True will return the @see ValidAddress#Latitude and @see ValidAddress#Longitude values for the @see ValidAddresses
184
+ * Default value is <b>false</b>
185
+ * </p>
186
+ * @return boolean
187
+ */
188
+
189
+ public function getCoordinates() { return $this->Coordinates; }
190
+ }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/ValidateResult.class.php RENAMED
@@ -1,87 +1,87 @@
1
- <?php
2
- /**
3
- * ValidateResult.class.php
4
- *
5
- * @package Address
6
- */
7
-
8
- /**
9
- * Contains an array of {@link ValidAddress} objects returned by {@link AddressServiceSoap#validate}
10
- *
11
- * <pre>
12
- * $port = new AddressServiceSoap();
13
- *
14
- * $address = new Address();
15
- * $address->setLine1("900 Winslow Way");
16
- * $address->setLine2("Suite 130");
17
- * $address->setCity("Bainbridge Is");
18
- * $address->setRegion("WA");
19
- * $address->setPostalCode("98110-2450");
20
- *
21
- * $result = $port->validate($address,TextCase::$Upper);
22
- * $addresses = $result->ValidAddresses;
23
- * print("Number of addresses returned is ". sizeoof($addresses));
24
- *
25
- * </pre>
26
- * @package Address
27
- * @see ValidAddress
28
- * @author tblanchard
29
- * Copyright (c) 2005, Avalara. All rights reserved.
30
- */
31
-
32
-
33
- class ValidateResult// extends BaseResult
34
- {
35
- /**
36
- * Array of matching {@link ValidAddress}'s.
37
- * @var array
38
- */
39
- private $ValidAddresses;
40
-
41
- /**
42
- * Method returning array of matching {@link ValidAddress}'s.
43
- * @return array
44
- */
45
- public function getValidAddresses() { return EnsureIsArray($this->ValidAddresses->ValidAddress); }
46
-
47
-
48
-
49
-
50
-
51
- /**
52
- * @var string
53
- */
54
- private $TransactionId;
55
- /**
56
- * @var string must be one of the values defined in {@link SeverityLevel}.
57
- */
58
- private $ResultCode = 'Success';
59
- /**
60
- * @var array of Message.
61
- */
62
- private $Messages = array();
63
-
64
- /**
65
- * Accessor
66
- * @return string
67
- */
68
- public function getTransactionId() { return $this->TransactionId; }
69
- /**
70
- * Accessor
71
- * @return string
72
- */
73
- public function getResultCode() { return $this->ResultCode; }
74
- /**
75
- * Accessor
76
- * @return array
77
- */
78
- public function getMessages() { return EnsureIsArray($this->Messages->Message); }
79
-
80
- //@author:swetal
81
-
82
- public function isTaxable()
83
- {
84
- return $this->Taxable;
85
- }
86
-
87
  }
1
+ <?php
2
+ /**
3
+ * ValidateResult.class.php
4
+ *
5
+ * @package Address
6
+ */
7
+
8
+ /**
9
+ * Contains an array of {@link ValidAddress} objects returned by {@link AddressServiceSoap#validate}
10
+ *
11
+ * <pre>
12
+ * $port = new AddressServiceSoap();
13
+ *
14
+ * $address = new Address();
15
+ * $address->setLine1("900 Winslow Way");
16
+ * $address->setLine2("Suite 130");
17
+ * $address->setCity("Bainbridge Is");
18
+ * $address->setRegion("WA");
19
+ * $address->setPostalCode("98110-2450");
20
+ *
21
+ * $result = $port->validate($address,TextCase::$Upper);
22
+ * $addresses = $result->ValidAddresses;
23
+ * print("Number of addresses returned is ". sizeoof($addresses));
24
+ *
25
+ * </pre>
26
+ * @package Address
27
+ * @see ValidAddress
28
+ * @author tblanchard
29
+ * Copyright (c) 2005, Avalara. All rights reserved.
30
+ */
31
+
32
+
33
+ class ValidateResult// extends BaseResult
34
+ {
35
+ /**
36
+ * Array of matching {@link ValidAddress}'s.
37
+ * @var array
38
+ */
39
+ private $ValidAddresses;
40
+
41
+ /**
42
+ * Method returning array of matching {@link ValidAddress}'s.
43
+ * @return array
44
+ */
45
+ public function getValidAddresses() { return EnsureIsArray($this->ValidAddresses->ValidAddress); }
46
+
47
+
48
+
49
+
50
+
51
+ /**
52
+ * @var string
53
+ */
54
+ private $TransactionId;
55
+ /**
56
+ * @var string must be one of the values defined in {@link SeverityLevel}.
57
+ */
58
+ private $ResultCode = 'Success';
59
+ /**
60
+ * @var array of Message.
61
+ */
62
+ private $Messages = array();
63
+
64
+ /**
65
+ * Accessor
66
+ * @return string
67
+ */
68
+ public function getTransactionId() { return $this->TransactionId; }
69
+ /**
70
+ * Accessor
71
+ * @return string
72
+ */
73
+ public function getResultCode() { return $this->ResultCode; }
74
+ /**
75
+ * Accessor
76
+ * @return array
77
+ */
78
+ public function getMessages() { return EnsureIsArray($this->Messages->Message); }
79
+
80
+ //@author:swetal
81
+
82
+ public function isTaxable()
83
+ {
84
+ return $this->Taxable;
85
+ }
86
+
87
  }
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/wsdl/Address.wsdl RENAMED
@@ -1,512 +1,512 @@
1
- <?xml version="1.0" encoding="utf-8"?>
2
- <wsdl:definitions xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:tm="http://microsoft.com/wsdl/mime/textMatching/" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/" xmlns:tns="http://avatax.avalara.com/services" xmlns:s="http://www.w3.org/2001/XMLSchema" xmlns:soap12="http://schemas.xmlsoap.org/wsdl/soap12/" xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" targetNamespace="http://avatax.avalara.com/services" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">
3
- <wsdl:types>
4
- <s:schema elementFormDefault="qualified" targetNamespace="http://avatax.avalara.com/services">
5
- <s:element name="Validate">
6
- <s:complexType>
7
- <s:sequence>
8
- <s:element minOccurs="0" maxOccurs="1" name="ValidateRequest" type="tns:ValidateRequest" />
9
- </s:sequence>
10
- </s:complexType>
11
- </s:element>
12
- <s:complexType name="BaseRequest" />
13
- <s:complexType name="ValidateRequest">
14
- <s:complexContent mixed="false">
15
- <s:extension base="tns:BaseRequest">
16
- <s:sequence>
17
- <s:element minOccurs="0" maxOccurs="1" name="Address" type="tns:BaseAddress" />
18
- <s:element minOccurs="1" maxOccurs="1" name="TextCase" type="tns:TextCase" />
19
- <s:element minOccurs="1" maxOccurs="1" name="Coordinates" type="s:boolean" />
20
- <s:element minOccurs="1" maxOccurs="1" name="Taxability" type="s:boolean" />
21
- </s:sequence>
22
- </s:extension>
23
- </s:complexContent>
24
- </s:complexType>
25
- <s:complexType name="BaseAddress">
26
- <s:sequence>
27
- <s:element minOccurs="0" maxOccurs="1" name="AddressCode" type="s:string" />
28
- <s:element minOccurs="0" maxOccurs="1" name="Line1" type="s:string" />
29
- <s:element minOccurs="0" maxOccurs="1" name="Line2" type="s:string" />
30
- <s:element minOccurs="0" maxOccurs="1" name="Line3" type="s:string" />
31
- <s:element minOccurs="0" maxOccurs="1" name="City" type="s:string" />
32
- <s:element minOccurs="0" maxOccurs="1" name="Region" type="s:string" />
33
- <s:element minOccurs="0" maxOccurs="1" name="PostalCode" type="s:string" />
34
- <s:element minOccurs="0" maxOccurs="1" name="Country" type="s:string" />
35
- <s:element minOccurs="1" maxOccurs="1" name="TaxRegionId" type="s:int" />
36
- </s:sequence>
37
- </s:complexType>
38
- <s:complexType name="ValidAddress">
39
- <s:complexContent mixed="false">
40
- <s:extension base="tns:BaseAddress">
41
- <s:sequence>
42
- <s:element minOccurs="0" maxOccurs="1" name="Line4" type="s:string" />
43
- <s:element minOccurs="0" maxOccurs="1" name="County" type="s:string" />
44
- <s:element minOccurs="0" maxOccurs="1" name="FipsCode" type="s:string" />
45
- <s:element minOccurs="0" maxOccurs="1" name="CarrierRoute" type="s:string" />
46
- <s:element minOccurs="0" maxOccurs="1" name="PostNet" type="s:string" />
47
- <s:element minOccurs="0" maxOccurs="1" name="AddressType" type="s:string" />
48
- <s:element minOccurs="0" maxOccurs="1" name="Latitude" type="s:string" />
49
- <s:element minOccurs="0" maxOccurs="1" name="Longitude" type="s:string" />
50
- </s:sequence>
51
- </s:extension>
52
- </s:complexContent>
53
- </s:complexType>
54
- <s:simpleType name="TextCase">
55
- <s:restriction base="s:string">
56
- <s:enumeration value="Default" />
57
- <s:enumeration value="Upper" />
58
- <s:enumeration value="Mixed" />
59
- </s:restriction>
60
- </s:simpleType>
61
- <s:element name="ValidateResponse">
62
- <s:complexType>
63
- <s:sequence>
64
- <s:element minOccurs="0" maxOccurs="1" name="ValidateResult" type="tns:ValidateResult" />
65
- </s:sequence>
66
- </s:complexType>
67
- </s:element>
68
- <s:complexType name="ValidateResult">
69
- <s:complexContent mixed="false">
70
- <s:extension base="tns:BaseResult">
71
- <s:sequence>
72
- <s:element minOccurs="0" maxOccurs="1" name="ValidAddresses" type="tns:ArrayOfValidAddress" />
73
- <s:element minOccurs="1" maxOccurs="1" name="Taxable" type="s:boolean" />
74
- </s:sequence>
75
- </s:extension>
76
- </s:complexContent>
77
- </s:complexType>
78
-
79
- <!-- Begin New Methods-->
80
- <s:element name="SubmitBatch">
81
- <s:complexType>
82
- <s:sequence>
83
- <s:element minOccurs="0" maxOccurs="1" name="SubmitAddressBatchRequest" type="tns:SubmitAddressBatchRequest" />
84
- </s:sequence>
85
- </s:complexType>
86
- </s:element>
87
- <s:complexType name="SubmitAddressBatchRequest">
88
- <s:complexContent mixed="false">
89
- <s:extension base="tns:BaseRequest">
90
- <s:sequence>
91
- <s:element minOccurs="0" maxOccurs="1" name="Requests" type="tns:AddressRequestList" />
92
- </s:sequence>
93
- </s:extension>
94
- </s:complexContent>
95
- </s:complexType>
96
- <s:complexType name="AddressRequestList">
97
- <s:choice minOccurs="0" maxOccurs="unbounded">
98
- <s:element name="ValidateRequest" nillable="true" type="tns:ValidateRequest" />
99
- </s:choice>
100
- </s:complexType>
101
- <s:element name="SubmitBatchResponse">
102
- <s:complexType>
103
- <s:sequence>
104
- <s:element minOccurs="0" maxOccurs="1" name="SubmitBatchResult" type="tns:SubmitAddressBatchResult" />
105
- </s:sequence>
106
- </s:complexType>
107
- </s:element>
108
- <s:complexType name="SubmitAddressBatchResult">
109
- <s:complexContent mixed="false">
110
- <s:extension base="tns:BaseResult">
111
- <s:sequence>
112
- <s:element minOccurs="0" maxOccurs="1" name="BatchId" type="s:string" />
113
- </s:sequence>
114
- </s:extension>
115
- </s:complexContent>
116
- </s:complexType>
117
-
118
- <s:element name="GetBatch">
119
- <s:complexType>
120
- <s:sequence>
121
- <s:element minOccurs="0" maxOccurs="1" name="GetAddressBatchRequest" type="tns:GetAddressBatchRequest" />
122
- </s:sequence>
123
- </s:complexType>
124
- </s:element>
125
- <s:complexType name="GetAddressBatchRequest">
126
- <s:complexContent mixed="false">
127
- <s:extension base="tns:BaseRequest">
128
- <s:sequence>
129
- <s:element minOccurs="1" maxOccurs="1" name="BatchId" type="s:string" />
130
- </s:sequence>
131
- </s:extension>
132
- </s:complexContent>
133
- </s:complexType>
134
- <s:element name="GetBatchResponse">
135
- <s:complexType>
136
- <s:sequence>
137
- <s:element minOccurs="0" maxOccurs="1" name="GetBatchResult" type="tns:GetAddressBatchResult" />
138
- </s:sequence>
139
- </s:complexType>
140
- </s:element>
141
- <s:complexType name="GetAddressBatchResult">
142
- <s:complexContent mixed="false">
143
- <s:extension base="tns:BaseResult">
144
- <s:sequence>
145
- <s:element minOccurs="1" maxOccurs="1" name="BatchId" type="s:string" />
146
- <s:element minOccurs="1" maxOccurs="1" name="BatchStatus" type="s:string" />
147
- <s:element minOccurs="1" maxOccurs="1" name="RecordCount" type="s:int" />
148
- <s:element minOccurs="1" maxOccurs="1" name="CurrentRecord" type="s:int" />
149
- <s:element minOccurs="0" maxOccurs="1" name="Results" type="tns:AddressResultList" />
150
- </s:sequence>
151
- </s:extension>
152
- </s:complexContent>
153
- </s:complexType>
154
- <s:complexType name="AddressResultList">
155
- <s:choice minOccurs="0" maxOccurs="unbounded">
156
- <s:element name="ValidateResult" nillable="true" type="tns:ValidateResult" />
157
- </s:choice>
158
- </s:complexType>
159
-
160
- <s:element name="CancelBatch">
161
- <s:complexType>
162
- <s:sequence>
163
- <s:element minOccurs="0" maxOccurs="1" name="CancelAddressBatchRequest" type="tns:CancelAddressBatchRequest" />
164
- </s:sequence>
165
- </s:complexType>
166
- </s:element>
167
- <s:complexType name="CancelAddressBatchRequest">
168
- <s:complexContent mixed="false">
169
- <s:extension base="tns:BaseRequest">
170
- <s:sequence>
171
- <s:element minOccurs="1" maxOccurs="1" name="BatchId" type="s:string" />
172
- </s:sequence>
173
- </s:extension>
174
- </s:complexContent>
175
- </s:complexType>
176
- <s:element name="CancelBatchResponse">
177
- <s:complexType>
178
- <s:sequence>
179
- <s:element minOccurs="0" maxOccurs="1" name="CancelBatchResult" type="tns:CancelAddressBatchResult" />
180
- </s:sequence>
181
- </s:complexType>
182
- </s:element>
183
- <s:complexType name="CancelAddressBatchResult">
184
- <s:complexContent mixed="false">
185
- <s:extension base="tns:BaseResult" />
186
- </s:complexContent>
187
- </s:complexType>
188
- <!-- End New Methods -->
189
-
190
- <s:complexType name="BaseResult">
191
- <s:sequence>
192
- <s:element minOccurs="0" maxOccurs="1" name="TransactionId" type="s:string" />
193
- <s:element minOccurs="1" maxOccurs="1" name="ResultCode" type="tns:SeverityLevel" />
194
- <s:element minOccurs="0" maxOccurs="1" name="Messages" type="tns:ArrayOfMessage" />
195
- </s:sequence>
196
- </s:complexType>
197
- <s:simpleType name="SeverityLevel">
198
- <s:restriction base="s:string">
199
- <s:enumeration value="Success" />
200
- <s:enumeration value="Warning" />
201
- <s:enumeration value="Error" />
202
- <s:enumeration value="Exception" />
203
- </s:restriction>
204
- </s:simpleType>
205
- <s:complexType name="ArrayOfMessage">
206
- <s:sequence>
207
- <s:element minOccurs="0" maxOccurs="unbounded" name="Message" nillable="true" type="tns:Message" />
208
- </s:sequence>
209
- </s:complexType>
210
- <s:complexType name="Message">
211
- <s:sequence>
212
- <s:element minOccurs="0" maxOccurs="1" name="Summary" type="s:string" />
213
- <s:element minOccurs="0" maxOccurs="1" name="Details" type="s:string" />
214
- <s:element minOccurs="0" maxOccurs="1" name="HelpLink" type="s:string" />
215
- <s:element minOccurs="0" maxOccurs="1" name="RefersTo" type="s:string" />
216
- <s:element minOccurs="1" maxOccurs="1" name="Severity" type="tns:SeverityLevel" />
217
- <s:element minOccurs="0" maxOccurs="1" name="Source" type="s:string" />
218
- </s:sequence>
219
- <s:attribute name="Name" type="s:string" />
220
- </s:complexType>
221
- <s:complexType name="ArrayOfValidAddress">
222
- <s:sequence>
223
- <s:element minOccurs="0" maxOccurs="unbounded" name="ValidAddress" nillable="true" type="tns:ValidAddress" />
224
- </s:sequence>
225
- </s:complexType>
226
- <s:element name="Profile" type="tns:Profile" />
227
- <s:complexType name="Profile">
228
- <s:sequence>
229
- <s:element minOccurs="0" maxOccurs="1" name="Name" type="s:string" />
230
- <s:element minOccurs="0" maxOccurs="1" name="Client" type="s:string" />
231
- <s:element minOccurs="0" maxOccurs="1" name="Adapter" type="s:string" />
232
- <s:element minOccurs="0" maxOccurs="1" name="Machine" type="s:string" />
233
- </s:sequence>
234
- <s:anyAttribute />
235
- </s:complexType>
236
-
237
- <s:element name="Ping">
238
- <s:complexType>
239
- <s:sequence>
240
- <s:element minOccurs="0" maxOccurs="1" name="Message" type="s:string" />
241
- </s:sequence>
242
- </s:complexType>
243
- </s:element>
244
- <s:element name="PingResponse">
245
- <s:complexType>
246
- <s:sequence>
247
- <s:element minOccurs="0" maxOccurs="1" name="PingResult" type="tns:PingResult" />
248
- </s:sequence>
249
- </s:complexType>
250
- </s:element>
251
- <s:complexType name="PingResult">
252
- <s:complexContent mixed="false">
253
- <s:extension base="tns:BaseResult">
254
- <s:sequence>
255
- <s:element minOccurs="0" maxOccurs="1" name="Version" type="s:string" />
256
- </s:sequence>
257
- </s:extension>
258
- </s:complexContent>
259
- </s:complexType>
260
- <s:element name="IsAuthorized">
261
- <s:complexType>
262
- <s:sequence>
263
- <s:element minOccurs="0" maxOccurs="1" name="Operations" type="s:string" />
264
- </s:sequence>
265
- </s:complexType>
266
- </s:element>
267
- <s:element name="IsAuthorizedResponse">
268
- <s:complexType>
269
- <s:sequence>
270
- <s:element minOccurs="0" maxOccurs="1" name="IsAuthorizedResult" type="tns:IsAuthorizedResult" />
271
- </s:sequence>
272
- </s:complexType>
273
- </s:element>
274
- <s:complexType name="IsAuthorizedResult">
275
- <s:complexContent mixed="false">
276
- <s:extension base="tns:BaseResult">
277
- <s:sequence>
278
- <s:element minOccurs="0" maxOccurs="1" name="Operations" type="s:string" />
279
- <s:element minOccurs="1" maxOccurs="1" name="Expires" type="s:dateTime" />
280
- </s:sequence>
281
- </s:extension>
282
- </s:complexContent>
283
- </s:complexType>
284
- </s:schema>
285
- </wsdl:types>
286
- <wsdl:message name="ValidateSoapIn">
287
- <wsdl:part name="parameters" element="tns:Validate" />
288
- </wsdl:message>
289
- <wsdl:message name="ValidateSoapOut">
290
- <wsdl:part name="parameters" element="tns:ValidateResponse" />
291
- </wsdl:message>
292
- <wsdl:message name="ValidateProfile">
293
- <wsdl:part name="Profile" element="tns:Profile" />
294
- </wsdl:message>
295
- <wsdl:message name="PingSoapIn">
296
- <wsdl:part name="parameters" element="tns:Ping" />
297
- </wsdl:message>
298
- <wsdl:message name="PingSoapOut">
299
- <wsdl:part name="parameters" element="tns:PingResponse" />
300
- </wsdl:message>
301
- <wsdl:message name="PingProfile">
302
- <wsdl:part name="Profile" element="tns:Profile" />
303
- </wsdl:message>
304
- <wsdl:message name="IsAuthorizedSoapIn">
305
- <wsdl:part name="parameters" element="tns:IsAuthorized" />
306
- </wsdl:message>
307
- <wsdl:message name="IsAuthorizedSoapOut">
308
- <wsdl:part name="parameters" element="tns:IsAuthorizedResponse" />
309
- </wsdl:message>
310
- <wsdl:message name="IsAuthorizedProfile">
311
- <wsdl:part name="Profile" element="tns:Profile" />
312
- </wsdl:message>
313
- <!--New Methods Begin-->
314
- <wsdl:message name="SubmitBatchSoapIn">
315
- <wsdl:part name="parameters" element="tns:SubmitBatch" />
316
- </wsdl:message>
317
- <wsdl:message name="SubmitBatchSoapOut">
318
- <wsdl:part name="parameters" element="tns:SubmitBatchResponse" />
319
- </wsdl:message>
320
- <wsdl:message name="SubmitBatchProfile">
321
- <wsdl:part name="Profile" element="tns:Profile" />
322
- </wsdl:message>
323
- <wsdl:message name="GetBatchSoapIn">
324
- <wsdl:part name="parameters" element="tns:GetBatch" />
325
- </wsdl:message>
326
- <wsdl:message name="GetBatchSoapOut">
327
- <wsdl:part name="parameters" element="tns:GetBatchResponse" />
328
- </wsdl:message>
329
- <wsdl:message name="GetBatchProfile">
330
- <wsdl:part name="Profile" element="tns:Profile" />
331
- </wsdl:message>
332
- <wsdl:message name="CancelBatchSoapIn">
333
- <wsdl:part name="parameters" element="tns:CancelBatch" />
334
- </wsdl:message>
335
- <wsdl:message name="CancelBatchSoapOut">
336
- <wsdl:part name="parameters" element="tns:CancelBatchResponse" />
337
- </wsdl:message>
338
- <wsdl:message name="CancelBatchProfile">
339
- <wsdl:part name="Profile" element="tns:Profile" />
340
- </wsdl:message>
341
- <!--New Methods End-->
342
- <wsdl:portType name="AddressSvcSoap">
343
- <wsdl:operation name="Validate">
344
- <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Validate an Address</wsdl:documentation>
345
- <wsdl:input message="tns:ValidateSoapIn" />
346
- <wsdl:output message="tns:ValidateSoapOut" />
347
- </wsdl:operation>
348
- <wsdl:operation name="SubmitBatch">
349
- <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Submits a batch of AddressSvc requests to be processed.</wsdl:documentation>
350
- <wsdl:input message="tns:SubmitBatchSoapIn" />
351
- <wsdl:output message="tns:SubmitBatchSoapOut" />
352
- </wsdl:operation>
353
- <wsdl:operation name="GetBatch">
354
- <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Gets the status and results of a submitted batch.</wsdl:documentation>
355
- <wsdl:input message="tns:GetBatchSoapIn" />
356
- <wsdl:output message="tns:GetBatchSoapOut" />
357
- </wsdl:operation>
358
- <wsdl:operation name="CancelBatch">
359
- <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Cancels an incomplete batch operation.</wsdl:documentation>
360
- <wsdl:input message="tns:CancelBatchSoapIn" />
361
- <wsdl:output message="tns:CancelBatchSoapOut" />
362
- </wsdl:operation>
363
- <wsdl:operation name="Ping">
364
- <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Tests connectivity and version of the service</wsdl:documentation>
365
- <wsdl:input message="tns:PingSoapIn" />
366
- <wsdl:output message="tns:PingSoapOut" />
367
- </wsdl:operation>
368
- <wsdl:operation name="IsAuthorized">
369
- <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Checks authentication and authorization to one or more operations on the service.</wsdl:documentation>
370
- <wsdl:input message="tns:IsAuthorizedSoapIn" />
371
- <wsdl:output message="tns:IsAuthorizedSoapOut" />
372
- </wsdl:operation>
373
- </wsdl:portType>
374
- <wsdl:binding name="AddressSvcSoap" type="tns:AddressSvcSoap">
375
- <soap:binding transport="http://schemas.xmlsoap.org/soap/http" />
376
- <wsdl:operation name="Validate">
377
- <soap:operation soapAction="http://avatax.avalara.com/services/Validate" style="document" />
378
- <wsdl:input>
379
- <soap:body use="literal" />
380
- <soap:header message="tns:ValidateProfile" part="Profile" use="literal" />
381
- </wsdl:input>
382
- <wsdl:output>
383
- <soap:body use="literal" />
384
- </wsdl:output>
385
- </wsdl:operation>
386
- <!--New Methods Begin-->
387
- <wsdl:operation name="SubmitBatch">
388
- <soap:operation soapAction="http://avatax.avalara.com/services/SubmitBatch" style="document" />
389
- <wsdl:input>
390
- <soap:body use="literal" />
391
- <soap:header message="tns:SubmitBatchProfile" part="Profile" use="literal" />
392
- </wsdl:input>
393
- <wsdl:output>
394
- <soap:body use="literal" />
395
- </wsdl:output>
396
- </wsdl:operation>
397
- <wsdl:operation name="GetBatch">
398
- <soap:operation soapAction="http://avatax.avalara.com/services/GetBatch" style="document" />
399
- <wsdl:input>
400
- <soap:body use="literal" />
401
- <soap:header message="tns:GetBatchProfile" part="Profile" use="literal" />
402
- </wsdl:input>
403
- <wsdl:output>
404
- <soap:body use="literal" />
405
- </wsdl:output>
406
- </wsdl:operation>
407
- <wsdl:operation name="CancelBatch">
408
- <soap:operation soapAction="http://avatax.avalara.com/services/CancelBatch" style="document" />
409
- <wsdl:input>
410
- <soap:body use="literal" />
411
- <soap:header message="tns:CancelBatchProfile" part="Profile" use="literal" />
412
- </wsdl:input>
413
- <wsdl:output>
414
- <soap:body use="literal" />
415
- </wsdl:output>
416
- </wsdl:operation>
417
- <!--New Methods End-->
418
- <wsdl:operation name="Ping">
419
- <soap:operation soapAction="http://avatax.avalara.com/services/Ping" style="document" />
420
- <wsdl:input>
421
- <soap:body use="literal" />
422
- <soap:header message="tns:PingProfile" part="Profile" use="literal" />
423
- </wsdl:input>
424
- <wsdl:output>
425
- <soap:body use="literal" />
426
- </wsdl:output>
427
- </wsdl:operation>
428
- <wsdl:operation name="IsAuthorized">
429
- <soap:operation soapAction="http://avatax.avalara.com/services/IsAuthorized" style="document" />
430
- <wsdl:input>
431
- <soap:body use="literal" />
432
- <soap:header message="tns:IsAuthorizedProfile" part="Profile" use="literal" />
433
- </wsdl:input>
434
- <wsdl:output>
435
- <soap:body use="literal" />
436
- </wsdl:output>
437
- </wsdl:operation>
438
- </wsdl:binding>
439
- <wsdl:binding name="AddressSvcSoap12" type="tns:AddressSvcSoap">
440
- <soap12:binding transport="http://schemas.xmlsoap.org/soap/http" />
441
- <wsdl:operation name="Validate">
442
- <soap12:operation soapAction="http://avatax.avalara.com/services/Validate" style="document" />
443
- <wsdl:input>
444
- <soap12:body use="literal" />
445
- <soap12:header message="tns:ValidateProfile" part="Profile" use="literal" />
446
- </wsdl:input>
447
- <wsdl:output>
448
- <soap12:body use="literal" />
449
- </wsdl:output>
450
- </wsdl:operation>
451
- <wsdl:operation name="Ping">
452
- <soap12:operation soapAction="http://avatax.avalara.com/services/Ping" style="document" />
453
- <wsdl:input>
454
- <soap12:body use="literal" />
455
- <soap12:header message="tns:PingProfile" part="Profile" use="literal" />
456
- </wsdl:input>
457
- <wsdl:output>
458
- <soap12:body use="literal" />
459
- </wsdl:output>
460
- </wsdl:operation>
461
- <wsdl:operation name="IsAuthorized">
462
- <soap12:operation soapAction="http://avatax.avalara.com/services/IsAuthorized" style="document" />
463
- <wsdl:input>
464
- <soap12:body use="literal" />
465
- <soap12:header message="tns:IsAuthorizedProfile" part="Profile" use="literal" />
466
- </wsdl:input>
467
- <wsdl:output>
468
- <soap12:body use="literal" />
469
- </wsdl:output>
470
- </wsdl:operation>
471
- <!--New Methods Begin-->
472
- <wsdl:operation name="SubmitBatch">
473
- <soap12:operation soapAction="http://avatax.avalara.com/services/SubmitBatch" style="document" />
474
- <wsdl:input>
475
- <soap12:body use="literal" />
476
- <soap12:header message="tns:SubmitBatchProfile" part="Profile" use="literal" />
477
- </wsdl:input>
478
- <wsdl:output>
479
- <soap12:body use="literal" />
480
- </wsdl:output>
481
- </wsdl:operation>
482
- <wsdl:operation name="GetBatch">
483
- <soap12:operation soapAction="http://avatax.avalara.com/services/GetBatch" style="document" />
484
- <wsdl:input>
485
- <soap12:body use="literal" />
486
- <soap12:header message="tns:GetBatchProfile" part="Profile" use="literal" />
487
- </wsdl:input>
488
- <wsdl:output>
489
- <soap12:body use="literal" />
490
- </wsdl:output>
491
- </wsdl:operation>
492
- <wsdl:operation name="CancelBatch">
493
- <soap12:operation soapAction="http://avatax.avalara.com/services/CancelBatch" style="document" />
494
- <wsdl:input>
495
- <soap12:body use="literal" />
496
- <soap12:header message="tns:CancelBatchProfile" part="Profile" use="literal" />
497
- </wsdl:input>
498
- <wsdl:output>
499
- <soap12:body use="literal" />
500
- </wsdl:output>
501
- </wsdl:operation>
502
- <!--New Methods End-->
503
- </wsdl:binding>
504
- <wsdl:service name="AddressSvc">
505
- <wsdl:port name="AddressSvcSoap" binding="tns:AddressSvcSoap">
506
- <soap:address location="http://localhost/avatax.services/Address/AddressSvc.asmx" />
507
- </wsdl:port>
508
- <wsdl:port name="AddressSvcSoap12" binding="tns:AddressSvcSoap12">
509
- <soap12:address location="http://localhost/avatax.services/Address/AddressSvc.asmx" />
510
- </wsdl:port>
511
- </wsdl:service>
512
  </wsdl:definitions>
1
+ <?xml version="1.0" encoding="utf-8"?>
2
+ <wsdl:definitions xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:tm="http://microsoft.com/wsdl/mime/textMatching/" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/" xmlns:tns="http://avatax.avalara.com/services" xmlns:s="http://www.w3.org/2001/XMLSchema" xmlns:soap12="http://schemas.xmlsoap.org/wsdl/soap12/" xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" targetNamespace="http://avatax.avalara.com/services" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">
3
+ <wsdl:types>
4
+ <s:schema elementFormDefault="qualified" targetNamespace="http://avatax.avalara.com/services">
5
+ <s:element name="Validate">
6
+ <s:complexType>
7
+ <s:sequence>
8
+ <s:element minOccurs="0" maxOccurs="1" name="ValidateRequest" type="tns:ValidateRequest" />
9
+ </s:sequence>
10
+ </s:complexType>
11
+ </s:element>
12
+ <s:complexType name="BaseRequest" />
13
+ <s:complexType name="ValidateRequest">
14
+ <s:complexContent mixed="false">
15
+ <s:extension base="tns:BaseRequest">
16
+ <s:sequence>
17
+ <s:element minOccurs="0" maxOccurs="1" name="Address" type="tns:BaseAddress" />
18
+ <s:element minOccurs="1" maxOccurs="1" name="TextCase" type="tns:TextCase" />
19
+ <s:element minOccurs="1" maxOccurs="1" name="Coordinates" type="s:boolean" />
20
+ <s:element minOccurs="1" maxOccurs="1" name="Taxability" type="s:boolean" />
21
+ </s:sequence>
22
+ </s:extension>
23
+ </s:complexContent>
24
+ </s:complexType>
25
+ <s:complexType name="BaseAddress">
26
+ <s:sequence>
27
+ <s:element minOccurs="0" maxOccurs="1" name="AddressCode" type="s:string" />
28
+ <s:element minOccurs="0" maxOccurs="1" name="Line1" type="s:string" />
29
+ <s:element minOccurs="0" maxOccurs="1" name="Line2" type="s:string" />
30
+ <s:element minOccurs="0" maxOccurs="1" name="Line3" type="s:string" />
31
+ <s:element minOccurs="0" maxOccurs="1" name="City" type="s:string" />
32
+ <s:element minOccurs="0" maxOccurs="1" name="Region" type="s:string" />
33
+ <s:element minOccurs="0" maxOccurs="1" name="PostalCode" type="s:string" />
34
+ <s:element minOccurs="0" maxOccurs="1" name="Country" type="s:string" />
35
+ <s:element minOccurs="1" maxOccurs="1" name="TaxRegionId" type="s:int" />
36
+ </s:sequence>
37
+ </s:complexType>
38
+ <s:complexType name="ValidAddress">
39
+ <s:complexContent mixed="false">
40
+ <s:extension base="tns:BaseAddress">
41
+ <s:sequence>
42
+ <s:element minOccurs="0" maxOccurs="1" name="Line4" type="s:string" />
43
+ <s:element minOccurs="0" maxOccurs="1" name="County" type="s:string" />
44
+ <s:element minOccurs="0" maxOccurs="1" name="FipsCode" type="s:string" />
45
+ <s:element minOccurs="0" maxOccurs="1" name="CarrierRoute" type="s:string" />
46
+ <s:element minOccurs="0" maxOccurs="1" name="PostNet" type="s:string" />
47
+ <s:element minOccurs="0" maxOccurs="1" name="AddressType" type="s:string" />
48
+ <s:element minOccurs="0" maxOccurs="1" name="Latitude" type="s:string" />
49
+ <s:element minOccurs="0" maxOccurs="1" name="Longitude" type="s:string" />
50
+ </s:sequence>
51
+ </s:extension>
52
+ </s:complexContent>
53
+ </s:complexType>
54
+ <s:simpleType name="TextCase">
55
+ <s:restriction base="s:string">
56
+ <s:enumeration value="Default" />
57
+ <s:enumeration value="Upper" />
58
+ <s:enumeration value="Mixed" />
59
+ </s:restriction>
60
+ </s:simpleType>
61
+ <s:element name="ValidateResponse">
62
+ <s:complexType>
63
+ <s:sequence>
64
+ <s:element minOccurs="0" maxOccurs="1" name="ValidateResult" type="tns:ValidateResult" />
65
+ </s:sequence>
66
+ </s:complexType>
67
+ </s:element>
68
+ <s:complexType name="ValidateResult">
69
+ <s:complexContent mixed="false">
70
+ <s:extension base="tns:BaseResult">
71
+ <s:sequence>
72
+ <s:element minOccurs="0" maxOccurs="1" name="ValidAddresses" type="tns:ArrayOfValidAddress" />
73
+ <s:element minOccurs="1" maxOccurs="1" name="Taxable" type="s:boolean" />
74
+ </s:sequence>
75
+ </s:extension>
76
+ </s:complexContent>
77
+ </s:complexType>
78
+
79
+ <!-- Begin New Methods-->
80
+ <s:element name="SubmitBatch">
81
+ <s:complexType>
82
+ <s:sequence>
83
+ <s:element minOccurs="0" maxOccurs="1" name="SubmitAddressBatchRequest" type="tns:SubmitAddressBatchRequest" />
84
+ </s:sequence>
85
+ </s:complexType>
86
+ </s:element>
87
+ <s:complexType name="SubmitAddressBatchRequest">
88
+ <s:complexContent mixed="false">
89
+ <s:extension base="tns:BaseRequest">
90
+ <s:sequence>
91
+ <s:element minOccurs="0" maxOccurs="1" name="Requests" type="tns:AddressRequestList" />
92
+ </s:sequence>
93
+ </s:extension>
94
+ </s:complexContent>
95
+ </s:complexType>
96
+ <s:complexType name="AddressRequestList">
97
+ <s:choice minOccurs="0" maxOccurs="unbounded">
98
+ <s:element name="ValidateRequest" nillable="true" type="tns:ValidateRequest" />
99
+ </s:choice>
100
+ </s:complexType>
101
+ <s:element name="SubmitBatchResponse">
102
+ <s:complexType>
103
+ <s:sequence>
104
+ <s:element minOccurs="0" maxOccurs="1" name="SubmitBatchResult" type="tns:SubmitAddressBatchResult" />
105
+ </s:sequence>
106
+ </s:complexType>
107
+ </s:element>
108
+ <s:complexType name="SubmitAddressBatchResult">
109
+ <s:complexContent mixed="false">
110
+ <s:extension base="tns:BaseResult">
111
+ <s:sequence>
112
+ <s:element minOccurs="0" maxOccurs="1" name="BatchId" type="s:string" />
113
+ </s:sequence>
114
+ </s:extension>
115
+ </s:complexContent>
116
+ </s:complexType>
117
+
118
+ <s:element name="GetBatch">
119
+ <s:complexType>
120
+ <s:sequence>
121
+ <s:element minOccurs="0" maxOccurs="1" name="GetAddressBatchRequest" type="tns:GetAddressBatchRequest" />
122
+ </s:sequence>
123
+ </s:complexType>
124
+ </s:element>
125
+ <s:complexType name="GetAddressBatchRequest">
126
+ <s:complexContent mixed="false">
127
+ <s:extension base="tns:BaseRequest">
128
+ <s:sequence>
129
+ <s:element minOccurs="1" maxOccurs="1" name="BatchId" type="s:string" />
130
+ </s:sequence>
131
+ </s:extension>
132
+ </s:complexContent>
133
+ </s:complexType>
134
+ <s:element name="GetBatchResponse">
135
+ <s:complexType>
136
+ <s:sequence>
137
+ <s:element minOccurs="0" maxOccurs="1" name="GetBatchResult" type="tns:GetAddressBatchResult" />
138
+ </s:sequence>
139
+ </s:complexType>
140
+ </s:element>
141
+ <s:complexType name="GetAddressBatchResult">
142
+ <s:complexContent mixed="false">
143
+ <s:extension base="tns:BaseResult">
144
+ <s:sequence>
145
+ <s:element minOccurs="1" maxOccurs="1" name="BatchId" type="s:string" />
146
+ <s:element minOccurs="1" maxOccurs="1" name="BatchStatus" type="s:string" />
147
+ <s:element minOccurs="1" maxOccurs="1" name="RecordCount" type="s:int" />
148
+ <s:element minOccurs="1" maxOccurs="1" name="CurrentRecord" type="s:int" />
149
+ <s:element minOccurs="0" maxOccurs="1" name="Results" type="tns:AddressResultList" />
150
+ </s:sequence>
151
+ </s:extension>
152
+ </s:complexContent>
153
+ </s:complexType>
154
+ <s:complexType name="AddressResultList">
155
+ <s:choice minOccurs="0" maxOccurs="unbounded">
156
+ <s:element name="ValidateResult" nillable="true" type="tns:ValidateResult" />
157
+ </s:choice>
158
+ </s:complexType>
159
+
160
+ <s:element name="CancelBatch">
161
+ <s:complexType>
162
+ <s:sequence>
163
+ <s:element minOccurs="0" maxOccurs="1" name="CancelAddressBatchRequest" type="tns:CancelAddressBatchRequest" />
164
+ </s:sequence>
165
+ </s:complexType>
166
+ </s:element>
167
+ <s:complexType name="CancelAddressBatchRequest">
168
+ <s:complexContent mixed="false">
169
+ <s:extension base="tns:BaseRequest">
170
+ <s:sequence>
171
+ <s:element minOccurs="1" maxOccurs="1" name="BatchId" type="s:string" />
172
+ </s:sequence>
173
+ </s:extension>
174
+ </s:complexContent>
175
+ </s:complexType>
176
+ <s:element name="CancelBatchResponse">
177
+ <s:complexType>
178
+ <s:sequence>
179
+ <s:element minOccurs="0" maxOccurs="1" name="CancelBatchResult" type="tns:CancelAddressBatchResult" />
180
+ </s:sequence>
181
+ </s:complexType>
182
+ </s:element>
183
+ <s:complexType name="CancelAddressBatchResult">
184
+ <s:complexContent mixed="false">
185
+ <s:extension base="tns:BaseResult" />
186
+ </s:complexContent>
187
+ </s:complexType>
188
+ <!-- End New Methods -->
189
+
190
+ <s:complexType name="BaseResult">
191
+ <s:sequence>
192
+ <s:element minOccurs="0" maxOccurs="1" name="TransactionId" type="s:string" />
193
+ <s:element minOccurs="1" maxOccurs="1" name="ResultCode" type="tns:SeverityLevel" />
194
+ <s:element minOccurs="0" maxOccurs="1" name="Messages" type="tns:ArrayOfMessage" />
195
+ </s:sequence>
196
+ </s:complexType>
197
+ <s:simpleType name="SeverityLevel">
198
+ <s:restriction base="s:string">
199
+ <s:enumeration value="Success" />
200
+ <s:enumeration value="Warning" />
201
+ <s:enumeration value="Error" />
202
+ <s:enumeration value="Exception" />
203
+ </s:restriction>
204
+ </s:simpleType>
205
+ <s:complexType name="ArrayOfMessage">
206
+ <s:sequence>
207
+ <s:element minOccurs="0" maxOccurs="unbounded" name="Message" nillable="true" type="tns:Message" />
208
+ </s:sequence>
209
+ </s:complexType>
210
+ <s:complexType name="Message">
211
+ <s:sequence>
212
+ <s:element minOccurs="0" maxOccurs="1" name="Summary" type="s:string" />
213
+ <s:element minOccurs="0" maxOccurs="1" name="Details" type="s:string" />
214
+ <s:element minOccurs="0" maxOccurs="1" name="HelpLink" type="s:string" />
215
+ <s:element minOccurs="0" maxOccurs="1" name="RefersTo" type="s:string" />
216
+ <s:element minOccurs="1" maxOccurs="1" name="Severity" type="tns:SeverityLevel" />
217
+ <s:element minOccurs="0" maxOccurs="1" name="Source" type="s:string" />
218
+ </s:sequence>
219
+ <s:attribute name="Name" type="s:string" />
220
+ </s:complexType>
221
+ <s:complexType name="ArrayOfValidAddress">
222
+ <s:sequence>
223
+ <s:element minOccurs="0" maxOccurs="unbounded" name="ValidAddress" nillable="true" type="tns:ValidAddress" />
224
+ </s:sequence>
225
+ </s:complexType>
226
+ <s:element name="Profile" type="tns:Profile" />
227
+ <s:complexType name="Profile">
228
+ <s:sequence>
229
+ <s:element minOccurs="0" maxOccurs="1" name="Name" type="s:string" />
230
+ <s:element minOccurs="0" maxOccurs="1" name="Client" type="s:string" />
231
+ <s:element minOccurs="0" maxOccurs="1" name="Adapter" type="s:string" />
232
+ <s:element minOccurs="0" maxOccurs="1" name="Machine" type="s:string" />
233
+ </s:sequence>
234
+ <s:anyAttribute />
235
+ </s:complexType>
236
+
237
+ <s:element name="Ping">
238
+ <s:complexType>
239
+ <s:sequence>
240
+ <s:element minOccurs="0" maxOccurs="1" name="Message" type="s:string" />
241
+ </s:sequence>
242
+ </s:complexType>
243
+ </s:element>
244
+ <s:element name="PingResponse">
245
+ <s:complexType>
246
+ <s:sequence>
247
+ <s:element minOccurs="0" maxOccurs="1" name="PingResult" type="tns:PingResult" />
248
+ </s:sequence>
249
+ </s:complexType>
250
+ </s:element>
251
+ <s:complexType name="PingResult">
252
+ <s:complexContent mixed="false">
253
+ <s:extension base="tns:BaseResult">
254
+ <s:sequence>
255
+ <s:element minOccurs="0" maxOccurs="1" name="Version" type="s:string" />
256
+ </s:sequence>
257
+ </s:extension>
258
+ </s:complexContent>
259
+ </s:complexType>
260
+ <s:element name="IsAuthorized">
261
+ <s:complexType>
262
+ <s:sequence>
263
+ <s:element minOccurs="0" maxOccurs="1" name="Operations" type="s:string" />
264
+ </s:sequence>
265
+ </s:complexType>
266
+ </s:element>
267
+ <s:element name="IsAuthorizedResponse">
268
+ <s:complexType>
269
+ <s:sequence>
270
+ <s:element minOccurs="0" maxOccurs="1" name="IsAuthorizedResult" type="tns:IsAuthorizedResult" />
271
+ </s:sequence>
272
+ </s:complexType>
273
+ </s:element>
274
+ <s:complexType name="IsAuthorizedResult">
275
+ <s:complexContent mixed="false">
276
+ <s:extension base="tns:BaseResult">
277
+ <s:sequence>
278
+ <s:element minOccurs="0" maxOccurs="1" name="Operations" type="s:string" />
279
+ <s:element minOccurs="1" maxOccurs="1" name="Expires" type="s:dateTime" />
280
+ </s:sequence>
281
+ </s:extension>
282
+ </s:complexContent>
283
+ </s:complexType>
284
+ </s:schema>
285
+ </wsdl:types>
286
+ <wsdl:message name="ValidateSoapIn">
287
+ <wsdl:part name="parameters" element="tns:Validate" />
288
+ </wsdl:message>
289
+ <wsdl:message name="ValidateSoapOut">
290
+ <wsdl:part name="parameters" element="tns:ValidateResponse" />
291
+ </wsdl:message>
292
+ <wsdl:message name="ValidateProfile">
293
+ <wsdl:part name="Profile" element="tns:Profile" />
294
+ </wsdl:message>
295
+ <wsdl:message name="PingSoapIn">
296
+ <wsdl:part name="parameters" element="tns:Ping" />
297
+ </wsdl:message>
298
+ <wsdl:message name="PingSoapOut">
299
+ <wsdl:part name="parameters" element="tns:PingResponse" />
300
+ </wsdl:message>
301
+ <wsdl:message name="PingProfile">
302
+ <wsdl:part name="Profile" element="tns:Profile" />
303
+ </wsdl:message>
304
+ <wsdl:message name="IsAuthorizedSoapIn">
305
+ <wsdl:part name="parameters" element="tns:IsAuthorized" />
306
+ </wsdl:message>
307
+ <wsdl:message name="IsAuthorizedSoapOut">
308
+ <wsdl:part name="parameters" element="tns:IsAuthorizedResponse" />
309
+ </wsdl:message>
310
+ <wsdl:message name="IsAuthorizedProfile">
311
+ <wsdl:part name="Profile" element="tns:Profile" />
312
+ </wsdl:message>
313
+ <!--New Methods Begin-->
314
+ <wsdl:message name="SubmitBatchSoapIn">
315
+ <wsdl:part name="parameters" element="tns:SubmitBatch" />
316
+ </wsdl:message>
317
+ <wsdl:message name="SubmitBatchSoapOut">
318
+ <wsdl:part name="parameters" element="tns:SubmitBatchResponse" />
319
+ </wsdl:message>
320
+ <wsdl:message name="SubmitBatchProfile">
321
+ <wsdl:part name="Profile" element="tns:Profile" />
322
+ </wsdl:message>
323
+ <wsdl:message name="GetBatchSoapIn">
324
+ <wsdl:part name="parameters" element="tns:GetBatch" />
325
+ </wsdl:message>
326
+ <wsdl:message name="GetBatchSoapOut">
327
+ <wsdl:part name="parameters" element="tns:GetBatchResponse" />
328
+ </wsdl:message>
329
+ <wsdl:message name="GetBatchProfile">
330
+ <wsdl:part name="Profile" element="tns:Profile" />
331
+ </wsdl:message>
332
+ <wsdl:message name="CancelBatchSoapIn">
333
+ <wsdl:part name="parameters" element="tns:CancelBatch" />
334
+ </wsdl:message>
335
+ <wsdl:message name="CancelBatchSoapOut">
336
+ <wsdl:part name="parameters" element="tns:CancelBatchResponse" />
337
+ </wsdl:message>
338
+ <wsdl:message name="CancelBatchProfile">
339
+ <wsdl:part name="Profile" element="tns:Profile" />
340
+ </wsdl:message>
341
+ <!--New Methods End-->
342
+ <wsdl:portType name="AddressSvcSoap">
343
+ <wsdl:operation name="Validate">
344
+ <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Validate an Address</wsdl:documentation>
345
+ <wsdl:input message="tns:ValidateSoapIn" />
346
+ <wsdl:output message="tns:ValidateSoapOut" />
347
+ </wsdl:operation>
348
+ <wsdl:operation name="SubmitBatch">
349
+ <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Submits a batch of AddressSvc requests to be processed.</wsdl:documentation>
350
+ <wsdl:input message="tns:SubmitBatchSoapIn" />
351
+ <wsdl:output message="tns:SubmitBatchSoapOut" />
352
+ </wsdl:operation>
353
+ <wsdl:operation name="GetBatch">
354
+ <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Gets the status and results of a submitted batch.</wsdl:documentation>
355
+ <wsdl:input message="tns:GetBatchSoapIn" />
356
+ <wsdl:output message="tns:GetBatchSoapOut" />
357
+ </wsdl:operation>
358
+ <wsdl:operation name="CancelBatch">
359
+ <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Cancels an incomplete batch operation.</wsdl:documentation>
360
+ <wsdl:input message="tns:CancelBatchSoapIn" />
361
+ <wsdl:output message="tns:CancelBatchSoapOut" />
362
+ </wsdl:operation>
363
+ <wsdl:operation name="Ping">
364
+ <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Tests connectivity and version of the service</wsdl:documentation>
365
+ <wsdl:input message="tns:PingSoapIn" />
366
+ <wsdl:output message="tns:PingSoapOut" />
367
+ </wsdl:operation>
368
+ <wsdl:operation name="IsAuthorized">
369
+ <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Checks authentication and authorization to one or more operations on the service.</wsdl:documentation>
370
+ <wsdl:input message="tns:IsAuthorizedSoapIn" />
371
+ <wsdl:output message="tns:IsAuthorizedSoapOut" />
372
+ </wsdl:operation>
373
+ </wsdl:portType>
374
+ <wsdl:binding name="AddressSvcSoap" type="tns:AddressSvcSoap">
375
+ <soap:binding transport="http://schemas.xmlsoap.org/soap/http" />
376
+ <wsdl:operation name="Validate">
377
+ <soap:operation soapAction="http://avatax.avalara.com/services/Validate" style="document" />
378
+ <wsdl:input>
379
+ <soap:body use="literal" />
380
+ <soap:header message="tns:ValidateProfile" part="Profile" use="literal" />
381
+ </wsdl:input>
382
+ <wsdl:output>
383
+ <soap:body use="literal" />
384
+ </wsdl:output>
385
+ </wsdl:operation>
386
+ <!--New Methods Begin-->
387
+ <wsdl:operation name="SubmitBatch">
388
+ <soap:operation soapAction="http://avatax.avalara.com/services/SubmitBatch" style="document" />
389
+ <wsdl:input>
390
+ <soap:body use="literal" />
391
+ <soap:header message="tns:SubmitBatchProfile" part="Profile" use="literal" />
392
+ </wsdl:input>
393
+ <wsdl:output>
394
+ <soap:body use="literal" />
395
+ </wsdl:output>
396
+ </wsdl:operation>
397
+ <wsdl:operation name="GetBatch">
398
+ <soap:operation soapAction="http://avatax.avalara.com/services/GetBatch" style="document" />
399
+ <wsdl:input>
400
+ <soap:body use="literal" />
401
+ <soap:header message="tns:GetBatchProfile" part="Profile" use="literal" />
402
+ </wsdl:input>
403
+ <wsdl:output>
404
+ <soap:body use="literal" />
405
+ </wsdl:output>
406
+ </wsdl:operation>
407
+ <wsdl:operation name="CancelBatch">
408
+ <soap:operation soapAction="http://avatax.avalara.com/services/CancelBatch" style="document" />
409
+ <wsdl:input>
410
+ <soap:body use="literal" />
411
+ <soap:header message="tns:CancelBatchProfile" part="Profile" use="literal" />
412
+ </wsdl:input>
413
+ <wsdl:output>
414
+ <soap:body use="literal" />
415
+ </wsdl:output>
416
+ </wsdl:operation>
417
+ <!--New Methods End-->
418
+ <wsdl:operation name="Ping">
419
+ <soap:operation soapAction="http://avatax.avalara.com/services/Ping" style="document" />
420
+ <wsdl:input>
421
+ <soap:body use="literal" />
422
+ <soap:header message="tns:PingProfile" part="Profile" use="literal" />
423
+ </wsdl:input>
424
+ <wsdl:output>
425
+ <soap:body use="literal" />
426
+ </wsdl:output>
427
+ </wsdl:operation>
428
+ <wsdl:operation name="IsAuthorized">
429
+ <soap:operation soapAction="http://avatax.avalara.com/services/IsAuthorized" style="document" />
430
+ <wsdl:input>
431
+ <soap:body use="literal" />
432
+ <soap:header message="tns:IsAuthorizedProfile" part="Profile" use="literal" />
433
+ </wsdl:input>
434
+ <wsdl:output>
435
+ <soap:body use="literal" />
436
+ </wsdl:output>
437
+ </wsdl:operation>
438
+ </wsdl:binding>
439
+ <wsdl:binding name="AddressSvcSoap12" type="tns:AddressSvcSoap">
440
+ <soap12:binding transport="http://schemas.xmlsoap.org/soap/http" />
441
+ <wsdl:operation name="Validate">
442
+ <soap12:operation soapAction="http://avatax.avalara.com/services/Validate" style="document" />
443
+ <wsdl:input>
444
+ <soap12:body use="literal" />
445
+ <soap12:header message="tns:ValidateProfile" part="Profile" use="literal" />
446
+ </wsdl:input>
447
+ <wsdl:output>
448
+ <soap12:body use="literal" />
449
+ </wsdl:output>
450
+ </wsdl:operation>
451
+ <wsdl:operation name="Ping">
452
+ <soap12:operation soapAction="http://avatax.avalara.com/services/Ping" style="document" />
453
+ <wsdl:input>
454
+ <soap12:body use="literal" />
455
+ <soap12:header message="tns:PingProfile" part="Profile" use="literal" />
456
+ </wsdl:input>
457
+ <wsdl:output>
458
+ <soap12:body use="literal" />
459
+ </wsdl:output>
460
+ </wsdl:operation>
461
+ <wsdl:operation name="IsAuthorized">
462
+ <soap12:operation soapAction="http://avatax.avalara.com/services/IsAuthorized" style="document" />
463
+ <wsdl:input>
464
+ <soap12:body use="literal" />
465
+ <soap12:header message="tns:IsAuthorizedProfile" part="Profile" use="literal" />
466
+ </wsdl:input>
467
+ <wsdl:output>
468
+ <soap12:body use="literal" />
469
+ </wsdl:output>
470
+ </wsdl:operation>
471
+ <!--New Methods Begin-->
472
+ <wsdl:operation name="SubmitBatch">
473
+ <soap12:operation soapAction="http://avatax.avalara.com/services/SubmitBatch" style="document" />
474
+ <wsdl:input>
475
+ <soap12:body use="literal" />
476
+ <soap12:header message="tns:SubmitBatchProfile" part="Profile" use="literal" />
477
+ </wsdl:input>
478
+ <wsdl:output>
479
+ <soap12:body use="literal" />
480
+ </wsdl:output>
481
+ </wsdl:operation>
482
+ <wsdl:operation name="GetBatch">
483
+ <soap12:operation soapAction="http://avatax.avalara.com/services/GetBatch" style="document" />
484
+ <wsdl:input>
485
+ <soap12:body use="literal" />
486
+ <soap12:header message="tns:GetBatchProfile" part="Profile" use="literal" />
487
+ </wsdl:input>
488
+ <wsdl:output>
489
+ <soap12:body use="literal" />
490
+ </wsdl:output>
491
+ </wsdl:operation>
492
+ <wsdl:operation name="CancelBatch">
493
+ <soap12:operation soapAction="http://avatax.avalara.com/services/CancelBatch" style="document" />
494
+ <wsdl:input>
495
+ <soap12:body use="literal" />
496
+ <soap12:header message="tns:CancelBatchProfile" part="Profile" use="literal" />
497
+ </wsdl:input>
498
+ <wsdl:output>
499
+ <soap12:body use="literal" />
500
+ </wsdl:output>
501
+ </wsdl:operation>
502
+ <!--New Methods End-->
503
+ </wsdl:binding>
504
+ <wsdl:service name="AddressSvc">
505
+ <wsdl:port name="AddressSvcSoap" binding="tns:AddressSvcSoap">
506
+ <soap:address location="http://localhost/avatax.services/Address/AddressSvc.asmx" />
507
+ </wsdl:port>
508
+ <wsdl:port name="AddressSvcSoap12" binding="tns:AddressSvcSoap12">
509
+ <soap12:address location="http://localhost/avatax.services/Address/AddressSvc.asmx" />
510
+ </wsdl:port>
511
+ </wsdl:service>
512
  </wsdl:definitions>
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/wsdl/BatchSvc.wsdl RENAMED
@@ -1,659 +1,659 @@
1
- <?xml version="1.0" encoding="UTF-8"?>
2
- <wsdl:definitions xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:tm="http://microsoft.com/wsdl/mime/textMatching/" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/" xmlns:tns="http://avatax.avalara.com/services" xmlns:s="http://www.w3.org/2001/XMLSchema" xmlns:soap12="http://schemas.xmlsoap.org/wsdl/soap12/" xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" targetNamespace="http://avatax.avalara.com/services" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">
3
- <wsdl:types>
4
- <s:schema elementFormDefault="qualified" targetNamespace="http://avatax.avalara.com/services">
5
- <s:element name="BatchFetch">
6
- <s:complexType>
7
- <s:sequence>
8
- <s:element minOccurs="0" maxOccurs="1" name="FetchRequest" type="tns:FetchRequest"/>
9
- </s:sequence>
10
- </s:complexType>
11
- </s:element>
12
- <s:complexType name="FetchRequest">
13
- <s:sequence>
14
- <s:element minOccurs="0" maxOccurs="1" name="Fields" type="s:string"/>
15
- <s:element minOccurs="0" maxOccurs="1" name="Filters" type="s:string"/>
16
- <s:element minOccurs="0" maxOccurs="1" name="Sort" type="s:string"/>
17
- <s:element minOccurs="1" maxOccurs="1" name="MaxCount" type="s:int"/>
18
- <s:element minOccurs="1" maxOccurs="1" name="PageIndex" type="s:int"/>
19
- <s:element minOccurs="1" maxOccurs="1" name="PageSize" type="s:int"/>
20
- <s:element minOccurs="1" maxOccurs="1" name="RecordCount" type="s:int"/>
21
- </s:sequence>
22
- </s:complexType>
23
- <s:element name="BatchFetchResponse">
24
- <s:complexType>
25
- <s:sequence>
26
- <s:element minOccurs="0" maxOccurs="1" name="BatchFetchResult" type="tns:BatchFetchResult"/>
27
- </s:sequence>
28
- </s:complexType>
29
- </s:element>
30
- <s:complexType name="BatchFetchResult">
31
- <s:complexContent mixed="false">
32
- <s:extension base="tns:BaseResult">
33
- <s:sequence>
34
- <s:element minOccurs="0" maxOccurs="1" name="Batches" type="tns:ArrayOfBatch"/>
35
- <s:element minOccurs="1" maxOccurs="1" name="RecordCount" type="s:int"/>
36
- </s:sequence>
37
- </s:extension>
38
- </s:complexContent>
39
- </s:complexType>
40
- <s:complexType name="BaseResult">
41
- <s:sequence>
42
- <s:element minOccurs="0" maxOccurs="1" name="TransactionId" type="s:string"/>
43
- <s:element minOccurs="1" maxOccurs="1" name="ResultCode" type="tns:SeverityLevel"/>
44
- <s:element minOccurs="0" maxOccurs="1" name="Messages" type="tns:ArrayOfMessage"/>
45
- </s:sequence>
46
- </s:complexType>
47
- <s:simpleType name="SeverityLevel">
48
- <s:restriction base="s:string">
49
- <s:enumeration value="Success"/>
50
- <s:enumeration value="Warning"/>
51
- <s:enumeration value="Error"/>
52
- <s:enumeration value="Exception"/>
53
- </s:restriction>
54
- </s:simpleType>
55
- <s:complexType name="ArrayOfMessage">
56
- <s:sequence>
57
- <s:element minOccurs="0" maxOccurs="unbounded" name="Message" nillable="true" type="tns:Message"/>
58
- </s:sequence>
59
- </s:complexType>
60
- <s:complexType name="Message">
61
- <s:sequence>
62
- <s:element minOccurs="0" maxOccurs="1" name="Summary" type="s:string"/>
63
- <s:element minOccurs="0" maxOccurs="1" name="Details" type="s:string"/>
64
- <s:element minOccurs="0" maxOccurs="1" name="HelpLink" type="s:string"/>
65
- <s:element minOccurs="0" maxOccurs="1" name="RefersTo" type="s:string"/>
66
- <s:element minOccurs="1" maxOccurs="1" name="Severity" type="tns:SeverityLevel"/>
67
- <s:element minOccurs="0" maxOccurs="1" name="Source" type="s:string"/>
68
- </s:sequence>
69
- <s:attribute name="Name" type="s:string"/>
70
- </s:complexType>
71
- <s:complexType name="ArrayOfBatch">
72
- <s:sequence>
73
- <s:element minOccurs="0" maxOccurs="unbounded" name="Batch" nillable="true" type="tns:Batch"/>
74
- </s:sequence>
75
- </s:complexType>
76
- <s:complexType name="Batch">
77
- <s:sequence>
78
- <s:element minOccurs="1" maxOccurs="1" name="AccountId" type="s:int"/>
79
- <s:element minOccurs="1" maxOccurs="1" name="BatchId" type="s:int"/>
80
- <s:element minOccurs="0" maxOccurs="1" name="BatchStatusId" type="s:string"/>
81
- <s:element minOccurs="0" maxOccurs="1" name="BatchTypeId" type="s:string"/>
82
- <s:element minOccurs="1" maxOccurs="1" name="CompanyId" type="s:int"/>
83
- <s:element minOccurs="1" maxOccurs="1" name="CreatedDate" type="s:dateTime"/>
84
- <s:element minOccurs="1" maxOccurs="1" name="CreatedUserId" type="s:int"/>
85
- <s:element minOccurs="1" maxOccurs="1" name="CompletedDate" type="s:dateTime"/>
86
- <s:element minOccurs="0" maxOccurs="1" name="Files" type="tns:ArrayOfBatchFile"/>
87
- <s:element minOccurs="1" maxOccurs="1" name="ModifiedDate" type="s:dateTime"/>
88
- <s:element minOccurs="1" maxOccurs="1" name="ModifiedUserId" type="s:int"/>
89
- <s:element minOccurs="0" maxOccurs="1" name="Name" type="s:string"/>
90
- <s:element minOccurs="0" maxOccurs="1" name="Options" type="s:string"/>
91
- <s:element minOccurs="1" maxOccurs="1" name="RecordCount" type="s:int"/>
92
- <s:element minOccurs="1" maxOccurs="1" name="CurrentRecord" type="s:int"/>
93
- </s:sequence>
94
- </s:complexType>
95
- <s:complexType name="ArrayOfBatchFile">
96
- <s:sequence>
97
- <s:element minOccurs="0" maxOccurs="unbounded" name="BatchFile" nillable="true" type="tns:BatchFile"/>
98
- </s:sequence>
99
- </s:complexType>
100
- <s:complexType name="BatchFile">
101
- <s:sequence>
102
- <s:element minOccurs="1" maxOccurs="1" name="BatchFileId" type="s:int"/>
103
- <s:element minOccurs="1" maxOccurs="1" name="BatchId" type="s:int"/>
104
- <s:element minOccurs="0" maxOccurs="1" name="Content" type="s:base64Binary"/>
105
- <s:element minOccurs="0" maxOccurs="1" name="ContentType" type="s:string"/>
106
- <s:element minOccurs="0" maxOccurs="1" name="Ext" type="s:string"/>
107
- <s:element minOccurs="0" maxOccurs="1" name="FilePath" type="s:string"/>
108
- <s:element minOccurs="0" maxOccurs="1" name="Name" type="s:string"/>
109
- <s:element minOccurs="1" maxOccurs="1" name="Size" type="s:int"/>
110
- <s:element minOccurs="1" maxOccurs="1" name="ErrorCount" type="s:int"/>
111
- </s:sequence>
112
- </s:complexType>
113
- <s:element name="Profile" type="tns:Profile"/>
114
- <s:complexType name="Profile">
115
- <s:sequence>
116
- <s:element minOccurs="0" maxOccurs="1" name="Name" type="s:string"/>
117
- <s:element minOccurs="0" maxOccurs="1" name="Client" type="s:string"/>
118
- <s:element minOccurs="0" maxOccurs="1" name="Adapter" type="s:string"/>
119
- <s:element minOccurs="0" maxOccurs="1" name="Machine" type="s:string"/>
120
- </s:sequence>
121
- <s:anyAttribute/>
122
- </s:complexType>
123
- <s:element name="BatchSave">
124
- <s:complexType>
125
- <s:sequence>
126
- <s:element minOccurs="0" maxOccurs="1" name="Batch" type="tns:Batch"/>
127
- </s:sequence>
128
- </s:complexType>
129
- </s:element>
130
- <s:element name="BatchSaveResponse">
131
- <s:complexType>
132
- <s:sequence>
133
- <s:element minOccurs="0" maxOccurs="1" name="BatchSaveResult" type="tns:BatchSaveResult"/>
134
- </s:sequence>
135
- </s:complexType>
136
- </s:element>
137
- <s:complexType name="BatchSaveResult">
138
- <s:complexContent mixed="false">
139
- <s:extension base="tns:BaseResult">
140
- <s:sequence>
141
- <s:element minOccurs="1" maxOccurs="1" name="BatchId" type="s:int"/>
142
- <s:element minOccurs="1" maxOccurs="1" name="EstimatedCompletion" type="s:dateTime"/>
143
- </s:sequence>
144
- </s:extension>
145
- </s:complexContent>
146
- </s:complexType>
147
- <s:element name="AuditMessage" type="tns:AuditMessage"/>
148
- <s:complexType name="AuditMessage">
149
- <s:sequence>
150
- <s:element minOccurs="0" maxOccurs="1" name="Message" type="s:string"/>
151
- </s:sequence>
152
- <s:anyAttribute/>
153
- </s:complexType>
154
- <s:element name="BatchDelete">
155
- <s:complexType>
156
- <s:sequence>
157
- <s:element minOccurs="0" maxOccurs="1" name="DeleteRequest" type="tns:DeleteRequest"/>
158
- </s:sequence>
159
- </s:complexType>
160
- </s:element>
161
- <s:complexType name="DeleteRequest">
162
- <s:complexContent mixed="false">
163
- <s:extension base="tns:FilterRequest"/>
164
- </s:complexContent>
165
- </s:complexType>
166
- <s:complexType name="FilterRequest">
167
- <s:sequence>
168
- <s:element minOccurs="0" maxOccurs="1" name="Filters" type="s:string"/>
169
- <s:element minOccurs="1" maxOccurs="1" name="MaxCount" type="s:int"/>
170
- </s:sequence>
171
- </s:complexType>
172
- <s:element name="BatchDeleteResponse">
173
- <s:complexType>
174
- <s:sequence>
175
- <s:element minOccurs="0" maxOccurs="1" name="BatchDeleteResult" type="tns:DeleteResult"/>
176
- </s:sequence>
177
- </s:complexType>
178
- </s:element>
179
- <s:complexType name="DeleteResult">
180
- <s:complexContent mixed="false">
181
- <s:extension base="tns:FilterResult"/>
182
- </s:complexContent>
183
- </s:complexType>
184
- <s:complexType name="FilterResult">
185
- <s:complexContent mixed="false">
186
- <s:extension base="tns:BaseResult">
187
- <s:sequence>
188
- <s:element minOccurs="1" maxOccurs="1" name="Count" type="s:int"/>
189
- </s:sequence>
190
- </s:extension>
191
- </s:complexContent>
192
- </s:complexType>
193
- <s:element name="BatchProcess">
194
- <s:complexType>
195
- <s:sequence>
196
- <s:element minOccurs="0" maxOccurs="1" name="BatchProcessRequest" type="tns:BatchProcessRequest"/>
197
- </s:sequence>
198
- </s:complexType>
199
- </s:element>
200
- <s:complexType name="BatchProcessRequest">
201
- <s:complexContent mixed="false">
202
- <s:extension base="tns:FilterRequest"/>
203
- </s:complexContent>
204
- </s:complexType>
205
- <s:element name="BatchProcessResponse">
206
- <s:complexType>
207
- <s:sequence>
208
- <s:element minOccurs="0" maxOccurs="1" name="BatchProcessResult" type="tns:BatchProcessResult"/>
209
- </s:sequence>
210
- </s:complexType>
211
- </s:element>
212
- <s:complexType name="BatchProcessResult">
213
- <s:complexContent mixed="false">
214
- <s:extension base="tns:FilterResult"/>
215
- </s:complexContent>
216
- </s:complexType>
217
- <s:element name="BatchFileFetch">
218
- <s:complexType>
219
- <s:sequence>
220
- <s:element minOccurs="0" maxOccurs="1" name="FetchRequest" type="tns:FetchRequest"/>
221
- </s:sequence>
222
- </s:complexType>
223
- </s:element>
224
- <s:element name="BatchFileFetchResponse">
225
- <s:complexType>
226
- <s:sequence>
227
- <s:element minOccurs="0" maxOccurs="1" name="BatchFileFetchResult" type="tns:BatchFileFetchResult"/>
228
- </s:sequence>
229
- </s:complexType>
230
- </s:element>
231
- <s:complexType name="BatchFileFetchResult">
232
- <s:complexContent mixed="false">
233
- <s:extension base="tns:BaseResult">
234
- <s:sequence>
235
- <s:element minOccurs="0" maxOccurs="1" name="BatchFiles" type="tns:ArrayOfBatchFile"/>
236
- <s:element minOccurs="1" maxOccurs="1" name="RecordCount" type="s:int"/>
237
- </s:sequence>
238
- </s:extension>
239
- </s:complexContent>
240
- </s:complexType>
241
- <s:element name="BatchFileSave">
242
- <s:complexType>
243
- <s:sequence>
244
- <s:element minOccurs="0" maxOccurs="1" name="BatchFile" type="tns:BatchFile"/>
245
- </s:sequence>
246
- </s:complexType>
247
- </s:element>
248
- <s:element name="BatchFileSaveResponse">
249
- <s:complexType>
250
- <s:sequence>
251
- <s:element minOccurs="0" maxOccurs="1" name="BatchFileSaveResult" type="tns:BatchFileSaveResult"/>
252
- </s:sequence>
253
- </s:complexType>
254
- </s:element>
255
- <s:complexType name="BatchFileSaveResult">
256
- <s:complexContent mixed="false">
257
- <s:extension base="tns:BaseResult">
258
- <s:sequence>
259
- <s:element minOccurs="1" maxOccurs="1" name="BatchFileId" type="s:int"/>
260
- </s:sequence>
261
- </s:extension>
262
- </s:complexContent>
263
- </s:complexType>
264
- <s:element name="BatchFileDelete">
265
- <s:complexType>
266
- <s:sequence>
267
- <s:element minOccurs="0" maxOccurs="1" name="DeleteRequest" type="tns:DeleteRequest"/>
268
- </s:sequence>
269
- </s:complexType>
270
- </s:element>
271
- <s:element name="BatchFileDeleteResponse">
272
- <s:complexType>
273
- <s:sequence>
274
- <s:element minOccurs="0" maxOccurs="1" name="BatchFileDeleteResult" type="tns:DeleteResult"/>
275
- </s:sequence>
276
- </s:complexType>
277
- </s:element>
278
- <s:element name="Ping">
279
- <s:complexType>
280
- <s:sequence>
281
- <s:element minOccurs="0" maxOccurs="1" name="Message" type="s:string"/>
282
- </s:sequence>
283
- </s:complexType>
284
- </s:element>
285
- <s:element name="PingResponse">
286
- <s:complexType>
287
- <s:sequence>
288
- <s:element minOccurs="0" maxOccurs="1" name="PingResult" type="tns:PingResult"/>
289
- </s:sequence>
290
- </s:complexType>
291
- </s:element>
292
- <s:complexType name="PingResult">
293
- <s:complexContent mixed="false">
294
- <s:extension base="tns:BaseResult">
295
- <s:sequence>
296
- <s:element minOccurs="0" maxOccurs="1" name="Version" type="s:string"/>
297
- </s:sequence>
298
- </s:extension>
299
- </s:complexContent>
300
- </s:complexType>
301
- <s:element name="IsAuthorized">
302
- <s:complexType>
303
- <s:sequence>
304
- <s:element minOccurs="0" maxOccurs="1" name="Operations" type="s:string"/>
305
- </s:sequence>
306
- </s:complexType>
307
- </s:element>
308
- <s:element name="IsAuthorizedResponse">
309
- <s:complexType>
310
- <s:sequence>
311
- <s:element minOccurs="0" maxOccurs="1" name="IsAuthorizedResult" type="tns:IsAuthorizedResult"/>
312
- </s:sequence>
313
- </s:complexType>
314
- </s:element>
315
- <s:complexType name="IsAuthorizedResult">
316
- <s:complexContent mixed="false">
317
- <s:extension base="tns:BaseResult">
318
- <s:sequence>
319
- <s:element minOccurs="0" maxOccurs="1" name="Operations" type="s:string"/>
320
- <s:element minOccurs="1" maxOccurs="1" name="Expires" type="s:dateTime"/>
321
- </s:sequence>
322
- </s:extension>
323
- </s:complexContent>
324
- </s:complexType>
325
- </s:schema>
326
- </wsdl:types>
327
- <wsdl:message name="BatchFetchSoapIn">
328
- <wsdl:part name="parameters" element="tns:BatchFetch"/>
329
- </wsdl:message>
330
- <wsdl:message name="BatchFetchSoapOut">
331
- <wsdl:part name="parameters" element="tns:BatchFetchResponse"/>
332
- </wsdl:message>
333
- <wsdl:message name="BatchFetchProfile">
334
- <wsdl:part name="Profile" element="tns:Profile"/>
335
- </wsdl:message>
336
- <wsdl:message name="BatchSaveSoapIn">
337
- <wsdl:part name="parameters" element="tns:BatchSave"/>
338
- </wsdl:message>
339
- <wsdl:message name="BatchSaveSoapOut">
340
- <wsdl:part name="parameters" element="tns:BatchSaveResponse"/>
341
- </wsdl:message>
342
- <wsdl:message name="BatchSaveAuditMessage">
343
- <wsdl:part name="AuditMessage" element="tns:AuditMessage"/>
344
- </wsdl:message>
345
- <wsdl:message name="BatchSaveProfile">
346
- <wsdl:part name="Profile" element="tns:Profile"/>
347
- </wsdl:message>
348
- <wsdl:message name="BatchDeleteSoapIn">
349
- <wsdl:part name="parameters" element="tns:BatchDelete"/>
350
- </wsdl:message>
351
- <wsdl:message name="BatchDeleteSoapOut">
352
- <wsdl:part name="parameters" element="tns:BatchDeleteResponse"/>
353
- </wsdl:message>
354
- <wsdl:message name="BatchDeleteAuditMessage">
355
- <wsdl:part name="AuditMessage" element="tns:AuditMessage"/>
356
- </wsdl:message>
357
- <wsdl:message name="BatchDeleteProfile">
358
- <wsdl:part name="Profile" element="tns:Profile"/>
359
- </wsdl:message>
360
- <wsdl:message name="BatchProcessSoapIn">
361
- <wsdl:part name="parameters" element="tns:BatchProcess"/>
362
- </wsdl:message>
363
- <wsdl:message name="BatchProcessSoapOut">
364
- <wsdl:part name="parameters" element="tns:BatchProcessResponse"/>
365
- </wsdl:message>
366
- <wsdl:message name="BatchProcessProfile">
367
- <wsdl:part name="Profile" element="tns:Profile"/>
368
- </wsdl:message>
369
- <wsdl:message name="BatchFileFetchSoapIn">
370
- <wsdl:part name="parameters" element="tns:BatchFileFetch"/>
371
- </wsdl:message>
372
- <wsdl:message name="BatchFileFetchSoapOut">
373
- <wsdl:part name="parameters" element="tns:BatchFileFetchResponse"/>
374
- </wsdl:message>
375
- <wsdl:message name="BatchFileFetchProfile">
376
- <wsdl:part name="Profile" element="tns:Profile"/>
377
- </wsdl:message>
378
- <wsdl:message name="BatchFileSaveSoapIn">
379
- <wsdl:part name="parameters" element="tns:BatchFileSave"/>
380
- </wsdl:message>
381
- <wsdl:message name="BatchFileSaveSoapOut">
382
- <wsdl:part name="parameters" element="tns:BatchFileSaveResponse"/>
383
- </wsdl:message>
384
- <wsdl:message name="BatchFileSaveProfile">
385
- <wsdl:part name="Profile" element="tns:Profile"/>
386
- </wsdl:message>
387
- <wsdl:message name="BatchFileDeleteSoapIn">
388
- <wsdl:part name="parameters" element="tns:BatchFileDelete"/>
389
- </wsdl:message>
390
- <wsdl:message name="BatchFileDeleteSoapOut">
391
- <wsdl:part name="parameters" element="tns:BatchFileDeleteResponse"/>
392
- </wsdl:message>
393
- <wsdl:message name="BatchFileDeleteProfile">
394
- <wsdl:part name="Profile" element="tns:Profile"/>
395
- </wsdl:message>
396
- <wsdl:message name="PingSoapIn">
397
- <wsdl:part name="parameters" element="tns:Ping"/>
398
- </wsdl:message>
399
- <wsdl:message name="PingSoapOut">
400
- <wsdl:part name="parameters" element="tns:PingResponse"/>
401
- </wsdl:message>
402
- <wsdl:message name="PingProfile">
403
- <wsdl:part name="Profile" element="tns:Profile"/>
404
- </wsdl:message>
405
- <wsdl:message name="IsAuthorizedSoapIn">
406
- <wsdl:part name="parameters" element="tns:IsAuthorized"/>
407
- </wsdl:message>
408
- <wsdl:message name="IsAuthorizedSoapOut">
409
- <wsdl:part name="parameters" element="tns:IsAuthorizedResponse"/>
410
- </wsdl:message>
411
- <wsdl:message name="IsAuthorizedProfile">
412
- <wsdl:part name="Profile" element="tns:Profile"/>
413
- </wsdl:message>
414
- <wsdl:portType name="BatchSvcSoap">
415
- <wsdl:operation name="BatchFetch">
416
- <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Fetches one or more Batch</wsdl:documentation>
417
- <wsdl:input message="tns:BatchFetchSoapIn"/>
418
- <wsdl:output message="tns:BatchFetchSoapOut"/>
419
- </wsdl:operation>
420
- <wsdl:operation name="BatchSave">
421
- <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Saves a Batch entry</wsdl:documentation>
422
- <wsdl:input message="tns:BatchSaveSoapIn"/>
423
- <wsdl:output message="tns:BatchSaveSoapOut"/>
424
- </wsdl:operation>
425
- <wsdl:operation name="BatchDelete">
426
- <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Deletes one or more Batches</wsdl:documentation>
427
- <wsdl:input message="tns:BatchDeleteSoapIn"/>
428
- <wsdl:output message="tns:BatchDeleteSoapOut"/>
429
- </wsdl:operation>
430
- <wsdl:operation name="BatchProcess">
431
- <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Processes one or more Batches</wsdl:documentation>
432
- <wsdl:input message="tns:BatchProcessSoapIn"/>
433
- <wsdl:output message="tns:BatchProcessSoapOut"/>
434
- </wsdl:operation>
435
- <wsdl:operation name="BatchFileFetch">
436
- <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Fetches one or more BatchFiles</wsdl:documentation>
437
- <wsdl:input message="tns:BatchFileFetchSoapIn"/>
438
- <wsdl:output message="tns:BatchFileFetchSoapOut"/>
439
- </wsdl:operation>
440
- <wsdl:operation name="BatchFileSave">
441
- <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Saves a Batch File</wsdl:documentation>
442
- <wsdl:input message="tns:BatchFileSaveSoapIn"/>
443
- <wsdl:output message="tns:BatchFileSaveSoapOut"/>
444
- </wsdl:operation>
445
- <wsdl:operation name="BatchFileDelete">
446
- <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Deletes one or more BatchFiles</wsdl:documentation>
447
- <wsdl:input message="tns:BatchFileDeleteSoapIn"/>
448
- <wsdl:output message="tns:BatchFileDeleteSoapOut"/>
449
- </wsdl:operation>
450
- <wsdl:operation name="Ping">
451
- <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Tests connectivity and version of the service</wsdl:documentation>
452
- <wsdl:input message="tns:PingSoapIn"/>
453
- <wsdl:output message="tns:PingSoapOut"/>
454
- </wsdl:operation>
455
- <wsdl:operation name="IsAuthorized">
456
- <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Checks authentication and authorization to one or more operations on the service.</wsdl:documentation>
457
- <wsdl:input message="tns:IsAuthorizedSoapIn"/>
458
- <wsdl:output message="tns:IsAuthorizedSoapOut"/>
459
- </wsdl:operation>
460
- </wsdl:portType>
461
- <wsdl:binding name="BatchSvcSoap" type="tns:BatchSvcSoap">
462
- <soap:binding transport="http://schemas.xmlsoap.org/soap/http"/>
463
- <wsdl:operation name="BatchFetch">
464
- <soap:operation soapAction="http://avatax.avalara.com/services/BatchFetch" style="document"/>
465
- <wsdl:input>
466
- <soap:body use="literal"/>
467
- <soap:header message="tns:BatchFetchProfile" part="Profile" use="literal"/>
468
- </wsdl:input>
469
- <wsdl:output>
470
- <soap:body use="literal"/>
471
- </wsdl:output>
472
- </wsdl:operation>
473
- <wsdl:operation name="BatchSave">
474
- <soap:operation soapAction="http://avatax.avalara.com/services/BatchSave" style="document"/>
475
- <wsdl:input>
476
- <soap:body use="literal"/>
477
- <soap:header message="tns:BatchSaveAuditMessage" part="AuditMessage" use="literal"/>
478
- <soap:header message="tns:BatchSaveProfile" part="Profile" use="literal"/>
479
- </wsdl:input>
480
- <wsdl:output>
481
- <soap:body use="literal"/>
482
- </wsdl:output>
483
- </wsdl:operation>
484
- <wsdl:operation name="BatchDelete">
485
- <soap:operation soapAction="http://avatax.avalara.com/services/BatchDelete" style="document"/>
486
- <wsdl:input>
487
- <soap:body use="literal"/>
488
- <soap:header message="tns:BatchDeleteAuditMessage" part="AuditMessage" use="literal"/>
489
- <soap:header message="tns:BatchDeleteProfile" part="Profile" use="literal"/>
490
- </wsdl:input>
491
- <wsdl:output>
492
- <soap:body use="literal"/>
493
- </wsdl:output>
494
- </wsdl:operation>
495
- <wsdl:operation name="BatchProcess">
496
- <soap:operation soapAction="http://avatax.avalara.com/services/BatchProcess" style="document"/>
497
- <wsdl:input>
498
- <soap:body use="literal"/>
499
- <soap:header message="tns:BatchProcessProfile" part="Profile" use="literal"/>
500
- </wsdl:input>
501
- <wsdl:output>
502
- <soap:body use="literal"/>
503
- </wsdl:output>
504
- </wsdl:operation>
505
- <wsdl:operation name="BatchFileFetch">
506
- <soap:operation soapAction="http://avatax.avalara.com/services/BatchFileFetch" style="document"/>
507
- <wsdl:input>
508
- <soap:body use="literal"/>
509
- <soap:header message="tns:BatchFileFetchProfile" part="Profile" use="literal"/>
510
- </wsdl:input>
511
- <wsdl:output>
512
- <soap:body use="literal"/>
513
- </wsdl:output>
514
- </wsdl:operation>
515
- <wsdl:operation name="BatchFileSave">
516
- <soap:operation soapAction="http://avatax.avalara.com/services/BatchFileSave" style="document"/>
517
- <wsdl:input>
518
- <soap:body use="literal"/>
519
- <soap:header message="tns:BatchFileSaveProfile" part="Profile" use="literal"/>
520
- </wsdl:input>
521
- <wsdl:output>
522
- <soap:body use="literal"/>
523
- </wsdl:output>
524
- </wsdl:operation>
525
- <wsdl:operation name="BatchFileDelete">
526
- <soap:operation soapAction="http://avatax.avalara.com/services/BatchFileDelete" style="document"/>
527
- <wsdl:input>
528
- <soap:body use="literal"/>
529
- <soap:header message="tns:BatchFileDeleteProfile" part="Profile" use="literal"/>
530
- </wsdl:input>
531
- <wsdl:output>
532
- <soap:body use="literal"/>
533
- </wsdl:output>
534
- </wsdl:operation>
535
- <wsdl:operation name="Ping">
536
- <soap:operation soapAction="http://avatax.avalara.com/services/Ping" style="document"/>
537
- <wsdl:input>
538
- <soap:body use="literal"/>
539
- <soap:header message="tns:PingProfile" part="Profile" use="literal"/>
540
- </wsdl:input>
541
- <wsdl:output>
542
- <soap:body use="literal"/>
543
- </wsdl:output>
544
- </wsdl:operation>
545
- <wsdl:operation name="IsAuthorized">
546
- <soap:operation soapAction="http://avatax.avalara.com/services/IsAuthorized" style="document"/>
547
- <wsdl:input>
548
- <soap:body use="literal"/>
549
- <soap:header message="tns:IsAuthorizedProfile" part="Profile" use="literal"/>
550
- </wsdl:input>
551
- <wsdl:output>
552
- <soap:body use="literal"/>
553
- </wsdl:output>
554
- </wsdl:operation>
555
- </wsdl:binding>
556
- <wsdl:binding name="BatchSvcSoap12" type="tns:BatchSvcSoap">
557
- <soap12:binding transport="http://schemas.xmlsoap.org/soap/http"/>
558
- <wsdl:operation name="BatchFetch">
559
- <soap12:operation soapAction="http://avatax.avalara.com/services/BatchFetch" style="document"/>
560
- <wsdl:input>
561
- <soap12:body use="literal"/>
562
- <soap12:header message="tns:BatchFetchProfile" part="Profile" use="literal"/>
563
- </wsdl:input>
564
- <wsdl:output>
565
- <soap12:body use="literal"/>
566
- </wsdl:output>
567
- </wsdl:operation>
568
- <wsdl:operation name="BatchSave">
569
- <soap12:operation soapAction="http://avatax.avalara.com/services/BatchSave" style="document"/>
570
- <wsdl:input>
571
- <soap12:body use="literal"/>
572
- <soap12:header message="tns:BatchSaveAuditMessage" part="AuditMessage" use="literal"/>
573
- <soap12:header message="tns:BatchSaveProfile" part="Profile" use="literal"/>
574
- </wsdl:input>
575
- <wsdl:output>
576
- <soap12:body use="literal"/>
577
- </wsdl:output>
578
- </wsdl:operation>
579
- <wsdl:operation name="BatchDelete">
580
- <soap12:operation soapAction="http://avatax.avalara.com/services/BatchDelete" style="document"/>
581
- <wsdl:input>
582
- <soap12:body use="literal"/>
583
- <soap12:header message="tns:BatchDeleteAuditMessage" part="AuditMessage" use="literal"/>
584
- <soap12:header message="tns:BatchDeleteProfile" part="Profile" use="literal"/>
585
- </wsdl:input>
586
- <wsdl:output>
587
- <soap12:body use="literal"/>
588
- </wsdl:output>
589
- </wsdl:operation>
590
- <wsdl:operation name="BatchProcess">
591
- <soap12:operation soapAction="http://avatax.avalara.com/services/BatchProcess" style="document"/>
592
- <wsdl:input>
593
- <soap12:body use="literal"/>
594
- <soap12:header message="tns:BatchProcessProfile" part="Profile" use="literal"/>
595
- </wsdl:input>
596
- <wsdl:output>
597
- <soap12:body use="literal"/>
598
- </wsdl:output>
599
- </wsdl:operation>
600
- <wsdl:operation name="BatchFileFetch">
601
- <soap12:operation soapAction="http://avatax.avalara.com/services/BatchFileFetch" style="document"/>
602
- <wsdl:input>
603
- <soap12:body use="literal"/>
604
- <soap12:header message="tns:BatchFileFetchProfile" part="Profile" use="literal"/>
605
- </wsdl:input>
606
- <wsdl:output>
607
- <soap12:body use="literal"/>
608
- </wsdl:output>
609
- </wsdl:operation>
610
- <wsdl:operation name="BatchFileSave">
611
- <soap12:operation soapAction="http://avatax.avalara.com/services/BatchFileSave" style="document"/>
612
- <wsdl:input>
613
- <soap12:body use="literal"/>
614
- <soap12:header message="tns:BatchFileSaveProfile" part="Profile" use="literal"/>
615
- </wsdl:input>
616
- <wsdl:output>
617
- <soap12:body use="literal"/>
618
- </wsdl:output>
619
- </wsdl:operation>
620
- <wsdl:operation name="BatchFileDelete">
621
- <soap12:operation soapAction="http://avatax.avalara.com/services/BatchFileDelete" style="document"/>
622
- <wsdl:input>
623
- <soap12:body use="literal"/>
624
- <soap12:header message="tns:BatchFileDeleteProfile" part="Profile" use="literal"/>
625
- </wsdl:input>
626
- <wsdl:output>
627
- <soap12:body use="literal"/>
628
- </wsdl:output>
629
- </wsdl:operation>
630
- <wsdl:operation name="Ping">
631
- <soap12:operation soapAction="http://avatax.avalara.com/services/Ping" style="document"/>
632
- <wsdl:input>
633
- <soap12:body use="literal"/>
634
- <soap12:header message="tns:PingProfile" part="Profile" use="literal"/>
635
- </wsdl:input>
636
- <wsdl:output>
637
- <soap12:body use="literal"/>
638
- </wsdl:output>
639
- </wsdl:operation>
640
- <wsdl:operation name="IsAuthorized">
641
- <soap12:operation soapAction="http://avatax.avalara.com/services/IsAuthorized" style="document"/>
642
- <wsdl:input>
643
- <soap12:body use="literal"/>
644
- <soap12:header message="tns:IsAuthorizedProfile" part="Profile" use="literal"/>
645
- </wsdl:input>
646
- <wsdl:output>
647
- <soap12:body use="literal"/>
648
- </wsdl:output>
649
- </wsdl:operation>
650
- </wsdl:binding>
651
- <wsdl:service name="BatchSvc">
652
- <wsdl:port name="BatchSvcSoap" binding="tns:BatchSvcSoap">
653
- <soap:address location="http://localhost/avatax.services/Batch/BatchSvc.asmx"/>
654
- </wsdl:port>
655
- <wsdl:port name="BatchSvcSoap12" binding="tns:BatchSvcSoap12">
656
- <soap12:address location="http://localhost/avatax.services/Batch/BatchSvc.asmx"/>
657
- </wsdl:port>
658
- </wsdl:service>
659
  </wsdl:definitions>
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <wsdl:definitions xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:tm="http://microsoft.com/wsdl/mime/textMatching/" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/" xmlns:tns="http://avatax.avalara.com/services" xmlns:s="http://www.w3.org/2001/XMLSchema" xmlns:soap12="http://schemas.xmlsoap.org/wsdl/soap12/" xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" targetNamespace="http://avatax.avalara.com/services" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">
3
+ <wsdl:types>
4
+ <s:schema elementFormDefault="qualified" targetNamespace="http://avatax.avalara.com/services">
5
+ <s:element name="BatchFetch">
6
+ <s:complexType>
7
+ <s:sequence>
8
+ <s:element minOccurs="0" maxOccurs="1" name="FetchRequest" type="tns:FetchRequest"/>
9
+ </s:sequence>
10
+ </s:complexType>
11
+ </s:element>
12
+ <s:complexType name="FetchRequest">
13
+ <s:sequence>
14
+ <s:element minOccurs="0" maxOccurs="1" name="Fields" type="s:string"/>
15
+ <s:element minOccurs="0" maxOccurs="1" name="Filters" type="s:string"/>
16
+ <s:element minOccurs="0" maxOccurs="1" name="Sort" type="s:string"/>
17
+ <s:element minOccurs="1" maxOccurs="1" name="MaxCount" type="s:int"/>
18
+ <s:element minOccurs="1" maxOccurs="1" name="PageIndex" type="s:int"/>
19
+ <s:element minOccurs="1" maxOccurs="1" name="PageSize" type="s:int"/>
20
+ <s:element minOccurs="1" maxOccurs="1" name="RecordCount" type="s:int"/>
21
+ </s:sequence>
22
+ </s:complexType>
23
+ <s:element name="BatchFetchResponse">
24
+ <s:complexType>
25
+ <s:sequence>
26
+ <s:element minOccurs="0" maxOccurs="1" name="BatchFetchResult" type="tns:BatchFetchResult"/>
27
+ </s:sequence>
28
+ </s:complexType>
29
+ </s:element>
30
+ <s:complexType name="BatchFetchResult">
31
+ <s:complexContent mixed="false">
32
+ <s:extension base="tns:BaseResult">
33
+ <s:sequence>
34
+ <s:element minOccurs="0" maxOccurs="1" name="Batches" type="tns:ArrayOfBatch"/>
35
+ <s:element minOccurs="1" maxOccurs="1" name="RecordCount" type="s:int"/>
36
+ </s:sequence>
37
+ </s:extension>
38
+ </s:complexContent>
39
+ </s:complexType>
40
+ <s:complexType name="BaseResult">
41
+ <s:sequence>
42
+ <s:element minOccurs="0" maxOccurs="1" name="TransactionId" type="s:string"/>
43
+ <s:element minOccurs="1" maxOccurs="1" name="ResultCode" type="tns:SeverityLevel"/>
44
+ <s:element minOccurs="0" maxOccurs="1" name="Messages" type="tns:ArrayOfMessage"/>
45
+ </s:sequence>
46
+ </s:complexType>
47
+ <s:simpleType name="SeverityLevel">
48
+ <s:restriction base="s:string">
49
+ <s:enumeration value="Success"/>
50
+ <s:enumeration value="Warning"/>
51
+ <s:enumeration value="Error"/>
52
+ <s:enumeration value="Exception"/>
53
+ </s:restriction>
54
+ </s:simpleType>
55
+ <s:complexType name="ArrayOfMessage">
56
+ <s:sequence>
57
+ <s:element minOccurs="0" maxOccurs="unbounded" name="Message" nillable="true" type="tns:Message"/>
58
+ </s:sequence>
59
+ </s:complexType>
60
+ <s:complexType name="Message">
61
+ <s:sequence>
62
+ <s:element minOccurs="0" maxOccurs="1" name="Summary" type="s:string"/>
63
+ <s:element minOccurs="0" maxOccurs="1" name="Details" type="s:string"/>
64
+ <s:element minOccurs="0" maxOccurs="1" name="HelpLink" type="s:string"/>
65
+ <s:element minOccurs="0" maxOccurs="1" name="RefersTo" type="s:string"/>
66
+ <s:element minOccurs="1" maxOccurs="1" name="Severity" type="tns:SeverityLevel"/>
67
+ <s:element minOccurs="0" maxOccurs="1" name="Source" type="s:string"/>
68
+ </s:sequence>
69
+ <s:attribute name="Name" type="s:string"/>
70
+ </s:complexType>
71
+ <s:complexType name="ArrayOfBatch">
72
+ <s:sequence>
73
+ <s:element minOccurs="0" maxOccurs="unbounded" name="Batch" nillable="true" type="tns:Batch"/>
74
+ </s:sequence>
75
+ </s:complexType>
76
+ <s:complexType name="Batch">
77
+ <s:sequence>
78
+ <s:element minOccurs="1" maxOccurs="1" name="AccountId" type="s:int"/>
79
+ <s:element minOccurs="1" maxOccurs="1" name="BatchId" type="s:int"/>
80
+ <s:element minOccurs="0" maxOccurs="1" name="BatchStatusId" type="s:string"/>
81
+ <s:element minOccurs="0" maxOccurs="1" name="BatchTypeId" type="s:string"/>
82
+ <s:element minOccurs="1" maxOccurs="1" name="CompanyId" type="s:int"/>
83
+ <s:element minOccurs="1" maxOccurs="1" name="CreatedDate" type="s:dateTime"/>
84
+ <s:element minOccurs="1" maxOccurs="1" name="CreatedUserId" type="s:int"/>
85
+ <s:element minOccurs="1" maxOccurs="1" name="CompletedDate" type="s:dateTime"/>
86
+ <s:element minOccurs="0" maxOccurs="1" name="Files" type="tns:ArrayOfBatchFile"/>
87
+ <s:element minOccurs="1" maxOccurs="1" name="ModifiedDate" type="s:dateTime"/>
88
+ <s:element minOccurs="1" maxOccurs="1" name="ModifiedUserId" type="s:int"/>
89
+ <s:element minOccurs="0" maxOccurs="1" name="Name" type="s:string"/>
90
+ <s:element minOccurs="0" maxOccurs="1" name="Options" type="s:string"/>
91
+ <s:element minOccurs="1" maxOccurs="1" name="RecordCount" type="s:int"/>
92
+ <s:element minOccurs="1" maxOccurs="1" name="CurrentRecord" type="s:int"/>
93
+ </s:sequence>
94
+ </s:complexType>
95
+ <s:complexType name="ArrayOfBatchFile">
96
+ <s:sequence>
97
+ <s:element minOccurs="0" maxOccurs="unbounded" name="BatchFile" nillable="true" type="tns:BatchFile"/>
98
+ </s:sequence>
99
+ </s:complexType>
100
+ <s:complexType name="BatchFile">
101
+ <s:sequence>
102
+ <s:element minOccurs="1" maxOccurs="1" name="BatchFileId" type="s:int"/>
103
+ <s:element minOccurs="1" maxOccurs="1" name="BatchId" type="s:int"/>
104
+ <s:element minOccurs="0" maxOccurs="1" name="Content" type="s:base64Binary"/>
105
+ <s:element minOccurs="0" maxOccurs="1" name="ContentType" type="s:string"/>
106
+ <s:element minOccurs="0" maxOccurs="1" name="Ext" type="s:string"/>
107
+ <s:element minOccurs="0" maxOccurs="1" name="FilePath" type="s:string"/>
108
+ <s:element minOccurs="0" maxOccurs="1" name="Name" type="s:string"/>
109
+ <s:element minOccurs="1" maxOccurs="1" name="Size" type="s:int"/>
110
+ <s:element minOccurs="1" maxOccurs="1" name="ErrorCount" type="s:int"/>
111
+ </s:sequence>
112
+ </s:complexType>
113
+ <s:element name="Profile" type="tns:Profile"/>
114
+ <s:complexType name="Profile">
115
+ <s:sequence>
116
+ <s:element minOccurs="0" maxOccurs="1" name="Name" type="s:string"/>
117
+ <s:element minOccurs="0" maxOccurs="1" name="Client" type="s:string"/>
118
+ <s:element minOccurs="0" maxOccurs="1" name="Adapter" type="s:string"/>
119
+ <s:element minOccurs="0" maxOccurs="1" name="Machine" type="s:string"/>
120
+ </s:sequence>
121
+ <s:anyAttribute/>
122
+ </s:complexType>
123
+ <s:element name="BatchSave">
124
+ <s:complexType>
125
+ <s:sequence>
126
+ <s:element minOccurs="0" maxOccurs="1" name="Batch" type="tns:Batch"/>
127
+ </s:sequence>
128
+ </s:complexType>
129
+ </s:element>
130
+ <s:element name="BatchSaveResponse">
131
+ <s:complexType>
132
+ <s:sequence>
133
+ <s:element minOccurs="0" maxOccurs="1" name="BatchSaveResult" type="tns:BatchSaveResult"/>
134
+ </s:sequence>
135
+ </s:complexType>
136
+ </s:element>
137
+ <s:complexType name="BatchSaveResult">
138
+ <s:complexContent mixed="false">
139
+ <s:extension base="tns:BaseResult">
140
+ <s:sequence>
141
+ <s:element minOccurs="1" maxOccurs="1" name="BatchId" type="s:int"/>
142
+ <s:element minOccurs="1" maxOccurs="1" name="EstimatedCompletion" type="s:dateTime"/>
143
+ </s:sequence>
144
+ </s:extension>
145
+ </s:complexContent>
146
+ </s:complexType>
147
+ <s:element name="AuditMessage" type="tns:AuditMessage"/>
148
+ <s:complexType name="AuditMessage">
149
+ <s:sequence>
150
+ <s:element minOccurs="0" maxOccurs="1" name="Message" type="s:string"/>
151
+ </s:sequence>
152
+ <s:anyAttribute/>
153
+ </s:complexType>
154
+ <s:element name="BatchDelete">
155
+ <s:complexType>
156
+ <s:sequence>
157
+ <s:element minOccurs="0" maxOccurs="1" name="DeleteRequest" type="tns:DeleteRequest"/>
158
+ </s:sequence>
159
+ </s:complexType>
160
+ </s:element>
161
+ <s:complexType name="DeleteRequest">
162
+ <s:complexContent mixed="false">
163
+ <s:extension base="tns:FilterRequest"/>
164
+ </s:complexContent>
165
+ </s:complexType>
166
+ <s:complexType name="FilterRequest">
167
+ <s:sequence>
168
+ <s:element minOccurs="0" maxOccurs="1" name="Filters" type="s:string"/>
169
+ <s:element minOccurs="1" maxOccurs="1" name="MaxCount" type="s:int"/>
170
+ </s:sequence>
171
+ </s:complexType>
172
+ <s:element name="BatchDeleteResponse">
173
+ <s:complexType>
174
+ <s:sequence>
175
+ <s:element minOccurs="0" maxOccurs="1" name="BatchDeleteResult" type="tns:DeleteResult"/>
176
+ </s:sequence>
177
+ </s:complexType>
178
+ </s:element>
179
+ <s:complexType name="DeleteResult">
180
+ <s:complexContent mixed="false">
181
+ <s:extension base="tns:FilterResult"/>
182
+ </s:complexContent>
183
+ </s:complexType>
184
+ <s:complexType name="FilterResult">
185
+ <s:complexContent mixed="false">
186
+ <s:extension base="tns:BaseResult">
187
+ <s:sequence>
188
+ <s:element minOccurs="1" maxOccurs="1" name="Count" type="s:int"/>
189
+ </s:sequence>
190
+ </s:extension>
191
+ </s:complexContent>
192
+ </s:complexType>
193
+ <s:element name="BatchProcess">
194
+ <s:complexType>
195
+ <s:sequence>
196
+ <s:element minOccurs="0" maxOccurs="1" name="BatchProcessRequest" type="tns:BatchProcessRequest"/>
197
+ </s:sequence>
198
+ </s:complexType>
199
+ </s:element>
200
+ <s:complexType name="BatchProcessRequest">
201
+ <s:complexContent mixed="false">
202
+ <s:extension base="tns:FilterRequest"/>
203
+ </s:complexContent>
204
+ </s:complexType>
205
+ <s:element name="BatchProcessResponse">
206
+ <s:complexType>
207
+ <s:sequence>
208
+ <s:element minOccurs="0" maxOccurs="1" name="BatchProcessResult" type="tns:BatchProcessResult"/>
209
+ </s:sequence>
210
+ </s:complexType>
211
+ </s:element>
212
+ <s:complexType name="BatchProcessResult">
213
+ <s:complexContent mixed="false">
214
+ <s:extension base="tns:FilterResult"/>
215
+ </s:complexContent>
216
+ </s:complexType>
217
+ <s:element name="BatchFileFetch">
218
+ <s:complexType>
219
+ <s:sequence>
220
+ <s:element minOccurs="0" maxOccurs="1" name="FetchRequest" type="tns:FetchRequest"/>
221
+ </s:sequence>
222
+ </s:complexType>
223
+ </s:element>
224
+ <s:element name="BatchFileFetchResponse">
225
+ <s:complexType>
226
+ <s:sequence>
227
+ <s:element minOccurs="0" maxOccurs="1" name="BatchFileFetchResult" type="tns:BatchFileFetchResult"/>
228
+ </s:sequence>
229
+ </s:complexType>
230
+ </s:element>
231
+ <s:complexType name="BatchFileFetchResult">
232
+ <s:complexContent mixed="false">
233
+ <s:extension base="tns:BaseResult">
234
+ <s:sequence>
235
+ <s:element minOccurs="0" maxOccurs="1" name="BatchFiles" type="tns:ArrayOfBatchFile"/>
236
+ <s:element minOccurs="1" maxOccurs="1" name="RecordCount" type="s:int"/>
237
+ </s:sequence>
238
+ </s:extension>
239
+ </s:complexContent>
240
+ </s:complexType>
241
+ <s:element name="BatchFileSave">
242
+ <s:complexType>
243
+ <s:sequence>
244
+ <s:element minOccurs="0" maxOccurs="1" name="BatchFile" type="tns:BatchFile"/>
245
+ </s:sequence>
246
+ </s:complexType>
247
+ </s:element>
248
+ <s:element name="BatchFileSaveResponse">
249
+ <s:complexType>
250
+ <s:sequence>
251
+ <s:element minOccurs="0" maxOccurs="1" name="BatchFileSaveResult" type="tns:BatchFileSaveResult"/>
252
+ </s:sequence>
253
+ </s:complexType>
254
+ </s:element>
255
+ <s:complexType name="BatchFileSaveResult">
256
+ <s:complexContent mixed="false">
257
+ <s:extension base="tns:BaseResult">
258
+ <s:sequence>
259
+ <s:element minOccurs="1" maxOccurs="1" name="BatchFileId" type="s:int"/>
260
+ </s:sequence>
261
+ </s:extension>
262
+ </s:complexContent>
263
+ </s:complexType>
264
+ <s:element name="BatchFileDelete">
265
+ <s:complexType>
266
+ <s:sequence>
267
+ <s:element minOccurs="0" maxOccurs="1" name="DeleteRequest" type="tns:DeleteRequest"/>
268
+ </s:sequence>
269
+ </s:complexType>
270
+ </s:element>
271
+ <s:element name="BatchFileDeleteResponse">
272
+ <s:complexType>
273
+ <s:sequence>
274
+ <s:element minOccurs="0" maxOccurs="1" name="BatchFileDeleteResult" type="tns:DeleteResult"/>
275
+ </s:sequence>
276
+ </s:complexType>
277
+ </s:element>
278
+ <s:element name="Ping">
279
+ <s:complexType>
280
+ <s:sequence>
281
+ <s:element minOccurs="0" maxOccurs="1" name="Message" type="s:string"/>
282
+ </s:sequence>
283
+ </s:complexType>
284
+ </s:element>
285
+ <s:element name="PingResponse">
286
+ <s:complexType>
287
+ <s:sequence>
288
+ <s:element minOccurs="0" maxOccurs="1" name="PingResult" type="tns:PingResult"/>
289
+ </s:sequence>
290
+ </s:complexType>
291
+ </s:element>
292
+ <s:complexType name="PingResult">
293
+ <s:complexContent mixed="false">
294
+ <s:extension base="tns:BaseResult">
295
+ <s:sequence>
296
+ <s:element minOccurs="0" maxOccurs="1" name="Version" type="s:string"/>
297
+ </s:sequence>
298
+ </s:extension>
299
+ </s:complexContent>
300
+ </s:complexType>
301
+ <s:element name="IsAuthorized">
302
+ <s:complexType>
303
+ <s:sequence>
304
+ <s:element minOccurs="0" maxOccurs="1" name="Operations" type="s:string"/>
305
+ </s:sequence>
306
+ </s:complexType>
307
+ </s:element>
308
+ <s:element name="IsAuthorizedResponse">
309
+ <s:complexType>
310
+ <s:sequence>
311
+ <s:element minOccurs="0" maxOccurs="1" name="IsAuthorizedResult" type="tns:IsAuthorizedResult"/>
312
+ </s:sequence>
313
+ </s:complexType>
314
+ </s:element>
315
+ <s:complexType name="IsAuthorizedResult">
316
+ <s:complexContent mixed="false">
317
+ <s:extension base="tns:BaseResult">
318
+ <s:sequence>
319
+ <s:element minOccurs="0" maxOccurs="1" name="Operations" type="s:string"/>
320
+ <s:element minOccurs="1" maxOccurs="1" name="Expires" type="s:dateTime"/>
321
+ </s:sequence>
322
+ </s:extension>
323
+ </s:complexContent>
324
+ </s:complexType>
325
+ </s:schema>
326
+ </wsdl:types>
327
+ <wsdl:message name="BatchFetchSoapIn">
328
+ <wsdl:part name="parameters" element="tns:BatchFetch"/>
329
+ </wsdl:message>
330
+ <wsdl:message name="BatchFetchSoapOut">
331
+ <wsdl:part name="parameters" element="tns:BatchFetchResponse"/>
332
+ </wsdl:message>
333
+ <wsdl:message name="BatchFetchProfile">
334
+ <wsdl:part name="Profile" element="tns:Profile"/>
335
+ </wsdl:message>
336
+ <wsdl:message name="BatchSaveSoapIn">
337
+ <wsdl:part name="parameters" element="tns:BatchSave"/>
338
+ </wsdl:message>
339
+ <wsdl:message name="BatchSaveSoapOut">
340
+ <wsdl:part name="parameters" element="tns:BatchSaveResponse"/>
341
+ </wsdl:message>
342
+ <wsdl:message name="BatchSaveAuditMessage">
343
+ <wsdl:part name="AuditMessage" element="tns:AuditMessage"/>
344
+ </wsdl:message>
345
+ <wsdl:message name="BatchSaveProfile">
346
+ <wsdl:part name="Profile" element="tns:Profile"/>
347
+ </wsdl:message>
348
+ <wsdl:message name="BatchDeleteSoapIn">
349
+ <wsdl:part name="parameters" element="tns:BatchDelete"/>
350
+ </wsdl:message>
351
+ <wsdl:message name="BatchDeleteSoapOut">
352
+ <wsdl:part name="parameters" element="tns:BatchDeleteResponse"/>
353
+ </wsdl:message>
354
+ <wsdl:message name="BatchDeleteAuditMessage">
355
+ <wsdl:part name="AuditMessage" element="tns:AuditMessage"/>
356
+ </wsdl:message>
357
+ <wsdl:message name="BatchDeleteProfile">
358
+ <wsdl:part name="Profile" element="tns:Profile"/>
359
+ </wsdl:message>
360
+ <wsdl:message name="BatchProcessSoapIn">
361
+ <wsdl:part name="parameters" element="tns:BatchProcess"/>
362
+ </wsdl:message>
363
+ <wsdl:message name="BatchProcessSoapOut">
364
+ <wsdl:part name="parameters" element="tns:BatchProcessResponse"/>
365
+ </wsdl:message>
366
+ <wsdl:message name="BatchProcessProfile">
367
+ <wsdl:part name="Profile" element="tns:Profile"/>
368
+ </wsdl:message>
369
+ <wsdl:message name="BatchFileFetchSoapIn">
370
+ <wsdl:part name="parameters" element="tns:BatchFileFetch"/>
371
+ </wsdl:message>
372
+ <wsdl:message name="BatchFileFetchSoapOut">
373
+ <wsdl:part name="parameters" element="tns:BatchFileFetchResponse"/>
374
+ </wsdl:message>
375
+ <wsdl:message name="BatchFileFetchProfile">
376
+ <wsdl:part name="Profile" element="tns:Profile"/>
377
+ </wsdl:message>
378
+ <wsdl:message name="BatchFileSaveSoapIn">
379
+ <wsdl:part name="parameters" element="tns:BatchFileSave"/>
380
+ </wsdl:message>
381
+ <wsdl:message name="BatchFileSaveSoapOut">
382
+ <wsdl:part name="parameters" element="tns:BatchFileSaveResponse"/>
383
+ </wsdl:message>
384
+ <wsdl:message name="BatchFileSaveProfile">
385
+ <wsdl:part name="Profile" element="tns:Profile"/>
386
+ </wsdl:message>
387
+ <wsdl:message name="BatchFileDeleteSoapIn">
388
+ <wsdl:part name="parameters" element="tns:BatchFileDelete"/>
389
+ </wsdl:message>
390
+ <wsdl:message name="BatchFileDeleteSoapOut">
391
+ <wsdl:part name="parameters" element="tns:BatchFileDeleteResponse"/>
392
+ </wsdl:message>
393
+ <wsdl:message name="BatchFileDeleteProfile">
394
+ <wsdl:part name="Profile" element="tns:Profile"/>
395
+ </wsdl:message>
396
+ <wsdl:message name="PingSoapIn">
397
+ <wsdl:part name="parameters" element="tns:Ping"/>
398
+ </wsdl:message>
399
+ <wsdl:message name="PingSoapOut">
400
+ <wsdl:part name="parameters" element="tns:PingResponse"/>
401
+ </wsdl:message>
402
+ <wsdl:message name="PingProfile">
403
+ <wsdl:part name="Profile" element="tns:Profile"/>
404
+ </wsdl:message>
405
+ <wsdl:message name="IsAuthorizedSoapIn">
406
+ <wsdl:part name="parameters" element="tns:IsAuthorized"/>
407
+ </wsdl:message>
408
+ <wsdl:message name="IsAuthorizedSoapOut">
409
+ <wsdl:part name="parameters" element="tns:IsAuthorizedResponse"/>
410
+ </wsdl:message>
411
+ <wsdl:message name="IsAuthorizedProfile">
412
+ <wsdl:part name="Profile" element="tns:Profile"/>
413
+ </wsdl:message>
414
+ <wsdl:portType name="BatchSvcSoap">
415
+ <wsdl:operation name="BatchFetch">
416
+ <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Fetches one or more Batch</wsdl:documentation>
417
+ <wsdl:input message="tns:BatchFetchSoapIn"/>
418
+ <wsdl:output message="tns:BatchFetchSoapOut"/>
419
+ </wsdl:operation>
420
+ <wsdl:operation name="BatchSave">
421
+ <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Saves a Batch entry</wsdl:documentation>
422
+ <wsdl:input message="tns:BatchSaveSoapIn"/>
423
+ <wsdl:output message="tns:BatchSaveSoapOut"/>
424
+ </wsdl:operation>
425
+ <wsdl:operation name="BatchDelete">
426
+ <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Deletes one or more Batches</wsdl:documentation>
427
+ <wsdl:input message="tns:BatchDeleteSoapIn"/>
428
+ <wsdl:output message="tns:BatchDeleteSoapOut"/>
429
+ </wsdl:operation>
430
+ <wsdl:operation name="BatchProcess">
431
+ <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Processes one or more Batches</wsdl:documentation>
432
+ <wsdl:input message="tns:BatchProcessSoapIn"/>
433
+ <wsdl:output message="tns:BatchProcessSoapOut"/>
434
+ </wsdl:operation>
435
+ <wsdl:operation name="BatchFileFetch">
436
+ <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Fetches one or more BatchFiles</wsdl:documentation>
437
+ <wsdl:input message="tns:BatchFileFetchSoapIn"/>
438
+ <wsdl:output message="tns:BatchFileFetchSoapOut"/>
439
+ </wsdl:operation>
440
+ <wsdl:operation name="BatchFileSave">
441
+ <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Saves a Batch File</wsdl:documentation>
442
+ <wsdl:input message="tns:BatchFileSaveSoapIn"/>
443
+ <wsdl:output message="tns:BatchFileSaveSoapOut"/>
444
+ </wsdl:operation>
445
+ <wsdl:operation name="BatchFileDelete">
446
+ <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Deletes one or more BatchFiles</wsdl:documentation>
447
+ <wsdl:input message="tns:BatchFileDeleteSoapIn"/>
448
+ <wsdl:output message="tns:BatchFileDeleteSoapOut"/>
449
+ </wsdl:operation>
450
+ <wsdl:operation name="Ping">
451
+ <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Tests connectivity and version of the service</wsdl:documentation>
452
+ <wsdl:input message="tns:PingSoapIn"/>
453
+ <wsdl:output message="tns:PingSoapOut"/>
454
+ </wsdl:operation>
455
+ <wsdl:operation name="IsAuthorized">
456
+ <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Checks authentication and authorization to one or more operations on the service.</wsdl:documentation>
457
+ <wsdl:input message="tns:IsAuthorizedSoapIn"/>
458
+ <wsdl:output message="tns:IsAuthorizedSoapOut"/>
459
+ </wsdl:operation>
460
+ </wsdl:portType>
461
+ <wsdl:binding name="BatchSvcSoap" type="tns:BatchSvcSoap">
462
+ <soap:binding transport="http://schemas.xmlsoap.org/soap/http"/>
463
+ <wsdl:operation name="BatchFetch">
464
+ <soap:operation soapAction="http://avatax.avalara.com/services/BatchFetch" style="document"/>
465
+ <wsdl:input>
466
+ <soap:body use="literal"/>
467
+ <soap:header message="tns:BatchFetchProfile" part="Profile" use="literal"/>
468
+ </wsdl:input>
469
+ <wsdl:output>
470
+ <soap:body use="literal"/>
471
+ </wsdl:output>
472
+ </wsdl:operation>
473
+ <wsdl:operation name="BatchSave">
474
+ <soap:operation soapAction="http://avatax.avalara.com/services/BatchSave" style="document"/>
475
+ <wsdl:input>
476
+ <soap:body use="literal"/>
477
+ <soap:header message="tns:BatchSaveAuditMessage" part="AuditMessage" use="literal"/>
478
+ <soap:header message="tns:BatchSaveProfile" part="Profile" use="literal"/>
479
+ </wsdl:input>
480
+ <wsdl:output>
481
+ <soap:body use="literal"/>
482
+ </wsdl:output>
483
+ </wsdl:operation>
484
+ <wsdl:operation name="BatchDelete">
485
+ <soap:operation soapAction="http://avatax.avalara.com/services/BatchDelete" style="document"/>
486
+ <wsdl:input>
487
+ <soap:body use="literal"/>
488
+ <soap:header message="tns:BatchDeleteAuditMessage" part="AuditMessage" use="literal"/>
489
+ <soap:header message="tns:BatchDeleteProfile" part="Profile" use="literal"/>
490
+ </wsdl:input>
491
+ <wsdl:output>
492
+ <soap:body use="literal"/>
493
+ </wsdl:output>
494
+ </wsdl:operation>
495
+ <wsdl:operation name="BatchProcess">
496
+ <soap:operation soapAction="http://avatax.avalara.com/services/BatchProcess" style="document"/>
497
+ <wsdl:input>
498
+ <soap:body use="literal"/>
499
+ <soap:header message="tns:BatchProcessProfile" part="Profile" use="literal"/>
500
+ </wsdl:input>
501
+ <wsdl:output>
502
+ <soap:body use="literal"/>
503
+ </wsdl:output>
504
+ </wsdl:operation>
505
+ <wsdl:operation name="BatchFileFetch">
506
+ <soap:operation soapAction="http://avatax.avalara.com/services/BatchFileFetch" style="document"/>
507
+ <wsdl:input>
508
+ <soap:body use="literal"/>
509
+ <soap:header message="tns:BatchFileFetchProfile" part="Profile" use="literal"/>
510
+ </wsdl:input>
511
+ <wsdl:output>
512
+ <soap:body use="literal"/>
513
+ </wsdl:output>
514
+ </wsdl:operation>
515
+ <wsdl:operation name="BatchFileSave">
516
+ <soap:operation soapAction="http://avatax.avalara.com/services/BatchFileSave" style="document"/>
517
+ <wsdl:input>
518
+ <soap:body use="literal"/>
519
+ <soap:header message="tns:BatchFileSaveProfile" part="Profile" use="literal"/>
520
+ </wsdl:input>
521
+ <wsdl:output>
522
+ <soap:body use="literal"/>
523
+ </wsdl:output>
524
+ </wsdl:operation>
525
+ <wsdl:operation name="BatchFileDelete">
526
+ <soap:operation soapAction="http://avatax.avalara.com/services/BatchFileDelete" style="document"/>
527
+ <wsdl:input>
528
+ <soap:body use="literal"/>
529
+ <soap:header message="tns:BatchFileDeleteProfile" part="Profile" use="literal"/>
530
+ </wsdl:input>
531
+ <wsdl:output>
532
+ <soap:body use="literal"/>
533
+ </wsdl:output>
534
+ </wsdl:operation>
535
+ <wsdl:operation name="Ping">
536
+ <soap:operation soapAction="http://avatax.avalara.com/services/Ping" style="document"/>
537
+ <wsdl:input>
538
+ <soap:body use="literal"/>
539
+ <soap:header message="tns:PingProfile" part="Profile" use="literal"/>
540
+ </wsdl:input>
541
+ <wsdl:output>
542
+ <soap:body use="literal"/>
543
+ </wsdl:output>
544
+ </wsdl:operation>
545
+ <wsdl:operation name="IsAuthorized">
546
+ <soap:operation soapAction="http://avatax.avalara.com/services/IsAuthorized" style="document"/>
547
+ <wsdl:input>
548
+ <soap:body use="literal"/>
549
+ <soap:header message="tns:IsAuthorizedProfile" part="Profile" use="literal"/>
550
+ </wsdl:input>
551
+ <wsdl:output>
552
+ <soap:body use="literal"/>
553
+ </wsdl:output>
554
+ </wsdl:operation>
555
+ </wsdl:binding>
556
+ <wsdl:binding name="BatchSvcSoap12" type="tns:BatchSvcSoap">
557
+ <soap12:binding transport="http://schemas.xmlsoap.org/soap/http"/>
558
+ <wsdl:operation name="BatchFetch">
559
+ <soap12:operation soapAction="http://avatax.avalara.com/services/BatchFetch" style="document"/>
560
+ <wsdl:input>
561
+ <soap12:body use="literal"/>
562
+ <soap12:header message="tns:BatchFetchProfile" part="Profile" use="literal"/>
563
+ </wsdl:input>
564
+ <wsdl:output>
565
+ <soap12:body use="literal"/>
566
+ </wsdl:output>
567
+ </wsdl:operation>
568
+ <wsdl:operation name="BatchSave">
569
+ <soap12:operation soapAction="http://avatax.avalara.com/services/BatchSave" style="document"/>
570
+ <wsdl:input>
571
+ <soap12:body use="literal"/>
572
+ <soap12:header message="tns:BatchSaveAuditMessage" part="AuditMessage" use="literal"/>
573
+ <soap12:header message="tns:BatchSaveProfile" part="Profile" use="literal"/>
574
+ </wsdl:input>
575
+ <wsdl:output>
576
+ <soap12:body use="literal"/>
577
+ </wsdl:output>
578
+ </wsdl:operation>
579
+ <wsdl:operation name="BatchDelete">
580
+ <soap12:operation soapAction="http://avatax.avalara.com/services/BatchDelete" style="document"/>
581
+ <wsdl:input>
582
+ <soap12:body use="literal"/>
583
+ <soap12:header message="tns:BatchDeleteAuditMessage" part="AuditMessage" use="literal"/>
584
+ <soap12:header message="tns:BatchDeleteProfile" part="Profile" use="literal"/>
585
+ </wsdl:input>
586
+ <wsdl:output>
587
+ <soap12:body use="literal"/>
588
+ </wsdl:output>
589
+ </wsdl:operation>
590
+ <wsdl:operation name="BatchProcess">
591
+ <soap12:operation soapAction="http://avatax.avalara.com/services/BatchProcess" style="document"/>
592
+ <wsdl:input>
593
+ <soap12:body use="literal"/>
594
+ <soap12:header message="tns:BatchProcessProfile" part="Profile" use="literal"/>
595
+ </wsdl:input>
596
+ <wsdl:output>
597
+ <soap12:body use="literal"/>
598
+ </wsdl:output>
599
+ </wsdl:operation>
600
+ <wsdl:operation name="BatchFileFetch">
601
+ <soap12:operation soapAction="http://avatax.avalara.com/services/BatchFileFetch" style="document"/>
602
+ <wsdl:input>
603
+ <soap12:body use="literal"/>
604
+ <soap12:header message="tns:BatchFileFetchProfile" part="Profile" use="literal"/>
605
+ </wsdl:input>
606
+ <wsdl:output>
607
+ <soap12:body use="literal"/>
608
+ </wsdl:output>
609
+ </wsdl:operation>
610
+ <wsdl:operation name="BatchFileSave">
611
+ <soap12:operation soapAction="http://avatax.avalara.com/services/BatchFileSave" style="document"/>
612
+ <wsdl:input>
613
+ <soap12:body use="literal"/>
614
+ <soap12:header message="tns:BatchFileSaveProfile" part="Profile" use="literal"/>
615
+ </wsdl:input>
616
+ <wsdl:output>
617
+ <soap12:body use="literal"/>
618
+ </wsdl:output>
619
+ </wsdl:operation>
620
+ <wsdl:operation name="BatchFileDelete">
621
+ <soap12:operation soapAction="http://avatax.avalara.com/services/BatchFileDelete" style="document"/>
622
+ <wsdl:input>
623
+ <soap12:body use="literal"/>
624
+ <soap12:header message="tns:BatchFileDeleteProfile" part="Profile" use="literal"/>
625
+ </wsdl:input>
626
+ <wsdl:output>
627
+ <soap12:body use="literal"/>
628
+ </wsdl:output>
629
+ </wsdl:operation>
630
+ <wsdl:operation name="Ping">
631
+ <soap12:operation soapAction="http://avatax.avalara.com/services/Ping" style="document"/>
632
+ <wsdl:input>
633
+ <soap12:body use="literal"/>
634
+ <soap12:header message="tns:PingProfile" part="Profile" use="literal"/>
635
+ </wsdl:input>
636
+ <wsdl:output>
637
+ <soap12:body use="literal"/>
638
+ </wsdl:output>
639
+ </wsdl:operation>
640
+ <wsdl:operation name="IsAuthorized">
641
+ <soap12:operation soapAction="http://avatax.avalara.com/services/IsAuthorized" style="document"/>
642
+ <wsdl:input>
643
+ <soap12:body use="literal"/>
644
+ <soap12:header message="tns:IsAuthorizedProfile" part="Profile" use="literal"/>
645
+ </wsdl:input>
646
+ <wsdl:output>
647
+ <soap12:body use="literal"/>
648
+ </wsdl:output>
649
+ </wsdl:operation>
650
+ </wsdl:binding>
651
+ <wsdl:service name="BatchSvc">
652
+ <wsdl:port name="BatchSvcSoap" binding="tns:BatchSvcSoap">
653
+ <soap:address location="http://localhost/avatax.services/Batch/BatchSvc.asmx"/>
654
+ </wsdl:port>
655
+ <wsdl:port name="BatchSvcSoap12" binding="tns:BatchSvcSoap12">
656
+ <soap12:address location="http://localhost/avatax.services/Batch/BatchSvc.asmx"/>
657
+ </wsdl:port>
658
+ </wsdl:service>
659
  </wsdl:definitions>
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/classes/wsdl/Tax.wsdl RENAMED
@@ -1,1280 +1,1280 @@
1
- <?xml version="1.0" encoding="utf-8"?>
2
- <wsdl:definitions xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:tm="http://microsoft.com/wsdl/mime/textMatching/" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/" xmlns:tns="http://avatax.avalara.com/services" xmlns:s="http://www.w3.org/2001/XMLSchema" xmlns:soap12="http://schemas.xmlsoap.org/wsdl/soap12/" xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" targetNamespace="http://avatax.avalara.com/services" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">
3
- <wsdl:types>
4
- <s:schema elementFormDefault="qualified" targetNamespace="http://avatax.avalara.com/services">
5
- <s:element name="GetTax">
6
- <s:complexType>
7
- <s:sequence>
8
- <s:element minOccurs="0" maxOccurs="1" name="GetTaxRequest" type="tns:GetTaxRequest" />
9
- </s:sequence>
10
- </s:complexType>
11
- </s:element>
12
- <s:complexType name="BaseRequest" />
13
- <s:complexType name="GetTaxRequest">
14
- <s:complexContent mixed="false">
15
- <s:extension base="tns:BaseRequest">
16
- <s:sequence>
17
- <s:element minOccurs="0" maxOccurs="1" name="CompanyCode" type="s:string" />
18
- <s:element minOccurs="1" maxOccurs="1" name="DocType" type="tns:DocumentType" />
19
- <s:element minOccurs="0" maxOccurs="1" name="DocCode" type="s:string" />
20
- <s:element minOccurs="1" maxOccurs="1" name="DocDate" type="s:date" />
21
- <s:element minOccurs="0" maxOccurs="1" name="SalespersonCode" type="s:string" />
22
- <s:element minOccurs="0" maxOccurs="1" name="CustomerCode" type="s:string" />
23
- <s:element minOccurs="0" maxOccurs="1" name="CustomerUsageType" type="s:string" />
24
- <s:element minOccurs="1" maxOccurs="1" name="Discount" type="s:decimal" />
25
- <s:element minOccurs="0" maxOccurs="1" name="PurchaseOrderNo" type="s:string" />
26
- <s:element minOccurs="0" maxOccurs="1" name="ExemptionNo" type="s:string" />
27
- <s:element minOccurs="0" maxOccurs="1" name="OriginCode" type="s:string" />
28
- <s:element minOccurs="0" maxOccurs="1" name="DestinationCode" type="s:string" />
29
- <s:element minOccurs="0" maxOccurs="1" name="Addresses" type="tns:ArrayOfBaseAddress" />
30
- <s:element minOccurs="0" maxOccurs="1" name="Lines" type="tns:ArrayOfLine" />
31
- <s:element minOccurs="1" maxOccurs="1" name="DetailLevel" type="tns:DetailLevel" />
32
- <s:element minOccurs="0" maxOccurs="1" name="ReferenceCode" type="s:string" />
33
- <s:element minOccurs="1" maxOccurs="1" name="HashCode" type="s:int" />
34
- <s:element minOccurs="0" maxOccurs="1" name="LocationCode" type="s:string" />
35
- <s:element minOccurs="1" maxOccurs="1" name="Commit" type="s:boolean" />
36
- <s:element minOccurs="0" maxOccurs="1" name="BatchCode" type="s:string" />
37
- <s:element minOccurs="0" maxOccurs="1" name="TaxOverride" type="tns:TaxOverride" />
38
- <s:element minOccurs="0" maxOccurs="1" name="CurrencyCode" type="s:string" />
39
- <s:element minOccurs="1" maxOccurs="1" name="ServiceMode" type="tns:ServiceMode" />
40
- <s:element minOccurs="1" maxOccurs="1" name="PaymentDate" type="s:date" />
41
- <s:element minOccurs="1" maxOccurs="1" name="ExchangeRate" type="s:decimal" />
42
- <s:element minOccurs="1" maxOccurs="1" name="ExchangeRateEffDate" type="s:date" />
43
- <s:element minOccurs="1" maxOccurs="1" name="TaxDate" type="s:date" />
44
- <s:element minOccurs="1" maxOccurs="1" name="StatusDate" type="s:date" />
45
- </s:sequence>
46
- </s:extension>
47
- </s:complexContent>
48
- </s:complexType>
49
- <s:simpleType name="DocumentType">
50
- <s:restriction base="s:string">
51
- <s:enumeration value="SalesOrder" />
52
- <s:enumeration value="SalesInvoice" />
53
- <s:enumeration value="PurchaseOrder" />
54
- <s:enumeration value="PurchaseInvoice" />
55
- <s:enumeration value="ReturnOrder" />
56
- <s:enumeration value="ReturnInvoice" />
57
- <s:enumeration value="PendingAdjustment" />
58
- <s:enumeration value="Any" />
59
- </s:restriction>
60
- </s:simpleType>
61
- <s:complexType name="ArrayOfBaseAddress">
62
- <s:sequence>
63
- <s:element minOccurs="0" maxOccurs="unbounded" name="BaseAddress" nillable="true" type="tns:BaseAddress" />
64
- </s:sequence>
65
- </s:complexType>
66
- <s:complexType name="BaseAddress">
67
- <s:sequence>
68
- <s:element minOccurs="0" maxOccurs="1" name="AddressCode" type="s:string" />
69
- <s:element minOccurs="0" maxOccurs="1" name="Line1" type="s:string" />
70
- <s:element minOccurs="0" maxOccurs="1" name="Line2" type="s:string" />
71
- <s:element minOccurs="0" maxOccurs="1" name="Line3" type="s:string" />
72
- <s:element minOccurs="0" maxOccurs="1" name="City" type="s:string" />
73
- <s:element minOccurs="0" maxOccurs="1" name="Region" type="s:string" />
74
- <s:element minOccurs="0" maxOccurs="1" name="PostalCode" type="s:string" />
75
- <s:element minOccurs="0" maxOccurs="1" name="Country" type="s:string" />
76
- <s:element minOccurs="1" maxOccurs="1" name="TaxRegionId" type="s:int" />
77
- </s:sequence>
78
- </s:complexType>
79
- <s:complexType name="ArrayOfLine">
80
- <s:sequence>
81
- <s:element minOccurs="0" maxOccurs="unbounded" name="Line" nillable="true" type="tns:Line" />
82
- </s:sequence>
83
- </s:complexType>
84
- <s:complexType name="Line">
85
- <s:sequence>
86
- <s:element minOccurs="0" maxOccurs="1" name="No" type="s:string" />
87
- <s:element minOccurs="0" maxOccurs="1" name="OriginCode" type="s:string" />
88
- <s:element minOccurs="0" maxOccurs="1" name="DestinationCode" type="s:string" />
89
- <s:element minOccurs="0" maxOccurs="1" name="ItemCode" type="s:string" />
90
- <s:element minOccurs="0" maxOccurs="1" name="TaxCode" type="s:string" />
91
- <s:element minOccurs="1" maxOccurs="1" name="Qty" type="s:decimal" />
92
- <s:element minOccurs="1" maxOccurs="1" name="Amount" type="s:decimal" />
93
- <s:element minOccurs="1" maxOccurs="1" name="Discounted" type="s:boolean" />
94
- <s:element minOccurs="0" maxOccurs="1" name="RevAcct" type="s:string" />
95
- <s:element minOccurs="0" maxOccurs="1" name="Ref1" type="s:string" />
96
- <s:element minOccurs="0" maxOccurs="1" name="Ref2" type="s:string" />
97
- <s:element minOccurs="0" maxOccurs="1" name="ExemptionNo" type="s:string" />
98
- <s:element minOccurs="0" maxOccurs="1" name="CustomerUsageType" type="s:string" />
99
- <s:element minOccurs="0" maxOccurs="1" name="Description" type="s:string" />
100
- <s:element minOccurs="0" maxOccurs="1" name="TaxOverride" type="tns:TaxOverride" />
101
- <s:element minOccurs="0" maxOccurs="1" name="TaxIncluded" type="s:boolean" default="false" />
102
- </s:sequence>
103
- </s:complexType>
104
- <s:complexType name="TaxOverride">
105
- <s:sequence>
106
- <s:element minOccurs="1" maxOccurs="1" name="TaxOverrideType" type="tns:TaxOverrideType" />
107
- <s:element minOccurs="1" maxOccurs="1" name="TaxAmount" type="s:decimal" />
108
- <s:element minOccurs="1" maxOccurs="1" name="TaxDate" type="s:date" />
109
- <s:element minOccurs="0" maxOccurs="1" name="Reason" type="s:string" />
110
- </s:sequence>
111
- </s:complexType>
112
- <s:simpleType name="TaxOverrideType">
113
- <s:restriction base="s:string">
114
- <s:enumeration value="None" />
115
- <s:enumeration value="TaxAmount" />
116
- <s:enumeration value="Exemption" />
117
- <s:enumeration value="TaxDate" />
118
- </s:restriction>
119
- </s:simpleType>
120
- <s:simpleType name="DetailLevel">
121
- <s:restriction base="s:string">
122
- <s:enumeration value="Document" />
123
- <s:enumeration value="Summary" />
124
- <s:enumeration value="Line" />
125
- <s:enumeration value="Tax" />
126
- <s:enumeration value="Diagnostic" />
127
- </s:restriction>
128
- </s:simpleType>
129
- <s:simpleType name="ServiceMode">
130
- <s:restriction base="s:string">
131
- <s:enumeration value="Automatic" />
132
- <s:enumeration value="Local" />
133
- <s:enumeration value="Remote" />
134
- </s:restriction>
135
- </s:simpleType>
136
- <s:element name="GetTaxResponse">
137
- <s:complexType>
138
- <s:sequence>
139
- <s:element minOccurs="0" maxOccurs="1" name="GetTaxResult" type="tns:GetTaxResult" />
140
- </s:sequence>
141
- </s:complexType>
142
- </s:element>
143
- <s:complexType name="GetTaxResult">
144
- <s:complexContent mixed="false">
145
- <s:extension base="tns:BaseResult">
146
- <s:sequence>
147
- <s:element minOccurs="0" maxOccurs="1" name="DocId" type="s:string" />
148
- <s:element minOccurs="1" maxOccurs="1" name="DocType" type="tns:DocumentType" />
149
- <s:element minOccurs="0" maxOccurs="1" name="DocCode" type="s:string" />
150
- <s:element minOccurs="1" maxOccurs="1" name="DocDate" type="s:date" />
151
- <s:element minOccurs="1" maxOccurs="1" name="DocStatus" type="tns:DocStatus" />
152
- <s:element minOccurs="1" maxOccurs="1" name="Reconciled" type="s:boolean" />
153
- <s:element minOccurs="1" maxOccurs="1" name="Timestamp" type="s:dateTime" />
154
- <s:element minOccurs="1" maxOccurs="1" name="TotalAmount" type="s:decimal" />
155
- <s:element minOccurs="1" maxOccurs="1" name="TotalDiscount" type="s:decimal" />
156
- <s:element minOccurs="1" maxOccurs="1" name="TotalExemption" type="s:decimal" />
157
- <s:element minOccurs="1" maxOccurs="1" name="TotalTaxable" type="s:decimal" />
158
- <s:element minOccurs="1" maxOccurs="1" name="TotalTax" type="s:decimal" />
159
- <s:element minOccurs="1" maxOccurs="1" name="TotalTaxCalculated" type="s:decimal" />
160
- <s:element minOccurs="1" maxOccurs="1" name="HashCode" type="s:int" />
161
- <s:element minOccurs="0" maxOccurs="1" name="TaxLines" type="tns:ArrayOfTaxLine" />
162
- <s:element minOccurs="0" maxOccurs="1" name="TaxAddresses" type="tns:ArrayOfTaxAddress" />
163
- <s:element minOccurs="1" maxOccurs="1" name="Locked" type="s:boolean" />
164
- <s:element minOccurs="1" maxOccurs="1" name="AdjustmentReason" type="s:int" />
165
- <s:element minOccurs="0" maxOccurs="1" name="AdjustmentDescription" type="s:string" />
166
- <s:element minOccurs="1" maxOccurs="1" name="Version" type="s:int" />
167
- <s:element minOccurs="1" maxOccurs="1" name="TaxDate" type="s:date" />
168
- <s:element minOccurs="0" maxOccurs="1" name="TaxSummary" type="tns:ArrayOfTaxDetail" />
169
- <s:element minOccurs="0" maxOccurs="1" name="Signature" type="s:string" />
170
- </s:sequence>
171
- </s:extension>
172
- </s:complexContent>
173
- </s:complexType>
174
- <s:complexType name="BaseResult">
175
- <s:sequence>
176
- <s:element minOccurs="0" maxOccurs="1" name="TransactionId" type="s:string" />
177
- <s:element minOccurs="1" maxOccurs="1" name="ResultCode" type="tns:SeverityLevel" />
178
- <s:element minOccurs="0" maxOccurs="1" name="Messages" type="tns:ArrayOfMessage" />
179
- </s:sequence>
180
- </s:complexType>
181
- <s:simpleType name="SeverityLevel">
182
- <s:restriction base="s:string">
183
- <s:enumeration value="Success" />
184
- <s:enumeration value="Warning" />
185
- <s:enumeration value="Error" />
186
- <s:enumeration value="Exception" />
187
- </s:restriction>
188
- </s:simpleType>
189
- <s:complexType name="ArrayOfMessage">
190
- <s:sequence>
191
- <s:element minOccurs="0" maxOccurs="unbounded" name="Message" nillable="true" type="tns:Message" />
192
- </s:sequence>
193
- </s:complexType>
194
- <s:complexType name="Message">
195
- <s:sequence>
196
- <s:element minOccurs="0" maxOccurs="1" name="Summary" type="s:string" />
197
- <s:element minOccurs="0" maxOccurs="1" name="Details" type="s:string" />
198
- <s:element minOccurs="0" maxOccurs="1" name="HelpLink" type="s:string" />
199
- <s:element minOccurs="0" maxOccurs="1" name="RefersTo" type="s:string" />
200
- <s:element minOccurs="1" maxOccurs="1" name="Severity" type="tns:SeverityLevel" />
201
- <s:element minOccurs="0" maxOccurs="1" name="Source" type="s:string" />
202
- </s:sequence>
203
- <s:attribute name="Name" type="s:string" />
204
- </s:complexType>
205
- <s:simpleType name="DocStatus">
206
- <s:restriction base="s:string">
207
- <s:enumeration value="Temporary" />
208
- <s:enumeration value="Saved" />
209
- <s:enumeration value="Posted" />
210
- <s:enumeration value="Committed" />
211
- <s:enumeration value="Cancelled" />
212
- <s:enumeration value="Adjusted" />
213
- <s:enumeration value="Any" />
214
- </s:restriction>
215
- </s:simpleType>
216
- <s:complexType name="ArrayOfTaxLine">
217
- <s:sequence>
218
- <s:element minOccurs="0" maxOccurs="unbounded" name="TaxLine" nillable="true" type="tns:TaxLine" />
219
- </s:sequence>
220
- </s:complexType>
221
- <s:complexType name="TaxLine">
222
- <s:sequence>
223
- <s:element minOccurs="0" maxOccurs="1" name="No" type="s:string" />
224
- <s:element minOccurs="0" maxOccurs="1" name="TaxCode" type="s:string" />
225
- <s:element minOccurs="1" maxOccurs="1" name="Taxability" type="s:boolean" />
226
- <s:element minOccurs="1" maxOccurs="1" name="BoundaryLevel" type="tns:BoundaryLevel" />
227
- <s:element minOccurs="1" maxOccurs="1" name="Exemption" type="s:decimal" />
228
- <s:element minOccurs="1" maxOccurs="1" name="Discount" type="s:decimal" />
229
- <s:element minOccurs="1" maxOccurs="1" name="Taxable" type="s:decimal" />
230
- <s:element minOccurs="1" maxOccurs="1" name="Rate" type="s:decimal" />
231
- <s:element minOccurs="1" maxOccurs="1" name="Tax" type="s:decimal" />
232
- <s:element minOccurs="1" maxOccurs="1" name="TaxCalculated" type="s:decimal" />
233
- <s:element minOccurs="0" maxOccurs="1" name="TaxDetails" type="tns:ArrayOfTaxDetail" />
234
- <s:element minOccurs="1" maxOccurs="1" name="ExemptCertId" type="s:int" />
235
- <s:element minOccurs="1" maxOccurs="1" name="TaxDate" type="s:date" />
236
- <s:element minOccurs="1" maxOccurs="1" name="ReportingDate" type="s:date" />
237
- <s:element minOccurs="1" maxOccurs="1" name="AccountingMethod" type="tns:AccountingMethod" />
238
- <s:element minOccurs="0" maxOccurs="1" name="TaxIncluded" type="s:boolean" default="false" />
239
- </s:sequence>
240
- </s:complexType>
241
- <s:simpleType name="BoundaryLevel">
242
- <s:restriction base="s:string">
243
- <s:enumeration value="Address" />
244
- <s:enumeration value="Zip9" />
245
- <s:enumeration value="Zip5" />
246
- </s:restriction>
247
- </s:simpleType>
248
- <s:complexType name="ArrayOfTaxDetail">
249
- <s:sequence>
250
- <s:element minOccurs="0" maxOccurs="unbounded" name="TaxDetail" nillable="true" type="tns:TaxDetail" />
251
- </s:sequence>
252
- </s:complexType>
253
- <s:complexType name="TaxDetail">
254
- <s:sequence>
255
- <s:element minOccurs="0" maxOccurs="1" name="Country" type="s:string" />
256
- <s:element minOccurs="0" maxOccurs="1" name="Region" type="s:string" />
257
- <s:element minOccurs="1" maxOccurs="1" name="JurisType" type="tns:JurisdictionType" />
258
- <s:element minOccurs="0" maxOccurs="1" name="JurisCode" type="s:string" />
259
- <s:element minOccurs="1" maxOccurs="1" name="TaxType" type="tns:TaxType" />
260
- <s:element minOccurs="1" maxOccurs="1" name="Base" type="s:decimal" />
261
- <s:element minOccurs="1" maxOccurs="1" name="Taxable" type="s:decimal" />
262
- <s:element minOccurs="1" maxOccurs="1" name="Rate" type="s:decimal" />
263
- <s:element minOccurs="1" maxOccurs="1" name="Tax" type="s:decimal" />
264
- <s:element minOccurs="1" maxOccurs="1" name="TaxCalculated" type="s:decimal" />
265
- <s:element minOccurs="1" maxOccurs="1" name="NonTaxable" type="s:decimal" />
266
- <s:element minOccurs="1" maxOccurs="1" name="Exemption" type="s:decimal" />
267
- <s:element minOccurs="0" maxOccurs="1" name="JurisName" type="s:string" />
268
- <s:element minOccurs="0" maxOccurs="1" name="TaxName" type="s:string" />
269
- <s:element minOccurs="1" maxOccurs="1" name="TaxAuthorityType" type="s:int" />
270
- <s:element minOccurs="0" maxOccurs="1" name="TaxGroup" type="s:string" />
271
- <s:element minOccurs="0" maxOccurs="1" name="RateType" type="s:string" />
272
- <s:element minOccurs="0" maxOccurs="1" name="StateAssignedNo" type="s:string" />
273
- </s:sequence>
274
- </s:complexType>
275
- <s:simpleType name="JurisdictionType">
276
- <s:restriction base="s:string">
277
- <s:enumeration value="Country" />
278
- <s:enumeration value="Composite" />
279
- <s:enumeration value="State" />
280
- <s:enumeration value="County" />
281
- <s:enumeration value="City" />
282
- <s:enumeration value="Special" />
283
- </s:restriction>
284
- </s:simpleType>
285
- <s:simpleType name="TaxType">
286
- <s:restriction base="s:string">
287
- <s:enumeration value="Sales" />
288
- <s:enumeration value="Use" />
289
- <s:enumeration value="ConsumerUse" />
290
- <s:enumeration value="Output" />
291
- <s:enumeration value="Input" />
292
- <s:enumeration value="Nonrecoverable" />
293
- <s:enumeration value="Fee" />
294
- <s:enumeration value="Rental" />
295
- </s:restriction>
296
- </s:simpleType>
297
- <s:simpleType name="AccountingMethod">
298
- <s:restriction base="s:string">
299
- <s:enumeration value="Accrual" />
300
- <s:enumeration value="Cash" />
301
- </s:restriction>
302
- </s:simpleType>
303
- <s:complexType name="ArrayOfTaxAddress">
304
- <s:sequence>
305
- <s:element minOccurs="0" maxOccurs="unbounded" name="TaxAddress" nillable="true" type="tns:TaxAddress" />
306
- </s:sequence>
307
- </s:complexType>
308
- <s:complexType name="TaxAddress">
309
- <s:sequence>
310
- <s:element minOccurs="0" maxOccurs="1" name="Address" type="s:string" />
311
- <s:element minOccurs="0" maxOccurs="1" name="AddressCode" type="s:string" />
312
- <s:element minOccurs="1" maxOccurs="1" name="BoundaryLevel" type="s:int" />
313
- <s:element minOccurs="0" maxOccurs="1" name="City" type="s:string" />
314
- <s:element minOccurs="0" maxOccurs="1" name="Country" type="s:string" />
315
- <s:element minOccurs="0" maxOccurs="1" name="PostalCode" type="s:string" />
316
- <s:element minOccurs="0" maxOccurs="1" name="Region" type="s:string" />
317
- <s:element minOccurs="1" maxOccurs="1" name="TaxRegionId" type="s:int" />
318
- <s:element minOccurs="0" maxOccurs="1" name="JurisCode" type="s:string" />
319
- </s:sequence>
320
- </s:complexType>
321
- <s:element name="Profile" type="tns:Profile" />
322
- <s:complexType name="Profile">
323
- <s:sequence>
324
- <s:element minOccurs="0" maxOccurs="1" name="Name" type="s:string" />
325
- <s:element minOccurs="0" maxOccurs="1" name="Client" type="s:string" />
326
- <s:element minOccurs="0" maxOccurs="1" name="Adapter" type="s:string" />
327
- <s:element minOccurs="0" maxOccurs="1" name="Machine" type="s:string" />
328
- </s:sequence>
329
- <s:anyAttribute />
330
- </s:complexType>
331
- <s:element name="GetTaxHistory">
332
- <s:complexType>
333
- <s:sequence>
334
- <s:element minOccurs="0" maxOccurs="1" name="GetTaxHistoryRequest" type="tns:GetTaxHistoryRequest" />
335
- </s:sequence>
336
- </s:complexType>
337
- </s:element>
338
- <s:complexType name="GetTaxHistoryRequest">
339
- <s:complexContent mixed="false">
340
- <s:extension base="tns:BaseRequest">
341
- <s:sequence>
342
- <s:element minOccurs="0" maxOccurs="1" name="DocId" type="s:string" />
343
- <s:element minOccurs="0" maxOccurs="1" name="CompanyCode" type="s:string" />
344
- <s:element minOccurs="1" maxOccurs="1" name="DocType" type="tns:DocumentType" />
345
- <s:element minOccurs="0" maxOccurs="1" name="DocCode" type="s:string" />
346
- <s:element minOccurs="1" maxOccurs="1" name="DetailLevel" type="tns:DetailLevel" />
347
- </s:sequence>
348
- </s:extension>
349
- </s:complexContent>
350
- </s:complexType>
351
- <s:element name="GetTaxHistoryResponse">
352
- <s:complexType>
353
- <s:sequence>
354
- <s:element minOccurs="0" maxOccurs="1" name="GetTaxHistoryResult" type="tns:GetTaxHistoryResult" />
355
- </s:sequence>
356
- </s:complexType>
357
- </s:element>
358
- <s:complexType name="GetTaxHistoryResult">
359
- <s:complexContent mixed="false">
360
- <s:extension base="tns:BaseResult">
361
- <s:sequence>
362
- <s:element minOccurs="0" maxOccurs="1" name="GetTaxRequest" type="tns:GetTaxRequest" />
363
- <s:element minOccurs="0" maxOccurs="1" name="GetTaxResult" type="tns:GetTaxResult" />
364
- </s:sequence>
365
- </s:extension>
366
- </s:complexContent>
367
- </s:complexType>
368
- <!-- <s:simpleType name="ConfirmationType">
369
- <s:restriction base="s:string">
370
- <s:enumeration value="None" />
371
- <s:enumeration value="Optional" />
372
- <s:enumeration value="Required" />
373
- </s:restriction>
374
- </s:simpleType> -->
375
- <s:element name="PostTax">
376
- <s:complexType>
377
- <s:sequence>
378
- <s:element minOccurs="0" maxOccurs="1" name="PostTaxRequest" type="tns:PostTaxRequest" />
379
- </s:sequence>
380
- </s:complexType>
381
- </s:element>
382
- <s:complexType name="PostTaxRequest">
383
- <s:complexContent mixed="false">
384
- <s:extension base="tns:BaseRequest">
385
- <s:sequence>
386
- <s:element minOccurs="0" maxOccurs="1" name="DocId" type="s:string" />
387
- <s:element minOccurs="0" maxOccurs="1" name="CompanyCode" type="s:string" />
388
- <s:element minOccurs="1" maxOccurs="1" name="DocType" type="tns:DocumentType" />
389
- <s:element minOccurs="0" maxOccurs="1" name="DocCode" type="s:string" />
390
- <s:element minOccurs="1" maxOccurs="1" name="DocDate" type="s:date" />
391
- <s:element minOccurs="1" maxOccurs="1" name="TotalAmount" type="s:decimal" />
392
- <s:element minOccurs="1" maxOccurs="1" name="TotalTax" type="s:decimal" />
393
- <s:element minOccurs="1" maxOccurs="1" name="HashCode" type="s:int" />
394
- <s:element minOccurs="1" maxOccurs="1" name="Commit" type="s:boolean" />
395
- <s:element minOccurs="0" maxOccurs="1" name="NewDocCode" type="s:string" />
396
- <s:element minOccurs="0" maxOccurs="1" name="Signature" type="s:string" />
397
- <!-- <s:element minOccurs="0" maxOccurs="1" name="Confirmation" type="tns:ConfirmationType" /> -->
398
- </s:sequence>
399
- </s:extension>
400
- </s:complexContent>
401
- </s:complexType>
402
- <s:element name="PostTaxResponse">
403
- <s:complexType>
404
- <s:sequence>
405
- <s:element minOccurs="0" maxOccurs="1" name="PostTaxResult" type="tns:PostTaxResult" />
406
- </s:sequence>
407
- </s:complexType>
408
- </s:element>
409
- <s:complexType name="PostTaxResult">
410
- <s:complexContent mixed="false">
411
- <s:extension base="tns:BaseResult">
412
- <s:sequence>
413
- <s:element minOccurs="0" maxOccurs="1" name="DocId" type="s:string" />
414
- </s:sequence>
415
- </s:extension>
416
- </s:complexContent>
417
- </s:complexType>
418
- <s:element name="CommitTax">
419
- <s:complexType>
420
- <s:sequence>
421
- <s:element minOccurs="0" maxOccurs="1" name="CommitTaxRequest" type="tns:CommitTaxRequest" />
422
- </s:sequence>
423
- </s:complexType>
424
- </s:element>
425
- <s:complexType name="CommitTaxRequest">
426
- <s:complexContent mixed="false">
427
- <s:extension base="tns:BaseRequest">
428
- <s:sequence>
429
- <s:element minOccurs="0" maxOccurs="1" name="DocId" type="s:string" />
430
- <s:element minOccurs="0" maxOccurs="1" name="CompanyCode" type="s:string" />
431
- <s:element minOccurs="1" maxOccurs="1" name="DocType" type="tns:DocumentType" />
432
- <s:element minOccurs="0" maxOccurs="1" name="DocCode" type="s:string" />
433
- <s:element minOccurs="0" maxOccurs="1" name="NewDocCode" type="s:string" />
434
- </s:sequence>
435
- </s:extension>
436
- </s:complexContent>
437
- </s:complexType>
438
- <s:element name="CommitTaxResponse">
439
- <s:complexType>
440
- <s:sequence>
441
- <s:element minOccurs="0" maxOccurs="1" name="CommitTaxResult" type="tns:CommitTaxResult" />
442
- </s:sequence>
443
- </s:complexType>
444
- </s:element>
445
- <s:complexType name="CommitTaxResult">
446
- <s:complexContent mixed="false">
447
- <s:extension base="tns:BaseResult">
448
- <s:sequence>
449
- <s:element minOccurs="0" maxOccurs="1" name="DocId" type="s:string" />
450
- </s:sequence>
451
- </s:extension>
452
- </s:complexContent>
453
- </s:complexType>
454
- <s:element name="AuditMessage" type="tns:AuditMessage" />
455
- <s:complexType name="AuditMessage">
456
- <s:sequence>
457
- <s:element minOccurs="0" maxOccurs="1" name="Message" type="s:string" />
458
- </s:sequence>
459
- <s:anyAttribute />
460
- </s:complexType>
461
- <s:element name="CancelTax">
462
- <s:complexType>
463
- <s:sequence>
464
- <s:element minOccurs="0" maxOccurs="1" name="CancelTaxRequest" type="tns:CancelTaxRequest" />
465
- </s:sequence>
466
- </s:complexType>
467
- </s:element>
468
- <s:complexType name="CancelTaxRequest">
469
- <s:complexContent mixed="false">
470
- <s:extension base="tns:BaseRequest">
471
- <s:sequence>
472
- <s:element minOccurs="0" maxOccurs="1" name="DocId" type="s:string" />
473
- <s:element minOccurs="0" maxOccurs="1" name="CompanyCode" type="s:string" />
474
- <s:element minOccurs="1" maxOccurs="1" name="DocType" type="tns:DocumentType" />
475
- <s:element minOccurs="0" maxOccurs="1" name="DocCode" type="s:string" />
476
- <s:element minOccurs="1" maxOccurs="1" name="CancelCode" type="tns:CancelCode" />
477
- </s:sequence>
478
- </s:extension>
479
- </s:complexContent>
480
- </s:complexType>
481
- <s:simpleType name="CancelCode">
482
- <s:restriction base="s:string">
483
- <s:enumeration value="Unspecified" />
484
- <s:enumeration value="PostFailed" />
485
- <s:enumeration value="DocDeleted" />
486
- <s:enumeration value="DocVoided" />
487
- <s:enumeration value="AdjustmentCancelled" />
488
- </s:restriction>
489
- </s:simpleType>
490
- <s:element name="CancelTaxResponse">
491
- <s:complexType>
492
- <s:sequence>
493
- <s:element minOccurs="0" maxOccurs="1" name="CancelTaxResult" type="tns:CancelTaxResult" />
494
- </s:sequence>
495
- </s:complexType>
496
- </s:element>
497
- <s:complexType name="CancelTaxResult">
498
- <s:complexContent mixed="false">
499
- <s:extension base="tns:BaseResult">
500
- <s:sequence>
501
- <s:element minOccurs="0" maxOccurs="1" name="DocId" type="s:string" />
502
- </s:sequence>
503
- </s:extension>
504
- </s:complexContent>
505
- </s:complexType>
506
- <s:element name="ReconcileTaxHistory">
507
- <s:complexType>
508
- <s:sequence>
509
- <s:element minOccurs="0" maxOccurs="1" name="ReconcileTaxHistoryRequest" type="tns:ReconcileTaxHistoryRequest" />
510
- </s:sequence>
511
- </s:complexType>
512
- </s:element>
513
- <s:complexType name="ReconcileTaxHistoryRequest">
514
- <s:complexContent mixed="false">
515
- <s:extension base="tns:BaseRequest">
516
- <s:sequence>
517
- <s:element minOccurs="0" maxOccurs="1" name="CompanyCode" type="s:string" />
518
- <s:element minOccurs="1" maxOccurs="1" name="StartDate" type="s:date" />
519
- <s:element minOccurs="1" maxOccurs="1" name="EndDate" type="s:date" />
520
- <s:element minOccurs="1" maxOccurs="1" name="DocStatus" type="tns:DocStatus" />
521
- <s:element minOccurs="1" maxOccurs="1" name="DocType" type="tns:DocumentType"/>
522
- <s:element minOccurs="1" maxOccurs="1" name="LastDocCode" type="s:string"/>
523
- <s:element minOccurs="1" maxOccurs="1" name="PageSize" type="s:int"/>
524
- </s:sequence>
525
- </s:extension>
526
- </s:complexContent>
527
- </s:complexType>
528
- <s:element name="ReconcileTaxHistoryResponse">
529
- <s:complexType>
530
- <s:sequence>
531
- <s:element minOccurs="0" maxOccurs="1" name="ReconcileTaxHistoryResult" type="tns:ReconcileTaxHistoryResult" />
532
- </s:sequence>
533
- </s:complexType>
534
- </s:element>
535
- <s:complexType name="ReconcileTaxHistoryResult">
536
- <s:complexContent mixed="false">
537
- <s:extension base="tns:SearchTaxHistoryResult">
538
- <s:sequence>
539
- <s:element minOccurs="0" maxOccurs="1" name="RecordCount" type="s:int"></s:element>
540
- </s:sequence>
541
- </s:extension>
542
- </s:complexContent>
543
- </s:complexType>
544
- <s:complexType name="SearchTaxHistoryResult">
545
- <s:complexContent mixed="false">
546
- <s:extension base="tns:BaseResult">
547
- <s:sequence>
548
- <s:element minOccurs="0" maxOccurs="1" name="GetTaxResults" type="tns:ArrayOfGetTaxResult" />
549
- <s:element minOccurs="0" maxOccurs="1" name="LastDocCode" type="s:string" />
550
- </s:sequence>
551
- </s:extension>
552
- </s:complexContent>
553
- </s:complexType>
554
- <s:complexType name="ArrayOfGetTaxResult">
555
- <s:sequence>
556
- <s:element minOccurs="0" maxOccurs="unbounded" name="GetTaxResult" nillable="true" type="tns:GetTaxResult" />
557
- </s:sequence>
558
- </s:complexType>
559
- <s:element name="AdjustTax">
560
- <s:complexType>
561
- <s:sequence>
562
- <s:element minOccurs="0" maxOccurs="1" name="AdjustTaxRequest" type="tns:AdjustTaxRequest" />
563
- </s:sequence>
564
- </s:complexType>
565
- </s:element>
566
- <s:complexType name="AdjustTaxRequest">
567
- <s:complexContent mixed="false">
568
- <s:extension base="tns:BaseRequest">
569
- <s:sequence>
570
- <s:element minOccurs="1" maxOccurs="1" name="AdjustmentReason" type="s:int" />
571
- <s:element minOccurs="0" maxOccurs="1" name="AdjustmentDescription" type="s:string" />
572
- <s:element minOccurs="0" maxOccurs="1" name="GetTaxRequest" type="tns:GetTaxRequest" />
573
- </s:sequence>
574
- </s:extension>
575
- </s:complexContent>
576
- </s:complexType>
577
- <s:element name="AdjustTaxResponse">
578
- <s:complexType>
579
- <s:sequence>
580
- <s:element minOccurs="0" maxOccurs="1" name="AdjustTaxResult" type="tns:AdjustTaxResult" />
581
- </s:sequence>
582
- </s:complexType>
583
- </s:element>
584
- <s:complexType name="AdjustTaxResult">
585
- <s:complexContent mixed="false">
586
- <s:extension base="tns:GetTaxResult" />
587
- </s:complexContent>
588
- </s:complexType>
589
- <s:element name="ApplyPayment">
590
- <s:complexType>
591
- <s:sequence>
592
- <s:element minOccurs="0" maxOccurs="1" name="ApplyPaymentRequest" type="tns:ApplyPaymentRequest" />
593
- </s:sequence>
594
- </s:complexType>
595
- </s:element>
596
- <s:complexType name="ApplyPaymentRequest">
597
- <s:complexContent mixed="false">
598
- <s:extension base="tns:BaseRequest">
599
- <s:sequence>
600
- <s:element minOccurs="0" maxOccurs="1" name="DocId" type="s:string" />
601
- <s:element minOccurs="0" maxOccurs="1" name="CompanyCode" type="s:string" />
602
- <s:element minOccurs="1" maxOccurs="1" name="DocType" type="tns:DocumentType" />
603
- <s:element minOccurs="0" maxOccurs="1" name="DocCode" type="s:string" />
604
- <s:element minOccurs="1" maxOccurs="1" name="PaymentDate" type="s:dateTime" />
605
- </s:sequence>
606
- </s:extension>
607
- </s:complexContent>
608
- </s:complexType>
609
- <s:element name="ApplyPaymentResponse">
610
- <s:complexType>
611
- <s:sequence>
612
- <s:element minOccurs="0" maxOccurs="1" name="ApplyPaymentResult" type="tns:ApplyPaymentResult" />
613
- </s:sequence>
614
- </s:complexType>
615
- </s:element>
616
- <s:complexType name="ApplyPaymentResult">
617
- <s:complexContent mixed="false">
618
- <s:extension base="tns:BaseResult">
619
- <s:sequence>
620
- <s:element minOccurs="0" maxOccurs="1" name="DocId" type="s:string" />
621
- </s:sequence>
622
- </s:extension>
623
- </s:complexContent>
624
- </s:complexType>
625
- <!-- Begin New Methods-->
626
- <s:element name="SubmitBatch">
627
- <s:complexType>
628
- <s:sequence>
629
- <s:element minOccurs="0" maxOccurs="1" name="SubmitTaxBatchRequest" type="tns:SubmitTaxBatchRequest" />
630
- </s:sequence>
631
- </s:complexType>
632
- </s:element>
633
- <s:complexType name="SubmitTaxBatchRequest">
634
- <s:complexContent mixed="false">
635
- <s:extension base="tns:BaseRequest">
636
- <s:sequence>
637
- <s:element minOccurs="0" maxOccurs="1" name="Requests" type="tns:RequestList" />
638
- <s:element minOccurs="0" maxOccurs="1" name="Name" type="s:string"/>
639
- <s:element minOccurs="0" maxOccurs="1" name="BatchTypeId" type="s:string"/>
640
- <s:element minOccurs="0" maxOccurs="1" name="Options" type="s:string"/>
641
- </s:sequence>
642
- </s:extension>
643
- </s:complexContent>
644
- </s:complexType>
645
- <s:complexType name="RequestList">
646
- <s:choice minOccurs="0" maxOccurs="unbounded">
647
- <s:element name="AdjustTaxRequest" nillable="true" type="tns:AdjustTaxRequest" />
648
- <s:element name="ApplyPaymentRequest" nillable="true" type="tns:ApplyPaymentRequest" />
649
- <s:element name="CancelTaxRequest" nillable="true" type="tns:CancelTaxRequest" />
650
- <s:element name="CommitTaxRequest" nillable="true" type="tns:CommitTaxRequest" />
651
- <s:element name="GetTaxHistoryRequest" nillable="true" type="tns:GetTaxHistoryRequest" />
652
- <s:element name="GetTaxRequest" nillable="true" type="tns:GetTaxRequest" />
653
- <s:element name="PostTaxRequest" nillable="true" type="tns:PostTaxRequest" />
654
- <s:element name="ReconcileTaxHistoryRequest" nillable="true" type="tns:ReconcileTaxHistoryRequest" />
655
- </s:choice>
656
- </s:complexType>
657
- <s:element name="SubmitBatchResponse">
658
- <s:complexType>
659
- <s:sequence>
660
- <s:element minOccurs="0" maxOccurs="1" name="SubmitBatchResult" type="tns:SubmitTaxBatchResult" />
661
- </s:sequence>
662
- </s:complexType>
663
- </s:element>
664
- <s:complexType name="SubmitTaxBatchResult">
665
- <s:complexContent mixed="false">
666
- <s:extension base="tns:BaseResult">
667
- <s:sequence>
668
- <s:element minOccurs="0" maxOccurs="1" name="BatchId" type="s:string" />
669
- </s:sequence>
670
- </s:extension>
671
- </s:complexContent>
672
- </s:complexType>
673
-
674
- <s:element name="GetBatch">
675
- <s:complexType>
676
- <s:sequence>
677
- <s:element minOccurs="0" maxOccurs="1" name="GetTaxBatchRequest" type="tns:GetTaxBatchRequest" />
678
- </s:sequence>
679
- </s:complexType>
680
- </s:element>
681
- <s:complexType name="GetTaxBatchRequest">
682
- <s:complexContent mixed="false">
683
- <s:extension base="tns:BaseRequest">
684
- <s:sequence>
685
- <s:element minOccurs="1" maxOccurs="1" name="BatchId" type="s:string" />
686
- </s:sequence>
687
- </s:extension>
688
- </s:complexContent>
689
- </s:complexType>
690
- <s:element name="GetBatchResponse">
691
- <s:complexType>
692
- <s:sequence>
693
- <s:element minOccurs="0" maxOccurs="1" name="GetBatchResult" type="tns:GetTaxBatchResult" />
694
- </s:sequence>
695
- </s:complexType>
696
- </s:element>
697
- <s:complexType name="GetTaxBatchResult">
698
- <s:complexContent mixed="false">
699
- <s:extension base="tns:BaseResult">
700
- <s:sequence>
701
- <s:element minOccurs="1" maxOccurs="1" name="BatchId" type="s:string" />
702
- <s:element minOccurs="1" maxOccurs="1" name="BatchStatus" type="s:string" />
703
- <s:element minOccurs="1" maxOccurs="1" name="RecordCount" type="s:int" />
704
- <s:element minOccurs="1" maxOccurs="1" name="CurrentRecord" type="s:int" />
705
- <s:element minOccurs="0" maxOccurs="1" name="Results" type="tns:ResultList" />
706
- </s:sequence>
707
- </s:extension>
708
- </s:complexContent>
709
- </s:complexType>
710
- <s:complexType name="ResultList">
711
- <s:choice minOccurs="0" maxOccurs="unbounded">
712
- <s:element name="AdjustTaxResult" nillable="true" type="tns:AdjustTaxResult" />
713
- <s:element name="ApplyPaymentResult" nillable="true" type="tns:ApplyPaymentResult" />
714
- <s:element name="CancelTaxResult" nillable="true" type="tns:CancelTaxResult" />
715
- <s:element name="CommitTaxResult" nillable="true" type="tns:CommitTaxResult" />
716
- <s:element name="GetTaxHistoryResult" nillable="true" type="tns:GetTaxHistoryResult" />
717
- <s:element name="GetTaxResult" nillable="true" type="tns:GetTaxResult" />
718
- <s:element name="PostTaxResult" nillable="true" type="tns:PostTaxResult" />
719
- <s:element name="ReconcileTaxHistoryResult" nillable="true" type="tns:ReconcileTaxHistoryResult" />
720
- </s:choice>
721
- </s:complexType>
722
-
723
- <s:element name="CancelBatch">
724
- <s:complexType>
725
- <s:sequence>
726
- <s:element minOccurs="0" maxOccurs="1" name="CancelTaxBatchRequest" type="tns:CancelTaxBatchRequest" />
727
- </s:sequence>
728
- </s:complexType>
729
- </s:element>
730
- <s:complexType name="CancelTaxBatchRequest">
731
- <s:complexContent mixed="false">
732
- <s:extension base="tns:BaseRequest">
733
- <s:sequence>
734
- <s:element minOccurs="1" maxOccurs="1" name="BatchId" type="s:string" />
735
- </s:sequence>
736
- </s:extension>
737
- </s:complexContent>
738
- </s:complexType>
739
- <s:element name="CancelBatchResponse">
740
- <s:complexType>
741
- <s:sequence>
742
- <s:element minOccurs="0" maxOccurs="1" name="CancelBatchResult" type="tns:CancelTaxBatchResult" />
743
- </s:sequence>
744
- </s:complexType>
745
- </s:element>
746
- <s:complexType name="CancelTaxBatchResult">
747
- <s:complexContent mixed="false">
748
- <s:extension base="tns:BaseResult" />
749
- </s:complexContent>
750
- </s:complexType>
751
- <!-- End New Methods -->
752
- <s:element name="Ping">
753
- <s:complexType>
754
- <s:sequence>
755
- <s:element minOccurs="0" maxOccurs="1" name="Message" type="s:string" />
756
- </s:sequence>
757
- </s:complexType>
758
- </s:element>
759
- <s:element name="PingResponse">
760
- <s:complexType>
761
- <s:sequence>
762
- <s:element minOccurs="0" maxOccurs="1" name="PingResult" type="tns:PingResult" />
763
- </s:sequence>
764
- </s:complexType>
765
- </s:element>
766
- <s:complexType name="PingResult">
767
- <s:complexContent mixed="false">
768
- <s:extension base="tns:BaseResult">
769
- <s:sequence>
770
- <s:element minOccurs="0" maxOccurs="1" name="Version" type="s:string" />
771
- </s:sequence>
772
- </s:extension>
773
- </s:complexContent>
774
- </s:complexType>
775
- <s:element name="IsAuthorized">
776
- <s:complexType>
777
- <s:sequence>
778
- <s:element minOccurs="0" maxOccurs="1" name="Operations" type="s:string" />
779
- </s:sequence>
780
- </s:complexType>
781
- </s:element>
782
- <s:element name="IsAuthorizedResponse">
783
- <s:complexType>
784
- <s:sequence>
785
- <s:element minOccurs="0" maxOccurs="1" name="IsAuthorizedResult" type="tns:IsAuthorizedResult" />
786
- </s:sequence>
787
- </s:complexType>
788
- </s:element>
789
- <s:complexType name="IsAuthorizedResult">
790
- <s:complexContent mixed="false">
791
- <s:extension base="tns:BaseResult">
792
- <s:sequence>
793
- <s:element minOccurs="0" maxOccurs="1" name="Operations" type="s:string" />
794
- <s:element minOccurs="1" maxOccurs="1" name="Expires" type="s:dateTime" />
795
- </s:sequence>
796
- </s:extension>
797
- </s:complexContent>
798
- </s:complexType>
799
- </s:schema>
800
- </wsdl:types>
801
- <wsdl:message name="GetTaxSoapIn">
802
- <wsdl:part name="parameters" element="tns:GetTax" />
803
- </wsdl:message>
804
- <wsdl:message name="GetTaxSoapOut">
805
- <wsdl:part name="parameters" element="tns:GetTaxResponse" />
806
- </wsdl:message>
807
- <wsdl:message name="GetTaxProfile">
808
- <wsdl:part name="Profile" element="tns:Profile" />
809
- </wsdl:message>
810
- <wsdl:message name="GetTaxHistorySoapIn">
811
- <wsdl:part name="parameters" element="tns:GetTaxHistory" />
812
- </wsdl:message>
813
- <wsdl:message name="GetTaxHistorySoapOut">
814
- <wsdl:part name="parameters" element="tns:GetTaxHistoryResponse" />
815
- </wsdl:message>
816
- <wsdl:message name="GetTaxHistoryProfile">
817
- <wsdl:part name="Profile" element="tns:Profile" />
818
- </wsdl:message>
819
- <wsdl:message name="PostTaxSoapIn">
820
- <wsdl:part name="parameters" element="tns:PostTax" />
821
- </wsdl:message>
822
- <wsdl:message name="PostTaxSoapOut">
823
- <wsdl:part name="parameters" element="tns:PostTaxResponse" />
824
- </wsdl:message>
825
- <wsdl:message name="PostTaxProfile">
826
- <wsdl:part name="Profile" element="tns:Profile" />
827
- </wsdl:message>
828
- <wsdl:message name="CommitTaxSoapIn">
829
- <wsdl:part name="parameters" element="tns:CommitTax" />
830
- </wsdl:message>
831
- <wsdl:message name="CommitTaxSoapOut">
832
- <wsdl:part name="parameters" element="tns:CommitTaxResponse" />
833
- </wsdl:message>
834
- <wsdl:message name="CommitTaxAuditMessage">
835
- <wsdl:part name="AuditMessage" element="tns:AuditMessage" />
836
- </wsdl:message>
837
- <wsdl:message name="CommitTaxProfile">
838
- <wsdl:part name="Profile" element="tns:Profile" />
839
- </wsdl:message>
840
- <wsdl:message name="CancelTaxSoapIn">
841
- <wsdl:part name="parameters" element="tns:CancelTax" />
842
- </wsdl:message>
843
- <wsdl:message name="CancelTaxSoapOut">
844
- <wsdl:part name="parameters" element="tns:CancelTaxResponse" />
845
- </wsdl:message>
846
- <wsdl:message name="CancelTaxAuditMessage">
847
- <wsdl:part name="AuditMessage" element="tns:AuditMessage" />
848
- </wsdl:message>
849
- <wsdl:message name="CancelTaxProfile">
850
- <wsdl:part name="Profile" element="tns:Profile" />
851
- </wsdl:message>
852
- <wsdl:message name="ReconcileTaxHistorySoapIn">
853
- <wsdl:part name="parameters" element="tns:ReconcileTaxHistory" />
854
- </wsdl:message>
855
- <wsdl:message name="ReconcileTaxHistorySoapOut">
856
- <wsdl:part name="parameters" element="tns:ReconcileTaxHistoryResponse" />
857
- </wsdl:message>
858
- <wsdl:message name="ReconcileTaxHistoryProfile">
859
- <wsdl:part name="Profile" element="tns:Profile" />
860
- </wsdl:message>
861
- <wsdl:message name="AdjustTaxSoapIn">
862
- <wsdl:part name="parameters" element="tns:AdjustTax" />
863
- </wsdl:message>
864
- <wsdl:message name="AdjustTaxSoapOut">
865
- <wsdl:part name="parameters" element="tns:AdjustTaxResponse" />
866
- </wsdl:message>
867
- <wsdl:message name="AdjustTaxProfile">
868
- <wsdl:part name="Profile" element="tns:Profile" />
869
- </wsdl:message>
870
- <wsdl:message name="ApplyPaymentSoapIn">
871
- <wsdl:part name="parameters" element="tns:ApplyPayment" />
872
- </wsdl:message>
873
- <wsdl:message name="ApplyPaymentSoapOut">
874
- <wsdl:part name="parameters" element="tns:ApplyPaymentResponse" />
875
- </wsdl:message>
876
- <wsdl:message name="ApplyPaymentAuditMessage">
877
- <wsdl:part name="AuditMessage" element="tns:AuditMessage" />
878
- </wsdl:message>
879
- <wsdl:message name="ApplyPaymentProfile">
880
- <wsdl:part name="Profile" element="tns:Profile" />
881
- </wsdl:message>
882
- <!--New Methods-->
883
- <wsdl:message name="SubmitBatchSoapIn">
884
- <wsdl:part name="parameters" element="tns:SubmitBatch" />
885
- </wsdl:message>
886
- <wsdl:message name="SubmitBatchSoapOut">
887
- <wsdl:part name="parameters" element="tns:SubmitBatchResponse" />
888
- </wsdl:message>
889
- <wsdl:message name="SubmitBatchProfile">
890
- <wsdl:part name="Profile" element="tns:Profile" />
891
- </wsdl:message>
892
- <wsdl:message name="GetBatchSoapIn">
893
- <wsdl:part name="parameters" element="tns:GetBatch" />
894
- </wsdl:message>
895
- <wsdl:message name="GetBatchSoapOut">
896
- <wsdl:part name="parameters" element="tns:GetBatchResponse" />
897
- </wsdl:message>
898
- <wsdl:message name="GetBatchProfile">
899
- <wsdl:part name="Profile" element="tns:Profile" />
900
- </wsdl:message>
901
- <wsdl:message name="CancelBatchSoapIn">
902
- <wsdl:part name="parameters" element="tns:CancelBatch" />
903
- </wsdl:message>
904
- <wsdl:message name="CancelBatchSoapOut">
905
- <wsdl:part name="parameters" element="tns:CancelBatchResponse" />
906
- </wsdl:message>
907
- <wsdl:message name="CancelBatchProfile">
908
- <wsdl:part name="Profile" element="tns:Profile" />
909
- </wsdl:message>
910
- <!--New Methods-->
911
- <wsdl:message name="PingSoapIn">
912
- <wsdl:part name="parameters" element="tns:Ping" />
913
- </wsdl:message>
914
- <wsdl:message name="PingSoapOut">
915
- <wsdl:part name="parameters" element="tns:PingResponse" />
916
- </wsdl:message>
917
- <wsdl:message name="PingProfile">
918
- <wsdl:part name="Profile" element="tns:Profile" />
919
- </wsdl:message>
920
- <wsdl:message name="IsAuthorizedSoapIn">
921
- <wsdl:part name="parameters" element="tns:IsAuthorized" />
922
- </wsdl:message>
923
- <wsdl:message name="IsAuthorizedSoapOut">
924
- <wsdl:part name="parameters" element="tns:IsAuthorizedResponse" />
925
- </wsdl:message>
926
- <wsdl:message name="IsAuthorizedProfile">
927
- <wsdl:part name="Profile" element="tns:Profile" />
928
- </wsdl:message>
929
- <wsdl:portType name="TaxSvcSoap">
930
- <wsdl:operation name="GetTax">
931
- <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Calculates taxes on a document</wsdl:documentation>
932
- <wsdl:input message="tns:GetTaxSoapIn" />
933
- <wsdl:output message="tns:GetTaxSoapOut" />
934
- </wsdl:operation>
935
- <wsdl:operation name="GetTaxHistory">
936
- <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Retrieves a previously calculated tax document</wsdl:documentation>
937
- <wsdl:input message="tns:GetTaxHistorySoapIn" />
938
- <wsdl:output message="tns:GetTaxHistorySoapOut" />
939
- </wsdl:operation>
940
- <wsdl:operation name="PostTax">
941
- <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Posts a previously calculated tax</wsdl:documentation>
942
- <wsdl:input message="tns:PostTaxSoapIn" />
943
- <wsdl:output message="tns:PostTaxSoapOut" />
944
- </wsdl:operation>
945
- <wsdl:operation name="CommitTax">
946
- <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Commits a previously posted tax</wsdl:documentation>
947
- <wsdl:input message="tns:CommitTaxSoapIn" />
948
- <wsdl:output message="tns:CommitTaxSoapOut" />
949
- </wsdl:operation>
950
- <wsdl:operation name="CancelTax">
951
- <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Cancels a previously calculated tax. This is for use as a compensating action when posting on the client fails to complete.</wsdl:documentation>
952
- <wsdl:input message="tns:CancelTaxSoapIn" />
953
- <wsdl:output message="tns:CancelTaxSoapOut" />
954
- </wsdl:operation>
955
- <wsdl:operation name="ReconcileTaxHistory">
956
- <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Reconciles tax history to ensure the client data matches the AvaTax history.</wsdl:documentation>
957
- <wsdl:input message="tns:ReconcileTaxHistorySoapIn" />
958
- <wsdl:output message="tns:ReconcileTaxHistorySoapOut" />
959
- </wsdl:operation>
960
- <wsdl:operation name="AdjustTax">
961
- <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Adjusts taxes on an existing invoice</wsdl:documentation>
962
- <wsdl:input message="tns:AdjustTaxSoapIn" />
963
- <wsdl:output message="tns:AdjustTaxSoapOut" />
964
- </wsdl:operation>
965
- <wsdl:operation name="ApplyPayment">
966
- <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Applies a payment date to an existing invoice</wsdl:documentation>
967
- <wsdl:input message="tns:ApplyPaymentSoapIn" />
968
- <wsdl:output message="tns:ApplyPaymentSoapOut" />
969
- </wsdl:operation>
970
- <wsdl:operation name="SubmitBatch">
971
- <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Submits a batch of TaxSvc requests to be processed.</wsdl:documentation>
972
- <wsdl:input message="tns:SubmitBatchSoapIn" />
973
- <wsdl:output message="tns:SubmitBatchSoapOut" />
974
- </wsdl:operation>
975
- <wsdl:operation name="GetBatch">
976
- <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Gets the status and results of a submitted batch.</wsdl:documentation>
977
- <wsdl:input message="tns:GetBatchSoapIn" />
978
- <wsdl:output message="tns:GetBatchSoapOut" />
979
- </wsdl:operation>
980
- <wsdl:operation name="CancelBatch">
981
- <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Cancels an incomplete batch operation.</wsdl:documentation>
982
- <wsdl:input message="tns:CancelBatchSoapIn" />
983
- <wsdl:output message="tns:CancelBatchSoapOut" />
984
- </wsdl:operation>
985
- <wsdl:operation name="Ping">
986
- <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Tests connectivity and version of the service</wsdl:documentation>
987
- <wsdl:input message="tns:PingSoapIn" />
988
- <wsdl:output message="tns:PingSoapOut" />
989
- </wsdl:operation>
990
- <wsdl:operation name="IsAuthorized">
991
- <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Checks authentication and authorization to one or more operations on the service.</wsdl:documentation>
992
- <wsdl:input message="tns:IsAuthorizedSoapIn" />
993
- <wsdl:output message="tns:IsAuthorizedSoapOut" />
994
- </wsdl:operation>
995
- </wsdl:portType>
996
- <wsdl:binding name="TaxSvcSoap" type="tns:TaxSvcSoap">
997
- <soap:binding transport="http://schemas.xmlsoap.org/soap/http" />
998
- <wsdl:operation name="GetTax">
999
- <soap:operation soapAction="http://avatax.avalara.com/services/GetTax" style="document" />
1000
- <wsdl:input>
1001
- <soap:body use="literal" />
1002
- <soap:header message="tns:GetTaxProfile" part="Profile" use="literal" />
1003
- </wsdl:input>
1004
- <wsdl:output>
1005
- <soap:body use="literal" />
1006
- </wsdl:output>
1007
- </wsdl:operation>
1008
- <wsdl:operation name="GetTaxHistory">
1009
- <soap:operation soapAction="http://avatax.avalara.com/services/GetTaxHistory" style="document" />
1010
- <wsdl:input>
1011
- <soap:body use="literal" />
1012
- <soap:header message="tns:GetTaxHistoryProfile" part="Profile" use="literal" />
1013
- </wsdl:input>
1014
- <wsdl:output>
1015
- <soap:body use="literal" />
1016
- </wsdl:output>
1017
- </wsdl:operation>
1018
- <wsdl:operation name="PostTax">
1019
- <soap:operation soapAction="http://avatax.avalara.com/services/PostTax" style="document" />
1020
- <wsdl:input>
1021
- <soap:body use="literal" />
1022
- <soap:header message="tns:PostTaxProfile" part="Profile" use="literal" />
1023
- </wsdl:input>
1024
- <wsdl:output>
1025
- <soap:body use="literal" />
1026
- </wsdl:output>
1027
- </wsdl:operation>
1028
- <wsdl:operation name="CommitTax">
1029
- <soap:operation soapAction="http://avatax.avalara.com/services/CommitTax" style="document" />
1030
- <wsdl:input>
1031
- <soap:body use="literal" />
1032
- <soap:header message="tns:CommitTaxAuditMessage" part="AuditMessage" use="literal" />
1033
- <soap:header message="tns:CommitTaxProfile" part="Profile" use="literal" />
1034
- </wsdl:input>
1035
- <wsdl:output>
1036
- <soap:body use="literal" />
1037
- </wsdl:output>
1038
- </wsdl:operation>
1039
- <wsdl:operation name="CancelTax">
1040
- <soap:operation soapAction="http://avatax.avalara.com/services/CancelTax" style="document" />
1041
- <wsdl:input>
1042
- <soap:body use="literal" />
1043
- <soap:header message="tns:CancelTaxAuditMessage" part="AuditMessage" use="literal" />
1044
- <soap:header message="tns:CancelTaxProfile" part="Profile" use="literal" />
1045
- </wsdl:input>
1046
- <wsdl:output>
1047
- <soap:body use="literal" />
1048
- </wsdl:output>
1049
- </wsdl:operation>
1050
- <wsdl:operation name="ReconcileTaxHistory">
1051
- <soap:operation soapAction="http://avatax.avalara.com/services/ReconcileTaxHistory" style="document" />
1052
- <wsdl:input>
1053
- <soap:body use="literal" />
1054
- <soap:header message="tns:ReconcileTaxHistoryProfile" part="Profile" use="literal" />
1055
- </wsdl:input>
1056
- <wsdl:output>
1057
- <soap:body use="literal" />
1058
- </wsdl:output>
1059
- </wsdl:operation>
1060
- <wsdl:operation name="AdjustTax">
1061
- <soap:operation soapAction="http://avatax.avalara.com/services/AdjustTax" style="document" />
1062
- <wsdl:input>
1063
- <soap:body use="literal" />
1064
- <soap:header message="tns:AdjustTaxProfile" part="Profile" use="literal" />
1065
- </wsdl:input>
1066
- <wsdl:output>
1067
- <soap:body use="literal" />
1068
- </wsdl:output>
1069
- </wsdl:operation>
1070
- <wsdl:operation name="ApplyPayment">
1071
- <soap:operation soapAction="http://avatax.avalara.com/services/ApplyPayment" style="document" />
1072
- <wsdl:input>
1073
- <soap:body use="literal" />
1074
- <soap:header message="tns:ApplyPaymentAuditMessage" part="AuditMessage" use="literal" />
1075
- <soap:header message="tns:ApplyPaymentProfile" part="Profile" use="literal" />
1076
- </wsdl:input>
1077
- <wsdl:output>
1078
- <soap:body use="literal" />
1079
- </wsdl:output>
1080
- </wsdl:operation>
1081
- <!--New Methods Begin-->
1082
- <wsdl:operation name="SubmitBatch">
1083
- <soap:operation soapAction="http://avatax.avalara.com/services/SubmitBatch" style="document" />
1084
- <wsdl:input>
1085
- <soap:body use="literal" />
1086
- <soap:header message="tns:SubmitBatchProfile" part="Profile" use="literal" />
1087
- </wsdl:input>
1088
- <wsdl:output>
1089
- <soap:body use="literal" />
1090
- </wsdl:output>
1091
- </wsdl:operation>
1092
- <wsdl:operation name="GetBatch">
1093
- <soap:operation soapAction="http://avatax.avalara.com/services/GetBatch" style="document" />
1094
- <wsdl:input>
1095
- <soap:body use="literal" />
1096
- <soap:header message="tns:GetBatchProfile" part="Profile" use="literal" />
1097
- </wsdl:input>
1098
- <wsdl:output>
1099
- <soap:body use="literal" />
1100
- </wsdl:output>
1101
- </wsdl:operation>
1102
- <wsdl:operation name="CancelBatch">
1103
- <soap:operation soapAction="http://avatax.avalara.com/services/CancelBatch" style="document" />
1104
- <wsdl:input>
1105
- <soap:body use="literal" />
1106
- <soap:header message="tns:CancelBatchProfile" part="Profile" use="literal" />
1107
- </wsdl:input>
1108
- <wsdl:output>
1109
- <soap:body use="literal" />
1110
- </wsdl:output>
1111
- </wsdl:operation>
1112
- <!--New Methods End-->
1113
- <wsdl:operation name="Ping">
1114
- <soap:operation soapAction="http://avatax.avalara.com/services/Ping" style="document" />
1115
- <wsdl:input>
1116
- <soap:body use="literal" />
1117
- <soap:header message="tns:PingProfile" part="Profile" use="literal" />
1118
- </wsdl:input>
1119
- <wsdl:output>
1120
- <soap:body use="literal" />
1121
- </wsdl:output>
1122
- </wsdl:operation>
1123
- <wsdl:operation name="IsAuthorized">
1124
- <soap:operation soapAction="http://avatax.avalara.com/services/IsAuthorized" style="document" />
1125
- <wsdl:input>
1126
- <soap:body use="literal" />
1127
- <soap:header message="tns:IsAuthorizedProfile" part="Profile" use="literal" />
1128
- </wsdl:input>
1129
- <wsdl:output>
1130
- <soap:body use="literal" />
1131
- </wsdl:output>
1132
- </wsdl:operation>
1133
- </wsdl:binding>
1134
- <wsdl:binding name="TaxSvcSoap12" type="tns:TaxSvcSoap">
1135
- <soap12:binding transport="http://schemas.xmlsoap.org/soap/http" />
1136
- <wsdl:operation name="GetTax">
1137
- <soap12:operation soapAction="http://avatax.avalara.com/services/GetTax" style="document" />
1138
- <wsdl:input>
1139
- <soap12:body use="literal" />
1140
- <soap12:header message="tns:GetTaxProfile" part="Profile" use="literal" />
1141
- </wsdl:input>
1142
- <wsdl:output>
1143
- <soap12:body use="literal" />
1144
- </wsdl:output>
1145
- </wsdl:operation>
1146
- <wsdl:operation name="GetTaxHistory">
1147
- <soap12:operation soapAction="http://avatax.avalara.com/services/GetTaxHistory" style="document" />
1148
- <wsdl:input>
1149
- <soap12:body use="literal" />
1150
- <soap12:header message="tns:GetTaxHistoryProfile" part="Profile" use="literal" />
1151
- </wsdl:input>
1152
- <wsdl:output>
1153
- <soap12:body use="literal" />
1154
- </wsdl:output>
1155
- </wsdl:operation>
1156
- <wsdl:operation name="PostTax">
1157
- <soap12:operation soapAction="http://avatax.avalara.com/services/PostTax" style="document" />
1158
- <wsdl:input>
1159
- <soap12:body use="literal" />
1160
- <soap12:header message="tns:PostTaxProfile" part="Profile" use="literal" />
1161
- </wsdl:input>
1162
- <wsdl:output>
1163
- <soap12:body use="literal" />
1164
- </wsdl:output>
1165
- </wsdl:operation>
1166
- <wsdl:operation name="CommitTax">
1167
- <soap12:operation soapAction="http://avatax.avalara.com/services/CommitTax" style="document" />
1168
- <wsdl:input>
1169
- <soap12:body use="literal" />
1170
- <soap12:header message="tns:CommitTaxAuditMessage" part="AuditMessage" use="literal" />
1171
- <soap12:header message="tns:CommitTaxProfile" part="Profile" use="literal" />
1172
- </wsdl:input>
1173
- <wsdl:output>
1174
- <soap12:body use="literal" />
1175
- </wsdl:output>
1176
- </wsdl:operation>
1177
- <wsdl:operation name="CancelTax">
1178
- <soap12:operation soapAction="http://avatax.avalara.com/services/CancelTax" style="document" />
1179
- <wsdl:input>
1180
- <soap12:body use="literal" />
1181
- <soap12:header message="tns:CancelTaxAuditMessage" part="AuditMessage" use="literal" />
1182
- <soap12:header message="tns:CancelTaxProfile" part="Profile" use="literal" />
1183
- </wsdl:input>
1184
- <wsdl:output>
1185
- <soap12:body use="literal" />
1186
- </wsdl:output>
1187
- </wsdl:operation>
1188
- <wsdl:operation name="ReconcileTaxHistory">
1189
- <soap12:operation soapAction="http://avatax.avalara.com/services/ReconcileTaxHistory" style="document" />
1190
- <wsdl:input>
1191
- <soap12:body use="literal" />
1192
- <soap12:header message="tns:ReconcileTaxHistoryProfile" part="Profile" use="literal" />
1193
- </wsdl:input>
1194
- <wsdl:output>
1195
- <soap12:body use="literal" />
1196
- </wsdl:output>
1197
- </wsdl:operation>
1198
- <wsdl:operation name="AdjustTax">
1199
- <soap12:operation soapAction="http://avatax.avalara.com/services/AdjustTax" style="document" />
1200
- <wsdl:input>
1201
- <soap12:body use="literal" />
1202
- <soap12:header message="tns:AdjustTaxProfile" part="Profile" use="literal" />
1203
- </wsdl:input>
1204
- <wsdl:output>
1205
- <soap12:body use="literal" />
1206
- </wsdl:output>
1207
- </wsdl:operation>
1208
- <wsdl:operation name="ApplyPayment">
1209
- <soap12:operation soapAction="http://avatax.avalara.com/services/ApplyPayment" style="document" />
1210
- <wsdl:input>
1211
- <soap12:body use="literal" />
1212
- <soap12:header message="tns:ApplyPaymentAuditMessage" part="AuditMessage" use="literal" />
1213
- <soap12:header message="tns:ApplyPaymentProfile" part="Profile" use="literal" />
1214
- </wsdl:input>
1215
- <wsdl:output>
1216
- <soap12:body use="literal" />
1217
- </wsdl:output>
1218
- </wsdl:operation>
1219
- <wsdl:operation name="Ping">
1220
- <soap12:operation soapAction="http://avatax.avalara.com/services/Ping" style="document" />
1221
- <wsdl:input>
1222
- <soap12:body use="literal" />
1223
- <soap12:header message="tns:PingProfile" part="Profile" use="literal" />
1224
- </wsdl:input>
1225
- <wsdl:output>
1226
- <soap12:body use="literal" />
1227
- </wsdl:output>
1228
- </wsdl:operation>
1229
- <wsdl:operation name="IsAuthorized">
1230
- <soap12:operation soapAction="http://avatax.avalara.com/services/IsAuthorized" style="document" />
1231
- <wsdl:input>
1232
- <soap12:body use="literal" />
1233
- <soap12:header message="tns:IsAuthorizedProfile" part="Profile" use="literal" />
1234
- </wsdl:input>
1235
- <wsdl:output>
1236
- <soap12:body use="literal" />
1237
- </wsdl:output>
1238
- </wsdl:operation>
1239
- <!--New Methods Begin-->
1240
- <wsdl:operation name="SubmitBatch">
1241
- <soap12:operation soapAction="http://avatax.avalara.com/services/SubmitBatch" style="document" />
1242
- <wsdl:input>
1243
- <soap12:body use="literal" />
1244
- <soap12:header message="tns:SubmitBatchProfile" part="Profile" use="literal" />
1245
- </wsdl:input>
1246
- <wsdl:output>
1247
- <soap12:body use="literal" />
1248
- </wsdl:output>
1249
- </wsdl:operation>
1250
- <wsdl:operation name="GetBatch">
1251
- <soap12:operation soapAction="http://avatax.avalara.com/services/GetBatch" style="document" />
1252
- <wsdl:input>
1253
- <soap12:body use="literal" />
1254
- <soap12:header message="tns:GetBatchProfile" part="Profile" use="literal" />
1255
- </wsdl:input>
1256
- <wsdl:output>
1257
- <soap12:body use="literal" />
1258
- </wsdl:output>
1259
- </wsdl:operation>
1260
- <wsdl:operation name="CancelBatch">
1261
- <soap12:operation soapAction="http://avatax.avalara.com/services/CancelBatch" style="document" />
1262
- <wsdl:input>
1263
- <soap12:body use="literal" />
1264
- <soap12:header message="tns:CancelBatchProfile" part="Profile" use="literal" />
1265
- </wsdl:input>
1266
- <wsdl:output>
1267
- <soap12:body use="literal" />
1268
- </wsdl:output>
1269
- </wsdl:operation>
1270
- <!--New Methods End-->
1271
- </wsdl:binding>
1272
- <wsdl:service name="TaxSvc">
1273
- <wsdl:port name="TaxSvcSoap" binding="tns:TaxSvcSoap">
1274
- <soap:address location="http://localhost/avatax.services/Tax/TaxSvc.asmx" />
1275
- </wsdl:port>
1276
- <wsdl:port name="TaxSvcSoap12" binding="tns:TaxSvcSoap12">
1277
- <soap12:address location="http://localhost/avatax.services/Tax/TaxSvc.asmx" />
1278
- </wsdl:port>
1279
- </wsdl:service>
1280
  </wsdl:definitions>
1
+ <?xml version="1.0" encoding="utf-8"?>
2
+ <wsdl:definitions xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:tm="http://microsoft.com/wsdl/mime/textMatching/" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/" xmlns:tns="http://avatax.avalara.com/services" xmlns:s="http://www.w3.org/2001/XMLSchema" xmlns:soap12="http://schemas.xmlsoap.org/wsdl/soap12/" xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" targetNamespace="http://avatax.avalara.com/services" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">
3
+ <wsdl:types>
4
+ <s:schema elementFormDefault="qualified" targetNamespace="http://avatax.avalara.com/services">
5
+ <s:element name="GetTax">
6
+ <s:complexType>
7
+ <s:sequence>
8
+ <s:element minOccurs="0" maxOccurs="1" name="GetTaxRequest" type="tns:GetTaxRequest" />
9
+ </s:sequence>
10
+ </s:complexType>
11
+ </s:element>
12
+ <s:complexType name="BaseRequest" />
13
+ <s:complexType name="GetTaxRequest">
14
+ <s:complexContent mixed="false">
15
+ <s:extension base="tns:BaseRequest">
16
+ <s:sequence>
17
+ <s:element minOccurs="0" maxOccurs="1" name="CompanyCode" type="s:string" />
18
+ <s:element minOccurs="1" maxOccurs="1" name="DocType" type="tns:DocumentType" />
19
+ <s:element minOccurs="0" maxOccurs="1" name="DocCode" type="s:string" />
20
+ <s:element minOccurs="1" maxOccurs="1" name="DocDate" type="s:date" />
21
+ <s:element minOccurs="0" maxOccurs="1" name="SalespersonCode" type="s:string" />
22
+ <s:element minOccurs="0" maxOccurs="1" name="CustomerCode" type="s:string" />
23
+ <s:element minOccurs="0" maxOccurs="1" name="CustomerUsageType" type="s:string" />
24
+ <s:element minOccurs="1" maxOccurs="1" name="Discount" type="s:decimal" />
25
+ <s:element minOccurs="0" maxOccurs="1" name="PurchaseOrderNo" type="s:string" />
26
+ <s:element minOccurs="0" maxOccurs="1" name="ExemptionNo" type="s:string" />
27
+ <s:element minOccurs="0" maxOccurs="1" name="OriginCode" type="s:string" />
28
+ <s:element minOccurs="0" maxOccurs="1" name="DestinationCode" type="s:string" />
29
+ <s:element minOccurs="0" maxOccurs="1" name="Addresses" type="tns:ArrayOfBaseAddress" />
30
+ <s:element minOccurs="0" maxOccurs="1" name="Lines" type="tns:ArrayOfLine" />
31
+ <s:element minOccurs="1" maxOccurs="1" name="DetailLevel" type="tns:DetailLevel" />
32
+ <s:element minOccurs="0" maxOccurs="1" name="ReferenceCode" type="s:string" />
33
+ <s:element minOccurs="1" maxOccurs="1" name="HashCode" type="s:int" />
34
+ <s:element minOccurs="0" maxOccurs="1" name="LocationCode" type="s:string" />
35
+ <s:element minOccurs="1" maxOccurs="1" name="Commit" type="s:boolean" />
36
+ <s:element minOccurs="0" maxOccurs="1" name="BatchCode" type="s:string" />
37
+ <s:element minOccurs="0" maxOccurs="1" name="TaxOverride" type="tns:TaxOverride" />
38
+ <s:element minOccurs="0" maxOccurs="1" name="CurrencyCode" type="s:string" />
39
+ <s:element minOccurs="1" maxOccurs="1" name="ServiceMode" type="tns:ServiceMode" />
40
+ <s:element minOccurs="1" maxOccurs="1" name="PaymentDate" type="s:date" />
41
+ <s:element minOccurs="1" maxOccurs="1" name="ExchangeRate" type="s:decimal" />
42
+ <s:element minOccurs="1" maxOccurs="1" name="ExchangeRateEffDate" type="s:date" />
43
+ <s:element minOccurs="1" maxOccurs="1" name="TaxDate" type="s:date" />
44
+ <s:element minOccurs="1" maxOccurs="1" name="StatusDate" type="s:date" />
45
+ </s:sequence>
46
+ </s:extension>
47
+ </s:complexContent>
48
+ </s:complexType>
49
+ <s:simpleType name="DocumentType">
50
+ <s:restriction base="s:string">
51
+ <s:enumeration value="SalesOrder" />
52
+ <s:enumeration value="SalesInvoice" />
53
+ <s:enumeration value="PurchaseOrder" />
54
+ <s:enumeration value="PurchaseInvoice" />
55
+ <s:enumeration value="ReturnOrder" />
56
+ <s:enumeration value="ReturnInvoice" />
57
+ <s:enumeration value="PendingAdjustment" />
58
+ <s:enumeration value="Any" />
59
+ </s:restriction>
60
+ </s:simpleType>
61
+ <s:complexType name="ArrayOfBaseAddress">
62
+ <s:sequence>
63
+ <s:element minOccurs="0" maxOccurs="unbounded" name="BaseAddress" nillable="true" type="tns:BaseAddress" />
64
+ </s:sequence>
65
+ </s:complexType>
66
+ <s:complexType name="BaseAddress">
67
+ <s:sequence>
68
+ <s:element minOccurs="0" maxOccurs="1" name="AddressCode" type="s:string" />
69
+ <s:element minOccurs="0" maxOccurs="1" name="Line1" type="s:string" />
70
+ <s:element minOccurs="0" maxOccurs="1" name="Line2" type="s:string" />
71
+ <s:element minOccurs="0" maxOccurs="1" name="Line3" type="s:string" />
72
+ <s:element minOccurs="0" maxOccurs="1" name="City" type="s:string" />
73
+ <s:element minOccurs="0" maxOccurs="1" name="Region" type="s:string" />
74
+ <s:element minOccurs="0" maxOccurs="1" name="PostalCode" type="s:string" />
75
+ <s:element minOccurs="0" maxOccurs="1" name="Country" type="s:string" />
76
+ <s:element minOccurs="1" maxOccurs="1" name="TaxRegionId" type="s:int" />
77
+ </s:sequence>
78
+ </s:complexType>
79
+ <s:complexType name="ArrayOfLine">
80
+ <s:sequence>
81
+ <s:element minOccurs="0" maxOccurs="unbounded" name="Line" nillable="true" type="tns:Line" />
82
+ </s:sequence>
83
+ </s:complexType>
84
+ <s:complexType name="Line">
85
+ <s:sequence>
86
+ <s:element minOccurs="0" maxOccurs="1" name="No" type="s:string" />
87
+ <s:element minOccurs="0" maxOccurs="1" name="OriginCode" type="s:string" />
88
+ <s:element minOccurs="0" maxOccurs="1" name="DestinationCode" type="s:string" />
89
+ <s:element minOccurs="0" maxOccurs="1" name="ItemCode" type="s:string" />
90
+ <s:element minOccurs="0" maxOccurs="1" name="TaxCode" type="s:string" />
91
+ <s:element minOccurs="1" maxOccurs="1" name="Qty" type="s:decimal" />
92
+ <s:element minOccurs="1" maxOccurs="1" name="Amount" type="s:decimal" />
93
+ <s:element minOccurs="1" maxOccurs="1" name="Discounted" type="s:boolean" />
94
+ <s:element minOccurs="0" maxOccurs="1" name="RevAcct" type="s:string" />
95
+ <s:element minOccurs="0" maxOccurs="1" name="Ref1" type="s:string" />
96
+ <s:element minOccurs="0" maxOccurs="1" name="Ref2" type="s:string" />
97
+ <s:element minOccurs="0" maxOccurs="1" name="ExemptionNo" type="s:string" />
98
+ <s:element minOccurs="0" maxOccurs="1" name="CustomerUsageType" type="s:string" />
99
+ <s:element minOccurs="0" maxOccurs="1" name="Description" type="s:string" />
100
+ <s:element minOccurs="0" maxOccurs="1" name="TaxOverride" type="tns:TaxOverride" />
101
+ <s:element minOccurs="0" maxOccurs="1" name="TaxIncluded" type="s:boolean" default="false" />
102
+ </s:sequence>
103
+ </s:complexType>
104
+ <s:complexType name="TaxOverride">
105
+ <s:sequence>
106
+ <s:element minOccurs="1" maxOccurs="1" name="TaxOverrideType" type="tns:TaxOverrideType" />
107
+ <s:element minOccurs="1" maxOccurs="1" name="TaxAmount" type="s:decimal" />
108
+ <s:element minOccurs="1" maxOccurs="1" name="TaxDate" type="s:date" />
109
+ <s:element minOccurs="0" maxOccurs="1" name="Reason" type="s:string" />
110
+ </s:sequence>
111
+ </s:complexType>
112
+ <s:simpleType name="TaxOverrideType">
113
+ <s:restriction base="s:string">
114
+ <s:enumeration value="None" />
115
+ <s:enumeration value="TaxAmount" />
116
+ <s:enumeration value="Exemption" />
117
+ <s:enumeration value="TaxDate" />
118
+ </s:restriction>
119
+ </s:simpleType>
120
+ <s:simpleType name="DetailLevel">
121
+ <s:restriction base="s:string">
122
+ <s:enumeration value="Document" />
123
+ <s:enumeration value="Summary" />
124
+ <s:enumeration value="Line" />
125
+ <s:enumeration value="Tax" />
126
+ <s:enumeration value="Diagnostic" />
127
+ </s:restriction>
128
+ </s:simpleType>
129
+ <s:simpleType name="ServiceMode">
130
+ <s:restriction base="s:string">
131
+ <s:enumeration value="Automatic" />
132
+ <s:enumeration value="Local" />
133
+ <s:enumeration value="Remote" />
134
+ </s:restriction>
135
+ </s:simpleType>
136
+ <s:element name="GetTaxResponse">
137
+ <s:complexType>
138
+ <s:sequence>
139
+ <s:element minOccurs="0" maxOccurs="1" name="GetTaxResult" type="tns:GetTaxResult" />
140
+ </s:sequence>
141
+ </s:complexType>
142
+ </s:element>
143
+ <s:complexType name="GetTaxResult">
144
+ <s:complexContent mixed="false">
145
+ <s:extension base="tns:BaseResult">
146
+ <s:sequence>
147
+ <s:element minOccurs="0" maxOccurs="1" name="DocId" type="s:string" />
148
+ <s:element minOccurs="1" maxOccurs="1" name="DocType" type="tns:DocumentType" />
149
+ <s:element minOccurs="0" maxOccurs="1" name="DocCode" type="s:string" />
150
+ <s:element minOccurs="1" maxOccurs="1" name="DocDate" type="s:date" />
151
+ <s:element minOccurs="1" maxOccurs="1" name="DocStatus" type="tns:DocStatus" />
152
+ <s:element minOccurs="1" maxOccurs="1" name="Reconciled" type="s:boolean" />
153
+ <s:element minOccurs="1" maxOccurs="1" name="Timestamp" type="s:dateTime" />
154
+ <s:element minOccurs="1" maxOccurs="1" name="TotalAmount" type="s:decimal" />
155
+ <s:element minOccurs="1" maxOccurs="1" name="TotalDiscount" type="s:decimal" />
156
+ <s:element minOccurs="1" maxOccurs="1" name="TotalExemption" type="s:decimal" />
157
+ <s:element minOccurs="1" maxOccurs="1" name="TotalTaxable" type="s:decimal" />
158
+ <s:element minOccurs="1" maxOccurs="1" name="TotalTax" type="s:decimal" />
159
+ <s:element minOccurs="1" maxOccurs="1" name="TotalTaxCalculated" type="s:decimal" />
160
+ <s:element minOccurs="1" maxOccurs="1" name="HashCode" type="s:int" />
161
+ <s:element minOccurs="0" maxOccurs="1" name="TaxLines" type="tns:ArrayOfTaxLine" />
162
+ <s:element minOccurs="0" maxOccurs="1" name="TaxAddresses" type="tns:ArrayOfTaxAddress" />
163
+ <s:element minOccurs="1" maxOccurs="1" name="Locked" type="s:boolean" />
164
+ <s:element minOccurs="1" maxOccurs="1" name="AdjustmentReason" type="s:int" />
165
+ <s:element minOccurs="0" maxOccurs="1" name="AdjustmentDescription" type="s:string" />
166
+ <s:element minOccurs="1" maxOccurs="1" name="Version" type="s:int" />
167
+ <s:element minOccurs="1" maxOccurs="1" name="TaxDate" type="s:date" />
168
+ <s:element minOccurs="0" maxOccurs="1" name="TaxSummary" type="tns:ArrayOfTaxDetail" />
169
+ <s:element minOccurs="0" maxOccurs="1" name="Signature" type="s:string" />
170
+ </s:sequence>
171
+ </s:extension>
172
+ </s:complexContent>
173
+ </s:complexType>
174
+ <s:complexType name="BaseResult">
175
+ <s:sequence>
176
+ <s:element minOccurs="0" maxOccurs="1" name="TransactionId" type="s:string" />
177
+ <s:element minOccurs="1" maxOccurs="1" name="ResultCode" type="tns:SeverityLevel" />
178
+ <s:element minOccurs="0" maxOccurs="1" name="Messages" type="tns:ArrayOfMessage" />
179
+ </s:sequence>
180
+ </s:complexType>
181
+ <s:simpleType name="SeverityLevel">
182
+ <s:restriction base="s:string">
183
+ <s:enumeration value="Success" />
184
+ <s:enumeration value="Warning" />
185
+ <s:enumeration value="Error" />
186
+ <s:enumeration value="Exception" />
187
+ </s:restriction>
188
+ </s:simpleType>
189
+ <s:complexType name="ArrayOfMessage">
190
+ <s:sequence>
191
+ <s:element minOccurs="0" maxOccurs="unbounded" name="Message" nillable="true" type="tns:Message" />
192
+ </s:sequence>
193
+ </s:complexType>
194
+ <s:complexType name="Message">
195
+ <s:sequence>
196
+ <s:element minOccurs="0" maxOccurs="1" name="Summary" type="s:string" />
197
+ <s:element minOccurs="0" maxOccurs="1" name="Details" type="s:string" />
198
+ <s:element minOccurs="0" maxOccurs="1" name="HelpLink" type="s:string" />
199
+ <s:element minOccurs="0" maxOccurs="1" name="RefersTo" type="s:string" />
200
+ <s:element minOccurs="1" maxOccurs="1" name="Severity" type="tns:SeverityLevel" />
201
+ <s:element minOccurs="0" maxOccurs="1" name="Source" type="s:string" />
202
+ </s:sequence>
203
+ <s:attribute name="Name" type="s:string" />
204
+ </s:complexType>
205
+ <s:simpleType name="DocStatus">
206
+ <s:restriction base="s:string">
207
+ <s:enumeration value="Temporary" />
208
+ <s:enumeration value="Saved" />
209
+ <s:enumeration value="Posted" />
210
+ <s:enumeration value="Committed" />
211
+ <s:enumeration value="Cancelled" />
212
+ <s:enumeration value="Adjusted" />
213
+ <s:enumeration value="Any" />
214
+ </s:restriction>
215
+ </s:simpleType>
216
+ <s:complexType name="ArrayOfTaxLine">
217
+ <s:sequence>
218
+ <s:element minOccurs="0" maxOccurs="unbounded" name="TaxLine" nillable="true" type="tns:TaxLine" />
219
+ </s:sequence>
220
+ </s:complexType>
221
+ <s:complexType name="TaxLine">
222
+ <s:sequence>
223
+ <s:element minOccurs="0" maxOccurs="1" name="No" type="s:string" />
224
+ <s:element minOccurs="0" maxOccurs="1" name="TaxCode" type="s:string" />
225
+ <s:element minOccurs="1" maxOccurs="1" name="Taxability" type="s:boolean" />
226
+ <s:element minOccurs="1" maxOccurs="1" name="BoundaryLevel" type="tns:BoundaryLevel" />
227
+ <s:element minOccurs="1" maxOccurs="1" name="Exemption" type="s:decimal" />
228
+ <s:element minOccurs="1" maxOccurs="1" name="Discount" type="s:decimal" />
229
+ <s:element minOccurs="1" maxOccurs="1" name="Taxable" type="s:decimal" />
230
+ <s:element minOccurs="1" maxOccurs="1" name="Rate" type="s:decimal" />
231
+ <s:element minOccurs="1" maxOccurs="1" name="Tax" type="s:decimal" />
232
+ <s:element minOccurs="1" maxOccurs="1" name="TaxCalculated" type="s:decimal" />
233
+ <s:element minOccurs="0" maxOccurs="1" name="TaxDetails" type="tns:ArrayOfTaxDetail" />
234
+ <s:element minOccurs="1" maxOccurs="1" name="ExemptCertId" type="s:int" />
235
+ <s:element minOccurs="1" maxOccurs="1" name="TaxDate" type="s:date" />
236
+ <s:element minOccurs="1" maxOccurs="1" name="ReportingDate" type="s:date" />
237
+ <s:element minOccurs="1" maxOccurs="1" name="AccountingMethod" type="tns:AccountingMethod" />
238
+ <s:element minOccurs="0" maxOccurs="1" name="TaxIncluded" type="s:boolean" default="false" />
239
+ </s:sequence>
240
+ </s:complexType>
241
+ <s:simpleType name="BoundaryLevel">
242
+ <s:restriction base="s:string">
243
+ <s:enumeration value="Address" />
244
+ <s:enumeration value="Zip9" />
245
+ <s:enumeration value="Zip5" />
246
+ </s:restriction>
247
+ </s:simpleType>
248
+ <s:complexType name="ArrayOfTaxDetail">
249
+ <s:sequence>
250
+ <s:element minOccurs="0" maxOccurs="unbounded" name="TaxDetail" nillable="true" type="tns:TaxDetail" />
251
+ </s:sequence>
252
+ </s:complexType>
253
+ <s:complexType name="TaxDetail">
254
+ <s:sequence>
255
+ <s:element minOccurs="0" maxOccurs="1" name="Country" type="s:string" />
256
+ <s:element minOccurs="0" maxOccurs="1" name="Region" type="s:string" />
257
+ <s:element minOccurs="1" maxOccurs="1" name="JurisType" type="tns:JurisdictionType" />
258
+ <s:element minOccurs="0" maxOccurs="1" name="JurisCode" type="s:string" />
259
+ <s:element minOccurs="1" maxOccurs="1" name="TaxType" type="tns:TaxType" />
260
+ <s:element minOccurs="1" maxOccurs="1" name="Base" type="s:decimal" />
261
+ <s:element minOccurs="1" maxOccurs="1" name="Taxable" type="s:decimal" />
262
+ <s:element minOccurs="1" maxOccurs="1" name="Rate" type="s:decimal" />
263
+ <s:element minOccurs="1" maxOccurs="1" name="Tax" type="s:decimal" />
264
+ <s:element minOccurs="1" maxOccurs="1" name="TaxCalculated" type="s:decimal" />
265
+ <s:element minOccurs="1" maxOccurs="1" name="NonTaxable" type="s:decimal" />
266
+ <s:element minOccurs="1" maxOccurs="1" name="Exemption" type="s:decimal" />
267
+ <s:element minOccurs="0" maxOccurs="1" name="JurisName" type="s:string" />
268
+ <s:element minOccurs="0" maxOccurs="1" name="TaxName" type="s:string" />
269
+ <s:element minOccurs="1" maxOccurs="1" name="TaxAuthorityType" type="s:int" />
270
+ <s:element minOccurs="0" maxOccurs="1" name="TaxGroup" type="s:string" />
271
+ <s:element minOccurs="0" maxOccurs="1" name="RateType" type="s:string" />
272
+ <s:element minOccurs="0" maxOccurs="1" name="StateAssignedNo" type="s:string" />
273
+ </s:sequence>
274
+ </s:complexType>
275
+ <s:simpleType name="JurisdictionType">
276
+ <s:restriction base="s:string">
277
+ <s:enumeration value="Country" />
278
+ <s:enumeration value="Composite" />
279
+ <s:enumeration value="State" />
280
+ <s:enumeration value="County" />
281
+ <s:enumeration value="City" />
282
+ <s:enumeration value="Special" />
283
+ </s:restriction>
284
+ </s:simpleType>
285
+ <s:simpleType name="TaxType">
286
+ <s:restriction base="s:string">
287
+ <s:enumeration value="Sales" />
288
+ <s:enumeration value="Use" />
289
+ <s:enumeration value="ConsumerUse" />
290
+ <s:enumeration value="Output" />
291
+ <s:enumeration value="Input" />
292
+ <s:enumeration value="Nonrecoverable" />
293
+ <s:enumeration value="Fee" />
294
+ <s:enumeration value="Rental" />
295
+ </s:restriction>
296
+ </s:simpleType>
297
+ <s:simpleType name="AccountingMethod">
298
+ <s:restriction base="s:string">
299
+ <s:enumeration value="Accrual" />
300
+ <s:enumeration value="Cash" />
301
+ </s:restriction>
302
+ </s:simpleType>
303
+ <s:complexType name="ArrayOfTaxAddress">
304
+ <s:sequence>
305
+ <s:element minOccurs="0" maxOccurs="unbounded" name="TaxAddress" nillable="true" type="tns:TaxAddress" />
306
+ </s:sequence>
307
+ </s:complexType>
308
+ <s:complexType name="TaxAddress">
309
+ <s:sequence>
310
+ <s:element minOccurs="0" maxOccurs="1" name="Address" type="s:string" />
311
+ <s:element minOccurs="0" maxOccurs="1" name="AddressCode" type="s:string" />
312
+ <s:element minOccurs="1" maxOccurs="1" name="BoundaryLevel" type="s:int" />
313
+ <s:element minOccurs="0" maxOccurs="1" name="City" type="s:string" />
314
+ <s:element minOccurs="0" maxOccurs="1" name="Country" type="s:string" />
315
+ <s:element minOccurs="0" maxOccurs="1" name="PostalCode" type="s:string" />
316
+ <s:element minOccurs="0" maxOccurs="1" name="Region" type="s:string" />
317
+ <s:element minOccurs="1" maxOccurs="1" name="TaxRegionId" type="s:int" />
318
+ <s:element minOccurs="0" maxOccurs="1" name="JurisCode" type="s:string" />
319
+ </s:sequence>
320
+ </s:complexType>
321
+ <s:element name="Profile" type="tns:Profile" />
322
+ <s:complexType name="Profile">
323
+ <s:sequence>
324
+ <s:element minOccurs="0" maxOccurs="1" name="Name" type="s:string" />
325
+ <s:element minOccurs="0" maxOccurs="1" name="Client" type="s:string" />
326
+ <s:element minOccurs="0" maxOccurs="1" name="Adapter" type="s:string" />
327
+ <s:element minOccurs="0" maxOccurs="1" name="Machine" type="s:string" />
328
+ </s:sequence>
329
+ <s:anyAttribute />
330
+ </s:complexType>
331
+ <s:element name="GetTaxHistory">
332
+ <s:complexType>
333
+ <s:sequence>
334
+ <s:element minOccurs="0" maxOccurs="1" name="GetTaxHistoryRequest" type="tns:GetTaxHistoryRequest" />
335
+ </s:sequence>
336
+ </s:complexType>
337
+ </s:element>
338
+ <s:complexType name="GetTaxHistoryRequest">
339
+ <s:complexContent mixed="false">
340
+ <s:extension base="tns:BaseRequest">
341
+ <s:sequence>
342
+ <s:element minOccurs="0" maxOccurs="1" name="DocId" type="s:string" />
343
+ <s:element minOccurs="0" maxOccurs="1" name="CompanyCode" type="s:string" />
344
+ <s:element minOccurs="1" maxOccurs="1" name="DocType" type="tns:DocumentType" />
345
+ <s:element minOccurs="0" maxOccurs="1" name="DocCode" type="s:string" />
346
+ <s:element minOccurs="1" maxOccurs="1" name="DetailLevel" type="tns:DetailLevel" />
347
+ </s:sequence>
348
+ </s:extension>
349
+ </s:complexContent>
350
+ </s:complexType>
351
+ <s:element name="GetTaxHistoryResponse">
352
+ <s:complexType>
353
+ <s:sequence>
354
+ <s:element minOccurs="0" maxOccurs="1" name="GetTaxHistoryResult" type="tns:GetTaxHistoryResult" />
355
+ </s:sequence>
356
+ </s:complexType>
357
+ </s:element>
358
+ <s:complexType name="GetTaxHistoryResult">
359
+ <s:complexContent mixed="false">
360
+ <s:extension base="tns:BaseResult">
361
+ <s:sequence>
362
+ <s:element minOccurs="0" maxOccurs="1" name="GetTaxRequest" type="tns:GetTaxRequest" />
363
+ <s:element minOccurs="0" maxOccurs="1" name="GetTaxResult" type="tns:GetTaxResult" />
364
+ </s:sequence>
365
+ </s:extension>
366
+ </s:complexContent>
367
+ </s:complexType>
368
+ <!-- <s:simpleType name="ConfirmationType">
369
+ <s:restriction base="s:string">
370
+ <s:enumeration value="None" />
371
+ <s:enumeration value="Optional" />
372
+ <s:enumeration value="Required" />
373
+ </s:restriction>
374
+ </s:simpleType> -->
375
+ <s:element name="PostTax">
376
+ <s:complexType>
377
+ <s:sequence>
378
+ <s:element minOccurs="0" maxOccurs="1" name="PostTaxRequest" type="tns:PostTaxRequest" />
379
+ </s:sequence>
380
+ </s:complexType>
381
+ </s:element>
382
+ <s:complexType name="PostTaxRequest">
383
+ <s:complexContent mixed="false">
384
+ <s:extension base="tns:BaseRequest">
385
+ <s:sequence>
386
+ <s:element minOccurs="0" maxOccurs="1" name="DocId" type="s:string" />
387
+ <s:element minOccurs="0" maxOccurs="1" name="CompanyCode" type="s:string" />
388
+ <s:element minOccurs="1" maxOccurs="1" name="DocType" type="tns:DocumentType" />
389
+ <s:element minOccurs="0" maxOccurs="1" name="DocCode" type="s:string" />
390
+ <s:element minOccurs="1" maxOccurs="1" name="DocDate" type="s:date" />
391
+ <s:element minOccurs="1" maxOccurs="1" name="TotalAmount" type="s:decimal" />
392
+ <s:element minOccurs="1" maxOccurs="1" name="TotalTax" type="s:decimal" />
393
+ <s:element minOccurs="1" maxOccurs="1" name="HashCode" type="s:int" />
394
+ <s:element minOccurs="1" maxOccurs="1" name="Commit" type="s:boolean" />
395
+ <s:element minOccurs="0" maxOccurs="1" name="NewDocCode" type="s:string" />
396
+ <s:element minOccurs="0" maxOccurs="1" name="Signature" type="s:string" />
397
+ <!-- <s:element minOccurs="0" maxOccurs="1" name="Confirmation" type="tns:ConfirmationType" /> -->
398
+ </s:sequence>
399
+ </s:extension>
400
+ </s:complexContent>
401
+ </s:complexType>
402
+ <s:element name="PostTaxResponse">
403
+ <s:complexType>
404
+ <s:sequence>
405
+ <s:element minOccurs="0" maxOccurs="1" name="PostTaxResult" type="tns:PostTaxResult" />
406
+ </s:sequence>
407
+ </s:complexType>
408
+ </s:element>
409
+ <s:complexType name="PostTaxResult">
410
+ <s:complexContent mixed="false">
411
+ <s:extension base="tns:BaseResult">
412
+ <s:sequence>
413
+ <s:element minOccurs="0" maxOccurs="1" name="DocId" type="s:string" />
414
+ </s:sequence>
415
+ </s:extension>
416
+ </s:complexContent>
417
+ </s:complexType>
418
+ <s:element name="CommitTax">
419
+ <s:complexType>
420
+ <s:sequence>
421
+ <s:element minOccurs="0" maxOccurs="1" name="CommitTaxRequest" type="tns:CommitTaxRequest" />
422
+ </s:sequence>
423
+ </s:complexType>
424
+ </s:element>
425
+ <s:complexType name="CommitTaxRequest">
426
+ <s:complexContent mixed="false">
427
+ <s:extension base="tns:BaseRequest">
428
+ <s:sequence>
429
+ <s:element minOccurs="0" maxOccurs="1" name="DocId" type="s:string" />
430
+ <s:element minOccurs="0" maxOccurs="1" name="CompanyCode" type="s:string" />
431
+ <s:element minOccurs="1" maxOccurs="1" name="DocType" type="tns:DocumentType" />
432
+ <s:element minOccurs="0" maxOccurs="1" name="DocCode" type="s:string" />
433
+ <s:element minOccurs="0" maxOccurs="1" name="NewDocCode" type="s:string" />
434
+ </s:sequence>
435
+ </s:extension>
436
+ </s:complexContent>
437
+ </s:complexType>
438
+ <s:element name="CommitTaxResponse">
439
+ <s:complexType>
440
+ <s:sequence>
441
+ <s:element minOccurs="0" maxOccurs="1" name="CommitTaxResult" type="tns:CommitTaxResult" />
442
+ </s:sequence>
443
+ </s:complexType>
444
+ </s:element>
445
+ <s:complexType name="CommitTaxResult">
446
+ <s:complexContent mixed="false">
447
+ <s:extension base="tns:BaseResult">
448
+ <s:sequence>
449
+ <s:element minOccurs="0" maxOccurs="1" name="DocId" type="s:string" />
450
+ </s:sequence>
451
+ </s:extension>
452
+ </s:complexContent>
453
+ </s:complexType>
454
+ <s:element name="AuditMessage" type="tns:AuditMessage" />
455
+ <s:complexType name="AuditMessage">
456
+ <s:sequence>
457
+ <s:element minOccurs="0" maxOccurs="1" name="Message" type="s:string" />
458
+ </s:sequence>
459
+ <s:anyAttribute />
460
+ </s:complexType>
461
+ <s:element name="CancelTax">
462
+ <s:complexType>
463
+ <s:sequence>
464
+ <s:element minOccurs="0" maxOccurs="1" name="CancelTaxRequest" type="tns:CancelTaxRequest" />
465
+ </s:sequence>
466
+ </s:complexType>
467
+ </s:element>
468
+ <s:complexType name="CancelTaxRequest">
469
+ <s:complexContent mixed="false">
470
+ <s:extension base="tns:BaseRequest">
471
+ <s:sequence>
472
+ <s:element minOccurs="0" maxOccurs="1" name="DocId" type="s:string" />
473
+ <s:element minOccurs="0" maxOccurs="1" name="CompanyCode" type="s:string" />
474
+ <s:element minOccurs="1" maxOccurs="1" name="DocType" type="tns:DocumentType" />
475
+ <s:element minOccurs="0" maxOccurs="1" name="DocCode" type="s:string" />
476
+ <s:element minOccurs="1" maxOccurs="1" name="CancelCode" type="tns:CancelCode" />
477
+ </s:sequence>
478
+ </s:extension>
479
+ </s:complexContent>
480
+ </s:complexType>
481
+ <s:simpleType name="CancelCode">
482
+ <s:restriction base="s:string">
483
+ <s:enumeration value="Unspecified" />
484
+ <s:enumeration value="PostFailed" />
485
+ <s:enumeration value="DocDeleted" />
486
+ <s:enumeration value="DocVoided" />
487
+ <s:enumeration value="AdjustmentCancelled" />
488
+ </s:restriction>
489
+ </s:simpleType>
490
+ <s:element name="CancelTaxResponse">
491
+ <s:complexType>
492
+ <s:sequence>
493
+ <s:element minOccurs="0" maxOccurs="1" name="CancelTaxResult" type="tns:CancelTaxResult" />
494
+ </s:sequence>
495
+ </s:complexType>
496
+ </s:element>
497
+ <s:complexType name="CancelTaxResult">
498
+ <s:complexContent mixed="false">
499
+ <s:extension base="tns:BaseResult">
500
+ <s:sequence>
501
+ <s:element minOccurs="0" maxOccurs="1" name="DocId" type="s:string" />
502
+ </s:sequence>
503
+ </s:extension>
504
+ </s:complexContent>
505
+ </s:complexType>
506
+ <s:element name="ReconcileTaxHistory">
507
+ <s:complexType>
508
+ <s:sequence>
509
+ <s:element minOccurs="0" maxOccurs="1" name="ReconcileTaxHistoryRequest" type="tns:ReconcileTaxHistoryRequest" />
510
+ </s:sequence>
511
+ </s:complexType>
512
+ </s:element>
513
+ <s:complexType name="ReconcileTaxHistoryRequest">
514
+ <s:complexContent mixed="false">
515
+ <s:extension base="tns:BaseRequest">
516
+ <s:sequence>
517
+ <s:element minOccurs="0" maxOccurs="1" name="CompanyCode" type="s:string" />
518
+ <s:element minOccurs="1" maxOccurs="1" name="StartDate" type="s:date" />
519
+ <s:element minOccurs="1" maxOccurs="1" name="EndDate" type="s:date" />
520
+ <s:element minOccurs="1" maxOccurs="1" name="DocStatus" type="tns:DocStatus" />
521
+ <s:element minOccurs="1" maxOccurs="1" name="DocType" type="tns:DocumentType"/>
522
+ <s:element minOccurs="1" maxOccurs="1" name="LastDocCode" type="s:string"/>
523
+ <s:element minOccurs="1" maxOccurs="1" name="PageSize" type="s:int"/>
524
+ </s:sequence>
525
+ </s:extension>
526
+ </s:complexContent>
527
+ </s:complexType>
528
+ <s:element name="ReconcileTaxHistoryResponse">
529
+ <s:complexType>
530
+ <s:sequence>
531
+ <s:element minOccurs="0" maxOccurs="1" name="ReconcileTaxHistoryResult" type="tns:ReconcileTaxHistoryResult" />
532
+ </s:sequence>
533
+ </s:complexType>
534
+ </s:element>
535
+ <s:complexType name="ReconcileTaxHistoryResult">
536
+ <s:complexContent mixed="false">
537
+ <s:extension base="tns:SearchTaxHistoryResult">
538
+ <s:sequence>
539
+ <s:element minOccurs="0" maxOccurs="1" name="RecordCount" type="s:int"></s:element>
540
+ </s:sequence>
541
+ </s:extension>
542
+ </s:complexContent>
543
+ </s:complexType>
544
+ <s:complexType name="SearchTaxHistoryResult">
545
+ <s:complexContent mixed="false">
546
+ <s:extension base="tns:BaseResult">
547
+ <s:sequence>
548
+ <s:element minOccurs="0" maxOccurs="1" name="GetTaxResults" type="tns:ArrayOfGetTaxResult" />
549
+ <s:element minOccurs="0" maxOccurs="1" name="LastDocCode" type="s:string" />
550
+ </s:sequence>
551
+ </s:extension>
552
+ </s:complexContent>
553
+ </s:complexType>
554
+ <s:complexType name="ArrayOfGetTaxResult">
555
+ <s:sequence>
556
+ <s:element minOccurs="0" maxOccurs="unbounded" name="GetTaxResult" nillable="true" type="tns:GetTaxResult" />
557
+ </s:sequence>
558
+ </s:complexType>
559
+ <s:element name="AdjustTax">
560
+ <s:complexType>
561
+ <s:sequence>
562
+ <s:element minOccurs="0" maxOccurs="1" name="AdjustTaxRequest" type="tns:AdjustTaxRequest" />
563
+ </s:sequence>
564
+ </s:complexType>
565
+ </s:element>
566
+ <s:complexType name="AdjustTaxRequest">
567
+ <s:complexContent mixed="false">
568
+ <s:extension base="tns:BaseRequest">
569
+ <s:sequence>
570
+ <s:element minOccurs="1" maxOccurs="1" name="AdjustmentReason" type="s:int" />
571
+ <s:element minOccurs="0" maxOccurs="1" name="AdjustmentDescription" type="s:string" />
572
+ <s:element minOccurs="0" maxOccurs="1" name="GetTaxRequest" type="tns:GetTaxRequest" />
573
+ </s:sequence>
574
+ </s:extension>
575
+ </s:complexContent>
576
+ </s:complexType>
577
+ <s:element name="AdjustTaxResponse">
578
+ <s:complexType>
579
+ <s:sequence>
580
+ <s:element minOccurs="0" maxOccurs="1" name="AdjustTaxResult" type="tns:AdjustTaxResult" />
581
+ </s:sequence>
582
+ </s:complexType>
583
+ </s:element>
584
+ <s:complexType name="AdjustTaxResult">
585
+ <s:complexContent mixed="false">
586
+ <s:extension base="tns:GetTaxResult" />
587
+ </s:complexContent>
588
+ </s:complexType>
589
+ <s:element name="ApplyPayment">
590
+ <s:complexType>
591
+ <s:sequence>
592
+ <s:element minOccurs="0" maxOccurs="1" name="ApplyPaymentRequest" type="tns:ApplyPaymentRequest" />
593
+ </s:sequence>
594
+ </s:complexType>
595
+ </s:element>
596
+ <s:complexType name="ApplyPaymentRequest">
597
+ <s:complexContent mixed="false">
598
+ <s:extension base="tns:BaseRequest">
599
+ <s:sequence>
600
+ <s:element minOccurs="0" maxOccurs="1" name="DocId" type="s:string" />
601
+ <s:element minOccurs="0" maxOccurs="1" name="CompanyCode" type="s:string" />
602
+ <s:element minOccurs="1" maxOccurs="1" name="DocType" type="tns:DocumentType" />
603
+ <s:element minOccurs="0" maxOccurs="1" name="DocCode" type="s:string" />
604
+ <s:element minOccurs="1" maxOccurs="1" name="PaymentDate" type="s:dateTime" />
605
+ </s:sequence>
606
+ </s:extension>
607
+ </s:complexContent>
608
+ </s:complexType>
609
+ <s:element name="ApplyPaymentResponse">
610
+ <s:complexType>
611
+ <s:sequence>
612
+ <s:element minOccurs="0" maxOccurs="1" name="ApplyPaymentResult" type="tns:ApplyPaymentResult" />
613
+ </s:sequence>
614
+ </s:complexType>
615
+ </s:element>
616
+ <s:complexType name="ApplyPaymentResult">
617
+ <s:complexContent mixed="false">
618
+ <s:extension base="tns:BaseResult">
619
+ <s:sequence>
620
+ <s:element minOccurs="0" maxOccurs="1" name="DocId" type="s:string" />
621
+ </s:sequence>
622
+ </s:extension>
623
+ </s:complexContent>
624
+ </s:complexType>
625
+ <!-- Begin New Methods-->
626
+ <s:element name="SubmitBatch">
627
+ <s:complexType>
628
+ <s:sequence>
629
+ <s:element minOccurs="0" maxOccurs="1" name="SubmitTaxBatchRequest" type="tns:SubmitTaxBatchRequest" />
630
+ </s:sequence>
631
+ </s:complexType>
632
+ </s:element>
633
+ <s:complexType name="SubmitTaxBatchRequest">
634
+ <s:complexContent mixed="false">
635
+ <s:extension base="tns:BaseRequest">
636
+ <s:sequence>
637
+ <s:element minOccurs="0" maxOccurs="1" name="Requests" type="tns:RequestList" />
638
+ <s:element minOccurs="0" maxOccurs="1" name="Name" type="s:string"/>
639
+ <s:element minOccurs="0" maxOccurs="1" name="BatchTypeId" type="s:string"/>
640
+ <s:element minOccurs="0" maxOccurs="1" name="Options" type="s:string"/>
641
+ </s:sequence>
642
+ </s:extension>
643
+ </s:complexContent>
644
+ </s:complexType>
645
+ <s:complexType name="RequestList">
646
+ <s:choice minOccurs="0" maxOccurs="unbounded">
647
+ <s:element name="AdjustTaxRequest" nillable="true" type="tns:AdjustTaxRequest" />
648
+ <s:element name="ApplyPaymentRequest" nillable="true" type="tns:ApplyPaymentRequest" />
649
+ <s:element name="CancelTaxRequest" nillable="true" type="tns:CancelTaxRequest" />
650
+ <s:element name="CommitTaxRequest" nillable="true" type="tns:CommitTaxRequest" />
651
+ <s:element name="GetTaxHistoryRequest" nillable="true" type="tns:GetTaxHistoryRequest" />
652
+ <s:element name="GetTaxRequest" nillable="true" type="tns:GetTaxRequest" />
653
+ <s:element name="PostTaxRequest" nillable="true" type="tns:PostTaxRequest" />
654
+ <s:element name="ReconcileTaxHistoryRequest" nillable="true" type="tns:ReconcileTaxHistoryRequest" />
655
+ </s:choice>
656
+ </s:complexType>
657
+ <s:element name="SubmitBatchResponse">
658
+ <s:complexType>
659
+ <s:sequence>
660
+ <s:element minOccurs="0" maxOccurs="1" name="SubmitBatchResult" type="tns:SubmitTaxBatchResult" />
661
+ </s:sequence>
662
+ </s:complexType>
663
+ </s:element>
664
+ <s:complexType name="SubmitTaxBatchResult">
665
+ <s:complexContent mixed="false">
666
+ <s:extension base="tns:BaseResult">
667
+ <s:sequence>
668
+ <s:element minOccurs="0" maxOccurs="1" name="BatchId" type="s:string" />
669
+ </s:sequence>
670
+ </s:extension>
671
+ </s:complexContent>
672
+ </s:complexType>
673
+
674
+ <s:element name="GetBatch">
675
+ <s:complexType>
676
+ <s:sequence>
677
+ <s:element minOccurs="0" maxOccurs="1" name="GetTaxBatchRequest" type="tns:GetTaxBatchRequest" />
678
+ </s:sequence>
679
+ </s:complexType>
680
+ </s:element>
681
+ <s:complexType name="GetTaxBatchRequest">
682
+ <s:complexContent mixed="false">
683
+ <s:extension base="tns:BaseRequest">
684
+ <s:sequence>
685
+ <s:element minOccurs="1" maxOccurs="1" name="BatchId" type="s:string" />
686
+ </s:sequence>
687
+ </s:extension>
688
+ </s:complexContent>
689
+ </s:complexType>
690
+ <s:element name="GetBatchResponse">
691
+ <s:complexType>
692
+ <s:sequence>
693
+ <s:element minOccurs="0" maxOccurs="1" name="GetBatchResult" type="tns:GetTaxBatchResult" />
694
+ </s:sequence>
695
+ </s:complexType>
696
+ </s:element>
697
+ <s:complexType name="GetTaxBatchResult">
698
+ <s:complexContent mixed="false">
699
+ <s:extension base="tns:BaseResult">
700
+ <s:sequence>
701
+ <s:element minOccurs="1" maxOccurs="1" name="BatchId" type="s:string" />
702
+ <s:element minOccurs="1" maxOccurs="1" name="BatchStatus" type="s:string" />
703
+ <s:element minOccurs="1" maxOccurs="1" name="RecordCount" type="s:int" />
704
+ <s:element minOccurs="1" maxOccurs="1" name="CurrentRecord" type="s:int" />
705
+ <s:element minOccurs="0" maxOccurs="1" name="Results" type="tns:ResultList" />
706
+ </s:sequence>
707
+ </s:extension>
708
+ </s:complexContent>
709
+ </s:complexType>
710
+ <s:complexType name="ResultList">
711
+ <s:choice minOccurs="0" maxOccurs="unbounded">
712
+ <s:element name="AdjustTaxResult" nillable="true" type="tns:AdjustTaxResult" />
713
+ <s:element name="ApplyPaymentResult" nillable="true" type="tns:ApplyPaymentResult" />
714
+ <s:element name="CancelTaxResult" nillable="true" type="tns:CancelTaxResult" />
715
+ <s:element name="CommitTaxResult" nillable="true" type="tns:CommitTaxResult" />
716
+ <s:element name="GetTaxHistoryResult" nillable="true" type="tns:GetTaxHistoryResult" />
717
+ <s:element name="GetTaxResult" nillable="true" type="tns:GetTaxResult" />
718
+ <s:element name="PostTaxResult" nillable="true" type="tns:PostTaxResult" />
719
+ <s:element name="ReconcileTaxHistoryResult" nillable="true" type="tns:ReconcileTaxHistoryResult" />
720
+ </s:choice>
721
+ </s:complexType>
722
+
723
+ <s:element name="CancelBatch">
724
+ <s:complexType>
725
+ <s:sequence>
726
+ <s:element minOccurs="0" maxOccurs="1" name="CancelTaxBatchRequest" type="tns:CancelTaxBatchRequest" />
727
+ </s:sequence>
728
+ </s:complexType>
729
+ </s:element>
730
+ <s:complexType name="CancelTaxBatchRequest">
731
+ <s:complexContent mixed="false">
732
+ <s:extension base="tns:BaseRequest">
733
+ <s:sequence>
734
+ <s:element minOccurs="1" maxOccurs="1" name="BatchId" type="s:string" />
735
+ </s:sequence>
736
+ </s:extension>
737
+ </s:complexContent>
738
+ </s:complexType>
739
+ <s:element name="CancelBatchResponse">
740
+ <s:complexType>
741
+ <s:sequence>
742
+ <s:element minOccurs="0" maxOccurs="1" name="CancelBatchResult" type="tns:CancelTaxBatchResult" />
743
+ </s:sequence>
744
+ </s:complexType>
745
+ </s:element>
746
+ <s:complexType name="CancelTaxBatchResult">
747
+ <s:complexContent mixed="false">
748
+ <s:extension base="tns:BaseResult" />
749
+ </s:complexContent>
750
+ </s:complexType>
751
+ <!-- End New Methods -->
752
+ <s:element name="Ping">
753
+ <s:complexType>
754
+ <s:sequence>
755
+ <s:element minOccurs="0" maxOccurs="1" name="Message" type="s:string" />
756
+ </s:sequence>
757
+ </s:complexType>
758
+ </s:element>
759
+ <s:element name="PingResponse">
760
+ <s:complexType>
761
+ <s:sequence>
762
+ <s:element minOccurs="0" maxOccurs="1" name="PingResult" type="tns:PingResult" />
763
+ </s:sequence>
764
+ </s:complexType>
765
+ </s:element>
766
+ <s:complexType name="PingResult">
767
+ <s:complexContent mixed="false">
768
+ <s:extension base="tns:BaseResult">
769
+ <s:sequence>
770
+ <s:element minOccurs="0" maxOccurs="1" name="Version" type="s:string" />
771
+ </s:sequence>
772
+ </s:extension>
773
+ </s:complexContent>
774
+ </s:complexType>
775
+ <s:element name="IsAuthorized">
776
+ <s:complexType>
777
+ <s:sequence>
778
+ <s:element minOccurs="0" maxOccurs="1" name="Operations" type="s:string" />
779
+ </s:sequence>
780
+ </s:complexType>
781
+ </s:element>
782
+ <s:element name="IsAuthorizedResponse">
783
+ <s:complexType>
784
+ <s:sequence>
785
+ <s:element minOccurs="0" maxOccurs="1" name="IsAuthorizedResult" type="tns:IsAuthorizedResult" />
786
+ </s:sequence>
787
+ </s:complexType>
788
+ </s:element>
789
+ <s:complexType name="IsAuthorizedResult">
790
+ <s:complexContent mixed="false">
791
+ <s:extension base="tns:BaseResult">
792
+ <s:sequence>
793
+ <s:element minOccurs="0" maxOccurs="1" name="Operations" type="s:string" />
794
+ <s:element minOccurs="1" maxOccurs="1" name="Expires" type="s:dateTime" />
795
+ </s:sequence>
796
+ </s:extension>
797
+ </s:complexContent>
798
+ </s:complexType>
799
+ </s:schema>
800
+ </wsdl:types>
801
+ <wsdl:message name="GetTaxSoapIn">
802
+ <wsdl:part name="parameters" element="tns:GetTax" />
803
+ </wsdl:message>
804
+ <wsdl:message name="GetTaxSoapOut">
805
+ <wsdl:part name="parameters" element="tns:GetTaxResponse" />
806
+ </wsdl:message>
807
+ <wsdl:message name="GetTaxProfile">
808
+ <wsdl:part name="Profile" element="tns:Profile" />
809
+ </wsdl:message>
810
+ <wsdl:message name="GetTaxHistorySoapIn">
811
+ <wsdl:part name="parameters" element="tns:GetTaxHistory" />
812
+ </wsdl:message>
813
+ <wsdl:message name="GetTaxHistorySoapOut">
814
+ <wsdl:part name="parameters" element="tns:GetTaxHistoryResponse" />
815
+ </wsdl:message>
816
+ <wsdl:message name="GetTaxHistoryProfile">
817
+ <wsdl:part name="Profile" element="tns:Profile" />
818
+ </wsdl:message>
819
+ <wsdl:message name="PostTaxSoapIn">
820
+ <wsdl:part name="parameters" element="tns:PostTax" />
821
+ </wsdl:message>
822
+ <wsdl:message name="PostTaxSoapOut">
823
+ <wsdl:part name="parameters" element="tns:PostTaxResponse" />
824
+ </wsdl:message>
825
+ <wsdl:message name="PostTaxProfile">
826
+ <wsdl:part name="Profile" element="tns:Profile" />
827
+ </wsdl:message>
828
+ <wsdl:message name="CommitTaxSoapIn">
829
+ <wsdl:part name="parameters" element="tns:CommitTax" />
830
+ </wsdl:message>
831
+ <wsdl:message name="CommitTaxSoapOut">
832
+ <wsdl:part name="parameters" element="tns:CommitTaxResponse" />
833
+ </wsdl:message>
834
+ <wsdl:message name="CommitTaxAuditMessage">
835
+ <wsdl:part name="AuditMessage" element="tns:AuditMessage" />
836
+ </wsdl:message>
837
+ <wsdl:message name="CommitTaxProfile">
838
+ <wsdl:part name="Profile" element="tns:Profile" />
839
+ </wsdl:message>
840
+ <wsdl:message name="CancelTaxSoapIn">
841
+ <wsdl:part name="parameters" element="tns:CancelTax" />
842
+ </wsdl:message>
843
+ <wsdl:message name="CancelTaxSoapOut">
844
+ <wsdl:part name="parameters" element="tns:CancelTaxResponse" />
845
+ </wsdl:message>
846
+ <wsdl:message name="CancelTaxAuditMessage">
847
+ <wsdl:part name="AuditMessage" element="tns:AuditMessage" />
848
+ </wsdl:message>
849
+ <wsdl:message name="CancelTaxProfile">
850
+ <wsdl:part name="Profile" element="tns:Profile" />
851
+ </wsdl:message>
852
+ <wsdl:message name="ReconcileTaxHistorySoapIn">
853
+ <wsdl:part name="parameters" element="tns:ReconcileTaxHistory" />
854
+ </wsdl:message>
855
+ <wsdl:message name="ReconcileTaxHistorySoapOut">
856
+ <wsdl:part name="parameters" element="tns:ReconcileTaxHistoryResponse" />
857
+ </wsdl:message>
858
+ <wsdl:message name="ReconcileTaxHistoryProfile">
859
+ <wsdl:part name="Profile" element="tns:Profile" />
860
+ </wsdl:message>
861
+ <wsdl:message name="AdjustTaxSoapIn">
862
+ <wsdl:part name="parameters" element="tns:AdjustTax" />
863
+ </wsdl:message>
864
+ <wsdl:message name="AdjustTaxSoapOut">
865
+ <wsdl:part name="parameters" element="tns:AdjustTaxResponse" />
866
+ </wsdl:message>
867
+ <wsdl:message name="AdjustTaxProfile">
868
+ <wsdl:part name="Profile" element="tns:Profile" />
869
+ </wsdl:message>
870
+ <wsdl:message name="ApplyPaymentSoapIn">
871
+ <wsdl:part name="parameters" element="tns:ApplyPayment" />
872
+ </wsdl:message>
873
+ <wsdl:message name="ApplyPaymentSoapOut">
874
+ <wsdl:part name="parameters" element="tns:ApplyPaymentResponse" />
875
+ </wsdl:message>
876
+ <wsdl:message name="ApplyPaymentAuditMessage">
877
+ <wsdl:part name="AuditMessage" element="tns:AuditMessage" />
878
+ </wsdl:message>
879
+ <wsdl:message name="ApplyPaymentProfile">
880
+ <wsdl:part name="Profile" element="tns:Profile" />
881
+ </wsdl:message>
882
+ <!--New Methods-->
883
+ <wsdl:message name="SubmitBatchSoapIn">
884
+ <wsdl:part name="parameters" element="tns:SubmitBatch" />
885
+ </wsdl:message>
886
+ <wsdl:message name="SubmitBatchSoapOut">
887
+ <wsdl:part name="parameters" element="tns:SubmitBatchResponse" />
888
+ </wsdl:message>
889
+ <wsdl:message name="SubmitBatchProfile">
890
+ <wsdl:part name="Profile" element="tns:Profile" />
891
+ </wsdl:message>
892
+ <wsdl:message name="GetBatchSoapIn">
893
+ <wsdl:part name="parameters" element="tns:GetBatch" />
894
+ </wsdl:message>
895
+ <wsdl:message name="GetBatchSoapOut">
896
+ <wsdl:part name="parameters" element="tns:GetBatchResponse" />
897
+ </wsdl:message>
898
+ <wsdl:message name="GetBatchProfile">
899
+ <wsdl:part name="Profile" element="tns:Profile" />
900
+ </wsdl:message>
901
+ <wsdl:message name="CancelBatchSoapIn">
902
+ <wsdl:part name="parameters" element="tns:CancelBatch" />
903
+ </wsdl:message>
904
+ <wsdl:message name="CancelBatchSoapOut">
905
+ <wsdl:part name="parameters" element="tns:CancelBatchResponse" />
906
+ </wsdl:message>
907
+ <wsdl:message name="CancelBatchProfile">
908
+ <wsdl:part name="Profile" element="tns:Profile" />
909
+ </wsdl:message>
910
+ <!--New Methods-->
911
+ <wsdl:message name="PingSoapIn">
912
+ <wsdl:part name="parameters" element="tns:Ping" />
913
+ </wsdl:message>
914
+ <wsdl:message name="PingSoapOut">
915
+ <wsdl:part name="parameters" element="tns:PingResponse" />
916
+ </wsdl:message>
917
+ <wsdl:message name="PingProfile">
918
+ <wsdl:part name="Profile" element="tns:Profile" />
919
+ </wsdl:message>
920
+ <wsdl:message name="IsAuthorizedSoapIn">
921
+ <wsdl:part name="parameters" element="tns:IsAuthorized" />
922
+ </wsdl:message>
923
+ <wsdl:message name="IsAuthorizedSoapOut">
924
+ <wsdl:part name="parameters" element="tns:IsAuthorizedResponse" />
925
+ </wsdl:message>
926
+ <wsdl:message name="IsAuthorizedProfile">
927
+ <wsdl:part name="Profile" element="tns:Profile" />
928
+ </wsdl:message>
929
+ <wsdl:portType name="TaxSvcSoap">
930
+ <wsdl:operation name="GetTax">
931
+ <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Calculates taxes on a document</wsdl:documentation>
932
+ <wsdl:input message="tns:GetTaxSoapIn" />
933
+ <wsdl:output message="tns:GetTaxSoapOut" />
934
+ </wsdl:operation>
935
+ <wsdl:operation name="GetTaxHistory">
936
+ <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Retrieves a previously calculated tax document</wsdl:documentation>
937
+ <wsdl:input message="tns:GetTaxHistorySoapIn" />
938
+ <wsdl:output message="tns:GetTaxHistorySoapOut" />
939
+ </wsdl:operation>
940
+ <wsdl:operation name="PostTax">
941
+ <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Posts a previously calculated tax</wsdl:documentation>
942
+ <wsdl:input message="tns:PostTaxSoapIn" />
943
+ <wsdl:output message="tns:PostTaxSoapOut" />
944
+ </wsdl:operation>
945
+ <wsdl:operation name="CommitTax">
946
+ <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Commits a previously posted tax</wsdl:documentation>
947
+ <wsdl:input message="tns:CommitTaxSoapIn" />
948
+ <wsdl:output message="tns:CommitTaxSoapOut" />
949
+ </wsdl:operation>
950
+ <wsdl:operation name="CancelTax">
951
+ <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Cancels a previously calculated tax. This is for use as a compensating action when posting on the client fails to complete.</wsdl:documentation>
952
+ <wsdl:input message="tns:CancelTaxSoapIn" />
953
+ <wsdl:output message="tns:CancelTaxSoapOut" />
954
+ </wsdl:operation>
955
+ <wsdl:operation name="ReconcileTaxHistory">
956
+ <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Reconciles tax history to ensure the client data matches the AvaTax history.</wsdl:documentation>
957
+ <wsdl:input message="tns:ReconcileTaxHistorySoapIn" />
958
+ <wsdl:output message="tns:ReconcileTaxHistorySoapOut" />
959
+ </wsdl:operation>
960
+ <wsdl:operation name="AdjustTax">
961
+ <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Adjusts taxes on an existing invoice</wsdl:documentation>
962
+ <wsdl:input message="tns:AdjustTaxSoapIn" />
963
+ <wsdl:output message="tns:AdjustTaxSoapOut" />
964
+ </wsdl:operation>
965
+ <wsdl:operation name="ApplyPayment">
966
+ <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Applies a payment date to an existing invoice</wsdl:documentation>
967
+ <wsdl:input message="tns:ApplyPaymentSoapIn" />
968
+ <wsdl:output message="tns:ApplyPaymentSoapOut" />
969
+ </wsdl:operation>
970
+ <wsdl:operation name="SubmitBatch">
971
+ <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Submits a batch of TaxSvc requests to be processed.</wsdl:documentation>
972
+ <wsdl:input message="tns:SubmitBatchSoapIn" />
973
+ <wsdl:output message="tns:SubmitBatchSoapOut" />
974
+ </wsdl:operation>
975
+ <wsdl:operation name="GetBatch">
976
+ <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Gets the status and results of a submitted batch.</wsdl:documentation>
977
+ <wsdl:input message="tns:GetBatchSoapIn" />
978
+ <wsdl:output message="tns:GetBatchSoapOut" />
979
+ </wsdl:operation>
980
+ <wsdl:operation name="CancelBatch">
981
+ <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Cancels an incomplete batch operation.</wsdl:documentation>
982
+ <wsdl:input message="tns:CancelBatchSoapIn" />
983
+ <wsdl:output message="tns:CancelBatchSoapOut" />
984
+ </wsdl:operation>
985
+ <wsdl:operation name="Ping">
986
+ <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Tests connectivity and version of the service</wsdl:documentation>
987
+ <wsdl:input message="tns:PingSoapIn" />
988
+ <wsdl:output message="tns:PingSoapOut" />
989
+ </wsdl:operation>
990
+ <wsdl:operation name="IsAuthorized">
991
+ <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">Checks authentication and authorization to one or more operations on the service.</wsdl:documentation>
992
+ <wsdl:input message="tns:IsAuthorizedSoapIn" />
993
+ <wsdl:output message="tns:IsAuthorizedSoapOut" />
994
+ </wsdl:operation>
995
+ </wsdl:portType>
996
+ <wsdl:binding name="TaxSvcSoap" type="tns:TaxSvcSoap">
997
+ <soap:binding transport="http://schemas.xmlsoap.org/soap/http" />
998
+ <wsdl:operation name="GetTax">
999
+ <soap:operation soapAction="http://avatax.avalara.com/services/GetTax" style="document" />
1000
+ <wsdl:input>
1001
+ <soap:body use="literal" />
1002
+ <soap:header message="tns:GetTaxProfile" part="Profile" use="literal" />
1003
+ </wsdl:input>
1004
+ <wsdl:output>
1005
+ <soap:body use="literal" />
1006
+ </wsdl:output>
1007
+ </wsdl:operation>
1008
+ <wsdl:operation name="GetTaxHistory">
1009
+ <soap:operation soapAction="http://avatax.avalara.com/services/GetTaxHistory" style="document" />
1010
+ <wsdl:input>
1011
+ <soap:body use="literal" />
1012
+ <soap:header message="tns:GetTaxHistoryProfile" part="Profile" use="literal" />
1013
+ </wsdl:input>
1014
+ <wsdl:output>
1015
+ <soap:body use="literal" />
1016
+ </wsdl:output>
1017
+ </wsdl:operation>
1018
+ <wsdl:operation name="PostTax">
1019
+ <soap:operation soapAction="http://avatax.avalara.com/services/PostTax" style="document" />
1020
+ <wsdl:input>
1021
+ <soap:body use="literal" />
1022
+ <soap:header message="tns:PostTaxProfile" part="Profile" use="literal" />
1023
+ </wsdl:input>
1024
+ <wsdl:output>
1025
+ <soap:body use="literal" />
1026
+ </wsdl:output>
1027
+ </wsdl:operation>
1028
+ <wsdl:operation name="CommitTax">
1029
+ <soap:operation soapAction="http://avatax.avalara.com/services/CommitTax" style="document" />
1030
+ <wsdl:input>
1031
+ <soap:body use="literal" />
1032
+ <soap:header message="tns:CommitTaxAuditMessage" part="AuditMessage" use="literal" />
1033
+ <soap:header message="tns:CommitTaxProfile" part="Profile" use="literal" />
1034
+ </wsdl:input>
1035
+ <wsdl:output>
1036
+ <soap:body use="literal" />
1037
+ </wsdl:output>
1038
+ </wsdl:operation>
1039
+ <wsdl:operation name="CancelTax">
1040
+ <soap:operation soapAction="http://avatax.avalara.com/services/CancelTax" style="document" />
1041
+ <wsdl:input>
1042
+ <soap:body use="literal" />
1043
+ <soap:header message="tns:CancelTaxAuditMessage" part="AuditMessage" use="literal" />
1044
+ <soap:header message="tns:CancelTaxProfile" part="Profile" use="literal" />
1045
+ </wsdl:input>
1046
+ <wsdl:output>
1047
+ <soap:body use="literal" />
1048
+ </wsdl:output>
1049
+ </wsdl:operation>
1050
+ <wsdl:operation name="ReconcileTaxHistory">
1051
+ <soap:operation soapAction="http://avatax.avalara.com/services/ReconcileTaxHistory" style="document" />
1052
+ <wsdl:input>
1053
+ <soap:body use="literal" />
1054
+ <soap:header message="tns:ReconcileTaxHistoryProfile" part="Profile" use="literal" />
1055
+ </wsdl:input>
1056
+ <wsdl:output>
1057
+ <soap:body use="literal" />
1058
+ </wsdl:output>
1059
+ </wsdl:operation>
1060
+ <wsdl:operation name="AdjustTax">
1061
+ <soap:operation soapAction="http://avatax.avalara.com/services/AdjustTax" style="document" />
1062
+ <wsdl:input>
1063
+ <soap:body use="literal" />
1064
+ <soap:header message="tns:AdjustTaxProfile" part="Profile" use="literal" />
1065
+ </wsdl:input>
1066
+ <wsdl:output>
1067
+ <soap:body use="literal" />
1068
+ </wsdl:output>
1069
+ </wsdl:operation>
1070
+ <wsdl:operation name="ApplyPayment">
1071
+ <soap:operation soapAction="http://avatax.avalara.com/services/ApplyPayment" style="document" />
1072
+ <wsdl:input>
1073
+ <soap:body use="literal" />
1074
+ <soap:header message="tns:ApplyPaymentAuditMessage" part="AuditMessage" use="literal" />
1075
+ <soap:header message="tns:ApplyPaymentProfile" part="Profile" use="literal" />
1076
+ </wsdl:input>
1077
+ <wsdl:output>
1078
+ <soap:body use="literal" />
1079
+ </wsdl:output>
1080
+ </wsdl:operation>
1081
+ <!--New Methods Begin-->
1082
+ <wsdl:operation name="SubmitBatch">
1083
+ <soap:operation soapAction="http://avatax.avalara.com/services/SubmitBatch" style="document" />
1084
+ <wsdl:input>
1085
+ <soap:body use="literal" />
1086
+ <soap:header message="tns:SubmitBatchProfile" part="Profile" use="literal" />
1087
+ </wsdl:input>
1088
+ <wsdl:output>
1089
+ <soap:body use="literal" />
1090
+ </wsdl:output>
1091
+ </wsdl:operation>
1092
+ <wsdl:operation name="GetBatch">
1093
+ <soap:operation soapAction="http://avatax.avalara.com/services/GetBatch" style="document" />
1094
+ <wsdl:input>
1095
+ <soap:body use="literal" />
1096
+ <soap:header message="tns:GetBatchProfile" part="Profile" use="literal" />
1097
+ </wsdl:input>
1098
+ <wsdl:output>
1099
+ <soap:body use="literal" />
1100
+ </wsdl:output>
1101
+ </wsdl:operation>
1102
+ <wsdl:operation name="CancelBatch">
1103
+ <soap:operation soapAction="http://avatax.avalara.com/services/CancelBatch" style="document" />
1104
+ <wsdl:input>
1105
+ <soap:body use="literal" />
1106
+ <soap:header message="tns:CancelBatchProfile" part="Profile" use="literal" />
1107
+ </wsdl:input>
1108
+ <wsdl:output>
1109
+ <soap:body use="literal" />
1110
+ </wsdl:output>
1111
+ </wsdl:operation>
1112
+ <!--New Methods End-->
1113
+ <wsdl:operation name="Ping">
1114
+ <soap:operation soapAction="http://avatax.avalara.com/services/Ping" style="document" />
1115
+ <wsdl:input>
1116
+ <soap:body use="literal" />
1117
+ <soap:header message="tns:PingProfile" part="Profile" use="literal" />
1118
+ </wsdl:input>
1119
+ <wsdl:output>
1120
+ <soap:body use="literal" />
1121
+ </wsdl:output>
1122
+ </wsdl:operation>
1123
+ <wsdl:operation name="IsAuthorized">
1124
+ <soap:operation soapAction="http://avatax.avalara.com/services/IsAuthorized" style="document" />
1125
+ <wsdl:input>
1126
+ <soap:body use="literal" />
1127
+ <soap:header message="tns:IsAuthorizedProfile" part="Profile" use="literal" />
1128
+ </wsdl:input>
1129
+ <wsdl:output>
1130
+ <soap:body use="literal" />
1131
+ </wsdl:output>
1132
+ </wsdl:operation>
1133
+ </wsdl:binding>
1134
+ <wsdl:binding name="TaxSvcSoap12" type="tns:TaxSvcSoap">
1135
+ <soap12:binding transport="http://schemas.xmlsoap.org/soap/http" />
1136
+ <wsdl:operation name="GetTax">
1137
+ <soap12:operation soapAction="http://avatax.avalara.com/services/GetTax" style="document" />
1138
+ <wsdl:input>
1139
+ <soap12:body use="literal" />
1140
+ <soap12:header message="tns:GetTaxProfile" part="Profile" use="literal" />
1141
+ </wsdl:input>
1142
+ <wsdl:output>
1143
+ <soap12:body use="literal" />
1144
+ </wsdl:output>
1145
+ </wsdl:operation>
1146
+ <wsdl:operation name="GetTaxHistory">
1147
+ <soap12:operation soapAction="http://avatax.avalara.com/services/GetTaxHistory" style="document" />
1148
+ <wsdl:input>
1149
+ <soap12:body use="literal" />
1150
+ <soap12:header message="tns:GetTaxHistoryProfile" part="Profile" use="literal" />
1151
+ </wsdl:input>
1152
+ <wsdl:output>
1153
+ <soap12:body use="literal" />
1154
+ </wsdl:output>
1155
+ </wsdl:operation>
1156
+ <wsdl:operation name="PostTax">
1157
+ <soap12:operation soapAction="http://avatax.avalara.com/services/PostTax" style="document" />
1158
+ <wsdl:input>
1159
+ <soap12:body use="literal" />
1160
+ <soap12:header message="tns:PostTaxProfile" part="Profile" use="literal" />
1161
+ </wsdl:input>
1162
+ <wsdl:output>
1163
+ <soap12:body use="literal" />
1164
+ </wsdl:output>
1165
+ </wsdl:operation>
1166
+ <wsdl:operation name="CommitTax">
1167
+ <soap12:operation soapAction="http://avatax.avalara.com/services/CommitTax" style="document" />
1168
+ <wsdl:input>
1169
+ <soap12:body use="literal" />
1170
+ <soap12:header message="tns:CommitTaxAuditMessage" part="AuditMessage" use="literal" />
1171
+ <soap12:header message="tns:CommitTaxProfile" part="Profile" use="literal" />
1172
+ </wsdl:input>
1173
+ <wsdl:output>
1174
+ <soap12:body use="literal" />
1175
+ </wsdl:output>
1176
+ </wsdl:operation>
1177
+ <wsdl:operation name="CancelTax">
1178
+ <soap12:operation soapAction="http://avatax.avalara.com/services/CancelTax" style="document" />
1179
+ <wsdl:input>
1180
+ <soap12:body use="literal" />
1181
+ <soap12:header message="tns:CancelTaxAuditMessage" part="AuditMessage" use="literal" />
1182
+ <soap12:header message="tns:CancelTaxProfile" part="Profile" use="literal" />
1183
+ </wsdl:input>
1184
+ <wsdl:output>
1185
+ <soap12:body use="literal" />
1186
+ </wsdl:output>
1187
+ </wsdl:operation>
1188
+ <wsdl:operation name="ReconcileTaxHistory">
1189
+ <soap12:operation soapAction="http://avatax.avalara.com/services/ReconcileTaxHistory" style="document" />
1190
+ <wsdl:input>
1191
+ <soap12:body use="literal" />
1192
+ <soap12:header message="tns:ReconcileTaxHistoryProfile" part="Profile" use="literal" />
1193
+ </wsdl:input>
1194
+ <wsdl:output>
1195
+ <soap12:body use="literal" />
1196
+ </wsdl:output>
1197
+ </wsdl:operation>
1198
+ <wsdl:operation name="AdjustTax">
1199
+ <soap12:operation soapAction="http://avatax.avalara.com/services/AdjustTax" style="document" />
1200
+ <wsdl:input>
1201
+ <soap12:body use="literal" />
1202
+ <soap12:header message="tns:AdjustTaxProfile" part="Profile" use="literal" />
1203
+ </wsdl:input>
1204
+ <wsdl:output>
1205
+ <soap12:body use="literal" />
1206
+ </wsdl:output>
1207
+ </wsdl:operation>
1208
+ <wsdl:operation name="ApplyPayment">
1209
+ <soap12:operation soapAction="http://avatax.avalara.com/services/ApplyPayment" style="document" />
1210
+ <wsdl:input>
1211
+ <soap12:body use="literal" />
1212
+ <soap12:header message="tns:ApplyPaymentAuditMessage" part="AuditMessage" use="literal" />
1213
+ <soap12:header message="tns:ApplyPaymentProfile" part="Profile" use="literal" />
1214
+ </wsdl:input>
1215
+ <wsdl:output>
1216
+ <soap12:body use="literal" />
1217
+ </wsdl:output>
1218
+ </wsdl:operation>
1219
+ <wsdl:operation name="Ping">
1220
+ <soap12:operation soapAction="http://avatax.avalara.com/services/Ping" style="document" />
1221
+ <wsdl:input>
1222
+ <soap12:body use="literal" />
1223
+ <soap12:header message="tns:PingProfile" part="Profile" use="literal" />
1224
+ </wsdl:input>
1225
+ <wsdl:output>
1226
+ <soap12:body use="literal" />
1227
+ </wsdl:output>
1228
+ </wsdl:operation>
1229
+ <wsdl:operation name="IsAuthorized">
1230
+ <soap12:operation soapAction="http://avatax.avalara.com/services/IsAuthorized" style="document" />
1231
+ <wsdl:input>
1232
+ <soap12:body use="literal" />
1233
+ <soap12:header message="tns:IsAuthorizedProfile" part="Profile" use="literal" />
1234
+ </wsdl:input>
1235
+ <wsdl:output>
1236
+ <soap12:body use="literal" />
1237
+ </wsdl:output>
1238
+ </wsdl:operation>
1239
+ <!--New Methods Begin-->
1240
+ <wsdl:operation name="SubmitBatch">
1241
+ <soap12:operation soapAction="http://avatax.avalara.com/services/SubmitBatch" style="document" />
1242
+ <wsdl:input>
1243
+ <soap12:body use="literal" />
1244
+ <soap12:header message="tns:SubmitBatchProfile" part="Profile" use="literal" />
1245
+ </wsdl:input>
1246
+ <wsdl:output>
1247
+ <soap12:body use="literal" />
1248
+ </wsdl:output>
1249
+ </wsdl:operation>
1250
+ <wsdl:operation name="GetBatch">
1251
+ <soap12:operation soapAction="http://avatax.avalara.com/services/GetBatch" style="document" />
1252
+ <wsdl:input>
1253
+ <soap12:body use="literal" />
1254
+ <soap12:header message="tns:GetBatchProfile" part="Profile" use="literal" />
1255
+ </wsdl:input>
1256
+ <wsdl:output>
1257
+ <soap12:body use="literal" />
1258
+ </wsdl:output>
1259
+ </wsdl:operation>
1260
+ <wsdl:operation name="CancelBatch">
1261
+ <soap12:operation soapAction="http://avatax.avalara.com/services/CancelBatch" style="document" />
1262
+ <wsdl:input>
1263
+ <soap12:body use="literal" />
1264
+ <soap12:header message="tns:CancelBatchProfile" part="Profile" use="literal" />
1265
+ </wsdl:input>
1266
+ <wsdl:output>
1267
+ <soap12:body use="literal" />
1268
+ </wsdl:output>
1269
+ </wsdl:operation>
1270
+ <!--New Methods End-->
1271
+ </wsdl:binding>
1272
+ <wsdl:service name="TaxSvc">
1273
+ <wsdl:port name="TaxSvcSoap" binding="tns:TaxSvcSoap">
1274
+ <soap:address location="http://localhost/avatax.services/Tax/TaxSvc.asmx" />
1275
+ </wsdl:port>
1276
+ <wsdl:port name="TaxSvcSoap12" binding="tns:TaxSvcSoap12">
1277
+ <soap12:address location="http://localhost/avatax.services/Tax/TaxSvc.asmx" />
1278
+ </wsdl:port>
1279
+ </wsdl:service>
1280
  </wsdl:definitions>
{app/code/community/OnePica/AvaTax/lib → lib/AvaTax}/functions.php RENAMED
@@ -1,74 +1,74 @@
1
- <?php
2
- /**
3
- * OnePica_AvaTax
4
- *
5
- * NOTICE OF LICENSE
6
- *
7
- * This source file is subject to the Open Software License (OSL 3.0), a
8
- * copy of which is available through the world-wide-web at this URL:
9
- * http://opensource.org/licenses/osl-3.0.php
10
- *
11
- * @category OnePica
12
- * @package OnePica_AvaTax
13
- * @author OnePica Codemaster <codemaster@onepica.com>
14
- * @copyright Copyright (c) 2009 One Pica, Inc.
15
- * @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
16
- */
17
-
18
- /**
19
- * The functions below are copied from AvaTax.php. That file cannot be included because
20
- * it defines the function __autoload(), which Magento already uses.
21
- */
22
-
23
- function EnsureIsArray( $obj )
24
- {
25
- if( is_object($obj))
26
- {
27
- $item[0] = $obj;
28
- }
29
- else
30
- {
31
- $item = (array)$obj;
32
- }
33
- return $item;
34
- }
35
-
36
- /**
37
- * Takes xml as a string and returns it nicely indented
38
- *
39
- * @param string $xml The xml to beautify
40
- * @param boolean $html_output If the xml should be formatted for display on an html page
41
- * @return string The beautified xml
42
- */
43
- function xml_pretty_printer($xml, $html_output=FALSE)
44
- {
45
- $xml_obj = new SimpleXMLElement($xml);
46
- $xml_lines = explode("n", $xml_obj->asXML());
47
- $indent_level = 0;
48
-
49
- $new_xml_lines = array();
50
- foreach ($xml_lines as $xml_line) {
51
- if (preg_match('#(<[a-z0-9:-]+((s+[a-z0-9:-]+="[^"]+")*)?>.*<s*/s*[^>]+>)|(<[a-z0-9:-]+((s+[a-z0-9:-]+="[^"]+")*)?s*/s*>)#i', $xml_line)) {
52
- $new_line = str_pad('', $indent_level*4) . $xml_line;
53
- $new_xml_lines[] = $new_line;
54
- } elseif (preg_match('#<[a-z0-9:-]+((s+[a-z0-9:-]+="[^"]+")*)?>#i', $xml_line)) {
55
- $new_line = str_pad('', $indent_level*4) . $xml_line;
56
- $indent_level++;
57
- $new_xml_lines[] = $new_line;
58
- } elseif (preg_match('#<s*/s*[^>/]+>#i', $xml_line)) {
59
- $indent_level--;
60
- if (trim($new_xml_lines[sizeof($new_xml_lines)-1]) == trim(str_replace("/", "", $xml_line))) {
61
- $new_xml_lines[sizeof($new_xml_lines)-1] .= $xml_line;
62
- } else {
63
- $new_line = str_pad('', $indent_level*4) . $xml_line;
64
- $new_xml_lines[] = $new_line;
65
- }
66
- } else {
67
- $new_line = str_pad('', $indent_level*4) . $xml_line;
68
- $new_xml_lines[] = $new_line;
69
- }
70
- }
71
-
72
- $xml = join("n", $new_xml_lines);
73
- return ($html_output) ? '<pre>' . htmlentities($xml) . '</pre>' : $xml;
74
- }
1
+ <?php
2
+ /**
3
+ * OnePica_AvaTax
4
+ *
5
+ * NOTICE OF LICENSE
6
+ *
7
+ * This source file is subject to the Open Software License (OSL 3.0), a
8
+ * copy of which is available through the world-wide-web at this URL:
9
+ * http://opensource.org/licenses/osl-3.0.php
10
+ *
11
+ * @category OnePica
12
+ * @package OnePica_AvaTax
13
+ * @author OnePica Codemaster <codemaster@onepica.com>
14
+ * @copyright Copyright (c) 2009 One Pica, Inc.
15
+ * @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
16
+ */
17
+
18
+ /**
19
+ * The functions below are copied from AvaTax.php. That file cannot be included because
20
+ * it defines the function __autoload(), which Magento already uses.
21
+ */
22
+
23
+ function EnsureIsArray( $obj )
24
+ {
25
+ if( is_object($obj))
26
+ {
27
+ $item[0] = $obj;
28
+ }
29
+ else
30
+ {
31
+ $item = (array)$obj;
32
+ }
33
+ return $item;
34
+ }
35
+
36
+ /**
37
+ * Takes xml as a string and returns it nicely indented
38
+ *
39
+ * @param string $xml The xml to beautify
40
+ * @param boolean $html_output If the xml should be formatted for display on an html page
41
+ * @return string The beautified xml
42
+ */
43
+ function xml_pretty_printer($xml, $html_output=FALSE)
44
+ {
45
+ $xml_obj = new SimpleXMLElement($xml);
46
+ $xml_lines = explode("n", $xml_obj->asXML());
47
+ $indent_level = 0;
48
+
49
+ $new_xml_lines = array();
50
+ foreach ($xml_lines as $xml_line) {
51
+ if (preg_match('#(<[a-z0-9:-]+((s+[a-z0-9:-]+="[^"]+")*)?>.*<s*/s*[^>]+>)|(<[a-z0-9:-]+((s+[a-z0-9:-]+="[^"]+")*)?s*/s*>)#i', $xml_line)) {
52
+ $new_line = str_pad('', $indent_level*4) . $xml_line;
53
+ $new_xml_lines[] = $new_line;
54
+ } elseif (preg_match('#<[a-z0-9:-]+((s+[a-z0-9:-]+="[^"]+")*)?>#i', $xml_line)) {
55
+ $new_line = str_pad('', $indent_level*4) . $xml_line;
56
+ $indent_level++;
57
+ $new_xml_lines[] = $new_line;
58
+ } elseif (preg_match('#<s*/s*[^>/]+>#i', $xml_line)) {
59
+ $indent_level--;
60
+ if (trim($new_xml_lines[sizeof($new_xml_lines)-1]) == trim(str_replace("/", "", $xml_line))) {
61
+ $new_xml_lines[sizeof($new_xml_lines)-1] .= $xml_line;
62
+ } else {
63
+ $new_line = str_pad('', $indent_level*4) . $xml_line;
64
+ $new_xml_lines[] = $new_line;
65
+ }
66
+ } else {
67
+ $new_line = str_pad('', $indent_level*4) . $xml_line;
68
+ $new_xml_lines[] = $new_line;
69
+ }
70
+ }
71
+
72
+ $xml = join("n", $new_xml_lines);
73
+ return ($html_output) ? '<pre>' . htmlentities($xml) . '</pre>' : $xml;
74
+ }
package.xml CHANGED
@@ -1,7 +1,7 @@
1
  <?xml version="1.0"?>
2
  <package>
3
  <name>OnePica_AvaTax</name>
4
- <version>2.5.0</version>
5
  <stability>stable</stability>
6
  <license>Open Software License (OSL 3.0)</license>
7
  <channel>community</channel>
@@ -18,27 +18,11 @@ Released as a commercial extension, this software will not work unless you have
18
  &#xD;
19
  &#xD;
20
  At One Pica (www.onepica.com), we strive to build increasingly scalable and flexible enterprise systems for all of our clients, large and small. We want to give back to this community both to promote its success and as a sign of our gratitude. Please feel free to contact us on ways we can improve this extension or extend on this framework.</description>
21
- <notes>Improved performance&#xD;
22
- &#xD;
23
- Improved logging&#xD;
24
- &#xD;
25
- Fixed tax calculation for configurable products&#xD;
26
- &#xD;
27
- Fixed tax calculation when coupon is applied&#xD;
28
- &#xD;
29
- Fixed tax calculation with gift wrapping&#xD;
30
- &#xD;
31
- Fixed filter tax calculation option&#xD;
32
- &#xD;
33
- Fixed queue clean up process&#xD;
34
- &#xD;
35
- &#xD;
36
- &#xD;
37
- </notes>
38
  <authors><author><name>Rostyslav Redko</name><user>marketing</user><email>avalara@onepica.com</email></author></authors>
39
- <date>2015-07-09</date>
40
- <time>16:26:17</time>
41
- <contents><target name="magecommunity"><dir name="OnePica"><dir name="AvaTax"><dir name="Block"><dir name="Adminhtml"><dir name="Export"><dir name="Abstract"><file name="Grid.php" hash="85f9e21148f0bcb16d2bba85379b620c"/></dir><dir name="Log"><file name="Grid.php" hash="9fc68393de0fc3ebdbcd943e39a59a9d"/><file name="View.php" hash="b04fc9f60d4acbb07051f7391b878a92"/></dir><dir name="Queue"><file name="Grid.php" hash="5f32911ee544353d05b093a20c6fac4c"/></dir></dir><dir name="Notification"><file name="Toolbar.php" hash="ce0f6022846b565184147dc50d1792b8"/></dir><dir name="System"><dir name="Config"><dir name="Form"><dir name="Field"><file name="Export.php" hash="9a34cc10bf2e179725517be980d8ef17"/></dir></dir></dir></dir><dir name="Tax"><dir name="Class"><dir name="Edit"><file name="Form.php" hash="80d7048a100539d0957cc2d1e433d3fa"/></dir><file name="Grid.php" hash="130503c2d1b2e2efe84c0a658aa0f7a8"/></dir></dir></dir><dir name="Checkout"><dir name="Onepage"><dir name="Shipping"><dir name="Method"><file name="Available.php" hash="c8ad904b71f344cfd1e01ceea7556dd1"/></dir></dir></dir></dir></dir><dir name="Helper"><file name="Data.php" hash="3e629ac46ddeefeac5370bcdd6af2476"/><dir name="Tax"><file name="Data.php" hash="2d267503f130a97db1786ea403564016"/></dir></dir><dir name="Model"><file name="Abstract.php" hash="dffa336069582428f490b85567dddb69"/><dir name="Admin"><file name="Session.php" hash="90dd2d8b332f813515889a454ee3c80b"/></dir><dir name="Adminhtml"><file name="Config.php" hash="b0232a66e3deb89a51c870ec9cc815ee"/><dir name="Sales"><dir name="Order"><file name="Create.php" hash="a83d3ac1d0dec5cd70d473dbfba7fc85"/></dir></dir></dir><dir name="Avatax"><file name="Abstract.php" hash="ad54fec335b71a6acc3887a68b347dc7"/><file name="Address.php" hash="365f7ac72aea4296cc5bfdee867a0f08"/><file name="Estimate.php" hash="76da48316e897fe0bdafa5dcc6c00237"/><dir name="Exception"><file name="Address.php" hash="689d9b351489c9101477b8f068bc48cd"/><file name="Commitfailure.php" hash="68e9c96eefed652e54a807bca1019f54"/><file name="Unbalanced.php" hash="778eb77593cb4787d6a00a5da0559ddc"/></dir><file name="Invoice.php" hash="0133aa19a1f4a4aea9d81a7f68d5d9bf"/><file name="Ping.php" hash="57b77948291fda5c6fe15733fd96a3c0"/></dir><file name="Config.php" hash="b4c80dbcd4d476f42f36d2a5dd666c15"/><file name="Exception.php" hash="78b46e431b3d8e1d31a3544c9a037e30"/><dir name="Export"><dir name="Adapter"><file name="Abstract.php" hash="840c8b87acd97646572bba9bb3b8f5ea"/><file name="Sql.php" hash="d4e76c823e5dd575279274debff69e4f"/></dir><dir name="Entity"><file name="Abstract.php" hash="a6e649456073395dc6f0d382e9abded8"/><file name="Log.php" hash="a1dd28eee3e72d1a4ef7bddd865ddbae"/><file name="Queue.php" hash="14a97c283aa74f97982ab71160017aa3"/></dir></dir><file name="Export.php" hash="479265899b15f58c1659c61f31c7470a"/><file name="Observer.php" hash="90932cf4977b4fed97e86746d8850ba7"/><dir name="Records"><file name="Log.php" hash="a15c22cf219e7750a37cde75ba3f22a9"/><dir name="Mysql4"><dir name="Log"><file name="Collection.php" hash="29db8163f4dda862ff822ddffd04554d"/></dir><file name="Log.php" hash="f9c213eef54837c95ebef0bb9403d610"/><dir name="Queue"><file name="Collection.php" hash="11bba1561c81f39695f091b94bd81560"/></dir><file name="Queue.php" hash="735132bae49948300cac00658a68cf74"/></dir><dir name="Queue"><file name="Process.php" hash="dda2ef9fa0571db1cb16292b7b93db54"/></dir><file name="Queue.php" hash="17e369325bcac42042676bb61a2248c5"/></dir><dir name="Sales"><dir name="Quote"><dir name="Address"><dir name="Total"><file name="Grand.php" hash="63fb5a808ad3c16d2ed15f1dafad7937"/><file name="Tax.php" hash="e309b0c41e91e714268c02a79d5e8e5f"/></dir></dir><file name="Address.php" hash="3191bbdf4e2227d35cf588dde798731b"/></dir></dir><file name="Session.php" hash="6a858f6395d248178c28160a29530bf1"/><dir name="Source"><file name="Actions.php" hash="879b80f92f735402f57e316546b16984"/><file name="Addressvalidation.php" hash="9f2315018910f7336ad894156d49d9b9"/><file name="Customercodeformat.php" hash="cfcfcbaa27ed29add072324816da0c9d"/><file name="Error.php" hash="7f5495a2f295ded2d0a30f2f7108d009"/><file name="Fieldlist.php" hash="b25835b23df6045777be1c891bd3dd05"/><file name="Logmode.php" hash="24d61da578a3b4adb896fea7d4d4d8ec"/><file name="Logtype.php" hash="4079ebbf7ef44593e631b8cc9f0fc2a5"/><file name="Onerrorfrontend.php" hash="ef4154ae563d8157c1083f20e0adf563"/><dir name="Regionfilter"><file name="List.php" hash="169d0a776823439984fbdf27e631f62e"/><file name="Mode.php" hash="27fdc94c6f162100d55005285b5170df"/></dir></dir><dir name="Tax"><file name="Config.php" hash="6168c0d674a44291b7dbfe358305a04b"/></dir></dir><dir name="controllers"><dir name="Adminhtml"><file name="ExportController.php" hash="306f2f688aaa85e4dbf2bda94bc7d353"/><file name="GridController.php" hash="91f38761378ff91d1f9c396b1cb3c150"/></dir></dir><dir name="data"><dir name="avatax_records_setup"><file name="data-upgrade-2.2.0-2.2.1.php" hash="260d1c57754ebadba00d8ccdbb0ec996"/></dir></dir><dir name="etc"><file name="adminhtml.xml" hash="92c529d045fa34fd0822b6ccb40bd4ed"/><file name="config.xml" hash="cf523de8daa4d2e4c289f3cafa30826b"/><file name="system-disabled.xml" hash="937460e7271eb45d25f424d7da2baa72"/><file name="system.xml" hash="a1aa4cb07bce94406110cc9c1628460e"/></dir><dir name="lib"><file name="AvaTax.php" hash="ee495f13f7b31af8837839f8fd571102"/><dir name="classes"><file name="ATConfig.class.php" hash="88559205ad296264e9d363e95b7a3e98"/><file name="ATObject.class.php" hash="5447af3f2e2fec7bbf66589539b09e9f"/><file name="AVObject.class.php" hash="b65c5532b01074a57a20703513148301"/><file name="Address.class.php" hash="4f027c9ddbe7449397f1fe6218738ddd"/><file name="AddressServiceSoap.class.php" hash="d61560d0b4f03b6ca2823d2250c9a55e"/><file name="AddressType.class.php" hash="f778cdd8c767edd49e69815e8bd74643"/><file name="AdjustTaxRequest.class.php" hash="868b9eaed8f91ffec23ea2a688d04775"/><file name="AdjustTaxResult.class.php" hash="af37112818b9542e75bded41243a55c8"/><file name="ApplyPaymentRequest.class.php" hash="3b3877a6dc9504b090b6f4feede52b9f"/><file name="ApplyPaymentResult.class.php" hash="a38a544cff1698c59e0da9cd059b8c79"/><file name="AvalaraSoapClient.class.php" hash="1b3209110dbdc4293fbdbc6490ba7fc2"/><file name="BaseResult.class.php" hash="8b85d243d1ad85b6336de60aea38e529"/><dir name="BatchSvc"><file name="AuditMessage.class.php" hash="f3366c62f07ae94366744a18f573a2f1"/><file name="AvaTaxBatchSvc.php" hash="d6d59c824afb9357289e28f5b9ad051e"/><file name="BaseResult.class.php" hash="3d4fb18a13cb2521bdcebbb4828499a5"/><file name="Batch.class.php" hash="345e1566373ff0114fab9faba63b3bb9"/><file name="BatchDelete.class.php" hash="f6c87e688ea9a74b271af1416a5c2d3e"/><file name="BatchDeleteResponse.class.php" hash="281a7f9f48212f37f4a8dd59a8cbef05"/><file name="BatchFetch.class.php" hash="f1bd03669588ce597fb8c9e2ddf1a0c3"/><file name="BatchFetchResponse.class.php" hash="3c348fe3bd7447d1de2b3a7079ef1cb2"/><file name="BatchFetchResult.class.php" hash="8834954a075a890f5408c0fa3f68f359"/><file name="BatchFile.class.php" hash="6c2832889ecfd643bbddd8da92806d17"/><file name="BatchFileDelete.class.php" hash="d026a2536b7062ae435450b53fe81472"/><file name="BatchFileDeleteResponse.class.php" hash="87aa29c139e0f2370d3f32834a3b93d0"/><file name="BatchFileFetch.class.php" hash="8c71726d14294fb18663ba310b76e874"/><file name="BatchFileFetchResponse.class.php" hash="40c3e51f350dd6ce0a84f37e44d0d00c"/><file name="BatchFileFetchResult.class.php" hash="bcf86f8303b40b3304dc8cbf11f9a386"/><file name="BatchFileSave.class.php" hash="e06ef0079955ea1bb79c1e6385761efd"/><file name="BatchFileSaveResponse.class.php" hash="843501f0a13d018d1c48b55750f6e61f"/><file name="BatchFileSaveResult.class.php" hash="620e54c1f0c5d9a461dd9bb7a2de67ce"/><file name="BatchProcess.class.php" hash="5812c04ab18e5c65f598f9fcdfdc428a"/><file name="BatchProcessRequest.class.php" hash="c0b6c76103141b5d07bb62a37a2a7412"/><file name="BatchProcessResponse.class.php" hash="74b46fdcfd39561fed0ba85476d0aafd"/><file name="BatchProcessResult.class.php" hash="274cabe36df7e72f581fa243a2fb8b31"/><file name="BatchSave.class.php" hash="6af9af77f6d3545db34446b1cb25fffd"/><file name="BatchSaveResponse.class.php" hash="98f349e087b1caf602f5f6079a71a146"/><file name="BatchSaveResult.class.php" hash="96b2cfa552d832b75d8561312809216b"/><file name="BatchSvc.class.php" hash="8095b3bba337fe5f83ce6e2ad9ca8623"/><file name="DeleteRequest.class.php" hash="b3f449312c8c302ad919c37282a65857"/><file name="DeleteResult.class.php" hash="6101765b716fb1f3d22d95e5cff59c59"/><file name="FetchRequest.class.php" hash="51f934530a594ecc5b6602e95a90e911"/><file name="FilterRequest.class.php" hash="14fffca5fd500759a41a5072a6731d12"/><file name="FilterResult.class.php" hash="2a2a01693393144a2b9084fc036e7b2c"/><file name="IsAuthorized.class.php" hash="daf2e4fadadfcfc7c1daa5f4083ca4fa"/><file name="IsAuthorizedResponse.class.php" hash="e42a678c7b7f9a31129f87b5aeb1b694"/><file name="IsAuthorizedResult.class.php" hash="55e13f429b08d78b2be811206d4d96a9"/><file name="Message.class.php" hash="21cc40706c1b1bf550f8c84f855960d0"/><file name="Ping.class.php" hash="92358ab5f79862ff0c5e789f64cab8a0"/><file name="PingResponse.class.php" hash="ab87b30bb8204facce97bcf71b589300"/><file name="PingResult.class.php" hash="e22e864065ae905db9c8ef23b69929e7"/><file name="Profile.class.php" hash="655af918d59e879670825e89e43a1fcf"/><file name="SeverityLevel.class.php" hash="2ad4f7c3a19eff71b3459bd261182e50"/></dir><file name="BoundaryLevel.class.php" hash="602a600d04db4d74c7836ee51fafe452"/><file name="CancelCode.class.php" hash="a790b5976535a954f8d6b54e11e305df"/><file name="CancelTaxRequest.class.php" hash="27e2f1313b553ada9af5c6e2c36bbd1d"/><file name="CancelTaxResult.class.php" hash="134c8bc90db0f46a864008c15edf7206"/><file name="CommitTaxRequest.class.php" hash="0ae85335dd2e771760f5cedfeca86f34"/><file name="CommitTaxResult.class.php" hash="f9903f0b8db5a1132e409194147571aa"/><file name="DetailLevel.class.php" hash="b8bbfebb185894572a99a9acd5e53f5d"/><file name="DocStatus.class.php" hash="325c369f1db10b2039d85825a997494f"/><file name="DocumentType.class.php" hash="6ced7e430cf0019d71a83f200de6d086"/><file name="DynamicSoapClient.class.php" hash="3dd165e8cc700b2482a6b5a30568ba7e"/><file name="Enum.class.php" hash="9a131750a6c0bfcef90402721050b27d"/><file name="GetTaxHistoryRequest.class.php" hash="969209d7fc39ed4399d7a0b1fcdd1b60"/><file name="GetTaxHistoryResult.class.php" hash="83b741ace8abca31c0ab6d5c4b8b5c88"/><file name="GetTaxRequest.class.php" hash="2e4a37cb06433880803c679ff0126710"/><file name="GetTaxResult.class.php" hash="d75f0d5fe5b5d351bf92073396c2f951"/><file name="IsAuthorizedResult.class.php" hash="4eb11ff3bdf628cc4e2fc80e35d65de6"/><file name="JurisdictionType.class.php" hash="602d25befdd973b8843bad8202ecfeb7"/><file name="Line.class.php" hash="eacfe73ed6c64325036f9f82c8bca939"/><file name="Message.class.php" hash="07e308557bd2eb7552c15f91e3c85402"/><file name="PingResult.class.php" hash="e3df2dfde0f47ce50c7d95ed61b091da"/><file name="PostTaxRequest.class.php" hash="53acee39c416530b84608660d70ad013"/><file name="PostTaxResult.class.php" hash="a5c918b585ba19331ddfc731d950d9c5"/><file name="ReconcileTaxHistoryRequest.class.php" hash="c5a1d1f0bafa784f33ead69d8adb2bdf"/><file name="ReconcileTaxHistoryResult.class.php" hash="123c536c7f0706139d8f2733d387b4c2"/><file name="SearchTaxHistoryResult.class.php" hash="06175321ad401f59ad2cacd5235c29f2"/><file name="ServiceMode.class.php" hash="f42500790eb598cf28ed0e5a4151ff9c"/><file name="SeverityLevel.class.php" hash="e986ede05ca42f3bb8f1cc41614d9dfc"/><file name="TaxDetail.class.php" hash="c44906a9fd7f2b66050c07b68c9d30b4"/><file name="TaxLine.class.php" hash="481c08a933c0a4530712d405e2ea73b3"/><file name="TaxOverride.class.php" hash="911f2dd4fd707e13e1ce04026cd84b1e"/><file name="TaxOverrideType.class.php" hash="b9b1739cfac7b5523a307a19a705bbb4"/><file name="TaxRequest.class.php" hash="03ba7cc4f0ffa6b4c2fb8eef80b31219"/><file name="TaxServiceSoap.class.php" hash="5f9b9f18e43807cf54f5b0ec915255b4"/><file name="TaxType.class.php" hash="9b51208efe71386135db17fd719160a9"/><file name="TextCase.class.php" hash="9459eeef84909b2a3e7c4fc0855684c9"/><file name="ValidAddress.class.php" hash="0eb72c8763869689f434ac90d568b323"/><file name="ValidateRequest.class.php" hash="444616330d73d1e8bfe4535057a2ce59"/><file name="ValidateResult.class.php" hash="7667161c044dd77f29a0a1863bf2a5f3"/><dir name="wsdl"><file name="Address.wsdl" hash="2ca743760c961db0ae03e4c6900667cb"/><file name="BatchSvc.wsdl" hash="eae666b959c1889d586919da4ebccefd"/><file name="Tax.wsdl" hash="da6b3da89c3e4f3f7db6d0ed9d4d33de"/></dir></dir><file name="functions.php" hash="b94adf9f4887ff8f023fdaff5c64d974"/></dir><dir name="sql"><dir name="avatax_records_setup"><file name="mysql4-install-0.1.0.php" hash="4b83a0755b3d1cfa095649d6d342c9ca"/><file name="mysql4-upgrade-0.1.4-0.1.5.php" hash="75a7ad390a41c2c1f3287ebbf14ab0bd"/><file name="mysql4-upgrade-1.0.1-2.0.0.php" hash="cdd11a55f102b50cf6e522efdb30dadd"/><file name="mysql4-upgrade-2.5.0.0-2.5.0.1.php" hash="5a425755b6aa9f0296ec9aad975653dc"/></dir></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="OnePica_AvaTax.xml" hash="07fd9423811b4dc084060d6131b889d7"/></dir></target><target name="magedesign"><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="layout"><dir name="onepica"><file name="avatax.xml" hash="a2514046fa0428d24a25f82d17627843"/></dir></dir><dir name="template"><dir name="onepica"><dir name="avatax"><dir name="log"><file name="view.phtml" hash="176cc0e9b7842837be8350de143bc29f"/></dir><dir name="notification"><file name="toolbar.phtml" hash="3fe57e7f43f5995ac69b2c74744bfbd3"/></dir></dir></dir></dir></dir></dir></dir><dir name="frontend"><dir name="base"><dir name="default"><dir name="layout"><dir name="onepica"><file name="avatax.xml" hash="38c6ce2165f6ccfd6641eb1487faad39"/></dir></dir></dir></dir></dir></target><target name="magelocale"><dir name="de_DE"><file name="OnePica_AvaTax.csv" hash="43d2dee74aee6f15abd471a65b4f407c"/></dir><dir name="en_US"><file name="OnePica_AvaTax.csv" hash="43d2dee74aee6f15abd471a65b4f407c"/></dir><dir name="es_ES"><file name="OnePica_AvaTax.csv" hash="43d2dee74aee6f15abd471a65b4f407c"/></dir><dir name="fr_FR"><file name="OnePica_AvaTax.csv" hash="43d2dee74aee6f15abd471a65b4f407c"/></dir><dir name="nl_NL"><file name="OnePica_AvaTax.csv" hash="43d2dee74aee6f15abd471a65b4f407c"/></dir><dir name="pt_BR"><file name="OnePica_AvaTax.csv" hash="43d2dee74aee6f15abd471a65b4f407c"/></dir><dir name="zh_CN"><file name="OnePica_AvaTax.csv" hash="43d2dee74aee6f15abd471a65b4f407c"/></dir></target></contents>
42
  <compatible/>
43
  <dependencies><required><php><min>5.2.3</min><max>6.0.0</max></php><extension><name>Core</name><min/><max/></extension><extension><name>curl</name><min/><max/></extension><extension><name>soap</name><min/><max/></extension></required></dependencies>
44
  </package>
1
  <?xml version="1.0"?>
2
  <package>
3
  <name>OnePica_AvaTax</name>
4
+ <version>2.5.2</version>
5
  <stability>stable</stability>
6
  <license>Open Software License (OSL 3.0)</license>
7
  <channel>community</channel>
18
  &#xD;
19
  &#xD;
20
  At One Pica (www.onepica.com), we strive to build increasingly scalable and flexible enterprise systems for all of our clients, large and small. We want to give back to this community both to promote its success and as a sign of our gratitude. Please feel free to contact us on ways we can improve this extension or extend on this framework.</description>
21
+ <notes>Fixed extension installation for versions below 1.6</notes>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
22
  <authors><author><name>Rostyslav Redko</name><user>marketing</user><email>avalara@onepica.com</email></author></authors>
23
+ <date>2015-09-09</date>
24
+ <time>14:32:04</time>
25
+ <contents><target name="magecommunity"><dir name="OnePica"><dir name="AvaTax"><dir name="Block"><dir name="Adminhtml"><dir name="Export"><dir name="Abstract"><file name="Grid.php" hash="5f96ca490c5f7bd3fac23e30b00336e5"/></dir><dir name="Log"><file name="Grid.php" hash="311c55d8bc770e6d6aa6f377c2eee6fd"/><file name="View.php" hash="097d82a3e2b1a8820d335a63f212451b"/></dir><dir name="Queue"><file name="Grid.php" hash="1ef8ba9bf3e0870ea6dc50bb202a0b91"/></dir></dir><dir name="Notification"><file name="Toolbar.php" hash="a31bc4d477eaa87b45da1113c7e4b8b6"/></dir><dir name="System"><dir name="Config"><dir name="Form"><dir name="Field"><file name="Export.php" hash="9a34cc10bf2e179725517be980d8ef17"/></dir></dir></dir></dir><dir name="Tax"><dir name="Class"><dir name="Edit"><file name="Form.php" hash="0e78c592366ee2746f3891cf91a388d3"/></dir><file name="Grid.php" hash="d731eb160457b8a22cfcd28682a1c485"/></dir></dir></dir><dir name="Checkout"><dir name="Onepage"><dir name="Shipping"><dir name="Method"><file name="Available.php" hash="c8ad904b71f344cfd1e01ceea7556dd1"/></dir></dir></dir></dir></dir><file name="Exception.php" hash="fc752f8da808a402baae2425c4072d22"/><dir name="Helper"><file name="Data.php" hash="af6dd71aa87a6161da941fe09cf4eeb2"/><dir name="Tax"><file name="Data.php" hash="e041b574919704a2ddc5173d38edda91"/></dir></dir><dir name="Model"><file name="Abstract.php" hash="97f0ae95e164849371f09dbb7b1afd86"/><dir name="Admin"><file name="Session.php" hash="90dd2d8b332f813515889a454ee3c80b"/></dir><dir name="Adminhtml"><file name="Config.php" hash="b0232a66e3deb89a51c870ec9cc815ee"/><dir name="Sales"><dir name="Order"><file name="Create.php" hash="08253fde693e39124b4b4f242c238852"/></dir></dir></dir><dir name="Avatax"><file name="Abstract.php" hash="9d5347c9eb201651469d0ffb62bbfa3f"/><file name="Address.php" hash="7c269d14d30b2faa1fbce281e6047889"/><file name="Estimate.php" hash="f136d8278b40cbfadea1d34b82189820"/><dir name="Exception"><file name="Address.php" hash="66761b418530d8682666a0ed6987ff3e"/><file name="Commitfailure.php" hash="81257541dd1d679493cfd2d3c5b6366e"/><file name="Unbalanced.php" hash="dc7967d9c5780b45ecb0828d5a1fc6dc"/></dir><file name="Invoice.php" hash="2f2fd8faefe375139a3b6f09247d810d"/><file name="Ping.php" hash="57b77948291fda5c6fe15733fd96a3c0"/></dir><file name="Config.php" hash="623922ea0cb4b335d2fca188f6f4f405"/><dir name="Export"><dir name="Adapter"><file name="Abstract.php" hash="840c8b87acd97646572bba9bb3b8f5ea"/><file name="Sql.php" hash="0e9bedb400f411785311f78ebbf676da"/></dir><dir name="Entity"><file name="Abstract.php" hash="d38a2293452c31e92f81bf5be59c3e1c"/><file name="Log.php" hash="a1dd28eee3e72d1a4ef7bddd865ddbae"/><file name="Queue.php" hash="14a97c283aa74f97982ab71160017aa3"/></dir></dir><file name="Export.php" hash="b94613b678b413d6268b07d314ba122e"/><file name="Observer.php" hash="721fb0a5a2c0502645becd665a54b0b3"/><dir name="Records"><file name="Log.php" hash="9a95ea609f75fa416c4564de8d3af4a2"/><dir name="Mysql4"><dir name="Log"><file name="Collection.php" hash="29db8163f4dda862ff822ddffd04554d"/></dir><file name="Log.php" hash="d6fb7997768b7e0f1b39363fd4de5917"/><dir name="Queue"><file name="Collection.php" hash="11bba1561c81f39695f091b94bd81560"/></dir><file name="Queue.php" hash="ad319339f577fdbbba740c52848a272c"/></dir><dir name="Queue"><file name="Process.php" hash="77092de76e08561d16759660b4a4f0c4"/></dir><file name="Queue.php" hash="17e369325bcac42042676bb61a2248c5"/></dir><dir name="Sales"><dir name="Quote"><dir name="Address"><dir name="Total"><file name="Grand.php" hash="63fb5a808ad3c16d2ed15f1dafad7937"/><file name="Tax.php" hash="359f5c252bad500b290d5569818d6478"/></dir></dir><file name="Address.php" hash="3191bbdf4e2227d35cf588dde798731b"/></dir></dir><file name="Session.php" hash="429142089e75418a702e70edc56374cf"/><dir name="Source"><file name="Actions.php" hash="879b80f92f735402f57e316546b16984"/><file name="Addressvalidation.php" hash="9f2315018910f7336ad894156d49d9b9"/><file name="Customercodeformat.php" hash="cfcfcbaa27ed29add072324816da0c9d"/><file name="Error.php" hash="7f5495a2f295ded2d0a30f2f7108d009"/><file name="Fieldlist.php" hash="18987603d4d58130959a8ac76716ed08"/><file name="Logmode.php" hash="24d61da578a3b4adb896fea7d4d4d8ec"/><file name="Logtype.php" hash="4079ebbf7ef44593e631b8cc9f0fc2a5"/><file name="Onerrorfrontend.php" hash="ef4154ae563d8157c1083f20e0adf563"/><dir name="Regionfilter"><file name="List.php" hash="169d0a776823439984fbdf27e631f62e"/><file name="Mode.php" hash="27fdc94c6f162100d55005285b5170df"/></dir></dir><dir name="Tax"><file name="Config.php" hash="6168c0d674a44291b7dbfe358305a04b"/></dir></dir><dir name="controllers"><dir name="Adminhtml"><file name="ExportController.php" hash="0ad97f1a39563925b5e33d6e9ca07885"/><file name="GridController.php" hash="91f38761378ff91d1f9c396b1cb3c150"/></dir></dir><dir name="etc"><file name="adminhtml.xml" hash="92c529d045fa34fd0822b6ccb40bd4ed"/><file name="config.xml" hash="3e524576864785049925f45ba3f22c2c"/><file name="system-disabled.xml" hash="937460e7271eb45d25f424d7da2baa72"/><file name="system.xml" hash="a1aa4cb07bce94406110cc9c1628460e"/></dir><dir name="sql"><dir name="avatax_records_setup"><file name="mysql4-data-upgrade-2.2.0-2.2.1.php" hash="260d1c57754ebadba00d8ccdbb0ec996"/><file name="mysql4-install-0.1.0.php" hash="3d16899179b36bfde69609a99a2faae6"/><file name="mysql4-upgrade-0.1.4-0.1.5.php" hash="94d0cf2fc0e9bbe2de2829198ce3026f"/><file name="mysql4-upgrade-1.0.1-2.0.0.php" hash="905d7519328cdb1c46bba4221288c41c"/><file name="mysql4-upgrade-2.5.0.0-2.5.0.1.php" hash="4b439957397049bbe01d458fd7cfe0a2"/></dir></dir></dir></dir></target><target name="mageetc"><dir name="modules"><file name="OnePica_AvaTax.xml" hash="07fd9423811b4dc084060d6131b889d7"/></dir></target><target name="magedesign"><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="layout"><dir name="onepica"><file name="avatax.xml" hash="a2514046fa0428d24a25f82d17627843"/></dir></dir><dir name="template"><dir name="onepica"><dir name="avatax"><dir name="log"><file name="view.phtml" hash="df14eee805bbedd484cf500dbf2335ed"/></dir><dir name="notification"><file name="toolbar.phtml" hash="fd368e043843df76ec3a74290b87dc3e"/></dir></dir></dir></dir></dir></dir></dir><dir name="frontend"><dir name="base"><dir name="default"><dir name="layout"><dir name="onepica"><file name="avatax.xml" hash="38c6ce2165f6ccfd6641eb1487faad39"/></dir></dir></dir></dir></dir></target><target name="magelocale"><dir name="de_DE"><file name="OnePica_AvaTax.csv" hash="43d2dee74aee6f15abd471a65b4f407c"/></dir><dir name="en_US"><file name="OnePica_AvaTax.csv" hash="43d2dee74aee6f15abd471a65b4f407c"/></dir><dir name="es_ES"><file name="OnePica_AvaTax.csv" hash="43d2dee74aee6f15abd471a65b4f407c"/></dir><dir name="fr_FR"><file name="OnePica_AvaTax.csv" hash="43d2dee74aee6f15abd471a65b4f407c"/></dir><dir name="nl_NL"><file name="OnePica_AvaTax.csv" hash="43d2dee74aee6f15abd471a65b4f407c"/></dir><dir name="pt_BR"><file name="OnePica_AvaTax.csv" hash="43d2dee74aee6f15abd471a65b4f407c"/></dir><dir name="zh_CN"><file name="OnePica_AvaTax.csv" hash="43d2dee74aee6f15abd471a65b4f407c"/></dir></target><target name="magelib"><dir name="AvaTax"><file name="AvaTax.php" hash="b90641e80230f53318050942cc6b018e"/><dir name="classes"><file name="ATConfig.class.php" hash="3dcbb1fa9a51c6879304acfc665bf448"/><file name="ATObject.class.php" hash="310310eb90550b27cdba24407d8ff3b4"/><file name="AVObject.class.php" hash="b65c5532b01074a57a20703513148301"/><file name="Address.class.php" hash="8fcdbac804176af8acdb842c666f6601"/><file name="AddressServiceSoap.class.php" hash="a7327489aad4fe9d998a3d7bd7073ee1"/><file name="AddressType.class.php" hash="027a8d859a0c6e5c41d8b99635bf088d"/><file name="AdjustTaxRequest.class.php" hash="2b81104d3a061a194425c33d67489957"/><file name="AdjustTaxResult.class.php" hash="b08c06eb0711d3202c9d9920b24cece0"/><file name="ApplyPaymentRequest.class.php" hash="06672fc904a5df2ea8724a43971a7aa6"/><file name="ApplyPaymentResult.class.php" hash="08d5ee00317eec6c08ca5c3b6d8df14f"/><file name="AvalaraSoapClient.class.php" hash="c7b0b8c214f3508489b235a176701fba"/><file name="BaseResult.class.php" hash="5cf878570642a4c6a2583bd28d2d8620"/><dir name="BatchSvc"><file name="AuditMessage.class.php" hash="8c963f144cf6e2c071f93a1597e32a80"/><file name="AvaTaxBatchSvc.php" hash="e44adcc534e8c5760b368bc565473438"/><file name="BaseResult.class.php" hash="ec50a42321502cc75c2faf592e39b907"/><file name="Batch.class.php" hash="ca0acabb6c024c705140d8e3f71b1212"/><file name="BatchDelete.class.php" hash="7df3c7433c28d63cc40c691d69274fbe"/><file name="BatchDeleteResponse.class.php" hash="1e30d2e0b974a05a3ab8fab69a3fe201"/><file name="BatchFetch.class.php" hash="a219586203d34a3a03cc9a5538917201"/><file name="BatchFetchResponse.class.php" hash="a57f9246b5c466582071df04c78af692"/><file name="BatchFetchResult.class.php" hash="725fd451543fe30eed13b8d98187f231"/><file name="BatchFile.class.php" hash="46cc9e7a93f97941b4f0c80da35640c2"/><file name="BatchFileDelete.class.php" hash="7c86228d0214a53c235109905bc02aad"/><file name="BatchFileDeleteResponse.class.php" hash="b2a6d01af2ed1292a70bbadf62119bd9"/><file name="BatchFileFetch.class.php" hash="daa00c82d13715687f2c3b00e99b1480"/><file name="BatchFileFetchResponse.class.php" hash="e5bd28ed93bf35aba9e4f7779b31ad80"/><file name="BatchFileFetchResult.class.php" hash="791b0af2ea67b5dbb475ccb6d685c429"/><file name="BatchFileSave.class.php" hash="e1ad2b7f81c9e82313717db5409b18c4"/><file name="BatchFileSaveResponse.class.php" hash="5bab865aee572b1accf3de7cddfb0f2f"/><file name="BatchFileSaveResult.class.php" hash="4dbe0e1f549ed394eef657beff8471d5"/><file name="BatchProcess.class.php" hash="7788019e9be7419d406c9066c965deb3"/><file name="BatchProcessRequest.class.php" hash="832ff7855024677b7386ffaa6e0104e6"/><file name="BatchProcessResponse.class.php" hash="3d44d5be278b15cf4b15aba43c37ccbd"/><file name="BatchProcessResult.class.php" hash="337878f3dacb143e9ae7020cdd95b15a"/><file name="BatchSave.class.php" hash="327a80041e4edd25229a928c98ca06ec"/><file name="BatchSaveResponse.class.php" hash="f6dcd4c5d37487fd3d369f6e45af6a9d"/><file name="BatchSaveResult.class.php" hash="a7d6928c7264c34111217724da73c33d"/><file name="BatchSvc.class.php" hash="002a810f1f528d9957acb9425ab0d413"/><file name="DeleteRequest.class.php" hash="b58d438f56e27657225fd7d5fd3345d5"/><file name="DeleteResult.class.php" hash="b85e674576d8e1ef932e65a89442b1ab"/><file name="FetchRequest.class.php" hash="f2dc7736d1d978b42208af43dbd1e5c4"/><file name="FilterRequest.class.php" hash="a6d398d8cb74108fbc5a8db2ec0257a3"/><file name="FilterResult.class.php" hash="3a3fa688fbb5301c724172c689c489ac"/><file name="IsAuthorized.class.php" hash="bcea0e6f94fd91896b5f7dab5ccf1d34"/><file name="IsAuthorizedResponse.class.php" hash="3257ed6e3f72776755a5c777005dc07e"/><file name="IsAuthorizedResult.class.php" hash="b448a3e693de964adcd94f4080053400"/><file name="Message.class.php" hash="50449eb305fd599b2d0c1f896d04de15"/><file name="Ping.class.php" hash="f41dfdeae46ed60807133640ae439e73"/><file name="PingResponse.class.php" hash="25a4f733ea8358bb704f599b73e3acf5"/><file name="PingResult.class.php" hash="1d4b1e742c64763ccb19bdd5f1f1242e"/><file name="Profile.class.php" hash="be9136ca7d9262ecf6cb475478ba6f34"/><file name="SeverityLevel.class.php" hash="1d0f3fbafc53eb0c95d8bd012f8bceb8"/></dir><file name="BoundaryLevel.class.php" hash="6668793633f248fb3b0f3202f9c1bb9e"/><file name="CancelCode.class.php" hash="9ee9566cc42dcdc7f0a3b72aeb018476"/><file name="CancelTaxRequest.class.php" hash="dab9d9ea6eb4136a90ae004d42f14137"/><file name="CancelTaxResult.class.php" hash="0956c33ca647ce8243162b5e9a2b0aca"/><file name="CommitTaxRequest.class.php" hash="60449d210f13a38268190d5e2646af66"/><file name="CommitTaxResult.class.php" hash="e6d9f7012e8ccfca24f2e518253d8166"/><file name="DetailLevel.class.php" hash="e1932019e1c37fe5d38f85df90270b58"/><file name="DocStatus.class.php" hash="85bca886f525c7e87dab26dde0d3863a"/><file name="DocumentType.class.php" hash="d3c1c1f2587fa678f07c238c04ddbece"/><file name="DynamicSoapClient.class.php" hash="99b8b6107cef48e9db0176c9a7eebfa3"/><file name="Enum.class.php" hash="c5742f64a549cab51215f8caf129cba4"/><file name="GetTaxHistoryRequest.class.php" hash="dc5f81710bc8fcaba219ae777d846d30"/><file name="GetTaxHistoryResult.class.php" hash="3caa151cba735013c3c1696f664420ae"/><file name="GetTaxRequest.class.php" hash="bff7746d46b73dcb3ca1e9cdd77243ef"/><file name="GetTaxResult.class.php" hash="c0dc8ba348373ee0b88349c770a11ecc"/><file name="IsAuthorizedResult.class.php" hash="5081fbdbac0d6744111c546ee3d86b02"/><file name="JurisdictionType.class.php" hash="1fe9bf7b10ab3fbcc5eafa572a1e60df"/><file name="Line.class.php" hash="49b5a64113159d176f9a59c545c3c7da"/><file name="Message.class.php" hash="828ee52d57c6bd5fac1b683f031cf6fb"/><file name="PingResult.class.php" hash="3ffb8ba98d405d42da5e81535d88bdd9"/><file name="PostTaxRequest.class.php" hash="f02d8cdb12faa58af032571ddea35153"/><file name="PostTaxResult.class.php" hash="7e4b10738889f6de5cd72890c75552a8"/><file name="ReconcileTaxHistoryRequest.class.php" hash="f7ee69eff0a927484c836070625dd5c1"/><file name="ReconcileTaxHistoryResult.class.php" hash="87150941612abae0a4c38bda917cf9fc"/><file name="SearchTaxHistoryResult.class.php" hash="83772c17bf1aa6603ded582f39b369d2"/><file name="ServiceMode.class.php" hash="1df748285dfa93e3289067e1eff357cb"/><file name="SeverityLevel.class.php" hash="b6dd0121e5f34618b69de53d780a0b37"/><file name="TaxDetail.class.php" hash="730a8b65a33d3f9a9a177271886260d8"/><file name="TaxLine.class.php" hash="8e76dad82886bb95b63cf7c06742b436"/><file name="TaxOverride.class.php" hash="e4a2dfbae6201f1f35f73cf7d406bc8a"/><file name="TaxOverrideType.class.php" hash="a7ebd4cc1752097072cab8e9f5ea30e9"/><file name="TaxRequest.class.php" hash="1e13ebb2e220d0fcb259d3195b42bf21"/><file name="TaxServiceSoap.class.php" hash="11674eb236496b62fd69faf41306d04e"/><file name="TaxType.class.php" hash="6bbf38a988efdb988524a08aee239278"/><file name="TextCase.class.php" hash="b27c032f45230cadff0d918f1a80261d"/><file name="ValidAddress.class.php" hash="6a404c90685b1af5fb3712a1776983c2"/><file name="ValidateRequest.class.php" hash="f095566ce30885dadc0272fb19cd00c8"/><file name="ValidateResult.class.php" hash="47258df8dbcd349743e9fcb53ea7ae36"/><dir name="wsdl"><file name="Address.wsdl" hash="803c4963306f4c59a818cd15163241c9"/><file name="BatchSvc.wsdl" hash="798a715e28b9751b01666a29554135f7"/><file name="Tax.wsdl" hash="8539baec3de1a11a1767921fd51f5852"/></dir></dir><file name="functions.php" hash="57734d162b59cbc65933d25bf3950270"/></dir></target></contents>
26
  <compatible/>
27
  <dependencies><required><php><min>5.2.3</min><max>6.0.0</max></php><extension><name>Core</name><min/><max/></extension><extension><name>curl</name><min/><max/></extension><extension><name>soap</name><min/><max/></extension></required></dependencies>
28
  </package>