Browse Source

bug解决

haogh 7 months ago
parent
commit
63c2b76606

+ 6 - 3
src/cn/hmsoft/art/control/score/ScoreCheckContorl.java

@@ -4,6 +4,7 @@ import java.util.HashMap;
 import java.util.List;
 import java.util.Map;
 
+import cn.hmsoft.art.data.model.sc.ScStdSubject;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.web.bind.annotation.RequestMapping;
 import org.springframework.web.bind.annotation.RestController;
@@ -23,7 +24,7 @@ public class ScoreCheckContorl extends ArtControl {
 
 	@RequestMapping("score/check/std")
 	public Ajax checkStd(int std_id) {
-		Map<String, Object> returnMap = new HashMap<String, Object>();
+		/*Map<String, Object> returnMap = new HashMap<String, Object>();
 		// 原始成绩
 		returnMap.put("SubjectScoreArray", this.daoStdSubject.list("std_id", std_id, new QueryOrder("subject_id")));
 		// 专业成绩
@@ -35,7 +36,9 @@ public class ScoreCheckContorl extends ArtControl {
 				returnMap.put("SubjectArray_" + aspect_id + "_" + i,
 						this.daoStdAspect.listStdSubject(std_id, aspect_id, i,null));
 		}
-		returnMap.put("AspectArray", aspectArray);
-		return new Ajax(returnMap);
+		returnMap.put("AspectArray", aspectArray);*/
+
+		List<ScStdSubject> subjectArray = this.daoStdSubject.list("std_id", std_id);
+		return new Ajax(subjectArray);
 	}
 }

+ 7 - 0
src/cn/hmsoft/art/service/score/FzScoreService.java

@@ -143,6 +143,13 @@ public class FzScoreService extends ArtService {
                 throw new BusinessException("第【" + row + "】行,成绩格式错误");
             }
 
+            if (StringHelper.isEmpty(qualified)) {
+                throw new BusinessException("第【" + row + "】行,是否合格不能为空");
+            } else if (qualified.length() > 8) {
+                throw new BusinessException("第【" + row + "】行,是否合格长度不能超过8个字符");
+            }
+
+
             fzScore.setStd_name(std_name);
             fzScore.setCert_id(cert_id);
             fzScore.setTicket_no(ticket_no);