summaryrefslogtreecommitdiff
path: root/addons/survey/static
diff options
context:
space:
mode:
authorDavid Beguin <dbe@odoo.com>2019-12-02 12:50:25 +0000
committerAurélien Warnon <awa@odoo.com>2020-01-10 11:01:04 +0000
commit26147efeab9bd37679c0202950c48bdb1c8ec04a (patch)
tree1efeff8e6bb7d5958c65d61f2ad673b9c369a630 /addons/survey/static
parent94fd0624afc508bb46b9444ac232d313a200c168 (diff)
[IMP] survey: save questions on time limit reached
Purpose ======= If the timer goes to 00:00, the form is automatically submitted but the answers are not saved. The form should be submitted, validation should filter out invalid answers to avoid showing validation errors on the form, and save answers. If the answer is not in the correct format : skip the question If the answer is required but there is no answer : skip the question This way, we can still compute score. Specifications ============== This commit removes the invalid answers from the question to save, only if the timer is not over, to be able to compute score on not finished survey. In order to avoid being able to submit answers when the survey is marked as done, a check was added to return an error for that use case. Also, to avoid frontend timer hacking, an extra buffer of 10 seconds has been added. If the time limit is reached and the submit occurs 10 seconds after the maximum stop time (start time + time limit), no answer can be submitted. Task ID: 2152223 PR #41453
Diffstat (limited to 'addons/survey/static')
0 files changed, 0 insertions, 0 deletions