Created
August 26, 2012 13:09
-
-
Save damiankloip/3479044 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
// TODO: This temp measure will be removed once we have a better way or | |
// separation of storage and the executed view. | |
$config_properties = array ( | |
'disabled', | |
'api_version', | |
'name', | |
'description', | |
'tag', | |
'base_table', | |
'human_name', | |
'core', | |
'display', | |
); | |
foreach ($config_properties as $property) { | |
if ($property == 'display') { | |
$displays = array(); | |
foreach ($entity->display as $key => $display) { | |
$displays[$key] = $display->display_options; | |
} | |
$config->set('display', $displays); | |
} | |
else { | |
$config->set($property, $entity->$property); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment