mirror of
https://github.com/magicbug/Cloudlog
synced 2024-11-21 15:56:30 +00:00
[Version] Store version number in the options table
Store version number in the options table so that its easier to update for the frontend rather than the config.php which we don't really want to touch
This commit is contained in:
parent
cfdbf29c78
commit
542f199295
@ -14,7 +14,7 @@ defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
*/
|
||||
|
||||
$config['app_name'] = "Cloudlog";
|
||||
$config['app_version'] = "2.4.3";
|
||||
$config['app_version'] = "2.4.5";
|
||||
$config['directory'] = "logbook";
|
||||
$config['callbook'] = "hamqth"; // Options are hamqth or qrz
|
||||
$config['datadir'] = null; // default to install directory
|
||||
|
@ -21,7 +21,7 @@ $config['migration_enabled'] = TRUE;
|
||||
| be upgraded / downgraded to.
|
||||
|
|
||||
*/
|
||||
$config['migration_version'] = 129;
|
||||
$config['migration_version'] = 130;
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
|
25
application/migrations/130_add_version_to_config.php
Normal file
25
application/migrations/130_add_version_to_config.php
Normal file
@ -0,0 +1,25 @@
|
||||
<?php
|
||||
|
||||
defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
|
||||
/*
|
||||
* This migration creates a table called options which will hold global options needed within cloudlog
|
||||
* removing the need for lots of configuration files.
|
||||
*/
|
||||
|
||||
class Migration_add_version_to_config extends CI_Migration {
|
||||
|
||||
public function up()
|
||||
{
|
||||
$data = array(
|
||||
array('option_name' => "version", 'option_value' => "2.4.5", 'autoload' => "yes"),
|
||||
);
|
||||
|
||||
$this->db->insert_batch('options', $data);
|
||||
}
|
||||
|
||||
public function down()
|
||||
{
|
||||
// No option to down
|
||||
}
|
||||
}
|
@ -11,7 +11,7 @@
|
||||
<table width="100%">
|
||||
<tr>
|
||||
<td>Version</td>
|
||||
<td><?php echo $this->config->item('app_version')."\n"; ?></td>
|
||||
<td><?php echo $this->optionslib->get_option('version')."\n"; ?></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Language</td>
|
||||
|
@ -14,7 +14,7 @@ defined('BASEPATH') OR exit('No direct script access allowed');
|
||||
*/
|
||||
|
||||
$config['app_name'] = "Cloudlog";
|
||||
$config['app_version'] = "2.4.4";
|
||||
$config['app_version'] = "2.4.5";
|
||||
$config['directory'] = "%directory%";
|
||||
$config['callbook'] = "hamqth"; // Options are hamqth or qrz
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user