Version Notes
For more information contact us at info@shipjunction.com
Download this release
Release Info
Developer | ShipJunction |
Extension | Shipjunction_Util |
Version | 0.1.0 |
Comparing to | |
See all releases |
Version 0.1.0
- app/code/local/Shipjunction/Utilities/Model/Objectmodel/Api.php +207 -0
- app/code/local/Shipjunction/Utilities/Model/Objectmodel/Api/V2.php +6 -0
- app/code/local/Shipjunction/Utilities/Model/Objectmodel/test.php +27 -0
- app/code/local/Shipjunction/Utilities/Model/Objectmodel/test_ordinc_id.php +7 -0
- app/code/local/Shipjunction/Utilities/Model/Objectmodel/xmlreturned.xml +295 -0
- app/code/local/Shipjunction/Utilities/etc/adminhtml.xml +22 -0
- app/code/local/Shipjunction/Utilities/etc/api.xml +41 -0
- app/code/local/Shipjunction/Utilities/etc/config.xml +24 -0
- app/code/local/Shipjunction/Utilities/etc/system.xml +38 -0
- app/code/local/Shipjunction/Utilities/etc/wsdl.xml +153 -0
- package.xml +21 -0
app/code/local/Shipjunction/Utilities/Model/Objectmodel/Api.php
ADDED
@@ -0,0 +1,207 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
class productLocationZone
|
3 |
+
{
|
4 |
+
public $productId = "";
|
5 |
+
public $location = "";
|
6 |
+
public $zone = "";
|
7 |
+
}
|
8 |
+
class Shipjunction_Utilities_Model_Objectmodel_Api extends Mage_Api_Model_Resource_Abstract
|
9 |
+
{
|
10 |
+
/**
|
11 |
+
* sendShipmentEmail
|
12 |
+
*
|
13 |
+
* @param string $shipmentIncrementId
|
14 |
+
* @return string 1 = sucess, 0 = failure
|
15 |
+
*/
|
16 |
+
|
17 |
+
public function sendShipmentEmail( $shipmentIncrementId )
|
18 |
+
{
|
19 |
+
$return = 1;
|
20 |
+
Mage::log("Shipjunction_Utilites_Model_Objectmodel_Api: sendShipmentEmail called");
|
21 |
+
$shipment = Mage::getModel('sales/order_shipment')->loadByIncrementId($shipmentIncrementId);
|
22 |
+
if($shipment)
|
23 |
+
{
|
24 |
+
$shipment->sendEmail(true);
|
25 |
+
$shipment->setEmailSent(true);
|
26 |
+
$shipment->save();
|
27 |
+
}
|
28 |
+
else {
|
29 |
+
Mage::log("Shipjunction_Utilites_Model_Objectmodel_Api: shipment NOT found : ". $shipmentIncrementId);
|
30 |
+
$result = 0;
|
31 |
+
}
|
32 |
+
return $return;
|
33 |
+
}
|
34 |
+
|
35 |
+
/**
|
36 |
+
* getClearpathOrderNumber
|
37 |
+
*
|
38 |
+
* @param string $_orderIncrementId
|
39 |
+
* @return string clearpathOrderNumber, boolean false
|
40 |
+
*/
|
41 |
+
public function getClearpathOrderNumber( $_orderIncrementId )
|
42 |
+
{
|
43 |
+
Mage::log("Shipjunction_Utilites_Model_Objectmodel_Api: getClearpathOrderNumber called");
|
44 |
+
|
45 |
+
$_clearpath_tablename = Mage::getStoreConfig('clearpath/general/clearpath_tablename');
|
46 |
+
$_db = Mage::getSingleton('core/resource')->getConnection('core_read');
|
47 |
+
$_db_query = "SELECT cp_order_number FROM {$_clearpath_tablename} WHERE mage_order_number = '{$_orderIncrementId}'";
|
48 |
+
$_db_result = $_db->fetchAll($_db_query);
|
49 |
+
|
50 |
+
if ($_db_result) {
|
51 |
+
return $_db_result[0]['cp_order_number'];
|
52 |
+
} else {
|
53 |
+
return false;
|
54 |
+
}
|
55 |
+
}
|
56 |
+
|
57 |
+
/**
|
58 |
+
* getEmbeddedErpFullStockOrders
|
59 |
+
*
|
60 |
+
* @return string comma delimited list of increment_ids which are fully stocked
|
61 |
+
*/
|
62 |
+
public function getEmbeddedErpFullStockOrders()
|
63 |
+
{
|
64 |
+
Mage::log("Shipjunction_Utilites_Model_Objectmodel_Api: getEmbeddedErpFullStockOrders called");
|
65 |
+
$result = "";
|
66 |
+
$resource = Mage::getSingleton('core/resource');
|
67 |
+
$readConnection = $resource->getConnection('core_read');
|
68 |
+
$sales_order_table = $resource->getTableName('sales/order');
|
69 |
+
|
70 |
+
$completeOrders = Mage::getModel('Orderpreparation/ordertoprepare')->getFullStockOrdersFromCache();
|
71 |
+
foreach($completeOrders as $completeOrder)
|
72 |
+
{
|
73 |
+
$completeOrderIds[] = $completeOrder->getopp_order_id();
|
74 |
+
}
|
75 |
+
|
76 |
+
$sql = "SELECT `increment_id` FROM `". $sales_order_table ."` WHERE `entity_id` in ('". implode("', '", $completeOrderIds) ."')";
|
77 |
+
$db_result = $readConnection->fetchAll($sql);
|
78 |
+
if ($db_result) {
|
79 |
+
foreach($db_result as $row){
|
80 |
+
$result = $result.$row['increment_id'].",";
|
81 |
+
}
|
82 |
+
}
|
83 |
+
|
84 |
+
return $result;
|
85 |
+
}
|
86 |
+
|
87 |
+
/**
|
88 |
+
* getEmbeddedErpZonesAndBins
|
89 |
+
*
|
90 |
+
* @param string $_productIdList comma delimited list of productIds to retrieve zone & bin information
|
91 |
+
* @return string pipe delimited set of productId|binLocation|zone for $_productIdList
|
92 |
+
*/
|
93 |
+
public function getEmbeddedErpZonesAndBins($_productIdList)
|
94 |
+
{
|
95 |
+
Mage::log("Shipjunction_Utilites_Model_Objectmodel_Api: getEmbeddedErpZonesAndBins called");
|
96 |
+
|
97 |
+
$productToBin = array();
|
98 |
+
$binToZone = array();
|
99 |
+
$locationList = "";
|
100 |
+
$result = "";
|
101 |
+
|
102 |
+
$warehouse = Mage::getModel('AdvancedStock/Warehouse')->load(1);
|
103 |
+
$productIds = explode(",",$_productIdList);
|
104 |
+
|
105 |
+
// Map each productId to a bin_num
|
106 |
+
foreach($productIds as $productId) {
|
107 |
+
$location = $warehouse->getProductLocation($productId);
|
108 |
+
$productToBin[$productId] = $location;
|
109 |
+
$locationList = $locationList."'".$location."',";
|
110 |
+
}
|
111 |
+
|
112 |
+
$resource = Mage::getSingleton('core/resource');
|
113 |
+
$readConnection = $resource->getConnection('core_read');
|
114 |
+
// Map each bin_num to a zone
|
115 |
+
$sql = "SELECT `bin_num`,`zone` FROM `bin_list` WHERE `bin_num` in (". rtrim($locationList, ',') .");";
|
116 |
+
|
117 |
+
$db_result = $readConnection->fetchAll($sql);
|
118 |
+
if ($db_result) {
|
119 |
+
foreach($db_result as $row){
|
120 |
+
if (strlen($row['bin_num']) > 0) {
|
121 |
+
$binToZone[$row['bin_num']] = $row['zone'];
|
122 |
+
}
|
123 |
+
}
|
124 |
+
}
|
125 |
+
// put the results together
|
126 |
+
foreach(array_keys($productToBin) as $productId) {
|
127 |
+
$location = $productToBin[$productId];
|
128 |
+
$zone = $binToZone[$location];
|
129 |
+
$result = $result."|".$productId."|".$location."|".$zone;
|
130 |
+
}
|
131 |
+
// remove starting pipe
|
132 |
+
$result = ltrim($result, '|');
|
133 |
+
|
134 |
+
return $result;
|
135 |
+
}
|
136 |
+
|
137 |
+
/**
|
138 |
+
* Create new invoice for order
|
139 |
+
*
|
140 |
+
* @param string $invoiceIncrementId
|
141 |
+
* @param array $itemsQty
|
142 |
+
* @param string $comment
|
143 |
+
* @param bool $email
|
144 |
+
* @param bool $includeComment
|
145 |
+
* @param bool $capture
|
146 |
+
* @return string
|
147 |
+
*/
|
148 |
+
public function createInvoice($orderIncrementId,
|
149 |
+
$itemsQty,
|
150 |
+
$comment = null,
|
151 |
+
$email = false,
|
152 |
+
$includeComment = false,
|
153 |
+
$capture = false)
|
154 |
+
{
|
155 |
+
Mage::log("Shipjunction_Utilites_Model_Objectmodel_Api: createInvoice called with id:".$orderIncrementId.",email=".$email.",capture=".$capture.",itemsQty=".var_dump($itemsQty));
|
156 |
+
$order = Mage::getModel('sales/order')->loadByIncrementId($orderIncrementId);
|
157 |
+
//$itemsQty = $this->_prepareItemQtyData($itemsQty);
|
158 |
+
/* @var $order Mage_Sales_Model_Order */
|
159 |
+
/**
|
160 |
+
* Check order existing
|
161 |
+
*/
|
162 |
+
if (!$order->getId()) {
|
163 |
+
return "Invalid order incrementId";
|
164 |
+
}
|
165 |
+
|
166 |
+
/**
|
167 |
+
* Check invoice create availability
|
168 |
+
*/
|
169 |
+
if (!$order->canInvoice()) {
|
170 |
+
return "Cannot do invoice for order.";
|
171 |
+
}
|
172 |
+
|
173 |
+
$invoice = $order->prepareInvoice(); // removing $itemsQty for now
|
174 |
+
|
175 |
+
$invoice->setRequestedCaptureCase(Mage_Sales_Model_Order_Invoice::CAPTURE_ONLINE);
|
176 |
+
|
177 |
+
$invoice->register();
|
178 |
+
|
179 |
+
if ($capture && $invoice->canCapture()) {
|
180 |
+
$invoice->capture();
|
181 |
+
Mage::log("Shipjunction_Utilites_Model_Objectmodel_Api: createInvoice attempted to capture invoice");
|
182 |
+
}
|
183 |
+
|
184 |
+
if ($comment !== null) {
|
185 |
+
$invoice->addComment($comment, $email);
|
186 |
+
}
|
187 |
+
|
188 |
+
if ($email) {
|
189 |
+
$invoice->setEmailSent(true);
|
190 |
+
}
|
191 |
+
|
192 |
+
$invoice->getOrder()->setIsInProcess(true);
|
193 |
+
|
194 |
+
try {
|
195 |
+
Mage::getModel('core/resource_transaction')
|
196 |
+
->addObject($invoice)
|
197 |
+
->addObject($invoice->getOrder())
|
198 |
+
->save();
|
199 |
+
$invoice->sendEmail($email, ($includeComment ? $comment : ''));
|
200 |
+
} catch (Mage_Core_Exception $e) {
|
201 |
+
return "Data invalid : ".$e->getMessage();
|
202 |
+
}
|
203 |
+
|
204 |
+
return $invoice->getIncrementId();
|
205 |
+
}
|
206 |
+
}
|
207 |
+
?>
|
app/code/local/Shipjunction/Utilities/Model/Objectmodel/Api/V2.php
ADDED
@@ -0,0 +1,6 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
//class Shipjunction_Utilites_Model_Objectmodel_Api_V2 extends Shipjunction_Utilites_Model_Objectmodel_Api
|
3 |
+
class Shipjunction_Utilities_Model_Objectmodel_Api_V2 extends Shipjunction_Utilities_Model_Objectmodel_Api
|
4 |
+
{
|
5 |
+
}
|
6 |
+
?>
|
app/code/local/Shipjunction/Utilities/Model/Objectmodel/test.php
ADDED
@@ -0,0 +1,27 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
class productLocationZone
|
3 |
+
{
|
4 |
+
public $productId = "";
|
5 |
+
public $location = "";
|
6 |
+
public $zone = "";
|
7 |
+
}
|
8 |
+
|
9 |
+
|
10 |
+
$_productIdList = "SKU1,SKU3";
|
11 |
+
$productIds = explode(",",$_productIdList);
|
12 |
+
$return = array();
|
13 |
+
foreach($productIds as $productId) {
|
14 |
+
$productLocation = $productId."LOC";
|
15 |
+
$zone = $productId."ZONE";
|
16 |
+
$productLocationZone = new productLocationZone();
|
17 |
+
$productLocationZone->productId = $productId;
|
18 |
+
$productLocationZone->location = $productLocation;
|
19 |
+
$productLocationZone->zone = $zone;
|
20 |
+
array_push($return, $productLocationZone);
|
21 |
+
/*array_push($return,
|
22 |
+
array("ProductId" => $productId,
|
23 |
+
"Location" => $productLocation,
|
24 |
+
"Zone" => $zone));*/
|
25 |
+
}
|
26 |
+
print_r($return);
|
27 |
+
?>
|
app/code/local/Shipjunction/Utilities/Model/Objectmodel/test_ordinc_id.php
ADDED
@@ -0,0 +1,7 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
|
3 |
+
$completeOrderIds = array(1,3);
|
4 |
+
|
5 |
+
$s = "SELECT `increment_id` FROM `". $sales_order_table ."` WHERE `entity_id` in ('". implode("', '", $completeOrderIds) ."')";
|
6 |
+
print_r($s);
|
7 |
+
?>
|
app/code/local/Shipjunction/Utilities/Model/Objectmodel/xmlreturned.xml
ADDED
@@ -0,0 +1,295 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
difficulties with returning a new object from Magento Api :
|
2 |
+
|
3 |
+
*. got the object defined in wsdl
|
4 |
+
*. have the object being returned as below, but the object itself is called of type "Struct", which I believe to be the default when the magento SOAP serializer gets an object with which it is unfamiliar.
|
5 |
+
|
6 |
+
so the question is, how do I get the SOAP serializer within Magento to return the below without Struct, and with "ProductLocationZone"
|
7 |
+
|
8 |
+
|
9 |
+
<!-- this is the result with the object, but it doesn't know anyhting about my class because it's defined in my api file, and the object->wsdl mapping is happening somewhere else -->
|
10 |
+
<?xml version="1.0" encoding="UTF-8"?>
|
11 |
+
<SOAP-ENV:Envelope SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/" xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns1="urn:Magento" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
|
12 |
+
<SOAP-ENV:Body>
|
13 |
+
<ns1:shipjunctionUtilitiesGetEmbeddedErpZonesAndBinsResponse>
|
14 |
+
<zonesBins SOAP-ENC:arrayType="SOAP-ENC:Struct[2]" xsi:type="SOAP-ENC:Array">
|
15 |
+
<item xsi:type="SOAP-ENC:Struct">
|
16 |
+
<productId xsi:type="xsd:string">SKU1</productId>
|
17 |
+
<location xsi:type="xsd:string">SKU1LOC</location>
|
18 |
+
<zone xsi:type="xsd:string">SKU1ZONE</zone>
|
19 |
+
</item>
|
20 |
+
<item xsi:type="SOAP-ENC:Struct">
|
21 |
+
<productId xsi:type="xsd:string">SKU2</productId>
|
22 |
+
<location xsi:type="xsd:string">SKU2LOC</location>
|
23 |
+
<zone xsi:type="xsd:string">SKU2ZONE</zone>
|
24 |
+
</item>
|
25 |
+
</zonesBins>
|
26 |
+
</ns1:shipjunctionUtilitiesGetEmbeddedErpZonesAndBinsResponse>
|
27 |
+
</SOAP-ENV:Body>
|
28 |
+
</SOAP-ENV:Envelope>
|
29 |
+
|
30 |
+
<complexType name="associativeEntity">
|
31 |
+
<all>
|
32 |
+
<element name="key" type="xsd:string"/>
|
33 |
+
<element name="value" type="xsd:string"/>
|
34 |
+
</all>
|
35 |
+
</complexType>
|
36 |
+
<complexType name="associativeArray">
|
37 |
+
<complexContent>
|
38 |
+
<restriction base="soapenc:Array">
|
39 |
+
<attribute ref="soapenc:arrayType" wsdl:arrayType="typens:associativeEntity[]"/>
|
40 |
+
</restriction>
|
41 |
+
</complexContent>
|
42 |
+
</complexType>
|
43 |
+
|
44 |
+
<?xml version="1.0" encoding="UTF-8"?>
|
45 |
+
<SOAP-ENV:Envelope SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/" xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns1="urn:Magento" xmlns:ns2="http://xml.apache.org/xml-soap" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
|
46 |
+
<SOAP-ENV:Body>
|
47 |
+
<ns1:shipjunctionUtilitiesGetEmbeddedErpZonesAndBinsResponse>
|
48 |
+
<zonesBins SOAP-ENC:arrayType="ns2:Map[2]" xsi:type="SOAP-ENC:Array">
|
49 |
+
<item xsi:type="ns2:Map">
|
50 |
+
<item>
|
51 |
+
<key xsi:type="xsd:string">productId</key>
|
52 |
+
<value xsi:type="xsd:string">SKU1</value>
|
53 |
+
</item>
|
54 |
+
<item>
|
55 |
+
<key xsi:type="xsd:string">location</key>
|
56 |
+
<value xsi:nil="true"/>
|
57 |
+
</item>
|
58 |
+
<item>
|
59 |
+
<key xsi:type="xsd:string">zone</key>
|
60 |
+
<value xsi:type="xsd:string">SKU1ZONE</value>
|
61 |
+
</item>
|
62 |
+
</item>
|
63 |
+
<item xsi:type="ns2:Map">
|
64 |
+
<item>
|
65 |
+
<key xsi:type="xsd:string">productId</key>
|
66 |
+
<value xsi:type="xsd:string">SKU2</value>
|
67 |
+
</item>
|
68 |
+
<item>
|
69 |
+
<key xsi:type="xsd:string">location</key>
|
70 |
+
<value xsi:nil="true"/>
|
71 |
+
</item>
|
72 |
+
<item>
|
73 |
+
<key xsi:type="xsd:string">zone</key>
|
74 |
+
<value xsi:type="xsd:string">SKU2ZONE</value>
|
75 |
+
</item>
|
76 |
+
</item>
|
77 |
+
</zonesBins>
|
78 |
+
</ns1:shipjunctionUtilitiesGetEmbeddedErpZonesAndBinsResponse>
|
79 |
+
</SOAP-ENV:Body>
|
80 |
+
</SOAP-ENV:Envelope>
|
81 |
+
|
82 |
+
|
83 |
+
<?xml version="1.0" encoding="UTF-8"?>
|
84 |
+
<SOAP-ENV:Envelope SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/" xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns1="urn:Magento" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
|
85 |
+
<SOAP-ENV:Body>
|
86 |
+
<ns1:salesOrderInfoResponse>
|
87 |
+
<result xsi:type="ns1:salesOrderEntity">
|
88 |
+
<increment_id xsi:type="xsd:string">100000003</increment_id>
|
89 |
+
<store_id xsi:type="xsd:string">1</store_id>
|
90 |
+
<created_at xsi:type="xsd:string">2013-06-27 16:01:40</created_at>
|
91 |
+
<updated_at xsi:type="xsd:string">2013-07-17 20:06:49</updated_at>
|
92 |
+
<customer_id xsi:type="xsd:string">3</customer_id>
|
93 |
+
<tax_amount xsi:type="xsd:string">1.2400</tax_amount>
|
94 |
+
<shipping_amount xsi:type="xsd:string">5.0000</shipping_amount>
|
95 |
+
<discount_amount xsi:type="xsd:string">0.0000</discount_amount>
|
96 |
+
<subtotal xsi:type="xsd:string">15.0000</subtotal>
|
97 |
+
<grand_total xsi:type="xsd:string">21.2400</grand_total>
|
98 |
+
<total_qty_ordered xsi:type="xsd:string">1.0000</total_qty_ordered>
|
99 |
+
<base_tax_amount xsi:type="xsd:string">1.2400</base_tax_amount>
|
100 |
+
<base_shipping_amount xsi:type="xsd:string">5.0000</base_shipping_amount>
|
101 |
+
<base_discount_amount xsi:type="xsd:string">0.0000</base_discount_amount>
|
102 |
+
<base_subtotal xsi:type="xsd:string">15.0000</base_subtotal>
|
103 |
+
<base_grand_total xsi:type="xsd:string">21.2400</base_grand_total>
|
104 |
+
<billing_address_id xsi:type="xsd:string">5</billing_address_id>
|
105 |
+
<shipping_address_id xsi:type="xsd:string">6</shipping_address_id>
|
106 |
+
<store_to_base_rate xsi:type="xsd:string">1.0000</store_to_base_rate>
|
107 |
+
<store_to_order_rate xsi:type="xsd:string">1.0000</store_to_order_rate>
|
108 |
+
<base_to_global_rate xsi:type="xsd:string">1.0000</base_to_global_rate>
|
109 |
+
<base_to_order_rate xsi:type="xsd:string">1.0000</base_to_order_rate>
|
110 |
+
<weight xsi:type="xsd:string">0.5000</weight>
|
111 |
+
<store_name xsi:type="xsd:string">Main Website
|
112 |
+
Main Store
|
113 |
+
English</store_name>
|
114 |
+
<remote_ip xsi:type="xsd:string">192.168.1.130</remote_ip>
|
115 |
+
<status xsi:type="xsd:string">processing</status>
|
116 |
+
<state xsi:type="xsd:string">processing</state>
|
117 |
+
<global_currency_code xsi:type="xsd:string">USD</global_currency_code>
|
118 |
+
<base_currency_code xsi:type="xsd:string">USD</base_currency_code>
|
119 |
+
<store_currency_code xsi:type="xsd:string">USD</store_currency_code>
|
120 |
+
<order_currency_code xsi:type="xsd:string">USD</order_currency_code>
|
121 |
+
<shipping_method xsi:type="xsd:string">flatrate_flatrate</shipping_method>
|
122 |
+
<shipping_description xsi:type="xsd:string">Flat Rate - Fixed</shipping_description>
|
123 |
+
<customer_email xsi:type="xsd:string">jcarr@shipjunction.com</customer_email>
|
124 |
+
<customer_firstname xsi:type="xsd:string">Joe</customer_firstname>
|
125 |
+
<customer_lastname xsi:type="xsd:string">Carr</customer_lastname>
|
126 |
+
<quote_id xsi:type="xsd:string">3</quote_id>
|
127 |
+
<is_virtual xsi:type="xsd:string">0</is_virtual>
|
128 |
+
<customer_group_id xsi:type="xsd:string">1</customer_group_id>
|
129 |
+
<customer_note_notify xsi:type="xsd:string">1</customer_note_notify>
|
130 |
+
<customer_is_guest xsi:type="xsd:string">0</customer_is_guest>
|
131 |
+
<email_sent xsi:type="xsd:string">1</email_sent>
|
132 |
+
<order_id xsi:type="xsd:string">3</order_id>
|
133 |
+
<shipping_address xsi:type="ns1:salesOrderAddressEntity">
|
134 |
+
<parent_id xsi:type="xsd:string">3</parent_id>
|
135 |
+
<address_type xsi:type="xsd:string">shipping</address_type>
|
136 |
+
<firstname xsi:type="xsd:string">Joe</firstname>
|
137 |
+
<lastname xsi:type="xsd:string">Carr</lastname>
|
138 |
+
<street xsi:type="xsd:string">4116 Emerald St</street>
|
139 |
+
<city xsi:type="xsd:string">San Francisco</city>
|
140 |
+
<region xsi:type="xsd:string">California</region>
|
141 |
+
<postcode xsi:type="xsd:string">94509</postcode>
|
142 |
+
<country_id xsi:type="xsd:string">US</country_id>
|
143 |
+
<telephone xsi:type="xsd:string">718-223-1923</telephone>
|
144 |
+
<region_id xsi:type="xsd:string">12</region_id>
|
145 |
+
<address_id xsi:type="xsd:string">6</address_id>
|
146 |
+
</shipping_address>
|
147 |
+
<billing_address xsi:type="ns1:salesOrderAddressEntity">
|
148 |
+
<parent_id xsi:type="xsd:string">3</parent_id>
|
149 |
+
<address_type xsi:type="xsd:string">billing</address_type>
|
150 |
+
<firstname xsi:type="xsd:string">Joe</firstname>
|
151 |
+
<lastname xsi:type="xsd:string">Carr</lastname>
|
152 |
+
<street xsi:type="xsd:string">4116 Emerald St</street>
|
153 |
+
<city xsi:type="xsd:string">San Francisco</city>
|
154 |
+
<region xsi:type="xsd:string">California</region>
|
155 |
+
<postcode xsi:type="xsd:string">94509</postcode>
|
156 |
+
<country_id xsi:type="xsd:string">US</country_id>
|
157 |
+
<telephone xsi:type="xsd:string">718-223-1923</telephone>
|
158 |
+
<region_id xsi:type="xsd:string">12</region_id>
|
159 |
+
<address_id xsi:type="xsd:string">5</address_id>
|
160 |
+
</billing_address>
|
161 |
+
<items SOAP-ENC:arrayType="ns1:salesOrderItemEntity[2]" xsi:type="ns1:salesOrderItemEntityArray">
|
162 |
+
<item xsi:type="ns1:salesOrderItemEntity">
|
163 |
+
<item_id xsi:type="xsd:string">4</item_id>
|
164 |
+
<order_id xsi:type="xsd:string">3</order_id>
|
165 |
+
<quote_item_id xsi:type="xsd:string">4</quote_item_id>
|
166 |
+
<created_at xsi:type="xsd:string">2013-06-27 16:01:40</created_at>
|
167 |
+
<updated_at xsi:type="xsd:string">2013-07-17 20:06:49</updated_at>
|
168 |
+
<product_id xsi:type="xsd:string">119</product_id>
|
169 |
+
<product_type xsi:type="xsd:string">configurable</product_type>
|
170 |
+
<product_options xsi:type="xsd:string">a:6:{s:15:"info_buyRequest";a:5:{s:4:"uenc";s:104:"aHR0cDovLzE5Mi4xNjguMS4xNDAvaW5kZXgucGhwL2NvYWxlc2NlLWZ1bmN0aW9uaW5nLW9uLWltcGF0aWVuY2UtdC1zaGlydC5odG1s";s:7:"product";s:3:"119";s:15:"related_product";s:0:"";s:15:"super_attribute";a:1:{i:525;s:2:"99";}s:3:"qty";s:1:"1";}s:15:"attributes_info";a:1:{i:0;a:2:{s:5:"label";s:4:"Size";s:5:"value";s:6:"Medium";}}s:11:"simple_name";s:43:"Coalesce: Functioning On Impatience T-Shirt";s:10:"simple_sku";s:7:"coal_md";s:20:"product_calculations";i:1;s:13:"shipment_type";i:0;}</product_options>
|
171 |
+
<weight xsi:type="xsd:string">0.5000</weight>
|
172 |
+
<is_virtual xsi:type="xsd:string">0</is_virtual>
|
173 |
+
<sku xsi:type="xsd:string">coal_md</sku>
|
174 |
+
<name xsi:type="xsd:string">Coalesce: Functioning On Impatience T-Shirt</name>
|
175 |
+
<free_shipping xsi:type="xsd:string">0</free_shipping>
|
176 |
+
<is_qty_decimal xsi:type="xsd:string">0</is_qty_decimal>
|
177 |
+
<no_discount xsi:type="xsd:string">0</no_discount>
|
178 |
+
<qty_canceled xsi:type="xsd:string">0.0000</qty_canceled>
|
179 |
+
<qty_invoiced xsi:type="xsd:string">0.0000</qty_invoiced>
|
180 |
+
<qty_ordered xsi:type="xsd:string">1.0000</qty_ordered>
|
181 |
+
<qty_refunded xsi:type="xsd:string">0.0000</qty_refunded>
|
182 |
+
<qty_shipped xsi:type="xsd:string">1.0000</qty_shipped>
|
183 |
+
<price xsi:type="xsd:string">15.0000</price>
|
184 |
+
<base_price xsi:type="xsd:string">15.0000</base_price>
|
185 |
+
<original_price xsi:type="xsd:string">15.0000</original_price>
|
186 |
+
<base_original_price xsi:type="xsd:string">15.0000</base_original_price>
|
187 |
+
<tax_percent xsi:type="xsd:string">8.2500</tax_percent>
|
188 |
+
<tax_amount xsi:type="xsd:string">1.2400</tax_amount>
|
189 |
+
<base_tax_amount xsi:type="xsd:string">1.2400</base_tax_amount>
|
190 |
+
<tax_invoiced xsi:type="xsd:string">0.0000</tax_invoiced>
|
191 |
+
<base_tax_invoiced xsi:type="xsd:string">0.0000</base_tax_invoiced>
|
192 |
+
<discount_percent xsi:type="xsd:string">0.0000</discount_percent>
|
193 |
+
<discount_amount xsi:type="xsd:string">0.0000</discount_amount>
|
194 |
+
<base_discount_amount xsi:type="xsd:string">0.0000</base_discount_amount>
|
195 |
+
<discount_invoiced xsi:type="xsd:string">0.0000</discount_invoiced>
|
196 |
+
<base_discount_invoiced xsi:type="xsd:string">0.0000</base_discount_invoiced>
|
197 |
+
<amount_refunded xsi:type="xsd:string">0.0000</amount_refunded>
|
198 |
+
<base_amount_refunded xsi:type="xsd:string">0.0000</base_amount_refunded>
|
199 |
+
<row_total xsi:type="xsd:string">15.0000</row_total>
|
200 |
+
<base_row_total xsi:type="xsd:string">15.0000</base_row_total>
|
201 |
+
<row_invoiced xsi:type="xsd:string">0.0000</row_invoiced>
|
202 |
+
<base_row_invoiced xsi:type="xsd:string">0.0000</base_row_invoiced>
|
203 |
+
<row_weight xsi:type="xsd:string">0.5000</row_weight>
|
204 |
+
<weee_tax_applied xsi:type="xsd:string">a:0:{}</weee_tax_applied>
|
205 |
+
<weee_tax_applied_amount xsi:type="xsd:string">0.0000</weee_tax_applied_amount>
|
206 |
+
<weee_tax_applied_row_amount xsi:type="xsd:string">0.0000</weee_tax_applied_row_amount>
|
207 |
+
<base_weee_tax_applied_amount xsi:type="xsd:string">0.0000</base_weee_tax_applied_amount>
|
208 |
+
<base_weee_tax_applied_row_amount xsi:type="xsd:string">0.0000</base_weee_tax_applied_row_amount>
|
209 |
+
<weee_tax_disposition xsi:type="xsd:string">0.0000</weee_tax_disposition>
|
210 |
+
<weee_tax_row_disposition xsi:type="xsd:string">0.0000</weee_tax_row_disposition>
|
211 |
+
<base_weee_tax_disposition xsi:type="xsd:string">0.0000</base_weee_tax_disposition>
|
212 |
+
<base_weee_tax_row_disposition xsi:type="xsd:string">0.0000</base_weee_tax_row_disposition>
|
213 |
+
</item>
|
214 |
+
<item xsi:type="ns1:salesOrderItemEntity">
|
215 |
+
<item_id xsi:type="xsd:string">5</item_id>
|
216 |
+
<order_id xsi:type="xsd:string">3</order_id>
|
217 |
+
<quote_item_id xsi:type="xsd:string">5</quote_item_id>
|
218 |
+
<created_at xsi:type="xsd:string">2013-06-27 16:01:40</created_at>
|
219 |
+
<updated_at xsi:type="xsd:string">2013-07-17 20:06:49</updated_at>
|
220 |
+
<product_id xsi:type="xsd:string">117</product_id>
|
221 |
+
<product_type xsi:type="xsd:string">simple</product_type>
|
222 |
+
<product_options xsi:type="xsd:string">a:1:{s:15:"info_buyRequest";a:5:{s:4:"uenc";s:104:"aHR0cDovLzE5Mi4xNjguMS4xNDAvaW5kZXgucGhwL2NvYWxlc2NlLWZ1bmN0aW9uaW5nLW9uLWltcGF0aWVuY2UtdC1zaGlydC5odG1s";s:7:"product";s:3:"119";s:15:"related_product";s:0:"";s:15:"super_attribute";a:1:{i:525;s:2:"99";}s:3:"qty";s:1:"1";}}</product_options>
|
223 |
+
<weight xsi:type="xsd:string">0.5000</weight>
|
224 |
+
<is_virtual xsi:type="xsd:string">0</is_virtual>
|
225 |
+
<sku xsi:type="xsd:string">coal_md</sku>
|
226 |
+
<name xsi:type="xsd:string">Coalesce: Functioning On Impatience T-Shirt</name>
|
227 |
+
<free_shipping xsi:type="xsd:string">0</free_shipping>
|
228 |
+
<is_qty_decimal xsi:type="xsd:string">0</is_qty_decimal>
|
229 |
+
<no_discount xsi:type="xsd:string">0</no_discount>
|
230 |
+
<qty_canceled xsi:type="xsd:string">0.0000</qty_canceled>
|
231 |
+
<qty_invoiced xsi:type="xsd:string">0.0000</qty_invoiced>
|
232 |
+
<qty_ordered xsi:type="xsd:string">1.0000</qty_ordered>
|
233 |
+
<qty_refunded xsi:type="xsd:string">0.0000</qty_refunded>
|
234 |
+
<qty_shipped xsi:type="xsd:string">0.0000</qty_shipped>
|
235 |
+
<price xsi:type="xsd:string">0.0000</price>
|
236 |
+
<base_price xsi:type="xsd:string">0.0000</base_price>
|
237 |
+
<original_price xsi:type="xsd:string">0.0000</original_price>
|
238 |
+
<tax_percent xsi:type="xsd:string">0.0000</tax_percent>
|
239 |
+
<tax_amount xsi:type="xsd:string">0.0000</tax_amount>
|
240 |
+
<base_tax_amount xsi:type="xsd:string">0.0000</base_tax_amount>
|
241 |
+
<tax_invoiced xsi:type="xsd:string">0.0000</tax_invoiced>
|
242 |
+
<base_tax_invoiced xsi:type="xsd:string">0.0000</base_tax_invoiced>
|
243 |
+
<discount_percent xsi:type="xsd:string">0.0000</discount_percent>
|
244 |
+
<discount_amount xsi:type="xsd:string">0.0000</discount_amount>
|
245 |
+
<base_discount_amount xsi:type="xsd:string">0.0000</base_discount_amount>
|
246 |
+
<discount_invoiced xsi:type="xsd:string">0.0000</discount_invoiced>
|
247 |
+
<base_discount_invoiced xsi:type="xsd:string">0.0000</base_discount_invoiced>
|
248 |
+
<amount_refunded xsi:type="xsd:string">0.0000</amount_refunded>
|
249 |
+
<base_amount_refunded xsi:type="xsd:string">0.0000</base_amount_refunded>
|
250 |
+
<row_total xsi:type="xsd:string">0.0000</row_total>
|
251 |
+
<base_row_total xsi:type="xsd:string">0.0000</base_row_total>
|
252 |
+
<row_invoiced xsi:type="xsd:string">0.0000</row_invoiced>
|
253 |
+
<base_row_invoiced xsi:type="xsd:string">0.0000</base_row_invoiced>
|
254 |
+
<row_weight xsi:type="xsd:string">0.0000</row_weight>
|
255 |
+
<weee_tax_applied xsi:type="xsd:string">a:0:{}</weee_tax_applied>
|
256 |
+
<weee_tax_applied_amount xsi:type="xsd:string">0.0000</weee_tax_applied_amount>
|
257 |
+
<weee_tax_applied_row_amount xsi:type="xsd:string">0.0000</weee_tax_applied_row_amount>
|
258 |
+
<base_weee_tax_applied_amount xsi:type="xsd:string">0.0000</base_weee_tax_applied_amount>
|
259 |
+
<weee_tax_disposition xsi:type="xsd:string">0.0000</weee_tax_disposition>
|
260 |
+
<weee_tax_row_disposition xsi:type="xsd:string">0.0000</weee_tax_row_disposition>
|
261 |
+
<base_weee_tax_disposition xsi:type="xsd:string">0.0000</base_weee_tax_disposition>
|
262 |
+
<base_weee_tax_row_disposition xsi:type="xsd:string">0.0000</base_weee_tax_row_disposition>
|
263 |
+
</item>
|
264 |
+
</items>
|
265 |
+
<payment xsi:type="ns1:salesOrderPaymentEntity">
|
266 |
+
<parent_id xsi:type="xsd:string">3</parent_id>
|
267 |
+
<amount_ordered xsi:type="xsd:string">21.2400</amount_ordered>
|
268 |
+
<shipping_amount xsi:type="xsd:string">5.0000</shipping_amount>
|
269 |
+
<base_amount_ordered xsi:type="xsd:string">21.2400</base_amount_ordered>
|
270 |
+
<base_shipping_amount xsi:type="xsd:string">5.0000</base_shipping_amount>
|
271 |
+
<method xsi:type="xsd:string">checkmo</method>
|
272 |
+
<cc_exp_month xsi:type="xsd:string">0</cc_exp_month>
|
273 |
+
<cc_exp_year xsi:type="xsd:string">0</cc_exp_year>
|
274 |
+
<cc_ss_start_month xsi:type="xsd:string">0</cc_ss_start_month>
|
275 |
+
<cc_ss_start_year xsi:type="xsd:string">0</cc_ss_start_year>
|
276 |
+
<payment_id xsi:type="xsd:string">3</payment_id>
|
277 |
+
</payment>
|
278 |
+
<status_history SOAP-ENC:arrayType="ns1:salesOrderStatusHistoryEntity[2]" xsi:type="ns1:salesOrderStatusHistoryEntityArray">
|
279 |
+
<item xsi:type="ns1:salesOrderStatusHistoryEntity">
|
280 |
+
<parent_id xsi:type="xsd:string">3</parent_id>
|
281 |
+
<created_at xsi:type="xsd:string">2013-07-17 20:06:49</created_at>
|
282 |
+
<is_customer_notified xsi:type="xsd:string">1</is_customer_notified>
|
283 |
+
<status xsi:type="xsd:string">processing</status>
|
284 |
+
</item>
|
285 |
+
<item xsi:type="ns1:salesOrderStatusHistoryEntity">
|
286 |
+
<parent_id xsi:type="xsd:string">3</parent_id>
|
287 |
+
<created_at xsi:type="xsd:string">2013-06-27 16:01:41</created_at>
|
288 |
+
<is_customer_notified xsi:type="xsd:string">1</is_customer_notified>
|
289 |
+
<status xsi:type="xsd:string">pending</status>
|
290 |
+
</item>
|
291 |
+
</status_history>
|
292 |
+
</result>
|
293 |
+
</ns1:salesOrderInfoResponse>
|
294 |
+
</SOAP-ENV:Body>
|
295 |
+
</SOAP-ENV:Envelope>
|
app/code/local/Shipjunction/Utilities/etc/adminhtml.xml
ADDED
@@ -0,0 +1,22 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?xml version="1.0"?>
|
2 |
+
<config>
|
3 |
+
<acl>
|
4 |
+
<resources>
|
5 |
+
<admin>
|
6 |
+
<children>
|
7 |
+
<system>
|
8 |
+
<children>
|
9 |
+
<config>
|
10 |
+
<children>
|
11 |
+
<clearpath>
|
12 |
+
<title>Clearpath</title>
|
13 |
+
</clearpath>
|
14 |
+
</children>
|
15 |
+
</config>
|
16 |
+
</children>
|
17 |
+
</system>
|
18 |
+
</children>
|
19 |
+
</admin>
|
20 |
+
</resources>
|
21 |
+
</acl>
|
22 |
+
</config>
|
app/code/local/Shipjunction/Utilities/etc/api.xml
ADDED
@@ -0,0 +1,41 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?xml version="1.0"?>
|
2 |
+
<config>
|
3 |
+
<api>
|
4 |
+
<resources>
|
5 |
+
<shipjunction_utilities translate="title" module="shipjunction_utilities">
|
6 |
+
<title>Shipjunction Utilites</title>
|
7 |
+
<model>Shipjunction_Utilities_Model_Objectmodel_Api</model>
|
8 |
+
<methods>
|
9 |
+
<sendShipmentEmail translate="title" module="shipjunction_utilities">
|
10 |
+
<title>Send Shipment Email</title>
|
11 |
+
<method>sendShipmentEmail</method>
|
12 |
+
</sendShipmentEmail>
|
13 |
+
<getClearpathOrderNumber translate="title" module="shipjunction_utilities">
|
14 |
+
<title>Get ClearPath Order Number</title>
|
15 |
+
<method>getClearpathOrderNumber</method>
|
16 |
+
</getClearpathOrderNumber>
|
17 |
+
<getEmbeddedErpFullStockOrders translate="title" module="shipjunction_utilities">
|
18 |
+
<title>Get Embedded Erp Orders which are fully stocked</title>
|
19 |
+
<method>getEmbeddedErpFullStockOrders</method>
|
20 |
+
</getEmbeddedErpFullStockOrders>
|
21 |
+
<getEmbeddedErpZonesAndBins translate="title" module="shipjunction_utilities">
|
22 |
+
<title>Get Embedded Erp zones and bins for a list of productIds</title>
|
23 |
+
<method>getEmbeddedErpZonesAndBins</method>
|
24 |
+
</getEmbeddedErpZonesAndBins>
|
25 |
+
<createInvoice translate="title" module="shipjunction_utilities">
|
26 |
+
<title>Create Invoice</title>
|
27 |
+
<method>createInvoice</method>
|
28 |
+
</createInvoice>
|
29 |
+
</methods>
|
30 |
+
</shipjunction_utilities>
|
31 |
+
</resources>
|
32 |
+
<resources_alias>
|
33 |
+
<shipjunctionUtilities>shipjunction_utilities</shipjunctionUtilities>
|
34 |
+
</resources_alias>
|
35 |
+
<v2>
|
36 |
+
<resources_function_prefix>
|
37 |
+
<shipjunctionUtilities>shipjunctionUtilities</shipjunctionUtilities>
|
38 |
+
</resources_function_prefix>
|
39 |
+
</v2>
|
40 |
+
</api>
|
41 |
+
</config>
|
app/code/local/Shipjunction/Utilities/etc/config.xml
ADDED
@@ -0,0 +1,24 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?xml version="1.0" encoding="UTF-8"?>
|
2 |
+
<config>
|
3 |
+
<modules>
|
4 |
+
<Shipjunction_Utilities>
|
5 |
+
<version>0.1.0</version>
|
6 |
+
</Shipjunction_Utilities>
|
7 |
+
</modules>
|
8 |
+
<global>
|
9 |
+
<models>
|
10 |
+
<shipjunction_utilities>
|
11 |
+
<!-- <modulename>-->
|
12 |
+
<class>Shipjunction_Utilities_Model</class>
|
13 |
+
</shipjunction_utilities>
|
14 |
+
<!-- </modulename>-->
|
15 |
+
</models>
|
16 |
+
</global>
|
17 |
+
<default>
|
18 |
+
<clearpath>
|
19 |
+
<general>
|
20 |
+
<clearpath_tablename>clearpath_ordernumber</clearpath_tablename>
|
21 |
+
</general>
|
22 |
+
</clearpath>
|
23 |
+
</default>
|
24 |
+
</config>
|
app/code/local/Shipjunction/Utilities/etc/system.xml
ADDED
@@ -0,0 +1,38 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?xml version="1.0"?>
|
2 |
+
<config>
|
3 |
+
<tabs>
|
4 |
+
<shipjunction translate="label">
|
5 |
+
<label>Shipjunction</label>
|
6 |
+
<sort_order>150</sort_order>
|
7 |
+
</shipjunction>
|
8 |
+
</tabs>
|
9 |
+
<sections>
|
10 |
+
<clearpath translate="label" module="adminhtml">
|
11 |
+
<label>Clearpath</label>
|
12 |
+
<tab>shipjunction</tab>
|
13 |
+
<sort_order>10</sort_order>
|
14 |
+
<show_in_default>1</show_in_default>
|
15 |
+
<show_in_website>1</show_in_website>
|
16 |
+
<show_in_store>1</show_in_store>
|
17 |
+
<groups>
|
18 |
+
<general translate="label">
|
19 |
+
<label>General</label>
|
20 |
+
<sort_order>50</sort_order>
|
21 |
+
<show_in_default>1</show_in_default>
|
22 |
+
<show_in_website>1</show_in_website>
|
23 |
+
<show_in_store>1</show_in_store>
|
24 |
+
<fields>
|
25 |
+
<clearpath_tablename translate="label">
|
26 |
+
<label>Clearpath table name</label>
|
27 |
+
<frontend_type>text</frontend_type>
|
28 |
+
<sort_order>10</sort_order>
|
29 |
+
<show_in_default>1</show_in_default>
|
30 |
+
<show_in_website>1</show_in_website>
|
31 |
+
<show_in_store>1</show_in_store>
|
32 |
+
</clearpath_tablename>
|
33 |
+
</fields>
|
34 |
+
</general>
|
35 |
+
</groups>
|
36 |
+
</clearpath>
|
37 |
+
</sections>
|
38 |
+
</config>
|
app/code/local/Shipjunction/Utilities/etc/wsdl.xml
ADDED
@@ -0,0 +1,153 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?xml version="1.0" encoding="UTF-8"?>
|
2 |
+
<definitions name="{{var wsdl.name}}" targetNamespace="urn:{{var wsdl.name}}" xmlns="http://schemas.xmlsoap.org/wsdl/" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:typens="urn:{{var wsdl.name}}" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
|
3 |
+
<types>
|
4 |
+
<schema targetNamespace="urn:{{var wsdl.name}}" xmlns:typens="urn:{{var wsdl.name}}">
|
5 |
+
<import namespace="http://schemas.xmlsoap.org/soap/encoding/" schemaLocation="http://schemas.xmlsoap.org/soap/encoding/"/>
|
6 |
+
<complexType name="productLocationZone">
|
7 |
+
<all>
|
8 |
+
<element name="productId" type="xsd:string"/>
|
9 |
+
<element name="location" type="xsd:string"/>
|
10 |
+
<element name="zone" type="xsd:string"/>
|
11 |
+
</all>
|
12 |
+
</complexType>
|
13 |
+
<complexType name="productLocationZoneArray">
|
14 |
+
<complexContent>
|
15 |
+
<restriction base="soapenc:Array">
|
16 |
+
<attribute ref="soapenc:arrayType" wsdl:arrayType="typens:productLocationZone[]"/>
|
17 |
+
</restriction>
|
18 |
+
</complexContent>
|
19 |
+
</complexType>
|
20 |
+
<complexType name="Map">
|
21 |
+
<sequence>
|
22 |
+
<element name="item" maxOccurs="unbounded" minOccurs="0">
|
23 |
+
<complexType>
|
24 |
+
<sequence>
|
25 |
+
<element name="key" type="xsd:string" maxOccurs="1" minOccurs="1"/>
|
26 |
+
<element name="value" type="xsd:string" maxOccurs="1" minOccurs="1"/>
|
27 |
+
</sequence>
|
28 |
+
</complexType>
|
29 |
+
</element>
|
30 |
+
</sequence>
|
31 |
+
</complexType>
|
32 |
+
</schema>
|
33 |
+
</types>
|
34 |
+
<message name="shipjunctionUtilitiesSendShipmentEmailRequest">
|
35 |
+
<part name="sessionId" type="xsd:string"/>
|
36 |
+
<part name="shipmentIncrementId" type="xsd:string"/>
|
37 |
+
</message>
|
38 |
+
<message name="shipjunctionUtilitiesSendShipmentEmailResponse">
|
39 |
+
<part name="result" type="xsd:string"/>
|
40 |
+
</message>
|
41 |
+
<message name="shipjunctionUtilitiesGetClearpathOrderNumberRequest">
|
42 |
+
<part name="sessionId" type="xsd:string"/>
|
43 |
+
<part name="_orderIncrementId" type="xsd:string"/>
|
44 |
+
</message>
|
45 |
+
<message name="shipjunctionUtilitiesGetClearpathOrderNumberResponse">
|
46 |
+
<part name="_cpOrderNumber" type="xsd:string"/>
|
47 |
+
</message>
|
48 |
+
<message name="shipjunctionUtilitiesGetEmbeddedErpFullStockOrdersRequest">
|
49 |
+
<part name="sessionId" type="xsd:string"/>
|
50 |
+
</message>
|
51 |
+
<message name="shipjunctionUtilitiesGetEmbeddedErpFullStockOrdersResponse">
|
52 |
+
<part name="incrementIdList" type="xsd:string"/>
|
53 |
+
</message>
|
54 |
+
<message name="shipjunctionUtilitiesGetEmbeddedErpZonesAndBinsRequest">
|
55 |
+
<part name="sessionId" type="xsd:string"/>
|
56 |
+
<part name="_productIdList" type="xsd:string"/>
|
57 |
+
</message>
|
58 |
+
<message name="shipjunctionUtilitiesGetEmbeddedErpZonesAndBinsResponse">
|
59 |
+
<part name="zonesBins" type="xsd:string"/>
|
60 |
+
</message>
|
61 |
+
<message name="shipjunctionUtilitiesCreateInvoiceRequest">
|
62 |
+
<part name="sessionId" type="xsd:string"></part>
|
63 |
+
<part name="orderIncrementId" type="xsd:string"></part>
|
64 |
+
<part name="itemsQty" type="typens:orderItemIdQtyArray"></part>
|
65 |
+
<part name="comment" type="xsd:string"></part>
|
66 |
+
<part name="email" type="xsd:string"></part>
|
67 |
+
<part name="includeComment" type="xsd:string"></part>
|
68 |
+
<part name="capture" type="xsd:string"></part>
|
69 |
+
</message>
|
70 |
+
<message name="shipjunctionUtilitiesCreateInvoiceResponse">
|
71 |
+
<part name="invoiceIncrementId" type="xsd:string"/>
|
72 |
+
</message>
|
73 |
+
<portType name="{{var wsdl.handler}}PortType">
|
74 |
+
<operation name="shipjunctionUtilitiesSendShipmentEmail">
|
75 |
+
<documentation>Send a shipment email by shipment incrementId</documentation>
|
76 |
+
<input message="typens:shipjunctionUtilitiesSendShipmentEmailRequest"/>
|
77 |
+
<output message="typens:shipjunctionUtilitiesSendShipmentEmailResponse"/>
|
78 |
+
</operation>
|
79 |
+
<operation name="shipjunctionUtilitiesGetClearpathOrderNumber">
|
80 |
+
<documentation>Get a ClearPath order number by Magento order number</documentation>
|
81 |
+
<input message="typens:shipjunctionUtilitiesGetClearpathOrderNumberRequest"/>
|
82 |
+
<output message="typens:shipjunctionUtilitiesGetClearpathOrderNumberResponse"/>
|
83 |
+
</operation>
|
84 |
+
<operation name="shipjunctionUtilitiesGetEmbeddedErpFullStockOrders">
|
85 |
+
<documentation>Get list of Embedded Erp fully stocked orders</documentation>
|
86 |
+
<input message="typens:shipjunctionUtilitiesGetEmbeddedErpFullStockOrdersRequest"/>
|
87 |
+
<output message="typens:shipjunctionUtilitiesGetEmbeddedErpFullStockOrdersResponse"/>
|
88 |
+
</operation>
|
89 |
+
<operation name="shipjunctionUtilitiesGetEmbeddedErpZonesAndBins">
|
90 |
+
<documentation>Get Embedded Erp zones and bins for list of products</documentation>
|
91 |
+
<input message="typens:shipjunctionUtilitiesGetEmbeddedErpZonesAndBinsRequest"/>
|
92 |
+
<output message="typens:shipjunctionUtilitiesGetEmbeddedErpZonesAndBinsResponse"/>
|
93 |
+
</operation>
|
94 |
+
<operation name="shipjunctionUtilitiesCreateInvoice">
|
95 |
+
<documentation>Create new invoice for order</documentation>
|
96 |
+
<input message="typens:shipjunctionUtilitiesCreateInvoiceRequest"></input>
|
97 |
+
<output message="typens:shipjunctionUtilitiesCreateInvoiceResponse"></output>
|
98 |
+
</operation>
|
99 |
+
</portType>
|
100 |
+
<binding name="{{var wsdl.handler}}Binding" type="typens:{{var wsdl.handler}}PortType">
|
101 |
+
<soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/>
|
102 |
+
<operation name="shipjunctionUtilitiesSendShipmentEmail">
|
103 |
+
<soap:operation soapAction="urn:{{var wsdl.handler}}Action"/>
|
104 |
+
<input>
|
105 |
+
<soap:body encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" namespace="urn:{{var wsdl.name}}" use="encoded"/>
|
106 |
+
</input>
|
107 |
+
<output>
|
108 |
+
<soap:body encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" namespace="urn:{{var wsdl.name}}" use="encoded"/>
|
109 |
+
</output>
|
110 |
+
</operation>
|
111 |
+
<operation name="shipjunctionUtilitiesGetClearpathOrderNumber">
|
112 |
+
<soap:operation soapAction="urn:{{var wsdl.handler}}Action"/>
|
113 |
+
<input>
|
114 |
+
<soap:body encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" namespace="urn:{{var wsdl.name}}" use="encoded"/>
|
115 |
+
</input>
|
116 |
+
<output>
|
117 |
+
<soap:body encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" namespace="urn:{{var wsdl.name}}" use="encoded"/>
|
118 |
+
</output>
|
119 |
+
</operation>
|
120 |
+
<operation name="shipjunctionUtilitiesGetEmbeddedErpFullStockOrders">
|
121 |
+
<soap:operation soapAction="urn:{{var wsdl.handler}}Action"/>
|
122 |
+
<input>
|
123 |
+
<soap:body encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" namespace="urn:{{var wsdl.name}}" use="encoded"/>
|
124 |
+
</input>
|
125 |
+
<output>
|
126 |
+
<soap:body encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" namespace="urn:{{var wsdl.name}}" use="encoded"/>
|
127 |
+
</output>
|
128 |
+
</operation>
|
129 |
+
<operation name="shipjunctionUtilitiesGetEmbeddedErpZonesAndBins">
|
130 |
+
<soap:operation soapAction="urn:{{var wsdl.handler}}Action"/>
|
131 |
+
<input>
|
132 |
+
<soap:body encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" namespace="urn:{{var wsdl.name}}" use="encoded"/>
|
133 |
+
</input>
|
134 |
+
<output>
|
135 |
+
<soap:body encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" namespace="urn:{{var wsdl.name}}" use="encoded"/>
|
136 |
+
</output>
|
137 |
+
</operation>
|
138 |
+
<operation name="shipjunctionUtilitiesCreateInvoice">
|
139 |
+
<soap:operation soapAction="urn:{{var wsdl.handler}}Action"/>
|
140 |
+
<input>
|
141 |
+
<soap:body encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" namespace="urn:{{var wsdl.name}}" use="encoded"/>
|
142 |
+
</input>
|
143 |
+
<output>
|
144 |
+
<soap:body encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" namespace="urn:{{var wsdl.name}}" use="encoded"/>
|
145 |
+
</output>
|
146 |
+
</operation>
|
147 |
+
</binding>
|
148 |
+
<service name="{{var wsdl.name}}Service">
|
149 |
+
<port binding="typens:{{var wsdl.handler}}Binding" name="{{var wsdl.handler}}Port">
|
150 |
+
<soap:address location="{{var wsdl.url}}"/>
|
151 |
+
</port>
|
152 |
+
</service>
|
153 |
+
</definitions>
|
package.xml
ADDED
@@ -0,0 +1,21 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?xml version="1.0"?>
|
2 |
+
<package>
|
3 |
+
<name>Shipjunction_Util</name>
|
4 |
+
<version>0.1.0</version>
|
5 |
+
<stability>stable</stability>
|
6 |
+
<license>Massachusetts Institute of Technology License (MITL)</license>
|
7 |
+
<channel>community</channel>
|
8 |
+
<extends/>
|
9 |
+
<summary>Shipjunction Utilities enables tight integration between the Magento and Shipjunction platforms</summary>
|
10 |
+
<description>ShipJunction is a multi-carrier shipping platform that provides unparalleled efficiency and optimization in the management of backend fulfillment processes and carrier expenses.
|
11 |
+

