Keyword

how to add tab to k2 admin "edit item" page?

  • Kran Chi
  • Kran Chi's Avatar Topic Author
  • Visitor
5 years 7 months ago - 5 years 7 months ago #169286 by Kran Chi
Hello,

According the below post :
www.joomlaworks.net/forum/k2-en/49661-payment-for-items-in-k2

I wrote a plugin for k2 that can feature an item after paypal payment. So now I need that display the transactions for each item. A good position can be "Edit item page" (in admin) and for that need to add a new tab. For example after latest (attachment).

Also I can see in this file a related code :
administrator\components\com_k2\views\item\tmpl\default.php
	<?php if(count(array_filter($this->K2PluginsItemOther)) && $this->params->get('showK2Plugins')): ?>
	<!-- Tab other plugins -->
	<div class="k2TabsContent k2TabsContentLower" id="k2TabPlugins">
		<div class="itemPlugins">
			<?php foreach($this->K2PluginsItemOther as $K2Plugin): ?>
			<?php if(!is_null($K2Plugin)): ?>
			<fieldset>
				<legend><?php echo $K2Plugin->name; ?></legend>
				<?php echo $K2Plugin->fields; ?>
			</fieldset>
			<?php endif; ?>
			<?php endforeach; ?>
		</div>
	</div>
	<?php endif; ?>

If it's possible how can be done?
With best.
Last edit: 5 years 7 months ago by Kran Chi.
The topic has been locked.
  • Mohamed Abdelaziz
  • Mohamed Abdelaziz's Avatar
  • Offline
  • Platinum Member
  • Joomla Developer
More
5 years 7 months ago #169289 by Mohamed Abdelaziz
Replied by Mohamed Abdelaziz on topic how to add tab to k2 admin "edit item" page?
In my Datasets For K2 plugin, I used jQuery to add a tab to the item edit form, you can see the plugin working in this video: www.youtube.com/watch?v=WDwVmCbqRMo

If you like to go with this approach, I will prepare an example to explain how to do it.

Multiple Extra Fields Groups for K2
AutoMeta for K2
Chained Fields for K2
More K2 Extensions In My Extensions Store
The topic has been locked.
  • Kran Chi
  • Kran Chi's Avatar Topic Author
  • Visitor
5 years 7 months ago - 5 years 7 months ago #169401 by Kran Chi
Replied by Kran Chi on topic how to add tab to k2 admin "edit item" page?
I did that with jquery in backend (Joomla User Edit page) & without it in frontend (User Profile)
Thank you.
Attachments:
Last edit: 5 years 7 months ago by Kran Chi.
The topic has been locked.

Powered by Kunena Forum