Summary

A PHP and MySQL based web application that manages collection and storage of prices for tombolas and provides lists for organized collocation of the prices for each customer.

Source code on request.

Main features:

Avoiding Double Occupancies

query_creators.php (snippet)

// Adds a customer and returns its CID
function addCustomer(mysqli $dbConnection, $customerName){
  // Use a transaction to ensure retrieving the right customer ID
  $dbConnection->begin_transaction();
  // SQL query to Insert a new customer...
  $dbConnection->query('INSERT INTO Kunden(Name) VALUES("' . $customerName . '");');
  // ... and get its ID
  $res = $dbConnection->query('SELECT LAST_INSERT_ID()');
  // Execute transaction
  $dbConnection->commit();
  // Print errors
  echo $dbConnection->error;
  // Return Customer ID
  return $res->fetch_array(MYSQLI_NUM)[0];
}
Landing page with different menu option.
Landing page.
Screen for adding new prices.
Add new prices screen.