Structuring a booking website - mysql

I am very new to web development, and I'm trying to get my head around the most efficient method in creating the website.
The premise of the website is for booking activities in various locations. Processes I believe that would take place are:
Customer books activity;
Request updates database, and request is sent to vendor;
If vendor approves request, confirmation is sent to customer in the form of QR code, barcode, and numerical code (for redemption);
If approved, customer is charged the amount of the activity.
My question is what structure should I use in approaching this problem? My thoughts at the moment is placing the website in Google' app engine, using mySQL database.
Any thoughts would be greatly appreciated.

If you're using GAE, I suggest looking into NDB Datastore. https://cloud.google.com/appengine/docs/python/ndb/
Customer books activity → a) store in ndb datastore and b) verify that information → send to vendor
Confirmation (display URL code e.g. http://website.com/?c=generaterandomlongstringhere)
If URL is clicked, you can add a confirm as well after like accept | decline (e.g. http://website.com/?c=generaterandomlongstringhere&?v=acceptordecline)
Update NDB and Charge user

Related

Telegram Usage for Registration site

I have a registration site that accepts registrations for an event.
This is based on woocommerce Word Press theme.
For every successful registration, woocommerce is sending a) Registration receipt b) Registration processed c) If registration went on hold 4) Customer Note 5) Ticket for the event (after completion) process
All these 5-6 customer touch point mail contents - I'm catching into files.
My objective is to send these files as well as some additional messages to Registrants through Telegram.
I'm able to do this using Telethon library and a Python script.
However I'm not sure if this is in any way disallowed since it involves many registrants (probably 5000+)
Would Telegram consider this as acceptable usage ?
Has anyone come across similar usage / situation. Please guide me. I do not want to realize that I did something wrong at a later time.
Thank you for your help.
The intended design and messaging Python script / Telethon all are working well.
N/A
Is this acceptable usage ?

Gmail add-on to pull data from many URLs

We are writing a Gmail add-on for synching the user's work schedule into his/her Google calendar. This requires logging into the the employer's workforce management application and fetching data from it. Every different employer is a different customer with a different URL. So, for every customer who wants its employees to be able to use this, we have to add another URL to urlFetchWhitelist and openLinkUrlPrefixes in appsscript.json. We could potentially have hundreds of customers using it. Is there a limit to how many URLs we can put into urlFetchWhitelist and openLinkUrlPrefixes? Or is there another way to solve this?

Is there any API for checking a Status of a given Order with Realex Payments?

I am wanting to integrate Realex for my upcoming E-Commerce website. Imagine a scenario as mentioned below:
Customer came to the site, added the products to the Cart and moved ahead to payments.
Now, Customer entered his details on the payment page, and clicked
on the “Pay Now” button.
Imagine below given possible issues (Bad transactions) which might
occur and I am trying to overcome the same:
A. The request was processed successfully by Realex, and while redirecting to my Server URL there was a Network glitch due to which the Redirection failed.
B. The request was processed successfully by Realex, and as it was redirecting there was an Issue with my Server side (let’s suppose some Code related issue).
Now, in the both above mentioned scenarios I need to understand, if there is any way wherein I can check the given Order’s status without manually doing so?
i.e. Is there any Status check API which can provide me the status of the Order, i.e. if it was processed successfully and I might go ahead with the Order or either go ahead for the Refund to the given Customer?

Updating Woocommerce Orders Programmatically

I have an eCommerce site running Woocommerce on top of Wordpress, and the company running it has changed there shipping system to an external company who stores the products in their warehouse and ships the products when they are bought.
In terms of automation, downloading information on new orders and sending it to the shipping company is fine, but when they respond to me with an XML of the orders sent and the associated tracking numbers, I need to be able to have a system that automatically updates the orders (including sending out the emails necessary). However, the only way I currently know how to do that is to update the MySQL database. But with that method, the automated email system is overridden and ignored.
Does anyone know how I can update orders statues and other information programmatically, which would allow Woocommerce's internal functions to be executed in the same way as manually logging into the admin side and updating the order?
Found a solution to this yet?
The code below works to mark an order as complete, but does not execute other actions as you describe in the admin
// create a new checkout instance and order id
$checkout = new WC_Checkout();
$this_order_id = $checkout->create_order();
$order = new WC_Order($this_order_id);
$order->update_status('completed');

Maintain parallel, identical databases: MySQL and SharePoint FBA

I have 2 websites, and both have a login system, where the user can create an account to access a special portion of our website. Website A is a standard LAMP creation, and the user information is thus stored in a MySQL database. Website B is a site that is hosted on SharePoint and the user information is stored in a SharePoint Form Based Authentication (FBA) database.
I want to make it so that when a user creates an account on Website A, an account is automatically created on Website B.
Does anybody know of an easy way to do this? I'm thinking when the account is created on Website A, the website can send a query to both databases and create the same information. OR the 2 databases could be kept in sync somehow.
Any help would be greatly appreciated! Thanks much.
Regarding your first method: I think it's not good solution because you have to wait until server b won't response. Better way is to use event model based on queue.
You have queue of ids which are new created users and add user_id from the first server to this queue during user's creation. From other side you have cron script with infinite loop
while(1) {
sleep(10);
//check new user_id in queue
if (no) {
continue;
}
//create a new user in server B and remove user_id from queue
}