KonaKart Community Forum

Installation / Configuration => Configuration of KonaKart => Topic started by: andarilhoestelar on February 24, 2008, 11:46:11 pm

Title: Custom fields
Post by: andarilhoestelar on February 24, 2008, 11:46:11 pm
How do I add a custom filed to a product?
Title: Re: Custom fields
Post by: heidi on February 25, 2008, 05:40:54 am
I'm not sure what you mean.   There are already 5 custom fields on product that you can use.
Heidi
Title: Re: Custom fields
Post by: andarilhoestelar on February 27, 2008, 02:00:42 am
Hi heidi.

Yes, there are 5 custom fields in a tab of the edit product page, but I don't know how to use them.

Is it possible to define a label for each field?
How can I show the labels and values of the fields in the product page?

For example, I am building a virtual book store. I need the following custom fields: author, pages, year
How can I put them in the product?

Thks

Title: Re: Custom fields
Post by: heidi on February 27, 2008, 05:52:21 am
Hi,

QuoteIs it possible to define a label for each field?

For the Admin App?   Yes...  You can modify the message catalog:
http://www.konakart.com/configurationfaq.php#HowToTranslateTheAdminApp
For the application?  Yes, modify the JSPs.

QuoteHow can I show the labels and values of the fields in the product page?

Modify the JSPs to pick out the custom field values that you require.  The custom field values will be available on your product object.

Heidi
Title: Re: Custom fields
Post by: andarilhoestelar on February 27, 2008, 01:11:46 pm
Hi Heidi!

Another question, is it possible to search products (keywords) using values stored on custom fields?

Thanks for helping me!
Title: Re: Custom fields
Post by: heidi on February 27, 2008, 01:19:44 pm
Yes, check out the javadoc:

http://www.konakart.com/javadoc/server/com/konakart/appif/KKEngIf.html#searchForProducts(java.lang.String, com.konakart.appif.DataDescriptorIf, com.konakart.appif.ProductSearchIf, int) (http://www.konakart.com/javadoc/server/com/konakart/appif/KKEngIf.html#searchForProducts(java.lang.String, com.konakart.appif.DataDescriptorIf, com.konakart.appif.ProductSearchIf, int))

.. and look at AdvancedSearchSubmitAction.java where you'll find an example....

... which is the code behind the demo:

http://www.konakart.com/konakart/AdvancedSearch.do

Heidi