Change the vendor link URL

Ihor Hi. Can you please tell me. Where can I change the link that a user clicks on when he clicks on the seller’s picture or his nickname. In some cases I need to make it so that when the user clicks on the seller’s picture or nickname, he will go to another address, not the seller’s profile address.

Hi,
It’s possible but requires overriding the name and image template parts (vendor/view/block/vendor-name.php and vendor-image.php), please try following this tutorial Customizing Templates I HivePress Developer Docs - YouTube

Thx, Ihor
Another question. What snippet can make when you change any attribute in the seller’s profile, send the profile to moderation?
It would help me a lot.

Ihor and another point that I still can not understand, in the dashboard when you cancel an order, on the chart in the income section is still the amount of the order. The balance in this case is zero. Is it possible to clear the seller’s dashboard completely?

  1. Unfortunately there’s no simple code for this, because the profile page behaviour is unpredictable for the Pending status, please try manually switching the vendor profile to this status and check how the profile settings form behaves.

  2. Please let me know what you mean about cancelling the order, disputing it? The dispute form just sends a request to the site admin, but only admins can change the order status to Canceled and refund the order amount (then the vendor balance is re-calculated).

Regarding the display of the sale amount in the seller’s chart. It seems that it was a cache, today in the sales chart of the order that was canceled is no longer there.

I noticed one detail today. When a seller offers a customer request, the seller has to find out the amount of his offer and there was a problem. The customer creates a request and specifies an amount of 100, the seller clicks the offer and there enters the amount they offer, for example “ready to perform for 80” If the user agrees with the offer, they accept it and are directed to make the payment. But here I have a surprise, the check that is generated indicates an amount of 100, although the client has accepted the merchant’s offer for 80. How to deal with this? I have a solution, need help.

I picked up a temporary solution for now. I banned links to photos and names. And added an attribute with a link to a personal profile under the nickname of the seller, which will lead from the subdomain to the main domain of the site.

This is strange, if you have bidding enabled in the offer settings, the checkout price should be updated to the selected offer price (the one where the Accept Offer button is clicked). Please let me know if there are some specific steps to reproduce this issue.

Hi, Ihor. After your post I checked the snippets again, the problem turns out to be in the snippet posted it below. With this snippet I removed the mandatory filling of the field budget. After I excluded it, the function worked as it should.
Maybe there is a way to remove the restriction without breaking the function?

add_filter(
	'hivepress/v1/models/request/fields',
	function( $fields ) {
		if ( isset( $fields['budget'] ) ) {
			$fields['budget']['required'] = false;
		}
 
		return $fields;
	},
	1000
);

This code shouldn’t affect the checkout redirect, it requires the offer price only (if the budget field is not removed completely). You can also check this code locally (in hivepress-requests/includes/controllers/class-offer.php file) Screenshot by Lightshot If the offer price is set, it saves it as the request budget and then redirects user to checkout.

Got it, but after turning it off the price began to change when the seller offers his price in the request. Well something like that, perhaps the reason for something else, but I got like this(
Let’s test it again. Thx, Ihor.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.