Fix some broken Survey i18n (Add Section). Add i18n for object edit dialog buttons.
This commit is contained in:
parent
b9a9c588d7
commit
f582bfd99e
4 changed files with 38 additions and 26 deletions
|
|
@ -10,6 +10,7 @@
|
||||||
- fixed #11301: Matrix - Comparing too many products error message
|
- fixed #11301: Matrix - Comparing too many products error message
|
||||||
- fixed #11297: YUI Rich Editor fails to load when editing Survey in 7.7.27
|
- fixed #11297: YUI Rich Editor fails to load when editing Survey in 7.7.27
|
||||||
- fixed #11306: Survey i18n: Loading....
|
- fixed #11306: Survey i18n: Loading....
|
||||||
|
- fixed #11307: Survey i18n #2
|
||||||
|
|
||||||
7.8.7
|
7.8.7
|
||||||
- fixed #11278: Wrong test for Template::Toolkit in testEnvironment.pl
|
- fixed #11278: Wrong test for Template::Toolkit in testEnvironment.pl
|
||||||
|
|
|
||||||
|
|
@ -1690,21 +1690,21 @@ section/answer.|,
|
||||||
lastUpdated => 0,
|
lastUpdated => 0,
|
||||||
},
|
},
|
||||||
|
|
||||||
'Add Question' => {
|
|
||||||
message => q{Add Question},
|
|
||||||
lastUpdated => 0,
|
|
||||||
},
|
|
||||||
|
|
||||||
'Add Answer' => {
|
|
||||||
message => q{Add Answer},
|
|
||||||
lastUpdated => 0,
|
|
||||||
},
|
|
||||||
|
|
||||||
'Survey Objects' => {
|
'Survey Objects' => {
|
||||||
message => q{Survey Objects},
|
message => q{Survey Objects},
|
||||||
lastUpdated => 0,
|
lastUpdated => 0,
|
||||||
},
|
},
|
||||||
|
|
||||||
|
'Make Default Type' => {
|
||||||
|
message => q{Make Default Type},
|
||||||
|
lastUpdated => 0,
|
||||||
|
},
|
||||||
|
|
||||||
|
'Remove Default Type' => {
|
||||||
|
message => q{Remove Default Type},
|
||||||
|
lastUpdated => 0,
|
||||||
|
},
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
1;
|
1;
|
||||||
|
|
|
||||||
|
|
@ -146,7 +146,7 @@ Survey.Data = (function(){
|
||||||
|
|
||||||
if (!sButton) {
|
if (!sButton) {
|
||||||
sButton = new YAHOO.widget.Button({
|
sButton = new YAHOO.widget.Button({
|
||||||
label: Survey.i18n.get('Asset_Survey','Add Section'),
|
label: Survey.i18n.get('Asset_Survey','add section'),
|
||||||
id: "addSection",
|
id: "addSection",
|
||||||
container: "addSection"
|
container: "addSection"
|
||||||
});
|
});
|
||||||
|
|
@ -155,7 +155,7 @@ Survey.Data = (function(){
|
||||||
|
|
||||||
if (!qButton) {
|
if (!qButton) {
|
||||||
qButton = new YAHOO.widget.Button({
|
qButton = new YAHOO.widget.Button({
|
||||||
label: Survey.i18n.get('Asset_Survey', 'Add Question'),
|
label: Survey.i18n.get('Asset_Survey', 'add question'),
|
||||||
id: "addQuestion",
|
id: "addQuestion",
|
||||||
container: "addQuestion"
|
container: "addQuestion"
|
||||||
});
|
});
|
||||||
|
|
@ -168,7 +168,7 @@ Survey.Data = (function(){
|
||||||
YAHOO.util.Dom.setStyle('addAnswer', 'display', 'inline');
|
YAHOO.util.Dom.setStyle('addAnswer', 'display', 'inline');
|
||||||
if (!aButton) {
|
if (!aButton) {
|
||||||
aButton = new YAHOO.widget.Button({
|
aButton = new YAHOO.widget.Button({
|
||||||
label: "Add Answer",
|
label: Survey.i18n.get('Asset_Survey',"Add Answer"),
|
||||||
id: "addAnswer",
|
id: "addAnswer",
|
||||||
container: "addAnswer"
|
container: "addAnswer"
|
||||||
});
|
});
|
||||||
|
|
@ -215,10 +215,21 @@ YAHOO.util.Event.onDOMReady(function(){
|
||||||
Survey.i18n = new WebGUI.i18n( {
|
Survey.i18n = new WebGUI.i18n( {
|
||||||
'namespaces' : {
|
'namespaces' : {
|
||||||
'Asset_Survey' : [
|
'Asset_Survey' : [
|
||||||
'Add Question',
|
'Make Default Type',
|
||||||
'Add Answer',
|
'Remove Default Type',
|
||||||
'Add Section',
|
'cancel',
|
||||||
|
'add question',
|
||||||
|
'add answer',
|
||||||
|
'add section',
|
||||||
'Survey Objects'
|
'Survey Objects'
|
||||||
|
],
|
||||||
|
'Asset' : [
|
||||||
|
'Copy'
|
||||||
|
],
|
||||||
|
'WebGUI' : [
|
||||||
|
'submit',
|
||||||
|
'preview',
|
||||||
|
'576'
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
onpreload : {
|
onpreload : {
|
||||||
|
|
|
||||||
|
|
@ -75,7 +75,7 @@ Survey.ObjectTemplate = (function(){
|
||||||
document.getElementById('edit').innerHTML = html;
|
document.getElementById('edit').innerHTML = html;
|
||||||
|
|
||||||
var btns = [{
|
var btns = [{
|
||||||
text: "Submit",
|
text: Survey.i18n.get('WebGUI',"submit"),
|
||||||
handler: function(){
|
handler: function(){
|
||||||
editor.saveHTML();
|
editor.saveHTML();
|
||||||
YAHOO.util.Dom.get('texteditortarget').value = editor.getEditorHTML();
|
YAHOO.util.Dom.get('texteditortarget').value = editor.getEditorHTML();
|
||||||
|
|
@ -84,25 +84,25 @@ Survey.ObjectTemplate = (function(){
|
||||||
},
|
},
|
||||||
isDefault: true
|
isDefault: true
|
||||||
}, {
|
}, {
|
||||||
text: "Copy",
|
text: Survey.i18n.get('Asset',"Copy"),
|
||||||
handler: function(){
|
handler: function(){
|
||||||
document.getElementById('copy').value = 1;
|
document.getElementById('copy').value = 1;
|
||||||
this.submit();
|
this.submit();
|
||||||
}
|
}
|
||||||
}, {
|
}, {
|
||||||
text: "Cancel",
|
text: Survey.i18n.get('Asset_Survey',"cancel"),
|
||||||
handler: function(){
|
handler: function(){
|
||||||
this.cancel();
|
this.cancel();
|
||||||
Survey.Comm.loadSurvey('-');
|
Survey.Comm.loadSurvey('-');
|
||||||
}
|
}
|
||||||
}, {
|
}, {
|
||||||
text: "Delete",
|
text: Survey.i18n.get('WebGUI',"576"),
|
||||||
handler: function(){
|
handler: function(){
|
||||||
document.getElementById('delete').value = 1;
|
document.getElementById('delete').value = 1;
|
||||||
this.submit();
|
this.submit();
|
||||||
}
|
}
|
||||||
}, {
|
}, {
|
||||||
text: "Preview",
|
text: Survey.i18n.get('WebGUI',"preview"),
|
||||||
handler: function(){
|
handler: function(){
|
||||||
if (type === 'answer') {
|
if (type === 'answer') {
|
||||||
alert('Sorry, preview is only supported for Sections and Questions, not Answers');
|
alert('Sorry, preview is only supported for Sections and Questions, not Answers');
|
||||||
|
|
@ -119,7 +119,7 @@ Survey.ObjectTemplate = (function(){
|
||||||
}];
|
}];
|
||||||
if(type === 'question'){
|
if(type === 'question'){
|
||||||
btns[btns.length] = {
|
btns[btns.length] = {
|
||||||
text: "Make Default Type",
|
text: Survey.i18n.get('Asset_Survey',"Make Default Type"),
|
||||||
handler: function(){
|
handler: function(){
|
||||||
var name = prompt("Please change name to new type, or leave to update current type",document.forms[0].questionType.value);
|
var name = prompt("Please change name to new type, or leave to update current type",document.forms[0].questionType.value);
|
||||||
if(name != null){
|
if(name != null){
|
||||||
|
|
@ -129,10 +129,10 @@ Survey.ObjectTemplate = (function(){
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
btns[btns.length] = {
|
btns[btns.length] = {
|
||||||
text: "Remove Default Type",
|
text: Survey.i18n.get('Asset_Survey',"Remove Default Type"),
|
||||||
handler: function(){
|
handler: function(){
|
||||||
document.getElementById('removetype').value = 1;
|
document.getElementById('removetype').value = 1;
|
||||||
this.submit();
|
this.submit();
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue