Commit 016483792ead538aedbff3bb92f76fa15c1eb312
1 parent
1ce4dbee
Exists in
master
and in
11 other branches
Filter random proposal by content type
Showing
1 changed file
with
1 additions
and
1 deletions
Show diff stats
js/main.js
... | ... | @@ -137,7 +137,7 @@ function loadRandomProposal(topic_id, private_token) { |
137 | 137 | $(".no-proposals").hide(); |
138 | 138 | $(".loading").show(); |
139 | 139 | $('.random-proposal').html(''); |
140 | - var url = host + '/api/v1/articles/' + topic_id + '/children' + '?private_token=' + private_token + '&limit=1&order=random()&_='+new Date().getTime()+'&fields=id,name,abstract,created_by'; | |
140 | + var url = host + '/api/v1/articles/' + topic_id + '/children' + '?private_token=' + private_token + '&limit=1&order=random()&_='+new Date().getTime()+'&fields=id,name,abstract,created_by&content_type=ProposalsDiscussionPlugin::Proposal'; | |
141 | 141 | $.getJSON(url).done(function( data ) { |
142 | 142 | $(".loading").hide(); |
143 | 143 | ... | ... |