Do you know if it is possible (and if yes how) that a user can sort his own pictures which are in a custom or image list? The list should not be sorted by name or anything else, but the user should be able to move the pictures and put it in the order of his choice.
Yes, it’s possible to create a sort order. The real issue is how you implement it.
Are you going to have the user select each image in the order they want it or have them number it themselves? That’s the hard part. The easy part is have a number field and sort accordingly…
Thank you for your answer:)
I imagined it so that the user can “drag and drop” the pictures.
Do you maybe know how to program this?
Yeah, that’s where I thought you were going with this
Adalo doesn’t have drag and drop, so how you implement this is going to be interesting.
I’d recommend selecting (toggling) and using their toggle order as the sorting order.
Sorry for the question, but how can I sort something with a toggle? I only know how to work with them with a true / false property.
Wow. Thank you very much for your time. I appreciate it very much. Now I understand the way how it works :D.
There is a little issue left, which doesn’t work yet.
I want to sort a list, which can be seen by every user and every user should be able to make his own sortation. So I have to put the number property in the user collection, but the list is not a list of users, but a list of images. So is it possible to sort a list of images by a number property from the user collection?
Can you explain that in a bit more depth?
Let’s say there are two users, five photos each, so ten total photos. Are you saying each user can choose how they sort the entire list? Or just how they sort their own photos?
My app is a bit different. The user can’t create a picture. I have an image collection where I manually added pictures. I also have an inapp-currency, with which the users can buy the pictures. At the home screen, there is a list of images with the filter logged in user/owned pictures. Now I want that the user is able to sort his owned pictures as he likes.
Thats why I need the property in the user collection. Every user wants to sort his owned images differently.
Okay. This is easy enough, basically you’re going to do exactly what I showed. When a user purchases an image, add them as the image owner. Only allow owners to edit the image order for the images they own.
Then you can sort their list by sortOrder and filter by image owner.
So should I do the number property in the user or image collection? A user who doesn’t own the picture can’t see it in the list, because the list has the setting logged in user/owned images. When a user buys a picture, it is added to his owned images.
Use the image collection. You shouldn’t be doing anything on the user level.
Ok. But what happens if a user wants a certain image to be displayed at the third place, but another user wants the same picture at the sixth place. That doesn’t work then, does it? Because only one digit can be assigned to each picture.
Sorry for asking in such a detail. Because of your video I completely understand how it would work if every user creates his own pictures. But in my case many users own the same picture and each user wants the picture at a different place. So if the picture has only one number property it doesn’t work.
Use two different image collections imagesForPurchase, ownedImages.
When a user purchases an image, put it in ownedImages. That should be unique to each user and photo, then put a sortOrder on the ownedImages.
Every user will get their own sort order then.
Thank you very much. Now I understand it:D
This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.