DataObjects/Companies.php
authorChris <chris@roojs.com>
Fri, 10 Jan 2014 09:00:39 +0000 (17:00 +0800)
committerChris <chris@roojs.com>
Fri, 10 Jan 2014 09:00:39 +0000 (17:00 +0800)
DataObjects/Companies.php

index d82b625..fa4f6cd 100644 (file)
@@ -233,7 +233,9 @@ class Pman_Core_DataObjects_Companies extends DB_DataObject
     
     function beforeUpdate($old, $q,$roo)
     {
-        if(!empty($this->is_system)){
+        if(!empty($this->is_system) && 
+            ($old->code != $this->code || $old->name != $this->name)
+        ){
             $roo->jerr('This company is not allow to editing...');
         }
     }