Working : Coupon : fix update effect (becomes type), update max usage

This commit is contained in:
gmorel
2013-09-19 23:25:01 +02:00
parent b545e1c012
commit 8e308d21e9
8 changed files with 50 additions and 34 deletions

View File

@@ -54,7 +54,7 @@ class Coupon extends BaseCoupon
* @param string $code Coupon Code
* @param string $title Coupon title
* @param float $amount Amount removed from the Total Checkout
* @param string $effect Coupon effect
* @param string $type Coupon type
* @param bool $isRemovingPostage Is removing Postage
* @param string $shortDescription Coupon short description
* @param string $description Coupon description
@@ -67,13 +67,13 @@ class Coupon extends BaseCoupon
*
* @throws \Exception
*/
function createOrUpdate($code, $title, $amount, $effect, $isRemovingPostage, $shortDescription, $description, $isEnabled, $expirationDate, $isAvailableOnSpecialOffers, $isCumulative, $maxUsage, $locale = null)
function createOrUpdate($code, $title, $amount, $type, $isRemovingPostage, $shortDescription, $description, $isEnabled, $expirationDate, $isAvailableOnSpecialOffers, $isCumulative, $maxUsage, $locale = null)
{
$this->setCode($code)
->setTitle($title)
->setShortDescription($shortDescription)
->setDescription($description)
->setType($effect)
->setType($type)
->setAmount($amount)
->setIsRemovingPostage($isRemovingPostage)
->setIsEnabled($isEnabled)