Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/matomo-org/matomo.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBenaka Moorthi <benaka.moorthi@gmail.com>2013-09-08 23:25:35 +0400
committerBenaka Moorthi <benaka.moorthi@gmail.com>2013-09-09 00:41:34 +0400
commit046502f876999afcc5e46e80c6698f0d6409881a (patch)
treefc2ccf5e65f1bc672052f94f7bd7842b52ab0dc2 /plugins/Live/javascripts/visitorProfile.js
parent581b2c3fa7329f22cdde6cfba1bd98cb61dbb441 (diff)
Refs #3089, display 'There are no more visits' if its known there are no more visits to display in the visitor profile.
Diffstat (limited to 'plugins/Live/javascripts/visitorProfile.js')
-rw-r--r--plugins/Live/javascripts/visitorProfile.js11
1 files changed, 9 insertions, 2 deletions
diff --git a/plugins/Live/javascripts/visitorProfile.js b/plugins/Live/javascripts/visitorProfile.js
index 4726734c4a..51197fb8ee 100644
--- a/plugins/Live/javascripts/visitorProfile.js
+++ b/plugins/Live/javascripts/visitorProfile.js
@@ -149,13 +149,15 @@
}, 'GET');
ajax.setCallback(function (response) {
if (response == "") { // no more visits left
- var noMoreSpan = $('<span/>').text(_pk_translate('Live_NoMoreVisits_js')).addClass('visitor-profile-no-visits');
- $('.visitor-profile-more-info', $element).html(noMoreSpan);
+ self._showNoMoreVisitsSpan();
} else {
response = $(response);
loading.hide();
$('.visitor-profile-visits', $element).append(response);
+ if (response.filter('li').length < 10) {
+ self._showNoMoreVisitsSpan();
+ }
piwikHelper.lazyScrollTo($(response)[0], 400, true);
}
@@ -164,6 +166,11 @@
ajax.send();
},
+ _showNoMoreVisitsSpan: function () {
+ var noMoreSpan = $('<span/>').text(_pk_translate('Live_NoMoreVisits_js')).addClass('visitor-profile-no-visits');
+ $('.visitor-profile-more-info', this.$element).html(noMoreSpan);
+ },
+
_loadIndividualVisitDetails: function ($visitElement) {
var self = this,
$element = this.$element,