feat: 집합교육 작업중
parent
a167cee4ba
commit
f9fe8d2f2e
6
list.txt
6
list.txt
|
|
@ -1,6 +1,11 @@
|
||||||
src\main\webapp\WEB-INF\views\home\include\top.jsp
|
src\main\webapp\WEB-INF\views\home\include\top.jsp
|
||||||
src\main\java\geoinfo\main\main\MainController.java
|
src\main\java\geoinfo\main\main\MainController.java
|
||||||
src\main\java\geoinfo\main\login\LoginController.java
|
src\main\java\geoinfo\main\login\LoginController.java
|
||||||
|
src\main\java\geoinfo\training\home\HomeTrainingController.java
|
||||||
|
src\main\java\geoinfo\training\home\service\HomeTrainingService.java
|
||||||
|
src\main\java\geoinfo\training\home\service\impl\HomeTrainingServiceImpl.java
|
||||||
|
src\main\java\geoinfo\training\home\service\HomeTrainingMapper.java
|
||||||
|
src\main\resources\egovframework\sqlmap\mapper\training\home\HomeTrainingMapper.xml
|
||||||
src\main\webapp\WEB-INF\views\visitEducationApplication\inquiry\visitEducationApplicationInquiry.jsp
|
src\main\webapp\WEB-INF\views\visitEducationApplication\inquiry\visitEducationApplicationInquiry.jsp
|
||||||
src\main\webapp\WEB-INF\views\visitEducationApplication\input\visitEducationApplicationInput.jsp
|
src\main\webapp\WEB-INF\views\visitEducationApplication\input\visitEducationApplicationInput.jsp
|
||||||
src\main\webapp\com\img\visitEducationApplication\visitEducationApplicationSample.svg
|
src\main\webapp\com\img\visitEducationApplication\visitEducationApplicationSample.svg
|
||||||
|
|
@ -18,3 +23,4 @@ src\main\webapp\com\fonts\NotoSansKr\NotoSansKR-Regular.otf
|
||||||
src\main\webapp\com\fonts\NotoSansKr\NotoSansKR-Bold.woff2
|
src\main\webapp\com\fonts\NotoSansKr\NotoSansKR-Bold.woff2
|
||||||
src\main\webapp\com\fonts\NotoSansKr\NotoSansKR-Bold.woff
|
src\main\webapp\com\fonts\NotoSansKr\NotoSansKR-Bold.woff
|
||||||
src\main\webapp\com\fonts\NotoSansKr\NotoSansKR-Bold.otf
|
src\main\webapp\com\fonts\NotoSansKr\NotoSansKR-Bold.otf
|
||||||
|
src\main\resources\egovframework\sqlmap\mapper\main\Login_SQL.xml
|
||||||
|
|
|
||||||
|
|
@ -642,6 +642,11 @@ public class LoginController {
|
||||||
String userName = "";
|
String userName = "";
|
||||||
String companyName = "";
|
String companyName = "";
|
||||||
|
|
||||||
|
String partName = "";
|
||||||
|
String phone = "";
|
||||||
|
String email = "";
|
||||||
|
|
||||||
|
|
||||||
int loginCnt = 0;
|
int loginCnt = 0;
|
||||||
String lastLoginDate = "";
|
String lastLoginDate = "";
|
||||||
|
|
||||||
|
|
@ -776,6 +781,8 @@ public class LoginController {
|
||||||
//String brower = "";
|
//String brower = "";
|
||||||
|
|
||||||
request.getSession().setAttribute("USERAGENT", agent); // 접속 브라우져 정보
|
request.getSession().setAttribute("USERAGENT", agent); // 접속 브라우져 정보
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
|
|
@ -825,6 +832,20 @@ public class LoginController {
|
||||||
|
|
||||||
request.getSession().setAttribute("USERAGENT", agent); // 접속 브라우져 정보
|
request.getSession().setAttribute("USERAGENT", agent); // 접속 브라우져 정보
|
||||||
|
|
||||||
|
if( selectWebMemberIn.get("part_name") != null ) {
|
||||||
|
partName = selectWebMemberIn.get("part_name").toString();
|
||||||
|
}
|
||||||
|
if( selectWebMemberIn.get("phone") != null ) {
|
||||||
|
phone = selectWebMemberIn.get("phone").toString();
|
||||||
|
}
|
||||||
|
if( selectWebMemberIn.get("email") != null ) {
|
||||||
|
email = selectWebMemberIn.get("email").toString();
|
||||||
|
}
|
||||||
|
|
||||||
|
request.getSession().setAttribute("PARTNNAME", partName);
|
||||||
|
request.getSession().setAttribute("PHONE", phone);
|
||||||
|
request.getSession().setAttribute("EMAIL", email);
|
||||||
|
|
||||||
// 로그 insert
|
// 로그 insert
|
||||||
map.put("userid", userid);
|
map.put("userid", userid);
|
||||||
map.put("sessionid", request.getSession().getId());
|
map.put("sessionid", request.getSession().getId());
|
||||||
|
|
|
||||||
|
|
@ -517,6 +517,11 @@ public class MainController
|
||||||
mv.addObject("companyname", request.getSession().getAttribute("COMPANYNAME"));
|
mv.addObject("companyname", request.getSession().getAttribute("COMPANYNAME"));
|
||||||
mv.addObject("url", url);
|
mv.addObject("url", url);
|
||||||
mv.addObject("cls", request.getSession().getAttribute("CLS"));
|
mv.addObject("cls", request.getSession().getAttribute("CLS"));
|
||||||
|
|
||||||
|
mv.addObject("partname", request.getSession().getAttribute("PARTNNAME"));
|
||||||
|
mv.addObject("phone", request.getSession().getAttribute("PHONE"));
|
||||||
|
mv.addObject("email", request.getSession().getAttribute("EMAIL"));
|
||||||
|
|
||||||
mv.addObject("eGovUrl", eGovUrl);
|
mv.addObject("eGovUrl", eGovUrl);
|
||||||
|
|
||||||
return mv;
|
return mv;
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,422 @@
|
||||||
|
package geoinfo.training.home;
|
||||||
|
|
||||||
|
import java.util.Date;
|
||||||
|
import java.util.HashMap;
|
||||||
|
|
||||||
|
import javax.annotation.Resource;
|
||||||
|
import javax.servlet.http.HttpServletRequest;
|
||||||
|
import javax.servlet.http.HttpServletResponse;
|
||||||
|
|
||||||
|
import org.apache.log4j.Logger;
|
||||||
|
import org.json.simple.JSONArray;
|
||||||
|
import org.json.simple.JSONObject;
|
||||||
|
import org.json.simple.parser.JSONParser;
|
||||||
|
import org.springframework.stereotype.Controller;
|
||||||
|
import org.springframework.web.bind.annotation.RequestBody;
|
||||||
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
|
import org.springframework.web.bind.annotation.RequestMethod;
|
||||||
|
import org.springframework.web.bind.annotation.RequestParam;
|
||||||
|
import org.springframework.web.bind.annotation.ResponseBody;
|
||||||
|
import geoinfo.training.home.service.HomeTrainingService;
|
||||||
|
import geoinfo.util.MyUtil;
|
||||||
|
|
||||||
|
|
||||||
|
@Controller
|
||||||
|
public class HomeTrainingController {
|
||||||
|
|
||||||
|
@Resource(name = "homeTrainingService")
|
||||||
|
private HomeTrainingService homeTrainingService;
|
||||||
|
|
||||||
|
|
||||||
|
private static final Logger LOGGER = Logger.getLogger(HomeTrainingController.class.getName());
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 집합교육 참석
|
||||||
|
* @param request
|
||||||
|
* @param strJSON
|
||||||
|
* @param response
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@RequestMapping(value = "training/home/attend.do", method = RequestMethod.POST)
|
||||||
|
@ResponseBody
|
||||||
|
public JSONObject attendHomeTraining(
|
||||||
|
HttpServletRequest request,
|
||||||
|
@RequestBody String strJSON,
|
||||||
|
HttpServletResponse response) {
|
||||||
|
|
||||||
|
|
||||||
|
JSONObject jsonResponse = new JSONObject();
|
||||||
|
|
||||||
|
System.out.println(
|
||||||
|
"\n--------------------------------------------------------------\n" +
|
||||||
|
request.getRequestURI() + " IN:" +
|
||||||
|
"\n--------------------------------------------------------------\n" +
|
||||||
|
"strJSON" + strJSON + "\n" +
|
||||||
|
"\n--------------------------------------------------------------\n"
|
||||||
|
);
|
||||||
|
|
||||||
|
JSONParser jsonParser = new JSONParser();
|
||||||
|
JSONArray jsonArr = null;
|
||||||
|
boolean isFail = false;
|
||||||
|
String failMsg = "";
|
||||||
|
|
||||||
|
|
||||||
|
/*
|
||||||
|
whtRegId : 집합교육 일련번호
|
||||||
|
reqName : 성명
|
||||||
|
companyName : 기관명
|
||||||
|
reqDept : 부서명
|
||||||
|
reqPosition : 직급
|
||||||
|
reqTel : 연락처
|
||||||
|
reqEmail : 이메일
|
||||||
|
*/
|
||||||
|
|
||||||
|
|
||||||
|
try {
|
||||||
|
jsonArr = (JSONArray)jsonParser.parse(strJSON);
|
||||||
|
for (Object obj : jsonArr) {
|
||||||
|
JSONObject jsonObject = (JSONObject) obj;
|
||||||
|
|
||||||
|
// JSONObject를 HashMap으로 변환
|
||||||
|
HashMap<String, Object> params = new HashMap<>();
|
||||||
|
for (Object key : jsonObject.keySet()) {
|
||||||
|
String keyStr = (String) key;
|
||||||
|
Object value = jsonObject.get(keyStr);
|
||||||
|
params.put(keyStr, value);
|
||||||
|
}
|
||||||
|
|
||||||
|
try {
|
||||||
|
HashMap<String, Object> hashMap = homeTrainingService.attendHomeTraining(request, response, params);
|
||||||
|
int nRetCode = MyUtil.getIntegerFromObject(hashMap.get("resultCode"));
|
||||||
|
String lpszRetMsg = MyUtil.getStringFromObject(hashMap.get("errMsg"));
|
||||||
|
long lWvtRegId = MyUtil.getLongFromObject(hashMap.get("whtId"));
|
||||||
|
|
||||||
|
|
||||||
|
if( nRetCode == 100 ) {
|
||||||
|
jsonResponse.put("resultCode", nRetCode);
|
||||||
|
jsonResponse.put("result", "true");
|
||||||
|
jsonResponse.put("message", "교육 신청이 완료되었습니다.");
|
||||||
|
} else {
|
||||||
|
if( nRetCode == 11 ) {
|
||||||
|
lpszRetMsg += "\n" +
|
||||||
|
"사업명: " + params.get("constName");
|
||||||
|
}
|
||||||
|
jsonResponse.put("resultCode", nRetCode);
|
||||||
|
jsonResponse.put("result", "false");
|
||||||
|
jsonResponse.put("message", lpszRetMsg);
|
||||||
|
|
||||||
|
isFail = true;
|
||||||
|
failMsg = lpszRetMsg;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
|
} catch (Exception e) {
|
||||||
|
// TODO Auto-generated catch block
|
||||||
|
String strTxt =
|
||||||
|
"---------- BUG REPORTING START ----------" + "\n" +
|
||||||
|
"에러 문구:[" + request.getRequestURI() + " " + "]" + "\n" +
|
||||||
|
"strJSON:[\n" + strJSON + "\n]\n" +
|
||||||
|
"e.getMessage():[\n" + e.getMessage() + "\n]\n" + "\n" +
|
||||||
|
"new Date().toString():[" + new Date().toString() + "]\n" + "\n" +
|
||||||
|
"---------- BUG REPORTING END ----------" + "\n" +
|
||||||
|
"";
|
||||||
|
System.out.println(strTxt);
|
||||||
|
int resultCode = -1;
|
||||||
|
|
||||||
|
if( e.getMessage().equals("로그인이 필요한 서비스 입니다.") ) {
|
||||||
|
resultCode = 401;
|
||||||
|
}
|
||||||
|
jsonResponse.put("resultCode", resultCode);
|
||||||
|
jsonResponse.put("result", "false");
|
||||||
|
jsonResponse.put("message", e.getMessage());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
} catch (org.json.simple.parser.ParseException e) {
|
||||||
|
// TODO Auto-generated catch block
|
||||||
|
e.printStackTrace();
|
||||||
|
}
|
||||||
|
|
||||||
|
if( isFail ) {
|
||||||
|
jsonResponse.put("resultCode", -2);
|
||||||
|
jsonResponse.put("result", "false");
|
||||||
|
jsonResponse.put("message", failMsg);
|
||||||
|
}
|
||||||
|
|
||||||
|
System.out.println("\n--------------------------------------------------------------\n" +
|
||||||
|
request.getRequestURI() + " OUT:" +
|
||||||
|
"\n--------------------------------------------------------------\n" +
|
||||||
|
"jsonResponse.toJSONString():[" + jsonResponse.toJSONString() + "]\n" +
|
||||||
|
"\n--------------------------------------------------------------\n");
|
||||||
|
|
||||||
|
return jsonResponse;
|
||||||
|
}
|
||||||
|
|
||||||
|
@RequestMapping(value = "training/home/list.do", method = RequestMethod.GET)
|
||||||
|
@ResponseBody
|
||||||
|
public JSONObject getHomeTraining(
|
||||||
|
HttpServletRequest request,
|
||||||
|
@RequestParam HashMap<String, Object> params,
|
||||||
|
HttpServletResponse response) {
|
||||||
|
|
||||||
|
|
||||||
|
JSONObject jsonResponse = new JSONObject();
|
||||||
|
|
||||||
|
System.out.println(
|
||||||
|
"\n--------------------------------------------------------------\n" +
|
||||||
|
request.getRequestURI() + " IN:" +
|
||||||
|
"\n--------------------------------------------------------------\n" +
|
||||||
|
"params.toString()" + params.toString() + "\n" +
|
||||||
|
"\n--------------------------------------------------------------\n"
|
||||||
|
);
|
||||||
|
|
||||||
|
|
||||||
|
try {
|
||||||
|
homeTrainingService.getHomeTraining(request, response, jsonResponse, params);
|
||||||
|
jsonResponse.put("resultCode", 100);
|
||||||
|
jsonResponse.put("result", "true");
|
||||||
|
jsonResponse.put("message", "조회가 완료되었습니다.");
|
||||||
|
|
||||||
|
} catch (Exception e) {
|
||||||
|
// TODO Auto-generated catch block
|
||||||
|
String strTxt =
|
||||||
|
"---------- BUG REPORTING START ----------" + "\n" +
|
||||||
|
"에러 문구:[" + request.getRequestURI() + " " + "]" + "\n" +
|
||||||
|
"e.getMessage():[\n" + e.getMessage() + "\n]\n" + "\n" +
|
||||||
|
"new Date().toString():[" + new Date().toString() + "]\n" + "\n" +
|
||||||
|
"---------- BUG REPORTING END ----------" + "\n" +
|
||||||
|
"";
|
||||||
|
System.out.println(strTxt);
|
||||||
|
jsonResponse.put("resultCode", -1);
|
||||||
|
jsonResponse.put("result", "false");
|
||||||
|
jsonResponse.put("message", e.getMessage());
|
||||||
|
}
|
||||||
|
|
||||||
|
System.out.println(
|
||||||
|
"\n--------------------------------------------------------------\n" +
|
||||||
|
request.getRequestURI() + " OUT:" +
|
||||||
|
"\n--------------------------------------------------------------\n" +
|
||||||
|
"jsonResponse.toJSONString():[" + jsonResponse.toJSONString() + "]\n" +
|
||||||
|
"\n--------------------------------------------------------------\n"
|
||||||
|
);
|
||||||
|
|
||||||
|
return jsonResponse;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 집합교육 참석 수정
|
||||||
|
* @param request
|
||||||
|
* @param strJSON
|
||||||
|
* @param response
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@RequestMapping(value = "training/home/update.do", method = RequestMethod.POST)
|
||||||
|
@ResponseBody
|
||||||
|
public JSONObject updateHomeTraining(
|
||||||
|
HttpServletRequest request,
|
||||||
|
@RequestBody String strJSON,
|
||||||
|
HttpServletResponse response) {
|
||||||
|
|
||||||
|
|
||||||
|
JSONObject jsonResponse = new JSONObject();
|
||||||
|
|
||||||
|
System.out.println(
|
||||||
|
"\n--------------------------------------------------------------\n" +
|
||||||
|
request.getRequestURI() + " IN:" +
|
||||||
|
"\n--------------------------------------------------------------\n" +
|
||||||
|
"strJSON" + strJSON + "\n" +
|
||||||
|
"\n--------------------------------------------------------------\n"
|
||||||
|
);
|
||||||
|
|
||||||
|
JSONParser jsonParser = new JSONParser();
|
||||||
|
JSONArray jsonArr = null;
|
||||||
|
boolean isFail = false;
|
||||||
|
String failMsg = "";
|
||||||
|
|
||||||
|
|
||||||
|
try {
|
||||||
|
jsonArr = (JSONArray)jsonParser.parse(strJSON);
|
||||||
|
for (Object obj : jsonArr) {
|
||||||
|
JSONObject jsonObject = (JSONObject) obj;
|
||||||
|
|
||||||
|
// JSONObject를 HashMap으로 변환
|
||||||
|
HashMap<String, Object> params = new HashMap<>();
|
||||||
|
for (Object key : jsonObject.keySet()) {
|
||||||
|
String keyStr = (String) key;
|
||||||
|
Object value = jsonObject.get(keyStr);
|
||||||
|
params.put(keyStr, value);
|
||||||
|
}
|
||||||
|
try {
|
||||||
|
HashMap<String, Object> hashMap = homeTrainingService.updateHomeTraining(request, response, params);
|
||||||
|
int nRetCode = MyUtil.getIntegerFromObject(hashMap.get("resultCode"));
|
||||||
|
String lpszRetMsg = MyUtil.getStringFromObject(hashMap.get("errMsg"));
|
||||||
|
|
||||||
|
if( nRetCode == 100 ) {
|
||||||
|
jsonResponse.put("resultCode", nRetCode);
|
||||||
|
jsonResponse.put("result", "true");
|
||||||
|
jsonResponse.put("message", "수정이 완료되었습니다.");
|
||||||
|
} else {
|
||||||
|
if( nRetCode == 11 ) {
|
||||||
|
lpszRetMsg += "\n" +
|
||||||
|
"사업명: " + params.get("constName");
|
||||||
|
}
|
||||||
|
jsonResponse.put("resultCode", nRetCode);
|
||||||
|
jsonResponse.put("result", "false");
|
||||||
|
jsonResponse.put("message", lpszRetMsg);
|
||||||
|
|
||||||
|
isFail = true;
|
||||||
|
failMsg = lpszRetMsg;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
|
} catch (Exception e) {
|
||||||
|
// TODO Auto-generated catch block
|
||||||
|
String strTxt =
|
||||||
|
"---------- BUG REPORTING START ----------" + "\n" +
|
||||||
|
"에러 문구:[" + request.getRequestURI() + " " + "]" + "\n" +
|
||||||
|
"strJSON:[\n" + strJSON + "\n]\n" +
|
||||||
|
"e.getMessage():[\n" + e.getMessage() + "\n]\n" + "\n" +
|
||||||
|
"new Date().toString():[" + new Date().toString() + "]\n" + "\n" +
|
||||||
|
"---------- BUG REPORTING END ----------" + "\n" +
|
||||||
|
"";
|
||||||
|
System.out.println(strTxt);
|
||||||
|
int resultCode = -1;
|
||||||
|
|
||||||
|
if( e.getMessage().equals("로그인이 필요한 서비스 입니다.") ) {
|
||||||
|
resultCode = 401;
|
||||||
|
}
|
||||||
|
jsonResponse.put("resultCode", resultCode);
|
||||||
|
jsonResponse.put("result", "false");
|
||||||
|
jsonResponse.put("message", e.getMessage());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
} catch (org.json.simple.parser.ParseException e) {
|
||||||
|
// TODO Auto-generated catch block
|
||||||
|
e.printStackTrace();
|
||||||
|
}
|
||||||
|
|
||||||
|
if( isFail ) {
|
||||||
|
jsonResponse.put("resultCode", -2);
|
||||||
|
jsonResponse.put("result", "false");
|
||||||
|
jsonResponse.put("message", failMsg);
|
||||||
|
}
|
||||||
|
|
||||||
|
System.out.println("\n--------------------------------------------------------------\n" +
|
||||||
|
request.getRequestURI() + " OUT:" +
|
||||||
|
"\n--------------------------------------------------------------\n" +
|
||||||
|
"jsonResponse.toJSONString():[" + jsonResponse.toJSONString() + "]\n" +
|
||||||
|
"\n--------------------------------------------------------------\n");
|
||||||
|
|
||||||
|
return jsonResponse;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 신청한 집합교육을 취소한다.
|
||||||
|
* @param request
|
||||||
|
* @param strJSON
|
||||||
|
* @param response
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@RequestMapping(value = "training/home/cancel.do", method = RequestMethod.POST)
|
||||||
|
@ResponseBody
|
||||||
|
public JSONObject cancelHomeTraining(
|
||||||
|
HttpServletRequest request,
|
||||||
|
@RequestBody String strJSON,
|
||||||
|
HttpServletResponse response) {
|
||||||
|
|
||||||
|
JSONObject jsonResponse = new JSONObject();
|
||||||
|
|
||||||
|
System.out.println(
|
||||||
|
"\n--------------------------------------------------------------\n" +
|
||||||
|
request.getRequestURI() + " IN:" +
|
||||||
|
"\n--------------------------------------------------------------\n" +
|
||||||
|
"strJSON" + strJSON + "\n" +
|
||||||
|
"\n--------------------------------------------------------------\n"
|
||||||
|
);
|
||||||
|
|
||||||
|
JSONParser jsonParser = new JSONParser();
|
||||||
|
JSONArray jsonArr = null;
|
||||||
|
boolean isFail = false;
|
||||||
|
String failMsg = "";
|
||||||
|
|
||||||
|
|
||||||
|
try {
|
||||||
|
jsonArr = (JSONArray)jsonParser.parse(strJSON);
|
||||||
|
for (Object obj : jsonArr) {
|
||||||
|
JSONObject jsonObject = (JSONObject) obj;
|
||||||
|
|
||||||
|
// JSONObject를 HashMap으로 변환
|
||||||
|
HashMap<String, Object> params = new HashMap<>();
|
||||||
|
for (Object key : jsonObject.keySet()) {
|
||||||
|
String keyStr = (String) key;
|
||||||
|
Object value = jsonObject.get(keyStr);
|
||||||
|
params.put(keyStr, value);
|
||||||
|
}
|
||||||
|
try {
|
||||||
|
HashMap<String, Object> hashMap = homeTrainingService.cancelHomeTraining(request, response, params);
|
||||||
|
int nRetCode = MyUtil.getIntegerFromObject(hashMap.get("resultCode"));
|
||||||
|
String lpszRetMsg = MyUtil.getStringFromObject(hashMap.get("errMsg"));
|
||||||
|
|
||||||
|
|
||||||
|
if( nRetCode == 100 ) {
|
||||||
|
jsonResponse.put("resultCode", nRetCode);
|
||||||
|
jsonResponse.put("result", "true");
|
||||||
|
jsonResponse.put("message", "교육 신청 취소가 완료되었습니다.");
|
||||||
|
} else {
|
||||||
|
if( nRetCode == 11 ) {
|
||||||
|
lpszRetMsg += "\n" +
|
||||||
|
"사업명: " + params.get("constName");
|
||||||
|
}
|
||||||
|
jsonResponse.put("resultCode", nRetCode);
|
||||||
|
jsonResponse.put("result", "false");
|
||||||
|
jsonResponse.put("message", lpszRetMsg);
|
||||||
|
|
||||||
|
isFail = true;
|
||||||
|
failMsg = lpszRetMsg;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
|
} catch (Exception e) {
|
||||||
|
// TODO Auto-generated catch block
|
||||||
|
String strTxt =
|
||||||
|
"---------- BUG REPORTING START ----------" + "\n" +
|
||||||
|
"에러 문구:[" + request.getRequestURI() + " " + "]" + "\n" +
|
||||||
|
"strJSON:[\n" + strJSON + "\n]\n" +
|
||||||
|
"e.getMessage():[\n" + e.getMessage() + "\n]\n" + "\n" +
|
||||||
|
"new Date().toString():[" + new Date().toString() + "]\n" + "\n" +
|
||||||
|
"---------- BUG REPORTING END ----------" + "\n" +
|
||||||
|
"";
|
||||||
|
System.out.println(strTxt);
|
||||||
|
int resultCode = -1;
|
||||||
|
|
||||||
|
if( e.getMessage().equals("로그인이 필요한 서비스 입니다.") ) {
|
||||||
|
resultCode = 401;
|
||||||
|
}
|
||||||
|
jsonResponse.put("resultCode", resultCode);
|
||||||
|
jsonResponse.put("result", "false");
|
||||||
|
jsonResponse.put("message", e.getMessage());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
} catch (org.json.simple.parser.ParseException e) {
|
||||||
|
// TODO Auto-generated catch block
|
||||||
|
e.printStackTrace();
|
||||||
|
}
|
||||||
|
|
||||||
|
if( isFail ) {
|
||||||
|
jsonResponse.put("resultCode", -2);
|
||||||
|
jsonResponse.put("result", "false");
|
||||||
|
jsonResponse.put("message", failMsg);
|
||||||
|
}
|
||||||
|
|
||||||
|
System.out.println("\n--------------------------------------------------------------\n" +
|
||||||
|
request.getRequestURI() + " OUT:" +
|
||||||
|
"\n--------------------------------------------------------------\n" +
|
||||||
|
"jsonResponse.toJSONString():[" + jsonResponse.toJSONString() + "]\n" +
|
||||||
|
"\n--------------------------------------------------------------\n");
|
||||||
|
|
||||||
|
return jsonResponse;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,22 @@
|
||||||
|
package geoinfo.training.home.service;
|
||||||
|
|
||||||
|
import java.sql.SQLException;
|
||||||
|
import java.util.HashMap;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
import egovframework.rte.psl.dataaccess.mapper.Mapper;
|
||||||
|
import egovframework.rte.psl.dataaccess.util.EgovMap;
|
||||||
|
|
||||||
|
@Mapper("homeTrainingMapper")
|
||||||
|
public interface HomeTrainingMapper {
|
||||||
|
public HashMap<String, Object> callSpAddHomeTrainingReq(HashMap<String, Object> params) throws SQLException;
|
||||||
|
public HashMap<String, Object> callSpUdpHomeTrainingReq(HashMap<String, Object> params) throws SQLException;
|
||||||
|
public HashMap<String, Object> callSpCancelHomeTrainingReq(HashMap<String, Object> params) throws SQLException;
|
||||||
|
public List<EgovMap> callSpGetHomeTrainingReg(HashMap<String, Object> params) throws SQLException;
|
||||||
|
public long callSpCntHomeTrainingReg(HashMap<String, Object> params) throws SQLException;
|
||||||
|
//특정 아이디로 특정 집합교육을 신청한 내역이 있는지 조회한다
|
||||||
|
public long getWebHomeTrainingReqCountByWhtRegIdAndUserId(HashMap<String, Object> params) throws SQLException;
|
||||||
|
public List<EgovMap> getWebHomeTrainingReqByWhtRegIdAndUserId(HashMap<String, Object> params) throws SQLException;
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,18 @@
|
||||||
|
package geoinfo.training.home.service;
|
||||||
|
|
||||||
|
import java.util.HashMap;
|
||||||
|
import javax.servlet.http.HttpServletRequest;
|
||||||
|
import javax.servlet.http.HttpServletResponse;
|
||||||
|
|
||||||
|
import org.json.simple.JSONObject;
|
||||||
|
|
||||||
|
public interface HomeTrainingService {
|
||||||
|
|
||||||
|
|
||||||
|
void getHomeTraining(HttpServletRequest request, HttpServletResponse response, JSONObject jsonResponse, HashMap<String, Object> params) throws Exception;
|
||||||
|
|
||||||
|
HashMap<String, Object> attendHomeTraining(HttpServletRequest request, HttpServletResponse response, HashMap<String, Object> params) throws Exception;
|
||||||
|
HashMap<String, Object> updateHomeTraining(HttpServletRequest request, HttpServletResponse response, HashMap<String, Object> params) throws Exception;
|
||||||
|
HashMap<String, Object> cancelHomeTraining(HttpServletRequest request, HttpServletResponse response, HashMap<String, Object> params) throws Exception;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,196 @@
|
||||||
|
package geoinfo.training.home.service.impl;
|
||||||
|
|
||||||
|
import java.math.BigDecimal;
|
||||||
|
import java.sql.SQLException;
|
||||||
|
import java.sql.Timestamp;
|
||||||
|
import java.util.ArrayList;
|
||||||
|
import java.util.HashMap;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
import javax.annotation.Resource;
|
||||||
|
import javax.servlet.http.HttpServletRequest;
|
||||||
|
import javax.servlet.http.HttpServletResponse;
|
||||||
|
|
||||||
|
import org.json.simple.JSONObject;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
|
import egovframework.rte.psl.dataaccess.util.EgovMap;
|
||||||
|
import geoinfo.training.home.service.HomeTrainingMapper;
|
||||||
|
import geoinfo.training.home.service.HomeTrainingService;
|
||||||
|
import geoinfo.util.MyUtil;
|
||||||
|
import oracle.sql.TIMESTAMP;
|
||||||
|
|
||||||
|
|
||||||
|
@Service("homeTrainingService")
|
||||||
|
public class HomeTrainingServiceImpl implements HomeTrainingService {
|
||||||
|
|
||||||
|
@Resource(name="homeTrainingMapper")
|
||||||
|
private HomeTrainingMapper homeTrainingMapper;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void getHomeTraining(HttpServletRequest request, HttpServletResponse response, JSONObject jsonResponse, HashMap<String, Object> params) throws Exception {
|
||||||
|
|
||||||
|
if(request.getSession().getAttribute("USERNAME") == null){
|
||||||
|
throw new Exception( "로그인이 필요한 서비스 입니다." );
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
String userId = (String)request.getSession().getAttribute("USERID");
|
||||||
|
params.put("userId", userId);
|
||||||
|
|
||||||
|
params.put("wvtRegId", null); // 조회할 레코드의 일련번호(숫자)
|
||||||
|
params.put("trainingName", null); // 집합교육명
|
||||||
|
params.put("startDate", null); // 확정된 날짜의 검색 시작일자
|
||||||
|
params.put("endDate", null); // 확정된 날짜의 검색 종료일자
|
||||||
|
params.put("stateCode", null); // 상태 코드
|
||||||
|
params.put("ncount", 100); // 페이지당 한번에 가져올 개수
|
||||||
|
params.put("npage", 0); // 페이지 번호
|
||||||
|
|
||||||
|
try {
|
||||||
|
List<EgovMap> list = homeTrainingMapper.callSpGetHomeTrainingReg(params);
|
||||||
|
|
||||||
|
HashMap<String, Object> webHomeTrainingReqCountParams = new HashMap<String, Object>();
|
||||||
|
|
||||||
|
List<EgovMap> dto = new ArrayList<EgovMap>();
|
||||||
|
for( EgovMap item : list ) {
|
||||||
|
TIMESTAMP oracleTimestamp = (TIMESTAMP) item.get("crtDt");
|
||||||
|
item.put("crtDt", new Timestamp(oracleTimestamp.timestampValue().getTime())); // oracle.sql.TIMESTAMP -> java.sql.Timestamp 변환
|
||||||
|
|
||||||
|
|
||||||
|
//신청 여부를 판단하여 stateCode를 T로 변환한다. A:신청중,D:삭제,C:취소,T:참석
|
||||||
|
webHomeTrainingReqCountParams.put("whtRegId", item.get("whtRegId"));
|
||||||
|
webHomeTrainingReqCountParams.put("userId", userId);
|
||||||
|
long webHomeTrainingReqCount = homeTrainingMapper.getWebHomeTrainingReqCountByWhtRegIdAndUserId(webHomeTrainingReqCountParams);
|
||||||
|
if( 0 < webHomeTrainingReqCount ) {
|
||||||
|
item.put("stateCode", "T");
|
||||||
|
}
|
||||||
|
|
||||||
|
List<EgovMap> webHomeTrainingReqlist = homeTrainingMapper.getWebHomeTrainingReqByWhtRegIdAndUserId(webHomeTrainingReqCountParams);
|
||||||
|
|
||||||
|
for( EgovMap webHomeTrainingReqItem : webHomeTrainingReqlist ) {
|
||||||
|
TIMESTAMP oracleTs = (TIMESTAMP) webHomeTrainingReqItem.get("crtDt");
|
||||||
|
item.put("registryCrtDt", new Timestamp(oracleTs.timestampValue().getTime()));
|
||||||
|
item.put("registryReqPosition", webHomeTrainingReqItem.get("reqPosition"));
|
||||||
|
item.put("registryCompanyName", webHomeTrainingReqItem.get("companyName"));
|
||||||
|
item.put("registryReqDept", webHomeTrainingReqItem.get("reqDept"));
|
||||||
|
item.put("registryReqName", webHomeTrainingReqItem.get("reqName"));
|
||||||
|
item.put("registryReqTel", webHomeTrainingReqItem.get("reqTel"));
|
||||||
|
item.put("registryReqEmail", webHomeTrainingReqItem.get("reqEmail"));
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
dto.add(item);
|
||||||
|
}
|
||||||
|
|
||||||
|
jsonResponse.put("data", dto);
|
||||||
|
long count = homeTrainingMapper.callSpCntHomeTrainingReg(params);
|
||||||
|
jsonResponse.put("count", count);
|
||||||
|
return;
|
||||||
|
} catch (SQLException e) {
|
||||||
|
throw new Exception( e.getMessage() );
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public HashMap<String, Object> attendHomeTraining(HttpServletRequest request, HttpServletResponse response, HashMap<String, Object> params) throws Exception {
|
||||||
|
|
||||||
|
if(request.getSession().getAttribute("USERNAME") == null){
|
||||||
|
throw new Exception( "로그인이 필요한 서비스 입니다." );
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
params.put("reqRemark", null);
|
||||||
|
params.put("personalInfoYn", "Y");
|
||||||
|
String userId = (String)request.getSession().getAttribute("USERID");
|
||||||
|
params.put("userId", userId);
|
||||||
|
|
||||||
|
|
||||||
|
String reqPosition = MyUtil.getStringFromObject( params.get("reqPosition") );
|
||||||
|
if( reqPosition == null ) {
|
||||||
|
throw new Exception( "직급을 입력하십시오." );
|
||||||
|
}
|
||||||
|
|
||||||
|
try {
|
||||||
|
//신청 여부를 판단하여 stateCode를 T로 변환한다. A:신청중,D:삭제,C:취소,T:참석
|
||||||
|
long webHomeTrainingReqCount = homeTrainingMapper.getWebHomeTrainingReqCountByWhtRegIdAndUserId(params);
|
||||||
|
if( 0 < webHomeTrainingReqCount ) {
|
||||||
|
throw new Exception( "참석 신청이 완료된 교육입니다." );
|
||||||
|
}
|
||||||
|
|
||||||
|
homeTrainingMapper.callSpAddHomeTrainingReq(params);
|
||||||
|
return params;
|
||||||
|
} catch (SQLException e) {
|
||||||
|
throw new Exception( e.getMessage() );
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public HashMap<String, Object> updateHomeTraining(HttpServletRequest request, HttpServletResponse response,
|
||||||
|
HashMap<String, Object> params) throws Exception {
|
||||||
|
if(request.getSession().getAttribute("USERNAME") == null){
|
||||||
|
throw new Exception( "로그인이 필요한 서비스 입니다." );
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
params.put("reqRemark", null);
|
||||||
|
params.put("personalInfoYn", "Y");
|
||||||
|
String userId = (String)request.getSession().getAttribute("USERID");
|
||||||
|
params.put("userId", userId);
|
||||||
|
|
||||||
|
Long whtId = null;
|
||||||
|
try {
|
||||||
|
List<EgovMap> list = homeTrainingMapper.getWebHomeTrainingReqByWhtRegIdAndUserId(params);
|
||||||
|
if( list.size() == 0 ) {
|
||||||
|
throw new Exception( "신청한 교육이 존재하지 않습니다." );
|
||||||
|
}
|
||||||
|
for( EgovMap item : list ) {
|
||||||
|
TIMESTAMP oracleTimestamp = (TIMESTAMP) item.get("crtDt");
|
||||||
|
item.put("crtDt", new Timestamp(oracleTimestamp.timestampValue().getTime())); // oracle.sql.TIMESTAMP -> java.sql.Timestamp 변환
|
||||||
|
|
||||||
|
|
||||||
|
whtId = Long.valueOf( ((BigDecimal)item.get("whtId")).longValue() );
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
params.put("whtId", whtId.intValue());
|
||||||
|
homeTrainingMapper.callSpUdpHomeTrainingReq(params);
|
||||||
|
return params;
|
||||||
|
} catch (SQLException e) {
|
||||||
|
throw new Exception( e.getMessage() );
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public HashMap<String, Object> cancelHomeTraining(HttpServletRequest request, HttpServletResponse response,
|
||||||
|
HashMap<String, Object> params) throws Exception {
|
||||||
|
if(request.getSession().getAttribute("USERNAME") == null){
|
||||||
|
throw new Exception( "로그인이 필요한 서비스 입니다." );
|
||||||
|
}
|
||||||
|
|
||||||
|
String userId = (String)request.getSession().getAttribute("USERID");
|
||||||
|
params.put("userId", userId);
|
||||||
|
|
||||||
|
try {
|
||||||
|
long webHomeTrainingReqCount = homeTrainingMapper.getWebHomeTrainingReqCountByWhtRegIdAndUserId(params);
|
||||||
|
if( webHomeTrainingReqCount == 0 ) {
|
||||||
|
throw new Exception( "교육 참석 취소 대상이 존재하지 않습니다." );
|
||||||
|
}
|
||||||
|
homeTrainingMapper.callSpCancelHomeTrainingReq(params);
|
||||||
|
return params;
|
||||||
|
} catch (SQLException e) {
|
||||||
|
throw new Exception( e.getMessage() );
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
@ -23,7 +23,10 @@
|
||||||
SELECT AGREEYN, USERID, PASSWD, CLS, USER_NAME, SYSDATE, LOGIN_COUNT, LAST_LOGIN_DATE + 1/(24*12) AS SYSDATE2, VIRTUALNO,
|
SELECT AGREEYN, USERID, PASSWD, CLS, USER_NAME, SYSDATE, LOGIN_COUNT, LAST_LOGIN_DATE + 1/(24*12) AS SYSDATE2, VIRTUALNO,
|
||||||
DECODE(PROJECT_MASTER_COMPANY_CODE,'','0',PROJECT_MASTER_COMPANY_CODE) MASTER_COMPANY_CODE,
|
DECODE(PROJECT_MASTER_COMPANY_CODE,'','0',PROJECT_MASTER_COMPANY_CODE) MASTER_COMPANY_CODE,
|
||||||
to_char(trunc(months_between(SYSDATE, PSWD_MONTH))) as PSWD_LIMIT, LIQ_YN, GOVEMENT_CODE, CERTIFICATION_YN,
|
to_char(trunc(months_between(SYSDATE, PSWD_MONTH))) as PSWD_LIMIT, LIQ_YN, GOVEMENT_CODE, CERTIFICATION_YN,
|
||||||
COMPANY_NAME
|
COMPANY_NAME,
|
||||||
|
PART_NAME,
|
||||||
|
PHONE,
|
||||||
|
EMAIL
|
||||||
FROM WEB_MEMBER_IN
|
FROM WEB_MEMBER_IN
|
||||||
WHERE
|
WHERE
|
||||||
<if test="userid != null">
|
<if test="userid != null">
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,100 @@
|
||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||||
|
|
||||||
|
<mapper namespace="geoinfo.training.home.service.HomeTrainingMapper">
|
||||||
|
|
||||||
|
|
||||||
|
<resultMap id="spAddHomeTrainingReqResult" type="java.util.HashMap">
|
||||||
|
<result property="whtId" column="P_WHT_ID" jdbcType="INTEGER"/>
|
||||||
|
<result property="resultCode" column="P_RESULT_CODE" jdbcType="VARCHAR"/>
|
||||||
|
<result property="errMsg" column="P_ERR_MSG" jdbcType="VARCHAR"/>
|
||||||
|
</resultMap>
|
||||||
|
|
||||||
|
<select id="callSpAddHomeTrainingReq" statementType="CALLABLE" parameterType="map" resultMap="spAddHomeTrainingReqResult">
|
||||||
|
CALL SP_ADD_HOME_TRAINING_REQ(
|
||||||
|
#{whtRegId, jdbcType=INTEGER, mode=IN},
|
||||||
|
#{companyName, jdbcType=VARCHAR, mode=IN},
|
||||||
|
#{reqDept, jdbcType=VARCHAR, mode=IN},
|
||||||
|
#{reqPosition, jdbcType=VARCHAR, mode=IN},
|
||||||
|
#{reqName, jdbcType=VARCHAR, mode=IN},
|
||||||
|
#{reqTel, jdbcType=VARCHAR, mode=IN},
|
||||||
|
#{reqEmail, jdbcType=VARCHAR, mode=IN},
|
||||||
|
#{reqRemark, jdbcType=VARCHAR, mode=IN},
|
||||||
|
#{personalInfoYn, jdbcType=CHAR, mode=IN},
|
||||||
|
#{userId, jdbcType=VARCHAR, mode=IN},
|
||||||
|
#{whtId, jdbcType=INTEGER, mode=OUT},
|
||||||
|
#{resultCode, jdbcType=VARCHAR, mode=OUT},
|
||||||
|
#{errMsg, jdbcType=VARCHAR, mode=OUT}
|
||||||
|
)
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="callSpGetHomeTrainingReg" parameterType="map" resultType="egovMap">
|
||||||
|
<![CDATA[
|
||||||
|
select * FROM TABLE(SP_GET_HOME_TRAINING_REG(#{wvtRegId},#{trainingName},#{startDate},#{endDate},#{stateCode},#{ncount},#{npage}))
|
||||||
|
]]>
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="callSpCntHomeTrainingReg" parameterType="map" resultType="long">
|
||||||
|
select SP_CNT_HOME_TRAINING_REG(#{wvtRegId},#{trainingName},#{startDate},#{endDate},#{stateCode}) from DUAL
|
||||||
|
</select>
|
||||||
|
|
||||||
|
|
||||||
|
<!-- 특정 아이디로 특정 집합교육을 신청한 내역이 있는지 조회한다 -->
|
||||||
|
<select id="getWebHomeTrainingReqCountByWhtRegIdAndUserId" parameterType="map" resultType="long">
|
||||||
|
<![CDATA[
|
||||||
|
SELECT count(1)
|
||||||
|
FROM WEB_HOME_TRAINING_REQ whtr
|
||||||
|
WHERE whtr.WHT_REG_ID = #{whtRegId} AND whtr.CRT_USERID = #{userId}
|
||||||
|
]]>
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="getWebHomeTrainingReqByWhtRegIdAndUserId" parameterType="map" resultType="egovMap">
|
||||||
|
<![CDATA[
|
||||||
|
SELECT *
|
||||||
|
FROM WEB_HOME_TRAINING_REQ whtr
|
||||||
|
WHERE whtr.WHT_REG_ID = #{whtRegId} AND whtr.CRT_USERID = #{userId}
|
||||||
|
]]>
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<!-- 집합 교육 신청 수정 기능(개인 사용자용) -->
|
||||||
|
<resultMap id="spUdpHomeTrainingReqResult" type="java.util.HashMap">
|
||||||
|
<result property="resultCode" column="P_RESULT_CODE" jdbcType="VARCHAR"/>
|
||||||
|
<result property="errMsg" column="P_ERR_MSG" jdbcType="VARCHAR"/>
|
||||||
|
</resultMap>
|
||||||
|
|
||||||
|
<select id="callSpUdpHomeTrainingReq" statementType="CALLABLE" parameterType="map" resultMap="spUdpHomeTrainingReqResult">
|
||||||
|
CALL SP_UDT_HOME_TRAINING_REQ(
|
||||||
|
#{whtId, jdbcType=INTEGER, mode=IN},
|
||||||
|
#{whtRegId, jdbcType=INTEGER, mode=IN},
|
||||||
|
#{companyName, jdbcType=VARCHAR, mode=IN},
|
||||||
|
#{reqDept, jdbcType=VARCHAR, mode=IN},
|
||||||
|
#{reqPosition, jdbcType=VARCHAR, mode=IN},
|
||||||
|
#{reqName, jdbcType=VARCHAR, mode=IN},
|
||||||
|
#{reqTel, jdbcType=VARCHAR, mode=IN},
|
||||||
|
#{reqEmail, jdbcType=VARCHAR, mode=IN},
|
||||||
|
#{reqRemark, jdbcType=VARCHAR, mode=IN},
|
||||||
|
#{personalInfoYn, jdbcType=CHAR, mode=IN},
|
||||||
|
#{userId, jdbcType=VARCHAR, mode=IN},
|
||||||
|
#{resultCode, jdbcType=VARCHAR, mode=OUT},
|
||||||
|
#{errMsg, jdbcType=VARCHAR, mode=OUT}
|
||||||
|
)
|
||||||
|
</select>
|
||||||
|
|
||||||
|
|
||||||
|
<!-- 집합 교육 신청 취소 기능(개인 사용자용) -->
|
||||||
|
<resultMap id="spCancelHomeTrainingReqResult" type="java.util.HashMap">
|
||||||
|
<result property="resultCode" column="P_RESULT_CODE" jdbcType="VARCHAR"/>
|
||||||
|
<result property="errMsg" column="P_ERR_MSG" jdbcType="VARCHAR"/>
|
||||||
|
</resultMap>
|
||||||
|
|
||||||
|
<select id="callSpCancelHomeTrainingReq" statementType="CALLABLE" parameterType="map" resultMap="spCancelHomeTrainingReqResult">
|
||||||
|
CALL SP_CANCEL_HOME_TRAINING_REQ(
|
||||||
|
#{whtRegId, jdbcType=INTEGER, mode=IN},
|
||||||
|
#{userId, jdbcType=VARCHAR, mode=IN},
|
||||||
|
#{resultCode, jdbcType=VARCHAR, mode=OUT},
|
||||||
|
#{errMsg, jdbcType=VARCHAR, mode=OUT}
|
||||||
|
)
|
||||||
|
</select>
|
||||||
|
|
||||||
|
|
||||||
|
</mapper>
|
||||||
|
|
@ -3,53 +3,458 @@
|
||||||
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
|
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
|
||||||
<%@ taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions" %>
|
<%@ taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions" %>
|
||||||
<script type="text/javascript" >
|
<script type="text/javascript" >
|
||||||
function doSave(){
|
|
||||||
var name = document.jusangdoForm.name.value;
|
let xhr;
|
||||||
var data = document.jusangdoForm.data.value;
|
if(window.XMLHttpRequest) {
|
||||||
if(confirm('주상도를 만드시겠습니까?')) {
|
xhr = new XMLHttpRequest();
|
||||||
var jusangdo = window.open("/ClipReport4/export/exportForPDF_Jusangdo_Server.jsp?name=" +name + "&data=" +data, "jusangdo", "directories=no,toolbar=no");
|
} else {
|
||||||
|
// IE5, IE6 일때
|
||||||
|
xhr = new ActiveXObject("Microsoft.XMLHTTP");
|
||||||
|
}
|
||||||
|
|
||||||
|
function ScrollStop() {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
function ScrollStart() {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
function unixTimestampToFormattedDate(unixTimestamp) {
|
||||||
|
const date = new Date(unixTimestamp);
|
||||||
|
|
||||||
|
const year = date.getFullYear();
|
||||||
|
const month = ('0' + (date.getMonth() + 1)).slice(-2); // 월은 0부터 시작하므로 1을 더하고, 두 자리로 만들기 위해 0을 앞에 붙인 후 마지막 두 자리만 취함
|
||||||
|
const day = ('0' + date.getDate()).slice(-2); // 일도 두 자리로 만들기 위해 0을 앞에 붙인 후 마지막 두 자리만 취함
|
||||||
|
|
||||||
|
const daysOfWeek = ['일', '월', '화', '수', '목', '금', '토'];
|
||||||
|
const dayOfWeek = daysOfWeek[date.getDay()];
|
||||||
|
|
||||||
|
return year + '-' + month + '-' + day + '(' + dayOfWeek + ')';
|
||||||
|
}
|
||||||
|
|
||||||
|
function setDisplayEle(EleId, display) {
|
||||||
|
var myEle = document.getElementById(EleId);
|
||||||
|
if (myEle) {
|
||||||
|
myEle.style.display = display;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
function doSave2(){
|
function onClickOpenPopupLink(e) {
|
||||||
var name = document.jusangdoForm.name.value;
|
let dataSeq = e.getAttribute('data-seq');
|
||||||
var data = document.jusangdoForm.data.value;
|
if( dataSeq ) {
|
||||||
if(confirm('주상도를 만드시겠습니까?')) {
|
dataSeq = Number(dataSeq);
|
||||||
var jusangdo = window.open("/ClipReport4/export/exportForPDF_Jusangdo_Server2.jsp?name=" +name + "&data=" +data, "jusangdo", "directories=no,toolbar=no");
|
}
|
||||||
|
|
||||||
|
|
||||||
|
let dataMode = e.getAttribute('data-mode');
|
||||||
|
if( dataMode ) {
|
||||||
|
dataMode = String(dataMode);
|
||||||
|
|
||||||
|
if( dataMode === "registration" ){
|
||||||
|
setDisplayEle('apply-button', 'inline-block');
|
||||||
|
setDisplayEle('modification-button', 'none');
|
||||||
|
setDisplayEle('apply-cancel-button', 'none');
|
||||||
|
} else if( dataMode === "modification" ){
|
||||||
|
setDisplayEle('apply-button', 'none');
|
||||||
|
setDisplayEle('modification-button', 'inline-block');
|
||||||
|
setDisplayEle('apply-cancel-button', 'inline-block');
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
let dataRegistryReqPosition = e.getAttribute('data-registry-req-position');
|
||||||
|
if (dataRegistryReqPosition) {
|
||||||
|
var reqPositionEle = document.getElementById('req-position');
|
||||||
|
if (reqPositionEle) {
|
||||||
|
reqPositionEle.value = dataRegistryReqPosition;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
/*
|
||||||
|
|
||||||
|
item.put("registryCompanyName
|
||||||
|
item.put("registryReqDept
|
||||||
|
item.put("registryReqName
|
||||||
|
item.put("registryReqTel
|
||||||
|
item.put("registryReqEmail
|
||||||
|
*/
|
||||||
|
|
||||||
|
|
||||||
|
var whtRegIdEle = document.getElementById('wht-reg-id');
|
||||||
|
if (whtRegIdEle) {
|
||||||
|
whtRegIdEle.value = dataSeq;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
function getButtonHTML(item) {
|
||||||
|
|
||||||
|
if( item.stateCode === 'F' ) {
|
||||||
|
// 마감
|
||||||
|
return '<button type="button" class="closed-button" data-seq="' + item.whtRegId + '">마감</button>';
|
||||||
|
} else if( item.stateCode === 'A' ) {
|
||||||
|
// 신청
|
||||||
|
return '<a href="#request-button" class="request-button open-popup-link" data-seq="' + item.whtRegId + '" data-mode="registration" onClick="onClickOpenPopupLink(this)">신청</a>';
|
||||||
|
} else if( item.stateCode === 'P' ) {
|
||||||
|
// 예정
|
||||||
|
return '<button type="button" class="deadline-button" disabled="disabled" data-seq="' + item.whtRegId + '">예정</button>';
|
||||||
|
} else if( item.stateCode === 'T' ) {
|
||||||
|
// 이미 신청이 완료된 교육
|
||||||
|
return '<a href="#request-button" class="approved-button open-popup-link" data-seq="' + item.whtRegId + '" data-mode="modification" onClick="onClickOpenPopupLink(this)" data-registry-crt-dt="' + item.registryCrtDt + '" data-registry-req-position="' + item.registryReqPosition + '">수정</a>';
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
function updateList() {
|
||||||
|
xhr.open('GET', 'training/home/list.do', true);
|
||||||
|
xhr.setRequestHeader('Content-type', 'application/json');
|
||||||
|
|
||||||
|
xhr.onreadystatechange = function() {
|
||||||
|
if (xhr.readyState === 4 && xhr.status === 200) {
|
||||||
|
// 요청 성공 시 처리
|
||||||
|
const obj = JSON.parse(xhr.responseText);
|
||||||
|
const data = obj.data;
|
||||||
|
|
||||||
|
const homeVisitListEle = document.getElementById('home-visit-list');
|
||||||
|
let homeVisitListHTML = '';
|
||||||
|
for( idx in data ) {
|
||||||
|
|
||||||
|
homeVisitListHTML +=
|
||||||
|
`
|
||||||
|
<tr>
|
||||||
|
<td>` + data[idx].whtRegId + `</td>
|
||||||
|
<td>` + data[idx].trainingName + `</td>
|
||||||
|
<td>` + unixTimestampToFormattedDate(data[idx].trainingDatetime) + `</td>
|
||||||
|
<td>` + data[idx].trainingLocation + `</td>
|
||||||
|
<td>` + unixTimestampToFormattedDate(data[idx].regStartDate) + `~` + unixTimestampToFormattedDate(data[idx].regEndDate) + `</td>
|
||||||
|
<td>` + getButtonHTML(data[idx]) + `</td>
|
||||||
|
</tr>
|
||||||
|
`;
|
||||||
|
}
|
||||||
|
if( data.length === 0 ) {
|
||||||
|
homeVisitListHTML =
|
||||||
|
`
|
||||||
|
<tr>
|
||||||
|
<td calspan='6'>등록된 집합교육이 없습니다.</td>
|
||||||
|
</tr>
|
||||||
|
`;
|
||||||
|
}
|
||||||
|
homeVisitListEle.innerHTML = homeVisitListHTML;
|
||||||
|
|
||||||
|
$('.open-popup-link').magnificPopup({
|
||||||
|
mainClass: 'mfp-fade',
|
||||||
|
closeOnBgClick: false,
|
||||||
|
preloader: false,
|
||||||
|
fixedContentPos: false,
|
||||||
|
closeBtnInside: true,
|
||||||
|
showCloseBtn: true,
|
||||||
|
items: {
|
||||||
|
src: '#input-data'
|
||||||
|
},
|
||||||
|
callbacks: {
|
||||||
|
open: function () {
|
||||||
|
$('#input-data').parent().addClass('input-data-modal-content');
|
||||||
|
if (!isMobile) {
|
||||||
|
$('body').addClass('overflow-hidden login-popup-wrapper');
|
||||||
|
} else {
|
||||||
|
$('body, html').on('touchmove', function (e) {
|
||||||
|
e.preventDefault();
|
||||||
|
});
|
||||||
|
}
|
||||||
|
},
|
||||||
|
close: function () {
|
||||||
|
if (!isMobile) {
|
||||||
|
$('body').removeClass('overflow-hidden login-popup-wrapper');
|
||||||
|
document.onmousewheel = ScrollStart;
|
||||||
|
} else {
|
||||||
|
$('body, html').unbind('touchmove');
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
} else if (xhr.readyState === 4) {
|
||||||
|
// 요청 실패 시 처리
|
||||||
|
console.error('요청 실패:', xhr.status);
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
xhr.send();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
document.addEventListener('DOMContentLoaded', function () {
|
||||||
|
|
||||||
|
|
||||||
|
const rows = document.querySelectorAll('#Table_contents tbody tr td:nth-child(7)');
|
||||||
|
|
||||||
|
rows.forEach(function (cell) {
|
||||||
|
|
||||||
|
const text = cell.textContent;
|
||||||
|
const number = parseInt(text.match(/\d+/));
|
||||||
|
|
||||||
|
if (number >= 100) {
|
||||||
|
cell.style.color = 'red';
|
||||||
|
} else {
|
||||||
|
cell.style.color = 'blue';
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
|
||||||
|
const requestRegistryButtonEle = document.getElementById('apply-button');
|
||||||
|
if( requestRegistryButtonEle ) {
|
||||||
|
requestRegistryButtonEle.addEventListener('click', function (e) {
|
||||||
|
|
||||||
|
var dataIndexValue;
|
||||||
|
|
||||||
|
var jsonData = new Array();
|
||||||
|
for (var i = 0; i < 1 ; i++) { // 여러 개를 한 번에 입력받는다면 입력받는 레코드만큼 loop를 순환하도록 수정되어야 한다.
|
||||||
|
var jsonItem = {};
|
||||||
|
//dataIndexValue = tableDataElements[i].getAttribute('data-index');
|
||||||
|
// 집합교육 일련번호
|
||||||
|
var whtRegIdEle = document.getElementById('wht-reg-id');
|
||||||
|
if (whtRegIdEle) {
|
||||||
|
jsonItem.whtRegId = Number(whtRegIdEle.value);
|
||||||
|
}
|
||||||
|
// 성명
|
||||||
|
var reqNameEle = document.getElementById('req-name');
|
||||||
|
if (reqNameEle) {
|
||||||
|
jsonItem.reqName = reqNameEle.value;
|
||||||
|
}
|
||||||
|
// 기관명
|
||||||
|
var companyNameEle = document.getElementById('company-name');
|
||||||
|
if (companyNameEle) {
|
||||||
|
jsonItem.companyName = companyNameEle.value;
|
||||||
|
}
|
||||||
|
// 부서명
|
||||||
|
var reqDeptEle = document.getElementById('req-dept');
|
||||||
|
if (reqDeptEle) {
|
||||||
|
jsonItem.reqDept = reqDeptEle.value;
|
||||||
|
}
|
||||||
|
// 직급
|
||||||
|
var reqPositionEle = document.getElementById('req-position');
|
||||||
|
if (reqPositionEle) {
|
||||||
|
jsonItem.reqPosition = reqPositionEle.value;
|
||||||
|
}
|
||||||
|
// 연락처
|
||||||
|
var reqTelEle = document.getElementById('req-tel');
|
||||||
|
if (reqTelEle) {
|
||||||
|
jsonItem.reqTel = reqTelEle.value;
|
||||||
|
}
|
||||||
|
// 이메일
|
||||||
|
var reqEmailEle = document.getElementById('req-email');
|
||||||
|
if (reqEmailEle) {
|
||||||
|
jsonItem.reqEmail = reqEmailEle.value;
|
||||||
|
}
|
||||||
|
jsonData.push(jsonItem);
|
||||||
|
}
|
||||||
|
|
||||||
|
console.log('%o', jsonData);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
xhr.open('POST', 'training/home/attend.do', true);
|
||||||
|
xhr.setRequestHeader('Content-type', 'application/json');
|
||||||
|
|
||||||
|
xhr.onreadystatechange = function() {
|
||||||
|
if (xhr.readyState === 4 && xhr.status === 200) {
|
||||||
|
// 요청 성공 시 처리
|
||||||
|
console.log(xhr.responseText);
|
||||||
|
const obj = JSON.parse(xhr.responseText);
|
||||||
|
updateList();
|
||||||
|
alert(obj.message);
|
||||||
|
if( obj.resultCode === 401 ) {
|
||||||
|
window.location.href="./";
|
||||||
|
}
|
||||||
|
} else if (xhr.readyState === 4) {
|
||||||
|
// 요청 실패 시 처리
|
||||||
|
console.error('요청 실패:', xhr.status);
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
xhr.send(JSON.stringify(jsonData));
|
||||||
|
});
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
const modificationButtonEle = document.getElementById('modification-button');
|
||||||
|
if( modificationButtonEle ) {
|
||||||
|
modificationButtonEle.addEventListener('click', function (e) {
|
||||||
|
|
||||||
|
var jsonData = new Array();
|
||||||
|
for (var i = 0; i < 1 ; i++) {
|
||||||
|
var jsonItem = {};
|
||||||
|
|
||||||
|
// 집합교육 일련번호
|
||||||
|
var whtRegIdEle = document.getElementById('wht-reg-id');
|
||||||
|
if (whtRegIdEle) {
|
||||||
|
jsonItem.whtRegId = Number(whtRegIdEle.value);
|
||||||
|
}
|
||||||
|
// 성명
|
||||||
|
var reqNameEle = document.getElementById('req-name');
|
||||||
|
if (reqNameEle) {
|
||||||
|
jsonItem.reqName = reqNameEle.value;
|
||||||
|
}
|
||||||
|
// 기관명
|
||||||
|
var companyNameEle = document.getElementById('company-name');
|
||||||
|
if (companyNameEle) {
|
||||||
|
jsonItem.companyName = companyNameEle.value;
|
||||||
|
}
|
||||||
|
// 부서명
|
||||||
|
var reqDeptEle = document.getElementById('req-dept');
|
||||||
|
if (reqDeptEle) {
|
||||||
|
jsonItem.reqDept = reqDeptEle.value;
|
||||||
|
}
|
||||||
|
// 직급
|
||||||
|
var reqPositionEle = document.getElementById('req-position');
|
||||||
|
if (reqPositionEle) {
|
||||||
|
jsonItem.reqPosition = reqPositionEle.value;
|
||||||
|
}
|
||||||
|
// 연락처
|
||||||
|
var reqTelEle = document.getElementById('req-tel');
|
||||||
|
if (reqTelEle) {
|
||||||
|
jsonItem.reqTel = reqTelEle.value;
|
||||||
|
}
|
||||||
|
// 이메일
|
||||||
|
var reqEmailEle = document.getElementById('req-email');
|
||||||
|
if (reqEmailEle) {
|
||||||
|
jsonItem.reqEmail = reqEmailEle.value;
|
||||||
|
}
|
||||||
|
jsonData.push(jsonItem);
|
||||||
|
}
|
||||||
|
|
||||||
|
console.log('%o', jsonData);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
xhr.open('POST', 'training/home/update.do', true);
|
||||||
|
xhr.setRequestHeader('Content-type', 'application/json');
|
||||||
|
|
||||||
|
xhr.onreadystatechange = function() {
|
||||||
|
if (xhr.readyState === 4 && xhr.status === 200) {
|
||||||
|
// 요청 성공 시 처리
|
||||||
|
console.log(xhr.responseText);
|
||||||
|
const obj = JSON.parse(xhr.responseText);
|
||||||
|
updateList();
|
||||||
|
alert(obj.message);
|
||||||
|
if( obj.resultCode === 401 ) {
|
||||||
|
window.location.href="./";
|
||||||
|
}
|
||||||
|
} else if (xhr.readyState === 4) {
|
||||||
|
// 요청 실패 시 처리
|
||||||
|
console.error('요청 실패:', xhr.status);
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
xhr.send(JSON.stringify(jsonData));
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
const cancelButtonEle = document.getElementById('apply-cancel-button');
|
||||||
|
if( cancelButtonEle ) {
|
||||||
|
cancelButtonEle.addEventListener('click', function (e) {
|
||||||
|
|
||||||
|
var jsonData = new Array();
|
||||||
|
for (var i = 0; i < 1 ; i++) { // 여러 개를 한 번에 입력받는다면 입력받는 레코드만큼 loop를 순환하도록 수정되어야 한다.
|
||||||
|
var jsonItem = {};
|
||||||
|
// 집합교육 일련번호
|
||||||
|
var whtRegIdEle = document.getElementById('wht-reg-id');
|
||||||
|
if (whtRegIdEle) {
|
||||||
|
jsonItem.whtRegId = Number(whtRegIdEle.value);
|
||||||
|
}
|
||||||
|
jsonData.push(jsonItem);
|
||||||
|
}
|
||||||
|
|
||||||
|
console.log('%o', jsonData);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
xhr.open('POST', 'training/home/cancel.do', true);
|
||||||
|
xhr.setRequestHeader('Content-type', 'application/json');
|
||||||
|
|
||||||
|
xhr.onreadystatechange = function() {
|
||||||
|
if (xhr.readyState === 4 && xhr.status === 200) {
|
||||||
|
// 요청 성공 시 처리
|
||||||
|
console.log(xhr.responseText);
|
||||||
|
const obj = JSON.parse(xhr.responseText);
|
||||||
|
updateList();
|
||||||
|
alert(obj.message);
|
||||||
|
if( obj.resultCode === 401 ) {
|
||||||
|
window.location.href="./";
|
||||||
|
}
|
||||||
|
} else if (xhr.readyState === 4) {
|
||||||
|
// 요청 실패 시 처리
|
||||||
|
console.error('요청 실패:', xhr.status);
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
xhr.send(JSON.stringify(jsonData));
|
||||||
|
});
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
updateList();
|
||||||
|
});
|
||||||
|
|
||||||
|
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style>
|
|
||||||
table {
|
|
||||||
border-collapse: collapse; /* 셀 간격 없애기 */
|
|
||||||
width: 100%;
|
|
||||||
max-width: 600px; /* 최대 너비 설정 */
|
|
||||||
margin: 20px auto; /* 가운데 정렬 */
|
|
||||||
font-family: Arial, sans-serif;
|
|
||||||
}
|
|
||||||
|
|
||||||
th, td {
|
|
||||||
text-align: left;
|
|
||||||
padding: 12px;
|
|
||||||
border: 1px solid #ddd;
|
|
||||||
}
|
|
||||||
|
|
||||||
th {
|
|
||||||
background-color: #f2f2f2;
|
|
||||||
}
|
|
||||||
|
|
||||||
tr:nth-child(even) {
|
|
||||||
background-color: #f9f9f9; /* 짝수 행 배경색 */
|
|
||||||
}
|
|
||||||
|
|
||||||
tr:hover {
|
|
||||||
background-color: #f5f5f5; /* 호버 효과 */
|
|
||||||
}
|
|
||||||
</style>
|
|
||||||
|
|
||||||
<form name="jusangdoForm" method="post">
|
<form name="jusangdoForm" method="post">
|
||||||
<!-- 그리드 시작 -->
|
<!-- 그리드 시작 -->
|
||||||
<div class="contents-row visit-education-application">
|
<div class="contents-row home-education-application-inquiry">
|
||||||
|
<div class="" style="width: 1020px; position: relative;">
|
||||||
|
<table class="Table_Main" id="Table_contents">
|
||||||
|
<colgroup>
|
||||||
|
<col style="width:40px;">
|
||||||
|
<col style="width:235px;">
|
||||||
|
<col style="width:180px;">
|
||||||
|
<col style="width:215px;">
|
||||||
|
<col style="width:280px;">
|
||||||
|
<col style="width:70px;">
|
||||||
|
</colgroup>
|
||||||
|
<thead class="Table_List">
|
||||||
|
<tr>
|
||||||
|
<th>번호</th>
|
||||||
|
<th>집합교육명</th>
|
||||||
|
<th>교육일시</th>
|
||||||
|
<th>교육장소</th>
|
||||||
|
<th>접수기간</th>
|
||||||
|
<th>신청</th>
|
||||||
|
</tr>
|
||||||
|
</thead>
|
||||||
|
<tbody id="home-visit-list">
|
||||||
|
</tbody>
|
||||||
|
<!--
|
||||||
|
|
||||||
|
<tr>
|
||||||
|
<td>3</td>
|
||||||
|
<td>24 제2차 국토지반정보 집합교육</td>
|
||||||
|
<td>2024-10-23(수) 14:00</td>
|
||||||
|
<td>한국건설기술연구원</td>
|
||||||
|
<td>2024-09-23(월) ~ 2024-10-18(금)</td>
|
||||||
|
<td><button type="button" class="edit-button">수정</button></td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td>2</td>
|
||||||
|
<td>24 제2차 국토지반정보 집합교육</td>
|
||||||
|
<td>2024-10-23(수) 14:00</td>
|
||||||
|
<td>한국건설기술연구원</td>
|
||||||
|
<td>2024-09-23(월) ~ 2024-10-18(금)</td>
|
||||||
|
<td><button type="button" class="request-button">신청</button></td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td>1</td>
|
||||||
|
<td>24 제2차 국토지반정보 집합교육</td>
|
||||||
|
<td>2024-10-23(수) 14:00</td>
|
||||||
|
<td>한국건설기술연구원</td>
|
||||||
|
<td>2024-09-23(월) ~ 2024-10-18(금)</td>
|
||||||
|
<td><button type="button" class="deadline-button" disabled="disabled">마감</button></td>
|
||||||
|
</tr>
|
||||||
|
-->
|
||||||
|
</table>
|
||||||
|
</div>
|
||||||
|
<!--
|
||||||
<div>
|
<div>
|
||||||
<table>
|
<table>
|
||||||
<tr>
|
<tr>
|
||||||
|
|
@ -80,7 +485,58 @@ function doSave2(){
|
||||||
</tr>
|
</tr>
|
||||||
</table>
|
</table>
|
||||||
</div>
|
</div>
|
||||||
|
-->
|
||||||
</div>
|
</div>
|
||||||
<!-- 그리드 끝 -->
|
<!-- 그리드 끝 -->
|
||||||
|
|
||||||
|
|
||||||
|
<!-- 입력 및 수정 modal 시작 -->
|
||||||
|
<div id="input-data" class="input-data-modal mfp-hide">
|
||||||
|
<button id="mfp-close" class="mfp-close">X</button>
|
||||||
|
<div class="input-data-modal-content">
|
||||||
|
<div class="input-data-modal-title" >집합교육 신청 내용 작성</div>
|
||||||
|
<div class="input-data-modal-body">
|
||||||
|
<table class="input-data-modal-table" id="input-data-modal-table">
|
||||||
|
<colgroup>
|
||||||
|
<col style="width:100px;">
|
||||||
|
<col style="width:150px;">
|
||||||
|
<col style="width:180px;">
|
||||||
|
<col style="width:155px;">
|
||||||
|
<col style="width:150px;">
|
||||||
|
<col style="width:200px;">
|
||||||
|
</colgroup>
|
||||||
|
<thead class="input-data-modal-thead">
|
||||||
|
<tr>
|
||||||
|
<th>신청자</th>
|
||||||
|
<th>소속기관</th>
|
||||||
|
<th>부서</th>
|
||||||
|
<th>직급</th>
|
||||||
|
<th>연락처</th>
|
||||||
|
<th>이메일</th>
|
||||||
|
</tr>
|
||||||
|
</thead>
|
||||||
|
<tbody class="input-data-modal-tbody" id="input-data-modal-tbody">
|
||||||
|
<tr>
|
||||||
|
<td><input type="hidden" id="wht-reg-id" name="wht-reg-id" class="wht-reg-id" alt="집합교육 일련번호" /><input type="hidden" id="mode" name="mode" class="mode" alt="data-mode 신청 or 수정" /><input type="text" id="req-name" name="req-name" class="req-name" value="${username}" alt="성명"/></td>
|
||||||
|
<td><input type="text" id="company-name" name="company-name" class="company-name" value="${companyname}" alt="기관명"/></td>
|
||||||
|
<td><input type="text" id="req-dept" name="req-dept" class="req-dept" value="${partname}" alt="부서명" /></td>
|
||||||
|
<td><input type="text" id="req-position" name="req-position" class="req-position" value="" alt="직급" /></td>
|
||||||
|
<td><input type="text" id="req-tel" name="req-tel" class="req-tel" value="${phone}" alt="연락처"/></td>
|
||||||
|
<td><input type="text" id="req-email" name="req-email" class="req-email" value="${email}" alt="이메일" /></td>
|
||||||
|
</tr>
|
||||||
|
</tbody>
|
||||||
|
</table>
|
||||||
|
</div>
|
||||||
|
<div class="input-data-modal-tail">
|
||||||
|
<div class="buttons">
|
||||||
|
<button type="button" class="apply-button" id="apply-button">신청하기</button>
|
||||||
|
|
||||||
|
<button type="button" class="modification-button" id="modification-button">수정하기</button>
|
||||||
|
|
||||||
|
<button type="button" class="apply-cancel-button" id="apply-cancel-button">신청 취소하기</button>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
</form>
|
</form>
|
||||||
|
|
|
||||||
|
|
@ -3768,6 +3768,129 @@ ul.faq-q > li textarea {
|
||||||
height: 26px;
|
height: 26px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* ====================================== */
|
||||||
|
/* ====================================== */
|
||||||
|
/* ====================================== */
|
||||||
|
/* ====================================== */
|
||||||
|
.home-education-application-inquiry {
|
||||||
|
/* 신청인정보 */
|
||||||
|
}
|
||||||
|
.home-education-application-inquiry th,
|
||||||
|
.home-education-application-inquiry tr {
|
||||||
|
height: 36px;
|
||||||
|
}
|
||||||
|
.home-education-application-inquiry button {
|
||||||
|
background-color: #007BFF;
|
||||||
|
color: #fff;
|
||||||
|
border-radius: 6px;
|
||||||
|
border: none;
|
||||||
|
padding: 5px 10px;
|
||||||
|
}
|
||||||
|
.home-education-application-inquiry button.edit-button {
|
||||||
|
background-color: #00a999;
|
||||||
|
}
|
||||||
|
.home-education-application-inquiry button.edit-button:hover {
|
||||||
|
background-color: #008979;
|
||||||
|
}
|
||||||
|
.home-education-application-inquiry button.deadline-button {
|
||||||
|
background-color: #e1e1e1;
|
||||||
|
cursor: not-allowed;
|
||||||
|
}
|
||||||
|
.home-education-application-inquiry button.deadline-button:hover {
|
||||||
|
background-color: #888888;
|
||||||
|
}
|
||||||
|
.home-education-application-inquiry button.closed-button {
|
||||||
|
background-color: #ed2227;
|
||||||
|
cursor: not-allowed;
|
||||||
|
}
|
||||||
|
.home-education-application-inquiry button.closed-button:hover {
|
||||||
|
background-color: #ad2227;
|
||||||
|
}
|
||||||
|
.home-education-application-inquiry a {
|
||||||
|
background-color: #007BFF;
|
||||||
|
color: #fff;
|
||||||
|
border-radius: 6px;
|
||||||
|
border: none;
|
||||||
|
padding: 5px 10px;
|
||||||
|
}
|
||||||
|
.home-education-application-inquiry a.request-button {
|
||||||
|
background-color: #007BFF;
|
||||||
|
}
|
||||||
|
.home-education-application-inquiry a.request-button:hover {
|
||||||
|
background-color: #006BeF;
|
||||||
|
}
|
||||||
|
.home-education-application-inquiry a.approved-button {
|
||||||
|
background-color: #00a999;
|
||||||
|
}
|
||||||
|
.home-education-application-inquiry a.approved-button:hover {
|
||||||
|
background-color: #009979;
|
||||||
|
}
|
||||||
|
.home-education-application-inquiry .Table_Main {
|
||||||
|
width: 1020px;
|
||||||
|
border: 1px solid #e9e9e9;
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
.home-education-application-inquiry .Table_List {
|
||||||
|
background: #e9eff4;
|
||||||
|
}
|
||||||
|
.home-education-application-inquiry button:hover {
|
||||||
|
background-color: #0056b3;
|
||||||
|
}
|
||||||
|
|
||||||
|
.input-data-modal-content {
|
||||||
|
display: table-cell;
|
||||||
|
vertical-align: middle;
|
||||||
|
}
|
||||||
|
.input-data-modal-content .input-data-modal {
|
||||||
|
position: relative;
|
||||||
|
width: 1000px;
|
||||||
|
height: 280px;
|
||||||
|
margin: 0px auto;
|
||||||
|
padding: 40px;
|
||||||
|
background-color: #fff;
|
||||||
|
border: 1px solid #000000;
|
||||||
|
box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
|
||||||
|
}
|
||||||
|
.input-data-modal-content .input-data-modal .input-data-modal-content .input-data-modal-title {
|
||||||
|
font-size: 34px;
|
||||||
|
margin-bottom: 45px;
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
.input-data-modal-content .input-data-modal .input-data-modal-content .input-data-modal-body .input-data-modal-table .input-data-modal-thead tr th {
|
||||||
|
padding-left: 13px;
|
||||||
|
padding-bottom: 10px;
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
.input-data-modal-content .input-data-modal .input-data-modal-content .input-data-modal-tail .buttons {
|
||||||
|
display: block;
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
.input-data-modal-content .input-data-modal .input-data-modal-content .input-data-modal-tail .buttons button {
|
||||||
|
background-color: #007BFF;
|
||||||
|
color: #fff;
|
||||||
|
border-radius: 6px;
|
||||||
|
border: none;
|
||||||
|
padding: 5px 10px;
|
||||||
|
}
|
||||||
|
.input-data-modal-content .input-data-modal .input-data-modal-content .input-data-modal-tail .buttons button.apply-button {
|
||||||
|
background-color: #00a999;
|
||||||
|
}
|
||||||
|
.input-data-modal-content .input-data-modal .input-data-modal-content .input-data-modal-tail .buttons button.apply-button:hover {
|
||||||
|
background-color: #008979;
|
||||||
|
}
|
||||||
|
.input-data-modal-content .input-data-modal .input-data-modal-content .input-data-modal-tail .buttons button.modification-button {
|
||||||
|
background-color: #00a999;
|
||||||
|
}
|
||||||
|
.input-data-modal-content .input-data-modal .input-data-modal-content .input-data-modal-tail .buttons button.modification-button:hover {
|
||||||
|
background-color: #008979;
|
||||||
|
}
|
||||||
|
.input-data-modal-content .input-data-modal .input-data-modal-content .input-data-modal-tail .buttons button.apply-cancel-button {
|
||||||
|
background-color: #ed2227;
|
||||||
|
}
|
||||||
|
.input-data-modal-content .input-data-modal .input-data-modal-content .input-data-modal-tail .buttons button.apply-cancel-button:hover {
|
||||||
|
background-color: #ad2227;
|
||||||
|
}
|
||||||
|
|
||||||
/* ====================================== */
|
/* ====================================== */
|
||||||
/* ====================================== */
|
/* ====================================== */
|
||||||
/* ====================================== */
|
/* ====================================== */
|
||||||
|
|
|
||||||
File diff suppressed because one or more lines are too long
|
|
@ -3437,6 +3437,146 @@ ul.faq-q > li textarea {
|
||||||
// 발주 기관 - 건설현장 등록 끝
|
// 발주 기관 - 건설현장 등록 끝
|
||||||
/* ====================================== */
|
/* ====================================== */
|
||||||
|
|
||||||
|
/* ====================================== */
|
||||||
|
// 집합교육 조회 시작
|
||||||
|
/* ====================================== */
|
||||||
|
.home-education-application-inquiry {
|
||||||
|
th,
|
||||||
|
tr{
|
||||||
|
height: 36px;
|
||||||
|
}
|
||||||
|
button{
|
||||||
|
background-color: #007BFF;
|
||||||
|
color:#fff;
|
||||||
|
border-radius: 6px;
|
||||||
|
border: none;
|
||||||
|
padding: 5px 10px;
|
||||||
|
|
||||||
|
&.edit-button {
|
||||||
|
background-color: #00a999;
|
||||||
|
&:hover {
|
||||||
|
background-color: #008979;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
&.deadline-button {
|
||||||
|
background-color: #e1e1e1;
|
||||||
|
cursor: not-allowed;
|
||||||
|
&:hover {
|
||||||
|
background-color: #888888;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
&.closed-button {
|
||||||
|
background-color: #ed2227;
|
||||||
|
cursor: not-allowed;
|
||||||
|
&:hover {
|
||||||
|
background-color: #ad2227;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
a {
|
||||||
|
background-color: #007BFF;
|
||||||
|
color:#fff;
|
||||||
|
border-radius: 6px;
|
||||||
|
border: none;
|
||||||
|
padding: 5px 10px;
|
||||||
|
&.request-button {
|
||||||
|
background-color: #007BFF;
|
||||||
|
&:hover {
|
||||||
|
background-color: #006BeF;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
&.approved-button {
|
||||||
|
background-color: #00a999;
|
||||||
|
&:hover {
|
||||||
|
background-color: #009979;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
.Table_Main{
|
||||||
|
width: 1020px;
|
||||||
|
border:1px solid #e9e9e9;
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
.Table_List{
|
||||||
|
background: #e9eff4;
|
||||||
|
}
|
||||||
|
/* 신청인정보 */
|
||||||
|
|
||||||
|
button:hover {
|
||||||
|
background-color: #0056b3;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
.input-data-modal-content {
|
||||||
|
display: table-cell;
|
||||||
|
vertical-align: middle;
|
||||||
|
.input-data-modal {
|
||||||
|
position: relative;
|
||||||
|
width: 1000px;
|
||||||
|
height: 280px;
|
||||||
|
margin: 0px auto;
|
||||||
|
padding: 40px;
|
||||||
|
background-color: #fff;
|
||||||
|
border: 1px solid #000000;
|
||||||
|
box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
|
||||||
|
.input-data-modal-content {
|
||||||
|
.input-data-modal-title {
|
||||||
|
font-size: 34px;
|
||||||
|
margin-bottom: 45px;
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
.input-data-modal-body {
|
||||||
|
.input-data-modal-table {
|
||||||
|
.input-data-modal-thead {
|
||||||
|
tr {
|
||||||
|
th {
|
||||||
|
padding-left: 13px;
|
||||||
|
padding-bottom: 10px;
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
.input-data-modal-tail {
|
||||||
|
.buttons {
|
||||||
|
display: block;
|
||||||
|
text-align: center;
|
||||||
|
button {
|
||||||
|
background-color: #007BFF;
|
||||||
|
color:#fff;
|
||||||
|
border-radius: 6px;
|
||||||
|
border: none;
|
||||||
|
padding: 5px 10px;
|
||||||
|
|
||||||
|
&.apply-button {
|
||||||
|
background-color: #00a999;
|
||||||
|
&:hover {
|
||||||
|
background-color: #008979;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
&.modification-button {
|
||||||
|
background-color: #00a999;
|
||||||
|
&:hover {
|
||||||
|
background-color: #008979;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
&.apply-cancel-button {
|
||||||
|
background-color: #ed2227;
|
||||||
|
&:hover {
|
||||||
|
background-color: #ad2227;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
/* ====================================== */
|
||||||
|
// 집합교육 조회 끝
|
||||||
|
/* ====================================== */
|
||||||
|
|
||||||
/* ====================================== */
|
/* ====================================== */
|
||||||
// 방문교육 신청 시작
|
// 방문교육 신청 시작
|
||||||
/* ====================================== */
|
/* ====================================== */
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue