diff --git a/public/react/src/context/TPIContextProvider.js b/public/react/src/context/TPIContextProvider.js index cc0fdbee..b4a645df 100644 --- a/public/react/src/context/TPIContextProvider.js +++ b/public/react/src/context/TPIContextProvider.js @@ -533,6 +533,14 @@ pop_box_new(htmlvalue, 480, 182); if (currentGamePassed) { game.status = 2; game.next_game = next_game; + } else { + this.showDialog({ + contentText:
+
评测未通过
+
详情请参见“测试结果”
+
, + isSingleButton: true + }) } const output_sets = { @@ -630,11 +638,12 @@ pop_box_new(htmlvalue, 480, 182); @param okButtonText “确定”按钮显示文本,如 继续查看 */ showDialog(params) { - const { contentText, callback, moreButtonsRender, okButtonText } = params; + const { contentText, callback, moreButtonsRender, okButtonText, isSingleButton } = params; this.dialogOkCallback = callback; this.moreButtonsRender = moreButtonsRender this.okButtonText = okButtonText; + this.isSingleButton = !!isSingleButton this.setState({ gDialogOpen: true, gDialogContentText: contentText @@ -696,14 +705,23 @@ pop_box_new(htmlvalue, 480, 182); - - - {this.moreButtonsRender && this.moreButtonsRender()} + { this.isSingleButton ?
+ 知道啦 +
: + + + + + } + {this.moreButtonsRender && this.moreButtonsRender()}