• Welcome to KonaKart Community Forum. Please login or sign up.
 

Show posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Messages - DispatchMediaGroup

16
Configuration of KonaKart / Re: Product Option IDs
September 27, 2011, 09:16:09 pm
Does anyone have any ideas on this?

More abstractly than this particular issue, there have arisen a couple of scenarios where eCommerce stakeholders would like some changes in the Admin App.  What is the workflow for this and is there any documentation I can peruse?

Further, along with the Product Options ID issue, on both the Customer Order Details page and the Product listing page, I would like to make a small enhancement to display the Product ID as well.

For non-admin changes such as these, I would look for the pertinent JSP under /webapps/konakart/WEB-INF/jsp/ ... no such path for admin stuff.  I do know that the admin app is driven (entirely?) by GWT - will I need to take similar steps for admin app alterations as I would for one-page-checkout code?
17
Welp, figured that out...just had to read the documentation more closely:

You need to make the call getProduct(String sessionId, int prodId, int languageId); this will return you the Product object with all associated information.
19
Any word on this?  I'm having similar issues using the Web Service KK app engine.  In my CMS, I make a web service call to get all products in a category, but I can see in the javadocs that the Product Options will not be set using this call.  Looking further through the javadocs for the WSAppEng, I see no way to get the Product Options for a given product.  Does anyone know how this can be accomplished, even if it were a separate call?
20
Configuration of KonaKart / Product Option IDs
August 25, 2011, 06:51:51 pm
Hey KonaKarts,

Is there a way to make the admin app display the IDs of Product Options on the product options creation screen?
21
Thank you so much, kate!  As it turns out, the documentation had nothing that even hints that this would be the issue, but if you use a DataDescriptor, you must use setLimit() to get any actual objects back, although the method call getTotalNumProducts() will reflect the correct total amount of results you'd expect.

Again, thank you, kate; I'm sure this little tidbit will help others like myself.  If there was some sort of poster rating, I'd plus one ya!
22
No one else knows anything about this?  The method call knows the correct number of Orders, but I cannot access them when I try to retrieve the array of Orders.  There has to be some stupid nuance I'm missing here.  And I'd really rather not write a bunch of SQL and build POJOs myself if the KK WS engine can already, ostensibly, do this for me...
23
I'm not sure what the root cause is, but it does look like this is a database server issue.  See the references below:

http://dev.mysql.com/doc/refman/5.1/en/statement-repreparation.html
http://bugs.mysql.com/bug.php?id=42041

Also, some people have reported that upping the value of table_definition_cache and table_open_cache may help assuage the issue.
24
That helped, thank you Trevor.  As in some of my previous posts, it turns out I was a step or two away from figuring this out...in this instance, I hadn't set up any product option parent categories.  Under 'root', I had just added some product options, without realizing that I was actually creating product option categories, which of course, you cannot assign to a product.
25
i get this error as well, and it seems to be linked somehow to the version of CentOS we're using.  the reports will run fine, but the charts aren't usable.
26
Hi KonaKarts,
    I'm having a bit of trouble here that I feel should be easily resolvable.  I'm making a web service call to my KonaKart server to get a list of all orders a specific customer has made.  Everything seems to be working okay, except that when I try to call getOrderArray(), it returns nothing.  You can see my code snippet below.  One thing to note here is that by calling getTotalNumOrders(), I can see that the WS engine does in fact know the correct number of orders, but when I try to get the actual array of orders, it gives me nothing.  Am I not utilizing the DataDescriptor correctly?


// CREATE DATA DESCRIPTOR FOR GETTING ORDERS BY ORDER DATE
DataDescriptor descriptor = new DataDescriptor();
descriptor.setOrderBy(DataDescConstants.ORDER_BY_DATE_ADDED_DESCENDING);

// USES CUSTOM METHOD FOR GETTING KK WS ENGINE
// ALSO USES CUSTOM METHOD FOR LOGGING IN A CUSTOMER
// -- BOTH OF THESE METHODS HAVE BEEN VALIDATED TO WORK AS EXPECTED
Orders orders = getKonaKartEngine().getOrdersPerCustomer(descriptor,
login(user), DEFAULT_LANGUAGE_ID);

