Permalink
Browse files

Updated API schema.

  • Loading branch information...
1 parent 8dfc743 commit 628d8ccefe07a2ab980460c273508bce896ae904 Phil Sturgeon committed May 1, 2012
Showing with 22 additions and 1 deletion.
  1. +1 −1 system/cms/config/migration.php
  2. +21 −0 system/cms/migrations/091_Fix_api_stream_view.php
View
2 system/cms/config/migration.php
@@ -23,7 +23,7 @@
|
*/
-$config['migration_version'] = 90;
+$config['migration_version'] = 91;
/*
|--------------------------------------------------------------------------
View
21 system/cms/migrations/091_Fix_api_stream_view.php
@@ -0,0 +1,21 @@
+<?php defined('BASEPATH') OR exit('No direct script access allowed');
+
+class Migration_Fix_api_stream_view extends CI_Migration
+{
+ public function up()
+ {
+ // Set the custom view fields for this stream
+ $this->db
+ ->set('view_options', serialize(array('id', 'key', 'user_id', 'level', 'created')))
+ ->where('stream_name', 'lang:api:api_keys')
+ ->update('data_streams');
+ }
+
+ public function down()
+ {
+ $this->db
+ ->set('view_options', null)
+ ->where('stream_name', 'lang:api:api_keys')
+ ->update('data_streams');
+ }
+}

0 comments on commit 628d8cc

Please sign in to comment.