Jump to content

Customer Pick-Up Mod


Guest chaleepas

Recommended Posts

Guest chaleepas

I needed a customer pick-up option for our internal employees. I created one and would be happy to share it if people want it.

It's my first shot at something like this, but it appears to be working just great!

:whistle:

Thanks.

Link to comment
Share on other sites

Guest chaleepas

Sorry it took so long to reply, it's been a very busy week, this is the first I have gotten on the pc for any amount of time in days!

I am using 3.0.5 but not sure if anything changed in that area for 3.0.6. So how do I get the files to everyone? I went ahead and zipped everything up together...

I'll just put up on my website, hopefully people can get the zip file there:

http://www.dreamdesignconsulting.com/Custo...p_Mod_Files.zip

Someday I'll get to finish my own website.. SIGH

Link to comment
Share on other sites

Got a quick question. Is this mode supposed to have Customer Pickup in the shipping box something like the other boxes?

(ups ground $5.29 but this would be customer Pickup $0.00 or something like that? also what is the second line down in the configuration screen for this shipping option? Is this where I am having a problem?

Link to comment
Share on other sites

vrakas,

Did you get the mode working? I got it all setup and I am not sure I got it right? Above is explanation on the probem I am having...

It works very well but how is the customer informed this is free shipping for pickups?

Link to comment
Share on other sites

Guest chaleepas

OMG It's been so long now since I created it I had forgot to include the next step. SO SORRY!

<br />

Log In to admin and enable it in the shipping module with a "blank" price. The customer pick-up option will appear in the cart once it's enabled.

:)

Link to comment
Share on other sites

I guess I did something wrong as I did enable it when I installed it...I just double checked everything and it still gives no Info

All it said is shipping then the dropdown menu ($0.00)

the other have (ups same day)$5.00

(ups Next day)$10.00

(ups ground)$20.00

Link to comment
Share on other sites

yep I modified the en language file to

