Home › Forums › WC Vendors Pro Support › Vendor address to display on Checkout page using Local Pickup shipping
NOTICE: We've Moved to a Ticket System for Support
As of August 31, 2017 (12am EST) our support forums will be retired (read-only), and we will be moving to a support ticket system. This will allow us to better organize and answer support requests, and provide a more personalized experience as we assist our customers.
For the time being, we will leave our forums open for reading and learning while we work on creating a more robust Knowledge Base for everyone to use.
If you are a WC Vendors Pro customer please open a support ticket here. If you are a WC Vendors user please open a support ticket on the Wordpress.org forums.
The information on this forum is outdated and in most instances no longer relevant. Please be sure to check our documentation for the most up to date information.
Thank you to all of our customers!
- This topic has 28 replies, 2 voices, and was last updated 6 years, 1 month ago by
Anna.
-
AuthorPosts
-
May 2, 2017 at 10:24 pm #64031
Saif
ParticipantHi support,
I know how to setup Local Pickup shipping method. Just wondering, how to add Local Pick address for each vendor? There is no shipping address option in Vendor Dashboard setting. Could you please help me?
My client wants a Local Pickup service for each vendor.
Just want to clarify that when customer go to Checkout page where shipping method displays, I want over there also display Vendor local pickup address which should be Vendor shop address.
And when customer submitted the order via PayPal then it also display on Order Summary page. I did Sandbox test and got this page after pay. See https://gourmairs.com/shoaib/checkout/order-received/540/?key=wc_order_5907f115b5bc1&order-received=540
I want Vendor address under Local Pickup column. I know is it possible to write custom PHP code but just dont know what is the code? I know it is possible to edit order-details-customer.php or order-details-item.php or order-details.php files.
Can you please help me and send me Vendor address code?
Regards,
SaifMay 3, 2017 at 6:41 pm #64138Anna
MemberHello,
Well first you will want to fix this:Pro Dashboard Page: ✕ -Your pro dashboard page cannot be set to your free dashboard page. Click here to change
And also update to WC Vendors Pro v1.4.3 so you have compatibility with the WooCommerce version that you are using.
We do not have local shipping in Vendor Shipping, which is the module we use for vendor-specified rates that can then be allocated to the vendors.
They can enter rates for specific zip codes and regions if they were to use the Vendors Shipping > Country Rate which you can set up in the admin as the default shipping method for the vendors.Vendors do have the fields to enter their store address and store shipping address in their Pro dashboard pages.
May 3, 2017 at 8:38 pm #64175Saif
ParticipantDear Anna,
Thanks for your reply. How to I fix “Pro Dashboard Page: ✕ -Your pro dashboard page cannot be set to your free dashboard page. Click here to change” issue and why I am getting this.
In regards to Vendor address, I know Pro Dashboard have option to enter Store address. My question is how to display Store address at Checkout page and Order summary page. Both pages show the product name and Sold by Storename which is fine then why not show vendor store address just under Shipping Method. See attached screenshot. I added message in the backend Local Pickup from Chef store and you can see in the screenshot and it also displays Sold by Store name but there is no link to Storename.
How can I display Vendor address just after Shipping method? Of if it is not possible then how can I like Storename to Store page. In store page customer can find the store address.
Please help me. I know it can achieve ny editing order-details.php or other PHP files.
REgards,
SaifMay 5, 2017 at 7:15 pm #64401Saif
ParticipantHi Anna,
I am waiting for my previous message. I fixed “Pro Dashboard Page: ✕ -Your pro dashboard page cannot be set to your free dashboard page. Click here to change” issue.
Can you please help me my main issue that I want to display Vendor store address on Checkout and order summary page as shown in previous attached screenshot. Please help me.
Regards,
SaifMay 10, 2017 at 12:37 am #64776Saif
ParticipantDear Author,
Can you please reply? I need to resolve this issue.
Regards,
SaifMay 10, 2017 at 9:28 pm #64833May 10, 2017 at 9:54 pm #64836Saif
ParticipantHi Anna,
You are great. Thanks for your reply. My site is nearly finished. I am not using WC Vendors PRO as all my necessary things are fulfill by using WC Vendors FREE plugin. Have a look my site at https://gourmairs.com/shoaib/
I also finished LIVE transaction. The only thing I am waiting for Local Pickup Seller store address to display on Checkout page and also on Order Summary page. The checkout page shows the store name so I am sure there is a way to display Store address as well. If you need my website FTP details please let me know.
Regards,
SaifMay 20, 2017 at 4:02 am #65773Saif
ParticipantHi Anna,
Hope you are well. Do you have any updates?
Regards,
SaifJune 1, 2017 at 7:51 pm #66985Saif
ParticipantDear Anna,
Do you have any updates. My site is almost finished. Have a look at https://gourmairs.com/shoaib/
I need to display Local Pickup address at Checkout page and order page. You said you are working on that. Can you please help me?
Regards,
SaifJune 12, 2017 at 7:44 pm #67891Saif
ParticipantDear Author,
Can you please advise me? I launched my site. Have a look at https://gourmairs.com/ but client is not happy. As it doesnot show Vendor address on Checkout page. Can you please help me? It shows Vendor name on Checkout page so why not display Vendor address. Please help.
Regards,
SaifJune 14, 2017 at 12:41 am #68036Anna
Member@saifuts
Hello Saif,
Ok- I beleive I finally have this one worked out!
🙂
This is for the address– this will show on the ORDER CONFIRMATION after checkout, and also for the customer if they go to: My Account > Orders
Theme/child theme functions.php:
https://gist.github.com/fervous/c9a09eb789da4bf9b080a3fda98319edAnd also this will show the vendor’s email, if you are interested:
https://gist.github.com/fervous/83739bcbf7e503114d0c1e8daeeb7775June 14, 2017 at 1:27 am #68047Saif
ParticipantHi Anna,
You are great. Thanks for your help. Just wondering, I added code under wp-content/themes/foodpicky/functions.php folder and it doesnot work.
Can you please tell me where I have to add exactly this code? I think it should be under wp-content/plugins/woocommerce/templates/. I am not sure.
If you go to https://www.wcvendors.com/help/topic/show-vendor-address-on-cart-for-local-pickup-option/ article , Patrick mentioned. I also followed this but it didnot work. Please help me.
Regards,
SaifJune 14, 2017 at 1:43 am #68053Anna
Member@saifuts
You placed it in the correct location: wp-content/themes/foodpicky/functions.php
Though I would STRONGLY suggest you use a child theme.Place a new test order, then tell me what you see on the Order confirmation page.
June 14, 2017 at 1:59 am #68056Saif
ParticipantHi Anna,
I attached function.php file in ZIP format. Can you please check and let me know I placed in the correct location.
Thanks for the advise for child theme. I have already took backup.
Waiting for quick reply.
Regards,
SaifJune 14, 2017 at 2:32 pm #68106Anna
Member@saifuts
There is no attachment.
This would just need to go at the end of your theme or child theme’s functions.php file. Somewhere on the page after the opening<?php
but before the closing?>
if there is one. Usually if you just place the code at the end of the functions.php (before any closing?>
) then it should work.I have tested this code on my dev site and it is working.
You will have to place a NEW test order to see the address info on the order confirmation page and my-account/orders view order page.
June 14, 2017 at 8:14 pm #68145Saif
ParticipantDear Anna,
You are so cool. Tell me what can I do for you? I am so impressed for your work. Thank you very much for your help. In my last email, I was trying to attach functions.php file but I guess your system denied. So I attached screenshot fro my test order summary page. Have a look.
It is working absolutely fine. I am getting email with Vendor address as well.
Once again, good on you. Now I can launched the site and hand over to client.
Regards,
SaifJune 15, 2017 at 12:40 am #68157Anna
Member@saifuts
Hello Saif,
Great! I am glad we were able to get this implemented for you and that it is working well. 🙂
If you are happy with our plugin & support, we always appreciate a review on our wordpress.org page: https://wordpress.org/plugins/wc-vendors/😀
August 19, 2017 at 11:28 am #77022Saif
ParticipantDear Anna,
Hope you are well. It has been long time to talk. Finally we are going to LIVE and I did final testing. The address is showing fine on Order Summary page bu tin email it is showing in one line along with Vendor name. Is it possible if you update your code form Email so Vendor name, Vendor address and Vendor email address shows in seperate line.
See attached screenshot.
I will look forward your soonest reply.
Regards,
SaifAugust 19, 2017 at 11:34 pm #77061Anna
MemberHello!
Glad you’re going live soon.
Try this in your child theme functions.php:
https://gist.github.com/fervous/d44c627f4a1685ba8dec01ceb8cd1fbfAugust 20, 2017 at 8:30 am #77080Saif
ParticipantHi Anna,
Thanks for your quick response. There is a bug I found and spent hours and hours to figure out. For some reason, after placed order Vendor address is showing wrong in Order Summary page and Email. See attached Screenshot 2. I checked Vendor profile and it is showing different address. See screenshot 1. Then I searched entire database and found the old address entry. See attached screenshot 3.
Just for your information, currently I am using WC Vendors FREE version. Initially when I started building my website I was using WC Vendors Pro version so I activated again and then went to user profile and found old address. See attached screenshot 4.
I think your code is for WC Vendors Pro, can you please update your code so it will show correct Vendor store address. Also can you fix the extra line spacing. See attached Screenshot 2, it is showing extra line space under Vendor details.
I will look forward to hear from you soon.
Regards,
SaifAugust 22, 2017 at 1:36 am #77169Saif
ParticipantHi Anna,
Hope you are well. Sorry to bother you. Just following up. I noticed that I logged this task in WC Vendors PRO support.
Actually initially I was using WC Vendors Pro plugin but then my theme author said I dont need as his them only support free version. See my theme https://themeforest.net/item/food-delivery-restaurant-directory-wordpress-theme-foodpicky/17966079. It has builtin WC Vendors Free.
Do you want me move this thread to FREE support or you can do it. Anyways I need the code to work on free version. Can you please tell me when you update the code.
Regards,
SaifAugust 23, 2017 at 7:26 pm #77274Saif
ParticipantHi Anna,
Hope you are well. Can you please tell me ETA for this issue as my client is asking? We need to go LIVE soon. Please let me know.
Regards,
SaifAugust 23, 2017 at 9:46 pm #77302Anna
MemberHello,
In WC Vendors free, those fields are not present to collect all of that data form the vendor.
The WooCommerce customer shipping/billing info would need to be used.
So for address and email you would need to instead gather the WooCommerce info (get_user_meta) if the vendor has filled out that information on their my-account page.August 23, 2017 at 9:54 pm #77303Saif
ParticipantHi Anna,
Thanks for your quick response. Can you please kindly update the code for me? I can update Vendor documentation so then when Vendor sign they can fill the Shipping and Billing address. So if shipping address and billing address are different which address it will display in Email and Order summary page.
Please help me.
Regards,
SaifAugust 24, 2017 at 8:28 am #77329Saif
ParticipantHi Anna,
I am very sorry to bother you again. I have a presentation to client on this Saturday. Is this possible if you update the code. Please I want to finish this project as it took so long.
I appreciate your help.
Regards,
SaifAugust 24, 2017 at 7:38 pm #77365Saif
ParticipantHi Anna,
Hope you are well. I think you are busy as I have not heard anything from you. So I updated James and Anne profile and added their billing and shipping address but unfortunately no address is displaying on Order summary page and email.
See attached screenshot. Can you please kindly help as I am about to go LIVE.
I will look forward to hear from you soon.
Regards,
SaifAugust 24, 2017 at 11:07 pm #77371Anna
MemberHello,
The code would have to be changed to use the woocommerce billing or shipping address. The way that code is written, it is out putting the WC Vendors Pro user_meta gathered with the Pro forms (address, email, etc.).
I have tried to do this using the WooCommerce billing user_meta a few times and have not been successful. I know it can be done; but I am missing something in my code and I am not sure yet *what* I am not getting right. It likely has to do with the separation of the vendors role vs. customer role user_meta.I wrote the above code you were using in Pro just to help out; this is not actually a feature we include nor support in WC Vendors.
I will try again to get the code written, but I have to take care of the other support tickets that deal with the features that are included in our plugin(s).August 25, 2017 at 12:08 am #77374Saif
ParticipantHi Anna,
Thanks for your reply. Can you please check below code? looks like I have fixed myself. So not sure that is correct code or not. I filled Vendor billing and shipping data under user profile and it seems like working fine. Please check below code and see my Order summary screenshot.
add_action( 'woocommerce_add_order_item_meta', 'bwd_add_vendor_to_order_item_meta', 10, 2); function bwd_add_vendor_to_order_item_meta( $item_id, $cart_item) { $vendor_id = $cart_item[ 'data' ]->post->post_author; // build up address $address1 = get_user_meta( $vendor_id , 'billing_address_1', true ); $address2 = get_user_meta( $vendor_id , 'billing_address_2', true ); $city = get_user_meta( $vendor_id , 'billing_city', true ); $store_postcode = get_user_meta( $vendor_id , 'billing_postcode', true ); $state = get_user_meta( $vendor_id , 'billing_state', true ); $address = ( $address1 != '') ? $address1 .', ' . $city .', ' . $state.', '. $store_postcode :''; wc_add_order_item_meta( $item_id, apply_filters('wcvendors_sold_by_in_email', __('Address', 'wcvendors')), $address); } add_action( 'woocommerce_add_order_item_meta', 'email_add_vendor_to_order_item_meta', 10, 3); function email_add_vendor_to_order_item_meta( $item_id, $cart_item) { $vendor_id = $cart_item[ 'data' ]->post->post_author; $email_vendor = get_userdata( $vendor_id )->user_email; wc_add_order_item_meta( $item_id, apply_filters('wcvendors_sold_by_in_email', __('Email', 'wcvendors')), $email_vendor); }
Regards,
SaifAugust 25, 2017 at 6:27 pm #77400Anna
MemberHello,
Looks like it is working great! 🙂 -
AuthorPosts
- The forum ‘WC Vendors Pro Support’ is closed to new topics and replies.