Hello,
How to hide tab payment_method for the vendor, but still available for admin.
Thank you. is it possible using my_change addon.
Hello,
How to hide tab payment_method for the vendor, but still available for admin.
Thank you. is it possible using my_change addon.
I do not see such tab on the clean installation. Do you use 3rd party modules to add it?
Hi Ecom,
i will check it first i don't remember about payment method from 3rd party or not.
Hi
It's working i hide tab with this code
if($mode == 'update') { if(Registry::get('addons.wk_single_seller_checkout.enable_payment_action') == 'Y') { $tabs = Registry::get('navigation.tabs'); $tabs['payment_method'] = array( 'title' => __('payment_method'), 'js' => true ); if (ACCOUNT_TYPE == 'vendor') { unset($tabs['payment_method']); } Registry::set('navigation.tabs', $tabs); $payments = fn_get_payments(array('status' => 'A')); $disable_payments = fn_wk_ssc_fn_get_vendor_disable_paymet($_REQUEST['company_id']);if(!empty($disable_payments) && is_array($disable_payments)) { foreach ($payments as $key => $payment) { if(in_array($payment['payment_id'], $disable_payments)) $payments[$key]['status'] = 'D'; } } Registry::get('view')->assign('payments',$payments);}
}
But the problem is with the view, the vendor can't see payment method tab but they can see content_payment_method.
how to hide this Registry::get('view')->assign('payments',$payments);} from vendor
Thank you.
Never mind i solve this one.
Thank you.
hot did you solved?
Looks like code of 3rd party module was changed
I put this on tab_content.post.tpl
{if $auth.user_type=="A"}
{/if}
after that vendor cannot access the content. but admin still can access it.