Jump to:

10990 Posts in 2727 Topics by 1818 members

All other Modules

SilverStripe Forums » All other Modules » Help! Problem Assets Section of CMS

Discuss all other Modules here.

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

Page: 1
Go to End
Author Topic: 747 Views
  • kuenkuen82
    Avatar
    Community Member
    41 Posts

    Help! Problem Assets Section of CMS Link to this post

    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/"

  • kuenkuen82
    Avatar
    Community Member
    41 Posts

    Re: Help! Problem Assets Section of CMS Link to this post

    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

  • kuenkuen82
    Avatar
    Community Member
    41 Posts

    Re: Help! Problem Assets Section of CMS Link to this post

    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

    747 Views
Page: 1
Go to Top

Want to know more about the company that brought you SilverStripe? Then check out SilverStripe.com

Comments on this website? Please give feedback.