Xaraya / Postnuke CVS Notices - Message

Note: this list is kept only as a demonstration for CVSNotice. For the latest CVS notices, see the Xaraya and Postnuke sites

View Statistics - Next Notice - Previous Notice

Directory filter : [ all ] / postnuke_official / html / modules / base [ view in CVS ]

Date Directory [filter] File(s) [view] Author [filter]
04 Aug 2002 03:12:33postnuke_official/html/modules/basepninit.php,1.5,1.6Paul Rosania
 fixes, and more table defs

Update of /home/cvsroot/postnuke_official/html/modules/base
In directory ns7.hostnuke.net:/tmp/cvs-serv16017

Modified Files:
	pninit.php 
Log Message:
fixes, and more table defs


Index: pninit.php
===================================================================
RCS file: /home/cvsroot/postnuke_official/html/modules/base/pninit.php,v
retrieving revision 1.5
retrieving revision 1.6
diff -C2 -d -r1.5 -r1.6
*** pninit.php	3 Aug 2002 17:59:44 -0000	1.5
--- pninit.php	4 Aug 2002 03:12:30 -0000	1.6
***************
*** 361,366 ****
                                                               'null'        => false,
                                                               'default'     => '0'),
!                                    'pn_flag'         => array('type'        => 'tinyint',
!                                                              'size'        => 2,
                                                               'null'        => false,
                                                               'default'     => '1')));
--- 361,366 ----
                                                               'null'        => false,
                                                               'default'     => '0'),
!                                    'pn_flag'         => array('type'        => 'integer',
!                                                              'size'        => 'tiny',
                                                               'null'        => false,
                                                               'default'     => '1')));
***************
*** 375,395 ****
      }
      
-     $query = pnDBCreateIndex($prefix . '_admin_menu',
-                              array('name'   => 'pn_amid_index',
-                                    'fields' => array('pn_amid'),
-                                    'unique' => 'false'));
-     $dbconn->Execute($query);
-     
-     // Check for db errors
-     if ($dbconn->ErrorNo() != 0) {
-         $msg = pnMLByKey('DATABASE_ERROR', $dbconn->ErrorMsg(), $query);
-         pnExceptionSet(PN_SYSTEM_EXCEPTION, 'DATABASE_ERROR',
-                        new SystemException(__FILE__.'('.__LINE__.'): '.$msg));
-         return NULL;
-     }
- 
      // *_block_groups
!     $query = pnDBCreateTable($prefix . '_users',
!                              array('pn_uid'         => array('type'        => 'integer',
                                                               'null'        => false,
                                                               'default'     => '',
--- 375,381 ----
      }
      
      // *_block_groups
!     $query = pnDBCreateTable($prefix . '_block_groups',
!                              array('pn_id'         => array('type'        => 'integer',
                                                               'null'        => false,
                                                               'default'     => '',
***************
*** 415,432 ****
      
      $query = pnDBCreateIndex($prefix . '_block_groups',
-                              array('name'   => 'pn_id_index',
-                                    'fields' => array('pn_id'),
-                                    'unique' => 'false'));
-     $dbconn->Execute($query);
-     
-     // Check for db errors
-     if ($dbconn->ErrorNo() != 0) {
-         $msg = pnMLByKey('DATABASE_ERROR', $dbconn->ErrorMsg(), $query);
-         pnExceptionSet(PN_SYSTEM_EXCEPTION, 'DATABASE_ERROR',
-                        new SystemException(__FILE__.'('.__LINE__.'): '.$msg));
-         return NULL;
-     }
-     
-     $query = pnDBCreateIndex($prefix . '_block_groups',
                               array('name'   => 'pn_name_index',
                                     'fields' => array('pn_name'),
--- 401,404 ----
***************
*** 441,445 ****
          return NULL;
      }
! 
      // *_block_instances
      $query = pnDBCreateTable($prefix . '_block_instances',
--- 413,417 ----
          return NULL;
      }
!     
      // *_block_instances
      $query = pnDBCreateTable($prefix . '_block_instances',
***************
*** 455,469 ****
                                                               'size'        => 255,
                                                               'null'        => true,
!                                                              'default'     => ''),
!                                    'pn_content'     => array('type'        => 'text',
!                                                              'default'     => ''),
                                     'pn_template'    => array('type'        => 'varchar',
                                                               'size'        => 255,
                                                               'null'        => true,
!                                                              'default'     => ''),
!                                    'pn_state'       => array('type'        => 'tinyint',
!                                                              'size'        => 1,
                                                               'null'        => false,
!                                                              'default'     => '1'),
                                     'pn_refresh'     => array('type'        => 'integer',
                                                               'null'        => false,
--- 427,440 ----
                                                               'size'        => 255,
                                                               'null'        => true,
!                                                              'default'     => NULL),
!                                    'pn_content'     => array('type'        => 'text'),
                                     'pn_template'    => array('type'        => 'varchar',
                                                               'size'        => 255,
                                                               'null'        => true,
!                                                              'default'     => NULL),
!                                    'pn_state'       => array('type'        => 'integer',
!                                                              'size'        => 'tiny',
                                                               'null'        => false,
!                                                              'default'     => '2'),
                                     'pn_refresh'     => array('type'        => 'integer',
                                                               'null'        => false,
***************
*** 482,490 ****
          return NULL;
      }
      
!     $query = pnDBCreateIndex($prefix . '_block_groups',
!                              array('name'   => 'pn_id_index',
!                                    'fields' => array('pn_id'),
!                                    'unique' => 'false'));
      $dbconn->Execute($query);
      
--- 453,501 ----
          return NULL;
      }
+                                                                                
+     // *_block_types
+     $query = pnDBCreateTable($prefix . '_block_types',
+                              array('pn_id'          => array('type'        => 'integer',
+                                                              'null'        => false,
+                                                              'default'     => '0',
+                                                              'increment'   => true,
+                                                              'primary_key' => true),
+                                    'pn_type'        => array('type'        => 'varchar',
+                                                              'size'        => 255,
+                                                              'null'        => false,
+                                                              'default'     => ''),
+                                    'pn_module'    => array('type'        => 'varchar',
+                                                              'size'        => 255,
+                                                              'null'        => false,
+                                                              'default'     => '')));
      
!      $dbconn->Execute($query);
!         
!     // Check for db errors
!     if ($dbconn->ErrorNo() != 0) {
!         $msg = pnMLByKey('DATABASE_ERROR', $dbconn->ErrorMsg(), $query);
!         pnExceptionSet(PN_SYSTEM_EXCEPTION, 'DATABASE_ERROR',
!                        new SystemException(__FILE__.'('.__LINE__.'): '.$msg));
!         return NULL;
!     }
!     
!     $query = pnDBCreateIndex($prefix . '_block_types',
!                              array('name'   => 'pn_type_index',
!                                    'fields' => array('pn_type'),
!                                    'unique' => false));
!     $dbconn->Execute($query);
!     
!     // Check for db errors
!     if ($dbconn->ErrorNo() != 0) {
!         $msg = pnMLByKey('DATABASE_ERROR', $dbconn->ErrorMsg(), $query);
!         pnExceptionSet(PN_SYSTEM_EXCEPTION, 'DATABASE_ERROR',
!                        new SystemException(__FILE__.'('.__LINE__.'): '.$msg));
!         return NULL;
!     }
! 
!     $query = pnDBCreateIndex($prefix . '_block_types',
!                              array('name'   => 'pn_typemodule_index',
!                                    'fields' => array('pn_type(50)', 'pn_module(50)'),
!                                    'unique' => true));
      $dbconn->Execute($query);
      
***************
*** 496,503 ****
          return NULL;
      }
-                                                                                
-     // *_block_types
      
      // *_block_group_instances
      // *_users
      $query = pnDBCreateTable($prefix . '_users',
--- 507,538 ----
          return NULL;
      }
      
      // *_block_group_instances
+     $query = pnDBCreateTable($prefix . '_block_group_instances',
+                              array('pn_id'          => array('type'        => 'integer',
+                                                              'null'        => false,
+                                                              'default'     => '0',
+                                                              'increment'   => true,
+                                                              'primary_key' => true),
+                                    'pn_group_id'    => array('type'        => 'integer',
+                                                              'null'        => false,
+                                                              'default'     => '0'),
+                                    'pn_instance_id' => array('type'        => 'integer',
+                                                              'null'        => false,
+                                                              'default'     => '0'),
+                                    'pn_position'    => array('type'        => 'integer',
+                                                              'null'        => false,
+                                                              'default'     => '0')));
+     
+      $dbconn->Execute($query);
+         
+     // Check for db errors
+     if ($dbconn->ErrorNo() != 0) {
+         $msg = pnMLByKey('DATABASE_ERROR', $dbconn->ErrorMsg(), $query);
+         pnExceptionSet(PN_SYSTEM_EXCEPTION, 'DATABASE_ERROR',
+                        new SystemException(__FILE__.'('.__LINE__.'): '.$msg));
+         return NULL;
+     }
+     
      // *_users
      $query = pnDBCreateTable($prefix . '_users',
***************
*** 677,691 ****
      }
      
-     $query = "INSERT INTO {$prefix}_admin_menu (pn_amid, pn_name, pn_category, pn_weight, pn_flag) VALUES (3, 'autolinks', 'Global', 0, 1);";
-     $dbconn->Execute($query);
-     
-     // Check for db errors
-     if ($dbconn->ErrorNo() != 0) {
-         $msg = pnMLByKey('DATABASE_ERROR', $dbconn->ErrorMsg(), $query);
-         pnExceptionSet(PN_SYSTEM_EXCEPTION, 'DATABASE_ERROR',
-                        new SystemException(__FILE__.'('.__LINE__.'): '.$msg));
-         return NULL;
-     }
-     
      $query = "INSERT INTO {$prefix}_admin_menu (pn_amid, pn_name, pn_category, pn_weight, pn_flag) VALUES (4, 'base', 'Global', 0, 1);";
      $dbconn->Execute($query);
--- 712,715 ----
***************
*** 700,714 ****
      
      $query = "INSERT INTO {$prefix}_admin_menu (pn_amid, pn_name, pn_category, pn_weight, pn_flag) VALUES (5, 'blocks', 'Global', 0, 1);";
-     $dbconn->Execute($query);
-     
-     // Check for db errors
-     if ($dbconn->ErrorNo() != 0) {
-         $msg = pnMLByKey('DATABASE_ERROR', $dbconn->ErrorMsg(), $query);
-         pnExceptionSet(PN_SYSTEM_EXCEPTION, 'DATABASE_ERROR',
-                        new SystemException(__FILE__.'('.__LINE__.'): '.$msg));
-         return NULL;
-     }
-     
-     $query = "INSERT INTO {$prefix}_admin_menu (pn_amid, pn_name, pn_category, pn_weight, pn_flag) VALUES (6, 'comments', 'Content', 0, 1);";
      $dbconn->Execute($query);
      
--- 724,727 ----


Directory filter : [ all ] / postnuke_official / html / modules / base [ view in CVS ]

View Statistics - Next Notice - Previous Notice


Visit Developer Site - Browse CVS Repository Syndicate via backend.rss
(max. once per hour please)
Powered by CVSNotice 0.1.3