Add and Delete only from the English collection.
This commit is contained in:
1 parent
decbff5ed8
commit
02083f3562
3 files changed
+26
-2
No files matched your search
@@ -36,7 +36,16 @@
|
||||
},
|
||||
{
|
||||
"style": "Text",
|
||||
"text": "Vaina 1"
|
||||
"text": "Vaina 1 Hello What's up?",
|
||||
"updated": 1609084560339,
|
||||
"translations": [
|
||||
{
|
||||
"language": "ES",
|
||||
"text": "Vaina 1 Hola. Que hay?",
|
||||
"updated": 1609084602600,
|
||||
"style": "Text"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"style": "Link",
|
||||
|
||||
@@ -16,7 +16,12 @@
|
||||
},
|
||||
{
|
||||
"style": "Success",
|
||||
"text": "Users can switch between languages using the links provided at the footer of every page at the Docs."
|
||||
"text": " Users can switch between languages using the links provided at the footer of every page at the Docs. ",
|
||||
"updated": 1609085068937
|
||||
},
|
||||
{
|
||||
"style": "Note",
|
||||
"text": "You can only add or delete pages to the Docs if you are navigating it in English, because English is the default language, and from there pages are later translated. "
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -1079,6 +1079,11 @@ function newSuperalgosDocSpace() {
|
||||
}
|
||||
if (command.indexOf('Docs.Add') !== 0 && command.indexOf('docs.add') !== 0) { return 'Not Add Command' }
|
||||
|
||||
if (language !== DEFAULT_LANGUAGE) {
|
||||
renderCommandResultsPage(["Usage Error. You can only add pages to the Docs while you are navigating it in English."])
|
||||
return
|
||||
}
|
||||
|
||||
let splittedCommand = command.split(': ')
|
||||
if (splittedCommand[1] === undefined) {
|
||||
renderCommandResultsPage(["Syntax Error. Keyword <b>: </b> missing: Example: docs.add Concept to Superalgos: New Concept Name. The keyword is a : character plus a blank space. Type <i>help docs.add</i> to learn the command's syntax."])
|
||||
@@ -1149,6 +1154,11 @@ function newSuperalgosDocSpace() {
|
||||
}
|
||||
if (command.indexOf('Docs.Delete') !== 0 && command.indexOf('docs.delete') !== 0) { return 'Not Delete Command' }
|
||||
|
||||
if (language !== DEFAULT_LANGUAGE) {
|
||||
renderCommandResultsPage(["Usage Error. You can only delete pages from the Docs while you are navigating it in English."])
|
||||
return
|
||||
}
|
||||
|
||||
let splittedCommand = command.split(': ')
|
||||
if (splittedCommand[1] === undefined) {
|
||||
renderCommandResultsPage(["Syntax Error. Keyword <b>: </b> missing: Example: docs.delete Concept from Superalgos: Concept Name. The keyword is a : character plus a blank space. Type <i>Hekp docs.delete</i> to learn the command's syntax."])
|
||||
|
||||
Reference in new issue
Block a user