From b0c23ea84327d48e3a4383fac3e795c2dc0a1215 Mon Sep 17 00:00:00 2001 From: root Date: Fri, 31 Jan 2014 16:42:40 +0100 Subject: Remove all studying apps code. --- lib/list/edbatch.php | 47 ----------------------------------------------- 1 file changed, 47 deletions(-) delete mode 100644 lib/list/edbatch.php (limited to 'lib/list/edbatch.php') diff --git a/lib/list/edbatch.php b/lib/list/edbatch.php deleted file mode 100644 index 380ecf2..0000000 --- a/lib/list/edbatch.php +++ /dev/null @@ -1,47 +0,0 @@ - $batch['listid'], 'name' => $batch['listname']); - -$batch_name = $batch['name']; -$batch_model = $batch['model']; -$batch_contents = $batch['contents']; -if (isset($_POST['name']) && isset($_POST['model']) && isset($_POST['contents'])) { - $batch_name = esca($_POST['name']); - $batch_model = esca($_POST['model']); - $batch_contents = esca($_POST['contents']); - $batch_json = mk_batch_json($batch_model, $batch_contents); - if ($batch_name == "") { - $error = "You must give a name to this batch."; - } else if (mysql_fetch_assoc(sql("SELECT id FROM batches WHERE list = " . $list['id'] . " AND name = '" . escs($batch_name) . "' AND id != $batchid"))) { - $error = "You already have a batch using that name."; - } else { - sql( - "UPDATE batches SET name = '" . escs($batch_name) . "', model = '" . escs($batch_model) . "', ". - "contents = '" . escs($batch_contents) . "', json_data = '" . escs($batch_json) . "' WHERE id = $batchid" - ); - header("Location: view-list-" . $list['id']); - die(); - } -} - -$title = "Edit batch in " . $list['name']; -$fields = array( - array("label" => "Name : ", "name" => "name", "value" => $batch_name), - array("label" => "Columns : ", "name" => "model", "value" => $batch_model), - array("label" => "Contents : ", "name" => "contents", "type" => "textarea", "value" => $batch_contents) -); -$validate = "Edit batch"; - -require("tpl/list/ef.php"); -- cgit v1.2.3