closed Album Questions

chorton581
@chorton581
11 years ago
139 posts
If an artist uploads an album with 15 songs then all 15 of them show up on the Newest song page. This happens to be my home page as well.
Is is possible to only have the album show up and not the entire 15 songs?
Current setup is like this
artist1 song1
artist2 song1
artist2 song2
artist2 song3
artist2 etc
artist3 song1

Would prefer
Artist1 song1
Artist2 Album
Artist3 Song1
artist3 song2

updated by @chorton581: 02/10/14 12:21:14PM
chorton581
@chorton581
11 years ago
139 posts
If not is there code to just limit an artist to show 2 songs on home page?
They could upload 15 into an album but only 2 would show on home page
Like this
Artist1 song1
Artist2 Album song1
chorton581
@chorton581
11 years ago
139 posts
my posts seem to be getting cut off
code to limit only 2 songs on the chart would be ok too
brian
@brian
11 years ago
10,148 posts
The only way I can think of to do this right now would be to group_by the audio album - so in your jrCore_list code, you would add:

group_by="audio_album"

This would only show one song for each album.

Let me know if that helps.


--
Brian Johnson
Founder and Lead Developer - Jamroom
https://www.jamroom.net
chorton581
@chorton581
11 years ago
139 posts
what template would i put that into.
brian
@brian
11 years ago
10,148 posts
Whatever page you want to make the change on - i.e. if you are looking at:

yoursite.com/music

then it would be:

skins/ActiveSkin/music.tpl

Look for the {jrCore_list ... } function call.

Hope this helps!


--
Brian Johnson
Founder and Lead Developer - Jamroom
https://www.jamroom.net
chorton581
@chorton581
11 years ago
139 posts
that did not do the trick.
douglas
@douglas
11 years ago
2,791 posts
chorton581:
that did not do the trick.

Where are you trying to do this?

Profile page or elsewhere?


--

Douglas Hackney
Jamroom Team - Designer/Developer/Support
FAQ-Docs-Help Videos
chorton581
@chorton581
11 years ago
139 posts
music.tpl
http://versionist.net/

look about 1/2 way down the page and you will see all the songs from 1 album that fill up the chart.
FYI the music chart is home page

updated by @chorton581: 12/22/13 12:57:49PM
douglas
@douglas
11 years ago
2,791 posts
Okay, in the music.tpl, find this:

                                {if isset($_conf.jrProJam_require_images) && $_conf.jrProJam_require_images == 'on'}
                                    {if isset($_post.search_area) && $_post.search_area == 'audio_genre'}
                                        {jrCore_list module="jrAudio" order_by=$order_by search1="audio_genre like `$_post.search_string`" template="music_row.tpl" require_image="audio_image" pagebreak=$_conf.jrProJam_default_pagebreak page=$_post.p}
                                    {elseif !empty($_post._1)}
                                        {jrCore_list module="jrAudio" order_by=$order_by template="music_row.tpl" require_image="audio_image" search="audio_title like `$_post._1`%" pagebreak=$_conf.jrProJam_default_pagebreak page=$_post.p}
                                    {else}
                                        {jrCore_list module="jrAudio" order_by=$order_by template="music_row.tpl" require_image="audio_image" pagebreak=$_conf.jrProJam_default_pagebreak page=$_post.p}
                                    {/if}
                                {else}
                                    {if isset($_post.search_area) && $_post.search_area == 'audio_genre'}
                                        {jrCore_list module="jrAudio" order_by=$order_by search1="audio_genre like `$_post.search_string`" template="music_row.tpl" pagebreak=$_conf.jrProJam_default_pagebreak page=$_post.p}
                                    {elseif !empty($_post._1)}
                                        {jrCore_list module="jrAudio" order_by=$order_by template="music_row.tpl" search="audio_title like `$_post._1`%" pagebreak=$_conf.jrProJam_default_pagebreak page=$_post.p}
                                    {else}
                                        {jrCore_list module="jrAudio" order_by=$order_by template="music_row.tpl" pagebreak=$_conf.jrProJam_default_pagebreak page=$_post.p}
                                    {/if}
                                {/if}

