VirtueMart Forum

VirtueMart 2 + 3 + 4 => 3rd party extension => Topic started by: GJC Web Design on April 22, 2016, 15:10:42 PM

Title: Canada Post Virtuemart 3 Plugin
Post by: GJC Web Design on April 22, 2016, 15:10:42 PM
The Virtuemart 3 Canada Post Shipping Plugin

This is the VirtueMart 3 Canada Post Shipping Plugin that returns live rates from Canada Post based on postcodes and weight.

Installs as native Joomla 3 Plugin.

You can download it here - The Virtuemart 3 Canada Post Shipping Plugin (http://www.gjcwebdesign.com/vm3-2-canada-post-shipping.html)


Download our Virtuemart 3 Canada Post Shipping Plugin Instruction PDF (http://www.gjcwebdesign.com/eximg/canada_post/GJC_CanadaPost_Virtuemart_3.pdf) to see everything you need to know about it.

(http://www.gjcwebdesign.com/eximg/canada_post/canpost-vm-pic.jpg)
Title: Re: Canada Post Virtuemart 3 Plugin
Post by: ddrapeau on May 21, 2016, 02:26:29 AM
After years of jerry-rigging shipping rules, finally a Canada post shipping module!  I've tried this shipping module out and it works great. The instructions were pretty easy to understand. (Only error was that you need a Canada post business account for the module, and that was not specified.) Otherwise everything has been excellent. GJC Web Design even pro-actively offered me a free re-download when they updated the module to display estimated arrival time.
Title: Re: Canada Post Virtuemart 3 Plugin
Post by: julash on July 17, 2016, 15:30:10 PM
Is there any demo site?

Thanks
Julash
Title: Re: Canada Post Virtuemart 3 Plugin
Post by: GJC Web Design on July 20, 2016, 16:18:52 PM
sent you an email
Title: Re: Canada Post Virtuemart 3 Plugin
Post by: Macs_Upcycling on August 14, 2016, 14:02:39 PM
Re: Canada Post plugin for VM3. Canada Post uses the following criteria when calculating shipping prices:

Sizes and Weights

Maximum size

• No one dimension may exceed 2 m (78.7 in.)
• Maximum length plus girth = 3 m (118 in.)

Oversize

• A surcharge applies if the length, width or height exceeds one metre

Minimum size
• 100 mm x 70 mm x 1 mm (3.9 in. x 2.7 in. x 0.039 in.)

Minimum dimensions for mailing tubes:

• 100 mm x 23 mm x 23 mm (3.9 in. x 0.8 in. x 0.8 in.)

Maximum weight

• 30 kg (66 lb.)

Does this CP plugin use the above criteria? I ask this as I can't seem to see a 'volumetric' option (weight, length, width, height inputs) to comply with their system.

Can you please confirm that weight and dimension calcs are included in the code.

Thanks!
Title: Re: Canada Post Virtuemart 3 Plugin
Post by: GJC Web Design on August 14, 2016, 19:03:50 PM
At the moment I am only sending the weight.

There is a check for over 30kg (the std. limit of the method) or if the "Allow overweight orders" is chosen then the excess is calc. by a "factor" on a by kilo basis based on the returned price for 30Kg.

there is an over length check for the 2 meters

   private function _lengthCond($cart, $method) {
$too_long = 1;
foreach ($cart->products as $product) {
   //Check lengths
if($product->product_length > 200){//if any length is greater than 200cm
$too_long = 0;

}


but only individually on each items length

Volumetric calc is extremely complex as it depends how multiple items are packed etc etc.. 

as for individual non complying items.. too long, too small etc - it really depends on how automated you want to get..

I mean just set a min weight for example for too smalls so that the method is excluded .. if it is in a mixed cart then it doesn't matter
too longs add a weight above the max

Some extra code could be added but this would need to be charged for

Cheers
Title: Re: Canada Post Virtuemart 3 Plugin
Post by: Macs_Upcycling on August 17, 2016, 13:05:03 PM
Thank you very much for your detailed explanation, GJC!

"Volumetric calc is extremely complex as it depends how multiple items are packed etc etc."

For my shop, it would be a very rare occurrence for shipping multiple purchases, in which case I would have the customer contact us first for a precise shipping quote and discount.

Can you please PM me for extra code costings that will automagically calculate the necessary volumetric-based shipping costs for our clients.

Cheers, GJC!

Mac

Title: Re: Canada Post Virtuemart 3 Plugin
Post by: Aamirault on December 29, 2016, 05:42:22 AM
It is a great plugin, agreed!
Any options to add a custom shipping option ?, I was told Canada post would ship a flat item like a brochure ( under 500g and less than 3/4 inch thick ) letter mail, typically cost about 5.00 CDN.
The plugin starts at cheapest parcel rate by the looks of things?

I am thinking of setting up a by weight additional shippingmethod  that sets the weight max and limit and using that for brochures if this plugin doesn't yet support it, but would be great to know if it can.

Thanks again

Title: Re: Canada Post Virtuemart 3 Plugin
Post by: GJC Web Design on December 29, 2016, 11:29:03 AM
Hi,

these are according to CanPosts docs the only other supported domestic options that I hadn't included

https://www.canadapost.ca/cpo/mc/business/productsservices/developers/services/rating/getrates/default.jsf

Code    Description
DOM.XP.CERT    Xpresspost Certified
DOM.LIB    Library Materials

But for Library Materials there is the assumption that u are a library

https://www.canadapost.ca/common/tools/pg/manual/PGlibrary-e.asp

there is no "Letter Post" available thru their api as I read it

I guess setup a normal weight method  and add a thickness limit to it ..  or if you can supply more complete info I can add a "static" letter method to the canpost that would just return a fixed amount if the weight was < Xkg and thickness < Xmm

But is this a flat rate Canada wide?

Title: Re: Canada Post Virtuemart 3 Plugin
Post by: Macs_Upcycling on February 17, 2017, 18:50:14 PM
Hi GJC!

I have been testing the CanPost plugin in sandbox mode and have been making steady progress, often referring to your installation PDF and my own tinkering. I think the tinkering bit has gone south as I'm getting the following error code at the top of the page:

Warning
Canada Post : Canada and USA are not valid as International country codes. Use the dedicated structure for these.
Canada Post : /rs/ship/price: cvc-simple-type 1: element {http://www.canadapost.ca/ws/ship/rate-v3}postal-code value 'XXX' is not a valid instance of type {http://www.canadapost.ca/ws/ship/rate-v3}PostalCodeType

I guess this is a common issue and that my configuration settings are interfering with this?

What do I need to amend in the VM CP settings in order to annihilate this error message?

Joomla 3.6.5
VM 3.0.18
Virtuemart 3.0 Shipping via canadapost.ca v.3.0.6

Cheers!

Mac
Title: Re: Canada Post Virtuemart 3 Plugin
Post by: GJC Web Design on February 17, 2017, 21:09:38 PM
Hi Mac,

can we move to email on this one as this forum isn't really for support

Thanks

John

webmaster at gjcwebdesign.com
Title: Re: Canada Post Virtuemart 3 Plugin
Post by: Macs_Upcycling on February 17, 2017, 21:45:57 PM
I've just got it working! For some reason, selecting "Cheapest rate always" under the drop-down list, Choose the required shipping method, it didn't like that so I changed to individual shipping options and bingo.

I'm satisfied that I can now start testing for the countries I'll be shipping to.

Cheers fella,

Mac
Title: Re: Canada Post Virtuemart 3 Plugin
Post by: Macs_Upcycling on May 04, 2017, 14:36:38 PM
Hi John!


I've sent you an email with detailed test results for several addresses. The variances are very significant between in-store prices given and prices shown in the cart. If you need Super Admin credentials, please let me know. We're launching our store mid-June, so we're very keen to get these price variations resolved.


Cheers!


Mac
Title: Re: Canada Post Virtuemart 3 Plugin
Post by: GJC Web Design on May 04, 2017, 18:43:01 PM
Plugin updated to use dimensions -- you must use centimeters
Tax handling added as well.
Title: Re: Canada Post Virtuemart 3 Plugin
Post by: GJC Web Design on July 15, 2021, 12:53:03 PM
CanPost plugin updated to /ws/ship/rate-v4 ... 

this allows the plugin to be used without a customer-number -- the customer-number is now optional (used to  obtain discounted rates for commercial customers and Solutions for Small Business members.)