From 996b4cbe39dc6b4aa5642a765a5265896d5e0afc Mon Sep 17 00:00:00 2001 From: Edward Date: Wed, 11 Feb 2015 15:57:46 +0800 Subject: [PATCH] Import/Core_notify.php --- Import/Core_notify.php | 45 +++++++++++++++++++++++++----------------- 1 file changed, 27 insertions(+), 18 deletions(-) diff --git a/Import/Core_notify.php b/Import/Core_notify.php index a7797481..eeffb055 100644 --- a/Import/Core_notify.php +++ b/Import/Core_notify.php @@ -35,24 +35,33 @@ class Pman_Core_Import_Core_notify extends Pman_Roo $this->etype(); - $this->defaults(); - - foreach ($this->defaults as $k => $v){ - $enum = DB_DataObject::factory('core_enum'); - $enum->setFrom(array( - 'etype' => $this->etype->name, - 'name' => $k, - 'active' => 1 - )); - - if($enum->find(true)){ - continue; - } - - $enum->display_name = $v; - $enum->insert(); - } - +// $this->defaults(); +// +// foreach ($this->defaults as $k => $v){ +// $enum = DB_DataObject::factory('core_enum'); +// $enum->setFrom(array( +// 'etype' => $this->etype->name, +// 'name' => $k, +// 'active' => 1 +// )); +// +// if($enum->find(true)){ +// continue; +// } +// +// $enum->display_name = $v; +// $enum->insert(); +// } +// + $notify = DB_DataObject::factory('core_notify'); + $notify->selectAdd(); + $notify->selectAdd(" + DISTINCT(evtype) AS evtype + "); + + $types = $notify->fetchAll(); + + print_r($types);exit; -- 2.39.2