Jump to:

7935 Posts in 1536 Topics by 943 members

DataObjectManager Module

SilverStripe Forums » DataObjectManager Module » Bug Reports

Discuss the DataObjectManager module, and the related ImageGallery module.

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

Page: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38
Go to End
Author Topic: 47818 Views
  • UncleCheese
    Avatar
    4085 Posts

    Bug Reports Link to this post

    Please use this thread to report existing bugs with DataObjectManager or ImageGallery. I have created this in an effort to keep my to-do list organized and in one place. It's getting to be a hassle to search through threads (even in only one forum) for what needs to be fixed.

    Let's try to keep this to a punchlist format rather than a discussion. The hope is that I will be able to RSS this thread and have a workable list of tasks.

    Before reporting a bug:

    - Make sure you update your SVN

    - Make sure you have Debug::email_errors_to('your@address.com'); set in your _config.php.

    - Have your PHP error reporting cranked up, if possible. White screens are not helpful.

    Bug reports should include:

    - A detailed description of the problem. "Upload doesn't work" is not helpful to me. Tell me everything you did leading up to the error and the content of the error, if applicable.

    - Browser/OS

    - Any relevant code that you have created that I can drop into my testing environment to duplicate the problem.

    - Screenshots, if available.

    Thanks, everyone. I hope that adhering to conventions like these will help streamline bug fixes.

  • UncleCheese
    Avatar
    4085 Posts

    Re: Bug Reports Link to this post

    DataObjectManager is not compliant with 2.3.2 until this ticket is resolved:

    http://open.silverstripe.com/ticket/4221

  • Ben Gribaudo
    Avatar
    Community Member
    181 Posts

    Re: Bug Reports Link to this post

    Uncle Cheese,

    Apparently, the DataObjectManager/FileDataObjectManager and nestedurls don't get along. Would you have time to address the issues mentioned in http://open.silverstripe.com/ticket/4211?

    Thanks,
    Ben

  • Jedateach
    Avatar
    Forum Moderator
    227 Posts

    Re: Bug Reports Link to this post

    I see that the DataObjectManager code blocks alot of javascript, which is probably why the profile edit form no longer pops up. I'm referring to the profile link in the bottom right of the cms, next to the log out link.

    Are you aware of this?

  • UncleCheese
    Avatar
    4085 Posts

    Re: Bug Reports Link to this post

    I have done some updates and DataObjectManager seems to be running okay on the nestedurls branch. Anyone who would like to test this, please update your SVN and let me know the result. Thanks.

  • Aram
    Avatar
    Community Member
    598 Posts

    Re: Bug Reports Link to this post

    Hi Uncle Cheese

    I am having a problem with the ManyManyDataObjectManager. It seems to break if you try to populate any of the table fields with a function, for example a thumbnail as described in this post: http://www.ssbits.com/adding-a-thumbnail-to-a-dataobjectmanager-or-complex-table-field/. It breaks even if you are just returning a string with the function too.

    All it does is popup a blank alert box when trying to access the page in the CMS, firebug reports a '500' error. Thats all there is to go on.

    As soon as you change it to either a regular DataObjectManager or a ManyManyComplexTableField it starts working again placing the thumbnail or string in the table correctly.

    Have you, or anyone else come accross this problem before?

    OS: Vista
    Browser: Firefox 3.5
    SS version: 2.3.2
    DOM version: r197 & latest SVN (212?)

    Cheers

    Aram

  • UncleCheese
    Avatar
    4085 Posts

    Re: Bug Reports Link to this post

    You need to get me a more verbose error. A blank alert box and a generic 500 error is not enough to go on. Crank up your error reporting, make sure your environment type is set to dev, and see if you can get a readable error.

  • Aram
    Avatar
    Community Member
    598 Posts

    Re: Bug Reports Link to this post

    Yea sorry, I hadn't realised I could get more than that in that situation, but I got it in the end, looks like it just looks in the dataobject table instead of looking for the function:

    [18-Jul-2009 05:54:33] Error at C:\wamp\www\DEB\sapphire\core\model\MySQLDatabase.php line 400: Couldn't run query:
    SELECT `Page_Offer`.*, `Page_Offer`.ID, if(`Page_Offer`.ClassName,`Page_Offer`.ClassName,'Page_Offer') AS RecordClassName, Thumbnail, IF(`PageID` IS NULL, '0', '1') AS Checked
    FROM `Page_Offer`
    LEFT JOIN `Page_Offers` ON (`Page_Offer`.`ID` = `Page_OfferID` AND `PageID` = '1')
    GROUP BY `Page_Offer`.ID
    ORDER BY SortOrder ASC
    LIMIT 0, 100

    Unknown column 'Thumbnail' in 'field list' (http://localhost/DEB/admin/getitem?ID=1&ajax=1)

    Here is the Page_offer class:

    class Page_Offer extends DataObject {
    .
    .
    .
       static $has_one = array (
          'Image' => 'Image'
       );
       
    .
    .
    .
       
       function Thumbnail() {
          $Image = $this->Image();
          if ($Image) {
             return $Image->CMSThumbnail();
          } else {
             return null;
          }
    }   
    }

    and the DOM code:

          $manager = new ManyManyDataObjectManager(
             $this,
             'Offers',
             'Page_Offer',
             array('Thumbnail' => 'Image'),
             'getCMSFields_forPopup'
          );

    Hope thats a little more useful...

    47818 Views
Page: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38
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.