Version Notes
Support Sandbox first enrollment, make Sandbox the default env, and always show the config form
Download this release
Release Info
Developer | Riskified_Mage |
Extension | riskified_magento |
Version | 1.0.6.5 |
Comparing to | |
See all releases |
Code changes from version 1.0.6.4 to 1.0.6.5
- app/code/community/Riskified/Full/.DS_Store +0 -0
- app/code/community/Riskified/Full/etc/config.xml +2 -2
- app/design/adminhtml/default/default/template/full/jsinit.phtml +0 -1
- lib/riskified_php_sdk/src/Riskified/.DS_Store +0 -0
- lib/riskified_scripts/riskified_historical_upload.php +69 -0
- package.xml +5 -8
app/code/community/Riskified/Full/.DS_Store
ADDED
Binary file
|
app/code/community/Riskified/Full/etc/config.xml
CHANGED
@@ -2,7 +2,7 @@
|
|
2 |
<config>
|
3 |
<modules>
|
4 |
<Riskified_Full>
|
5 |
-
<version>1.0.6.
|
6 |
</Riskified_Full>
|
7 |
</modules>
|
8 |
|
@@ -283,7 +283,7 @@
|
|
283 |
<fullsection>
|
284 |
<full>
|
285 |
<order_status_sync>0</order_status_sync>
|
286 |
-
<env>
|
287 |
<beaconurl>beacon.riskified.com</beaconurl>
|
288 |
<auto_invoice_enabled>0</auto_invoice_enabled>
|
289 |
<auto_invoice_capture_case>online</auto_invoice_capture_case>
|
2 |
<config>
|
3 |
<modules>
|
4 |
<Riskified_Full>
|
5 |
+
<version>1.0.6.5</version>
|
6 |
</Riskified_Full>
|
7 |
</modules>
|
8 |
|
283 |
<fullsection>
|
284 |
<full>
|
285 |
<order_status_sync>0</order_status_sync>
|
286 |
+
<env>SANDBOX</env>
|
287 |
<beaconurl>beacon.riskified.com</beaconurl>
|
288 |
<auto_invoice_enabled>0</auto_invoice_enabled>
|
289 |
<auto_invoice_capture_case>online</auto_invoice_capture_case>
|
app/design/adminhtml/default/default/template/full/jsinit.phtml
CHANGED
@@ -239,7 +239,6 @@ document.observe("dom:loaded", function() {
|
|
239 |
rhtml += '<div id="riskified-header" style="font-family:Helvetica Neue; font-size: 19px; line-height: 23px; color: #393536;margin-bottom: 25px;">The extension is connected to your Riskified account</div>';
|
240 |
rhtml += '<a class="riskified-botton" style="margin-bottom:30px" href="//<?php echo Mage::helper('full/order')->getRiskifiedApp()?>" target="_blank">Go to Riskified App</a>';
|
241 |
}else{
|
242 |
-
section.style.display = "none";
|
243 |
$$(".entry-edit-head.collapseable")[0].style.display = "none";
|
244 |
}
|
245 |
htmlBody = rhtml;
|
239 |
rhtml += '<div id="riskified-header" style="font-family:Helvetica Neue; font-size: 19px; line-height: 23px; color: #393536;margin-bottom: 25px;">The extension is connected to your Riskified account</div>';
|
240 |
rhtml += '<a class="riskified-botton" style="margin-bottom:30px" href="//<?php echo Mage::helper('full/order')->getRiskifiedApp()?>" target="_blank">Go to Riskified App</a>';
|
241 |
}else{
|
|
|
242 |
$$(".entry-edit-head.collapseable")[0].style.display = "none";
|
243 |
}
|
244 |
htmlBody = rhtml;
|
lib/riskified_php_sdk/src/Riskified/.DS_Store
ADDED
Binary file
|
lib/riskified_scripts/riskified_historical_upload.php
ADDED
@@ -0,0 +1,69 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
// if this is not run from the Magento root, use chdir() to move execution back.
|
3 |
+
//chdir('../magento/');
|
4 |
+
|
5 |
+
set_include_path(dirname(__FILE__) . PATH_SEPARATOR . get_include_path());
|
6 |
+
require 'app/Mage.php';
|
7 |
+
|
8 |
+
umask (0);
|
9 |
+
Mage::app(); // can set the run code/type, just like in the Mage::run() call
|
10 |
+
|
11 |
+
$helper = Mage::helper('full');
|
12 |
+
$authToken = $helper->getAuthToken();
|
13 |
+
$env = constant($helper->getConfigEnv());
|
14 |
+
$domain = $helper->getShopDomain();
|
15 |
+
|
16 |
+
echo "Riskified auth token: $authToken \n";
|
17 |
+
echo "Riskified shop domain: $domain \n";
|
18 |
+
echo "Riskified target environment: $env \n";
|
19 |
+
echo "*********** \n";
|
20 |
+
include __DIR__ . 'lib/riskified_php_sdk/src/Riskified/autoloader.php';
|
21 |
+
use Riskified\Common\Riskified;
|
22 |
+
use Riskified\Common\Env;
|
23 |
+
use Riskified\Common\Validations;
|
24 |
+
use Riskified\Common\Signature;
|
25 |
+
use Riskified\OrderWebhook\Model;
|
26 |
+
use Riskified\OrderWebhook\Transport;
|
27 |
+
|
28 |
+
Riskified::init($domain, $authToken, $env, Validations::SKIP);
|
29 |
+
// add your own code below:
|
30 |
+
$batch_size = 10;
|
31 |
+
$options = getopt("p::");
|
32 |
+
$page = intval($options["p"]);
|
33 |
+
if (!$page) {
|
34 |
+
$page = 1;
|
35 |
+
}
|
36 |
+
$orders = Mage::getModel('sales/order')->getCollection();
|
37 |
+
|
38 |
+
$total_count = $orders->getSize();
|
39 |
+
|
40 |
+
echo "starting to upload orders, total_count: $total_count \n";
|
41 |
+
|
42 |
+
$orders_collection = Mage::getModel('sales/order')
|
43 |
+
->getCollection()
|
44 |
+
->setPageSize($batch_size)
|
45 |
+
->setCurPage($page);
|
46 |
+
|
47 |
+
$total_uploaded = 0;
|
48 |
+
|
49 |
+
while ($total_uploaded < $total_count) {
|
50 |
+
$last_id = $orders_collection->getLastItem()->getEntityId();
|
51 |
+
|
52 |
+
try {
|
53 |
+
Mage::helper('full/order')->postHistoricalOrders($orders_collection);
|
54 |
+
$total_uploaded += $orders_collection->count();
|
55 |
+
echo "last id: $last_id, page:$page, total_uploaded: $total_uploaded \n";
|
56 |
+
$page++;
|
57 |
+
$orders_collection = Mage::getModel('sales/order')
|
58 |
+
->getCollection()
|
59 |
+
->setPageSize($batch_size)
|
60 |
+
->setCurPage($page);
|
61 |
+
} catch (Exception $e) {
|
62 |
+
echo "Error: ".$e->getMessage();
|
63 |
+
exit(1);
|
64 |
+
}
|
65 |
+
}
|
66 |
+
echo "*********** \n";
|
67 |
+
echo "wOOt, Finished successfully!!!! total_uploaded: $total_uploaded\n";
|
68 |
+
echo "Please let us know and we will process the order within 24 hours, Thanks!!\n";
|
69 |
+
?>
|
package.xml
CHANGED
@@ -1,7 +1,7 @@
|
|
1 |
<?xml version="1.0"?>
|
2 |
<package>
|
3 |
<name>riskified_magento</name>
|
4 |
-
<version>1.0.6.
|
5 |
<stability>stable</stability>
|
6 |
<license>OSL v3.0</license>
|
7 |
<channel>community</channel>
|
@@ -9,14 +9,11 @@
|
|
9 |
<summary>Riskified Magento extension</summary>
|
10 |
<description>Riskified reviews, approves & guarantees
|
11 |
transactions you would otherwise decline.</description>
|
12 |
-
<notes
|
13 |
-
* Support for Transarmor gateway
|
14 |
-
* New integration process support
|
15 |
-
* Historical orders script upgraded</notes>
|
16 |
<authors><author><name>Riskified_Mage</name><user>Riskified_Mage</user><email>support@riskified.com</email></author></authors>
|
17 |
-
<date>2015-
|
18 |
-
<time>
|
19 |
-
<contents><target name="magecommunity"><dir name="Riskified"><dir name="Full"><dir><dir name="Helper"><file name="Data.php" hash="2d3f448cc5a13b49950826af2cd07148"/><file name="Debug.php" hash="18335d988a142ee639ea59dbecafa15c"/><file name="Log.php" hash="14125243576ab5b08f40066d24b7241d"/><dir name="Order"><file name="Invoice.php" hash="fd6fcbdedd44551785eddd0e1a482e80"/><file name="Status.php" hash="201a5c07c1d0d0b0a15d3bfb94a46d4b"/></dir><file name="Order.php" hash="5a7c1c431fb7a8c7dccbee1f78d41f65"/></dir><dir name="Model"><file name="Authorizenet.php" hash="bd42f62d06a036b9da7709d2e40fc8f1"/><file name="Cron.php" hash="187b86ebe9238ff132ed0337f05a8ae9"/><file name="Observer.php" hash="f15afcb69bf13683d637b293fbdf1a6c"/><dir name="Resource"><dir name="Retry"><file name="Collection.php" hash="fd62ad4e4cdd8d372751bfa9988cc3a9"/></dir><file name="Retry.php" hash="3be3db7e54bd8bb45e0faffa1941f515"/></dir><file name="Retry.php" hash="89e7344139affa4fe0b9a252a5d1c592"/><dir name="System"><dir name="Config"><dir name="Source"><file name="ApprovedState.php" hash="5c620d1039347218354bd58c2238ecb4"/><file name="CaptureCase.php" hash="daafa6f53c65fa6e6e7ffbb067dbbbba"/><file name="DeclinedState.php" hash="a00907072c06ade079483e3db03bb94f"/><file name="Env.php" hash="4d923355b3e56fac95c2a9b3c353ab76"/></dir></dir></dir></dir><dir name="Test"><dir name="Config"><file name="General.php" hash="a5d4950c5655960879e7d75c06977941"/></dir><dir name="Helper"><dir name="General"><dir name="fixtures"><file name="extensionConfigEnabled.yaml" hash="eec8c8d8a1d5de49897b19740cf8e074"/></dir></dir><file name="General.php" hash="607c9711656be48084f6688e114b6bf6"/></dir><dir name="Model"><file name="Environments.php" hash="f3fc028d17c82b9b84b709b932e64eae"/></dir></dir><dir name="controllers"><dir name="Adminhtml"><file name="FullController.php" hash="f80e78a808e99f11a7bc00bd02be3f2e"/></dir><file name="ResponseController.php" hash="550c29c6c6706067bac3531b8f3eb37f"/></dir><dir name="etc"><file name="config.xml" hash="
|
20 |
<compatible/>
|
21 |
<dependencies><required><php><min>4.4.0</min><max>6.0.0</max></php></required></dependencies>
|
22 |
</package>
|
1 |
<?xml version="1.0"?>
|
2 |
<package>
|
3 |
<name>riskified_magento</name>
|
4 |
+
<version>1.0.6.5</version>
|
5 |
<stability>stable</stability>
|
6 |
<license>OSL v3.0</license>
|
7 |
<channel>community</channel>
|
9 |
<summary>Riskified Magento extension</summary>
|
10 |
<description>Riskified reviews, approves & guarantees
|
11 |
transactions you would otherwise decline.</description>
|
12 |
+
<notes>Support Sandbox first enrollment, make Sandbox the default env, and always show the config form</notes>
|
|
|
|
|
|
|
13 |
<authors><author><name>Riskified_Mage</name><user>Riskified_Mage</user><email>support@riskified.com</email></author></authors>
|
14 |
+
<date>2015-03-03</date>
|
15 |
+
<time>07:02:31</time>
|
16 |
+
<contents><target name="magecommunity"><dir name="Riskified"><dir name="Full"><dir><dir name="Helper"><file name="Data.php" hash="2d3f448cc5a13b49950826af2cd07148"/><file name="Debug.php" hash="18335d988a142ee639ea59dbecafa15c"/><file name="Log.php" hash="14125243576ab5b08f40066d24b7241d"/><dir name="Order"><file name="Invoice.php" hash="fd6fcbdedd44551785eddd0e1a482e80"/><file name="Status.php" hash="201a5c07c1d0d0b0a15d3bfb94a46d4b"/></dir><file name="Order.php" hash="5a7c1c431fb7a8c7dccbee1f78d41f65"/></dir><dir name="Model"><file name="Authorizenet.php" hash="bd42f62d06a036b9da7709d2e40fc8f1"/><file name="Cron.php" hash="187b86ebe9238ff132ed0337f05a8ae9"/><file name="Observer.php" hash="f15afcb69bf13683d637b293fbdf1a6c"/><dir name="Resource"><dir name="Retry"><file name="Collection.php" hash="fd62ad4e4cdd8d372751bfa9988cc3a9"/></dir><file name="Retry.php" hash="3be3db7e54bd8bb45e0faffa1941f515"/></dir><file name="Retry.php" hash="89e7344139affa4fe0b9a252a5d1c592"/><dir name="System"><dir name="Config"><dir name="Source"><file name="ApprovedState.php" hash="5c620d1039347218354bd58c2238ecb4"/><file name="CaptureCase.php" hash="daafa6f53c65fa6e6e7ffbb067dbbbba"/><file name="DeclinedState.php" hash="a00907072c06ade079483e3db03bb94f"/><file name="Env.php" hash="4d923355b3e56fac95c2a9b3c353ab76"/></dir></dir></dir></dir><dir name="Test"><dir name="Config"><file name="General.php" hash="a5d4950c5655960879e7d75c06977941"/></dir><dir name="Helper"><dir name="General"><dir name="fixtures"><file name="extensionConfigEnabled.yaml" hash="eec8c8d8a1d5de49897b19740cf8e074"/></dir></dir><file name="General.php" hash="607c9711656be48084f6688e114b6bf6"/></dir><dir name="Model"><file name="Environments.php" hash="f3fc028d17c82b9b84b709b932e64eae"/></dir></dir><dir name="controllers"><dir name="Adminhtml"><file name="FullController.php" hash="f80e78a808e99f11a7bc00bd02be3f2e"/></dir><file name="ResponseController.php" hash="550c29c6c6706067bac3531b8f3eb37f"/></dir><dir name="etc"><file name="config.xml" hash="e8508707f181d416e892295153e366fa"/><file name="system.xml" hash="9ed5ff1209c08a7babb0e286804c1f9b"/></dir><dir name="sql"><dir name="riskified_full_setup"><file name="mysql4-install-1.0.1.php" hash="6d29dde79353e8bfefa6ea7bc2ef562a"/><file name="mysql4-upgrade-1.0.2.0-1.0.2.1.php" hash="822e85326678a320f141a3ae948e4a24"/><file name="mysql4-upgrade-1.0.4-1.0.5.0.php" hash="557115e1a978d9b194b2cd1cfb8b5a95"/><file name="mysql4-upgrade-1.0.5.5-1.0.6.0.php" hash="0318846fbe8f3e56d8f7d3fdc750e102"/></dir></dir></dir><file name=".DS_Store" hash="715cd4ccc06f4d229c9e00b8f6557eb0"/></dir></dir></target><target name="mageetc"><dir name="modules"><file name="Riskified_Full.xml" hash="d684caecdf710e5d0173ca07e5c5d1c0"/></dir></target><target name="magedesign"><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="layout"><file name="full.xml" hash="8dbb3dd16fcb5821eb07e9b5d978d55c"/></dir><dir name="template"><dir name="full"><file name="jsinit.phtml" hash="6d115f22624a7a4e9841888ba5df35cb"/></dir></dir></dir></dir></dir><dir name="frontend"><dir name="base"><dir name="default"><dir name="layout"><file name="full.xml" hash="9497753e5c3d2860062c5446c058b4bc"/></dir><dir name="template"><dir name="full"><file name="riskified.phtml" hash="fe4a577c6ef98316d906c36c17f11406"/></dir></dir></dir></dir></dir></target><target name="mageskin"><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="images"><dir name="riskified"><file name="logo.jpg" hash="0ac96bf07aa8b8ecb3ff06c2ccbf0827"/></dir></dir></dir></dir></dir></target><target name="magelib"><dir name="riskified_php_sdk"><file name="README.md" hash="f37118baa641e4ef6d670bb1c0298482"/><dir><dir name="sample"><file name="callback.php" hash="c6fb5a90b2c527b794fcec803acb36d9"/><file name="order_full_flow.php" hash="71d931fff3aa98402c9a7d3b271a6ae4"/><file name="order_marketplace_create.php" hash="ae3d2fb28154a710934d6243302a590d"/><file name="order_simple_submit.php" hash="d8458f7992b486b6dac28558526f068b"/><file name="run_callback_server.sh" hash="8202fd93c15e088d072805d3a2f4c02b"/><file name="upload_historical.php" hash="78bdb85c036183de16968a79c8836efd"/></dir><dir name="src"><dir name="Riskified"><dir name="Common"><file name="Env.php" hash="3fc8342a423141fb0c110901deebfe25"/><dir name="Exception"><file name="BaseException.php" hash="ce902d0a3bd9af53b3c1923541602ead"/></dir><file name="Riskified.php" hash="2137e73cf6371aeb113a6755357b603f"/><dir name="Signature"><file name="HttpDataSignature.php" hash="b9f5d57db1903126a72eb38ca55ba878"/></dir><file name="Validations.php" hash="4af37b31901f215b660c868c31594b75"/></dir><dir name="DecisionNotification"><dir name="Exception"><file name="AuthorizationException.php" hash="4cab71ac324efd3b29bdfa6236a8f531"/><file name="BadHeaderException.php" hash="407a0d9e94d52e8b43bed02e34bd4a70"/><file name="BadPostJsonException.php" hash="2e2a7f84fae19fd525f01f6899ea218b"/><file name="NotificationException.php" hash="8f7d1ed8b9523ec66423c6ff2703085f"/></dir><dir name="Model"><file name="Notification.php" hash="9e2f5fd421abe37ab7b742767966f312"/></dir></dir><dir name="OrderWebhook"><dir name="Exception"><file name="ClassMismatchPropertyException.php" hash="8854b7aea6736b290826eb44ac0ba578"/><file name="CurlException.php" hash="27488d2dd0fa2c25b647a5967e3821b1"/><file name="FormatMismatchPropertyException.php" hash="2729989c3ac2a245341fd01a4d004b49"/><file name="InvalidPropertyException.php" hash="97084ff2ff33f5c657c5876a44aa97d2"/><file name="MalformedJsonException.php" hash="8c795b605988f20f1899dcf160f29cf1"/><file name="MissingPropertyException.php" hash="5ad8df6ba645a113fac7b65e08167d2c"/><file name="MultiplePropertiesException.php" hash="aaa042c5a0fcfd15dc2744059b15798b"/><file name="PropertyException.php" hash="7a234406434c5616aab72da27a1ed6ed"/><file name="TypeMismatchPropertyException.php" hash="5eed61220c954a462411f433a2c85bf2"/><file name="UnsuccessfulActionException.php" hash="b02fafbda955fa889ca36c5092ccc68d"/></dir><dir name="Model"><file name="AbstractModel.php" hash="73adfaac9fe9e189827baac5a71e41a4"/><file name="Address.php" hash="68d2ed178575374f2b6f7701b6f30cd9"/><file name="Attribute.php" hash="e7fa146d7c9c807494c225e6a41afcfb"/><file name="AuthorizationError.php" hash="b82229eff42d94ceba58d4d6a3a4118b"/><file name="Checkout.php" hash="ede0e6d2fd8319ada669de35b4c3190f"/><file name="ClientDetails.php" hash="50b329fa6b77bcbeff4b725705b957af"/><file name="Customer.php" hash="02801c70557fbfa6aea7ac6058f6f4b4"/><file name="DiscountCode.php" hash="0861920950828a3ff19904b92b4cb50d"/><file name="Fulfillment.php" hash="9111db9b13ae7b2fbe6bf806a66d78f2"/><file name="FulfillmentDetails.php" hash="d3c11d4e8943862fc4a774f3f8e9d7d7"/><file name="LineItem.php" hash="3a03c75348060aa9ca930174b9d5dc56"/><file name="Order.php" hash="d32cd686532d5cc2810321c5befe3149"/><file name="OrderCancellation.php" hash="f6f2d5234bb98b56902e632fbccc07b3"/><file name="PaymentDetails.php" hash="413b5a6ab26ec6b9b0664a9d9e301c02"/><file name="Refund.php" hash="1c3ad264984585cfcefc909ffa708dc4"/><file name="RefundDetails.php" hash="f9a0e27e26bbfb6699bb0dd44fe6a184"/><file name="Seller.php" hash="2dd5dc2dc22582231263cad803149a16"/><file name="ShippingLine.php" hash="5ac14361474789db570fa6d14b17a973"/><file name="SocialDetails.php" hash="8a9296a4277a645bb86f5956b7437081"/><file name="TaxLine.php" hash="59f82a19bc9ada690aa79bc96307db5e"/></dir><dir name="Transport"><file name="AbstractTransport.php" hash="4ab3636ee044c9272542ce8076ac8d33"/><file name="CurlTransport.php" hash="ecfb195ac0f8f9599dd859dffc40c968"/></dir></dir><file name="autoloader.php" hash="f3471e90daf6184a096d337bbcd40bd1"/><file name=".DS_Store" hash="cb0eca70daefed8b870bdb3fe4b6c9e5"/></dir></dir></dir><file name=".gitignore" hash="73f01e1298c44b6cc3e24a70cad8c56c"/></dir><dir name="riskified_scripts"><file name="riskified_historical_upload.php" hash="db28908aa4d29a78b712057fa60924fb"/></dir></target></contents>
|
17 |
<compatible/>
|
18 |
<dependencies><required><php><min>4.4.0</min><max>6.0.0</max></php></required></dependencies>
|
19 |
</package>
|