Sequence order in django

63 views
Skip to first unread message

Pooja Kumari

unread,
Apr 3, 2023, 12:50:43 AM4/3/23
to django...@googlegroups.com
Hi guys... I wanna know if there any build-in function in django to re order the sequence order... Let me explain I have a playlist where some tracks are saved now I want to change the sequence order of track and rest of track will reorder according to given track number. If I assign number 5 to any track rest will automatically start from 1 to 4. Any idea how can I do that?

Jason

unread,
Apr 3, 2023, 6:46:29 AM4/3/23
to Django users
seems like what you're asking for is user-defined ordering, and I implemented this for O'Reilly's playlists.

Nitesh Solanki

unread,
Apr 23, 2023, 12:21:43 PM4/23/23
to Django users
Hi Pooja,

Can you please explain it a little bit like, suppose you are having 10 tracks in a list and you select 5th, then what do you want while you are having two partitions?

first partition - 1st to 4th tracks (before the 5th track)
second partition - 6th to 10th tracks (after the 5th track)
Reply all
Reply to author
Forward
0 new messages