Paypal Discount When purchasing two + items (not two instances of same object) - paypal

Paypal has listed out methods for discounts such as :
discount_amount
Optional
Discount amount associated with an item.
It must be less than the selling price of the item. If you specify discount_amount and discount_amount2 is not defined, then this flat amount is applied regardless of the quantity of items purchased.
Valid only for Buy Now and Add to Cart buttons.
discount_amount2
Optional
Discount amount associated with each additional quantity of the item.
It must be equal to or less than the selling price of the item. A discount_amount must also be specified as greater than or equal to 0 for discount_amount2 to take effect.
Valid only for Buy Now and Add to Cart buttons.
I understand that you can have a discount associated with the amount of the same object inside of the cart. I'm wondering if anyone knows a way or method to allow a discount to show up if you say add 3 items or 5 items. Basically the situation is users have the option of signing up for either 1-4 courses. If a user signs up for 1 normal price(lets say 30) occurs. If a second is added they would receive a 10 dollar discount on the tuition(50). Than if a third is added it would show up as the regular method (resulting in 90) However if a fourth is added it would be a charge of 3 courses plus 50. (95). Is there any solution to presenting this to paypal to update based on amount of items (each being different items[different course dates and names]) included in your cart?

If it's for the whole cart and not just the item use discount_amount_cart
Remember discount_amount_1 has to be less in value than amount_1

Related

ATG - Can an Order Level Discount be applied to Items?

Consider I have two items in my cart 50 USD each , I also have a coupon '20 USD off 100'. when I apply this my cart will look like below (for simplicity and focus I am eliminating tax and shipping)
Item 1 50 X1 = 50
Item 2 50 X1 = 50
subtotal =100
discount (-)20
**Total 80
now I have multiple cases where I have to split this 20 USD to items so that returns at third party are easy , also in situations where the two items will be fulfilled by two independent vendors.
I understand that ATG's ReturnManager class provide wealth of methods to calculate returns and does consider all item shipping order discounts and taxes.
but is there a way I can split the order discount to items Out of the Box based on weighted average algorithm.
Thanks
The simplest way to do this would be, to do the splitting algorithm in a Order Pipeline Processor (custom processor) store the split Item Level Discount Shares in a ApportionmentInfo repository item. Whenever, a return occurs you need to access this repository item through the order and display it to the user.
Regards,
Gaurav E
You Can't
Basically OrderPricingEngine will set adjusment against OrderPriceInfo. you cant do apportionment that to item level because the trigger is on order.
Best practice is expose a reprice Order as service to thirdparty. Re run the calculation
and identify the return value. If you customize per promotion level it will open up pandora box of reprice order issue.

Apply Discount to Products in Magento Cart page

I wanted to know how can I give discount value/percentage on cart page for specific product's quantity dynamically via OBSERVER.
Discount can be given on same product's with different quantities.
EX:
Customer add 4 QTY from Product A and I should be able to give 10% discount on 2 QTYs and the discount value should be shown after subtotal (as normal cart rule applied in Magento)
If I can create dynamic cart rule and apply that to products which I wanted that also useful in this case.
http://excellencemagentoblog.com/magento-add-fee-discount-order-total
this is good link to give discount for order , we can modified for particular product & product qty. calculate discount for different product and its qty. add it and setFeeAmount.

How to add dynamic discount amount for one coupon in Magento

How to set dynamic discount amount if an coupon is applied.
For this i have created a shopping cart price rule and send this promo coupon to some customers and when they purchase products from my site and applied this coupon every customers get different discount amount based on the products in their shopping cart so how i can set this dynamic discount amount ?
I have already make some research on salesrule/rule module but getting confused so please help me...
Just for some your knowledge or someone needy finally i have found solution for my question for dynamic discount amount.
to achieve this you need to change in two methods first one is process(Mage_Sales_Model_Quote_Item_Abstract $item) under Mage_SalesRule_Model_Validator class in which you need to change the rule discount amount and set it to any dynamic calculated value like
$rule->setDiscountAmount($dynamicDiscountAmount);
and in the collect method just update the discount amount for display purpose in totals block
$address->setDiscountAmount(-$discountAmount);
$address->setBaseDiscountAmount(-$discountAmount);

Pass variable cart total to PayPal for Subscription (using Enhanced Recurring Payments w. Website Payments Standard)

Summary: Trying to pass along a variable Monthly Subscription cost to PayPal based on user-selected options on a form I created. Working within Website Payments Standard with Enhanced Recurring Payment option, is this possible?
Details:
User visits "shop" page, which is a form with 4 line items, each line item consisting of 2-7 options, each option with an associated price.
For example, line item 1 is "size of business" with the options being:
a) 1-3 employees - $10
b) 4+ employees - $12.50
User goes through the list and chooses 1 option for each line item and some javascript calculates the total due on the fly.
Is it possible to pass this total to PayPal, not as a one-time cost, rather as the base cost for a monthly subscription?
Yes. Just change the value you're passing for a3, rather than amount.
Is there a problem you're running into?

Paypal IPN using PHP to get customized Quantity and Amount

I have downloaded the sample paypal IPN script using php and customised with the email for the buyout option and it has also some hidden paramaters such as amount, quantity,return_url, notify_url like this. My main idea is to do the buyout option for the product purchase in my website.The current calculation for the product purchase is as follows:
Item Price:$20
Quantity :10
Total amount $200
I need the calculation to some different way as our site have some static set of quantities and prices, so our point of calculation is as follows:
Item Price:$20
Quantity :10
Total amount:$20
So, the total amount needs to be the same for the given number of quantities.The IPN configuration doesn't allow me to change the quantity field by this way, please suggest some ideas to overcome this issue.
The item price is price per item, the quantity is of course multiplied by the item price. Your second example should have $2 as the --Item-- price. If you want to sell "10 items for $20", I think you will need to make a new item for that combo and just but the actual quantity in a custom field.
If you want to use the same item and paypal's quantity field, I think you need to look into calculating a discount and making that part of the parameters (discount_amount_cart or discount_amount_X for item X I think).