<?php include 'include.php'; include "menu_tree.php"; $ofid = $_REQUEST['ofid']; $member = new members($_SESSION['userid']); if ($_SERVER['REQUEST_METHOD'] == "POST") { $compt = $_POST['compt']; $opinion = $_POST['opinion']; $type = $member->ComplainType($compt); $opinion = "<li>" . $type . $opinion . "(" . date("Y-m-d H:i:s") . ")</li>"; $time = time(); $opinion = mysql_escape_string(stripslashes($opinion)); $sql = "UPDATE order_form_1 SET opinion = CONCAT(opinion,'{$opinion}'),opinion_type = {$compt},opinion_if = 1,opinion_time = '{$time}' WHERE ofid = {$ofid}"; $db->query($sql); $smarty->assign("act", "success"); /* 将操作写入日志表 */ $sys->setOrderNum($ofid); $sys->writeLog("修改数据", $sql, $ofid); } else { $smarty->assign("act", "complaint"); } $smarty->display("Complaint.htm");