This commit is contained in:
Paminger
2016-03-20 12:53:17 +01:00
parent 0c3c47f848
commit 9689fd5a01
137 changed files with 8480 additions and 405 deletions
@@ -5,8 +5,9 @@ defined('BASEPATH') OR exit('No direct script access allowed');
class Migration_Init extends CI_Migration {
public function up()
{
// Schemas
{
//$this->load->database('system');
// Schemas
//$this->db->query('CREATE SCHEMA IF NOT EXISTS gis;');
}
@@ -7,7 +7,8 @@ class Migration_Pk_migrations extends CI_Migration {
public function up()
{
if ($this->db->table_exists('ci_migrations'))
//$this->load->database('system');
if ($this->db->table_exists('ci_migrations'))
{
$this->db->query('ALTER TABLE ci_migrations ADD CONSTRAINT pk_migrations PRIMARY KEY(version);');
}
@@ -6,7 +6,8 @@ class Migration_Add_apikey extends CI_Migration {
public function up()
{
$this->dbforge->add_field(array(
//$this->load->database('system');
$this->dbforge->add_field(array(
'apikey_id' => array(
'type' => 'INT',
'constraint' => 5,
@@ -5,7 +5,8 @@ defined('BASEPATH') OR exit('No direct script access allowed');
class Migration_Create_basedb extends CI_Migration {
public function up()
{
{
//$this->load->database('system');
if (!$this->db->table_exists('tbl_person'))
{
$this->load->helper('file');
@@ -20,7 +21,7 @@ class Migration_Create_basedb extends CI_Migration {
public function down()
{
$this->db->simple_query('DROP SCHEMA bis;');
/*$this->db->simple_query('DROP SCHEMA bis;');
$this->db->simple_query('DROP SCHEMA campus;');
$this->db->simple_query('DROP SCHEMA fue;');
$this->db->simple_query('DROP SCHEMA kommune;');
@@ -28,7 +29,7 @@ class Migration_Create_basedb extends CI_Migration {
$this->db->simple_query('DROP SCHEMA sync;');
$this->db->simple_query('DROP SCHEMA system;');
$this->db->simple_query('DROP SCHEMA testtool;');
$this->db->simple_query('DROP SCHEMA wawi;');
$this->db->simple_query('DROP SCHEMA wawi;');*/
}
}