Get basket items - to send via email

  • Posts: 5
  • Thank you received: 0
11 years 11 months ago #88664

Hello

I am currently dealing with a request from a client to be able to produce an 'enquiry list' of products - that would run along the existing payment method on the site.

The client wants to have both hire and purchase items on the site, so need an enquiry option as well as a 'pay' option.

My theory is that if I can get the list of current items in the basket, I can input a button on the checkout page for 'Click to enquire'.
I could use the list to produce a form, which could then be sent via email to the client without the need to pay for the items.

I can't see anything on the API and wondered if anyone had done anything like this before?

Thanks
Alan

Please Log in or Create an account to join the conversation.

  • Posts: 13201
  • Thank you received: 2322
11 years 11 months ago #88798

Hi,

I don't remember that someone already need this functionality.

What about a payment method like "check" and edit it to "Hire". In the payment method configuration change the title of the payment method and the description to describe the function of this method.
By this way, when a customer have products in cart and use this payment method, he don't need to pay the items, and he will receive an email with the products in it.

Please Log in or Create an account to join the conversation.

  • Posts: 5
  • Thank you received: 0
11 years 11 months ago #88878

Thanks - i think this works. The only thing is that the hire items have no price attached - so that they cannot be purchased.

However this means that the payment options are not displayed.
I'm assuming the php code in the checkout component only displays the payment plugins if the price is greater than 0. I can't seem to locate where this happens, so I can change it to show payment options in every scenario.

Can you help with this?

Many thanks

Please Log in or Create an account to join the conversation.

  • Posts: 13201
  • Thank you received: 2322
11 years 11 months ago #88971

If they can't be purchased so why display a payment method ?
Why not display only a message ?

If all the products are free, you display a message, the payment methods are not displayed, and the checkout can be finished.
In the checkout options, you can set the default order status to "confirmed" and in each payment methods to "created".

By this way the Hire process give a confirmed status and no payment, and the regular process create a "created" order and take the customer to the payment to confirm the order.

Please Log in or Create an account to join the conversation.

  • Posts: 5
  • Thank you received: 0
11 years 11 months ago #89263

Sounds perfect - how do i display a message instead of payment methods - when the total is 0?

Please Log in or Create an account to join the conversation.

  • Posts: 13201
  • Thank you received: 2322
11 years 11 months ago #89390

You can edit the view "checkout / payment" and at the end of the file add:

else if(bccomp($this->orderInfos->full_total->prices[0]->price_value_with_tax,0,5)==0){
    echo JText::_('HIRE_CHECKOUT');
}

And add a translation for the key "HIRE_CHECKOUT" in Configuration > Languages in the override part.

Please Log in or Create an account to join the conversation.

Time to create page: 0.069 seconds
Powered by Kunena Forum