public function delete() { $result = array('error' => -1, 'message' => '删除失败'); if ($_POST['node_id'] != null) { if (NodeModel::deleteNode($_POST['node_id']) > 0) { $result = array('error' => 0, 'message' => '删除成功'); } } return $result; }