Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

All other Modules /

Discuss all other Modules here.

Moderators: martimiz, Sean, biapar, Willr, Ingo, swaiba

Help! Problem Assets Section of CMS


Go to End
Reply


3 Posts   815 Views

Avatar
kuenkuen82

Community Member, 41 Posts

29 April 2010 at 4:21pm

Edited: 29/04/2010 4:26pm

436 	 * Prepare static variables before processing a {@link get_static} or {@link set_static}
437 	 * call.
438 	 */
439 	private static function prepare_statics($class) {
440 		// _cache_statics_prepared setting must come first to prevent infinite loops when we call
441 		// get_static below
442 		self::$_cache_statics_prepared[$class] = true;
443 
444 		// load statics now for DataObject classes
445 		if(is_subclass_of($class, 'DataObject')) {
446 			$extensions = Object::uninherited_static($class, 'extensions');
447 			if($extensions) foreach($extensions as $extension) {
448 				if(preg_match('/^([^(]*)/', $extension, $matches)) {
449 					$extensionClass = $matches[1];
450 					DataObjectDecorator::load_extra_statics($class, $extensionClass);
451 				}

In the firebug concole it only says:

"NetworkError: 500 Warning: "Unknown c...apphire\core\Object.php - http://128.1.10.34:8505/ss_site/admin/assets/"

Avatar
kuenkuen82

Community Member, 41 Posts

29 April 2010 at 6:20pm

on line 429 in Object.php

		// load statics now for DataObject classes
		if(is_subclass_of($class, 'DataObject')) {
			var_dump($extensionClass);
			DataObjectDecorator::load_extra_statics($class, $extensionClass);
		}

which dump:
string(18) "AssetManagerFolder"
string(18) "SortableDataObject"
string(18) "SortableDataObject"
string(18) "SortableDataObject"
string(20) "ImageGallerySiteTree"
string(12) "Translatable"
string(18) "SortableDataObject"

I'm guessing it's to do with SortableDataObject

Avatar
kuenkuen82

Community Member, 41 Posts

29 April 2010 at 6:32pm

Edited: 07/05/2010 3:58pm

Changing the DataObjectManager _config seems to solve the problem

// Allow DataObjectManager to take control of the AssetAdmin using the AssetManager field
DataObjectManager::allow_assets_override(false);

This seems to allow only to access the Asset, the bug in the system is still there... looking for away to fix this :(