From fb07b2fbdbea2e39adbfb82863793c586e5f5866 Mon Sep 17 00:00:00 2001 From: Edward Date: Thu, 20 Feb 2014 14:40:26 +0800 Subject: [PATCH] MessagePreview.php --- MessagePreview.php | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/MessagePreview.php b/MessagePreview.php index ad784664..b4238f3d 100644 --- a/MessagePreview.php +++ b/MessagePreview.php @@ -38,14 +38,11 @@ class Pman_Core_MessagePreview extends Pman { function post() { - if(empty($_REQUEST['_id'])){ - $this->jerr('id got error'); - } - if(empty($_REQUEST['_action'])){ - $this->jerr('preview type not set'); + if(empty($_REQUEST['_id']) || empty($_REQUEST['_table'])){ + $this->jerr('Missing Options'); } - $msg = DB_DataObject::factory('crm_mailing_list_message'); + $msg = DB_DataObject::factory($_REQUEST['_table']); $msg->get($_REQUEST['_id']); -- 2.39.2