Skip to content

Commit

Permalink
Merge pull request Martin-Gleiss#19 from Martin-Gleiss/develop
Browse files Browse the repository at this point in the history
merge upstream changes
  • Loading branch information
wvhn authored Apr 11, 2020
2 parents e3226e8 + 9662f93 commit 85cea1e
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion widgets/multimedia.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,14 @@ $.widget("sv.multimedia_image", $.sv.widget, {
_update: function(response) {
var widget_url = this.element.attr('data-url');
var resp = Array.isArray(response) ? response[0]: response;
var img_base = widget_url ? widget_url + '?' : resp+((resp.indexOf('?') == -1) ? '?' : '&')
if (widget_url)
{
var img_base = widget_url + ((widget_url.indexOf('?') == -1) ? '?' : '&');
}
else
{
var img_base = resp + ((resp.indexOf('?') == -1) ? '?' : '&');
}
img = img_base + '_=' + new Date().getTime();
refreshing = this.element.attr('data-repeat') ? this.element.attr('data-repeat') : 'refresh by item';
console.log("Response: " + response + " Update Multimedia Image: " + img + ", repeat: " + refreshing);
Expand Down

0 comments on commit 85cea1e

Please sign in to comment.