Jump to:

7940 Posts in 1543 Topics by 946 members

DataObjectManager Module

SilverStripe Forums » DataObjectManager Module » ImageGalleryItems suddenly have wrong imageID's

Discuss the DataObjectManager module, and the related ImageGallery module.

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

Page: 1 2
Go to End
Author Topic: 1560 Views
  • vancouverWill
    Avatar
    Community Member
    121 Posts

    ImageGalleryItems suddenly have wrong imageID's Link to this post

    I can see from the ImageGalleryItem table that all ImageGalleryItems are still there with the text I gave them for descriptions but they somehow have ImageIDs which are pointed to the wrong non-existent files now. Has anyone else had this problem. It is strange cause I go into the image gallery and there are twelve images like there used to be in the same order and the same description but they all point to non existent files. When I go to the File table I can see the files are still there but the file IDs must be the original ones as when you go back to the imagegalleryitem table the corresponding image has an imageID of a higher value that doesn't exist in the file table. I hope this makes sense to someone as to either a recognizable bug or some module or update which has caused the two tables to get out of alignment.

    It doesn't really matter right now as I don't have that many images but it is obviously scary for the future as if a client uses the image gallery a fair amount and has a substantial number of images then loses the links all his or her work will be wasted. Looking forward to hearing other peoples experience with this matter.

    cheers

    Will

  • UncleCheese
    Avatar
    4085 Posts

    Re: ImageGalleryItems suddenly have wrong imageID's Link to this post

    When was the last time everything was working? Did this just happen suddenly or did happen after a specific change?

  • vancouverWill
    Avatar
    Community Member
    121 Posts

    Re: ImageGalleryItems suddenly have wrong imageID's Link to this post

    hey sorry, I didn't notice you had replied as I wasn't subscribed. Yeah it happened suddenly. I still have no idea how they got out of alignment. In the end I deleted all the photos and reimported them. Just wondering if anyone else had this problem or had any thoughts. Thanks

    Will

  • vancouverWill
    Avatar
    Community Member
    121 Posts

    Re: ImageGalleryItems suddenly have wrong imageID's Link to this post

    So this happened again. I went to have a look at my site and there were no images in the gallery. I went to the admin section and the image gallery page showed that it remembered there were images before as there were as many grey faded out boxes as there used to be images. I understand this means the page knows there should be a photo but it doesn't know the link to it. I had a look in the file table and there were items with the classname 'ImageGalleryImage'. When I tried to add a new image to the gallery it worked fine and a new entry showed up in the image gallery and in the file table. However somehow all my previous images have somehow been wiped and no record is there of them in the file table at all. Should dev/build clear out the links? This seems like a major bug in image gallery yet I have no idea where it is coming from. Other than that super happy with the modules but this problem has got me stumped.

    Thanks

    Will

  • UncleCheese
    Avatar
    4085 Posts

    Re: ImageGalleryItems suddenly have wrong imageID's Link to this post

    Yeah, that's not good. I'm really sorry you're having this issue. Is there any specific behavior you can point to that caused these images to break? When was the last time it was working? This is definitely a bug I'd like to nail down, assuming it is a bug, so the more info you can provide to help me replicate it, the easier that will be.

  • Dave L
    Avatar
    Community Member
    56 Posts

    Re: ImageGalleryItems suddenly have wrong imageID's Link to this post

    I have this problem at the moment. Haven't been able to reproduce 100% but it seems to involve:

    1. have images in Uploads folder
    2. go to ImageGalleryPage's Photos tab in CMS
    3. select Import from Existing folder

    Something like...
    4a. Choose a file
    5a. "Close" the next popup (caption), instead of using the "Finish" button, OR

    4b. Choose an image previously imported into another album
    5b. "Close" the next popup (caption), instead of using the "Finish" button, OR

    4c. Choose an image previously imported into another album,
    5c. Select "Finish"

    Not sure if step 4b or 5b is the problem, but I'm ending up with ImageGalleryItem IDs that aren't tied to File record IDs.

    Will keep running some tests

  • UncleCheese
    Avatar
    4085 Posts

    Re: ImageGalleryItems suddenly have wrong imageID's Link to this post

    Okay, good to know. Just make sure you're running tests on the most recent rev (r331).

  • vancouverWill
    Avatar
    Community Member
    121 Posts

    Re: ImageGalleryItems suddenly have wrong imageID's Link to this post

    Hmm, glad to see it is not just my setup but I guess shame to see other people are having a problem. Afraid I can't be as specific to exactly when the images were lost. Other staff were using the setup so when I came back to it and the image links were lost it was a surprise.

    1560 Views
Page: 1 2
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.