[TYPO3-commerce] Coupon extension - every visit increase the money amount reduction in the basket

Ralf Merz ralf.merz at heindl.de
Tue Sep 30 12:07:51 CEST 2008


Hi there,

sorry for answering a bit late. But I can hardly find time at the moment.

Christian schrieb:
> Hello Søren,
> Thanks for your investigation.
> I'm a bit lost now. I made the correlation between TS, article_type_uid 
> and article_title but I can't see now the result of the 
> ###COUPON_VIEW### marker.
> The coupon is Ok when I visit the page again but not when i recalculate 
> the basket by modifying the existing quantity of an article or just 
> click on the "calculate" (input type="image" as a submit button) button.
> The value is the double now and it is corrected when I click on my 
> basket again.
> 
> Here is my configuration
> 
> In the backend :
> article_uid for syscoupons is 6
> article_uid for syscoupons_special is 7
> article_uid for syscoupons_use is 8
> 
> TS Setup
> plugin.tx_commercecoupons_pi1 {
>  couponNormalType = 6
>  couponRelatedType = 7
>  couponBuyType = 8
> }
> 
> plugin.tx_commerce_pi2{
>    couponNormalType = 6
>    couponRelatedType = 7
>    couponBuyType = 8
>    couponBasketTemplateFile = EXT:commerce_coupons/pi1/couponsInBasket.tpl
> }
> 
> plugin.tx_commerce_pi3{
>    couponNormalType = 6
>    couponRelatedType = 7
>    couponBuyType = 8
>    couponArticleId = 50
>    couponListingTemplateFile = 
> EXT:commerce_coupons/pi1/couponsInListing.tpl
>    couponFinishTemplateFile = EXT:commerce_coupons/pi1/couponsInFinish.tpl
>    couponMailsTemplateFile = EXT:commerce_coupons/pi1/couponsInMails.tpl
> 
> }
> 
> Christian

If you want to have a normal coupon, money or percent, you have to 
choose "syscoupon".
The type "syscoupon_special" has been ment to be used for coupons with 
related articles, "syscoupon_use" was ment for coupons that you can buy 
in the shop.
The last one is still buggy. (Well, you´ll laugh now as there are still 
other bugs, right?)

> 
> Søren Thing Andersen wrote:
>> Hi.
>>
>> Christian skrev:
>>  
>>> I have a strange behaviour with the extension "commerce coupons 0.2".
>>> When I put a coupon in the basket, the coupon plugin show me that the 
>>> coupon is valid and invit me to check the basket again so the 
>>> ###COUPON_VIEW### marker is filled in the commerce basket template.
>>> The problem is that each time I visit my basket, the coupon value is 
>>> multiplicated by the number of time I reload/visit my basket o_O
>>> Anyone else encountered this problem ? I put the coupon plugin before 
>>> or after the pi2 commerce plugin and it's the same behaviour. I also 
>>> deactivated the hooks I created for commerce but nothing can solve 
>>> this problem.
>>>     
>>
>> I had the same problem at first.
>> Based on ext/commerce_coupons/doc/quick_howto.txt and the thread 
>> "[TYPO3-commerce] commerce_couponss" from last year I chose to use the 
>> article "syscoupons_use".
>>
>> Today I found the following text in the top of 
>> ext/commerce_coupons/static/setup.txt:
>> ######## Note:
>> # couponNormalType is the Id of the normal coupons, which are money or
>>    percent
>> # couponRelatedType is the Id of coupons that have an related article
>> # couponBuyType is meant as Id if you have coupons that can be bought by
>>    customer, not in use here at the moment
>>
>> A little below:
>>    couponNormalType = 4
>>    couponRelatedType = 5
>>    couponBuyType = 6
>>
>>  From typo3 backend => Commerce = Category I clicked in the tree at
>> Category => SYSTEM => COUPONS => syscoupons_use.
>> At the bottom (second last field) article_type_uid has the value
>> [ INVALID VALUE ("6") ]
>>
>> So it seems that the relations are like this:
>> (TypoScript-variable = Article_type_uid = Article title)
>> couponNormalType  = 4 =    syscoupons       
>> couponRelatedType = 5 = syscoupons_special
>> couponBuyType     = 6 = syscoupons_use
>>
>> Baed on this I changed the article to "syscoupons" in my test coupon, 
>> and now it seems to work - no ever increasing discount any more ;-)
>>
>> As a side note: Should commerce_coupons create the 3 article types (4, 
>> 5 and 6) that it expects, or should this step just be added to the 
>> documentation?

The 3 articles types are hard coded at the moment. This schould be made 
changeable by EM or Constant Editor because there is the possibility 
that those IDs are already given to other article types. But in a normal 
shop, 1 (articles),2(payment) and 3(delivery) are set, higher numbers 
are free.

Did you come along now with that Extension?

Kind regards
Ralf Merz



>>
>> /Thing
>> _______________________________________________
>> TYPO3-project-commerce mailing list
>> TYPO3-project-commerce at lists.netfielders.de
>> http://lists.netfielders.de/cgi-bin/mailman/listinfo/typo3-project-commerce 
>>
>>   
> 


-- 
--
Greetings
Ralf Merz

Heindl Internet AG
Tübingen , Germany
ralf.merz at heindl.de


More information about the TYPO3-project-commerce mailing list