Go Back   Mosets Community > Archives > Mosets Tree 2.2 > Discussions, Troubleshooting & Problems

 
 
Thread Tools Search this Thread Display Modes
  #1  
Old 12-03-2011, 12:56 AM
stevenkong stevenkong is offline
Mosets'd
 
Join Date: Nov 2011
Posts: 18
Default How to add a core field to Mosets Tree

I have just purchased Mosets Tree 2.2.3. I am using Joomla 1.7.2. Mosets tree is a solid component and I congratulate this but I have come across a limitation. There is no copy button to duplicate a core field and change its caption name or add a new core field.

I want to be able to add a core field called “Address 2” line in the address part rather than just a custom field. When I added a custom called “Address 2”, it creates a problem because it is not appearing as part of the address in either summary/ listing view or detail page view. See attached screenshot.

http://www.kd-webdesign.co.uk/Core-Field-Issue.jpg

Can someone provide me a step-to-step solution please and the requirements for the new core fields are:

1) It must be searchable
2) It must have all the parameter just like any custom module has in editing mode.

I can see a thread relating to Hot Property here but not for Mosets Tree - http://forum.mosets.com/showthread.php?t=10790

I am not a programmer, so step-to-step solution would be ideal for creating core field in Mosets Tree. Thanks.
  #2  
Old 12-03-2011, 04:48 PM
tradewise tradewise is offline
Senior Member
 
Join Date: Feb 2006
Location: Hervey Bay Qld Australia
Posts: 576
Default

You can do it with a custom field and you can set the parameters of the CF to be search able if you want.

Firstly you need to order the Custom field in the logical order with the Core address fields.

After that you need to modify sub_listingSummary.tpl.php and sub_listingDetails.tpl.php

Find this in both:
if(in_array($field->getId(),array(4,5,6,7,8)) && !empty($output)) {
$address_parts[] = $output;

Then simply add the CF ID number to the array in each template.

There's a couple of other arrays in the scripts that effect the address and depending on your settings for how the arddress displays you may need to add your CF ID to these as well. It's just a matter of playing with it, just remember to back up the files beforehand.

Hope this Helps
Regards Steve
Developer of PaymentsPlus
  #3  
Old 12-06-2011, 11:04 PM
stevenkong stevenkong is offline
Mosets'd
 
Join Date: Nov 2011
Posts: 18
Default

Thanks for the reply. Ok, I will give it a try. Apart from modifying sub_listingSummary.tpl.php and sub_listingDetails.tpl.php, do you know any other files that contains these codes which I need to modify (since Mosets tree is a big component and there are many files to look into):

if(in_array($field->getId(),array(4,5,6,7,8)) && !empty($output)) {
$address_parts[] = $output;
  #4  
Old 12-08-2011, 05:02 AM
tradewise tradewise is offline
Senior Member
 
Join Date: Feb 2006
Location: Hervey Bay Qld Australia
Posts: 576
Default

Quote:
Originally Posted by stevenkong View Post
Thanks for the reply. Ok, I will give it a try. Apart from modifying sub_listingSummary.tpl.php and sub_listingDetails.tpl.php, do you know any other files that contains these codes which I need to modify (since Mosets tree is a big component and there are many files to look into):

if(in_array($field->getId(),array(4,5,6,7,8)) && !empty($output)) {
$address_parts[] = $output;

I'm 99% sure these are the only files you'll need to worry about because other pages that render a list of listings like My Page simply include sub_listingDetails.tpl.php to render the listings.

Regards Steve
Developer of PaymentsPlus
  #5  
Old 12-09-2011, 12:41 AM
stevenkong stevenkong is offline
Mosets'd
 
Join Date: Nov 2011
Posts: 18
Default

many thanks
  #6  
Old 02-08-2012, 07:52 PM
tazzarkin tazzarkin is offline
Mosets'd
 
Join Date: Jan 2012
Posts: 76
Default

Actually, I need to add a core field for a Spreadsheet Module we're using. How can we add a core field?

-------------------------------

This has been SOLVED. Thank you to the Mosets Team for their help. For my application of Mosets, I ended up creating several new custom fields in Mosets, a new View in my database, and then was able to display the information I needed. Mosets Tree is a fantastic component to use with Joomla!!

Last edited by tazzarkin; 02-10-2012 at 02:59 AM.
  #7  
Old 03-12-2012, 08:46 PM
tevaimaiau tevaimaiau is offline
Mosets'd
 
Join Date: Jun 2010
Posts: 1
Talking Custom field or core field ?

Hello, this component is so nice and I love it - very good job !
I really need to create a CORE field searchable for specific SQL request between 2 tables (jos_mt_links and jos_mt_cl)

The reason is : the field "metakey" in the table "jos_mt_links" isn't searchable... (too bad..)
It's a problem for me, because I would like to change values of my (custom) field captioned "Days" only into specific categories, so I must write an sql request..
The big problem is : I didn't found any solution to link the table "jos_mt_cl" where cat_id are stored (to select only one cat_id) and the table "jos_mt_cfvalues" where the custom field's values are stored.

e.g.
1/ I would like to change the values of the fields named "Days" for all the listings stored in the category "Restaurants" (cat_id=128)
2/ So I would do this SQL request :

UPDATE jos_mt_links, jos_mt_cl
SET Days="Mon,Thu,Fri"
WHERE jos_mt_links.link_id = jos_mt_cl.link_id
AND jos_mt_cl.cat_id= 128

So I don't know if I should create a custom or core field, It seems it isn't possible with custom field and I'm really lost...
I didn't found any solution, can you please help me ?

Thanks again for the response, best reguards

Last edited by tevaimaiau; 03-12-2012 at 08:50 PM.
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Mosets Tree 2.2.0 for Joomla 1.6 released dknight Announcements 0 02-24-2011 11:21 AM
Add New Core field to Hot Property 1.0 !! startprogram Discussions, Troubleshooting and Problems 9 04-19-2009 02:41 AM
Mosets Tree 2.0 released dknight Announcements 0 08-02-2007 05:32 PM


All times are GMT +8. The time now is 03:54 PM.

Copyright © 2005-2010 Mosets Consulting

Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.