UpdateDatabase.php
authorAlan Knowles <alan@roojs.com>
Tue, 7 Oct 2014 06:26:48 +0000 (14:26 +0800)
committerAlan Knowles <alan@roojs.com>
Tue, 7 Oct 2014 06:26:48 +0000 (14:26 +0800)
UpdateDatabase.php

index 2fbeec0..cb32d79 100644 (file)
@@ -134,12 +134,31 @@ class Pman_Xtuple_UpdateDatabase extends Pman_Core_UpdateDatabase
                 // it should really use xtuple... but it's not very well organized...
                 //$this->{$dirmethod}($dburl, $this->rootDir. "/Pman/$m/{$dbtype}.init");
                 
+                // ?? use dbscripts/misc/postbooks_empty.backup ???
+                
                 $this->{$dirmethod}($dburl, $this->rootDir. "/Pman/$m/{$dbtype}.init");
+                foreach(array(
+                    'indexes',
+                    'api/functions',
+                    'api/views',
+                    
+                ) as $dir) {
+                    $this->{$dirmethod}($dburl, $this->rootDir. "/Pman/Xtuple/xtuple-database/dbscripts/" . $dir);   
+                }
+            }
+            
+            
+            foreach(array(
+                'functions',
+                'api/functions',
+                'api/views',
                 
+            ) as $dir) {
+                $this->{$dirmethod}($dburl, $this->rootDir. "/Pman/Xtuple/xtuple-database/dbscripts/" . $dir);   
             }
             
             // first try the standard from xtuple-database
-            $this->{$dirmethod}($dburl, $this->rootDir. "/Pman/Xtuple/xtuple-database/dbscripts/functions");
+            
             
             // new -- sql directory..
             // new style will not support migrate ... they have to go into mysql-migrate.... directories..