Multi Vendor Marketplace Plugin | WCFM Marketplace › Forums › WC Marketplace › Email to Vendor when add Product
- This topic has 10 replies, 2 voices, and was last updated 5 years, 3 months ago by WCFM Forum.
- AuthorPosts
- July 1, 2019 at 9:30 am #70497thiemann.kParticipant
Hey Community,
what do i have to do (for example with a snippet) that all sellers get an email when a product in category (cat-id=228) has been added?
Members can submit a “Product Inquiry”. These all come in a single category. I would like to inform the sellers if a new product has been created here.
Best regards!
Karsten - July 4, 2019 at 5:15 am #70931WCFM ForumMember
HI,
what do i have to do (for example with a snippet) that all sellers get an email when a product in category (cat-id=228) has been added?
– You mean, if Admin add a product in this category then all vendors will be notified?
Members can submit a “Product Inquiry”. These all come in a single category.
– Sorry, not getting this clearly.
Thank You
- July 10, 2019 at 4:40 am #71769thiemann.kParticipant
– You mean, if Admin add a product in this category then all vendors will be notified?
– no…
I have a category where product inquiries come in. if a seller has this product, or can create, then he can respond to it.
Now I would like all Vendors to always receive an email or a notification when a product is added in category “228”.is that possible?
Thanks
- July 13, 2019 at 7:44 am #72255WCFM ForumMember
Hi,
Well, vendors are by default notified if any inquiry comes for their products!
Do you want to disable this and only allow notification for this particular category products?
Thank You
- July 17, 2019 at 4:27 am #72733thiemann.kParticipant
no, I do not want to =)
So:
I have a category where users can create “product requests”.
A customer is looking for a product that is not yet available in the shop, this can create its own product (Add User Product)
The user product automatically comes in a specified category (cat-id = “228”)
Now I would like an email / referrals (preferably both) to be sent to all sellers when a new product is created in this category. - July 18, 2019 at 12:08 pm #72943WCFM ForumMember
HI,
Thanks for the details. I understand your concept.
A customer is looking for a product that is not yet available in the shop, this can create its own product (Add User Product)
– Do you have implemented this yet!
Thank You
- July 18, 2019 at 2:01 pm #72974thiemann.kParticipant
hey =)
yes, I have already implemented that.
there are some plugins that implement that … which I like the most is the Add product frontend by NSThemes.Maybe you can offer something like that in the future? I think that is a good thing.
A customer is looking for a product that is not yet available in the shop, this can create its own product (Add User Product)
YES !
And now, when a customer has create his own product, than all vendors should be an notification/or email (maybe both).
but how does it continue?
a snippet should certainly implement this.
but how? - July 19, 2019 at 12:46 pm #73085WCFM ForumMember
Hi,
And now, when a customer has create his own product, than all vendors should be an notification/or email (maybe both).
but how does it continue?– Well, that can be implemented easily.
Do you have any idea about this plugin’s coding?
Actually, I want to know, is there any hook after completing the product creating by this form!
Thank You
- July 19, 2019 at 4:17 pm #73104thiemann.kParticipant
not yet. is that necessary?
Thanks!
- July 20, 2019 at 5:02 am #73149WCFM ForumMember
HI,
Yeah, as we have to write custom code to send out emails based on that hook.
Otherwise, we have to edit that plugin, and this is not good at any situation!
Can you please share your site access with me here – https://wclovers.com/woocommerce-multivendor-customization/
I will take a look at this.Thank You
- August 2, 2019 at 11:03 am #74830WCFM ForumMember
Hi,
Here is your code for the purpose –
add_action( 'wp_insert_post', function( $post_ID, $post, $update ) { global $WCFM; if( isset( $_POST["ns-product-name"] ) ) { $wcfm_messages = 'New product added to the site - <a href="' . get_permalink( $post_ID ) . '">' . get_the_title( $post_ID ) . '</a>'; $all_vendors = $WCFM->wcfm_vendor_support->wcfm_get_vendor_list( true, '', '', '', '', false ); if( !empty( $all_vendors ) ) { foreach( $all_vendors as $vendor_id => $all_vendor ) { if( $vendor_id ) { $WCFM->wcfm_notification->wcfm_send_direct_message( -1, $vendor_id, 1, 0, $wcfm_messages, 'new_product', true ); } } } } }, 50, 3 );
Thank You
- AuthorPosts
- You must be logged in to reply to this topic.