From: Edward Date: Wed, 11 Feb 2015 07:56:22 +0000 (+0800) Subject: Import/Core_notify.php X-Git-Url: http://git.roojs.org/?p=Pman.Core;a=commitdiff_plain;h=f1a6c82cb183717eb1f427379504f91fda0d1e25 Import/Core_notify.php --- diff --git a/Import/Core_notify.php b/Import/Core_notify.php index 99ea3b70..a7797481 100644 --- a/Import/Core_notify.php +++ b/Import/Core_notify.php @@ -33,11 +33,27 @@ class Pman_Core_Import_Core_notify extends Pman_Roo $this->modules = $this->modulesList(); + $this->etype(); + $this->defaults(); - print_r($this->defaults);exit; + 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->etype();