server: changes lang field to name

This commit is contained in:
bjorn
2008-09-12 11:32:30 +00:00
parent 9cebc28e8e
commit ddd4d418c0
2 changed files with 5 additions and 5 deletions

View File

@@ -102,9 +102,9 @@ doLinearize pgf tree mto = showJSON $ map toJSObject
doLanguages :: PGF -> JSValue
doLanguages pgf = showJSON $ map toJSObject
[[("lang", showJSON l),
("languageCode", showJSON $ fromMaybe "" (PGF.languageCode pgf l)),
("canParse", showJSON $ PGF.canParse pgf l)]
[[("name", showJSON l),
("languageCode", showJSON $ fromMaybe "" (PGF.languageCode pgf l)),
("canParse", showJSON $ PGF.canParse pgf l)]
| l <- PGF.languages pgf]
doCategories :: PGF -> JSValue

View File

@@ -27,9 +27,9 @@
var t = document.getElementById('toLang');
for (var i in langs) {
if (langs[i].canParse) {
addOption(f, langs[i].lang, langs[i].lang);
addOption(f, langs[i].name, langs[i].name);
}
addOption(t, langs[i].lang, langs[i].lang);
addOption(t, langs[i].name, langs[i].name);
}
}