From 9db9a49fc589c9bcc5fd3577369ead496e8a4724 Mon Sep 17 00:00:00 2001 From: Edward Date: Mon, 22 Oct 2018 16:59:12 +0800 Subject: [PATCH] UpdateDatabase.php --- UpdateDatabase.php | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/UpdateDatabase.php b/UpdateDatabase.php index 5b9b6e61..4fda8da9 100644 --- a/UpdateDatabase.php +++ b/UpdateDatabase.php @@ -847,15 +847,17 @@ class Pman_Core_UpdateDatabase extends Pman $c = DB_DataObject::Factory('core_company'); $c->selectAdd(); $c->selectAdd('distinct(comptype) as comptype'); - $c->whereAdd("comptype != ''"); + $c->whereAdd(" + comptype != '' + AND + comptype != 'undefined' + AND + comptype != 'undefine' + "); $ctb = array(); foreach($c->fetchAll('comptype') as $cts) { - if($cts == 'undefined' || $cts == 'undefine'){ - continue; - } - $ctb[]= array( 'etype'=>'COMPTYPE', 'name' => $cts, 'display_name' => ucfirst(strtolower($cts))); } -- 2.39.2