VRFS-2701 wip musician profile enhancements
This commit is contained in:
parent
0c599ca023
commit
80e942d69e
|
|
@ -256,3 +256,4 @@ remove_bpm_from_jamtracks.sql
|
|||
alter_type_columns.sql
|
||||
user_presences_rename.sql
|
||||
add_genre_type.sql
|
||||
add_description_to_perf_samples.sql
|
||||
|
|
@ -0,0 +1 @@
|
|||
alter table performance_samples add column description varchar(256) NULL;
|
||||
|
|
@ -27,10 +27,21 @@
|
|||
var $studioCount = $screen.find('#studio-count');
|
||||
|
||||
// performance samples
|
||||
var $noSamples = $screen.find('no-samples');
|
||||
var $noSamples = $screen.find('#no-samples');
|
||||
var $jamkazamSamples = $screen.find('#jamkazam-samples');
|
||||
var $soundCloudSamples = $screen.find('#soundcloud-samples');
|
||||
var $youTubeSamples = $screen.find('#youtube-samples');
|
||||
|
||||
// online presence
|
||||
var $noOnlinePresence = $screen.find('no-online-presence');
|
||||
var $noOnlinePresence = $screen.find('#no-online-presence');
|
||||
var $userWebsite = $screen.find('#user-website');
|
||||
var $soundCloudPresence = $screen.find('#soundcloud-presence');
|
||||
var $reverbNationPresence = $screen.find('#reverbnation-presence');
|
||||
var $bandCampPresence = $screen.find('#bandcamp-presence');
|
||||
var $fandalismPresence = $screen.find('#fandalism-presence');
|
||||
var $soundCloudPresence = $screen.find('#youtube-presence');
|
||||
var $soundCloudPresence = $screen.find('#facebook-presence');
|
||||
var $youTubePresence = $screen.find('#twitter-presence');
|
||||
|
||||
// current interests
|
||||
var $noInterests = $screen.find('#no-interests');
|
||||
|
|
@ -43,10 +54,10 @@
|
|||
var $cowritingSection = $screen.find('#cowriting');
|
||||
var $cowritingDetails = $screen.find('#cowriting-details');
|
||||
|
||||
var $traditionalBandSection = $screen.find("#traditional-band");
|
||||
var $traditionalBandSection = $screen.find('#traditional-band');
|
||||
var $traditionalBandDetails = $screen.find('#traditional-band-details');
|
||||
|
||||
var $virtualBandSection = $screen.find("#virtual-band");
|
||||
var $virtualBandSection = $screen.find('#virtual-band');
|
||||
var $virtualBandDetails = $screen.find('#virtual-band-details');
|
||||
|
||||
// tabs
|
||||
|
|
@ -483,6 +494,23 @@
|
|||
}
|
||||
else {
|
||||
$noSamples.hide();
|
||||
|
||||
// show samples section
|
||||
var jamkazamSamples = profileUtils.jamkazamSamples(user.performance_samples);
|
||||
var soundCloudSamples = profileUtils.soundCloudSamples(user.performance_samples);
|
||||
var youTubeSamples = profileUtils.youTubeSamples(user.performance_samples);
|
||||
|
||||
$.each(jamkazamSamples, function(index, sample) {
|
||||
$jamkazamSamples.append("<a href=''>" + sample.claimed_recording.name + "</a>");
|
||||
});
|
||||
|
||||
$.each(soundCloudSamples, function(index, sample) {
|
||||
$soundCloudSamples.append("<a href=''>" + sample.service_id + "</a>");
|
||||
});
|
||||
|
||||
$.each(youTubeSamples, function(index, sample) {
|
||||
$youTubeSamples.append("<a href=''>" + sample.service_id + "</a>");
|
||||
});
|
||||
}
|
||||
|
||||
// online presences
|
||||
|
|
@ -491,7 +519,15 @@
|
|||
$noOnlinePresence.show();
|
||||
}
|
||||
else {
|
||||
$noOnlinePresence.hide();
|
||||
$noOnlinePresence.hide();
|
||||
|
||||
if (user.website) {
|
||||
$userWebsite.append("");
|
||||
}
|
||||
|
||||
$.each(onlinePresences, function(index, presence) {
|
||||
|
||||
});
|
||||
}
|
||||
|
||||
// current interests
|
||||
|
|
|
|||
|
|
@ -18,9 +18,21 @@
|
|||
var COWRITING_GENRE_TYPE = 'cowriting';
|
||||
|
||||
// performance samples
|
||||
var JAMKAZAM = 'jamkazam';
|
||||
var SOUNDCLOUD = 'soundcloud';
|
||||
var YOUTUBE = 'youtube';
|
||||
var SAMPLE_TYPES = {
|
||||
JAMKAZAM: {description: "jamkazam"},
|
||||
SOUNDCLOUD: {description: "soundcloud"},
|
||||
YOUTUBE: {description: "youtube"}
|
||||
};
|
||||
|
||||
var ONLINE_PRESENCE_TYPES = {
|
||||
SOUNDCLOUD: {description: "soundcloud"},
|
||||
REVERBNATION: {description: "reverbnation"},
|
||||
BANDCAMP: {description: "bandcamp"},
|
||||
FANDALISM: {description: "fandalism"},
|
||||
YOUTUBE: {description: "youtube"},
|
||||
FACEBOOK: {description: "facebook"},
|
||||
TWITTER: {description: "twitter"}
|
||||
};
|
||||
|
||||
var USER_TYPE = 'JamRuby::User';
|
||||
|
||||
|
|
@ -148,7 +160,7 @@
|
|||
|
||||
profileUtils.jamkazamSamples = function(samples) {
|
||||
var matches = $.grep(samples, function(s) {
|
||||
return s.service_type === JAMKAZAM;
|
||||
return s.service_type === SAMPLE_TYPES.JAMKAZAM.description;
|
||||
});
|
||||
|
||||
return matches;
|
||||
|
|
@ -156,7 +168,7 @@
|
|||
|
||||
profileUtils.soundCloudSamples = function(samples) {
|
||||
var matches = $.grep(samples, function(s) {
|
||||
return s.service_type === SOUNDCLOUD;
|
||||
return s.service_type === SAMPLE_TYPES.SOUNDCLOUD.description;
|
||||
});
|
||||
|
||||
return matches;
|
||||
|
|
@ -164,7 +176,63 @@
|
|||
|
||||
profileUtils.youTubeSamples = function(samples) {
|
||||
var matches = $.grep(samples, function(s) {
|
||||
return s.service_type === YOUTUBE;
|
||||
return s.service_type === SAMPLE_TYPES.YOUTUBE.description;
|
||||
});
|
||||
|
||||
return matches;
|
||||
}
|
||||
|
||||
profileUtils.soundCloudPresences = function(presences) {
|
||||
var matches = $.grep(presences, function(p) {
|
||||
return p.service_type === ONLINE_PRESENCE_TYPES.SOUNDCLOUD.description;
|
||||
});
|
||||
|
||||
return matches;
|
||||
}
|
||||
|
||||
profileUtils.reverbNationPresences = function(presences) {
|
||||
var matches = $.grep(presences, function(p) {
|
||||
return p.service_type === ONLINE_PRESENCE_TYPES.REVERBNATION.description;
|
||||
});
|
||||
|
||||
return matches;
|
||||
}
|
||||
|
||||
profileUtils.bandCampPresences = function(presences) {
|
||||
var matches = $.grep(presences, function(p) {
|
||||
return p.service_type === ONLINE_PRESENCE_TYPES.BANDCAMP.description;
|
||||
});
|
||||
|
||||
return matches;
|
||||
}
|
||||
|
||||
profileUtils.fandalismPresences = function(presences) {
|
||||
var matches = $.grep(presences, function(p) {
|
||||
return p.service_type === ONLINE_PRESENCE_TYPES.FANDALISM.description;
|
||||
});
|
||||
|
||||
return matches;
|
||||
}
|
||||
|
||||
profileUtils.youTubePresences = function(presences) {
|
||||
var matches = $.grep(presences, function(p) {
|
||||
return p.service_type === ONLINE_PRESENCE_TYPES.YOUTUBE.description;
|
||||
});
|
||||
|
||||
return matches;
|
||||
}
|
||||
|
||||
profileUtils.facebookPresences = function(presences) {
|
||||
var matches = $.grep(presences, function(p) {
|
||||
return p.service_type === ONLINE_PRESENCE_TYPES.FACEBOOK.description;
|
||||
});
|
||||
|
||||
return matches;
|
||||
}
|
||||
|
||||
profileUtils.twitterPresences = function(presences) {
|
||||
var matches = $.grep(presences, function(p) {
|
||||
return s.service_type === ONLINE_PRESENCE_TYPES.TWITTER.description;
|
||||
});
|
||||
|
||||
return matches;
|
||||
|
|
|
|||
|
|
@ -8,7 +8,7 @@ child :online_presences => :online_presences do
|
|||
end
|
||||
|
||||
child :performance_samples => :performance_samples do
|
||||
attributes :id, :url, :service_type, :claimed_recording_id, :service_id
|
||||
attributes :id, :url, :service_type, :claimed_recording_id, :service_id, :description
|
||||
|
||||
child :claimed_recording => :claimed_recording do
|
||||
attributes :name
|
||||
|
|
|
|||
|
|
@ -121,6 +121,15 @@
|
|||
<br clear="all" />
|
||||
<div id="no-samples" class="left">None specified</div>
|
||||
|
||||
<div id="jamkazam-samples">
|
||||
</div>
|
||||
|
||||
<div id="soundcloud-samples">
|
||||
</div>
|
||||
|
||||
<div id="youtube-samples">
|
||||
</div>
|
||||
|
||||
<br clear="all" />
|
||||
<br clear="all" />
|
||||
|
||||
|
|
@ -128,6 +137,30 @@
|
|||
<br clear="all" />
|
||||
<div id="no-online-presence" class="left">None specified</div>
|
||||
|
||||
<div id="user-website">
|
||||
</div>
|
||||
|
||||
<div id="soundcloud-presence">
|
||||
</div>
|
||||
|
||||
<div id="reverbnation-presence">
|
||||
</div>
|
||||
|
||||
<div id="bandcamp-presence">
|
||||
</div>
|
||||
|
||||
<div id="fandalism-presence">
|
||||
</div>
|
||||
|
||||
<div id="youtube-presence">
|
||||
</div>
|
||||
|
||||
<div id="facebook-presence">
|
||||
</div>
|
||||
|
||||
<div id="twitter-presence">
|
||||
</div>
|
||||
|
||||
<br clear="all" />
|
||||
<br clear="all" />
|
||||
|
||||
|
|
@ -201,7 +234,7 @@
|
|||
|
||||
<br clear="all" />
|
||||
<br clear="all" />
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="history-content" class="profile-wrapper">
|
||||
|
|
|
|||
Loading…
Reference in New Issue