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

Promotions

Started by Steveinjava, December 14, 2007, 09:25:20 am

Previous topic - Next topic

Steveinjava

Hi Anni! No I still haven't got ANY modules working. Sorry to hear you haven't got Promotions working either.
I am keen to be pointed to a website that DOES have the promotions working actually. Can you tell me where you put the compiled classes like Table.class and Paypal.class (Or whatever payment provider you use).
Presumably you put the promotional classes in the /modules/ordertotal/ directory? Which promotion are you trying to use? I want to allow discount for volume purchases of specific products so have used ProductDiscount.class but the others, like TotalDiscount I haven't tried.
Good luck & hang in there  :D
Steve H

pete

Hi Anni,

Have you gone to the Modules>>Order Total section of the Admin App and actually installed the promotion module that you are using ?

-Pete

Anni

hi steve,

with one exception I didn't do anything to the classes and just left everything as it was. so the classes used in my version will be in the jar files. but otherwise the directory would be classes/com/konakart(admin)/bl/modules/ordertotal/... and resp. for other modules. it should work if you put them there.
and I also just want to use the product discount. just to verify that it actually doesn't work I also installed the total discount and set it up to be active for all products. this didn't work either  :-\
because of this I started printing the promotionIds that are valid for a checkoutOrder to the tomcat console. it seems like for my shop there actually are no promotions ... I just have no idea why that is.

let me know if you find out something new. I'll do the same :)

anni

Anni

hi pete,

yes, everything is installed and I also checked the database entries, which are ok. as I mentioned in the post before I've now installed both promotion types but none of them are working ... neither for specific products nor when active for all products.  ???

regards,
anni

pete

Hi Anni,

As a sanity check I just did a fresh install against a fresh DB. Then I took the following steps:

  • In the Admin App under Modules>>Order Totals I installed the Product Discount and Order Total discount modules

  • In the Admin App under Products>>Promotions I created a new Order Total Discount promotion for 10% discount

  • I proceeded to the checkout section of the application and received a discount. See attached image



I've no idea why it isn't working for you.

-Pete

Steveinjava

Pete, I couldn't see the image you were going to attach...Did you forget
Also do you have a handy image of a product quantity discount working?
Cheers Steve

pete

Hi,

I've attached a screenshot of a 33.3% discount if you buy at least 3 printers.

Steveinjava

Pete, many thanks- It gives me a bit of relief to see it working - I will try again to work out which class isn't in the right place to get my implementation working.
I presume there is some indication on the product page that a discount is available? The promotions description/name being displayed? When I briefly looked, I couldn't find any JSP with logic to display the promotion so had wondered if I had to update more files. I guess the extra functionality is added by inheritance but haven't had time to look for the code. I guess I should look into the JavaDoc & will do so.
Cheers, Steve

Anni

hi again!

I now tried some other things. first, I added the unmodified class files for the product discount to my konakart and konakartadmin apps (i.e. com/konakart/bl/modules/ordertotal/productdiscount/... and com/konakartadmin/modules/ordertotal/productdiscount/...). after deleting all old promotions and setting up a new product discount for all products, it finally worked.  :)
but normally the class files should be in and read from one of the jars, right?

afterwards I started adding rules to that discount. for normal products, i.e. without any options, this still works fine. but the products I need promotions for have two options. to determine which product has a discount I only use one of those.  but that makes the promotion not stop working again ...  :-\

I'll try to figure this problem out. in the worst case I think I'll have to remove one of the options.

Anni

found the problem. I just needed to add both options. so for me it works now.
hope you get it to work as well, steve.

regards

Steveinjava

Anni, great news. I had already manually added the class files that way but it didn't help for me.
If you are using Windows could you just check for me the web apps file structure?
Assuming the use of the default locations for the installation for ProductDiscount.class I have...
C:\Program Files\KonaKart\webapps\konakart\WEB-INF\classes\com\konakart\bl\modules\ordertotal\productdiscount\ProductDiscount.class

Is that the same for you?

I confess with my problems I have been hacking around a bit and want to ensure I am not chasing my own tail.
I also tried a fresh install on to a laptop and I even get errors running it with the sample db! If I hadn't heard your good news I would have been tempted to give up & either continue my own JSP project or (better?) become a beach comber ;D
Steve

Anni

hi steve,

yes, your file path should be correct. I also put in the properties files though I think that won't make a difference. did you also add the productdiscount.class for konakartadmin? not sure if that's the reason why it's not working but it might be well worth a try.

good luck :)

anni

Steveinjava

Anni, cheers for your feedback. Yes I had copied the konakartadmin class files but there again I am a bit confused  ???
In my file structure there are /konakart and /konakartadmin directories within c:Program Files\
but even within C:/Program Files/KonaKart/webapps there are subdirectories entitled /konakart and /konakartadmin
To cover every combination I have copied the C:/Program Files/KonaKart/custom/modules/classes/com/konakart and konakartadmin sundry classes to all the directories in the same relative position in the two places mentioned above.
Is that what you did? Like you, I can't understand why they are not auto-copied when selected...
Thanks in advance for your time when you have it sorted already  :)

kate

QuoteLike you, I can't understand why they are not auto-copied when selected...


What do you mean by this?

If you have not customised the standard modules they will be in their jars already deployed in lib directories. Nothing to do.

If you have customised the modules, how do you think the system will know where you have put the classes to be able to copy them?

Kate

Steveinjava

Hi Kate, if the app does read the lib directory and its jar files then why do I have no shipping,payment or promotion functionality in the web site? I had assumed the selection of a module in the admin app would mean it would read the lib/*.jars, find the relavant classes and insert them into the classes directory, hence my attempts at physically moving them.

Now I am left with no clue as to the problem. ???

Trying a fresh install on a laptop using the default db didn't help- I got different errors but the modules still didn't appear...I had hoped using jdk1.5 instead of 1.6 might have helped. I did get it going on OSCent4 via eApps but my development machines are all windoze.
Steve