Index: lams_central/conf/language/lams/ApplicationResources.properties
===================================================================
diff -u -r6ab3389a13d007de0abc74bc9df848332037f9dd -r84f740de47dc46a5210e1217511c4e5eb60aceae
--- lams_central/conf/language/lams/ApplicationResources.properties (.../ApplicationResources.properties) (revision 6ab3389a13d007de0abc74bc9df848332037f9dd)
+++ lams_central/conf/language/lams/ApplicationResources.properties (.../ApplicationResources.properties) (revision 84f740de47dc46a5210e1217511c4e5eb60aceae)
@@ -20,6 +20,7 @@
msg.LAMS.version = Version
msg.LAMS.copyright.short = 2002 onwards LAMS Foundation.
button.save = Save
+button.save.new.version = Save as new version
button.cancel = Cancel
no.such.learningdesign.exist = No Learning Design with learning_design_id of:{0} exists.
no.such.user.exist = No such User with a user_id of: {0} exists.
Index: lams_central/src/java/org/lamsfoundation/lams/web/qb/EditQbQuestionController.java
===================================================================
diff -u -re423418cca5e77a3b54cb3be496b67abe01c4183 -r84f740de47dc46a5210e1217511c4e5eb60aceae
--- lams_central/src/java/org/lamsfoundation/lams/web/qb/EditQbQuestionController.java (.../EditQbQuestionController.java) (revision e423418cca5e77a3b54cb3be496b67abe01c4183)
+++ lams_central/src/java/org/lamsfoundation/lams/web/qb/EditQbQuestionController.java (.../EditQbQuestionController.java) (revision 84f740de47dc46a5210e1217511c4e5eb60aceae)
@@ -167,7 +167,8 @@
*/
@RequestMapping(path = "/saveOrUpdateQuestion", method = RequestMethod.POST)
public String saveOrUpdateQuestion(@ModelAttribute("assessmentQuestionForm") QbQuestionForm form,
- HttpServletRequest request, HttpServletResponse response) throws IOException, ServletException {
+ @RequestParam(name = "newVersion", required = false) boolean enforceNewVersion, HttpServletRequest request,
+ HttpServletResponse response) throws IOException, ServletException {
//find according question
QbQuestion qbQuestion = null;
Long oldQuestionUid = null;
@@ -187,6 +188,9 @@
}
int questionModificationStatus = extractFormToQbQuestion(qbQuestion, form, request);
+ if (questionModificationStatus < IQbService.QUESTION_MODIFIED_VERSION_BUMP && enforceNewVersion) {
+ questionModificationStatus = IQbService.QUESTION_MODIFIED_VERSION_BUMP;
+ }
switch (questionModificationStatus) {
case IQbService.QUESTION_MODIFIED_VERSION_BUMP: {
// new version of the old question gets created
Index: lams_central/web/qb/authoring/addQuestionFooter.jsp
===================================================================
diff -u -r9012873415698350686bf05ac1ddb1ee5b8fe154 -r84f740de47dc46a5210e1217511c4e5eb60aceae
--- lams_central/web/qb/authoring/addQuestionFooter.jsp (.../addQuestionFooter.jsp) (revision 9012873415698350686bf05ac1ddb1ee5b8fe154)
+++ lams_central/web/qb/authoring/addQuestionFooter.jsp (.../addQuestionFooter.jsp) (revision 84f740de47dc46a5210e1217511c4e5eb60aceae)
@@ -21,9 +21,20 @@