X-Cart: shopping cart software

X-Cart forums (https://forum.x-cart.com/index.php)
-   Third Party Add-Ons for X-Cart 4 (https://forum.x-cart.com/forumdisplay.php?f=45)
-   -   Shipstation? (https://forum.x-cart.com/showthread.php?t=66369)

TA 09-11-2015 09:47 AM

Re: Shipstation?
 
Shipstation has discontinued Endicia integration in favor of Stamps.com.

I wish TrueShip or other shipping modules had an X-Cart integration with Endicia.

vulcan-works 03-27-2018 03:58 PM

Re: Shipstation?
 
Is the xcart connector going to be updated for 4.7.9?
There were major changes made to tracking in 4.7.6 and orders are no longer being updated.

Errors being generated:
Logged as :
SQL query : UPDATE xcart_orders SET status='C', tracking='XXXXXXXXXX' WHERE orderid='19981'
Error code : 1054
Description : Unknown column 'tracking' in 'field list'

vulcan-works 03-28-2018 10:01 AM

Re: Shipstation?
 
Figured out what needed to be changed to work in 4.7.6+ in case anybody else runs into this.
Replace:
Code:

db_query("UPDATE xcart_orders SET status='C', tracking='$comments' WHERE orderid='". $result_ordercheck['orderid'] ."'");
WITH:
Code:

db_query("UPDATE xcart_orders SET status='C' WHERE orderid='". $result_ordercheck['orderid'] ."'");
db_query("INSERT INTO xcart_order_tracking_numbers (orderid, tracking) VALUES ('". $result_ordercheck['orderid'] ."', '$comments')");


shipstation2018 04-11-2018 07:32 AM

Re: Shipstation?
 
Hello!

The X-Cart 4 connector for ShipStation has been updated to support the most recent release of 4.7.9!



Cheers,

ShipStation

keystone 04-17-2019 10:03 AM

Re: Shipstation?
 
I'm using shipstation, it works great. However I was wondering if anyone who had different membership levels has been able to have that info imported into shipstation? It would be great to be able to filter orders and shipping reports based on membership lever, ie wholesale vs. retail customers. Shipstation says that currently x-cart doesn't submit that info so they can't set up a filter for it.

Anyone else try this?

aim 04-19-2019 07:09 AM

Re: Shipstation?
 
1 Attachment(s)
Quote:

Originally Posted by keystone
I'm using shipstation, it works great. However I was wondering if anyone who had different membership levels has been able to have that info imported into shipstation? It would be great to be able to filter orders and shipping reports based on membership lever, ie wholesale vs. retail customers. Shipstation says that currently x-cart doesn't submit that info so they can't set up a filter for it.

Anyone else try this?


Hello,

I have prepared a patch according to the man
https://help.shipstation.com/hc/en-us/articles/360025856192

Thank you.

keystone 04-19-2019 10:52 AM

Re: Shipstation?
 
Hi AIM,
Thanks for the patch, I installed it however it doesn't seem to be passing the variable membership or membershipid. It does pull Membershipid- into custom field 2 but after the - it is blank and custom field 1 is also blank on all the orders. Any ideas? When I pull the membership info into my invoices I used $_userinfo.membership could that be used instead maybe?

keystone 04-19-2019 01:01 PM

Re: Shipstation?
 
I got it, it should be
Code:

                        AddFieldToXML("CustomField1", $order['order']['membership']);
                        AddFieldToXML("CustomField2", 'Membershipid-' . $order['order']['membershipid']);


aim 04-21-2019 08:26 PM

Re: Shipstation?
 
Hello,

Thank you for the fix.

I have updated my post.

keystone 10-31-2019 09:24 AM

Re: Shipstation?
 
I just upgraded my site to php7.3 x-cart version 4.7.11 and am having an issue with Shipstation not posting back the tracking info. I get an error
Quote:

Warning: A non-numeric value encountered in /home/uscandle/public_html.dev/include/func/func.logging.php on line 534

Here is the function in question from func.logging.php...
Code:

function func_array_compare($orig, $new)
{
    $result = array (
        'removed' => false,
        'added' => false,
        'delta' => false,
        'changed' => false
    );

    $keys = array();
    if (is_array($orig)) $keys = array_keys($orig);
    if (is_array($new)) $keys = array_merge($keys, array_keys($new));
    $keys = array_unique($keys);

    foreach ($keys as $key) {
        $in_orig = isset($orig[$key]);
        $in_new = isset($new[$key]);

        if ($in_orig && !$in_new) {
            $result['removed'][$key] = $orig[$key];
        }
        elseif (!$in_orig && $in_new) {
            $result['added'][$key] = $new[$key];
        }
        else {
            // check for changed values
            if (!is_array($new[$key])) {
                if (!strcmp((string)$orig[$key], (string)$new[$key])) {
                    continue;
                }

                $is_numeric = preg_match('!^((\d+)|(\d+\.\d+))$!S', $new[$key]);

                if ($is_numeric) {
                    $result['delta'][$key] = $new[$key] - $orig[$key];            <------------- Line 534
                }

                $result['changed'][$key] = $new[$key];
            }
            else {
                $tmp = func_array_compare($orig[$key],$new[$key]);

                foreach ($tmp as $tmp_key=>$tmp_value) {
                    if ($tmp_value === false) continue;

                    $result[$tmp_key][$key] = $tmp_value;
                }
            }
        }
    }

    // remove not used arrays
    foreach ($result as $k=>$v) {
        if ($v === false)
            unset($result[$k]);
    }

    return $result;
}


and then I also get this warning as well...

Quote:

Warning: ini_set(): Headers already sent. You cannot change the session module's ini settings at this time in /home/uscandle/public_html/include/sessions.php on line 75


here is the code for sessions.php
Code:

* PHP build-in sessions tuning (for type '1' & '2')
 */

// PHP 4.3.0 and higher allow to turn off trans-sid using this command:
ini_set('url_rewriter.tags','');
// Let's garbage collection will occurs more frequently
ini_set('session.gc_probability',90);                        <-------------------Line 75
ini_set('session.gc_divisor',100); // for PHP >= 4.3.0
ini_set('session.use_cookies', false);


Any idea how to fix these errors?

Thanks.


All times are GMT -8. The time now is 07:10 PM.

Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.