Skip to content

Commit

Permalink
Fixed issue #14229: Popover showed multiple times when save survey
Browse files Browse the repository at this point in the history
Dev: removed duplicate functions
  • Loading branch information
dominikvitt committed Nov 9, 2018
1 parent e618a41 commit 57a35d5
Showing 1 changed file with 1 addition and 21 deletions.
22 changes: 1 addition & 21 deletions assets/packages/limesurvey/survey.js
Expand Up @@ -394,24 +394,4 @@ function updateMandatoryErrorClass(){
$(this).closest(".has-error").removeClass("has-error");
});
}
/**
* showStartPopups : Take all message in startPopups json array and launch an alert with text
*/
function showStartPopups()
{
if(LSvar.showpopup && typeof(LSvar.startPopups) == 'array' && LSvar.startPopups.length){
startPopup=LSvar.startPopups.map(function(text) {
return $("<div/>").html(text).text();
});
alertSurveyDialog(startPopup.join("\n"),''); // What can be a good title here ? ANd this title must come from PHP
}
}
/**
* alertSurveyDialog : Send a warning/alert to the user
* @var string text : the text to be shown
* @var string optionnal title
*/
function alertSurveyDialog(text,title)
{
alert(text);
}

2 comments on commit 57a35d5

@Shnoulle
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I really think it's not the good solution …

@Shnoulle
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We need the 2 function : we need this function by core … not by template. Theme can/must replace this function see https://bugs.limesurvey.org/view.php?id=14410

You can not fix a theme issue by an update in core.

Please sign in to comment.