2

I wish to use the UK Initial CityLink courier, as the shipment provider. Does anyone know anything on integrating with their systems, such as an extension or plug-in?

If not, how can we add a new carrier to the list, so we can manually add a tracking number to the order. That the customer can use - to track their order on the CityLink website.

Daniel Widdis
  • 8,424
  • 13
  • 41
  • 63
mattpark22
  • 741
  • 2
  • 14
  • 26

5 Answers5

3

Add a new active/inactive carrier in config

<default>
        <carriers>
            <your_carrier>
                <active>0|1</active>
                <model>your_module/your_carrier</model>
                <title>Your Carrier</title>
                <name>your_carrier</name>
                <price>0.00</price>
            </your_carrier>
        </carriers>
</default>

Then in your model your_module/your_carrier which extends Mage_Shipping_Model_Carrier_Abstract, rewrite the method isTrackingAvailable to return true:

public function isTrackingAvailable()
{
    return true;
}
mimarcel
  • 695
  • 7
  • 20
0

I hope you are in for a shock - most carriers work well to get your business and have backend systems that work well. CityLink are in the era of having bespoke Visual Basic applications running on a 486 PC with a dot-matrix printer. I exaggerate but you get the idea.

We wrote our own CityLink module to work on their zone rates taking volumetric measurements into account and checking that we did not exceed the maximum dimensions.

This requires the rates to be manually entered and does not print labels or anything fancy - the customer gets an accurate quote though.

I think they have tidied up their rates to being sensible enough to use the standard table rates of Magento, you can also enter in the tracking number at delivery time when you 'create delivery'.

ʍǝɥʇɐɯ
  • 4,012
  • 7
  • 32
  • 53
  • Mathew, have you released the module yet? Could the existing table rates module be used instead? – clockworkgeek Jul 12 '11 at 18:31
  • @clockworkgeek For most applications 'table rates' will give an accurate quote with CityLink as the zones are quite straightforward - I think you could even do 'London Congestion Zone' on the postcode to take account of that surcharge. As for my module, it does volumetric for international orders and has freight rates for bulky stuff. This requires dimension attributes that most people don't have. If I was a bit more forceful I should get it printing labels and placing collection info with CityLink but I could not impress on them the virtues of a 'Magento module' at the time. – ʍǝɥʇɐɯ Jul 12 '11 at 18:58
-2

Your best bet would be installing Parcelhub software to integrate multiple carriers into your Magento account.

-3

if you are going to modify function getCarriers() as suggested by Rashid, note that this function is repeated in several places:

 \app\code\core\Mage\Adminhtml\Block\Sales\Order\Invoice\Create\Tracking.php 
 \app\code\core\Mage\Adminhtml\Block\Sales\Order\Shipment\Create\Tracking.php 
 \app\code\core\Mage\Adminhtml\Block\Sales\Order\Shipment\View\Tracking.php 
 \app\code\core\Mage\Sales\Model\Order\Shipment\Api.php 
Mustapha George
  • 2,497
  • 9
  • 47
  • 79
  • Under no circumstances should you be editing core files. This will render your website unable to update safely, amongst other issues. – Mike Jan 16 '17 at 23:38
-5

To add new carrier in the listSimply edit the tracking.php file from directory app/code/core/Mage/Adminhtml/Block/Sales/Order/Shipment/Create/

find the code

public function getCarriers()
    {
        $carriers = array();
        $carrierInstances = Mage::getSingleton('shipping/config')->getAllCarriers(
            $this->getShipment()->getStoreId()
        );
        $carriers['custom'] = Mage::helper('sales')->__('CustomValue');

and then make copy of the last line i.e

$carriers['custom'] = Mage::helper('sales')->__('CustomValue');  

Now chage 'custom' with your 'customvalue' and 'CustomValue' with your own Custom Label e.g

$carriers['firstflight'] = Mage::helper('sales')->__('First Flight Courier');

Hope it will help you!!

Rashid
  • 135
  • 1
  • 8
  • 2
    Editing core files is not recommended in Magento. You should make the changes through class rewriting or observers. I didn't test it, but rewriting Mage::getSingleton('shipping/config')->getAllCarriers should work. – mimarcel Oct 13 '14 at 08:28