|
12 |
+
Supported Releases 1.5.0.0 & later
|
13 |
+
</description>
|
14 |
+
<notes>For more information contact us at info@shipjunction.com</notes>
|
15 |
+
<authors><author><name> ShipJunction</name><user>shipjunction</user><email>dev@shipjunction.com</email></author></authors>
|
16 |
+
<date>2014-02-14</date>
|
17 |
+
<time>00:01:11</time>
|
18 |
+
<contents><target name="magelocal"><dir name="Shipjunction"><dir name="Utilities"><dir name="Model"><dir name="Objectmodel"><dir name="Api"><file name="V2.php" hash="c72849bd552b06b397854eb0327cab1a"/></dir><file name="Api.php" hash="70f1f62424a3f8b489e5a8f223d5e60c"/><file name="test.php" hash="3540a784ed1d7718ac71de641a5ebed6"/><file name="test_ordinc_id.php" hash="f57e53a52e00a157413aaa9ecf575462"/><file name="xmlreturned.xml" hash="e59322fac4773ec2b62db3b88a792676"/></dir></dir><dir name="etc"><file name="adminhtml.xml" hash="8bd8b8559228898482f0350c88abbf2c"/><file name="api.xml" hash="0b54268c9e7a49ad5b2a980facf67ea8"/><file name="config.xml" hash="61dbf18db5f93e7c2f0d233db70d0cfa"/><file name="system.xml" hash="9a1e37f245ae223621bdaede1ac2e329"/><file name="wsdl.xml" hash="3e61b422ba97b24b96172f1265bef8e1"/></dir></dir></dir></target></contents>
|
19 |
+
<compatible/>
|
20 |
+
<dependencies><required><php><min>5.0.0</min><max>6.0.0</max></php></required></dependencies>
|
21 |
+
</package>
|