I have an image gallery implemented with the below simple class. Until now it was displaying in the order it was being uploaded on the server, so it will sort by uploaded date in the table.
But now client has an requirement of reordering the images after they are uploaded on the server. How do I achieve this sorting once images are tagged in the database.
public class Gallery
{
public int GalleryID { get; set; }
public string GalleryBoatId { get; set; }
public string Image { get; set; }
public string Title { get; set; }
public string Description { get; set; }
public string Featured { get; set; }
public int Sort { get; set; }
public string DateTimeStamp { get; set; }
}
I have tried the option of putting the dropdown list in front of every image, which client can choose & reorder. But it is not feasible in all scenario. Because if client chooses a SortNo as 2, he has change the existing number 2 image sequence. With many combination, it is a uphill task if there are 40-50 images to sequence.
I couldn't find any solution in Stackoverflow, or I might not searched properly. Please guide.
So what they are asking is to have provision to do drag & drop which will store the sequence, the way they place on the screen.