www/includes/db_inventory_yeasts.php

changeset 20
22271f3598ac
parent 18
395833e20f88
child 33
2ee6ad5d6f14
--- a/www/includes/db_inventory_yeasts.php	Thu Aug 16 16:38:20 2018 +0200
+++ b/www/includes/db_inventory_yeasts.php	Thu Aug 16 17:17:40 2018 +0200
@@ -16,8 +16,6 @@
 	$sql  = "INSERT INTO `inventory_yeasts` SET name='" . mysqli_real_escape_string($connect, $_GET['name']);
 	$sql .= "', type='" . $_GET['type'];
 	$sql .= "', form='" . $_GET['form'];
-	$sql .= "', amount='" . $_GET['amount'];
-	($_GET['amount_is_weight'] == 'true') ? $sql .= "', amount_is_weight='1" : $sql .= "', amount_is_weight='0";
 	$sql .= "', laboratory='" . mysqli_real_escape_string($connect, $_GET['laboratory']);
 	$sql .= "', product_id='" . mysqli_real_escape_string($connect, $_GET['product_id']);
 	$sql .= "', min_temperature='" . $_GET['min_temperature'];
@@ -26,9 +24,7 @@
 	$sql .= "', attenuation='" . $_GET['attenuation'];
 	$sql .= "', notes='" . mysqli_real_escape_string($connect, $_GET['notes']);
 	$sql .= "', best_for='" . mysqli_real_escape_string($connect, $_GET['best_for']);
-	$sql .= "', times_cultured='" . $_GET['times_cultured'];
 	$sql .= "', max_reuse='" . $_GET['max_reuse'];
-	($_GET['add_to_secondary'] == 'true') ? $sql .= "', add_to_secondary='1" : $sql .= "', add_to_secondary='0";
 	$sql .= "', inventory='" . $_GET['inventory'];
 	$sql .= "', cost='" . $_GET['cost'];
 	$sql .= "', production_date='" . $_GET['production_date'];
@@ -47,8 +43,6 @@
 	$sql  = "UPDATE `inventory_yeasts` SET name='" . mysqli_real_escape_string($connect, $_GET['name']);
 	$sql .= "', type='" . $_GET['type'];
 	$sql .= "', form='" . $_GET['form'];
-	$sql .= "', amount='" . $_GET['amount'];
-	($_GET['amount_is_weight'] == 'true') ? $sql .= "', amount_is_weight='1" : $sql .= "', amount_is_weight='0";
 	$sql .= "', laboratory='" . mysqli_real_escape_string($connect, $_GET['laboratory']);
 	$sql .= "', product_id='" . mysqli_real_escape_string($connect, $_GET['product_id']);
 	$sql .= "', min_temperature='" . $_GET['min_temperature'];
@@ -57,9 +51,7 @@
 	$sql .= "', attenuation='" . $_GET['attenuation'];
 	$sql .= "', notes='" . mysqli_real_escape_string($connect, $_GET['notes']);
 	$sql .= "', best_for='" . mysqli_real_escape_string($connect, $_GET['best_for']);
-	$sql .= "', times_cultured='" . $_GET['times_cultured'];
 	$sql .= "', max_reuse='" . $_GET['max_reuse'];
-	($_GET['add_to_secondary'] == 'true') ? $sql .= "', add_to_secondary='1" : $sql .= "', add_to_secondary='0";
 	$sql .= "', inventory='" . $_GET['inventory'];
 	$sql .= "', cost='" . $_GET['cost'];
 	$sql .= "', production_date='" . $_GET['production_date'];
@@ -93,8 +85,6 @@
 			'name' => $row['name'],
 			'type' => $row['type'],
 			'form' => $row['form'],
-			'amount' => $row['amount'],
-			'amount_is_weight' => $row['amount_is_weight'],
 			'laboratory' => $row['laboratory'],
 			'product_id' => $row['product_id'],
 			'min_temperature' => $row['min_temperature'],
@@ -103,9 +93,7 @@
 			'attenuation' => $row['attenuation'],
 			'notes' => $row['notes'],
 			'best_for' => $row['best_for'],
-			'times_cultured' => $row['times_cultured'],
 			'max_reuse' => $row['max_reuse'],
-			'add_to_secondary' => $row['add_to_secondary'],
 			'inventory' => $row['inventory'],
 			'cost' => $row['cost'],
 			'production_date' => $row['production_date'],

mercurial