From e112369ff174723377714b561d845aea654e416a Mon Sep 17 00:00:00 2001 From: hjm <63528605@qq.com> Date: Tue, 16 Jul 2019 10:13:28 +0800 Subject: [PATCH] lang --- public/react/src/modules/page/component/monaco/TPIMonaco.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/public/react/src/modules/page/component/monaco/TPIMonaco.js b/public/react/src/modules/page/component/monaco/TPIMonaco.js index 1d5193a6e..d6c0ba5cc 100644 --- a/public/react/src/modules/page/component/monaco/TPIMonaco.js +++ b/public/react/src/modules/page/component/monaco/TPIMonaco.js @@ -154,11 +154,13 @@ function checkIfLoaded (callback) { const mirror2LanguageMap = { 'JFinal': 'java', 'Java': 'java', + 'JavaWeb': 'java', 'Kotlin': 'java', 'Html': 'html', 'Css': 'css', 'Javascript': 'javascript', + 'JavaScript': 'javascript', 'C/C++': 'cpp', 'MachineLearning': 'python', @@ -173,6 +175,7 @@ function getLanguageByMirrorName(mirror_name) { let lang = 'javascript' if (mirror_name && mirror_name.length) { // 需要倒着遍历, html、css的实训,主评测语言环境是python,小类别是html或css + // TODO http://localhost:3007/tasks/hmcwa3g8typ5?debug=t ["Python3.6", "VNC", "Html"] for (let i = mirror_name.length - 1; i >= 0; i--) { let languageVal = mirror2LanguageMap[mirror_name[i]]; if (languageVal) {