if (LOG.isDebugEnabled())
{
        // THIS RETURNS THE CORRECT NUMBER OF ORDERS
LOG.debug("Number of orders (getTotalNumOrders) ... "
+ orders.getTotalNumOrders());

        // THIS RETURNS NOTHING (i.e. 0)
LOG.debug("Number of orders (orderArray.length) ... "
+ orders.getOrderArray().length);
}
27
no reply to this?  this is kind of an important question for anyone who would like to programatically leverage/alter KK code.  Even if an admin could reply with a link to an answer...
28
I did figure this one out, actually.  Thank you for your reply and attempt at help though.  For others going through this process, there's a bit more to the steps that must be taken than the documentation might have suggested, although it probably should have been fairly obvious to anyone with experience in application deployment and web configuration.

I had literally just copied the generated javascript file, but nothing else, to <konakart>/webapps/konakart/.  But there's much more that should have been done on my part, which I will try to detail as well as possible below (admins, correct any mistakes, please):

1.) Go through the KonaKart documentation for making changes to the one-page-checkout (OPC) process, and continue to follow the documentation for ant building the OPC code.

2.) All generated classes and files will be put in /<konakart>/custom/onepagecheckout/war/.  Under this directory, there should be three folders: com.konakart.Konakart, images, and WEB-INF.
     - com.konakart.Konakart
          -- the contents of this generated folder should be copied to /<konakart>/webapps/konakart/, overwriting any files needed.
     - images
          -- this folder should also be copied to the aforementioned location, /<konakart>/webapps/konakart, merging with any existing files at that location
     - WEB-INF
          -- the contents of this should be copied to /<konakart>/webapps/konakart/WEB-INF/.  Particularly pay attention to where the new classes folder gets copied.  You will want to keep the contents of the original classes folder, but added to that will be a new folder structure which will contain the newly generated class files needed to interact with the javascript and GWT code.  So, your WEB-INF folder should have a bunch of messages files in it, along with com/konakart/.../.
          -- My recommendation would be to just copy the class files you need into WEB-INF (maintaining the necessary folder structure), and letting the class loader handle using those files.  I know this methodology will work with Tomcat installations, as the WEB-INF/classes location takes precedence over the lib folder.  This also means that you won't need to create/edit any jar files, and will, ostensibly, keep upgrade paths simple in the future, as these class files can be swapped with newer ones.

3.) After copying all new classes and folders to their respective locations, I would advise removing the following two folders, which will make sure that the new classes and such are being used: /<konakart>/temp/ and /<konakart>/work/.

4.) Restart Tomcat.

For me, using a headless Linux install as my KonaKart server, I was not able to completely use the dev shell method outlined in the documentation.  Rebuilding the custom OPC code and copying pertinent class files allowed for fairly easy development and testing.  I hope this helps others who share my general lack of experience and knowledge when it comes to deployment and class-loading mechanisms.  Again, any admins or konakarts, please feel free to update and/or correct my information posted in this thread to help with documentation and others' development.
29
Here are the two onepagecheckout files that I edited.  You can see the changes and comments on the changes' purpose.  I made changes to Konakart.java at line 395, where action== REGISTER_KO and at LoginBody.java at line 248, where I added a method that gets called from the aforementioned Konakart.java.

My purpose in these changes is to alter one aspect of the onepagecheckout process.  When a Customer uses onepagecheckout with an email address that's already been registered with KonaKart, I want to display a custom message with a link off to a Dispatch.com (my company's site) login page.  That login page would take care of redirecting back to the KonaKart checkout process, where the customer would then be logged in to KonaKart, effectively bypassing the onepagecheckout process.  However, it does not seem that the newly compiled code has any effect. Hope this addendum helps...
30
Well, I made all the onepagecheckout GWT changes I wanted to and ran the ant script.  The compilation went okay, outputted success, and generated a whole bunch of new files, including one javascript file, at the location, /usr/local/konakart/custom/onepagecheckout/war/com.konakart.Konakart/.  I then copied everything in that directory to /usr/local/konakart/webapps/konakart/.  The only javascript file that was generated was called com.konakart.Konakart.nocache.js, which matches the GWT javascript I was able to find that came packaged with KonaKart.

But when I restart KonaKart and then test the one page checkout process, I get the exact same results and behavior as I did before.  Anyone have any ideas?  Am I missing a step, putting files in the wrong place, etc.?  Is there more I can post to help others help me?