Changing Miminum Amount Upon Checkout

Hello,



I have a company that is currently working on their pricing of products. Until then, we have them all listed as $0.00 and are allowing customer to “request” a quote for each item by simply adding an item to the cart and sending in an order. Upon receipt of the invoice, we either call or email the customer about actual pricing and conduct business in that fashion. The company is a distributor which is why we’re doing things differently.



The problem at hand is that we cannot find a way to allow customers to send in orders with a miminum amount at $0.00. The cart will simply say “[COLOR=“Red”]To continue checkout process your order total must exceed $0.00.[/COLOR]”



Is there anywhere in the code that I can change to allow orders to go through for amounts that result in $0.00? There must be a conditional statement somewhere in the code, but I simply can’t find it anywhere among the templates or php files.



Any help would be greatly appreciated.



Regards,



Jim

I hope I don’t mislead you here

but I had to do something like this in the past…

I don’t recall (and can’t locate it) but it had something to do with some

code that said something like “read only” as a variable or something like that

sorry I can’t be more help



edit: i recall i may have altered the .js code too…(…i think)



now…to top it off, i just checked one of my 0.00 priced items and i am getting a strange code in the amount…

:slight_smile:

so…maybe we should just disregard this reply…



wonder what i did??

Thanks! I’ll look into it. I have PHP experience so I figured there was something in the code somewhere, but I’m also seeing a lot of javascript and Ajax code which is something I’m not heavily familiar with, so I thought I would ask some of the more experienced users here. It’s probably something simple, it’s just taking some time wading through all the code for CS-Cart right now. I’m sure I’ll find it sooner or later.



If I can find a way to allow items that cost $0.00 to checkout and complete orders that would be great. Currently I am setting all products to $0.01 which works of course, but that is kind of unprofessional for the size and type of company I work for.



Thanks again!

i know it can be done, and it must not be too hard if i did it…



i just can’t remember how i did it…

There is an option to allow free checkout of items. Either in the settings somewhere or when actually adding the product.

maybe the “zero price action” for each product?

Thanks everyone for the replies.



The problem is that when the total amount due is $0.00, the shopping cart will not allow you to view the payment step which contains choices for faxing, calling, or obtaining a purchase order. The Cart claims that any order that totals $0.00 will not be allowed to be further processed. --“[COLOR=“Red”]To continue checkout process your order total must exceed $0.00.[/COLOR]”-- Even with a Free checkout or “zero price action”, this will lead to a total amount of $0.00. I need to get the cart to recognize that any order with a total amount due of $0.00 is a legitimate order regardless if the amount totals $0.00. I will investigate further and update this post with a solution when I find one. Thanks again for the replies. They help me very much in making sure I am looking at all options.



Regards,



Jim

Fixed my problem at least without any side effects so far. Here’s what I did.



In file /core/[COLOR=“red”]fn_cart.php [/COLOR]edit line 2777 and change from $result = [COLOR=“Blue”]false[/COLOR]; to $result = [COLOR=“blue”]true[/COLOR];



Then in /skins/basic/admin/[COLOR=“Red”]payment_methods.tpl[/COLOR] change line 8 from {if $cart.total|floatval} to {if $cart.total}



I tried a ton of different things and I believe in the end, these were the two changes that made everything work the way I wanted it to. Line 2777 basically removes the $0.00 minimum condition and makes anything put in the cart result in true.



With regards to line 8 of the payment_methods.tpl, I understand where the floatval pops up around the code, but I have no idea why when removed it makes things work. It is a part of the conditional, but I am not sure why. Since I edited line 2777, the $cart.total works so I didn’t need to remove that.



Sound complicated? Yeah, it pretty much is, however if anyone knows what I’m talking about here and can see any problems, I’d really appreciate any additional info. Otherwise case closed in my book and I’m off to the next programming task.



Thanks very much.



Jim