$lang['front']['cart'] = array(

'free_shipping' => "Free Shipping",

'customer_pick_up' => "Customer Pick Up",

I did see a thing that may be the problem but not sure. will the capital P in

_Pick_up and the small p in

'customer_pick_up' =>

will that make it not work?

// Created by chaleepas November 2005 for Customer_Pick_UP mod

//Under admin/modules/shipping/ folder structure add the included

Customer_Pick_Up file folder and files.

//Under modules/shipping/ folder structure add the included

Customer_Pick_Up file folder and files.

//Under this section in the "en" language file:

$lang['front']['cart'] = array(

// Add another line called this for the customer pick up option:

'customer_pick_up' => "Customer Pick Up",

here is a pic of the problem

shipping.jpg

Link to comment
Share on other sites

Guest estelle

yep I modified the en language file to

$lang['front']['cart'] = array(

'free_shipping' => "Free Shipping",

'customer_pick_up' => "Customer Pick Up",

There's nothing wrong with what you have done, but its only a partial solution.

If you create a new language string identified by 'customer_pick_up', then you will have to make a change to the code in calc.php so that it uses this new language string rather than the old language string identified by 'free_shipping'.

I.e. edit modules/shipping/Customer_Pick_Up/calc.php

Change this line:

$shippingPrice .= ">".$lang['misc']['free']." (".priceFormat("0.00").")</option>\r\n";


To this line:


$shippingPrice .= ">".$lang['front']['cart']['customer_pick_up']." (".priceFormat("0.00").")</option>\r\n";


And, change this line:


	$basket = $cart->setVar($lang['misc']['freeShipping'],"shipMethod");


To this line:


	$basket = $cart->setVar($lang['front']['cart']['customer_pick_up'],"shipMethod");

Estelle.

Link to comment
Share on other sites

Works like a charm Estelle, Thank you so much for the help.

I do have one little question more though ;)

in the shipping dropdown it does say

Customer Pick Up ($0.00)

I would like it to say

(Customer Pick Up) $0.00

Makes it uniform with the other shipping options..

How hard would it be to change that?

Link to comment
Share on other sites

Guest estelle

Okay, now find this line (its one of the lines you previously changed):

$shippingPrice .= ">".$lang['front']['cart']['customer_pick_up']." (".priceFormat("0.00").")</option>\r\n";


And change it to:


$shippingPrice .= ">(".$lang['front']['cart']['customer_pick_up'].") ".priceFormat("0.00")."</option>\r\n";

Estelle.

Link to comment
Share on other sites

Guest chaleepas

Thanks Estelle for helping with this.

I had it corrected as you explain in this forum in my "at work" calc.php file version, but not in the version I had originally set up on my test site (which is the one I had access to at home when I posted it to this forum, sorry about that guys) (two entirely different websites).

I will try and fix the zip file tonight to include the correct calc.php file.

;)

Link to comment
Share on other sites

Chaleepas,

Hey not a problem at all. It is all a new learning experience for me. And I am loving it. This is pretty cool stuff.

Thank you for this mod also. We apriec it alot.

Link to comment
Share on other sites

  • 4 months later...
Guest Denver Dave

Just thought I'd touch base and see if there had been any changes in thinking or with newer CubeCart versions to handle a shipping method of Customer Pickup. Seems like should be a relatively common option.

I did change the language file in version 3.0.10 to

'freeShipping' => "Customer Pickup",

and

'free' => "Pickup",

however, I can see how setting up a new

'customer_pick_up' => "Customer Pick Up",

and modifying the calc.php might be a better way to go.

Also, we'd prefer that the "Customer Pickup" option be at the bottom of the dropdown shipping method box rather than the first item - anyone else have this issue?

Any new thinking on this - any chance CC will add Customer Pickup as a standard shipping option?

Thanks.

Link to comment
Share on other sites

  • 2 weeks later...

All these contributions are great - but I guess I'm going to take a stab at writing my first mod - I may get part of it done and ask for help for some specific options from the brilliant people here - but what I have to have along with customer pickup is local / area delivery as well - I think I've got the logic in my head - but with gas prices, it's not something that can be added into and covered in the cost of the product - so we've set some specific area / miles and prices -- if anyone will be interested I'll post it here when done - cross your fingers...

Link to comment
Share on other sites

Guest Kristina

All these contributions are great - but I guess I'm going to take a stab at writing my first mod - I may get part of it done and ask for help for some specific options from the brilliant people here - but what I have to have along with customer pickup is local / area delivery as well - I think I've got the logic in my head - but with gas prices, it's not something that can be added into and covered in the cost of the product - so we've set some specific area / miles and prices -- if anyone will be interested I'll post it here when done - cross your fingers...

That would be awesome! ;)

Link to comment
Share on other sites

  • 3 months later...
Guest grey legion

Hmmm...did not work for me and I read everything twice..

I must be missing something, chaleepas did you update all files as you mentioned I simply get ($0.00) with nothing else..

But I'll take a shot in the dark I only need 3 types of shipping

1 - Flat rate ( already done )

2 - Pick up $0.00

3 - Drop off at MFC $0.00

how could I go about simply haveing them and nothing else..

Take a look at the store place a dummy order if you wish, just let me know

http://www.themfc.com/Aquarium_Shop/index.php

Thanks

BTW here is my calc.php file

*/

// free shipping

$module = fetchDbConfig("Customer_Pick_Up");

if($module['status']==1){

$sum = 0;

$shippingPrice .= "<option value='".$shipKey."'";

if($shipKey ==$basket['shipKey']){

$shippingPrice .= " selected='selected'";

$basket = $cart->setVar($lang['front']['cart']['customer_Pick_Up'],"shipMethod");

$basket = $cart->setVar($sum,"shipCost");

}

$shippingPrice .= ">".$lang['front']['cart']['customer_Pick_Up']." (".priceFormat("0.00").")</option>\r\n";

$shipKey++;

unset($module, $taxVal);

}

?>

am I missing something !?!

Link to comment
Share on other sites

  • 2 weeks later...
Guest tbladecki

This line in your post is incorrect:

$shippingPrice .= ">".$lang['front']['cart']['customer_Pick_Up']." (".priceFormat("0.00").")</option>\r\n";




change it to: 
$shippingPrice .= ">(".$lang['front']['cart']['customer_pick_up'].") ".priceFormat("0.00")."</option>\r\n";

Be very careful when changing or rewriting code... PHP is like any other programming code... it has to be a certian format to work correctly.

*/* hope this helps

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...