-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathscripts.ctp
More file actions
29 lines (27 loc) · 1.27 KB
/
scripts.ctp
File metadata and controls
29 lines (27 loc) · 1.27 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
<?php
echo $this->NetCommonsHtml->script(array(
'/questionnaires/js/questionnaires.js'
));
$maxQuestionWarningMsg = __d('questionnaires',
'Number of questions that can be created is up %d . Already it has become %d .',
QuestionnairesComponent::MAX_QUESTION_COUNT,
QuestionnairesComponent::MAX_QUESTION_COUNT
);
$maxChoiceWarningMsg = __d('questionnaires',
'Number of choices that can be created is up %d per question. Already it has become %d .',
QuestionnairesComponent::MAX_CHOICE_COUNT,
QuestionnairesComponent::MAX_CHOICE_COUNT
);
echo $this->NetCommonsHtml->scriptBlock(
'NetCommonsApp.constant("questionnairesMessages", {' .
'"newPageLabel": "' . __d('questionnaires', 'page') . '",' .
'"newQuestionLabel": "' . __d('questionnaires', 'New Question') . '",' .
'"newChoiceLabel": "' . __d('questionnaires', 'new choice') . '",' .
'"newChoiceColumnLabel": "' . __d('questionnaires', 'new column choice') . '",' .
'"newChoiceOtherLabel": "' . __d('questionnaires', 'other choice') . '",' .
'"maxQuestionWarningMsg": "' . $maxQuestionWarningMsg . '",' .
'"maxChoiceWarningMsg": "' . $maxChoiceWarningMsg . '",' .
'"sendingErrorMsg": "' . __d('questionnaires', 'Failed to send data.') . '",' .
'});'
);
echo $this->NetCommonsHtml->css('/questionnaires/css/questionnaire.css');