Please help us help you and fill where relevant:
LimeSurvey version: LimeSurvey Community Edition Version 6.16.2+251209
Own server or LimeSurvey Cloud: own server
Survey theme/template: Bootstrap Vanilla
==================
I have a survey that we've been using for 5+ years. Open Survey, with usually 150-200 responses, all in our organization. We run it once per month, and I set the start date to the 1st of the month and the stop date to the 10th of the month. I have modified the layout_errors.twig file to indicate the survey is open only from the 1st to the 10th. That works fine: when the survey is open, people click on the link and they get to the survey and submit their data. When the survey is closed (11th-31st of the month) people see my custom error message, "our metrics survey is not active at this time. It is active from the 1st to the 10th of the month".
We are moving to a closed system with participants loaded from a csv file. About 360 participants. I will generate access codes and send emails to each participant with their SURVEYURL in the email. We allow only one submittal per month.
So, I want to be able to display error messages based on the reason:
1. If the survey is not active (11th to 31st of the month), I want to display a "not active" message
2. if the survey is active but the user has already submitted data, I want to display a message "you have already submitted" message.
I can't seem to get exactly what I want. I'm debugging with the layout_errors.twig and accessing the aError.message and aError.reason and aError.type data items. When the survey is active and but data is already submitted, I'm getting the message "We are sorry but you are not allowed to enter this survey." When the survey is not active, I get the message "We are sorry but the survey is expired and no longer available." I see in another post (Tony Partner, screenshot below) that there is supposedly a message "You have already completed this survey." but I can't figure out how to generate that error message. I *could* use the "you are not allowed" message but that's not really the correct error message. (yes, I could check for that message and generate my own).
Any ideas?
thanks,
Rick