Tours Site

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.
5 years ago
Hey guys how are you all doing ?

So im delevoping a tours site with nopcommerce and I need to create a administration table that get orders before the checkout (like shopping cart) to check if we have the trip avaibable and freeze the payment, only when we on the table put the status avaivable the customer can proceed to checkout and payment.

Someone have an idea  how can i do this ?

Thanks for all opinions !!
5 years ago
I would hack the wishlist for this.

Something like: disable the normal shopping cart for the visitors, only make the wishlist available to public who would place the selected tour(s) in their wishlists, you then approve it by moving the wishlist items into their shopping carts and notify them that the cart is ready for payment.  They would log in again and do the checkout with their shopping cart.

you will need some customization for this

You can also put the customer with approved items into a special role (like approved), that would allow him to place the wishlist items into the shopping cart.
5 years ago
Can you tell me how to do this please ?

Like how to disable the shopping cart etc
5 years ago
A manual approach with no coding, just a little .chtml editing:

- check the 'Disable buy button' for all tours, left the Wishlist button enabled. (you can chose a theme where the wishlist button has text on it, you can change it to 'Select tour'
Your customers can only place items in the wishlist and not in the shopping cart.  (change all description text and guides in the shop so that they will not be confused of this)

- When they are ready with the wishlist, the go into their wishlist, and press 'Email a Friend' button (which you rename 'Pre-Order Tour' or something similar_, in the next Form you change Friend's email text to your company name, and edit the .cshtml file to preload the admin's email address and make this field not editable.  You change the button below to  'Send Request'

- When the admin receives the email with the wishlist, he checks the selected tour(s) for availability, he the logs in as admin. Closes the shop, so nobody can directly buy the item in this short time, and unchecks the disable but button in the product. He then impersonates the customer, goes into his wishlist, and presses the 'Add to cart' button in the wishlist. The tours are now in the shopping cart. Admin finishes impersonation. Checks the disable buy button again in the product, and opens the shop. (the shop was closed for ca. 10 seconds, if you don't have 100 visitors on your website, I would not even bother to close the shop for this time)

- Replies the customer in an email that the tours are ready for payment, the customer logs in any time he wants and does the checkout and payment in his shopping cart.


A more professional approach with very little coding:

- would be to add a role to the admin that would allow him to override the disable buy button's effect. So it will be not needed the uncheck/check this button in the product's datasheet.

..if you can go thru the first part and ready for the coding part, we can go on with this


The ultimate solution with more coding:  This requires more time and programming skills

Eliminate the need to impersonate the customer.  Make all wishlists viewable for the admin in a new View page.  Add a button to the wishlist's admin view that would place the items in the customer's shopping cart and send the email to the customer that the shopping cart is ready for payment.

(I may be some time later be available for more help you asked for, but I think you can start with the info above)
5 years ago
the ideia was aproved and worked very well !!!

Thank you!

When you have time send me a dm so we can talk about the advanced mode !

one more time thanks ! you have saved me
5 years ago
Hey i founded a bug that when the chekcbox 'disable buy button' is checked the customer can´t check out !!!!

How do I fix that ? someone know ?


thanks
5 years ago
Hi, I think it was meant so by the nopcommerce team (ie. checkout is also disabled if buy button is disabled), but I think with this naming of the setting it is a bug. A 'disabled buy button' should just mean no buy button would show up. What it does now is 'disabled buy' or 'disabled checkout', now it not just prohibits placing the item in the cart but also disallows checking out with an item already placed in the shopping cart.

I agree with the nopcommerce team that this behaviour is wanted more often but the naming of this setting is misleading so, why just not name it 'disable buy' then.

Having two distinct settings would be the perfect approach: 'Disable buy button' and 'Disable checkout' and each one would do only what they say.


The quick solution to your problem can be done only with a little code modification that would result disregarding this setting in all shopping cart related procedures.

In the ShoppingCartServices.cs  file find these lines  (they are in the GetStandardWarnings method, in my code they are at line 290):

//disabled "add to cart" button                  
if (shoppingCartType == ShoppingCartType.ShoppingCart && product.DisableBuyButton)
{
    warnings.Add(_localizationService.GetResource("ShoppingCart.BuyingDisabled"));
}

and comment them out like so:
//if (shoppingCartType == ShoppingCartType.ShoppingCart && product.DisableBuyButton)
//{
//    warnings.Add(_localizationService.GetResource("ShoppingCart.BuyingDisabled"));
//}

then recompile the whole solution and change the modified .dll files on the server.
5 years ago
Hey bro thanks for the quick response ,


It worked !

Thank you so much !!!!!!!!!!!!!

You saved my life haha
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.