and change it to this:

                                {if isset($_conf.jrProJam_require_images) && $_conf.jrProJam_require_images == 'on'}
                                    {if isset($_post.search_area) && $_post.search_area == 'audio_genre'}
                                        {jrCore_list module="jrAudio" order_by=$order_by search1="audio_genre like `$_post.search_string`" template="music_row.tpl" require_image="audio_image" pagebreak=$_conf.jrProJam_default_pagebreak page=$_post.p}
                                    {elseif !empty($_post._1)}
                                        {jrCore_list module="jrAudio" order_by=$order_by template="music_row.tpl" require_image="audio_image" search="audio_title like `$_post._1`%" pagebreak=$_conf.jrProJam_default_pagebreak page=$_post.p}
                                    {else}
                                        {jrCore_list module="jrAudio" order_by=$order_by group_by="audio_album" template="music_row.tpl" require_image="audio_image" pagebreak=$_conf.jrProJam_default_pagebreak page=$_post.p}
                                    {/if}
                                {else}
                                    {if isset($_post.search_area) && $_post.search_area == 'audio_genre'}
                                        {jrCore_list module="jrAudio" order_by=$order_by search1="audio_genre like `$_post.search_string`" template="music_row.tpl" pagebreak=$_conf.jrProJam_default_pagebreak page=$_post.p}
                                    {elseif !empty($_post._1)}
                                        {jrCore_list module="jrAudio" order_by=$order_by template="music_row.tpl" search="audio_title like `$_post._1`%" pagebreak=$_conf.jrProJam_default_pagebreak page=$_post.p}
                                    {else}
                                        {jrCore_list module="jrAudio" order_by=$order_by group_by="audio_album" template="music_row.tpl" pagebreak=$_conf.jrProJam_default_pagebreak page=$_post.p}
                                    {/if}
                                {/if}


There are actually only two places to add the group_by parameter.

Hope this helps,
Douglas


--

Douglas Hackney
Jamroom Team - Designer/Developer/Support
FAQ-Docs-Help Videos

updated by @douglas: 12/23/13 04:25:24AM
chorton581
@chorton581
11 years ago
139 posts
that did not fix the issue. if you create 2 songs in the same album them both appear on the home page,
i reset everything as well and it they still appeared.
douglas
@douglas
11 years ago
2,791 posts
Did you make the changes to the index.tpl then instead of the music.tpl?


--

Douglas Hackney
Jamroom Team - Designer/Developer/Support
FAQ-Docs-Help Videos
chorton581
@chorton581
11 years ago
139 posts
yes my fault. I am using the music tpl for home tpl. I changed music only and not home.
All working nicely now. You can mark this solved
douglas
@douglas
11 years ago
2,791 posts
Glad to hear it. :)


--

Douglas Hackney
Jamroom Team - Designer/Developer/Support
FAQ-Docs-Help Videos
chorton581
@chorton581
11 years ago
139 posts
and thank you.
chorton581
@chorton581
10 years ago
139 posts
after further review of this it is only putting one song on the music.tpl page
you can compare www.versionist.net/music
to www.versionist.net/music1

In reality i would want this to be 2. This should match a module brian is creating that would say quota x can upload 2 per day. So 2 show up on charts.
Quota x (labels) can upload 15 a day for their album but only 2 show up on charts.

The other issue is if they do not put in an album nothing shows up under current code your provided.
So i assume i would need to make album name required?
updated by @chorton581: 01/02/14 06:44:25AM
douglas
@douglas
10 years ago
2,791 posts
Yes, you would need to make the album field required since your grouping the audio by albums.

To show two of each album, you would have to do something custom. You might pass that along to Brian since he is creating you another module for the uploads.

Hope this helps,
Douglas


--

Douglas Hackney
Jamroom Team - Designer/Developer/Support
FAQ-Docs-Help Videos
chorton581
@chorton581
10 years ago
139 posts
Douglas,
Can the music.tpl just show quota id = 3 ?
I can always create music1.tpl and that shows quota id = 4 and apply the rule you sent me to that tpl file and make some new nav links..
Can the quota_id="4" string be added to jrAudio?
or do i need to add something else
douglas
@douglas
10 years ago
2,791 posts
Yes, you can use quota_id="#" on any jrCore_list function, where # is the actual ID of the quota.

Hope this helps,
Douglas


--

Douglas Hackney
Jamroom Team - Designer/Developer/Support
FAQ-Docs-Help Videos

Tags