View Issue Details

This bug affects 1 person(s).
 6
IDProjectCategoryView StatusLast Update
14507Bug reportsTheme editorpublic2019-10-16 14:28
ReporterDenisChenu Assigned ToDenisChenu  
PrioritynoneSeverityminor 
Status closedResolutionreopened 
Product Version3.15.x 
Summary14507: Unable to use some needed var in EM twig
Description

Using SAVEDID or TOKEN show empty string in some twig files (question.twig here, but same with completed.twig

Steps To Reproduce

Import included theme + included survey, test a token

Additional Information

SAVEDID : really needed
TOKEN : can be replaced by TOKEN:TOKEN

Other one ? Why this ones and not SURVEYRESSOURCEURL ?

TagsNo tags attached.
Attached Files
SAVEDID_vanilla.zip (112,736 bytes)
Bug heat6
Complete LimeSurvey version number (& build)3.15.8 github
I will donate to the project if issue is resolvedNo
Browsernot relevant
Database type & versionnot relevant
Server OS (if known)not relevant
Webserver software & version (if known)not relevant
PHP Versionnot relevant

Relationships

related to 14415 closedDenisChenu Unale to use SAVEDID or some other reponse related var in submit.twig 

Users monitoring this issue

jelo

Activities

DenisChenu

DenisChenu

2019-02-08 15:31

developer   ~50471

The big question : why it's OK for TEMPLATEURL (only in template replace) and not SAVEDID : same function ?

DenisChenu

DenisChenu

2019-02-08 15:42

developer   ~50472

OK : git it
getStandardsReplacementFields seems done before survey is started : no SAVEDID at this time, relaunch after : SAVEDID is here
For token : seems usage of global + at first page : get it via GET (global $token). But why it disappear ?

DenisChenu

DenisChenu

2019-02-09 13:52

developer   ~50480

Oh, better understanding : SAVEDID and TOKEN are filled at start of survey, before survey is saved or session is filled.
Since it's filled like a static var : it's not updated … need a way to update WITHOUT delete other tempVars …

DenisChenu

DenisChenu

2019-02-12 08:50

developer   ~50509

https://github.com/LimeSurvey/LimeSurvey/pull/1216

DenisChenu

DenisChenu

2019-02-12 08:51

developer   ~50510

I must test with optout where TOKEN seems needed, but i think tempVars replace coreVars

DenisChenu

DenisChenu

2019-02-26 19:00

developer   ~50689

https://github.com/LimeSurvey/LimeSurvey/commit/678f47a5f7360319c87055efc8a50c8b7409cdd9

dominikvitt

dominikvitt

2019-10-16 13:54

developer   ~54063

@DenisChenu:
Can you explain why SID placeholder was removed from $coreReplacements array?
Right now SID placeholder can't be used inside email templates, and it would be very useful for generating custom survey URLs inside invitation emails.

DenisChenu

DenisChenu

2019-10-16 14:23

developer   ~54064

Because it was set directly in LimeExpressionManager::setVariableAndTokenMappingsForExpressionManager

Then it was in email template too. But more iuf i remind it was added because coreReplacements is not always done, but setVariableAndTokenMappingsForExpressionManager always.

DenisChenu

DenisChenu

2019-10-16 14:28

developer   ~54065

@dominikvitt : can use {SID} in email template (checked with invitation) : no issue.

Issue History

Date Modified Username Field Change
2019-02-08 15:14 DenisChenu New Issue
2019-02-08 15:14 DenisChenu Status new => assigned
2019-02-08 15:14 DenisChenu Assigned To => DenisChenu
2019-02-08 15:14 DenisChenu File Added: SAVEDID_vanilla.zip
2019-02-08 15:14 DenisChenu File Added: survey_archive_SAVEDID.lsa
2019-02-08 15:14 DenisChenu File Added: Capture d’écran du 2019-02-08 15-12-34.png
2019-02-08 15:15 DenisChenu Relationship added related to 14415
2019-02-08 15:16 DenisChenu Description Updated
2019-02-08 15:31 DenisChenu Note Added: 50471
2019-02-08 15:42 DenisChenu Note Added: 50472
2019-02-08 21:27 jelo Issue Monitored: jelo
2019-02-09 13:52 DenisChenu Note Added: 50480
2019-02-12 08:50 DenisChenu Note Added: 50509
2019-02-12 08:51 DenisChenu Note Added: 50510
2019-02-26 19:00 DenisChenu Status assigned => resolved
2019-02-26 19:00 DenisChenu Resolution open => fixed
2019-02-26 19:00 DenisChenu Note Added: 50689
2019-04-30 09:11 c_schmitz Status resolved => closed
2019-10-16 13:54 dominikvitt Status closed => feedback
2019-10-16 13:54 dominikvitt Resolution fixed => reopened
2019-10-16 13:54 dominikvitt Note Added: 54063
2019-10-16 14:23 DenisChenu Note Added: 54064
2019-10-16 14:28 DenisChenu File Added: Capture d’écran du 2019-10-16 14-25-04.png
2019-10-16 14:28 DenisChenu Note Added: 54065
2019-10-16 14:28 DenisChenu Status feedback => closed
2019-10-16 14:28 DenisChenu File Added: Capture d’écran du 2019-10-16 14-28-30.png
2021-08-02 17:28 guest Bug heat 4 => 6