|
@@ -424,6 +424,32 @@ public class CloudMarkingTaskUtils {
|
|
|
}
|
|
|
}
|
|
|
|
|
|
+ /**
|
|
|
+ * 绑定科组长接口
|
|
|
+ *
|
|
|
+ * @param schoolId 学校ID
|
|
|
+ * @param subjectCode 科目代码
|
|
|
+ * @param loginName 用户名
|
|
|
+ */
|
|
|
+ public boolean saveMarkLeader(Long schoolId, String subjectCode, String loginName) {
|
|
|
+ String hostUrl = dictionaryConfig.syncDataDomain().getHostUrl();
|
|
|
+ String markLeaderSaveUrl = dictionaryConfig.syncDataDomain().getMarkLeaderSaveUrl();
|
|
|
+ validUrl(hostUrl, markLeaderSaveUrl);
|
|
|
+ String postUrl = hostUrl.concat(markLeaderSaveUrl);
|
|
|
+ try {
|
|
|
+ //参数
|
|
|
+ Map<String, Object> map = new HashMap<>();
|
|
|
+ map.put("subjectCode", validParam(subjectCode, null, true, "科目代码"));
|
|
|
+ map.put("account", MARKER_LEADER_PREFIX + validParam(loginName, null, true, "用户名"));
|
|
|
+
|
|
|
+ String result = HttpKit.sendPost(postUrl, getHeaders(schoolId, markLeaderSaveUrl), map, null, null, null);
|
|
|
+ JSONObject jsonObject = JSONObject.parseObject(result);
|
|
|
+ return jsonObject.containsKey("updateTime");
|
|
|
+ } catch (Exception e) {
|
|
|
+ throw ExceptionResultEnum.ERROR.exception(e.getMessage());
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
/**
|
|
|
* 评卷员登录
|
|
|
*/
|