This commit is contained in:
郑明仁 2019-08-19 08:38:18 +08:00
parent 0d29d7a136
commit 706a341b0b
2 changed files with 2 additions and 13 deletions

View File

@ -1,21 +1,11 @@
package com.educoder.bridge.k8s.controller;
import com.alibaba.fastjson.JSONObject;
import com.educoder.bridge.common.constant.ApiResultCodeCsts;
import com.educoder.bridge.common.model.ApiResult;
import com.educoder.bridge.common.model.BridgePage;
import com.educoder.bridge.game.service.K8sService;
import com.educoder.bridge.k8s.model.BridgePod;
import com.educoder.bridge.k8s.model.EvaluatingScript;
import com.educoder.bridge.k8s.model.PodQueryParam;
import com.educoder.bridge.k8s.service.BridgePodService;
import com.educoder.bridge.k8s.service.EvaScriptService;
import com.github.pagehelper.Page;
import io.fabric8.kubernetes.api.model.Pod;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import io.swagger.annotations.ApiParam;
import org.apache.commons.lang.StringEscapeUtils;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
@ -23,7 +13,6 @@ import org.springframework.http.MediaType;
import org.springframework.web.bind.annotation.*;
import java.time.LocalDateTime;
import java.util.List;
/**
* 评测脚本相关的接口
@ -58,7 +47,7 @@ public class ScriptController {
evaluatingScript.setScript(script);
evaluatingScript.setCreateTime(now);
evaluatingScript.setUpdateTime(now);
evaScriptService.savaEvaluationScript(evaluatingScript);
evaScriptService.saveEvaluationScript(evaluatingScript);
} else {
evaluatingScript.setScript(script);
evaluatingScript.setUpdateTime(now);

View File

@ -18,7 +18,7 @@ public class EvaScriptService {
@Autowired
private EvaScriptMapper evaScriptMapper;
public void savaEvaluationScript(EvaluatingScript evaluatingScript) {
public void saveEvaluationScript(EvaluatingScript evaluatingScript) {
evaScriptMapper.insert(evaluatingScript);
}