Compare commits
75 Commits
| Author | SHA1 | Date |
|---|---|---|
|
|
bb9ffb8a41 | |
|
|
6a2219e829 | |
|
|
b4b0e250f3 | |
|
|
aab3a7b4d9 | |
|
|
2f487b0dfb | |
|
|
4c616bd1a0 | |
|
|
140357e136 | |
|
|
4f17dbdb80 | |
|
|
54db411eed | |
|
|
8443310b64 | |
|
|
3c62256841 | |
|
|
30e8ca481d | |
|
|
2939d541a8 | |
|
|
aad6a50563 | |
|
|
b56f41671b | |
|
|
c47f9d5262 | |
|
|
30eb9b6bec | |
|
|
74bf8a53f6 | |
|
|
16aded3a95 | |
|
|
0e3b99ec25 | |
|
|
0b71e50d0c | |
|
|
9e8965ed0c | |
|
|
b3c57451f5 | |
|
|
f785523d73 | |
|
|
6fe4474c82 | |
|
|
309813dd6e | |
|
|
d8ee817fac | |
|
|
a53ed90757 | |
|
|
601db491f1 | |
|
|
3010732fb5 | |
|
|
cc4f8ddf6d | |
|
|
f6f94152cc | |
|
|
07830d7c57 | |
|
|
12e5867ff9 | |
|
|
bac8ab8220 | |
|
|
970df1cd47 | |
|
|
f5f757a94c | |
|
|
3cab7c123a | |
|
|
a51e393efb | |
|
|
cf89e0cc4d | |
|
|
5173229196 | |
|
|
b9d9c182b2 | |
|
|
27e3e6d775 | |
|
|
5640127022 | |
|
|
989c42f1b6 | |
|
|
d305365119 | |
|
|
38b6e5fb79 | |
|
|
b7010282ab | |
|
|
fbf06470d6 | |
|
|
e9f449b0a4 | |
|
|
6363358ab7 | |
|
|
db98cb473f | |
|
|
2fca65e742 | |
|
|
3389346ca3 | |
|
|
4c81f4054c | |
|
|
9be281becd | |
|
|
66172bfc74 | |
|
|
6de7268f18 | |
|
|
4db0d9d126 | |
|
|
61c133a7cc | |
|
|
8123b512e9 | |
|
|
71b9701160 | |
|
|
d7d06b15d5 | |
|
|
aa4c298b14 | |
|
|
8313c57024 | |
|
|
a32565bd83 | |
|
|
3026b45af8 | |
|
|
20df991f64 | |
|
|
db70792bf3 | |
|
|
9e28a540a0 | |
|
|
6574428fb4 | |
|
|
bc4d2390bf | |
|
|
79035b9202 | |
|
|
4046654459 | |
|
|
fe45ea49b9 |
|
|
@ -185,3 +185,4 @@ fabric.properties
|
|||
hs_err_pid*
|
||||
replay_pid*
|
||||
|
||||
faics.iml
|
||||
|
|
|
|||
32
pom.xml
32
pom.xml
|
|
@ -130,10 +130,15 @@
|
|||
<version>1.0.0.GA</version>
|
||||
</dependency>
|
||||
|
||||
<!-- <dependency>-->
|
||||
<!-- <groupId>net.sf</groupId>-->
|
||||
<!-- <artifactId>log4jdbc3</artifactId>-->
|
||||
<!-- <version>1.1</version>-->
|
||||
<!-- </dependency>-->
|
||||
<dependency>
|
||||
<groupId>net.sf</groupId>
|
||||
<artifactId>log4jdbc3</artifactId>
|
||||
<version>1.1</version>
|
||||
<groupId>org.bgee.log4jdbc-log4j2</groupId>
|
||||
<artifactId>log4jdbc-log4j2-jdbc4.1</artifactId>
|
||||
<version>1.16</version>
|
||||
</dependency>
|
||||
|
||||
<!-- validation -->
|
||||
|
|
@ -158,15 +163,22 @@
|
|||
|
||||
|
||||
<!-- database driver -->
|
||||
<dependency>
|
||||
<groupId>ojdbc</groupId>
|
||||
<artifactId>ojdbc</artifactId>
|
||||
<version>14</version>
|
||||
<scope>system</scope>
|
||||
<systemPath>${basedir}/src/main/webapp/WEB-INF/lib/ojdbc-14.jar</systemPath>
|
||||
</dependency>
|
||||
<!-- <dependency>-->
|
||||
<!-- <groupId>ojdbc</groupId>-->
|
||||
<!-- <artifactId>ojdbc</artifactId>-->
|
||||
<!-- <version>14</version>-->
|
||||
<!-- <scope>system</scope>-->
|
||||
<!-- <systemPath>${basedir}/src/main/webapp/WEB-INF/lib/ojdbc-14.jar</systemPath>-->
|
||||
<!-- </dependency>-->
|
||||
<!-- /database driver -->
|
||||
|
||||
<!-- https://mvnrepository.com/artifact/org.postgresql/postgresql -->
|
||||
<dependency>
|
||||
<groupId>org.postgresql</groupId>
|
||||
<artifactId>postgresql</artifactId>
|
||||
<version>42.3.3</version>
|
||||
</dependency>
|
||||
|
||||
|
||||
<dependency>
|
||||
<groupId>javax.servlet</groupId>
|
||||
|
|
|
|||
|
|
@ -12,11 +12,7 @@ package kcg.faics.admin.web;
|
|||
|
||||
import java.net.URLEncoder;
|
||||
import java.text.SimpleDateFormat;
|
||||
import java.util.Calendar;
|
||||
import java.util.Date;
|
||||
import java.util.HashMap;
|
||||
import java.util.LinkedHashMap;
|
||||
import java.util.List;
|
||||
import java.util.*;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
|
|
@ -316,6 +312,66 @@ public class AdminController {
|
|||
return "excelView";
|
||||
}
|
||||
|
||||
/**
|
||||
* 외사 경찰 삭제.
|
||||
*
|
||||
* @param userIdStr
|
||||
* 삭제 대상 아이디
|
||||
* @return 삭제 결과 수
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
@ResponseBody
|
||||
@RequestMapping(value = "/faMemberDelete.do", method = RequestMethod.POST)
|
||||
public HashMap<String, Object> faMemberDelete(HttpServletResponse res, String userIdStr) throws Exception {
|
||||
HashMap<String, Object> resultMap = new HashMap<String, Object>();
|
||||
try{
|
||||
List<MemberVO> userList = new ArrayList<>();
|
||||
for(String userId : userIdStr.split("\\|")){
|
||||
MemberVO user = new MemberVO();
|
||||
user.setUserid(userId);
|
||||
userList.add(user);
|
||||
}
|
||||
MemberVO deleteUserInfo = new MemberVO();
|
||||
deleteUserInfo.setDeleteUserList(userList);
|
||||
|
||||
resultMap.put("result", memberService.deleteFaMemberList(deleteUserInfo));
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
return resultMap;
|
||||
}
|
||||
|
||||
/**
|
||||
* 일반 경찰 삭제.
|
||||
*
|
||||
* @param userIdStr
|
||||
* 삭제 대상 아이디
|
||||
* @return 삭제 결과 수
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
@ResponseBody
|
||||
@RequestMapping(value = "/cmmnMemberDelete.do", method = RequestMethod.POST)
|
||||
public HashMap<String, Object> cmmnMemberDelete(HttpServletResponse res, String userIdStr) throws Exception {
|
||||
HashMap<String, Object> resultMap = new HashMap<String, Object>();
|
||||
try{
|
||||
List<MemberVO> userList = new ArrayList<>();
|
||||
for(String userId : userIdStr.split("\\|")){
|
||||
MemberVO user = new MemberVO();
|
||||
user.setUserid(userId);
|
||||
userList.add(user);
|
||||
}
|
||||
MemberVO deleteUserInfo = new MemberVO();
|
||||
deleteUserInfo.setDeleteUserList(userList);
|
||||
|
||||
resultMap.put("result", memberService.deleteCmmnMemberList(deleteUserInfo));
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
return resultMap;
|
||||
}
|
||||
|
||||
/**
|
||||
* 외사경찰 정보수정 화면을 반환한다.
|
||||
*
|
||||
|
|
|
|||
|
|
@ -74,7 +74,7 @@ public class ArrestServiceImpl implements ArrestService {
|
|||
|
||||
//
|
||||
if(!arrestVO.getShipProcType().equals("01")){
|
||||
arrestVO.setCommissionCost("");
|
||||
arrestVO.setCommissionCost(0);
|
||||
}
|
||||
|
||||
if(arrestVO.getMarginPaymentYn().equals("N")){
|
||||
|
|
@ -101,7 +101,7 @@ public class ArrestServiceImpl implements ArrestService {
|
|||
HashMap<String, Object> result = new HashMap<String, Object>();
|
||||
|
||||
if(!arrestVO.getShipProcType().equals("01")){
|
||||
arrestVO.setCommissionCost("");
|
||||
arrestVO.setCommissionCost(0);
|
||||
}
|
||||
|
||||
if(arrestVO.getMarginPaymentYn().equals("N")){
|
||||
|
|
|
|||
File diff suppressed because it is too large
Load Diff
|
|
@ -115,6 +115,7 @@ public class BoardMapper extends EgovAbstractMapper {
|
|||
return map;
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* 선택한 게시물의 내용을 반환한다.
|
||||
*
|
||||
|
|
|
|||
|
|
@ -72,9 +72,6 @@ public class BoardSearchVO extends BaseSearchVO {
|
|||
* @param id 를 설정한다.
|
||||
*/
|
||||
public void setCategory(String category) {
|
||||
if (category == null || category.equals("")) {
|
||||
category = " ";
|
||||
}
|
||||
this.category = category;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -52,11 +52,9 @@ public class CommonAop {
|
|||
LogService logService;
|
||||
|
||||
@Around("execution(* kcg.faics..*Controller.*(..))")
|
||||
public Object menuGenerator(final ProceedingJoinPoint thisJoinPoint)
|
||||
throws Throwable {
|
||||
public Object menuGenerator(final ProceedingJoinPoint thisJoinPoint) throws Throwable {
|
||||
|
||||
HttpServletRequest req = ((ServletRequestAttributes) RequestContextHolder
|
||||
.getRequestAttributes()).getRequest();
|
||||
HttpServletRequest req = ((ServletRequestAttributes) RequestContextHolder.getRequestAttributes()).getRequest();
|
||||
String loginUrl = "/loginView.do";
|
||||
String url = req.getRequestURI();
|
||||
|
||||
|
|
@ -81,12 +79,10 @@ public class CommonAop {
|
|||
MenuVO menuVO = new MenuVO();
|
||||
menuVO.setUserId(loginUserVO.getUserid());
|
||||
menuVO.setUserType(loginUserVO.getType());
|
||||
List<MenuVO> mainMenuList = menuService
|
||||
.selectMainMenuList(menuVO);
|
||||
List<MenuVO> mainMenuList = menuService.selectMainMenuList(menuVO);
|
||||
model.addAttribute("mainMenuList", mainMenuList);
|
||||
|
||||
List<MenuVO> topSubMenuList = menuService
|
||||
.selectTopSubMenuList(menuVO);
|
||||
List<MenuVO> topSubMenuList = menuService.selectTopSubMenuList(menuVO);
|
||||
|
||||
model.addAttribute("topSubMenuList", topSubMenuList);
|
||||
|
||||
|
|
@ -114,12 +110,8 @@ public class CommonAop {
|
|||
|
||||
default:
|
||||
if (req.getParameter("category") != null
|
||||
&& !req.getParameter("category")
|
||||
.equals(" ")) {
|
||||
qryCate = "category="
|
||||
+ req.getParameter("category");
|
||||
// url = url + "/" +
|
||||
// req.getParameter("category");
|
||||
&& !req.getParameter("category").equals(" ")) {
|
||||
qryCate = "category=" + req.getParameter("category");
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
|
@ -130,19 +122,14 @@ public class CommonAop {
|
|||
menu.put("boardId", boardId);
|
||||
menu.put("query", qryCate);
|
||||
|
||||
HashMap<String, Object> menuInfo = menuService
|
||||
.getMenuInfo(menu);
|
||||
menuVO.setId(Integer
|
||||
.parseInt(menuInfo.get("ID").toString()));
|
||||
HashMap<String, Object> menuInfo = menuService.getMenuInfo(menu);
|
||||
menuVO.setId(((Double)menuInfo.get("id")).intValue());
|
||||
menuInfo.put("userId", loginUserVO.getUserid());
|
||||
|
||||
List<MenuVO> currAndHigherMenuList = menuService
|
||||
.selectListWithHigher(menuVO);
|
||||
model.addAttribute("currAndHigherMenuList",
|
||||
currAndHigherMenuList);
|
||||
List<MenuVO> currAndHigherMenuList = menuService.selectListWithHigher(menuVO);
|
||||
model.addAttribute("currAndHigherMenuList", currAndHigherMenuList);
|
||||
model.addAttribute("menu", menuInfo);
|
||||
model.addAttribute("subMenu",
|
||||
menuService.getSubmenu(menuInfo));
|
||||
model.addAttribute("subMenu", menuService.getSubmenu(menuInfo));
|
||||
|
||||
addUserLog(req, menu);
|
||||
}
|
||||
|
|
@ -151,8 +138,7 @@ public class CommonAop {
|
|||
// e.printStackTrace();
|
||||
}
|
||||
|
||||
Object proc = thisJoinPoint.proceed();
|
||||
return proc;
|
||||
return thisJoinPoint.proceed();
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -100,10 +100,10 @@ public class ExcelExporter<T> extends AbstractExcelExport {
|
|||
|
||||
try {
|
||||
if (t instanceof Map<?, ?>) {
|
||||
Object o = ((Map<?, ?>) t).get(key);
|
||||
Object o = ((Map<?, ?>) t).get(key.toLowerCase());
|
||||
if (o instanceof String) {
|
||||
value = o.toString();
|
||||
} else if (o instanceof Integer || o instanceof Double) {
|
||||
} else if (o instanceof Integer || o instanceof Double || o instanceof Long) {
|
||||
value = String.valueOf(o);
|
||||
} else if (o instanceof BigDecimal) {
|
||||
value = ((BigDecimal) o).toString();
|
||||
|
|
|
|||
|
|
@ -34,16 +34,14 @@ public class MenuServiceImpl implements MenuService {
|
|||
LoginUserVO loginUserVO = UserUtil.getMemberInfo();
|
||||
|
||||
menuVO.setDepth(1);
|
||||
menuVO.setMaxLevel(2);
|
||||
menuVO.setMenuPosition(MenuPosition.TOP);
|
||||
List<MenuVO> list = menuMapper.selectListWithConnectBy(menuVO);
|
||||
List<MenuVO> menuList = new ArrayList<MenuVO>();
|
||||
|
||||
MenuVO prevMenu = null;
|
||||
for (int i = 0; i < list.size(); i++) {
|
||||
MenuVO currVO = list.get(i);
|
||||
for (MenuVO currVO: list) {
|
||||
if (currVO.getDepth() == 0) {
|
||||
prevMenu = currVO;
|
||||
menuList.add(prevMenu);
|
||||
menuList.add(currVO);
|
||||
} else if (currVO.getDepth() == 1) {
|
||||
|
||||
// 견문 메뉴 권한
|
||||
|
|
@ -56,8 +54,13 @@ public class MenuServiceImpl implements MenuService {
|
|||
if (loginUserVO.getAuthManage() <= 0 && !UserUtil.isAdmin() && "관리기능".equals(currVO.getName())) {
|
||||
continue;
|
||||
}
|
||||
for(MenuVO menu: menuList){
|
||||
if(menu.getId()==currVO.getParent()){
|
||||
menu.getSubMenu().add(currVO);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
prevMenu.getSubMenu().add(currVO);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -67,6 +70,7 @@ public class MenuServiceImpl implements MenuService {
|
|||
@Override
|
||||
public List<MenuVO> selectTopSubMenuList(final MenuVO menuVO) {
|
||||
menuVO.setDepth(0);
|
||||
menuVO.setMaxLevel(1);
|
||||
menuVO.setMenuPosition(MenuPosition.TOP_SUB);
|
||||
return menuMapper.selectListWithConnectBy(menuVO);
|
||||
}
|
||||
|
|
@ -81,11 +85,10 @@ public class MenuServiceImpl implements MenuService {
|
|||
|
||||
HashMap<String, Object> paramMenu = menuMapper.getMenuInfo(menu);
|
||||
|
||||
int depth = ((BigDecimal) paramMenu.get("DEPTH")).intValue();
|
||||
if (depth < 3) {
|
||||
if ((Double)paramMenu.get("depth") < 3.0d) {
|
||||
return paramMenu;
|
||||
} else {
|
||||
menu.put("id", ((BigDecimal) paramMenu.get("PARENT")).intValue());
|
||||
menu.put("id", ((BigDecimal) paramMenu.get("parent")).intValue());
|
||||
return menuMapper.getMenuInfoById(menu);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -85,6 +85,16 @@ public class MenuVO {
|
|||
*/
|
||||
private int userType;
|
||||
|
||||
private int maxLevel;
|
||||
|
||||
public int getMaxLevel() {
|
||||
return maxLevel;
|
||||
}
|
||||
|
||||
public void setMaxLevel(int maxLevel) {
|
||||
this.maxLevel = maxLevel;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return the id
|
||||
*/
|
||||
|
|
|
|||
|
|
@ -96,7 +96,7 @@ public class CommonController {
|
|||
LoginUserVO loginUserVO = UserUtil.getMemberInfo();
|
||||
ReportSearchVO reportSearchVO = new ReportSearchVO();
|
||||
reportSearchVO.setRecordCountPerPage(5);
|
||||
reportSearchVO.setType(loginUserVO.getType());
|
||||
reportSearchVO.setType(Integer.toString(loginUserVO.getType()));
|
||||
reportSearchVO.setUserid(loginUserVO.getUserid());
|
||||
//최근 1달치
|
||||
Calendar mon = Calendar.getInstance();
|
||||
|
|
|
|||
|
|
@ -59,10 +59,8 @@ public class ApproveServiceImpl implements ApproveService {
|
|||
}
|
||||
|
||||
@Override
|
||||
public HashMap<String, Object> insert(final ApproveVO dataVO,
|
||||
final Map<String, MultipartFile> fileMap) throws Exception {
|
||||
public HashMap<String, Object> insert(final ApproveVO dataVO, final Map<String, MultipartFile> fileMap) throws Exception {
|
||||
HashMap<String, Object> result = new HashMap<String, Object>();
|
||||
|
||||
// 이미 결재 내역이 있으면 결재하지 않는다.
|
||||
ApproveVO vo = select(dataVO);
|
||||
if (vo == null) {
|
||||
|
|
|
|||
|
|
@ -170,7 +170,7 @@ public class EquipmentServiceImpl implements EquipmentService {
|
|||
while (it.hasNext()) {
|
||||
HashMap<String, Object> value = paramMap.get(it.next());
|
||||
HashMap<String, Object> record = equipmentMapper.getEquipUseStateInfoByCode(value);
|
||||
boolean isInsert = (record == null) ? true : false;
|
||||
boolean isInsert = record == null;
|
||||
|
||||
if (isInsert) {
|
||||
success = equipmentMapper.insertEquipUseState(value);
|
||||
|
|
|
|||
|
|
@ -10,7 +10,7 @@ package kcg.faics.equip.vo;
|
|||
*
|
||||
*/
|
||||
public class EquipVO {
|
||||
private String serNo;
|
||||
private Integer serNo;
|
||||
private String num;
|
||||
private String equipType;
|
||||
private String equipTypeName;
|
||||
|
|
@ -41,7 +41,7 @@ public class EquipVO {
|
|||
/**
|
||||
* @return the serNo
|
||||
*/
|
||||
public String getSerNo() {
|
||||
public Integer getSerNo() {
|
||||
return serNo;
|
||||
}
|
||||
|
||||
|
|
@ -90,7 +90,7 @@ public class EquipVO {
|
|||
/**
|
||||
* @param serNo the serNo to set
|
||||
*/
|
||||
public void setSerNo(String serNo) {
|
||||
public void setSerNo(Integer serNo) {
|
||||
this.serNo = serNo;
|
||||
}
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -36,8 +36,8 @@ import kcg.faics.member.vo.MemberVO;
|
|||
import kcg.faics.sec.AuthType;
|
||||
import kcg.faics.sec.LoginUserVO;
|
||||
import kcg.faics.sec.UserUtil;
|
||||
import kcg.faics.target.service.impl.DivMngServiceImpl;
|
||||
import kcg.faics.target.vo.DivMngVO;
|
||||
import kcg.faics.tg.service.impl.DivMngServiceImpl;
|
||||
import kcg.faics.tg.vo.DivMngVO;
|
||||
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
|
|
@ -186,10 +186,10 @@ public class EquipmentController {
|
|||
|
||||
Calendar c = Calendar.getInstance();
|
||||
int currYear = c.get(Calendar.YEAR);
|
||||
int lastYear = Integer.parseInt((String) year.get(year.size() - 1).get("UYEAR"));
|
||||
int lastYear = Integer.parseInt((String) year.get(year.size() - 1).get("uyear"));
|
||||
for (int i = lastYear + 1; i <= currYear; i++) {
|
||||
HashMap<String, Object> map = new HashMap<String, Object>();
|
||||
map.put("UYEAR", i);
|
||||
map.put("uyear", i);
|
||||
year.add(map);
|
||||
}
|
||||
|
||||
|
|
@ -431,10 +431,8 @@ public class EquipmentController {
|
|||
public String approve(final ApproveVO approveVO, final Model model) throws Exception {
|
||||
HashMap<String, Object> result = approveService.insert(approveVO, null);
|
||||
if ("1".equals(result.get("result").toString())) {
|
||||
return String
|
||||
.format("redirect:/equip/useStateWaiting.do?police=%s&year=%s&quater=%s",
|
||||
approveVO.getPolice(), approveVO.getYear(),
|
||||
approveVO.getQuater());
|
||||
return String.format("redirect:/equip/useStateWaiting.do?police=%s&year=%s&quater=%s",
|
||||
approveVO.getPolice(), approveVO.getYear(), approveVO.getQuater());
|
||||
}
|
||||
return useStateApprove(approveVO, model);
|
||||
}
|
||||
|
|
@ -598,7 +596,7 @@ public class EquipmentController {
|
|||
final Map<String, MultipartFile> fileMap = multiRequest.getFileMap();
|
||||
|
||||
|
||||
if( equipVO.getSerNo().equals("") || equipVO.getSerNo().equals(null)){
|
||||
if(equipVO.getSerNo()==null || equipVO.getSerNo() == 0){
|
||||
/* 등록 처리 */
|
||||
|
||||
equipVO.setWriter(loginUserVO.getUserid());
|
||||
|
|
|
|||
|
|
@ -17,8 +17,8 @@ import kcg.faics.fa.vo.EduSearchVO;
|
|||
import kcg.faics.fa.vo.EduVO;
|
||||
import kcg.faics.sec.LoginUserVO;
|
||||
import kcg.faics.sec.UserUtil;
|
||||
import kcg.faics.target.vo.DivMngSearchVO;
|
||||
import kcg.faics.target.vo.DivMngVO;
|
||||
import kcg.faics.tg.vo.DivMngSearchVO;
|
||||
import kcg.faics.tg.vo.DivMngVO;
|
||||
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
|
|
|
|||
|
|
@ -123,7 +123,7 @@ public class ExMemberController {
|
|||
|
||||
List<ExMemberVO> resultList = memberService.exmemberVoList(searchVO);
|
||||
|
||||
model.addAttribute("resultList", memberService.exmemberVoList(searchVO));
|
||||
model.addAttribute("resultList", resultList);
|
||||
model.addAttribute("place1List", codeService.getPlace1List(false));
|
||||
model.addAttribute("positionList", codeService.getPositionList());
|
||||
} catch (Exception e) {
|
||||
|
|
|
|||
|
|
@ -88,35 +88,35 @@ public class FaController {
|
|||
@RequestMapping("/memberManagePersonnelExcel.do")
|
||||
public String memberManagePersonnelExcel(final Model model) throws Exception {
|
||||
|
||||
String title = "외사경찰 정원 및 현원 현황";
|
||||
|
||||
List<HashMap<String, Object>> resultList = memberService.getCapacityManagement();
|
||||
|
||||
LinkedHashMap<String, String> header = new LinkedHashMap<String, String>();
|
||||
header.put("CODENM", "구분");
|
||||
header.put("TOT_CNT", "전체 정원");
|
||||
header.put("CURRENT_CNT", "현재 정원");
|
||||
header.put("EXCESS", "과부족");
|
||||
header.put("POSITION204", "총경 정원");
|
||||
header.put("CNT_204", "총경 현원");
|
||||
header.put("codenm", "구분");
|
||||
header.put("tot_cnt", "전체 정원");
|
||||
header.put("current_cnt", "현재 정원");
|
||||
header.put("excess", "과부족");
|
||||
header.put("position204", "총경 정원");
|
||||
header.put("cnt_204", "총경 현원");
|
||||
|
||||
header.put("POSITION203", "경정 정원");
|
||||
header.put("CNT_203", "경정 현원");
|
||||
header.put("position203", "경정 정원");
|
||||
header.put("cnt_203", "경정 현원");
|
||||
|
||||
header.put("POSITION202", "경감 정원");
|
||||
header.put("CNT_202", "경감 현원");
|
||||
header.put("position202", "경감 정원");
|
||||
header.put("cnt_202", "경감 현원");
|
||||
|
||||
header.put("POSITION201", "경위 정원");
|
||||
header.put("CNT_201", "경위 현원");
|
||||
header.put("position201", "경위 정원");
|
||||
header.put("cnt_201", "경위 현원");
|
||||
|
||||
header.put("POSITION104", "경사 정원");
|
||||
header.put("CNT_104", "경사 현원");
|
||||
header.put("position104", "경사 정원");
|
||||
header.put("cnt_104", "경사 현원");
|
||||
|
||||
header.put("POSITION103", "경장 정원");
|
||||
header.put("CNT_103", "경장 현원");
|
||||
header.put("position103", "경장 정원");
|
||||
header.put("cnt_103", "경장 현원");
|
||||
|
||||
header.put("POSITION102", "순경 정원");
|
||||
header.put("CNT_102", "순경 현원");
|
||||
header.put("position102", "순경 정원");
|
||||
header.put("cnt_102", "순경 현원");
|
||||
|
||||
String title = "외사경찰 정원 및 현원 현황";
|
||||
|
||||
model.addAttribute("excel", new ExcelExporter<HashMap<String, Object>>(header, resultList, title));
|
||||
model.addAttribute("filename", title);
|
||||
|
|
|
|||
|
|
@ -108,23 +108,23 @@ public class InternationalVO {
|
|||
/**
|
||||
* 침범유형1
|
||||
*/
|
||||
private int invasionType1 = 0;
|
||||
private String invasionType1 = "";
|
||||
/**
|
||||
* 침범유형2
|
||||
*/
|
||||
private int invasionType2 = 0;
|
||||
private String invasionType2 = "";
|
||||
/**
|
||||
* 침범유형3
|
||||
*/
|
||||
private int invasionType3 = 0;
|
||||
private String invasionType3 = "";
|
||||
/**
|
||||
* 침범유형4
|
||||
*/
|
||||
private int invasionType4 = 0;
|
||||
private String invasionType4 = "";
|
||||
/**
|
||||
* 침범유형5
|
||||
*/
|
||||
private int invasionType5 = 0;
|
||||
private String invasionType5 = "";
|
||||
/**
|
||||
* 선박처리유형(위탁관리)
|
||||
*/
|
||||
|
|
@ -1315,7 +1315,7 @@ public class InternationalVO {
|
|||
/**
|
||||
* @return the invasionType1
|
||||
*/
|
||||
public int getInvasionType1() {
|
||||
public String getInvasionType1() {
|
||||
return invasionType1;
|
||||
}
|
||||
|
||||
|
|
@ -1323,7 +1323,7 @@ public class InternationalVO {
|
|||
/**
|
||||
* @param invasionType1 the invasionType1 to set
|
||||
*/
|
||||
public void setInvasionType1(int invasionType1) {
|
||||
public void setInvasionType1(String invasionType1) {
|
||||
this.invasionType1 = invasionType1;
|
||||
}
|
||||
|
||||
|
|
@ -1331,7 +1331,7 @@ public class InternationalVO {
|
|||
/**
|
||||
* @return the invasionType2
|
||||
*/
|
||||
public int getInvasionType2() {
|
||||
public String getInvasionType2() {
|
||||
return invasionType2;
|
||||
}
|
||||
|
||||
|
|
@ -1339,7 +1339,7 @@ public class InternationalVO {
|
|||
/**
|
||||
* @param invasionType2 the invasionType2 to set
|
||||
*/
|
||||
public void setInvasionType2(int invasionType2) {
|
||||
public void setInvasionType2(String invasionType2) {
|
||||
this.invasionType2 = invasionType2;
|
||||
}
|
||||
|
||||
|
|
@ -1347,7 +1347,7 @@ public class InternationalVO {
|
|||
/**
|
||||
* @return the invasionType3
|
||||
*/
|
||||
public int getInvasionType3() {
|
||||
public String getInvasionType3() {
|
||||
return invasionType3;
|
||||
}
|
||||
|
||||
|
|
@ -1355,7 +1355,7 @@ public class InternationalVO {
|
|||
/**
|
||||
* @param invasionType3 the invasionType3 to set
|
||||
*/
|
||||
public void setInvasionType3(int invasionType3) {
|
||||
public void setInvasionType3(String invasionType3) {
|
||||
this.invasionType3 = invasionType3;
|
||||
}
|
||||
|
||||
|
|
@ -1363,7 +1363,7 @@ public class InternationalVO {
|
|||
/**
|
||||
* @return the invasionType4
|
||||
*/
|
||||
public int getInvasionType4() {
|
||||
public String getInvasionType4() {
|
||||
return invasionType4;
|
||||
}
|
||||
|
||||
|
|
@ -1371,7 +1371,7 @@ public class InternationalVO {
|
|||
/**
|
||||
* @param invasionType4 the invasionType4 to set
|
||||
*/
|
||||
public void setInvasionType4(int invasionType4) {
|
||||
public void setInvasionType4(String invasionType4) {
|
||||
this.invasionType4 = invasionType4;
|
||||
}
|
||||
|
||||
|
|
@ -1379,7 +1379,7 @@ public class InternationalVO {
|
|||
/**
|
||||
* @return the invasionType5
|
||||
*/
|
||||
public int getInvasionType5() {
|
||||
public String getInvasionType5() {
|
||||
return invasionType5;
|
||||
}
|
||||
|
||||
|
|
@ -1387,7 +1387,7 @@ public class InternationalVO {
|
|||
/**
|
||||
* @param invasionType5 the invasionType5 to set
|
||||
*/
|
||||
public void setInvasionType5(int invasionType5) {
|
||||
public void setInvasionType5(String invasionType5) {
|
||||
this.invasionType5 = invasionType5;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -561,10 +561,10 @@ public class InternationalController {
|
|||
header.put("speciallaw", "기타(외국인관련범죄)_특별법범");
|
||||
header.put("commissionCost", "비고");
|
||||
|
||||
arrestCntList.setDetentionTotalCnt(String.valueOf(arrestCntList.getCaptainCount()
|
||||
+ arrestCntList.getMateCount()
|
||||
+ arrestCntList.getEngineerCount()
|
||||
+ arrestCntList.getCrewCount()));
|
||||
arrestCntList.setDetentionTotalCnt(
|
||||
String.valueOf(
|
||||
arrestCntList.getCaptainCount() + arrestCntList.getMateCount()
|
||||
+ arrestCntList.getEngineerCount() + arrestCntList.getCrewCount()));
|
||||
arrestCntList.setSpecBatlYn(String.valueOf(arrestCntList.getSpecBatlCnt()));
|
||||
arrestCntList.setNllYn(String.valueOf(arrestCntList.getNllCnt()));
|
||||
arrestCntList.setNoPaymentCnt(String.valueOf(arrestCntList.getNotPayment()));
|
||||
|
|
|
|||
|
|
@ -177,4 +177,8 @@ public interface MemberService extends BaseBbsService<MemberSearchVO, MemberVO>
|
|||
* 기본 예외 처리
|
||||
*/
|
||||
HashMap<String, Object> deleteExMember(ExMemberVO dataVO) throws Exception;
|
||||
|
||||
|
||||
int deleteFaMemberList(MemberVO user) throws Exception;
|
||||
int deleteCmmnMemberList(MemberVO user) throws Exception;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -354,4 +354,13 @@ public class MemberMapper extends EgovAbstractMapper {
|
|||
public int insertExMemeber(final MemberVO dataVO) {
|
||||
return insert("Member.insertExMemberByMemberVO", dataVO);
|
||||
}
|
||||
|
||||
|
||||
public int deleteFaMemberList(MemberVO user) {
|
||||
return delete("Member.deleteFaMemberList", user);
|
||||
}
|
||||
|
||||
public int deleteCmmnMemberList(MemberVO user) {
|
||||
return delete("Member.deleteCmmnMemberList", user);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -652,5 +652,10 @@ public class MemberServiceImpl implements MemberService {
|
|||
return resultMap;
|
||||
}
|
||||
|
||||
|
||||
public int deleteFaMemberList(MemberVO user) throws Exception{
|
||||
return memberMapper.deleteFaMemberList(user);
|
||||
}
|
||||
public int deleteCmmnMemberList(MemberVO user) throws Exception{
|
||||
return memberMapper.deleteCmmnMemberList(user);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -5,6 +5,7 @@ import java.text.ParseException;
|
|||
import java.text.SimpleDateFormat;
|
||||
import java.util.Calendar;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
import java.util.Locale;
|
||||
|
||||
import kcg.faics.member.UserType;
|
||||
|
|
@ -288,6 +289,19 @@ public class MemberVO implements Serializable {
|
|||
*/
|
||||
private String writer;
|
||||
|
||||
private List<MemberVO> deleteUserList;
|
||||
|
||||
public void setNowPlaceStr(String nowPlaceStr) {
|
||||
this.nowPlaceStr = nowPlaceStr;
|
||||
}
|
||||
|
||||
public List<MemberVO> getDeleteUserList() {
|
||||
return deleteUserList;
|
||||
}
|
||||
|
||||
public void setDeleteUserList(List<MemberVO> deleteUserList) {
|
||||
this.deleteUserList = deleteUserList;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return the userid
|
||||
|
|
|
|||
|
|
@ -401,17 +401,17 @@ public class ReportJudgeServiceImpl extends EgovAbstractServiceImpl implements R
|
|||
|
||||
HashMap<String, String> ttt = new HashMap<String, String>();
|
||||
for (String mapKey : newMap.keySet()) {
|
||||
if (!mapKey.equals("TOTAL") && !mapKey.equals("PLACENAME") && !mapKey.equals("PLACECODE")) {
|
||||
if (!mapKey.equals("total") && !mapKey.equals("placename") && !mapKey.equals("placecode")) {
|
||||
ttt.put(mapKey + "_1", newMap.get(mapKey));
|
||||
}
|
||||
}
|
||||
ttt.put("PLACENAME", newMap.get("PLACENAME"));
|
||||
ttt.put("placename", newMap.get("placename"));
|
||||
|
||||
if (cateMap.size() > idx && cateMap.get(idx) != null) {
|
||||
cateMap.get(idx).putAll(ttt);
|
||||
cateMap.get(idx).put("TOTAL", String.valueOf(Integer.parseInt(cateMap.get(idx).get("TOTAL").toString()) + Integer.parseInt(newMap.get("TOTAL").toString())));
|
||||
cateMap.get(idx).put("total", String.valueOf(Integer.parseInt(cateMap.get(idx).get("total").toString()) + Integer.parseInt(newMap.get("total").toString())));
|
||||
} else {
|
||||
ttt.put("TOTAL", newMap.get("TOTAL"));
|
||||
ttt.put("total", newMap.get("total"));
|
||||
cateMap.add(idx, ttt);
|
||||
}
|
||||
idx++;
|
||||
|
|
@ -427,17 +427,17 @@ public class ReportJudgeServiceImpl extends EgovAbstractServiceImpl implements R
|
|||
HashMap<String, String> ttt = new HashMap<String, String>();
|
||||
|
||||
for (String mapKey : newMap.keySet()) {
|
||||
if (!mapKey.equals("TOTAL") && !mapKey.equals("PLACENAME") && !mapKey.equals("PLACECODE")) {
|
||||
if (!mapKey.equals("total") && !mapKey.equals("placename") && !mapKey.equals("placecode")) {
|
||||
ttt.put(mapKey + "_2", newMap.get(mapKey));
|
||||
}
|
||||
ttt.put("PLACENAME", newMap.get("PLACENAME"));
|
||||
ttt.put("placename", newMap.get("placename"));
|
||||
}
|
||||
|
||||
if (cateMap.size() > idx && cateMap.get(idx) != null) {
|
||||
cateMap.get(idx).putAll(ttt);
|
||||
cateMap.get(idx).put("TOTAL", String.valueOf(Integer.parseInt(cateMap.get(idx).get("TOTAL").toString()) + Integer.parseInt(newMap.get("TOTAL").toString())));
|
||||
cateMap.get(idx).put("total", String.valueOf((Integer.parseInt(String.valueOf(cateMap.get(idx).get("total"))) + Integer.parseInt(String.valueOf(newMap.get("total"))))));
|
||||
} else {
|
||||
ttt.put("TOTAL", newMap.get("TOTAL"));
|
||||
ttt.put("total", newMap.get("total"));
|
||||
cateMap.add(idx, ttt);
|
||||
}
|
||||
idx++;
|
||||
|
|
@ -452,17 +452,17 @@ public class ReportJudgeServiceImpl extends EgovAbstractServiceImpl implements R
|
|||
HashMap<String, String> ttt = new HashMap<String, String>();
|
||||
|
||||
for (String mapKey : newMap.keySet()) {
|
||||
if (!mapKey.equals("TOTAL") && !mapKey.equals("PLACENAME") && !mapKey.equals("PLACECODE")) {
|
||||
if (!mapKey.equals("total") && !mapKey.equals("placename") && !mapKey.equals("placecode")) {
|
||||
ttt.put(mapKey + "_3", newMap.get(mapKey));
|
||||
}
|
||||
ttt.put("PLACENAME", newMap.get("PLACENAME"));
|
||||
ttt.put("placename", newMap.get("placename"));
|
||||
}
|
||||
|
||||
if (cateMap.size() > idx && cateMap.get(idx) != null) {
|
||||
cateMap.get(idx).putAll(ttt);
|
||||
cateMap.get(idx).put("TOTAL", String.valueOf(Integer.parseInt(cateMap.get(idx).get("TOTAL").toString()) + Integer.parseInt(newMap.get("TOTAL").toString())));
|
||||
cateMap.get(idx).put("total", String.valueOf(Integer.parseInt(String.valueOf(cateMap.get(idx).get("total"))) + Integer.parseInt(String.valueOf(newMap.get("total")))));
|
||||
} else {
|
||||
ttt.put("TOTAL", newMap.get("TOTAL"));
|
||||
ttt.put("total", newMap.get("total"));
|
||||
cateMap.add(idx, ttt);
|
||||
}
|
||||
idx++;
|
||||
|
|
@ -477,17 +477,17 @@ public class ReportJudgeServiceImpl extends EgovAbstractServiceImpl implements R
|
|||
HashMap<String, String> ttt = new HashMap<String, String>();
|
||||
|
||||
for (String mapKey : newMap.keySet()) {
|
||||
if (!mapKey.equals("TOTAL") && !mapKey.equals("PLACENAME") && !mapKey.equals("PLACECODE")) {
|
||||
if (!mapKey.equals("total") && !mapKey.equals("placename") && !mapKey.equals("placecode")) {
|
||||
ttt.put(mapKey + "_4", newMap.get(mapKey));
|
||||
}
|
||||
ttt.put("PLACENAME", newMap.get("PLACENAME"));
|
||||
ttt.put("placename", newMap.get("placename"));
|
||||
}
|
||||
|
||||
if (cateMap.size() > idx && cateMap.get(idx) != null) {
|
||||
cateMap.get(idx).putAll(ttt);
|
||||
cateMap.get(idx).put("TOTAL", String.valueOf(Integer.parseInt(cateMap.get(idx).get("TOTAL").toString()) + Integer.parseInt(newMap.get("TOTAL").toString())));
|
||||
cateMap.get(idx).put("total", String.valueOf(Integer.parseInt(String.valueOf(cateMap.get(idx).get("total"))) + Integer.parseInt(String.valueOf(newMap.get("total")))));
|
||||
} else {
|
||||
ttt.put("TOTAL", newMap.get("TOTAL"));
|
||||
ttt.put("total", newMap.get("total"));
|
||||
cateMap.add(idx, ttt);
|
||||
}
|
||||
idx++;
|
||||
|
|
@ -496,15 +496,15 @@ public class ReportJudgeServiceImpl extends EgovAbstractServiceImpl implements R
|
|||
|
||||
if (cateMap.size() > 0) {
|
||||
HashMap<String, String> totalMap = new HashMap<String, String>();
|
||||
totalMap.put("PLACENAME", "누계");
|
||||
totalMap.put("placename", "누계");
|
||||
|
||||
for (String key : cateMap.get(0).keySet()) {
|
||||
if (key.equals("PLACENAME")) {
|
||||
if (key.equals("placename")) {
|
||||
continue;
|
||||
}
|
||||
int tt = 0;
|
||||
for (HashMap<String, String> hashMap : cateMap) {
|
||||
tt = tt + Integer.parseInt(hashMap.get(key));
|
||||
tt = tt + Integer.parseInt(String.valueOf(hashMap.get(key)));
|
||||
}
|
||||
totalMap.put(key, String.valueOf(tt));
|
||||
}
|
||||
|
|
@ -520,33 +520,33 @@ public class ReportJudgeServiceImpl extends EgovAbstractServiceImpl implements R
|
|||
List<HashMap<String, String>> list = reportJudgeMapper.statsJudge(reportSearchVO);
|
||||
|
||||
HashMap<String, String> map = new HashMap<String, String>();
|
||||
map.put("PLACENAME", "누계");
|
||||
map.put("placename", "누계");
|
||||
|
||||
if (list.size() > 0) {
|
||||
for (String key : list.get(0).keySet()) {
|
||||
if (key.equals("PLACENAME")) {
|
||||
if (key.equals("placename")) {
|
||||
continue;
|
||||
}
|
||||
int total = 0;
|
||||
for (HashMap<String, String> item : list) {
|
||||
total = total + Integer.parseInt(item.get(key));
|
||||
total += Integer.parseInt(String.valueOf(item.get("bg")));
|
||||
}
|
||||
map.put(key, String.valueOf(total));
|
||||
}
|
||||
} else {
|
||||
map.put("REPORT1", "0");
|
||||
map.put("REPORT2", "0");
|
||||
map.put("JU1", "0");
|
||||
map.put("JU2", "0");
|
||||
map.put("JU3", "0");
|
||||
map.put("JU4", "0");
|
||||
map.put("JU5", "0");
|
||||
map.put("JU6", "0");
|
||||
map.put("JU7", "0");
|
||||
map.put("AG", "0");
|
||||
map.put("BG", "0");
|
||||
map.put("CG", "0");
|
||||
map.put("DG", "0");
|
||||
map.put("report1", "0");
|
||||
map.put("report2", "0");
|
||||
map.put("ju1", "0");
|
||||
map.put("ju2", "0");
|
||||
map.put("ju3", "0");
|
||||
map.put("ju4", "0");
|
||||
map.put("ju5", "0");
|
||||
map.put("ju6", "0");
|
||||
map.put("ju7", "0");
|
||||
map.put("ag", "0");
|
||||
map.put("bg", "0");
|
||||
map.put("cg", "0");
|
||||
map.put("dg", "0");
|
||||
}
|
||||
|
||||
list.add(list.size(), map);
|
||||
|
|
|
|||
|
|
@ -9,6 +9,11 @@ import kcg.faics.cmmn.bbs.BaseSearchVO;
|
|||
* 견문 검색 VO
|
||||
*/
|
||||
public class ReportSearchVO extends BaseSearchVO implements Cloneable {
|
||||
private int report1;
|
||||
|
||||
private int report2;
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* 접속한 사용자 아이디
|
||||
|
|
@ -21,7 +26,7 @@ public class ReportSearchVO extends BaseSearchVO implements Cloneable {
|
|||
/**
|
||||
* 접속한 사용자 타입
|
||||
*/
|
||||
private int type;
|
||||
private String type;
|
||||
/**
|
||||
* 접속한 사용자 그룹
|
||||
*/
|
||||
|
|
@ -150,6 +155,22 @@ public class ReportSearchVO extends BaseSearchVO implements Cloneable {
|
|||
*/
|
||||
private String month;
|
||||
|
||||
public int getReport1() {
|
||||
return report1;
|
||||
}
|
||||
|
||||
public void setReport1(int report1) {
|
||||
this.report1 = report1;
|
||||
}
|
||||
|
||||
public int getReport2() {
|
||||
return report2;
|
||||
}
|
||||
|
||||
public void setReport2(int report2) {
|
||||
this.report2 = report2;
|
||||
}
|
||||
|
||||
public String getUserid() {
|
||||
return userid;
|
||||
}
|
||||
|
|
@ -162,10 +183,10 @@ public class ReportSearchVO extends BaseSearchVO implements Cloneable {
|
|||
public void setUsegrade(final int usegrade) {
|
||||
this.usegrade = usegrade;
|
||||
}
|
||||
public int getType() {
|
||||
public String getType() {
|
||||
return type;
|
||||
}
|
||||
public void setType(final int type) {
|
||||
public void setType(final String type) {
|
||||
this.type = type;
|
||||
}
|
||||
public int getMyGroupCode() {
|
||||
|
|
|
|||
|
|
@ -348,6 +348,7 @@ public class ReportVO {
|
|||
private String isJudge5;
|
||||
private String isJudge6;
|
||||
private String isJudge7;
|
||||
private String isJudge8;
|
||||
private String isReport1;
|
||||
private String isReport2;
|
||||
|
||||
|
|
@ -615,6 +616,9 @@ public class ReportVO {
|
|||
break;
|
||||
case 7:
|
||||
this.isJudge7 = STRCORRECT;
|
||||
break;
|
||||
case 8:
|
||||
this.isJudge8 = STRCORRECT;
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
|
|
@ -908,6 +912,9 @@ public class ReportVO {
|
|||
}
|
||||
public String getIsJudge7() {
|
||||
return isJudge7;
|
||||
}
|
||||
public String getIsJudge8() {
|
||||
return isJudge8;
|
||||
}
|
||||
public String getIsReport1() {
|
||||
return isReport1;
|
||||
|
|
@ -981,8 +988,8 @@ public class ReportVO {
|
|||
+ ", isSection=" + isSection + ", isJudge2=" + isJudge2
|
||||
+ ", isJudge3=" + isJudge3 + ", isJudge4=" + isJudge4
|
||||
+ ", isJudge5=" + isJudge5 + ", isJudge6=" + isJudge6
|
||||
+ ", isJudge7=" + isJudge7 + ", isReport1=" + isReport1
|
||||
+ ", isReport2=" + isReport2 + ", reportList=" + reportList
|
||||
+ ", isJudge7=" + isJudge7 + ", isJudge8=" + isJudge8
|
||||
+ ", isReport1=" + isReport1 + ", isReport2=" + isReport2 + ", reportList=" + reportList
|
||||
+ "]";
|
||||
}
|
||||
}
|
||||
|
|
@ -213,7 +213,7 @@ public class ReportCommon {
|
|||
|
||||
result.setUserid(loginUserVO.getUserid());
|
||||
result.setUsegrade(loginUserVO.getUsegrade());
|
||||
result.setType(loginUserVO.getType());
|
||||
result.setType(Integer.toString(loginUserVO.getType()));
|
||||
result.setMyGroupCode(ReportCommon.getMyGroupCode());
|
||||
result.setDuties(loginUserVO.getDutiesStr());
|
||||
result.setUserPlace(loginUserVO.getPlace1());
|
||||
|
|
|
|||
|
|
@ -131,7 +131,7 @@ public class ReportController {
|
|||
try {
|
||||
rptSearchVO.setUserid(loginUserVO.getUserid());
|
||||
rptSearchVO.setUsegrade(loginUserVO.getUsegrade());
|
||||
rptSearchVO.setType(loginUserVO.getType());
|
||||
rptSearchVO.setType(Integer.toString(loginUserVO.getType()));
|
||||
|
||||
/* 페이징 처리 정보 */
|
||||
rptSearchVO.setPageUnit(propertiesService.getInt("pageUnit"));
|
||||
|
|
|
|||
|
|
@ -1,12 +1,7 @@
|
|||
package kcg.faics.report.web;
|
||||
|
||||
import java.text.SimpleDateFormat;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Date;
|
||||
import java.util.HashMap;
|
||||
import java.util.LinkedHashMap;
|
||||
import java.util.List;
|
||||
import java.util.Locale;
|
||||
import java.util.*;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
|
|
@ -202,21 +197,48 @@ public class ReportStatsController {
|
|||
searchVO = ReportCommon.setSearchUserInfo(searchVO);
|
||||
|
||||
// 분야별 통계
|
||||
|
||||
|
||||
if ("C".equals(searchVO.getStatsType())) {
|
||||
header.put("PLACENAME", messageSource.getMessage("report.view.division", null, locale));
|
||||
header.put("TOTAL", messageSource.getMessage("report.stats.total", null, locale));
|
||||
header.put("placename", messageSource.getMessage("report.view.division", null, locale));
|
||||
header.put("total", messageSource.getMessage("report.stats.total", null, locale));
|
||||
if(reportSearchVO.getCategory1() != null) {
|
||||
for (String category : reportSearchVO.getCategory1()) {
|
||||
header.put(category + "_1", messageSource.getMessage("report.category." + category + "_1", null, locale));
|
||||
}
|
||||
}
|
||||
else {
|
||||
HashMap<String, String> category = cateService.getCategory1();
|
||||
searchVO.setCategory1(category.keySet().toArray(new String[category.size()]));
|
||||
}
|
||||
|
||||
if(reportSearchVO.getCategory2()!=null) {
|
||||
for (String category : reportSearchVO.getCategory2()) {
|
||||
header.put(category + "_2", messageSource.getMessage("report.category." + category + "_2", null, locale));
|
||||
}
|
||||
}
|
||||
else {
|
||||
HashMap<String, String> category = cateService.getCategory2();
|
||||
searchVO.setCategory2(category.keySet().toArray(new String[category.size()]));
|
||||
}
|
||||
if(reportSearchVO.getCategory3()!=null) {
|
||||
for (String category : reportSearchVO.getCategory3()) {
|
||||
header.put(category + "_3", messageSource.getMessage("report.category." + category + "_3", null, locale));
|
||||
}
|
||||
}
|
||||
else {
|
||||
HashMap<String, String> category = cateService.getCategory3();
|
||||
searchVO.setCategory3(category.keySet().toArray(new String[category.size()]));
|
||||
}
|
||||
if(reportSearchVO.getCategory4()!=null) {
|
||||
for (String category : reportSearchVO.getCategory4()) {
|
||||
header.put(category + "_4", messageSource.getMessage("report.category." + category + "_4", null, locale));
|
||||
}
|
||||
}
|
||||
else {
|
||||
HashMap<String, String> category = cateService.getCategory4();
|
||||
searchVO.setCategory4(category.keySet().toArray(new String[category.size()]));
|
||||
}
|
||||
|
||||
try {
|
||||
Date d = new Date();
|
||||
|
|
@ -232,7 +254,7 @@ public class ReportStatsController {
|
|||
searchVO.setPlaces(placeList.toArray(new String[placeList.size()]));
|
||||
}
|
||||
|
||||
// 분류 아무것도 선택하지 않은 경우 모두 세팅
|
||||
/* // 분류 아무것도 선택하지 않은 경우 모두 세팅
|
||||
if (searchVO.isSearchCate1() && searchVO.getCategory1().length == 0) {
|
||||
HashMap<String, String> category = cateService.getCategory1();
|
||||
searchVO.setCategory1(category.keySet().toArray(new String[category.size()]));
|
||||
|
|
@ -248,7 +270,7 @@ public class ReportStatsController {
|
|||
if (searchVO.isSearchCate1() && searchVO.getCategory4().length == 0) {
|
||||
HashMap<String, String> category = cateService.getCategory4();
|
||||
searchVO.setCategory4(category.keySet().toArray(new String[category.size()]));
|
||||
}
|
||||
}*/
|
||||
|
||||
List<HashMap<String, String>> list = judgeService.statsCategory(searchVO);
|
||||
|
||||
|
|
@ -259,23 +281,23 @@ public class ReportStatsController {
|
|||
e.printStackTrace();
|
||||
}
|
||||
} else if ("J".equals(searchVO.getStatsType())) {
|
||||
header.put("PLACENAME", messageSource.getMessage("report.view.division", null, locale));
|
||||
header.put("placename", messageSource.getMessage("report.view.division", null, locale));
|
||||
|
||||
header.put("REPORT1", messageSource.getMessage("report.type.fullReport1", null, locale));
|
||||
header.put("REPORT2", messageSource.getMessage("report.type.fullReport2", null, locale));
|
||||
header.put("report1", messageSource.getMessage("report.type.fullReport1", null, locale));
|
||||
header.put("report2", messageSource.getMessage("report.type.fullReport2", null, locale));
|
||||
|
||||
header.put("JU1", messageSource.getMessage("report.type.newsflash", null, locale));
|
||||
header.put("JU2", messageSource.getMessage("report.type.judge", null, locale));
|
||||
header.put("JU3", messageSource.getMessage("report.type.middle", null, locale));
|
||||
header.put("JU4", messageSource.getMessage("report.type.notice", null, locale));
|
||||
header.put("JU5", messageSource.getMessage("report.type.record", null, locale));
|
||||
header.put("JU6", messageSource.getMessage("report.type.survey", null, locale));
|
||||
header.put("JU7", messageSource.getMessage("report.type.reference", null, locale));
|
||||
header.put("ju1", messageSource.getMessage("report.type.newsflash", null, locale));
|
||||
header.put("ju2", messageSource.getMessage("report.type.judge", null, locale));
|
||||
header.put("ju3", messageSource.getMessage("report.type.middle", null, locale));
|
||||
header.put("ju4", messageSource.getMessage("report.type.notice", null, locale));
|
||||
header.put("ju5", messageSource.getMessage("report.type.record", null, locale));
|
||||
header.put("ju6", messageSource.getMessage("report.type.survey", null, locale));
|
||||
header.put("ju7", messageSource.getMessage("report.type.reference", null, locale));
|
||||
|
||||
header.put("AG", messageSource.getMessage("report.stats.AGrade", null, locale));
|
||||
header.put("BG", messageSource.getMessage("report.stats.BGrade", null, locale));
|
||||
header.put("CG", messageSource.getMessage("report.stats.CGrade", null, locale));
|
||||
header.put("DG", messageSource.getMessage("report.stats.DGrade", null, locale));
|
||||
header.put("ag", messageSource.getMessage("report.stats.AGrade", null, locale));
|
||||
header.put("bg", messageSource.getMessage("report.stats.BGrade", null, locale));
|
||||
header.put("cg", messageSource.getMessage("report.stats.CGrade", null, locale));
|
||||
header.put("dg", messageSource.getMessage("report.stats.DGrade", null, locale));
|
||||
|
||||
Date d = new Date();
|
||||
SimpleDateFormat sdf = new SimpleDateFormat("yyyyMMdd");
|
||||
|
|
|
|||
|
|
@ -99,8 +99,8 @@ public class LoginSuccessHandler implements AuthenticationSuccessHandler {
|
|||
String head = null;
|
||||
String section = null;
|
||||
if (rptApprove != null) {
|
||||
head = (String) rptApprove.get("HEAD");
|
||||
section = (String) rptApprove.get("SECTION");
|
||||
head = (String) rptApprove.get("head");
|
||||
section = (String) rptApprove.get("section");
|
||||
}
|
||||
/* 계장? */
|
||||
user.setAuthHead(head != null && head.equals(userId) ? 1 : 0);
|
||||
|
|
@ -113,10 +113,10 @@ public class LoginSuccessHandler implements AuthenticationSuccessHandler {
|
|||
int authCode = 0;
|
||||
if (rptAu != null) {
|
||||
|
||||
if (rptAu.get("CODE") == null) {
|
||||
if (rptAu.get("code") == null) {
|
||||
authCode = 32;
|
||||
} else {
|
||||
authCode = Integer.parseInt(rptAu.get("CODE").toString());
|
||||
authCode = Integer.parseInt(rptAu.get("code").toString());
|
||||
}
|
||||
}
|
||||
user.setAuthCode(authCode);
|
||||
|
|
@ -170,8 +170,8 @@ public class LoginSuccessHandler implements AuthenticationSuccessHandler {
|
|||
/* 관리자? */
|
||||
int roleLev = user.getRolelevel();
|
||||
user.setAuthAdmin((roleLev <= propertiesService.getInt("adminLevel")) ? 1 : 0);
|
||||
user.setIsAdmin((roleLev <= propertiesService.getInt("adminLevel")) ? true : false);
|
||||
user.setIsSysAdmin((roleLev <= propertiesService.getInt("sysAdminLevel")) || propertiesService.getString("sysAdminId").equals(userId) ? true : false);
|
||||
user.setIsAdmin(roleLev <= propertiesService.getInt("adminLevel"));
|
||||
user.setIsSysAdmin((roleLev <= propertiesService.getInt("sysAdminLevel")) || propertiesService.getString("sysAdminId").equals(userId));
|
||||
|
||||
/* 로그인 실패횟수 초기화 */
|
||||
MemberVO memberVO = new MemberVO();
|
||||
|
|
|
|||
|
|
@ -11,6 +11,7 @@ import kcg.faics.member.vo.MemberVO;
|
|||
import kcg.faics.sec.LoginUserVO;
|
||||
import kcg.faics.sec.role.SecurityRolesVO;
|
||||
|
||||
import org.springframework.beans.factory.annotation.Value;
|
||||
import org.springframework.security.access.ConfigAttribute;
|
||||
import org.springframework.security.access.SecurityConfig;
|
||||
import org.springframework.security.web.util.matcher.AntPathRequestMatcher;
|
||||
|
|
@ -33,7 +34,6 @@ import egovframework.rte.psl.dataaccess.EgovAbstractMapper;
|
|||
@Repository("securityMapper")
|
||||
public class SecurityMapper extends EgovAbstractMapper {
|
||||
|
||||
|
||||
/**
|
||||
* 외사경찰 사용자 정보를 가져온다.
|
||||
*
|
||||
|
|
@ -85,13 +85,14 @@ public class SecurityMapper extends EgovAbstractMapper {
|
|||
public String getHierarchyRoles() {
|
||||
List<Map<String, Object>> resultList = selectList("Security.getHierarchyRoles");
|
||||
Iterator<Map<String, Object>> itr = resultList.iterator();
|
||||
StringBuffer concatedRoles = new StringBuffer();
|
||||
|
||||
StringBuilder concatedRoles = new StringBuilder();
|
||||
Map<String, Object> tempMap;
|
||||
while (itr.hasNext()) {
|
||||
tempMap = itr.next();
|
||||
concatedRoles.append(tempMap.get("CHILD"));
|
||||
concatedRoles.append(tempMap.get("child"));
|
||||
concatedRoles.append(" > ");
|
||||
concatedRoles.append(tempMap.get("PARENT"));
|
||||
concatedRoles.append(tempMap.get("parent"));
|
||||
concatedRoles.append("\n");
|
||||
}
|
||||
return concatedRoles.toString();
|
||||
|
|
@ -140,7 +141,8 @@ public class SecurityMapper extends EgovAbstractMapper {
|
|||
* SecuredObjectDAO, SecuredObjectServiceImpl을 참조해서 변경한다.
|
||||
* */
|
||||
boolean isResourcesUrl = true;
|
||||
String resourceType = "URL";
|
||||
|
||||
String resourceType ="url";
|
||||
|
||||
LinkedHashMap<Object, List<ConfigAttribute>> resourcesMap = new LinkedHashMap<Object, List<ConfigAttribute>>();
|
||||
Iterator<Map<String, Object>> itr = list.iterator();
|
||||
|
|
@ -175,7 +177,7 @@ public class SecurityMapper extends EgovAbstractMapper {
|
|||
}
|
||||
}
|
||||
|
||||
configList.add(new SecurityConfig((String) tempMap.get("AUTHORITY")));
|
||||
configList.add(new SecurityConfig((String) tempMap.get("authority")));
|
||||
|
||||
resourcesMap.put(presentResource, configList);
|
||||
|
||||
|
|
@ -196,7 +198,7 @@ public class SecurityMapper extends EgovAbstractMapper {
|
|||
/**
|
||||
* 차단 정보를 업데이트한다.
|
||||
*
|
||||
* @param loginUserVO 로그인 사용자 객체
|
||||
* @param memberVO 로그인 사용자 객체
|
||||
* @return 성공 - 1, 실패 - 0
|
||||
*/
|
||||
public int updateChkInfo(MemberVO memberVO) {
|
||||
|
|
|
|||
|
|
@ -253,10 +253,8 @@ public class PromotController {
|
|||
promotVO.setWriter(loginUserVO.getUserid());
|
||||
|
||||
// 파일 저장 및 데이터 입력
|
||||
final Map<String, MultipartFile> fileMap = multiRequest
|
||||
.getFileMap();
|
||||
HashMap<String, Object> map = susaService.insert(promotVO,
|
||||
fileMap);
|
||||
final Map<String, MultipartFile> fileMap = multiRequest.getFileMap();
|
||||
HashMap<String, Object> map = susaService.insert(promotVO, fileMap);
|
||||
|
||||
status.setComplete();
|
||||
|
||||
|
|
|
|||
|
|
@ -0,0 +1,96 @@
|
|||
package kcg.faics.tg;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 항로 타입.
|
||||
*
|
||||
* @author kimnomin
|
||||
*
|
||||
*/
|
||||
public enum FerryRouteType {
|
||||
/**
|
||||
* 한-중.
|
||||
*/
|
||||
KR_CH("A", "한-중"),
|
||||
/**
|
||||
* 한-러.
|
||||
*/
|
||||
KR_RU("B", "한-러"),
|
||||
/**
|
||||
* 한-일.
|
||||
*/
|
||||
KR_JP("C", "한-일"),
|
||||
/**
|
||||
* 북한.
|
||||
*/
|
||||
KP("D", "북한");
|
||||
|
||||
/**
|
||||
* code.
|
||||
*/
|
||||
private final String code;
|
||||
/**
|
||||
* value.
|
||||
*/
|
||||
private final String value;
|
||||
/**
|
||||
* @return the code
|
||||
*/
|
||||
public final String getCode() {
|
||||
return code;
|
||||
}
|
||||
/**
|
||||
* @return the value
|
||||
*/
|
||||
public final String getValue() {
|
||||
return value;
|
||||
}
|
||||
/**
|
||||
* code에 해당하는 value를 반환한다.
|
||||
*
|
||||
* @param code code
|
||||
* @return value
|
||||
*/
|
||||
public static final String getValue(final String code) {
|
||||
String value = "";
|
||||
|
||||
for (FerryRouteType item: FerryRouteType.values()) {
|
||||
if (item.getCode().equalsIgnoreCase(code)) {
|
||||
value = item.getValue();
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
return value;
|
||||
}
|
||||
|
||||
/**
|
||||
* exclude를 제외한 List를 반환한다.
|
||||
*
|
||||
* @param exclude 제외할 타입
|
||||
* @return List
|
||||
*/
|
||||
public static final List<FerryRouteType> values(final FerryRouteType... exclude) {
|
||||
List<FerryRouteType> list = new ArrayList<FerryRouteType>();
|
||||
for (FerryRouteType item : values()) {
|
||||
if (!Arrays.asList(exclude).contains(item)) {
|
||||
list.add(item);
|
||||
}
|
||||
}
|
||||
return list;
|
||||
}
|
||||
|
||||
/**
|
||||
* 생성자.
|
||||
*
|
||||
* @param code 코드값
|
||||
* @param value 표출값
|
||||
*/
|
||||
FerryRouteType(final String code, final String value) {
|
||||
this.code = code;
|
||||
this.value = value;
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,68 @@
|
|||
package kcg.faics.tg;
|
||||
|
||||
/**
|
||||
* 국제여객선 운항횟수 타입.
|
||||
*
|
||||
* @author kimnomin
|
||||
*
|
||||
*/
|
||||
public enum FerryRunTermType {
|
||||
/**
|
||||
* 주.
|
||||
*/
|
||||
WEEK("A", "주"),
|
||||
/**
|
||||
* 일.
|
||||
*/
|
||||
DAY("B", "일");
|
||||
|
||||
/**
|
||||
* code.
|
||||
*/
|
||||
private final String code;
|
||||
/**
|
||||
* value.
|
||||
*/
|
||||
private final String value;
|
||||
|
||||
/**
|
||||
* @return the code
|
||||
*/
|
||||
public final String getCode() {
|
||||
return code;
|
||||
}
|
||||
/**
|
||||
* @return the value
|
||||
*/
|
||||
public final String getValue() {
|
||||
return value;
|
||||
}
|
||||
/**
|
||||
* code에 해당하는 value를 반환한다.
|
||||
*
|
||||
* @param code code
|
||||
* @return value
|
||||
*/
|
||||
public static final String getValue(final String code) {
|
||||
String value = "";
|
||||
|
||||
for (FerryRunTermType item: FerryRunTermType.values()) {
|
||||
if (item.getCode().equalsIgnoreCase(code)) {
|
||||
value = item.getValue();
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
return value;
|
||||
}
|
||||
/**
|
||||
* 생성자.
|
||||
*
|
||||
* @param code 코드값
|
||||
* @param value 표출값
|
||||
*/
|
||||
FerryRunTermType(final String code, final String value) {
|
||||
this.code = code;
|
||||
this.value = value;
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,8 @@
|
|||
/**
|
||||
* 외사대상목표 패키지.
|
||||
*/
|
||||
/**
|
||||
* @author kimnomin
|
||||
*
|
||||
*/
|
||||
package kcg.faics.tg;
|
||||
|
|
@ -0,0 +1,25 @@
|
|||
package kcg.faics.tg.service;
|
||||
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
|
||||
import kcg.faics.cmmn.bbs.BaseBbsService;
|
||||
import kcg.faics.tg.vo.CorpSearchVO;
|
||||
import kcg.faics.tg.vo.CorpVO;
|
||||
|
||||
/**
|
||||
* 치안대상 관련 인터페이스.
|
||||
*
|
||||
* @author kimnomin
|
||||
*
|
||||
*/
|
||||
public interface CorpService extends BaseBbsService<CorpSearchVO, CorpVO> {
|
||||
/**
|
||||
* 치안대상 통계현황을 반환한다.
|
||||
*
|
||||
* @return 치안대상 통계현황
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
List<HashMap<String, Object>> selectStats() throws Exception;
|
||||
}
|
||||
|
|
@ -0,0 +1,37 @@
|
|||
package kcg.faics.tg.service;
|
||||
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
|
||||
import kcg.faics.cmmn.bbs.BaseBbsService;
|
||||
import kcg.faics.tg.vo.WeakPlaceSearchVO;
|
||||
import kcg.faics.tg.vo.WeakPlaceVO;
|
||||
|
||||
/**
|
||||
* 외사취약지 관련 인터페이스.
|
||||
*
|
||||
* @author kimnomin
|
||||
*
|
||||
*/
|
||||
public interface WeakPlaceService extends
|
||||
BaseBbsService<WeakPlaceSearchVO, WeakPlaceVO> {
|
||||
/**
|
||||
* 소속별 외사취약지 통계현황을 반환한다.
|
||||
*
|
||||
* @return 소속별 외사취약지 통계현황
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
List<HashMap<String, Object>> selectStatsPerPlace() throws Exception;
|
||||
|
||||
/**
|
||||
* 해당 소속의 마지막 외사취약지 일련번호를 반환한다.
|
||||
*
|
||||
* @param place1
|
||||
* 소속
|
||||
* @return 마지막 외사취약지 일련번호
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
int selectMaxWpNo(String place1) throws Exception;
|
||||
}
|
||||
|
|
@ -0,0 +1,109 @@
|
|||
package kcg.faics.tg.service.impl;
|
||||
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
|
||||
import kcg.faics.tg.vo.CorpSearchVO;
|
||||
import kcg.faics.tg.vo.CorpVO;
|
||||
|
||||
import org.springframework.stereotype.Repository;
|
||||
|
||||
import egovframework.rte.psl.dataaccess.EgovAbstractMapper;
|
||||
|
||||
/**
|
||||
* 치안대상 관련 Mapper 클래스.
|
||||
*
|
||||
* @author kimnomin
|
||||
*
|
||||
*/
|
||||
@Repository("corpMapper")
|
||||
public class CorpMapper extends EgovAbstractMapper {
|
||||
|
||||
/**
|
||||
* 치안대상 정보를 반환한다.
|
||||
*
|
||||
* @param corpVO
|
||||
* 치안대상 VO
|
||||
* @return 치안대상 정보
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
public CorpVO select(final CorpVO corpVO) throws Exception {
|
||||
return selectOne("Corp.select", corpVO);
|
||||
}
|
||||
|
||||
/**
|
||||
* 치안대상 목록을 반환한다.
|
||||
*
|
||||
* @param searchVO
|
||||
* 검색조건 VO
|
||||
* @return 치안대상 목록
|
||||
*/
|
||||
public List<CorpVO> selectList(final CorpSearchVO searchVO) {
|
||||
return selectList("Corp.selectList", searchVO);
|
||||
}
|
||||
|
||||
/**
|
||||
* 치안대상 통계현황을 반환한다.
|
||||
*
|
||||
* @param map
|
||||
* 조건 Map 객체
|
||||
* @return 치안대상 통계현황
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
public List<HashMap<String, Object>> selectStats(final HashMap<String, Object> map)
|
||||
throws Exception {
|
||||
return selectList("Corp.selectStats", map);
|
||||
}
|
||||
|
||||
/**
|
||||
* 치안대상 정보를 입력한다.
|
||||
*
|
||||
* @param corpVO
|
||||
* 입력할 치안대상 VO
|
||||
* @return <code>1</code> 성공, <code>0</code> 실패
|
||||
*/
|
||||
public int insert(final CorpVO corpVO) {
|
||||
return insert("Corp.insert", corpVO);
|
||||
}
|
||||
|
||||
/**
|
||||
* orgNo의 최대값을 반환한다.
|
||||
*
|
||||
* @param corpVO
|
||||
* 치안대상 VO
|
||||
* @return orgNo 최대값
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
public int selectMaxOrgNo(final CorpVO corpVO) throws Exception {
|
||||
return selectOne("Corp.selectMaxOrgNo", corpVO);
|
||||
}
|
||||
|
||||
/**
|
||||
* 치안대상 정보를 삭제한다.
|
||||
*
|
||||
* @param corpVO
|
||||
* 치안대상 VO
|
||||
* @return <code>1</code>성공, <code>0</code>실패
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
public int delete(final CorpVO corpVO) throws Exception {
|
||||
return delete("Corp.delete", corpVO);
|
||||
}
|
||||
|
||||
/**
|
||||
* 치안대상 정보를 수정한다.
|
||||
*
|
||||
* @param corpVO
|
||||
* 치안대상 VO
|
||||
* @return <code>1</code>성공, <code>0</code>실패
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
public int update(final CorpVO corpVO) throws Exception {
|
||||
return update("Corp.update", corpVO);
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,128 @@
|
|||
package kcg.faics.tg.service.impl;
|
||||
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
|
||||
import kcg.faics.cmmn.egov.file.EgovFileMngUtil;
|
||||
import kcg.faics.cmmn.service.CodeService;
|
||||
import kcg.faics.tg.service.CorpService;
|
||||
import kcg.faics.tg.vo.CorpSearchVO;
|
||||
import kcg.faics.tg.vo.CorpVO;
|
||||
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
|
||||
import egovframework.rte.fdl.cmmn.EgovAbstractServiceImpl;
|
||||
|
||||
/**
|
||||
* 치안대상 관련 비지니스로직.
|
||||
*
|
||||
* @author kimnomin
|
||||
*
|
||||
*/
|
||||
@Service("corpService")
|
||||
public class CorpServiceImpl extends EgovAbstractServiceImpl implements CorpService {
|
||||
/**
|
||||
* 전자정부프레임워크에서 제공되는 파일 업로드 처리 관련 Utility.
|
||||
**/
|
||||
@Resource(name = "EgovFileMngUtil")
|
||||
private EgovFileMngUtil fileUtil;
|
||||
|
||||
/**
|
||||
* 치안대상 Mapper 클래스.
|
||||
*/
|
||||
@Resource(name = "corpMapper")
|
||||
private CorpMapper corpMapper;
|
||||
|
||||
|
||||
/**
|
||||
* orgNo의 최대값을 반환한다.
|
||||
*
|
||||
* @param corpVO
|
||||
* 치안대상 VO
|
||||
* @return orgNo 최대값
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
private int selectNextOrgNo(final CorpVO corpVO) throws Exception {
|
||||
int result = 1;
|
||||
try {
|
||||
result = corpMapper.selectMaxOrgNo(corpVO) + 1;
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
@Override
|
||||
public CorpVO select(final CorpVO dataVO) throws Exception {
|
||||
return corpMapper.select(dataVO);
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<CorpVO> selectListAll(final CorpSearchVO searchVO) throws Exception {
|
||||
// TODO Auto-generated method stub
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<CorpVO> selectList(final CorpSearchVO searchVO) throws Exception {
|
||||
if (CodeService.LIST_ALL_VAL.equalsIgnoreCase(searchVO.getPlace1())) {
|
||||
searchVO.setPlace1("");
|
||||
}
|
||||
return corpMapper.selectList(searchVO);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int selectListCnt(final CorpSearchVO searchVO) throws Exception {
|
||||
// TODO Auto-generated method stub
|
||||
return 0;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int selectTotalCnt(final CorpSearchVO searchVO) throws Exception {
|
||||
// TODO Auto-generated method stub
|
||||
return 0;
|
||||
}
|
||||
|
||||
@Override
|
||||
public HashMap<String, Object> insert(final CorpVO dataVO,
|
||||
final Map<String, MultipartFile> fileMap) throws Exception {
|
||||
int nextOrgNo = selectNextOrgNo(dataVO);
|
||||
dataVO.setOrgNo(nextOrgNo);
|
||||
|
||||
HashMap<String, Object> map = new HashMap<String, Object>();
|
||||
map.put("result", corpMapper.insert(dataVO));
|
||||
|
||||
return map;
|
||||
}
|
||||
|
||||
@Override
|
||||
public HashMap<String, Object> update(final CorpVO dataVO,
|
||||
final Map<String, MultipartFile> fileMap, final String[] deleteFiles)
|
||||
throws Exception {
|
||||
HashMap<String, Object> map = new HashMap<String, Object>();
|
||||
map.put("result", corpMapper.update(dataVO));
|
||||
|
||||
return map;
|
||||
}
|
||||
|
||||
@Override
|
||||
public HashMap<String, Object> delete(final CorpVO dataVO) throws Exception {
|
||||
HashMap<String, Object> map = new HashMap<String, Object>();
|
||||
map.put("result", corpMapper.delete(dataVO));
|
||||
|
||||
return map;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<HashMap<String, Object>> selectStats() throws Exception {
|
||||
HashMap<String, Object> map = new HashMap<String, Object>();
|
||||
map.put("placeList", CodeService.POLICE_STATION_LIST);
|
||||
|
||||
return corpMapper.selectStats(map);
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,94 @@
|
|||
package kcg.faics.tg.service.impl;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import kcg.faics.tg.vo.DivMngSearchVO;
|
||||
import kcg.faics.tg.vo.DivMngVO;
|
||||
|
||||
import org.springframework.stereotype.Repository;
|
||||
|
||||
import egovframework.rte.psl.dataaccess.EgovAbstractMapper;
|
||||
|
||||
/**
|
||||
* 외사분실운영현황 관련 Mapper 클래스.
|
||||
*
|
||||
* @author kimnomin
|
||||
*
|
||||
*/
|
||||
@Repository("divMngMapper")
|
||||
public class DivMngMapper extends EgovAbstractMapper {
|
||||
|
||||
/**
|
||||
* 외사분실운영현황 정보를 반환한다.
|
||||
*
|
||||
* @param vo
|
||||
* 외사분실운영현황 VO
|
||||
* @return 외사분실운영현황 정보
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
public DivMngVO select(final DivMngVO vo) throws Exception {
|
||||
return selectOne("DivMng.select", vo);
|
||||
}
|
||||
|
||||
/**
|
||||
* 외사분실운영현황 목록을 반환한다.
|
||||
*
|
||||
* @param searchVO
|
||||
* 검색조건 VO
|
||||
* @return 치안대상 목록
|
||||
*/
|
||||
public List<DivMngVO> selectList(final DivMngSearchVO searchVO) {
|
||||
return selectList("DivMng.selectList", searchVO);
|
||||
}
|
||||
|
||||
/**
|
||||
* 외사분실운영현황 정보를 입력한다.
|
||||
*
|
||||
* @param vo
|
||||
* 입력할 외사분실운영현황 VO
|
||||
* @return <code>1</code> 성공, <code>0</code> 실패
|
||||
*/
|
||||
public int insert(final DivMngVO vo) {
|
||||
return insert("DivMng.insert", vo);
|
||||
}
|
||||
|
||||
/**
|
||||
* 외사분실운영현황 정보를 삭제한다.
|
||||
*
|
||||
* @param vo
|
||||
* 외사분실운영현황 VO
|
||||
* @return <code>1</code>성공, <code>0</code>실패
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
public int delete(final DivMngVO vo) throws Exception {
|
||||
return delete("DivMng.delete", vo);
|
||||
}
|
||||
|
||||
/**
|
||||
* 외사분실운영현황 정보를 수정한다.
|
||||
*
|
||||
* @param vo
|
||||
* 외사분실운영현황 VO
|
||||
* @return <code>1</code>성공, <code>0</code>실패
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
public int update(final DivMngVO vo) throws Exception {
|
||||
return update("DivMng.update", vo);
|
||||
}
|
||||
|
||||
/**
|
||||
* Place별 DS_NO의 최대값을 반환한다.
|
||||
*
|
||||
* @param vo
|
||||
* 외사분실운영현황 VO
|
||||
* @return place별 최대 DS_NO 값
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
public int selectMaxNo(final DivMngVO vo) throws Exception {
|
||||
return selectOne("DivMng.selectMaxNo", vo);
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,224 @@
|
|||
package kcg.faics.tg.service.impl;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Arrays;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
|
||||
import kcg.faics.cmmn.bbs.BaseBbsService;
|
||||
import kcg.faics.cmmn.egov.file.EgovFileMngUtil;
|
||||
import kcg.faics.cmmn.egov.vo.FileVO;
|
||||
import kcg.faics.cmmn.service.CodeService;
|
||||
import kcg.faics.tg.vo.DivMngSearchVO;
|
||||
import kcg.faics.tg.vo.DivMngVO;
|
||||
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
|
||||
import egovframework.rte.fdl.cmmn.EgovAbstractServiceImpl;
|
||||
|
||||
/**
|
||||
* 외사분실운영현황 관련 비지니스로직.
|
||||
*
|
||||
* @author kimnomin
|
||||
*
|
||||
*/
|
||||
@Service("divMngService")
|
||||
public class DivMngServiceImpl extends EgovAbstractServiceImpl implements
|
||||
BaseBbsService<DivMngSearchVO, DivMngVO> {
|
||||
|
||||
/**
|
||||
* property 파일에서 읽은 저장 경로 키워드.
|
||||
*/
|
||||
public static final String FILE_PATH_KEYWORD = "Target.divmng.fileStorePath";
|
||||
|
||||
/**
|
||||
* 전자정부프레임워크에서 제공되는 파일 업로드 처리 관련 Utility.
|
||||
**/
|
||||
@Resource(name = "EgovFileMngUtil")
|
||||
private EgovFileMngUtil fileUtil;
|
||||
|
||||
/**
|
||||
* 외사분실운영현황 Mapper 클래스.
|
||||
*/
|
||||
@Resource(name = "divMngMapper")
|
||||
private DivMngMapper divMngMapper;
|
||||
|
||||
/**
|
||||
* Place별 다음에 사용할 DS_NO를 반환한다.
|
||||
*
|
||||
* @param divMngVO
|
||||
* 외사분실운영현황 VO
|
||||
* @return place별 최대 DS_NO+1
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
private int selectNextNo(final DivMngVO divMngVO) throws Exception {
|
||||
int result = 1;
|
||||
try {
|
||||
result = divMngMapper.selectMaxNo(divMngVO) + 1;
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
@Override
|
||||
public DivMngVO select(final DivMngVO dataVO) throws Exception {
|
||||
return divMngMapper.select(dataVO);
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<DivMngVO> selectListAll(final DivMngSearchVO searchVO)
|
||||
throws Exception {
|
||||
// TODO Auto-generated method stub
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<DivMngVO> selectList(final DivMngSearchVO searchVO) throws Exception {
|
||||
if (CodeService.LIST_ALL_VAL.equalsIgnoreCase(searchVO.getPlace())) {
|
||||
searchVO.setPlace("");
|
||||
}
|
||||
return divMngMapper.selectList(searchVO);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int selectListCnt(final DivMngSearchVO searchVO) throws Exception {
|
||||
// TODO Auto-generated method stub
|
||||
return 0;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int selectTotalCnt(final DivMngSearchVO searchVO) throws Exception {
|
||||
// TODO Auto-generated method stub
|
||||
return 0;
|
||||
}
|
||||
|
||||
@Override
|
||||
public HashMap<String, Object> insert(final DivMngVO dataVO,
|
||||
final Map<String, MultipartFile> fileMap) throws Exception {
|
||||
HashMap<String, Object> map = new HashMap<String, Object>();
|
||||
int no = selectNextNo(dataVO);
|
||||
if (no > 0) {
|
||||
dataVO.setNo(no);
|
||||
|
||||
List<FileVO> fileList = fileUtil.parseFileInf(fileMap, null, 0, "", FILE_PATH_KEYWORD);
|
||||
for (FileVO fileVO : fileList) {
|
||||
if ("fileImgObj".equalsIgnoreCase(fileVO.getFileSn())) {
|
||||
dataVO.setFileImg(fileVO.getStreFileNm());
|
||||
} else if ("file1obj".equalsIgnoreCase(fileVO.getFileSn())) {
|
||||
dataVO.setFile1(fileVO.getStreFileNm());
|
||||
} else if ("file2obj".equalsIgnoreCase(fileVO.getFileSn())) {
|
||||
dataVO.setFile2(fileVO.getStreFileNm());
|
||||
} else if ("file3obj".equalsIgnoreCase(fileVO.getFileSn())) {
|
||||
dataVO.setFile3(fileVO.getStreFileNm());
|
||||
}
|
||||
}
|
||||
|
||||
map.put("result", divMngMapper.insert(dataVO));
|
||||
} else {
|
||||
map.put("result", 0);
|
||||
}
|
||||
|
||||
return map;
|
||||
}
|
||||
|
||||
/**
|
||||
* Update시 파일삭제 대상을 판별한다.
|
||||
*
|
||||
* @param fileMap 파일 Map 객체
|
||||
* @param fileMapKey 파일 Map 객체에서 추출할 key
|
||||
* @param deleteFileList 삭제대상 목록
|
||||
* @param deleteFileListKey 삭제대상 목록에서 추출할 문자열
|
||||
* @return 파일삭제여부
|
||||
*/
|
||||
private boolean isRemoveTarget(final Map<String, MultipartFile> fileMap,
|
||||
final String fileMapKey, final List<String> deleteFileList,
|
||||
final String deleteFileListKey) {
|
||||
boolean isRemoveTarget = false;
|
||||
|
||||
if (deleteFileList.contains(deleteFileListKey)
|
||||
|| (fileMap.containsKey(fileMapKey) && fileMap.get(fileMapKey).getSize() > 0)) {
|
||||
isRemoveTarget = true;
|
||||
}
|
||||
|
||||
return isRemoveTarget;
|
||||
}
|
||||
|
||||
@Override
|
||||
public HashMap<String, Object> update(final DivMngVO dataVO,
|
||||
final Map<String, MultipartFile> fileMap, final String[] deleteFiles)
|
||||
throws Exception {
|
||||
DivMngVO vo = select(dataVO);
|
||||
dataVO.setFileImg(vo.getFileImg());
|
||||
dataVO.setFile1(vo.getFile1());
|
||||
dataVO.setFile2(vo.getFile2());
|
||||
dataVO.setFile3(vo.getFile3());
|
||||
|
||||
List<String> deleteFileList = new ArrayList<String>();
|
||||
if (deleteFiles != null) {
|
||||
deleteFileList = Arrays.asList(deleteFiles);
|
||||
}
|
||||
if (isRemoveTarget(fileMap, "fileImgObj", deleteFileList, "fileImg")) {
|
||||
fileUtil.deleteFile(vo.getFileImg(), FILE_PATH_KEYWORD);
|
||||
dataVO.setFileImg("");
|
||||
}
|
||||
if (isRemoveTarget(fileMap, "file1obj", deleteFileList, "file1")) {
|
||||
fileUtil.deleteFile(vo.getFile1(), FILE_PATH_KEYWORD);
|
||||
dataVO.setFile1("");
|
||||
}
|
||||
if (isRemoveTarget(fileMap, "file2obj", deleteFileList, "file2")) {
|
||||
fileUtil.deleteFile(vo.getFile2(), FILE_PATH_KEYWORD);
|
||||
dataVO.setFile2("");
|
||||
}
|
||||
if (isRemoveTarget(fileMap, "file3obj", deleteFileList, "file3")) {
|
||||
fileUtil.deleteFile(vo.getFile3(), FILE_PATH_KEYWORD);
|
||||
dataVO.setFile3("");
|
||||
}
|
||||
|
||||
List<FileVO> fileList = fileUtil.parseFileInf(fileMap, null, 0, "", FILE_PATH_KEYWORD);
|
||||
for (FileVO fileVO : fileList) {
|
||||
if ("fileImgObj".equalsIgnoreCase(fileVO.getFileSn())) {
|
||||
dataVO.setFileImg(fileVO.getStreFileNm());
|
||||
} else if ("file1obj".equalsIgnoreCase(fileVO.getFileSn())) {
|
||||
dataVO.setFile1(fileVO.getStreFileNm());
|
||||
} else if ("file2obj".equalsIgnoreCase(fileVO.getFileSn())) {
|
||||
dataVO.setFile2(fileVO.getStreFileNm());
|
||||
} else if ("file3obj".equalsIgnoreCase(fileVO.getFileSn())) {
|
||||
dataVO.setFile3(fileVO.getStreFileNm());
|
||||
}
|
||||
}
|
||||
|
||||
HashMap<String, Object> map = new HashMap<String, Object>();
|
||||
map.put("result", divMngMapper.update(dataVO));
|
||||
|
||||
return map;
|
||||
}
|
||||
|
||||
@Override
|
||||
public HashMap<String, Object> delete(final DivMngVO dataVO) throws Exception {
|
||||
DivMngVO vo = select(dataVO);
|
||||
HashMap<String, Object> map = new HashMap<String, Object>();
|
||||
map.put("result", divMngMapper.delete(dataVO));
|
||||
|
||||
if (StringUtils.isNotBlank(vo.getFileImg())) {
|
||||
fileUtil.deleteFile(vo.getFileImg(), FILE_PATH_KEYWORD);
|
||||
}
|
||||
if (StringUtils.isNotBlank(vo.getFile1())) {
|
||||
fileUtil.deleteFile(vo.getFile1(), FILE_PATH_KEYWORD);
|
||||
}
|
||||
if (StringUtils.isNotBlank(vo.getFile2())) {
|
||||
fileUtil.deleteFile(vo.getFile2(), FILE_PATH_KEYWORD);
|
||||
}
|
||||
if (StringUtils.isNotBlank(vo.getFile3())) {
|
||||
fileUtil.deleteFile(vo.getFile3(), FILE_PATH_KEYWORD);
|
||||
}
|
||||
|
||||
return map;
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,94 @@
|
|||
package kcg.faics.tg.service.impl;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import kcg.faics.tg.vo.FerrySearchVO;
|
||||
import kcg.faics.tg.vo.FerryVO;
|
||||
|
||||
import org.springframework.stereotype.Repository;
|
||||
|
||||
import egovframework.rte.psl.dataaccess.EgovAbstractMapper;
|
||||
|
||||
/**
|
||||
* 국제여객선 관련 Mapper 클래스.
|
||||
*
|
||||
* @author kimnomin
|
||||
*
|
||||
*/
|
||||
@Repository("ferryMapper")
|
||||
public class FerryMapper extends EgovAbstractMapper {
|
||||
|
||||
/**
|
||||
* 국제여객선 정보를 반환한다.
|
||||
*
|
||||
* @param vo
|
||||
* 국제여객선 VO
|
||||
* @return 국제여객선 정보
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
public FerryVO select(final FerryVO vo) throws Exception {
|
||||
return selectOne("Ferry.select", vo);
|
||||
}
|
||||
|
||||
/**
|
||||
* 국제여객선 목록을 반환한다.
|
||||
*
|
||||
* @param searchVO
|
||||
* 검색조건 VO
|
||||
* @return 치안대상 목록
|
||||
*/
|
||||
public List<FerryVO> selectList(final FerrySearchVO searchVO) {
|
||||
return selectList("Ferry.selectList", searchVO);
|
||||
}
|
||||
|
||||
/**
|
||||
* 국제여객선 정보를 입력한다.
|
||||
*
|
||||
* @param vo
|
||||
* 입력할 국제여객선 VO
|
||||
* @return <code>1</code> 성공, <code>0</code> 실패
|
||||
*/
|
||||
public int insert(final FerryVO vo) {
|
||||
return insert("Ferry.insert", vo);
|
||||
}
|
||||
|
||||
/**
|
||||
* 국제여객선 정보를 삭제한다.
|
||||
*
|
||||
* @param vo
|
||||
* 국제여객선 VO
|
||||
* @return <code>1</code>성공, <code>0</code>실패
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
public int delete(final FerryVO vo) throws Exception {
|
||||
return delete("Ferry.delete", vo);
|
||||
}
|
||||
|
||||
/**
|
||||
* 국제여객선 정보를 수정한다.
|
||||
*
|
||||
* @param vo
|
||||
* 국제여객선 VO
|
||||
* @return <code>1</code>성공, <code>0</code>실패
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
public int update(final FerryVO vo) throws Exception {
|
||||
return update("Ferry.update", vo);
|
||||
}
|
||||
|
||||
/**
|
||||
* SER_NO의 최대값을 반환한다.
|
||||
*
|
||||
* @param vo
|
||||
* 국제여객선 VO
|
||||
* @return SER_NO 최대 값
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
public int selectMaxSerNo(final FerryVO vo) throws Exception {
|
||||
return selectOne("Ferry.selectMaxSerNo", vo);
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,184 @@
|
|||
package kcg.faics.tg.service.impl;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Arrays;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
|
||||
import kcg.faics.cmmn.bbs.BaseBbsService;
|
||||
import kcg.faics.cmmn.egov.file.EgovFileMngUtil;
|
||||
import kcg.faics.cmmn.egov.vo.FileVO;
|
||||
import kcg.faics.tg.vo.FerrySearchVO;
|
||||
import kcg.faics.tg.vo.FerryVO;
|
||||
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
|
||||
import egovframework.rte.fdl.cmmn.EgovAbstractServiceImpl;
|
||||
|
||||
/**
|
||||
* 국제여객선 관련 비지니스로직.
|
||||
*
|
||||
* @author kimnomin
|
||||
*
|
||||
*/
|
||||
@Service("ferryService")
|
||||
public class FerryServiceImpl extends EgovAbstractServiceImpl implements
|
||||
BaseBbsService<FerrySearchVO, FerryVO> {
|
||||
|
||||
/**
|
||||
* property 파일에서 읽은 저장 경로 키워드.
|
||||
*/
|
||||
public static final String FILE_PATH_KEYWORD = "Target.ferry.fileStorePath";
|
||||
|
||||
/**
|
||||
* 전자정부프레임워크에서 제공되는 파일 업로드 처리 관련 Utility.
|
||||
**/
|
||||
@Resource(name = "EgovFileMngUtil")
|
||||
private EgovFileMngUtil fileUtil;
|
||||
|
||||
/**
|
||||
* 국제여객선 Mapper 클래스.
|
||||
*/
|
||||
@Resource(name = "ferryMapper")
|
||||
private FerryMapper ferryMapper;
|
||||
|
||||
/**
|
||||
* Place별 다음에 사용할 DS_NO를 반환한다.
|
||||
*
|
||||
* @param ferryVO
|
||||
* 국제여객선 VO
|
||||
* @return SER_NO 최대 값+1
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
private int selectNextSerNo(final FerryVO ferryVO) throws Exception {
|
||||
int result = 1;
|
||||
try {
|
||||
result = ferryMapper.selectMaxSerNo(ferryVO) + 1;
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
@Override
|
||||
public FerryVO select(final FerryVO dataVO) throws Exception {
|
||||
return ferryMapper.select(dataVO);
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<FerryVO> selectListAll(final FerrySearchVO searchVO)
|
||||
throws Exception {
|
||||
// TODO Auto-generated method stub
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<FerryVO> selectList(final FerrySearchVO searchVO) throws Exception {
|
||||
return ferryMapper.selectList(searchVO);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int selectListCnt(final FerrySearchVO searchVO) throws Exception {
|
||||
// TODO Auto-generated method stub
|
||||
return 0;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int selectTotalCnt(final FerrySearchVO searchVO) throws Exception {
|
||||
// TODO Auto-generated method stub
|
||||
return 0;
|
||||
}
|
||||
|
||||
@Override
|
||||
public HashMap<String, Object> insert(final FerryVO dataVO,
|
||||
final Map<String, MultipartFile> fileMap) throws Exception {
|
||||
HashMap<String, Object> map = new HashMap<String, Object>();
|
||||
int no = selectNextSerNo(dataVO);
|
||||
if (no > 0) {
|
||||
dataVO.setSerNo(no);
|
||||
|
||||
List<FileVO> fileList = fileUtil.parseFileInf(fileMap, null, 0, "", FILE_PATH_KEYWORD);
|
||||
for (FileVO fileVO : fileList) {
|
||||
if ("imgFileObj".equalsIgnoreCase(fileVO.getFileSn())) {
|
||||
dataVO.setImgFile(fileVO.getStreFileNm());
|
||||
}
|
||||
}
|
||||
|
||||
map.put("result", ferryMapper.insert(dataVO));
|
||||
} else {
|
||||
map.put("result", 0);
|
||||
}
|
||||
|
||||
return map;
|
||||
}
|
||||
|
||||
/**
|
||||
* Update시 파일삭제 대상을 판별한다.
|
||||
*
|
||||
* @param fileMap 파일 Map 객체
|
||||
* @param fileMapKey 파일 Map 객체에서 추출할 key
|
||||
* @param deleteFileList 삭제대상 목록
|
||||
* @param deleteFileListKey 삭제대상 목록에서 추출할 문자열
|
||||
* @return 파일삭제여부
|
||||
*/
|
||||
private boolean isRemoveTarget(final Map<String, MultipartFile> fileMap,
|
||||
final String fileMapKey, final List<String> deleteFileList,
|
||||
final String deleteFileListKey) {
|
||||
boolean isRemoveTarget = false;
|
||||
|
||||
if (deleteFileList.contains(deleteFileListKey)
|
||||
|| (fileMap.containsKey(fileMapKey) && fileMap.get(fileMapKey).getSize() > 0)) {
|
||||
isRemoveTarget = true;
|
||||
}
|
||||
|
||||
return isRemoveTarget;
|
||||
}
|
||||
|
||||
@Override
|
||||
public HashMap<String, Object> update(final FerryVO dataVO,
|
||||
final Map<String, MultipartFile> fileMap, final String[] deleteFiles)
|
||||
throws Exception {
|
||||
FerryVO vo = select(dataVO);
|
||||
dataVO.setImgFile(vo.getImgFile());
|
||||
|
||||
List<String> deleteFileList = new ArrayList<String>();
|
||||
if (deleteFiles != null) {
|
||||
deleteFileList = Arrays.asList(deleteFiles);
|
||||
}
|
||||
if (isRemoveTarget(fileMap, "imgFileObj", deleteFileList, "imgFile")) {
|
||||
fileUtil.deleteFile(vo.getImgFile(), FILE_PATH_KEYWORD);
|
||||
dataVO.setImgFile("");
|
||||
}
|
||||
|
||||
List<FileVO> fileList = fileUtil.parseFileInf(fileMap, null, 0, "", FILE_PATH_KEYWORD);
|
||||
for (FileVO fileVO : fileList) {
|
||||
if ("imgFileObj".equalsIgnoreCase(fileVO.getFileSn())) {
|
||||
dataVO.setImgFile(fileVO.getStreFileNm());
|
||||
}
|
||||
}
|
||||
|
||||
HashMap<String, Object> map = new HashMap<String, Object>();
|
||||
map.put("result", ferryMapper.update(dataVO));
|
||||
|
||||
return map;
|
||||
}
|
||||
|
||||
@Override
|
||||
public HashMap<String, Object> delete(final FerryVO dataVO) throws Exception {
|
||||
FerryVO vo = select(dataVO);
|
||||
HashMap<String, Object> map = new HashMap<String, Object>();
|
||||
map.put("result", ferryMapper.delete(dataVO));
|
||||
|
||||
if (StringUtils.isNotBlank(vo.getImgFile())) {
|
||||
fileUtil.deleteFile(vo.getImgFile(), FILE_PATH_KEYWORD);
|
||||
}
|
||||
|
||||
return map;
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,120 @@
|
|||
package kcg.faics.tg.service.impl;
|
||||
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
|
||||
import kcg.faics.tg.vo.WeakPlaceSearchVO;
|
||||
import kcg.faics.tg.vo.WeakPlaceVO;
|
||||
|
||||
import org.springframework.stereotype.Repository;
|
||||
|
||||
import egovframework.rte.psl.dataaccess.EgovAbstractMapper;
|
||||
|
||||
/**
|
||||
* 외사취약지 관련 Mapper 클래스.
|
||||
*
|
||||
* @author kimnomin
|
||||
*
|
||||
*/
|
||||
@Repository("weakPlaceMapper")
|
||||
public class WeakPlaceMapper extends EgovAbstractMapper {
|
||||
/**
|
||||
* 외사취약지 정보를 반환한다.
|
||||
*
|
||||
* @param vo
|
||||
* 검색정보 VO
|
||||
* @return 외사취약지 VO
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
public WeakPlaceVO select(final WeakPlaceVO vo) throws Exception {
|
||||
return selectOne("WeakPlace.select", vo);
|
||||
}
|
||||
|
||||
/**
|
||||
* 외사취약지 목록을 반환한다.
|
||||
*
|
||||
* @param vo
|
||||
* 검색정보 VO
|
||||
* @return 외사취약지 목록
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
public List<WeakPlaceVO> selectList(final WeakPlaceSearchVO vo)
|
||||
throws Exception {
|
||||
return selectList("WeakPlace.selectList", vo);
|
||||
}
|
||||
|
||||
/**
|
||||
* 해당 소속의 마지막 외사취약지 일련번호를 반환한다.
|
||||
*
|
||||
* @param place1
|
||||
* 소속
|
||||
* @return 마지막 외사취약지 일련번호
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
public int selectMaxWpNo(final String place1) throws Exception {
|
||||
int wpNo = 0;
|
||||
try {
|
||||
wpNo = selectOne("WeakPlace.selectMaxWpNo", place1);
|
||||
} catch (Exception e) {
|
||||
wpNo = 0;
|
||||
}
|
||||
return wpNo;
|
||||
}
|
||||
|
||||
/**
|
||||
* 소속별 외사취약지 통계현황을 반환한다.
|
||||
*
|
||||
* @param placeList
|
||||
* 통계를 산출할 소속 코드 배열
|
||||
* @return 소속별 외사취약지 통계현황
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
public List<HashMap<String, Object>> selectStatsPerPlace(final String[] placeList) throws Exception {
|
||||
HashMap<String, String[]> map = new HashMap<String, String[]>();
|
||||
map.put("placeList", placeList);
|
||||
return selectList("WeakPlace.selectStatsPerPlace", map);
|
||||
}
|
||||
|
||||
/**
|
||||
* 외사취약지 정보를 입력한다.
|
||||
*
|
||||
* @param weakPlaceVO
|
||||
* 입력할 외사취약지 VO
|
||||
* @return 1-성공, 0-실패
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
public int insert(final WeakPlaceVO weakPlaceVO) throws Exception {
|
||||
return insert("WeakPlace.insert", weakPlaceVO);
|
||||
}
|
||||
|
||||
/**
|
||||
* 외사취약지 정보를 수정한다.
|
||||
*
|
||||
* @param weakPlaceVO
|
||||
* 수정할 외사취약지 VO
|
||||
* @return 1-성공, 0-실패
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
public int update(final WeakPlaceVO weakPlaceVO) throws Exception {
|
||||
return update("WeakPlace.update", weakPlaceVO);
|
||||
}
|
||||
|
||||
/**
|
||||
* 외사취약지 정보를 삭제한다.
|
||||
*
|
||||
* @param weakPlaceVO
|
||||
* 삭제할 외사취약지 VO
|
||||
* @return 1-성공, 0-실패
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
public int delete(final WeakPlaceVO weakPlaceVO) throws Exception {
|
||||
return delete("WeakPlace.delete", weakPlaceVO);
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,191 @@
|
|||
package kcg.faics.tg.service.impl;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
|
||||
import kcg.faics.cmmn.egov.file.EgovFileMngUtil;
|
||||
import kcg.faics.cmmn.egov.vo.FileVO;
|
||||
import kcg.faics.cmmn.service.CodeService;
|
||||
import kcg.faics.tg.service.WeakPlaceService;
|
||||
import kcg.faics.tg.vo.WeakPlaceSearchVO;
|
||||
import kcg.faics.tg.vo.WeakPlaceVO;
|
||||
import egovframework.rte.fdl.cmmn.EgovAbstractServiceImpl;
|
||||
|
||||
/**
|
||||
* 외사취약지 관련 비지니스로직.
|
||||
*
|
||||
* @author kimnomin
|
||||
*
|
||||
*/
|
||||
@Service("weakPlaceService")
|
||||
public class WeakPlaceServiceImpl extends EgovAbstractServiceImpl implements WeakPlaceService {
|
||||
/**
|
||||
* property 파일에서 읽은 저장 경로 키워드.
|
||||
*/
|
||||
private String filePathKeyword = "Target.wp.fileStorePath";
|
||||
|
||||
/**
|
||||
* 전자정부프레임워크에서 제공되는 파일 업로드 처리 관련 Utility.
|
||||
**/
|
||||
@Resource(name = "EgovFileMngUtil")
|
||||
private EgovFileMngUtil fileUtil;
|
||||
|
||||
/**
|
||||
* 외사취약지 Mapper 클래스.
|
||||
*/
|
||||
@Resource(name = "weakPlaceMapper")
|
||||
private WeakPlaceMapper weakPlaceMapper;
|
||||
|
||||
@Override
|
||||
public WeakPlaceVO select(final WeakPlaceVO dataVO) throws Exception {
|
||||
return weakPlaceMapper.select(dataVO);
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<WeakPlaceVO> selectListAll(final WeakPlaceSearchVO searchVO)
|
||||
throws Exception {
|
||||
// 사용하지 않음
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<WeakPlaceVO> selectList(final WeakPlaceSearchVO searchVO)
|
||||
throws Exception {
|
||||
return weakPlaceMapper.selectList(searchVO);
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<HashMap<String, Object>> selectStatsPerPlace() throws Exception {
|
||||
List<HashMap<String, Object>> statsList = new ArrayList<HashMap<String, Object>>();
|
||||
try {
|
||||
statsList = weakPlaceMapper.selectStatsPerPlace(CodeService.POLICE_STATION_LIST);
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
return statsList;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int selectListCnt(final WeakPlaceSearchVO searchVO) throws Exception {
|
||||
// 사용하지 않음
|
||||
return 0;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int selectTotalCnt(final WeakPlaceSearchVO searchVO) throws Exception {
|
||||
// 사용하지 않음
|
||||
return 0;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int selectMaxWpNo(final String place1) throws Exception {
|
||||
return weakPlaceMapper.selectMaxWpNo(place1);
|
||||
}
|
||||
|
||||
@Override
|
||||
public HashMap<String, Object> insert(final WeakPlaceVO dataVO,
|
||||
final Map<String, MultipartFile> fileMap) throws Exception {
|
||||
int result = 0;
|
||||
|
||||
try {
|
||||
// 파일저장
|
||||
if (fileMap != null) {
|
||||
List<FileVO> uploadedFile = fileUtil.parseFileInf(fileMap, null, 0, "", filePathKeyword);
|
||||
for (FileVO file : uploadedFile) {
|
||||
if (file != null) {
|
||||
String fileSn = file.getFileSn();
|
||||
if (!StringUtils.isBlank(fileSn)) {
|
||||
fileSn = fileSn.trim();
|
||||
}
|
||||
if ("file1".equalsIgnoreCase(fileSn)) {
|
||||
dataVO.setFilename1(file.getStreFileNm());
|
||||
} else if ("file2".equalsIgnoreCase(fileSn)) {
|
||||
dataVO.setFilename2(file.getStreFileNm());
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// DB저장
|
||||
result = weakPlaceMapper.insert(dataVO);
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
HashMap<String, Object> map = new HashMap<String, Object>();
|
||||
map.put("result", result);
|
||||
if (result == 1) {
|
||||
map.put("place1", dataVO.getPlace1());
|
||||
map.put("wpNo", dataVO.getWpNo());
|
||||
}
|
||||
|
||||
return map;
|
||||
}
|
||||
|
||||
@Override
|
||||
public HashMap<String, Object> update(final WeakPlaceVO dataVO,
|
||||
final Map<String, MultipartFile> fileMap, final String[] deleteFiles)
|
||||
throws Exception {
|
||||
int result = 0;
|
||||
|
||||
try {
|
||||
// 파일삭제 : 기존 PHP 소스에서 실제 물리적인 파일은 삭제하지 않는다. 이를 준용한다.
|
||||
if (deleteFiles != null) {
|
||||
for (String deleteTarget : deleteFiles) {
|
||||
if ("1".equalsIgnoreCase(deleteTarget)) {
|
||||
dataVO.setFilename1("");
|
||||
} else if ("2".equalsIgnoreCase(deleteTarget)) {
|
||||
dataVO.setFilename2("");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// 파일저장
|
||||
if (fileMap != null) {
|
||||
List<FileVO> uploadedFile = fileUtil.parseFileInf(fileMap, null, 0, "", filePathKeyword);
|
||||
for (FileVO file : uploadedFile) {
|
||||
if (file != null) {
|
||||
String fileSn = file.getFileSn();
|
||||
if (!StringUtils.isBlank(fileSn)) {
|
||||
fileSn = fileSn.trim();
|
||||
}
|
||||
if ("file1".equalsIgnoreCase(fileSn)) {
|
||||
dataVO.setFilename1(file.getStreFileNm());
|
||||
} else if ("file2".equalsIgnoreCase(fileSn)) {
|
||||
dataVO.setFilename2(file.getStreFileNm());
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// DB저장
|
||||
result = weakPlaceMapper.update(dataVO);
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
|
||||
HashMap<String, Object> map = new HashMap<String, Object>();
|
||||
map.put("result", result);
|
||||
|
||||
return map;
|
||||
}
|
||||
|
||||
@Override
|
||||
public HashMap<String, Object> delete(final WeakPlaceVO dataVO) throws Exception {
|
||||
// 기존 PHP 소스에서 실제 물리적인 파일은 삭제하지 않는다. 이를 준용한다.
|
||||
int result = weakPlaceMapper.delete(dataVO);
|
||||
HashMap<String, Object> map = new HashMap<String, Object>();
|
||||
map.put("result", result);
|
||||
|
||||
return map;
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,8 @@
|
|||
/**
|
||||
* 외사수사대상 관련 비지니스로직 패키지.
|
||||
*/
|
||||
/**
|
||||
* @author kimnomin
|
||||
*
|
||||
*/
|
||||
package kcg.faics.tg.service.impl;
|
||||
|
|
@ -0,0 +1,8 @@
|
|||
/**
|
||||
* 외사수사대상 관련 인터페이스 패키지.
|
||||
*/
|
||||
/**
|
||||
* @author kimnomin
|
||||
*
|
||||
*/
|
||||
package kcg.faics.tg.service;
|
||||
|
|
@ -0,0 +1,92 @@
|
|||
package kcg.faics.tg.vo;
|
||||
|
||||
import kcg.faics.cmmn.bbs.BaseSearchVO;
|
||||
|
||||
/**
|
||||
* 치안대상 검색 관련 Value Object.
|
||||
*
|
||||
* @author kimnomin
|
||||
*
|
||||
*/
|
||||
public class CorpSearchVO extends BaseSearchVO {
|
||||
/**
|
||||
* 소속1.
|
||||
*/
|
||||
private String place1;
|
||||
/**
|
||||
* 구분(협조기관~외국인투자업체).
|
||||
*/
|
||||
private String orgId;
|
||||
/**
|
||||
* 화면구분. (01-업무협조기관, 02-해운항만관련협회, 03-외사관련없체, 04-외국인고용업체, 05-외국인투자업체)
|
||||
*/
|
||||
private String grpNo;
|
||||
/**
|
||||
* 기관/협회/업체명.
|
||||
*/
|
||||
private String name;
|
||||
/**
|
||||
* 업종(외국인 고용업체).
|
||||
*/
|
||||
private String jobType;
|
||||
/**
|
||||
* @return the place1
|
||||
*/
|
||||
public final String getPlace1() {
|
||||
return place1;
|
||||
}
|
||||
/**
|
||||
* @param place1 the place1 to set
|
||||
*/
|
||||
public final void setPlace1(final String place1) {
|
||||
this.place1 = place1;
|
||||
}
|
||||
/**
|
||||
* @return the orgId
|
||||
*/
|
||||
public final String getOrgId() {
|
||||
return orgId;
|
||||
}
|
||||
/**
|
||||
* @param orgId the orgId to set
|
||||
*/
|
||||
public final void setOrgId(final String orgId) {
|
||||
this.orgId = orgId;
|
||||
}
|
||||
/**
|
||||
* @return the grpNo
|
||||
*/
|
||||
public final String getGrpNo() {
|
||||
return grpNo;
|
||||
}
|
||||
/**
|
||||
* @param grpNo the grpNo to set
|
||||
*/
|
||||
public final void setGrpNo(final String grpNo) {
|
||||
this.grpNo = grpNo;
|
||||
}
|
||||
/**
|
||||
* @return the name
|
||||
*/
|
||||
public final String getName() {
|
||||
return name;
|
||||
}
|
||||
/**
|
||||
* @param name the name to set
|
||||
*/
|
||||
public final void setName(final String name) {
|
||||
this.name = name;
|
||||
}
|
||||
/**
|
||||
* @return the jobType
|
||||
*/
|
||||
public final String getJobType() {
|
||||
return jobType;
|
||||
}
|
||||
/**
|
||||
* @param jobType the jobType to set
|
||||
*/
|
||||
public final void setJobType(final String jobType) {
|
||||
this.jobType = jobType;
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,346 @@
|
|||
package kcg.faics.tg.vo;
|
||||
|
||||
/**
|
||||
* 치안대상 Value Ojbect.
|
||||
*
|
||||
* @author kimnomin
|
||||
*
|
||||
*/
|
||||
public class CorpVO {
|
||||
/**
|
||||
* 소속1.
|
||||
*/
|
||||
private String place1;
|
||||
/**
|
||||
* 소속1 명칭.
|
||||
*/
|
||||
private String place1str;
|
||||
/**
|
||||
* 구분(협조기관~외국인투자업체).
|
||||
*/
|
||||
private String orgId;
|
||||
/**
|
||||
* 구분별 일련번호.
|
||||
*/
|
||||
private int orgNo;
|
||||
/**
|
||||
* 화면구분. (01-업무협조기관, 02-해운항만관련협회, 03-외사관련없체, 04-외국인고용업체, 05-외국인투자업체)
|
||||
*/
|
||||
private String grpNo;
|
||||
/**
|
||||
* 기관/협회/업체명.
|
||||
*/
|
||||
private String name;
|
||||
/**
|
||||
* 소재지.
|
||||
*/
|
||||
private String location;
|
||||
/**
|
||||
* 대표자명.
|
||||
*/
|
||||
private String ceo;
|
||||
/**
|
||||
* 업종(외국인 고용업체).
|
||||
*/
|
||||
private String jobType;
|
||||
/**
|
||||
* 전화번호.
|
||||
*/
|
||||
private String tel;
|
||||
/**
|
||||
* FAX.
|
||||
*/
|
||||
private String fax;
|
||||
/**
|
||||
* 비고.
|
||||
*/
|
||||
private String comments;
|
||||
/**
|
||||
* 대상국(외국인 투자업체).
|
||||
*/
|
||||
private String partner;
|
||||
/**
|
||||
* 선박(척).
|
||||
*/
|
||||
private int shipCnt;
|
||||
/**
|
||||
* 근무인원.
|
||||
*/
|
||||
private int memberCnt;
|
||||
/**
|
||||
* 설립년도.
|
||||
*/
|
||||
private String basicYear;
|
||||
/**
|
||||
* 자본금(만원).
|
||||
*/
|
||||
private int fund;
|
||||
/**
|
||||
* 등록자 소속서.
|
||||
*/
|
||||
private String writerPlace1;
|
||||
/**
|
||||
* 등록자.
|
||||
*/
|
||||
private String writer;
|
||||
/**
|
||||
* 생성일.
|
||||
*/
|
||||
private String credate;
|
||||
/**
|
||||
* 수정일.
|
||||
*/
|
||||
private String logdate;
|
||||
/**
|
||||
* @return the place1
|
||||
*/
|
||||
public final String getPlace1() {
|
||||
return place1;
|
||||
}
|
||||
/**
|
||||
* @param place1 the place1 to set
|
||||
*/
|
||||
public final void setPlace1(final String place1) {
|
||||
this.place1 = place1;
|
||||
}
|
||||
/**
|
||||
* @return the place1str
|
||||
*/
|
||||
public final String getPlace1str() {
|
||||
return place1str;
|
||||
}
|
||||
/**
|
||||
* @param place1str the place1str to set
|
||||
*/
|
||||
public final void setPlace1str(final String place1str) {
|
||||
this.place1str = place1str;
|
||||
}
|
||||
/**
|
||||
* @return the orgId
|
||||
*/
|
||||
public final String getOrgId() {
|
||||
return orgId;
|
||||
}
|
||||
/**
|
||||
* @param orgId the orgId to set
|
||||
*/
|
||||
public final void setOrgId(final String orgId) {
|
||||
this.orgId = orgId;
|
||||
}
|
||||
/**
|
||||
* @return the orgNo
|
||||
*/
|
||||
public final int getOrgNo() {
|
||||
return orgNo;
|
||||
}
|
||||
/**
|
||||
* @param orgNo the orgNo to set
|
||||
*/
|
||||
public final void setOrgNo(final int orgNo) {
|
||||
this.orgNo = orgNo;
|
||||
}
|
||||
/**
|
||||
* @return the grpNo
|
||||
*/
|
||||
public final String getGrpNo() {
|
||||
return grpNo;
|
||||
}
|
||||
/**
|
||||
* @param grpNo the grpNo to set
|
||||
*/
|
||||
public final void setGrpNo(final String grpNo) {
|
||||
this.grpNo = grpNo;
|
||||
}
|
||||
/**
|
||||
* @return the name
|
||||
*/
|
||||
public final String getName() {
|
||||
return name;
|
||||
}
|
||||
/**
|
||||
* @param name the name to set
|
||||
*/
|
||||
public final void setName(final String name) {
|
||||
this.name = name;
|
||||
}
|
||||
/**
|
||||
* @return the location
|
||||
*/
|
||||
public final String getLocation() {
|
||||
return location;
|
||||
}
|
||||
/**
|
||||
* @param location the location to set
|
||||
*/
|
||||
public final void setLocation(final String location) {
|
||||
this.location = location;
|
||||
}
|
||||
/**
|
||||
* @return the ceo
|
||||
*/
|
||||
public final String getCeo() {
|
||||
return ceo;
|
||||
}
|
||||
/**
|
||||
* @param ceo the ceo to set
|
||||
*/
|
||||
public final void setCeo(final String ceo) {
|
||||
this.ceo = ceo;
|
||||
}
|
||||
/**
|
||||
* @return the jobType
|
||||
*/
|
||||
public final String getJobType() {
|
||||
return jobType;
|
||||
}
|
||||
/**
|
||||
* @param jobType the jobType to set
|
||||
*/
|
||||
public final void setJobType(final String jobType) {
|
||||
this.jobType = jobType;
|
||||
}
|
||||
/**
|
||||
* @return the tel
|
||||
*/
|
||||
public final String getTel() {
|
||||
return tel;
|
||||
}
|
||||
/**
|
||||
* @param tel the tel to set
|
||||
*/
|
||||
public final void setTel(final String tel) {
|
||||
this.tel = tel;
|
||||
}
|
||||
/**
|
||||
* @return the fax
|
||||
*/
|
||||
public final String getFax() {
|
||||
return fax;
|
||||
}
|
||||
/**
|
||||
* @param fax the fax to set
|
||||
*/
|
||||
public final void setFax(final String fax) {
|
||||
this.fax = fax;
|
||||
}
|
||||
/**
|
||||
* @return the comments
|
||||
*/
|
||||
public final String getComments() {
|
||||
return comments;
|
||||
}
|
||||
/**
|
||||
* @param comments the comments to set
|
||||
*/
|
||||
public final void setComments(final String comments) {
|
||||
this.comments = comments;
|
||||
}
|
||||
/**
|
||||
* @return the partner
|
||||
*/
|
||||
public final String getPartner() {
|
||||
return partner;
|
||||
}
|
||||
/**
|
||||
* @param partner the partner to set
|
||||
*/
|
||||
public final void setPartner(final String partner) {
|
||||
this.partner = partner;
|
||||
}
|
||||
/**
|
||||
* @return the shipCnt
|
||||
*/
|
||||
public final int getShipCnt() {
|
||||
return shipCnt;
|
||||
}
|
||||
/**
|
||||
* @param shipCnt the shipCnt to set
|
||||
*/
|
||||
public final void setShipCnt(final int shipCnt) {
|
||||
this.shipCnt = shipCnt;
|
||||
}
|
||||
/**
|
||||
* @return the memberCnt
|
||||
*/
|
||||
public final int getMemberCnt() {
|
||||
return memberCnt;
|
||||
}
|
||||
/**
|
||||
* @param memberCnt the memberCnt to set
|
||||
*/
|
||||
public final void setMemberCnt(final int memberCnt) {
|
||||
this.memberCnt = memberCnt;
|
||||
}
|
||||
/**
|
||||
* @return the basicYear
|
||||
*/
|
||||
public final String getBasicYear() {
|
||||
return basicYear;
|
||||
}
|
||||
/**
|
||||
* @param basicYear the basicYear to set
|
||||
*/
|
||||
public final void setBasicYear(final String basicYear) {
|
||||
this.basicYear = basicYear;
|
||||
}
|
||||
/**
|
||||
* @return the fund
|
||||
*/
|
||||
public final int getFund() {
|
||||
return fund;
|
||||
}
|
||||
/**
|
||||
* @param fund the fund to set
|
||||
*/
|
||||
public final void setFund(final int fund) {
|
||||
this.fund = fund;
|
||||
}
|
||||
/**
|
||||
* @return the writerPlace1
|
||||
*/
|
||||
public final String getWriterPlace1() {
|
||||
return writerPlace1;
|
||||
}
|
||||
/**
|
||||
* @param writerPlace1 the writerPlace1 to set
|
||||
*/
|
||||
public final void setWriterPlace1(final String writerPlace1) {
|
||||
this.writerPlace1 = writerPlace1;
|
||||
}
|
||||
/**
|
||||
* @return the writer
|
||||
*/
|
||||
public final String getWriter() {
|
||||
return writer;
|
||||
}
|
||||
/**
|
||||
* @param writer the writer to set
|
||||
*/
|
||||
public final void setWriter(final String writer) {
|
||||
this.writer = writer;
|
||||
}
|
||||
/**
|
||||
* @return the credate
|
||||
*/
|
||||
public final String getCredate() {
|
||||
return credate;
|
||||
}
|
||||
/**
|
||||
* @param credate the credate to set
|
||||
*/
|
||||
public final void setCredate(final String credate) {
|
||||
this.credate = credate;
|
||||
}
|
||||
/**
|
||||
* @return the logdate
|
||||
*/
|
||||
public final String getLogdate() {
|
||||
return logdate;
|
||||
}
|
||||
/**
|
||||
* @param logdate the logdate to set
|
||||
*/
|
||||
public final void setLogdate(final String logdate) {
|
||||
this.logdate = logdate;
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,31 @@
|
|||
package kcg.faics.tg.vo;
|
||||
|
||||
import kcg.faics.cmmn.bbs.BaseSearchVO;
|
||||
|
||||
/**
|
||||
* 외사분실운영현황 검색정보 Value Object.
|
||||
*
|
||||
* @author kimnomin
|
||||
*
|
||||
*/
|
||||
public class DivMngSearchVO extends BaseSearchVO {
|
||||
|
||||
/**
|
||||
* 소속.
|
||||
*/
|
||||
private String place;
|
||||
|
||||
/**
|
||||
* @return the place
|
||||
*/
|
||||
public final String getPlace() {
|
||||
return place;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param place the place to set
|
||||
*/
|
||||
public final void setPlace(final String place) {
|
||||
this.place = place;
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,355 @@
|
|||
package kcg.faics.tg.vo;
|
||||
|
||||
import java.util.Date;
|
||||
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
|
||||
/**
|
||||
* 외사분신운영현황 Value Object.
|
||||
*
|
||||
* @author kimnomin
|
||||
*
|
||||
*/
|
||||
public class DivMngVO {
|
||||
/**
|
||||
* 소속.
|
||||
*/
|
||||
private String place;
|
||||
/**
|
||||
* 소속명칭.
|
||||
*/
|
||||
private String placeStr;
|
||||
/**
|
||||
* 소속별 일련번호.
|
||||
*/
|
||||
private int no;
|
||||
/**
|
||||
* 설치장소.
|
||||
*/
|
||||
private String local;
|
||||
/**
|
||||
* 근무형태. 근무형태 i-상주, o-비상주
|
||||
*/
|
||||
private String gubun = "i";
|
||||
/**
|
||||
* 근무형태 표현 문자열.
|
||||
*/
|
||||
private String gubunStr = "비상주";
|
||||
/**
|
||||
* 근무인원.
|
||||
*/
|
||||
private int staffNum;
|
||||
/**
|
||||
* 전화번호.
|
||||
*/
|
||||
private String tel;
|
||||
/**
|
||||
* 현황.
|
||||
*/
|
||||
private String condition;
|
||||
/**
|
||||
* 장비현황.
|
||||
*/
|
||||
private String equipStat;
|
||||
/**
|
||||
* 사진.
|
||||
*/
|
||||
private String fileImg;
|
||||
/**
|
||||
* 사진 객체.
|
||||
*/
|
||||
private MultipartFile fileImgObj;
|
||||
/**
|
||||
* 첨부파일1.
|
||||
*/
|
||||
private String file1;
|
||||
/**
|
||||
* 첨부파일2.
|
||||
*/
|
||||
private String file2;
|
||||
/**
|
||||
* 첨부파일3.
|
||||
*/
|
||||
private String file3;
|
||||
/**
|
||||
* 첨부파일1 객체.
|
||||
*/
|
||||
private MultipartFile file1obj;
|
||||
/**
|
||||
* 첨부파일 2 객체.
|
||||
*/
|
||||
private MultipartFile file2obj;
|
||||
/**
|
||||
* 첨부파일 3 객체.
|
||||
*/
|
||||
private MultipartFile file3obj;
|
||||
/**
|
||||
* 입력일.
|
||||
*/
|
||||
private Date creDate;
|
||||
/**
|
||||
* 수정일.
|
||||
*/
|
||||
private Date logDate;
|
||||
/**
|
||||
* 입력자.
|
||||
*/
|
||||
private String writer;
|
||||
/**
|
||||
* @return the place
|
||||
*/
|
||||
public final String getPlace() {
|
||||
return place;
|
||||
}
|
||||
/**
|
||||
* @param place the place to set
|
||||
*/
|
||||
public final void setPlace(final String place) {
|
||||
this.place = place;
|
||||
}
|
||||
/**
|
||||
* @return the placeStr
|
||||
*/
|
||||
public final String getPlaceStr() {
|
||||
return placeStr;
|
||||
}
|
||||
/**
|
||||
* @param placeStr the placeStr to set
|
||||
*/
|
||||
public final void setPlaceStr(final String placeStr) {
|
||||
this.placeStr = placeStr;
|
||||
}
|
||||
/**
|
||||
* @return the no
|
||||
*/
|
||||
public final int getNo() {
|
||||
return no;
|
||||
}
|
||||
/**
|
||||
* @param no the no to set
|
||||
*/
|
||||
public final void setNo(final int no) {
|
||||
this.no = no;
|
||||
}
|
||||
/**
|
||||
* @return the local
|
||||
*/
|
||||
public final String getLocal() {
|
||||
return local;
|
||||
}
|
||||
/**
|
||||
* @param local the local to set
|
||||
*/
|
||||
public final void setLocal(final String local) {
|
||||
this.local = local;
|
||||
}
|
||||
/**
|
||||
* @return the gubun
|
||||
*/
|
||||
public final String getGubun() {
|
||||
return gubun;
|
||||
}
|
||||
/**
|
||||
* @param gubun the gubun to set
|
||||
*/
|
||||
public final void setGubun(final String gubun) {
|
||||
this.gubun = gubun;
|
||||
if ("i".equalsIgnoreCase(this.gubun)) {
|
||||
setGubunStr("상주");
|
||||
} else {
|
||||
setGubunStr("비상주");
|
||||
}
|
||||
}
|
||||
/**
|
||||
* @return the gubunStr
|
||||
*/
|
||||
public final String getGubunStr() {
|
||||
return gubunStr;
|
||||
}
|
||||
/**
|
||||
* @param gubunStr the gubunStr to set
|
||||
*/
|
||||
public final void setGubunStr(final String gubunStr) {
|
||||
this.gubunStr = gubunStr;
|
||||
}
|
||||
/**
|
||||
* @return the staffNum
|
||||
*/
|
||||
public final int getStaffNum() {
|
||||
return staffNum;
|
||||
}
|
||||
/**
|
||||
* @param staffNum the staffNum to set
|
||||
*/
|
||||
public final void setStaffNum(final int staffNum) {
|
||||
this.staffNum = staffNum;
|
||||
}
|
||||
/**
|
||||
* @return the tel
|
||||
*/
|
||||
public final String getTel() {
|
||||
return tel;
|
||||
}
|
||||
/**
|
||||
* @param tel the tel to set
|
||||
*/
|
||||
public final void setTel(final String tel) {
|
||||
this.tel = tel;
|
||||
}
|
||||
/**
|
||||
* @return the condition
|
||||
*/
|
||||
public final String getCondition() {
|
||||
return condition;
|
||||
}
|
||||
/**
|
||||
* @param condition the condition to set
|
||||
*/
|
||||
public final void setCondition(final String condition) {
|
||||
this.condition = condition;
|
||||
}
|
||||
/**
|
||||
* @return the equipStat
|
||||
*/
|
||||
public final String getEquipStat() {
|
||||
return equipStat;
|
||||
}
|
||||
/**
|
||||
* @param equipStat the equipStat to set
|
||||
*/
|
||||
public final void setEquipStat(final String equipStat) {
|
||||
this.equipStat = equipStat;
|
||||
}
|
||||
/**
|
||||
* @return the fileImgObj
|
||||
*/
|
||||
public final MultipartFile getFileImgObj() {
|
||||
return fileImgObj;
|
||||
}
|
||||
/**
|
||||
* @param fileImgObj the fileImgObj to set
|
||||
*/
|
||||
public final void setFileImgObj(final MultipartFile fileImgObj) {
|
||||
this.fileImgObj = fileImgObj;
|
||||
}
|
||||
/**
|
||||
* @return the fileImg
|
||||
*/
|
||||
public final String getFileImg() {
|
||||
return fileImg;
|
||||
}
|
||||
/**
|
||||
* @param fileImg the fileImg to set
|
||||
*/
|
||||
public final void setFileImg(final String fileImg) {
|
||||
this.fileImg = fileImg;
|
||||
}
|
||||
/**
|
||||
* @return the file1
|
||||
*/
|
||||
public final String getFile1() {
|
||||
return file1;
|
||||
}
|
||||
/**
|
||||
* @param file1 the file1 to set
|
||||
*/
|
||||
public final void setFile1(final String file1) {
|
||||
this.file1 = file1;
|
||||
}
|
||||
/**
|
||||
* @return the file2
|
||||
*/
|
||||
public final String getFile2() {
|
||||
return file2;
|
||||
}
|
||||
/**
|
||||
* @param file2 the file2 to set
|
||||
*/
|
||||
public final void setFile2(final String file2) {
|
||||
this.file2 = file2;
|
||||
}
|
||||
/**
|
||||
* @return the file3
|
||||
*/
|
||||
public final String getFile3() {
|
||||
return file3;
|
||||
}
|
||||
/**
|
||||
* @param file3 the file3 to set
|
||||
*/
|
||||
public final void setFile3(final String file3) {
|
||||
this.file3 = file3;
|
||||
}
|
||||
/**
|
||||
* @return the file1obj
|
||||
*/
|
||||
public final MultipartFile getFile1obj() {
|
||||
return file1obj;
|
||||
}
|
||||
/**
|
||||
* @param file1obj the file1obj to set
|
||||
*/
|
||||
public final void setFile1obj(final MultipartFile file1obj) {
|
||||
this.file1obj = file1obj;
|
||||
}
|
||||
/**
|
||||
* @return the file2obj
|
||||
*/
|
||||
public final MultipartFile getFile2obj() {
|
||||
return file2obj;
|
||||
}
|
||||
/**
|
||||
* @param file2obj the file2obj to set
|
||||
*/
|
||||
public final void setFile2obj(final MultipartFile file2obj) {
|
||||
this.file2obj = file2obj;
|
||||
}
|
||||
/**
|
||||
* @return the file3obj
|
||||
*/
|
||||
public final MultipartFile getFile3obj() {
|
||||
return file3obj;
|
||||
}
|
||||
/**
|
||||
* @param file3obj the file3obj to set
|
||||
*/
|
||||
public final void setFile3obj(final MultipartFile file3obj) {
|
||||
this.file3obj = file3obj;
|
||||
}
|
||||
/**
|
||||
* @return the creDate
|
||||
*/
|
||||
public final Date getCreDate() {
|
||||
return creDate;
|
||||
}
|
||||
/**
|
||||
* @param creDate the creDate to set
|
||||
*/
|
||||
public final void setCreDate(final Date creDate) {
|
||||
this.creDate = creDate;
|
||||
}
|
||||
/**
|
||||
* @return the logDate
|
||||
*/
|
||||
public final Date getLogDate() {
|
||||
return logDate;
|
||||
}
|
||||
/**
|
||||
* @param logDate the logDate to set
|
||||
*/
|
||||
public final void setLogDate(final Date logDate) {
|
||||
this.logDate = logDate;
|
||||
}
|
||||
/**
|
||||
* @return the writer
|
||||
*/
|
||||
public final String getWriter() {
|
||||
return writer;
|
||||
}
|
||||
/**
|
||||
* @param writer the writer to set
|
||||
*/
|
||||
public final void setWriter(final String writer) {
|
||||
this.writer = writer;
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,51 @@
|
|||
package kcg.faics.tg.vo;
|
||||
|
||||
import kcg.faics.cmmn.bbs.BaseSearchVO;
|
||||
import kcg.faics.tg.FerryRouteType;
|
||||
|
||||
/**
|
||||
* 국제여객선 검색정보 Value Object.
|
||||
*
|
||||
* @author kimnomin
|
||||
*
|
||||
*/
|
||||
public class FerrySearchVO extends BaseSearchVO {
|
||||
/**
|
||||
* 항로(한-중, 한-러, 한-일, 금강산).
|
||||
*/
|
||||
private String ferryRoute;
|
||||
/**
|
||||
* 항로 표현 문자열.
|
||||
*/
|
||||
private String ferryRouteStr;
|
||||
|
||||
/**
|
||||
* @return the ferryRoute
|
||||
*/
|
||||
public final String getFerryRoute() {
|
||||
return ferryRoute;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param ferryRoute the ferryRoute to set
|
||||
*/
|
||||
public final void setFerryRoute(final String ferryRoute) {
|
||||
this.ferryRoute = ferryRoute;
|
||||
|
||||
setFerryRouteStr(FerryRouteType.getValue(ferryRoute));
|
||||
}
|
||||
|
||||
/**
|
||||
* @return the ferryRouteStr
|
||||
*/
|
||||
public final String getFerryRouteStr() {
|
||||
return ferryRouteStr;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param ferryRouteStr the ferryRouteStr to set
|
||||
*/
|
||||
public final void setFerryRouteStr(final String ferryRouteStr) {
|
||||
this.ferryRouteStr = ferryRouteStr;
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,559 @@
|
|||
package kcg.faics.tg.vo;
|
||||
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
|
||||
import kcg.faics.tg.FerryRouteType;
|
||||
import kcg.faics.tg.FerryRunTermType;
|
||||
|
||||
/**
|
||||
* 국제여객선 Value Object.
|
||||
*
|
||||
* @author kimnomin
|
||||
*
|
||||
*/
|
||||
public class FerryVO {
|
||||
/**
|
||||
* ID.
|
||||
*/
|
||||
private int serNo;
|
||||
/**
|
||||
* 여객선사.
|
||||
*/
|
||||
private String ferryOffice;
|
||||
/**
|
||||
* 선명.
|
||||
*/
|
||||
private String ferryName;
|
||||
/**
|
||||
* 톤수.
|
||||
*/
|
||||
private String ferryTon;
|
||||
/**
|
||||
* 항로(한-중, 한-러, 한-일, 금강산).
|
||||
*/
|
||||
private String ferryRoute;
|
||||
/**
|
||||
* 항로 표현 문자열.
|
||||
*/
|
||||
private String ferryRouteStr;
|
||||
/**
|
||||
* 항해시간.
|
||||
*/
|
||||
private String ferryTime;
|
||||
/**
|
||||
* 최대속력.
|
||||
*/
|
||||
private String ferrySpeedMax;
|
||||
/**
|
||||
* 항해속력.
|
||||
*/
|
||||
private String ferrySpeedNor;
|
||||
/**
|
||||
* 여객정원.
|
||||
*/
|
||||
private int ferryGuestCnt;
|
||||
/**
|
||||
* 승무원정원.
|
||||
*/
|
||||
private int ferryClueCnt;
|
||||
/**
|
||||
* 운항주기.
|
||||
*/
|
||||
private String runTerm;
|
||||
/**
|
||||
* 운항주기 표현 문자열.
|
||||
*/
|
||||
private String runTermStr;
|
||||
/**
|
||||
* 운항횟수.
|
||||
*/
|
||||
private String runCnt;
|
||||
/**
|
||||
* 대표자.
|
||||
*/
|
||||
private String repreName;
|
||||
/**
|
||||
* 연락처.
|
||||
*/
|
||||
private String tel;
|
||||
/**
|
||||
* 선적.
|
||||
*/
|
||||
private String ferrySosok;
|
||||
/**
|
||||
* 항해거리.
|
||||
*/
|
||||
private String sailingDistance;
|
||||
/**
|
||||
* 취항일.
|
||||
*/
|
||||
private String sailingDate;
|
||||
/**
|
||||
* 합작국.
|
||||
*/
|
||||
private String cooperateNation;
|
||||
/**
|
||||
* 합작여부 표현 문자열.
|
||||
*/
|
||||
private String isCooperateStr = "-";
|
||||
/**
|
||||
* 등록자.
|
||||
*/
|
||||
private String writer;
|
||||
/**
|
||||
* 생성일.
|
||||
*/
|
||||
private String creDate;
|
||||
/**
|
||||
* 수정일.
|
||||
*/
|
||||
private String logDate;
|
||||
/**
|
||||
* 첨부이미지.
|
||||
*/
|
||||
private String imgFile;
|
||||
/**
|
||||
* 첨부이미지 객체.
|
||||
*/
|
||||
private MultipartFile imgFileObj;
|
||||
/**
|
||||
* 비고.
|
||||
*/
|
||||
private String comments;
|
||||
|
||||
/**
|
||||
* @return the serNo
|
||||
*/
|
||||
public final int getSerNo() {
|
||||
return serNo;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param serNo
|
||||
* the serNo to set
|
||||
*/
|
||||
public final void setSerNo(final int serNo) {
|
||||
this.serNo = serNo;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return the ferryOffice
|
||||
*/
|
||||
public final String getFerryOffice() {
|
||||
return ferryOffice;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param ferryOffice
|
||||
* the ferryOffice to set
|
||||
*/
|
||||
public final void setFerryOffice(final String ferryOffice) {
|
||||
this.ferryOffice = ferryOffice;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return the ferryName
|
||||
*/
|
||||
public final String getFerryName() {
|
||||
return ferryName;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param ferryName
|
||||
* the ferryName to set
|
||||
*/
|
||||
public final void setFerryName(final String ferryName) {
|
||||
this.ferryName = ferryName;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return the ferryTon
|
||||
*/
|
||||
public final String getFerryTon() {
|
||||
return ferryTon;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param ferryTon
|
||||
* the ferryTon to set
|
||||
*/
|
||||
public final void setFerryTon(final String ferryTon) {
|
||||
this.ferryTon = ferryTon;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return the ferryRoute
|
||||
*/
|
||||
public final String getFerryRoute() {
|
||||
return ferryRoute;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param ferryRoute
|
||||
* the ferryRoute to set
|
||||
*/
|
||||
public final void setFerryRoute(final String ferryRoute) {
|
||||
this.ferryRoute = ferryRoute;
|
||||
|
||||
setFerryRouteStr(FerryRouteType.getValue(ferryRoute));
|
||||
}
|
||||
|
||||
/**
|
||||
* @return the ferryRouteStr
|
||||
*/
|
||||
public final String getFerryRouteStr() {
|
||||
return ferryRouteStr;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param ferryRouteStr
|
||||
* the ferryRouteStr to set
|
||||
*/
|
||||
public final void setFerryRouteStr(final String ferryRouteStr) {
|
||||
this.ferryRouteStr = ferryRouteStr;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return the ferryTime
|
||||
*/
|
||||
public final String getFerryTime() {
|
||||
return ferryTime;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param ferryTime
|
||||
* the ferryTime to set
|
||||
*/
|
||||
public final void setFerryTime(final String ferryTime) {
|
||||
this.ferryTime = ferryTime;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return the ferrySpeedMax
|
||||
*/
|
||||
public final String getFerrySpeedMax() {
|
||||
return ferrySpeedMax;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param ferrySpeedMax
|
||||
* the ferrySpeedMax to set
|
||||
*/
|
||||
public final void setFerrySpeedMax(final String ferrySpeedMax) {
|
||||
this.ferrySpeedMax = ferrySpeedMax;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return the ferrySpeedNor
|
||||
*/
|
||||
public final String getFerrySpeedNor() {
|
||||
return ferrySpeedNor;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param ferrySpeedNor
|
||||
* the ferrySpeedNor to set
|
||||
*/
|
||||
public final void setFerrySpeedNor(final String ferrySpeedNor) {
|
||||
this.ferrySpeedNor = ferrySpeedNor;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return the capacity
|
||||
*/
|
||||
public final int getCapacity() {
|
||||
return getFerryGuestCnt() + getFerryClueCnt();
|
||||
}
|
||||
|
||||
/**
|
||||
* @return the ferryGuestCnt
|
||||
*/
|
||||
public final int getFerryGuestCnt() {
|
||||
return ferryGuestCnt;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param ferryGuestCnt
|
||||
* the ferryGuestCnt to set
|
||||
*/
|
||||
public final void setFerryGuestCnt(final int ferryGuestCnt) {
|
||||
this.ferryGuestCnt = ferryGuestCnt;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return the ferryClueCnt
|
||||
*/
|
||||
public final int getFerryClueCnt() {
|
||||
return ferryClueCnt;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param ferryClueCnt
|
||||
* the ferryClueCnt to set
|
||||
*/
|
||||
public final void setFerryClueCnt(final int ferryClueCnt) {
|
||||
this.ferryClueCnt = ferryClueCnt;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return the runTerm
|
||||
*/
|
||||
public final String getRunTerm() {
|
||||
return runTerm;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param runTerm
|
||||
* the runTerm to set
|
||||
*/
|
||||
public final void setRunTerm(final String runTerm) {
|
||||
this.runTerm = runTerm;
|
||||
|
||||
setRunTermStr(FerryRunTermType.getValue(runTerm));
|
||||
}
|
||||
|
||||
/**
|
||||
* @return the runTermStr
|
||||
*/
|
||||
public final String getRunTermStr() {
|
||||
return runTermStr;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param runTermStr
|
||||
* the runTermStr to set
|
||||
*/
|
||||
public final void setRunTermStr(final String runTermStr) {
|
||||
this.runTermStr = runTermStr;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return the runCnt
|
||||
*/
|
||||
public final String getRunCnt() {
|
||||
return runCnt;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param runCnt
|
||||
* the runCnt to set
|
||||
*/
|
||||
public final void setRunCnt(final String runCnt) {
|
||||
this.runCnt = runCnt;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return the runCntStr
|
||||
*/
|
||||
public final String getRunCntStr() {
|
||||
String result = "";
|
||||
|
||||
if (StringUtils.isNotBlank(getRunCnt())) {
|
||||
result = String.format("%s %s회", getRunTermStr(), getRunCnt());
|
||||
}
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return the repreName
|
||||
*/
|
||||
public final String getRepreName() {
|
||||
return repreName;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param repreName
|
||||
* the repreName to set
|
||||
*/
|
||||
public final void setRepreName(final String repreName) {
|
||||
this.repreName = repreName;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return the tel
|
||||
*/
|
||||
public final String getTel() {
|
||||
return tel;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param tel
|
||||
* the tel to set
|
||||
*/
|
||||
public final void setTel(final String tel) {
|
||||
this.tel = tel;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return the ferrySosok
|
||||
*/
|
||||
public final String getFerrySosok() {
|
||||
return ferrySosok;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param ferrySosok
|
||||
* the ferrySosok to set
|
||||
*/
|
||||
public final void setFerrySosok(final String ferrySosok) {
|
||||
this.ferrySosok = ferrySosok;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return the sailingDistance
|
||||
*/
|
||||
public final String getSailingDistance() {
|
||||
return sailingDistance;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param sailingDistance
|
||||
* the sailingDistance to set
|
||||
*/
|
||||
public final void setSailingDistance(final String sailingDistance) {
|
||||
this.sailingDistance = sailingDistance;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return the sailingDate
|
||||
*/
|
||||
public final String getSailingDate() {
|
||||
return sailingDate;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param sailingDate
|
||||
* the sailingDate to set
|
||||
*/
|
||||
public final void setSailingDate(final String sailingDate) {
|
||||
this.sailingDate = sailingDate;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return the cooperateNation
|
||||
*/
|
||||
public final String getCooperateNation() {
|
||||
return cooperateNation;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param cooperateNation
|
||||
* the cooperateNation to set
|
||||
*/
|
||||
public final void setCooperateNation(final String cooperateNation) {
|
||||
this.cooperateNation = cooperateNation;
|
||||
|
||||
if (StringUtils.isNotBlank(cooperateNation)) {
|
||||
setIsCooperateStr("합작");
|
||||
} else {
|
||||
setIsCooperateStr("-");
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @return the isCooperateStr
|
||||
*/
|
||||
public final String getIsCooperateStr() {
|
||||
return isCooperateStr;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param isCooperateStr
|
||||
* the isCooperateStr to set
|
||||
*/
|
||||
public final void setIsCooperateStr(final String isCooperateStr) {
|
||||
this.isCooperateStr = isCooperateStr;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return the writer
|
||||
*/
|
||||
public final String getWriter() {
|
||||
return writer;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param writer
|
||||
* the writer to set
|
||||
*/
|
||||
public final void setWriter(final String writer) {
|
||||
this.writer = writer;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return the creDate
|
||||
*/
|
||||
public final String getCreDate() {
|
||||
return creDate;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param creDate
|
||||
* the creDate to set
|
||||
*/
|
||||
public final void setCreDate(final String creDate) {
|
||||
this.creDate = creDate;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return the logDate
|
||||
*/
|
||||
public final String getLogDate() {
|
||||
return logDate;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param logDate
|
||||
* the logDate to set
|
||||
*/
|
||||
public final void setLogDate(final String logDate) {
|
||||
this.logDate = logDate;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return the imgFile
|
||||
*/
|
||||
public final String getImgFile() {
|
||||
return imgFile;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param imgFile
|
||||
* the imgFile to set
|
||||
*/
|
||||
public final void setImgFile(final String imgFile) {
|
||||
this.imgFile = imgFile;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return the imgFileObj
|
||||
*/
|
||||
public final MultipartFile getImgFileObj() {
|
||||
return imgFileObj;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param imgFileObj
|
||||
* the imgFileObj to set
|
||||
*/
|
||||
public final void setImgFileObj(final MultipartFile imgFileObj) {
|
||||
this.imgFileObj = imgFileObj;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return the comments
|
||||
*/
|
||||
public final String getComments() {
|
||||
return comments;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param comments
|
||||
* the comments to set
|
||||
*/
|
||||
public final void setComments(final String comments) {
|
||||
this.comments = comments;
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,35 @@
|
|||
package kcg.faics.tg.vo;
|
||||
|
||||
import kcg.faics.cmmn.bbs.BaseSearchVO;
|
||||
|
||||
/**
|
||||
* 외사취약지 검색 관련 Value Object.
|
||||
*
|
||||
* @author kimnomin
|
||||
*
|
||||
*/
|
||||
public class WeakPlaceSearchVO extends BaseSearchVO {
|
||||
/**
|
||||
* 소속.
|
||||
*/
|
||||
private String place1;
|
||||
|
||||
/**
|
||||
* 소속을 반환한다.
|
||||
*
|
||||
* @return 소속
|
||||
*/
|
||||
public final String getPlace1() {
|
||||
return place1;
|
||||
}
|
||||
|
||||
/**
|
||||
* 소속을 설정한다.
|
||||
*
|
||||
* @param place1 소속
|
||||
*/
|
||||
public final void setPlace1(final String place1) {
|
||||
this.place1 = place1;
|
||||
}
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,314 @@
|
|||
package kcg.faics.tg.vo;
|
||||
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
|
||||
/**
|
||||
* 외사취약지 Value Object.
|
||||
*
|
||||
* @author kimnomin
|
||||
*
|
||||
*/
|
||||
public class WeakPlaceVO {
|
||||
/**
|
||||
* 소속 코드.
|
||||
*/
|
||||
private String place1;
|
||||
/**
|
||||
* 소속명.
|
||||
*/
|
||||
private String place1str;
|
||||
/**
|
||||
* 일련번호.
|
||||
*/
|
||||
private int wpNo;
|
||||
/**
|
||||
* 취약지명.
|
||||
*/
|
||||
private String name;
|
||||
/**
|
||||
* 소재지.
|
||||
*/
|
||||
private String location;
|
||||
/**
|
||||
* 선정사유.
|
||||
*/
|
||||
private String comments;
|
||||
/**
|
||||
* 요도 첨부파일 객체.
|
||||
*/
|
||||
private MultipartFile file1;
|
||||
/**
|
||||
* 요도 첨부파일.
|
||||
*/
|
||||
private String filename1 = "";
|
||||
/**
|
||||
* 화면에 출력할 요도 첨부파일 여부 텍스트.
|
||||
* O : 있다, - : 없다.
|
||||
*/
|
||||
private String filename1viewStr = "-";
|
||||
/**
|
||||
* 첨부파일 객체.
|
||||
*/
|
||||
private MultipartFile file2;
|
||||
/**
|
||||
* 첨부파일.
|
||||
*/
|
||||
private String filename2 = "";
|
||||
/**
|
||||
* 등록자.
|
||||
*/
|
||||
private String writer;
|
||||
/**
|
||||
* 등록일.
|
||||
*/
|
||||
private String credate;
|
||||
/**
|
||||
* 수정일.
|
||||
*/
|
||||
private String logdate;
|
||||
|
||||
|
||||
/**
|
||||
* 소속 코드을 반환한다.
|
||||
*
|
||||
* @return 소속 코드
|
||||
*/
|
||||
public final String getPlace1() {
|
||||
return place1;
|
||||
}
|
||||
/**
|
||||
* 소속 코드을 설정한다.
|
||||
*
|
||||
* @param place1 소속 코드
|
||||
*/
|
||||
public final void setPlace1(final String place1) {
|
||||
this.place1 = place1;
|
||||
}
|
||||
/**
|
||||
* 소속명을 반환한다.
|
||||
*
|
||||
* @return 소속명
|
||||
*/
|
||||
public final String getPlace1str() {
|
||||
return place1str;
|
||||
}
|
||||
/**
|
||||
* 소속명을 설정한다.
|
||||
*
|
||||
* @param place1str 소속명
|
||||
*/
|
||||
public final void setPlace1str(final String place1str) {
|
||||
this.place1str = place1str;
|
||||
}
|
||||
/**
|
||||
* 일련번호를 반환한다.
|
||||
*
|
||||
* @return 일련번호
|
||||
*/
|
||||
public final int getWpNo() {
|
||||
return wpNo;
|
||||
}
|
||||
/**
|
||||
* 일련번호를 설정한다.
|
||||
*
|
||||
* @param wpNo 일련번호
|
||||
*/
|
||||
public final void setWpNo(final int wpNo) {
|
||||
this.wpNo = wpNo;
|
||||
}
|
||||
/**
|
||||
* 관리번호를 반환한다.
|
||||
*
|
||||
* @return 관리번호
|
||||
*/
|
||||
public final String getWpNoStr() {
|
||||
return String.format("%s - %s", this.place1str, this.wpNo);
|
||||
}
|
||||
/**
|
||||
* 취약지명을 반환한다.
|
||||
*
|
||||
* @return 취약지명
|
||||
*/
|
||||
public final String getName() {
|
||||
return name;
|
||||
}
|
||||
/**
|
||||
* 취약지명을 설정한다.
|
||||
*
|
||||
* @param name 취약지명
|
||||
*/
|
||||
public final void setName(final String name) {
|
||||
this.name = name;
|
||||
}
|
||||
/**
|
||||
* 소재지를 반환한다.
|
||||
*
|
||||
* @return 소재지
|
||||
*/
|
||||
public final String getLocation() {
|
||||
return location;
|
||||
}
|
||||
/**
|
||||
* 소재지를 설정한다.
|
||||
*
|
||||
* @param location 소재지
|
||||
*/
|
||||
public final void setLocation(final String location) {
|
||||
this.location = location;
|
||||
}
|
||||
/**
|
||||
* 선정사유를 반환한다.
|
||||
*
|
||||
* @return 선정사유
|
||||
*/
|
||||
public final String getComments() {
|
||||
return comments;
|
||||
}
|
||||
/**
|
||||
* 선정사유를 설정한다.
|
||||
*
|
||||
* @param comments 선정사유
|
||||
*/
|
||||
public final void setComments(final String comments) {
|
||||
this.comments = comments;
|
||||
}
|
||||
/**
|
||||
* 요도 첨부파일 객체를 반환한다.
|
||||
*
|
||||
* @return 요도 첨부파일 객체
|
||||
*/
|
||||
public final MultipartFile getFile1() {
|
||||
return file1;
|
||||
}
|
||||
/**
|
||||
* 요도 첨부파일 객체를 설정한다.
|
||||
*
|
||||
* @param file1 요도 첨부파일 객체
|
||||
*/
|
||||
public final void setFile1(final MultipartFile file1) {
|
||||
this.file1 = file1;
|
||||
if (this.file1 != null) {
|
||||
setFilename1(this.file1.getOriginalFilename());
|
||||
}
|
||||
}
|
||||
/**
|
||||
* 요도 첨부파일을 반환한다.
|
||||
*
|
||||
* @return 요도 첨부파일
|
||||
*/
|
||||
public final String getFilename1() {
|
||||
return filename1;
|
||||
}
|
||||
/**
|
||||
* 요도 첨부파일을 설정한다.
|
||||
*
|
||||
* @param filename1 요도 첨부파일
|
||||
*/
|
||||
public final void setFilename1(final String filename1) {
|
||||
this.filename1 = filename1;
|
||||
if (this.filename1 != null && this.filename1.trim().length() > 0) {
|
||||
setFilename1viewStr("O");
|
||||
} else {
|
||||
setFilename1viewStr("-");
|
||||
}
|
||||
}
|
||||
/**
|
||||
* 화면에 출력할 요도 첨부파일 여부 텍스트를 반환한다.
|
||||
*
|
||||
* @return 화면에 출력할 요도 첨부파일 여부 텍스트
|
||||
*/
|
||||
public final String getFilename1viewStr() {
|
||||
return filename1viewStr;
|
||||
}
|
||||
/**
|
||||
* 화면에 출력할 요도 첨부파일 여부 텍스트를 설정한다.
|
||||
*
|
||||
* @param filename1viewStr 화면에 출력할 요도 첨부파일 여부 텍스트
|
||||
*/
|
||||
public final void setFilename1viewStr(final String filename1viewStr) {
|
||||
this.filename1viewStr = filename1viewStr;
|
||||
}
|
||||
/**
|
||||
* 첨부파일 객체를 반환한다.
|
||||
*
|
||||
* @return 첨부파일
|
||||
*/
|
||||
public final MultipartFile getFile2() {
|
||||
return file2;
|
||||
}
|
||||
/**
|
||||
* 첨부파일 객체를 설정한다.
|
||||
*
|
||||
* @param file2 첨부파일
|
||||
*/
|
||||
public final void setFile2(final MultipartFile file2) {
|
||||
this.file2 = file2;
|
||||
if (this.file2 != null) {
|
||||
setFilename2(this.file2.getOriginalFilename());
|
||||
}
|
||||
}
|
||||
/**
|
||||
* 첨부파일를 반환한다.
|
||||
*
|
||||
* @return 첨부파일
|
||||
*/
|
||||
public final String getFilename2() {
|
||||
return filename2;
|
||||
}
|
||||
/**
|
||||
* 첨부파일를 설정한다.
|
||||
*
|
||||
* @param filename2 첨부파일
|
||||
*/
|
||||
public final void setFilename2(final String filename2) {
|
||||
this.filename2 = filename2;
|
||||
}
|
||||
/**
|
||||
* 등록자를 반환한다.
|
||||
*
|
||||
* @return 등록자
|
||||
*/
|
||||
public final String getWriter() {
|
||||
return writer;
|
||||
}
|
||||
/**
|
||||
* 등록자를 설정한다.
|
||||
*
|
||||
* @param writer 등록자
|
||||
*/
|
||||
public final void setWriter(final String writer) {
|
||||
this.writer = writer;
|
||||
}
|
||||
/**
|
||||
* 등록일을 반환한다.
|
||||
*
|
||||
* @return 등록일
|
||||
*/
|
||||
public final String getCredate() {
|
||||
return credate;
|
||||
}
|
||||
/**
|
||||
* 등록일을 설정한다.
|
||||
*
|
||||
* @param credate 등록일
|
||||
*/
|
||||
public final void setCredate(final String credate) {
|
||||
this.credate = credate;
|
||||
}
|
||||
/**
|
||||
* 수정일을 반환한다.
|
||||
*
|
||||
* @return 수정일
|
||||
*/
|
||||
public final String getLogdate() {
|
||||
return logdate;
|
||||
}
|
||||
/**
|
||||
* 수정일을 설정한다.
|
||||
*
|
||||
* @param logdate 수정일
|
||||
*/
|
||||
public final void setLogdate(final String logdate) {
|
||||
this.logdate = logdate;
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,8 @@
|
|||
/**
|
||||
* 외사대상목표 관련 Value Object 패키지.
|
||||
*/
|
||||
/**
|
||||
* @author kimnomin
|
||||
*
|
||||
*/
|
||||
package kcg.faics.tg.vo;
|
||||
|
|
@ -0,0 +1,532 @@
|
|||
package kcg.faics.tg.web;
|
||||
|
||||
import java.util.HashMap;
|
||||
import java.util.LinkedHashMap;
|
||||
import java.util.List;
|
||||
import java.util.Locale;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import javax.validation.Valid;
|
||||
|
||||
import kcg.faics.cmmn.bbs.PageType;
|
||||
import kcg.faics.cmmn.excel.ExcelExporter;
|
||||
import kcg.faics.cmmn.service.CodeService;
|
||||
import kcg.faics.cmmn.vo.CodeVO;
|
||||
import kcg.faics.sec.LoginUserVO;
|
||||
import kcg.faics.sec.UserUtil;
|
||||
import kcg.faics.tg.service.CorpService;
|
||||
import kcg.faics.tg.vo.CorpSearchVO;
|
||||
import kcg.faics.tg.vo.CorpVO;
|
||||
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.context.MessageSource;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.ui.Model;
|
||||
import org.springframework.validation.BindingResult;
|
||||
import org.springframework.web.bind.annotation.ModelAttribute;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMethod;
|
||||
import org.springframework.web.bind.support.SessionStatus;
|
||||
import org.springmodules.validation.commons.DefaultBeanValidator;
|
||||
|
||||
import egovframework.rte.fdl.property.EgovPropertyService;
|
||||
import egovframework.rte.fdl.security.userdetails.util.EgovUserDetailsHelper;
|
||||
|
||||
/**
|
||||
* 치안대상 컨트롤러.
|
||||
*
|
||||
* @author kimnomin
|
||||
*
|
||||
*/
|
||||
@Controller
|
||||
@RequestMapping("/target/corp")
|
||||
public class CorpController {
|
||||
/**
|
||||
* properties값을 가져오는 인터페이스.
|
||||
**/
|
||||
@Resource(name = "propertiesService")
|
||||
private EgovPropertyService propertiesService;
|
||||
|
||||
/**
|
||||
* message.properties의 값을 가져오는 인터페이스.
|
||||
*/
|
||||
@Autowired
|
||||
private MessageSource messageSource;
|
||||
|
||||
/**
|
||||
* Validator - 유효성 검사.
|
||||
**/
|
||||
@Resource(name = "beanValidator")
|
||||
private DefaultBeanValidator beanValidator;
|
||||
|
||||
/**
|
||||
* 코드관련 정보 인터페이스.
|
||||
*/
|
||||
@Resource(name = "codeService")
|
||||
private CodeService codeService;
|
||||
|
||||
/**
|
||||
* 치안대상 비지니스 로직 클래스.
|
||||
*/
|
||||
@Resource(name = "corpService")
|
||||
private CorpService corpService;
|
||||
|
||||
/**
|
||||
* grpNo에 따른 항목명을 반환한다.
|
||||
*
|
||||
* @param grpNo
|
||||
* 화면구분
|
||||
* @param locale
|
||||
* Locale 객체
|
||||
* @return 항목명
|
||||
*/
|
||||
private LinkedHashMap<String, String> getFieldName(final String grpNo, final Locale locale) {
|
||||
LinkedHashMap<String, String> map = new LinkedHashMap<String, String>();
|
||||
map.put("place1str", messageSource.getMessage("target.corp.place1", null, locale));
|
||||
if ("01".equalsIgnoreCase(grpNo)) {
|
||||
map.put("name", messageSource.getMessage("target.corp.name01", null, locale));
|
||||
map.put("location", messageSource.getMessage("target.corp.location", null, locale));
|
||||
} else if ("02".equalsIgnoreCase(grpNo)) {
|
||||
map.put("name", messageSource.getMessage("target.corp.name02", null, locale));
|
||||
map.put("location", messageSource.getMessage("target.corp.location", null, locale));
|
||||
map.put("ceo", messageSource.getMessage("target.corp.ceo", null, locale));
|
||||
} else if ("03".equalsIgnoreCase(grpNo)) {
|
||||
map.put("name", messageSource.getMessage("target.corp.name", null, locale));
|
||||
map.put("location", messageSource.getMessage("target.corp.location", null, locale));
|
||||
map.put("shipCnt", messageSource.getMessage("target.corp.shipcnt", null, locale));
|
||||
map.put("ceo", messageSource.getMessage("target.corp.ceo", null, locale));
|
||||
map.put("memberCnt", messageSource.getMessage("target.corp.membercnt", null, locale));
|
||||
map.put("basicYear", messageSource.getMessage("target.corp.basicyear", null, locale));
|
||||
map.put("fund", messageSource.getMessage("target.corp.fund", null, locale));
|
||||
} else if ("04".equalsIgnoreCase(grpNo)) {
|
||||
map.put("name", messageSource.getMessage("target.corp.name", null, locale));
|
||||
map.put("location", messageSource.getMessage("target.corp.location", null, locale));
|
||||
map.put("ceo", messageSource.getMessage("target.corp.ceo", null, locale));
|
||||
map.put("jobType", messageSource.getMessage("target.corp.jobtype", null, locale));
|
||||
} else if ("05".equalsIgnoreCase(grpNo)) {
|
||||
map.put("name", messageSource.getMessage("target.corp.name", null, locale));
|
||||
map.put("location", messageSource.getMessage("target.corp.location", null, locale));
|
||||
map.put("ceo", messageSource.getMessage("target.corp.ceo", null, locale));
|
||||
map.put("jobType", messageSource.getMessage("target.corp.jobtype", null, locale));
|
||||
map.put("partner", messageSource.getMessage("target.corp.partner", null, locale));
|
||||
}
|
||||
map.put("tel", messageSource.getMessage("target.corp.tel", null, locale));
|
||||
map.put("fax", messageSource.getMessage("target.corp.fax", null, locale));
|
||||
map.put("comments", messageSource.getMessage("target.corp.comments", null, locale));
|
||||
|
||||
return map;
|
||||
}
|
||||
|
||||
/**
|
||||
* Redirect URI를 조합하여 반환한다.
|
||||
*
|
||||
* @param pageType
|
||||
* 화면구분
|
||||
* @param vo
|
||||
* 치안대상 VO
|
||||
* @return Redirect URI
|
||||
*/
|
||||
private String makeRedirectUri(final PageType pageType, final CorpVO vo) {
|
||||
String uri = "redirect:/target/corp";
|
||||
|
||||
switch (pageType) {
|
||||
case View:
|
||||
uri = String.format("%s/view.do?place1=%s&orgId=%s&orgNo=%s", uri,
|
||||
vo.getPlace1(), vo.getOrgId(), vo.getOrgNo());
|
||||
break;
|
||||
case List:
|
||||
uri = String.format("%s/list.do?place1=%s&orgId=%s&grpNo=%s", uri,
|
||||
vo.getPlace1(), vo.getOrgId(), vo.getGrpNo());
|
||||
break;
|
||||
case Stats:
|
||||
default:
|
||||
uri += "stats.do";
|
||||
break;
|
||||
}
|
||||
|
||||
return uri;
|
||||
}
|
||||
|
||||
/**
|
||||
* 치안대상 통계화면을 반환한다.
|
||||
*
|
||||
* @param model
|
||||
* Model 객체
|
||||
* @return 치안대상 통계화면
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
@RequestMapping(value = "/stats.do")
|
||||
public String stats(final Model model) throws Exception {
|
||||
List<HashMap<String, Object>> stats = corpService.selectStats();
|
||||
model.addAttribute("stats", stats);
|
||||
|
||||
return "/tg/corpStats.tiles";
|
||||
}
|
||||
|
||||
/**
|
||||
* 치안대상 통계현황을 엑셀로 반환한다.
|
||||
*
|
||||
* @param model
|
||||
* Model 객체
|
||||
* @return 치안대상 통계현황 엑셀
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
@RequestMapping(value = "/statstoexcel.do")
|
||||
public String statsToExcel(final Model model) throws Exception {
|
||||
String title = "치안대상";
|
||||
|
||||
// 엑셀 헤더 생성
|
||||
LinkedHashMap<String, String> header = new LinkedHashMap<String, String>();
|
||||
header.put("ORG_NM", "구분");
|
||||
header.put("TOT_CNT", "계");
|
||||
List<CodeVO> policeStations = codeService.getPlace1List(CodeService.POLICE_STATION_LIST);
|
||||
for (CodeVO placeCode : policeStations) {
|
||||
header.put(placeCode.getCode2() + "_CNT", placeCode.getCodenmYak());
|
||||
}
|
||||
|
||||
// 데이터 생성
|
||||
List<HashMap<String, Object>> stats = corpService.selectStats();
|
||||
|
||||
// Export
|
||||
model.addAttribute("excel", new ExcelExporter<HashMap<String, Object>>(header, stats, title));
|
||||
model.addAttribute("filename", title);
|
||||
|
||||
return "excelView";
|
||||
}
|
||||
|
||||
/**
|
||||
* 치안대상 목록화면을 반환한다.
|
||||
*
|
||||
* @param model
|
||||
* Model 객체
|
||||
* @param searchVO
|
||||
* 검색조건 VO
|
||||
* @param locale
|
||||
* Locale 객체
|
||||
* @return 치안대상 목록화면
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
@RequestMapping(value = "/list.do")
|
||||
public String list(final Model model,
|
||||
@ModelAttribute("searchVO") final CorpSearchVO searchVO,
|
||||
final Locale locale) throws Exception {
|
||||
LoginUserVO loginUserVO = UserUtil.getMemberInfo();
|
||||
model.addAttribute("loginUserVO", loginUserVO);
|
||||
|
||||
List<CodeVO> placeList = codeService.getPlace1List(CodeService.POLICE_STATION_LIST, true);
|
||||
model.addAttribute("placeList", placeList);
|
||||
|
||||
// place1 조건이 할당되지 않은 상태이고 로그인한 사용자의 소속이 검색조건에 적합하면 소속코드 할당
|
||||
if (StringUtils.isEmpty(searchVO.getPlace1())) {
|
||||
for (CodeVO place: placeList) {
|
||||
if (loginUserVO.getPlace1().equalsIgnoreCase(place.getCode2())) {
|
||||
searchVO.setPlace1(loginUserVO.getPlace1());
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if ("03".equalsIgnoreCase(searchVO.getGrpNo())) {
|
||||
List<CodeVO> corpOrgList = codeService.getCorpOrgList();
|
||||
LinkedHashMap<String, String> corpOrgMap = new LinkedHashMap<String, String>();
|
||||
for (CodeVO vo : corpOrgList) {
|
||||
String code2 = vo.getCode2();
|
||||
String stChar2 = code2.substring(0, 2);
|
||||
String edChar2 = code2.substring(code2.length() - 2);
|
||||
if ("03".equalsIgnoreCase(edChar2)) {
|
||||
corpOrgMap.put(stChar2, vo.getCodenm());
|
||||
}
|
||||
}
|
||||
model.addAttribute("corpOrgList", corpOrgMap);
|
||||
}
|
||||
|
||||
List<CorpVO> corpList = corpService.selectList(searchVO);
|
||||
model.addAttribute("corpList", corpList);
|
||||
|
||||
LinkedHashMap<String, String> fieldNameMap = getFieldName(searchVO.getGrpNo(), locale);
|
||||
model.addAttribute("fieldNameMap", fieldNameMap);
|
||||
|
||||
return "/tg/corpList.tiles";
|
||||
}
|
||||
|
||||
/**
|
||||
* 치안대상 목록을 엑셀로 반환한다.
|
||||
*
|
||||
* @param model
|
||||
* Model 객체
|
||||
* @param searchVO
|
||||
* 검색조건 VO
|
||||
* @param locale
|
||||
* Locale 객체
|
||||
* @return 치안대상 목록 엑셀
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
@RequestMapping(value = "/listtoexcel.do")
|
||||
public String listToExcel(final Model model,
|
||||
@ModelAttribute("searchVO") final CorpSearchVO searchVO,
|
||||
final Locale locale) throws Exception {
|
||||
String grpNo = searchVO.getGrpNo();
|
||||
String title = "치안대상";
|
||||
|
||||
// 엑셀 헤더 생성
|
||||
LinkedHashMap<String, String> header = getFieldName(grpNo, locale);
|
||||
|
||||
// 데이터 생성
|
||||
List<CorpVO> corpList = corpService.selectList(searchVO);
|
||||
|
||||
// Export
|
||||
model.addAttribute("excel", new ExcelExporter<CorpVO>(header, corpList, title));
|
||||
model.addAttribute("filename", title);
|
||||
|
||||
return "excelView";
|
||||
}
|
||||
|
||||
/**
|
||||
* 치안대상 정보 조회화면을 반환한다.
|
||||
*
|
||||
* @param model
|
||||
* Model 객체
|
||||
* @param locale
|
||||
* Locale 객체
|
||||
* @param corpVO
|
||||
* 치안대상 VO
|
||||
* @return 치안대상 정보 조회화면
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
@RequestMapping(value = "/view.do")
|
||||
public String view(final Model model, final Locale locale,
|
||||
final CorpVO corpVO) throws Exception {
|
||||
LoginUserVO loginUserVO = UserUtil.getMemberInfo();
|
||||
model.addAttribute("loginUserVO", loginUserVO);
|
||||
|
||||
CorpVO vo = corpService.select(corpVO);
|
||||
model.addAttribute("corpVO", vo);
|
||||
|
||||
LinkedHashMap<String, String> fieldNameMap = getFieldName(vo.getGrpNo(), locale);
|
||||
model.addAttribute("fieldNameMap", fieldNameMap);
|
||||
|
||||
return "/tg/corpView.tiles";
|
||||
}
|
||||
|
||||
/**
|
||||
* 치안대상 입력화면을 반환한다.
|
||||
*
|
||||
* @param model
|
||||
* Model 객체
|
||||
* @param corpVO
|
||||
* 치안대상 VO
|
||||
* @param locale
|
||||
* Locale 객체
|
||||
* @return 치안대상 입력화면
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
@RequestMapping(value = "/add.do")
|
||||
public String add(final Model model,
|
||||
@ModelAttribute("corpVO") final CorpVO corpVO, final Locale locale) throws Exception {
|
||||
// 사용자 인증 검사
|
||||
Boolean isAuthenticated = EgovUserDetailsHelper.isAuthenticated();
|
||||
|
||||
// 등록은 isAdmin이 true인 사용자만 가능하다.
|
||||
if (isAuthenticated && UserUtil.isAdmin()) {
|
||||
List<CodeVO> placeList = codeService.getPlace1List(CodeService.POLICE_STATION_LIST);
|
||||
model.addAttribute("placeList", placeList);
|
||||
|
||||
LoginUserVO loginUserVO = UserUtil.getMemberInfo();
|
||||
model.addAttribute("loginUserVO", loginUserVO);
|
||||
|
||||
// 로그인한 사용자가 입력가능한 소속이면 해당 소속으로 할당하고,
|
||||
// 그렇지 않으면 기본값인 파라미터의 소속코드를 사용한다.
|
||||
for (CodeVO tempVO : placeList) {
|
||||
if (tempVO.getCode2().equalsIgnoreCase(loginUserVO.getPlace1())) {
|
||||
corpVO.setPlace1(loginUserVO.getPlace1());
|
||||
corpVO.setPlace1str(loginUserVO.getPlace1Str());
|
||||
break;
|
||||
}
|
||||
}
|
||||
corpVO.setWriter(loginUserVO.getUserid());
|
||||
corpVO.setWriterPlace1(loginUserVO.getPlace1());
|
||||
|
||||
LinkedHashMap<String, String> fieldNameMap = getFieldName(corpVO.getGrpNo(), locale);
|
||||
model.addAttribute("fieldNameMap", fieldNameMap);
|
||||
model.addAttribute("registerFlag", "create");
|
||||
}
|
||||
return "/tg/corpAdd.tiles";
|
||||
}
|
||||
|
||||
/**
|
||||
* 치안대상 정보를 입력한다.
|
||||
*
|
||||
* <pre>
|
||||
* php소스에는 파일 업로드 기능이 있으나,
|
||||
* 파일 관련 필드가 DB에도 없고 표현기능도 없어서 제외함.
|
||||
* </pre>
|
||||
*
|
||||
* @param corpVO
|
||||
* 치안대상 VO
|
||||
* @param bindingResult
|
||||
* 유효성 검사결과 객체
|
||||
* @param model
|
||||
* 모델 객체
|
||||
* @param status
|
||||
* SessionStatus 객체
|
||||
* @param locale
|
||||
* Locale 객체
|
||||
* @return 치안대상 목록화면
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
@RequestMapping(value = "/add.do", method = RequestMethod.POST)
|
||||
public String add(@ModelAttribute("corpVO") final CorpVO corpVO,
|
||||
final BindingResult bindingResult, final Model model,
|
||||
final SessionStatus status, final Locale locale) throws Exception {
|
||||
// 사용자 인증 검사
|
||||
Boolean isAuthenticated = EgovUserDetailsHelper.isAuthenticated();
|
||||
|
||||
// 등록은 isAdmin이 true인 사용자만 가능하다.
|
||||
if (isAuthenticated && UserUtil.isAdmin()) {
|
||||
// 유효성 검사
|
||||
beanValidator.validate(corpVO, bindingResult);
|
||||
if (bindingResult.hasErrors()) {
|
||||
return add(model, corpVO, locale);
|
||||
}
|
||||
|
||||
HashMap<String, Object> map = corpService.insert(corpVO, null);
|
||||
|
||||
status.setComplete();
|
||||
|
||||
if ((Integer) map.get("result") == 1) {
|
||||
return makeRedirectUri(PageType.List, corpVO);
|
||||
}
|
||||
}
|
||||
|
||||
return "error/bizError";
|
||||
}
|
||||
|
||||
/**
|
||||
* 치안대상 수정화면을 반환한다.
|
||||
*
|
||||
* @param model
|
||||
* Model 객체
|
||||
* @param locale
|
||||
* Locale 객체
|
||||
* @param corpVO
|
||||
* 치안대상 VO
|
||||
* @return 치안대상 수정화면
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
@RequestMapping(value = "/update.do")
|
||||
public String update(final Model model, final Locale locale, final CorpVO corpVO) throws Exception {
|
||||
LoginUserVO loginUserVO = UserUtil.getMemberInfo();
|
||||
model.addAttribute("loginUserVO", loginUserVO);
|
||||
|
||||
// 등록은 관리자만 가능하지만, 수정/삭제는 관리자 + 해당 기관도 가능하다.
|
||||
if (loginUserVO.getIsAdmin()
|
||||
|| loginUserVO.getPlace1().equalsIgnoreCase(corpVO.getPlace1())) {
|
||||
CorpVO vo = corpService.select(corpVO);
|
||||
model.addAttribute("corpVO", vo);
|
||||
|
||||
LinkedHashMap<String, String> fieldNameMap = getFieldName(vo.getGrpNo(), locale);
|
||||
model.addAttribute("fieldNameMap", fieldNameMap);
|
||||
model.addAttribute("registerFlag", "modify");
|
||||
|
||||
return "/tg/corpAdd.tiles";
|
||||
}
|
||||
|
||||
return makeRedirectUri(PageType.View, corpVO);
|
||||
}
|
||||
|
||||
/**
|
||||
* 치안대상 정보를 수정한다.
|
||||
*
|
||||
* <pre>
|
||||
* php소스에는 파일 업로드 기능이 있으나,
|
||||
* 파일 관련 필드가 DB에도 없고 표현기능도 없어서 제외함.
|
||||
* </pre>
|
||||
*
|
||||
* @param corpVO
|
||||
* 치안대상 VO
|
||||
* @param bindingResult
|
||||
* 유효성 검사결과 객체
|
||||
* @param model
|
||||
* 모델 객체
|
||||
* @param status
|
||||
* SessionStatus 객체
|
||||
* @param locale
|
||||
* Locale 객체
|
||||
* @return 치안대상 목록화면
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
@RequestMapping(value = "/update.do", method = RequestMethod.POST)
|
||||
public String update(@Valid @ModelAttribute("corpVO") final CorpVO corpVO,
|
||||
final BindingResult bindingResult, final Model model,
|
||||
final SessionStatus status, final Locale locale) throws Exception {
|
||||
// 사용자 인증 검사
|
||||
Boolean isAuthenticated = EgovUserDetailsHelper.isAuthenticated();
|
||||
if (isAuthenticated) {
|
||||
LoginUserVO loginUserVO = UserUtil.getMemberInfo();
|
||||
|
||||
// 등록은 관리자만 가능하지만, 수정/삭제는 관리자 + 해당 기관도 가능하다.
|
||||
if (loginUserVO.getIsAdmin()
|
||||
|| loginUserVO.getPlace1().equalsIgnoreCase(corpVO.getPlace1())) {
|
||||
// 유효성 검사
|
||||
beanValidator.validate(corpVO, bindingResult);
|
||||
if (bindingResult.hasErrors()) {
|
||||
return update(model, locale, corpVO);
|
||||
}
|
||||
|
||||
corpVO.setWriter(loginUserVO.getUserid());
|
||||
corpVO.setWriterPlace1(loginUserVO.getPlace1());
|
||||
|
||||
HashMap<String, Object> map = corpService.update(corpVO, null,
|
||||
null);
|
||||
|
||||
status.setComplete();
|
||||
|
||||
if ((Integer) map.get("result") == 1) {
|
||||
return makeRedirectUri(PageType.View, corpVO);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return "error/bizError";
|
||||
}
|
||||
|
||||
/**
|
||||
* 치안대상 정보를 삭제하고 목록화면을 반환한다.
|
||||
*
|
||||
* @param model
|
||||
* Model 객체
|
||||
* @param locale
|
||||
* Locale 객체
|
||||
* @param corpVO
|
||||
* 치안대상 VO
|
||||
* @return 치안대상 목록화면
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
@RequestMapping(value = "/delete.do", method = RequestMethod.POST)
|
||||
public String delete(final Model model, final Locale locale, final CorpVO corpVO) throws Exception {
|
||||
LoginUserVO loginUserVO = UserUtil.getMemberInfo();
|
||||
|
||||
// 등록은 관리자만 가능하지만, 수정/삭제는 관리자 + 해당 기관도 가능하다.
|
||||
if (loginUserVO.getIsAdmin()
|
||||
|| loginUserVO.getPlace1().equalsIgnoreCase(corpVO.getPlace1())) {
|
||||
CorpVO vo = corpService.select(corpVO);
|
||||
|
||||
HashMap<String, Object> result = corpService.delete(corpVO);
|
||||
if ((Integer) result.get("result") == 1) {
|
||||
return makeRedirectUri(PageType.List, vo);
|
||||
}
|
||||
}
|
||||
return makeRedirectUri(PageType.View, corpVO);
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,435 @@
|
|||
package kcg.faics.tg.web;
|
||||
|
||||
import java.io.BufferedInputStream;
|
||||
import java.io.File;
|
||||
import java.io.FileInputStream;
|
||||
import java.util.HashMap;
|
||||
import java.util.LinkedHashMap;
|
||||
import java.util.List;
|
||||
import java.util.Locale;
|
||||
import java.util.Map;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
|
||||
import kcg.faics.cmmn.bbs.BaseBbsService;
|
||||
import kcg.faics.cmmn.bbs.PageType;
|
||||
import kcg.faics.cmmn.excel.ExcelExporter;
|
||||
import kcg.faics.cmmn.file.FileResponser;
|
||||
import kcg.faics.cmmn.service.CodeService;
|
||||
import kcg.faics.cmmn.vo.CodeVO;
|
||||
import kcg.faics.sec.LoginUserVO;
|
||||
import kcg.faics.sec.UserUtil;
|
||||
import kcg.faics.tg.service.impl.DivMngServiceImpl;
|
||||
import kcg.faics.tg.vo.DivMngSearchVO;
|
||||
import kcg.faics.tg.vo.DivMngVO;
|
||||
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.context.MessageSource;
|
||||
import org.springframework.http.HttpStatus;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.ui.Model;
|
||||
import org.springframework.util.FileCopyUtils;
|
||||
import org.springframework.validation.BindingResult;
|
||||
import org.springframework.web.bind.annotation.ModelAttribute;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMethod;
|
||||
import org.springframework.web.bind.support.SessionStatus;
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
import org.springframework.web.multipart.MultipartHttpServletRequest;
|
||||
import org.springmodules.validation.commons.DefaultBeanValidator;
|
||||
|
||||
import egovframework.rte.fdl.property.EgovPropertyService;
|
||||
import egovframework.rte.fdl.security.userdetails.util.EgovUserDetailsHelper;
|
||||
|
||||
/**
|
||||
* 외사분실운영현황 컨트롤러.
|
||||
*
|
||||
* @author kimnomin
|
||||
*
|
||||
*/
|
||||
@Controller
|
||||
@RequestMapping("/target/divmng")
|
||||
public class DivMngController {
|
||||
/**
|
||||
* properties값을 가져오는 인터페이스.
|
||||
**/
|
||||
@Resource(name = "propertiesService")
|
||||
private EgovPropertyService propertiesService;
|
||||
|
||||
/**
|
||||
* message.properties의 값을 가져오는 인터페이스.
|
||||
*/
|
||||
@Autowired
|
||||
private MessageSource messageSource;
|
||||
|
||||
/**
|
||||
* Validator - 유효성 검사.
|
||||
**/
|
||||
@Resource(name = "beanValidator")
|
||||
private DefaultBeanValidator beanValidator;
|
||||
|
||||
/**
|
||||
* 코드관련 정보 인터페이스.
|
||||
*/
|
||||
@Resource(name = "codeService")
|
||||
private CodeService codeService;
|
||||
|
||||
/**
|
||||
* 외사분실운영현황 비지니스 로직 클래스.
|
||||
*/
|
||||
@Resource(name = "divMngService")
|
||||
private BaseBbsService<DivMngSearchVO, DivMngVO> divMngService;
|
||||
|
||||
/**
|
||||
* Redirect URI를 조합하여 반환한다.
|
||||
*
|
||||
* @param pageType
|
||||
* 화면구분
|
||||
* @param vo
|
||||
* 외사분실운영현황 VO
|
||||
* @return Redirect URI
|
||||
*/
|
||||
private String makeRedirectUri(final PageType pageType, final DivMngVO vo) {
|
||||
String uri = "redirect:/target/divmng";
|
||||
|
||||
switch (pageType) {
|
||||
case View:
|
||||
uri = String.format("%s/view.do?place=%s&no=%s", uri, vo.getPlace(), vo.getNo());
|
||||
break;
|
||||
case List:
|
||||
uri = String.format("%s/list.do?place=%s", uri, vo.getPlace());
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
||||
return uri;
|
||||
}
|
||||
|
||||
/**
|
||||
* 외사분실운영현황 정보 조회화면을 반환한다.
|
||||
*
|
||||
* @param model
|
||||
* Model 객체
|
||||
* @param divMngVO
|
||||
* 외사분실운영현황 VO
|
||||
* @return 외사분실운영현황 정보 조회화면
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
@RequestMapping(value = "/view.do")
|
||||
public String view(final Model model, final DivMngVO divMngVO) throws Exception {
|
||||
LoginUserVO loginUserVO = UserUtil.getMemberInfo();
|
||||
model.addAttribute("loginUserVO", loginUserVO);
|
||||
|
||||
DivMngVO vo = divMngService.select(divMngVO);
|
||||
model.addAttribute("divMngVO", vo);
|
||||
|
||||
return "/tg/divMngView.tiles";
|
||||
}
|
||||
|
||||
/**
|
||||
* 외사분실운영현황 목록화면을 반환한다.
|
||||
*
|
||||
* @param model
|
||||
* Model 객체
|
||||
* @param locale
|
||||
* Locale 객체
|
||||
* @param searchVO
|
||||
* 검색조건 VO
|
||||
* @return 외사분실운영현황 목록화면
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
@RequestMapping(value = "/list.do")
|
||||
public String list(final Model model, final Locale locale,
|
||||
@ModelAttribute("searchVO") final DivMngSearchVO searchVO)
|
||||
throws Exception {
|
||||
LoginUserVO loginUserVO = UserUtil.getMemberInfo();
|
||||
model.addAttribute("loginUserVO", loginUserVO);
|
||||
|
||||
List<CodeVO> placeList = codeService.getPlace1List(false, true);
|
||||
model.addAttribute("placeList", placeList);
|
||||
|
||||
List<DivMngVO> divMngList = divMngService.selectList(searchVO);
|
||||
model.addAttribute("divMngList", divMngList);
|
||||
|
||||
return "/tg/divMngList.tiles";
|
||||
}
|
||||
|
||||
/**
|
||||
* 외사분실운영현황 목록을 엑셀로 반환한다.
|
||||
*
|
||||
* @param model
|
||||
* Model 객체
|
||||
* @param locale
|
||||
* Locale 객체
|
||||
* @param searchVO
|
||||
* 검색조건 VO
|
||||
* @return 외사분실운영현황 목록 엑셀
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
@RequestMapping(value = "/listtoexcel.do")
|
||||
public String listToExcel(final Model model, final Locale locale,
|
||||
@ModelAttribute("searchVO") final DivMngSearchVO searchVO)
|
||||
throws Exception {
|
||||
String title = messageSource.getMessage("target.divmng", null, locale);
|
||||
|
||||
// 엑셀 헤더 생성
|
||||
LinkedHashMap<String, String> header = new LinkedHashMap<String, String>();
|
||||
header.put("placeStr", messageSource.getMessage("target.divmng.place", null, locale));
|
||||
header.put("local", messageSource.getMessage("target.divmng.local", null, locale));
|
||||
header.put("gubunStr", messageSource.getMessage("target.divmng.gubun", null, locale));
|
||||
header.put("staffNum", messageSource.getMessage("target.divmng.staffNum", null, locale));
|
||||
header.put("tel", messageSource.getMessage("target.divmng.tel", null, locale));
|
||||
|
||||
// 데이터 생성
|
||||
List<DivMngVO> divMngList = divMngService.selectList(searchVO);
|
||||
|
||||
// Export
|
||||
model.addAttribute("excel", new ExcelExporter<DivMngVO>(header, divMngList, title));
|
||||
model.addAttribute("filename", title);
|
||||
|
||||
return "excelView";
|
||||
}
|
||||
|
||||
/**
|
||||
* 외사분실운영현황 입력화면을 반환한다.
|
||||
*
|
||||
* @param model
|
||||
* Model 객체
|
||||
* @param divMngVO
|
||||
* 외사분실운영현황 VO
|
||||
* @return 외사분실운영현황 입력화면
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
@RequestMapping(value = "/add.do")
|
||||
public String add(final Model model, final DivMngVO divMngVO)
|
||||
throws Exception {
|
||||
Boolean isAuthenticated = EgovUserDetailsHelper.isAuthenticated();
|
||||
|
||||
if (isAuthenticated && UserUtil.isAdmin()) {
|
||||
LoginUserVO loginUserVO = UserUtil.getMemberInfo();
|
||||
model.addAttribute("loginUserVO", loginUserVO);
|
||||
model.addAttribute("registerFlag", "create");
|
||||
|
||||
List<CodeVO> placeList = codeService.getPlace1List(false, false);
|
||||
model.addAttribute("placeList", placeList);
|
||||
|
||||
divMngVO.setWriter(loginUserVO.getUserid());
|
||||
divMngVO.setPlace(loginUserVO.getPlace1());
|
||||
divMngVO.setPlaceStr(loginUserVO.getPlace1Str());
|
||||
|
||||
return "/tg/divMngAdd.tiles";
|
||||
} else {
|
||||
return makeRedirectUri(PageType.List, divMngVO);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 외사분실운영현황 정보를 입력한다.
|
||||
*
|
||||
* @param divMngVO
|
||||
* 외사분실운영현황 VO
|
||||
* @param bindingResult
|
||||
* BindingResult 객체
|
||||
* @param model
|
||||
* Model 객체
|
||||
* @param status
|
||||
* SessionStatus 객체
|
||||
* @param multiRequest
|
||||
* MultipartHttpServletRequest 객체
|
||||
* @return 외사분실운영현황 정보 조회화면
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
@RequestMapping(value = "/add.do", method = RequestMethod.POST)
|
||||
public String add(@ModelAttribute("divMngVO") final DivMngVO divMngVO,
|
||||
final BindingResult bindingResult, final Model model,
|
||||
final SessionStatus status,
|
||||
final MultipartHttpServletRequest multiRequest) throws Exception {
|
||||
// 사용자 인증 검사
|
||||
Boolean isAuthenticated = EgovUserDetailsHelper.isAuthenticated();
|
||||
if (isAuthenticated && UserUtil.isAdmin()) {
|
||||
// 유효성 검사
|
||||
beanValidator.validate(divMngVO, bindingResult);
|
||||
if (bindingResult.hasErrors()) {
|
||||
return add(model, divMngVO);
|
||||
}
|
||||
|
||||
final Map<String, MultipartFile> fileMap = multiRequest.getFileMap();
|
||||
HashMap<String, Object> resultMap = divMngService.insert(divMngVO, fileMap);
|
||||
|
||||
if ((Integer) resultMap.get("result") == 1) {
|
||||
status.setComplete();
|
||||
return makeRedirectUri(PageType.View, divMngVO);
|
||||
}
|
||||
}
|
||||
return "error/bizError";
|
||||
}
|
||||
|
||||
/**
|
||||
* 외사분실운영현황 수정화면을 반환한다.
|
||||
*
|
||||
* @param divMngVO
|
||||
* 외사분실운영현황 VO
|
||||
* @param model
|
||||
* Model 객체
|
||||
* @return 외사분실운영현황 수정화면
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
@RequestMapping(value = "/update.do")
|
||||
public String update(final DivMngVO divMngVO, final Model model) throws Exception {
|
||||
if (UserUtil.isAdmin()) {
|
||||
model.addAttribute("registerFlag", "modify");
|
||||
|
||||
DivMngVO vo = divMngService.select(divMngVO);
|
||||
model.addAttribute("divMngVO", vo);
|
||||
|
||||
LoginUserVO loginUserVO = UserUtil.getMemberInfo();
|
||||
model.addAttribute("loginUserVO", loginUserVO);
|
||||
|
||||
return "/tg/divMngAdd.tiles";
|
||||
}
|
||||
|
||||
return makeRedirectUri(PageType.View, divMngVO);
|
||||
}
|
||||
|
||||
/**
|
||||
* 외사분실운영현황 정보를 수정한다.
|
||||
*
|
||||
* @param divMngVO
|
||||
* 외사분실운영현황 VO
|
||||
* @param bindingResult
|
||||
* BindingResult 객체
|
||||
* @param model
|
||||
* Model 객체
|
||||
* @param status
|
||||
* SessionStatus 객체
|
||||
* @param multiRequest
|
||||
* MultipartHttpServletRequest 객체
|
||||
* @return 외사분실운영현황 조회화면
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
@RequestMapping(value = "/update.do", method = RequestMethod.POST)
|
||||
public String update(@ModelAttribute("divMngVO") final DivMngVO divMngVO,
|
||||
final BindingResult bindingResult, final Model model,
|
||||
final SessionStatus status,
|
||||
final MultipartHttpServletRequest multiRequest) throws Exception {
|
||||
// 사용자 인증 검사
|
||||
Boolean isAuthenticated = EgovUserDetailsHelper.isAuthenticated();
|
||||
if (isAuthenticated && UserUtil.isAdmin()) {
|
||||
// 유효성 검사
|
||||
beanValidator.validate(divMngVO, bindingResult);
|
||||
if (bindingResult.hasErrors()) {
|
||||
return update(divMngVO, model);
|
||||
}
|
||||
|
||||
String[] deleteFiles = multiRequest.getParameterValues("deleteFile");
|
||||
final Map<String, MultipartFile> fileMap = multiRequest.getFileMap();
|
||||
HashMap<String, Object> resultMap = divMngService.update(divMngVO, fileMap, deleteFiles);
|
||||
|
||||
if ((Integer) resultMap.get("result") > 0) {
|
||||
status.setComplete();
|
||||
return makeRedirectUri(PageType.View, divMngVO);
|
||||
}
|
||||
}
|
||||
|
||||
return update(divMngVO, model);
|
||||
}
|
||||
|
||||
/**
|
||||
* 외사분실운영현황 정보를 삭제한다.
|
||||
*
|
||||
* @param divMngVO
|
||||
* 외사분실운영현황 VO
|
||||
* @param model
|
||||
* Model 객체
|
||||
* @param status
|
||||
* SessionStatus 객체
|
||||
* @return 외사분실운영현황 목록화면
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
@RequestMapping(value = "/delete.do", method = RequestMethod.POST)
|
||||
public String delete(final DivMngVO divMngVO, final Model model,
|
||||
final SessionStatus status) throws Exception {
|
||||
|
||||
if (UserUtil.isAdmin()) {
|
||||
DivMngVO vo = divMngService.select(divMngVO);
|
||||
if (vo != null) {
|
||||
HashMap<String, Object> map = divMngService.delete(vo);
|
||||
if ((Integer) map.get("result") > 0) {
|
||||
return makeRedirectUri(PageType.List, vo);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return makeRedirectUri(PageType.View, divMngVO);
|
||||
}
|
||||
|
||||
/**
|
||||
* 파일을 반환한다.
|
||||
*
|
||||
* @param divMngVO
|
||||
* 외사분실운영현황 VO
|
||||
* @param fileId
|
||||
* 파일ID
|
||||
* @param request
|
||||
* HttpServletRequest 객체
|
||||
* @param response
|
||||
* HttpServletResponse 객체
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
@RequestMapping(value = "/download.do")
|
||||
public void fileResponse(final DivMngVO divMngVO, final String fileId,
|
||||
final HttpServletRequest request, final HttpServletResponse response)
|
||||
throws Exception {
|
||||
DivMngVO vo = divMngService.select(divMngVO);
|
||||
String filename = "";
|
||||
if ("fileImg".equals(fileId)) {
|
||||
filename = vo.getFileImg();
|
||||
} else if ("file1".equals(fileId)) {
|
||||
filename = vo.getFile1();
|
||||
} else if ("file2".equals(fileId)) {
|
||||
filename = vo.getFile2();
|
||||
} else if ("file3".equals(fileId)) {
|
||||
filename = vo.getFile3();
|
||||
}
|
||||
|
||||
if (StringUtils.isNotBlank(filename)) {
|
||||
String fileFullPath = propertiesService
|
||||
.getString(DivMngServiceImpl.FILE_PATH_KEYWORD) + filename;
|
||||
File file = new File(fileFullPath);
|
||||
if (file.exists()) {
|
||||
FileResponser.setResponse(file, filename, request, response);
|
||||
BufferedInputStream in = null;
|
||||
try {
|
||||
in = new BufferedInputStream(new FileInputStream(file));
|
||||
FileCopyUtils.copy(in, response.getOutputStream());
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
} finally {
|
||||
if (in != null) {
|
||||
try {
|
||||
in.close();
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
}
|
||||
} else {
|
||||
response.setStatus(HttpStatus.NOT_FOUND.value());
|
||||
throw new Exception();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,398 @@
|
|||
package kcg.faics.tg.web;
|
||||
|
||||
import java.io.BufferedInputStream;
|
||||
import java.io.File;
|
||||
import java.io.FileInputStream;
|
||||
import java.util.Arrays;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Locale;
|
||||
import java.util.Map;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
|
||||
import kcg.faics.cmmn.bbs.BaseBbsService;
|
||||
import kcg.faics.cmmn.bbs.PageType;
|
||||
import kcg.faics.cmmn.file.FileResponser;
|
||||
import kcg.faics.cmmn.service.CodeService;
|
||||
import kcg.faics.sec.LoginUserVO;
|
||||
import kcg.faics.sec.UserUtil;
|
||||
import kcg.faics.tg.FerryRouteType;
|
||||
import kcg.faics.tg.FerryRunTermType;
|
||||
import kcg.faics.tg.service.impl.FerryServiceImpl;
|
||||
import kcg.faics.tg.vo.FerrySearchVO;
|
||||
import kcg.faics.tg.vo.FerryVO;
|
||||
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.context.MessageSource;
|
||||
import org.springframework.http.HttpStatus;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.ui.Model;
|
||||
import org.springframework.util.FileCopyUtils;
|
||||
import org.springframework.validation.BindingResult;
|
||||
import org.springframework.web.bind.annotation.ModelAttribute;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMethod;
|
||||
import org.springframework.web.bind.support.SessionStatus;
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
import org.springframework.web.multipart.MultipartHttpServletRequest;
|
||||
import org.springmodules.validation.commons.DefaultBeanValidator;
|
||||
|
||||
import egovframework.rte.fdl.property.EgovPropertyService;
|
||||
import egovframework.rte.fdl.security.userdetails.util.EgovUserDetailsHelper;
|
||||
|
||||
/**
|
||||
* 국제여객선 컨트롤러.
|
||||
*
|
||||
* @author kimnomin
|
||||
*
|
||||
*/
|
||||
@Controller
|
||||
@RequestMapping("/target/ferry")
|
||||
public class FerryController {
|
||||
/**
|
||||
* properties값을 가져오는 인터페이스.
|
||||
**/
|
||||
@Resource(name = "propertiesService")
|
||||
private EgovPropertyService propertiesService;
|
||||
|
||||
/**
|
||||
* message.properties의 값을 가져오는 인터페이스.
|
||||
*/
|
||||
@Autowired
|
||||
private MessageSource messageSource;
|
||||
|
||||
/**
|
||||
* Validator - 유효성 검사.
|
||||
**/
|
||||
@Resource(name = "beanValidator")
|
||||
private DefaultBeanValidator beanValidator;
|
||||
|
||||
/**
|
||||
* 코드관련 정보 인터페이스.
|
||||
*/
|
||||
@Resource(name = "codeService")
|
||||
private CodeService codeService;
|
||||
|
||||
/**
|
||||
* 국제여객선 비지니스 로직 클래스.
|
||||
*/
|
||||
@Resource(name = "ferryService")
|
||||
private BaseBbsService<FerrySearchVO, FerryVO> ferryService;
|
||||
|
||||
/**
|
||||
* Redirect URI를 조합하여 반환한다.
|
||||
*
|
||||
* @param pageType
|
||||
* 화면구분
|
||||
* @param vo
|
||||
* 국제여객선 VO
|
||||
* @return Redirect URI
|
||||
*/
|
||||
private String makeRedirectUri(final PageType pageType, final FerryVO vo) {
|
||||
String uri = "redirect:/target/ferry";
|
||||
|
||||
switch (pageType) {
|
||||
case View:
|
||||
uri = String.format("%s/view.do?serNo=%s", uri, vo.getSerNo());
|
||||
break;
|
||||
case List:
|
||||
uri = String.format("%s/list.do?route=%s", uri, vo.getFerryRoute());
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
||||
return uri;
|
||||
}
|
||||
|
||||
/**
|
||||
* 국제여객선 정보 조회화면을 반환한다.
|
||||
*
|
||||
* @param model
|
||||
* Model 객체
|
||||
* @param ferryVO
|
||||
* 국제여객선 VO
|
||||
* @return 국제여객선 정보 조회화면
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
@RequestMapping(value = "/view.do")
|
||||
public String view(final Model model, final FerryVO ferryVO) throws Exception {
|
||||
LoginUserVO loginUserVO = UserUtil.getMemberInfo();
|
||||
model.addAttribute("loginUserVO", loginUserVO);
|
||||
|
||||
FerryVO vo = ferryService.select(ferryVO);
|
||||
model.addAttribute("ferryVO", vo);
|
||||
|
||||
return "/tg/ferryView.tiles";
|
||||
}
|
||||
|
||||
/**
|
||||
* 국제여객선 목록화면을 반환한다.
|
||||
*
|
||||
* @param model
|
||||
* Model 객체
|
||||
* @param locale
|
||||
* Locale 객체
|
||||
* @param searchVO
|
||||
* 검색조건 VO
|
||||
* @return 국제여객선 목록화면
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
@RequestMapping(value = "/list.do")
|
||||
public String list(final Model model, final Locale locale,
|
||||
@ModelAttribute("searchVO") final FerrySearchVO searchVO)
|
||||
throws Exception {
|
||||
LoginUserVO loginUserVO = UserUtil.getMemberInfo();
|
||||
model.addAttribute("loginUserVO", loginUserVO);
|
||||
|
||||
List<FerryRouteType> routeList = Arrays.asList(FerryRouteType.values());
|
||||
model.addAttribute("routeList", routeList);
|
||||
|
||||
if (StringUtils.isBlank(searchVO.getFerryRoute())) {
|
||||
searchVO.setFerryRoute(FerryRouteType.KR_CH.getCode());
|
||||
}
|
||||
List<FerryVO> ferryList = ferryService.selectList(searchVO);
|
||||
model.addAttribute("ferryList", ferryList);
|
||||
|
||||
return "/tg/ferryList.tiles";
|
||||
}
|
||||
|
||||
/**
|
||||
* 국제여객선 입력화면을 반환한다.
|
||||
*
|
||||
* @param model
|
||||
* Model 객체
|
||||
* @param ferryVO
|
||||
* 국제여객선 VO
|
||||
* @return 국제여객선 입력화면
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
@RequestMapping(value = "/add.do")
|
||||
public String add(final Model model, final FerryVO ferryVO)
|
||||
throws Exception {
|
||||
Boolean isAuthenticated = EgovUserDetailsHelper.isAuthenticated();
|
||||
|
||||
if (isAuthenticated && UserUtil.isAdmin()) {
|
||||
model.addAttribute("registerFlag", "create");
|
||||
|
||||
LoginUserVO loginUserVO = UserUtil.getMemberInfo();
|
||||
model.addAttribute("loginUserVO", loginUserVO);
|
||||
|
||||
List<FerryRouteType> routeList = FerryRouteType.values(FerryRouteType.KP);
|
||||
model.addAttribute("routeList", routeList);
|
||||
|
||||
List<FerryRunTermType> runTermList = Arrays.asList(FerryRunTermType.values());
|
||||
model.addAttribute("runTermList", runTermList);
|
||||
|
||||
ferryVO.setWriter(loginUserVO.getUserid());
|
||||
|
||||
return "/tg/ferryAdd.tiles";
|
||||
} else {
|
||||
return makeRedirectUri(PageType.List, ferryVO);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 국제여객선 정보를 입력한다.
|
||||
*
|
||||
* @param ferryVO
|
||||
* 국제여객선 VO
|
||||
* @param bindingResult
|
||||
* BindingResult 객체
|
||||
* @param model
|
||||
* Model 객체
|
||||
* @param status
|
||||
* SessionStatus 객체
|
||||
* @param multiRequest
|
||||
* MultipartHttpServletRequest 객체
|
||||
* @return 국제여객선 정보 조회화면
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
@RequestMapping(value = "/add.do", method = RequestMethod.POST)
|
||||
public String add(@ModelAttribute("ferryVO") final FerryVO ferryVO,
|
||||
final BindingResult bindingResult, final Model model,
|
||||
final SessionStatus status,
|
||||
final MultipartHttpServletRequest multiRequest) throws Exception {
|
||||
// 사용자 인증 검사
|
||||
Boolean isAuthenticated = EgovUserDetailsHelper.isAuthenticated();
|
||||
if (isAuthenticated && UserUtil.isAdmin()) {
|
||||
// 유효성 검사
|
||||
beanValidator.validate(ferryVO, bindingResult);
|
||||
if (bindingResult.hasErrors()) {
|
||||
return add(model, ferryVO);
|
||||
}
|
||||
|
||||
final Map<String, MultipartFile> fileMap = multiRequest.getFileMap();
|
||||
HashMap<String, Object> resultMap = ferryService.insert(ferryVO, fileMap);
|
||||
|
||||
if ((Integer) resultMap.get("result") == 1) {
|
||||
status.setComplete();
|
||||
return makeRedirectUri(PageType.View, ferryVO);
|
||||
}
|
||||
}
|
||||
return "error/bizError";
|
||||
}
|
||||
|
||||
/**
|
||||
* 국제여객선 수정화면을 반환한다.
|
||||
*
|
||||
* @param ferryVO
|
||||
* 국제여객선 VO
|
||||
* @param model
|
||||
* Model 객체
|
||||
* @return 국제여객선 수정화면
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
@RequestMapping(value = "/update.do")
|
||||
public String update(final FerryVO ferryVO, final Model model) throws Exception {
|
||||
if (UserUtil.isAdmin()) {
|
||||
model.addAttribute("registerFlag", "modify");
|
||||
|
||||
FerryVO vo = ferryService.select(ferryVO);
|
||||
model.addAttribute("ferryVO", vo);
|
||||
|
||||
LoginUserVO loginUserVO = UserUtil.getMemberInfo();
|
||||
model.addAttribute("loginUserVO", loginUserVO);
|
||||
|
||||
List<FerryRouteType> routeList = FerryRouteType.values(FerryRouteType.KP);
|
||||
model.addAttribute("routeList", routeList);
|
||||
|
||||
List<FerryRunTermType> runTermList = Arrays.asList(FerryRunTermType.values());
|
||||
model.addAttribute("runTermList", runTermList);
|
||||
|
||||
return "/tg/ferryAdd.tiles";
|
||||
}
|
||||
|
||||
return makeRedirectUri(PageType.View, ferryVO);
|
||||
}
|
||||
|
||||
/**
|
||||
* 국제여객선 정보를 수정한다.
|
||||
*
|
||||
* @param ferryVO
|
||||
* 국제여객선 VO
|
||||
* @param bindingResult
|
||||
* BindingResult 객체
|
||||
* @param model
|
||||
* Model 객체
|
||||
* @param status
|
||||
* SessionStatus 객체
|
||||
* @param multiRequest
|
||||
* MultipartHttpServletRequest 객체
|
||||
* @return 국제여객선 조회화면
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
@RequestMapping(value = "/update.do", method = RequestMethod.POST)
|
||||
public String update(@ModelAttribute("ferryVO") final FerryVO ferryVO,
|
||||
final BindingResult bindingResult, final Model model,
|
||||
final SessionStatus status,
|
||||
final MultipartHttpServletRequest multiRequest) throws Exception {
|
||||
// 사용자 인증 검사
|
||||
Boolean isAuthenticated = EgovUserDetailsHelper.isAuthenticated();
|
||||
if (isAuthenticated && UserUtil.isAdmin()) {
|
||||
// 유효성 검사
|
||||
beanValidator.validate(ferryVO, bindingResult);
|
||||
if (bindingResult.hasErrors()) {
|
||||
return update(ferryVO, model);
|
||||
}
|
||||
|
||||
String[] deleteFiles = multiRequest.getParameterValues("deleteFile");
|
||||
final Map<String, MultipartFile> fileMap = multiRequest.getFileMap();
|
||||
HashMap<String, Object> resultMap = ferryService.update(ferryVO, fileMap, deleteFiles);
|
||||
|
||||
if ((Integer) resultMap.get("result") > 0) {
|
||||
status.setComplete();
|
||||
return makeRedirectUri(PageType.View, ferryVO);
|
||||
}
|
||||
}
|
||||
|
||||
return update(ferryVO, model);
|
||||
}
|
||||
|
||||
/**
|
||||
* 국제여객선 정보를 삭제한다.
|
||||
*
|
||||
* @param ferryVO
|
||||
* 국제여객선 VO
|
||||
* @param model
|
||||
* Model 객체
|
||||
* @param status
|
||||
* SessionStatus 객체
|
||||
* @return 국제여객선 목록화면
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
@RequestMapping(value = "/delete.do", method = RequestMethod.POST)
|
||||
public String delete(final FerryVO ferryVO, final Model model,
|
||||
final SessionStatus status) throws Exception {
|
||||
|
||||
if (UserUtil.isAdmin()) {
|
||||
FerryVO vo = ferryService.select(ferryVO);
|
||||
if (vo != null) {
|
||||
HashMap<String, Object> map = ferryService.delete(vo);
|
||||
if ((Integer) map.get("result") > 0) {
|
||||
return makeRedirectUri(PageType.List, vo);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return makeRedirectUri(PageType.View, ferryVO);
|
||||
}
|
||||
|
||||
/**
|
||||
* 파일을 반환한다.
|
||||
*
|
||||
* @param ferryVO
|
||||
* 국제여객선 VO
|
||||
* @param request
|
||||
* HttpServletRequest 객체
|
||||
* @param response
|
||||
* HttpServletResponse 객체
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
@RequestMapping(value = "/download.do")
|
||||
public void fileResponse(final FerryVO ferryVO,
|
||||
final HttpServletRequest request, final HttpServletResponse response)
|
||||
throws Exception {
|
||||
FerryVO vo = ferryService.select(ferryVO);
|
||||
String filename = vo.getImgFile();
|
||||
|
||||
if (StringUtils.isNotBlank(filename)) {
|
||||
String fileFullPath = propertiesService
|
||||
.getString(FerryServiceImpl.FILE_PATH_KEYWORD) + filename;
|
||||
File file = new File(fileFullPath);
|
||||
if (file.exists()) {
|
||||
FileResponser.setResponse(file, filename, request, response);
|
||||
BufferedInputStream in = null;
|
||||
try {
|
||||
in = new BufferedInputStream(new FileInputStream(file));
|
||||
FileCopyUtils.copy(in, response.getOutputStream());
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
} finally {
|
||||
if (in != null) {
|
||||
try {
|
||||
in.close();
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
}
|
||||
} else {
|
||||
response.setStatus(HttpStatus.NOT_FOUND.value());
|
||||
throw new Exception();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,418 @@
|
|||
package kcg.faics.tg.web;
|
||||
|
||||
import java.io.BufferedInputStream;
|
||||
import java.io.File;
|
||||
import java.io.FileInputStream;
|
||||
import java.text.SimpleDateFormat;
|
||||
import java.util.Date;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import javax.validation.Valid;
|
||||
|
||||
import kcg.faics.cmmn.file.FileResponser;
|
||||
import kcg.faics.cmmn.service.CodeService;
|
||||
import kcg.faics.cmmn.vo.CodeVO;
|
||||
import kcg.faics.sec.LoginUserVO;
|
||||
import kcg.faics.sec.UserUtil;
|
||||
import kcg.faics.tg.service.WeakPlaceService;
|
||||
import kcg.faics.tg.vo.WeakPlaceSearchVO;
|
||||
import kcg.faics.tg.vo.WeakPlaceVO;
|
||||
|
||||
import org.apache.commons.io.FilenameUtils;
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.context.MessageSource;
|
||||
import org.springframework.http.HttpStatus;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.ui.Model;
|
||||
import org.springframework.ui.ModelMap;
|
||||
import org.springframework.util.FileCopyUtils;
|
||||
import org.springframework.validation.BindingResult;
|
||||
import org.springframework.web.bind.annotation.ModelAttribute;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMethod;
|
||||
import org.springframework.web.bind.support.SessionStatus;
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
import org.springframework.web.multipart.MultipartHttpServletRequest;
|
||||
import org.springmodules.validation.commons.DefaultBeanValidator;
|
||||
|
||||
import egovframework.rte.fdl.property.EgovPropertyService;
|
||||
import egovframework.rte.fdl.security.userdetails.util.EgovUserDetailsHelper;
|
||||
|
||||
/**
|
||||
* 외사취약지 컨트롤러.
|
||||
*
|
||||
* @author kimnomin
|
||||
*
|
||||
*/
|
||||
@Controller
|
||||
@RequestMapping("/target/weakplace")
|
||||
public class WeakPlaceController {
|
||||
/**
|
||||
* properties값을 가져오는 인터페이스.
|
||||
**/
|
||||
@Resource(name = "propertiesService")
|
||||
private EgovPropertyService propertiesService;
|
||||
|
||||
/**
|
||||
* message.properties의 값을 가져오는 인터페이스.
|
||||
*/
|
||||
@Autowired
|
||||
private MessageSource messageSource;
|
||||
|
||||
/**
|
||||
* 코드관련 정보 인터페이스.
|
||||
*/
|
||||
@Resource(name = "codeService")
|
||||
private CodeService codeService;
|
||||
|
||||
/**
|
||||
* Validator - 유효성 검사.
|
||||
**/
|
||||
@Resource(name = "beanValidator")
|
||||
private DefaultBeanValidator beanValidator;
|
||||
|
||||
/**
|
||||
* 외사취약지 비지니스 로직 클래스.
|
||||
*/
|
||||
@Resource(name = "weakPlaceService")
|
||||
private WeakPlaceService weakPlaceService;
|
||||
|
||||
/**
|
||||
* 외사취약지 조회 화면을 반환한다.
|
||||
*
|
||||
* @param vo
|
||||
* 검색할 외사취약지 VO
|
||||
* @param model
|
||||
* Model 객체
|
||||
* @return 외사취약지 조회 화면
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
@RequestMapping(value = "/view.do")
|
||||
public String view(final WeakPlaceVO vo, final ModelMap model)
|
||||
throws Exception {
|
||||
|
||||
LoginUserVO loginUserVO = UserUtil.getMemberInfo();
|
||||
model.addAttribute("loginUserVO", loginUserVO);
|
||||
|
||||
WeakPlaceVO weakPlaceVO = weakPlaceService.select(vo);
|
||||
model.addAttribute("weakPlaceVO", weakPlaceVO);
|
||||
|
||||
String filename1Ext = "";
|
||||
String filename1 = weakPlaceVO.getFilename1();
|
||||
if (!StringUtils.isBlank(filename1)) {
|
||||
filename1Ext = FilenameUtils.getExtension(filename1).toLowerCase();
|
||||
}
|
||||
model.addAttribute("filename1Ext", filename1Ext);
|
||||
|
||||
return "/tg/weakPlaceView.tiles";
|
||||
}
|
||||
|
||||
/**
|
||||
* 외사취약지 목록 화면을 반환한다.
|
||||
*
|
||||
* @param searchVO
|
||||
* 검색정보 VO
|
||||
* @param model
|
||||
* Model 객체
|
||||
* @return 외사취약지 목록화면
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
@RequestMapping(value = "/list.do")
|
||||
public String list(@ModelAttribute("searchVO") final WeakPlaceSearchVO searchVO,
|
||||
final ModelMap model) throws Exception {
|
||||
|
||||
LoginUserVO loginUserVO = UserUtil.getMemberInfo();
|
||||
model.addAttribute("loginUserVO", loginUserVO);
|
||||
|
||||
List<CodeVO> placeList = codeService.getPlace1List(CodeService.POLICE_STATION_LIST);
|
||||
model.addAttribute("placeList", placeList);
|
||||
|
||||
List<HashMap<String, Object>> statsPerPlace = weakPlaceService.selectStatsPerPlace();
|
||||
model.addAttribute("statsPerPlace", statsPerPlace);
|
||||
|
||||
List<WeakPlaceVO> weakPlaceList = weakPlaceService.selectList(searchVO);
|
||||
model.addAttribute("weakPlaceList", weakPlaceList);
|
||||
|
||||
Date today = new Date();
|
||||
SimpleDateFormat simpleDate = new SimpleDateFormat("yyyy. MM. dd.");
|
||||
String todayStr = simpleDate.format(today);
|
||||
model.addAttribute("today", todayStr);
|
||||
|
||||
|
||||
return "/tg/weakPlaceList.tiles";
|
||||
}
|
||||
|
||||
/**
|
||||
* 외사취약지 입력화면을 반환한다.
|
||||
*
|
||||
* @param model
|
||||
* Model 객체
|
||||
* @param weakPlaceVO
|
||||
* 입력할 외사취약지 VO
|
||||
* @return 외사취약지 입력화면
|
||||
* @throws Exception
|
||||
* 기본예외처리
|
||||
*/
|
||||
@RequestMapping(value = "/add.do")
|
||||
public String add(final Model model, final WeakPlaceVO weakPlaceVO) throws Exception {
|
||||
LoginUserVO loginUserVO = UserUtil.getMemberInfo();
|
||||
WeakPlaceVO vo;
|
||||
if (weakPlaceVO == null) {
|
||||
vo = new WeakPlaceVO();
|
||||
} else {
|
||||
vo = weakPlaceVO;
|
||||
}
|
||||
vo.setWriter(loginUserVO.getUserid());
|
||||
vo.setPlace1(loginUserVO.getPlace1());
|
||||
vo.setPlace1str(loginUserVO.getPlace1Str());
|
||||
|
||||
List<CodeVO> placeList = codeService.getPlace1List(CodeService.POLICE_STATION_LIST);
|
||||
|
||||
int tempWpNo = 0;
|
||||
String tempPlace1Code = "";
|
||||
HashMap<String, Integer> wpNoMap = new HashMap<String, Integer>();
|
||||
for (int i = 0; i < CodeService.POLICE_STATION_LIST.length; i++) {
|
||||
tempWpNo = 0;
|
||||
tempPlace1Code = CodeService.POLICE_STATION_LIST[i];
|
||||
tempWpNo = weakPlaceService.selectMaxWpNo(tempPlace1Code);
|
||||
wpNoMap.put(tempPlace1Code, ++tempWpNo);
|
||||
|
||||
// 중앙부처 사용자는 placeList의 첫번째 기관의 wpno 값을 기본으로 한다.
|
||||
if ("PS00".equalsIgnoreCase(vo.getPlace1())
|
||||
&& tempPlace1Code.equalsIgnoreCase(placeList.get(0).getCode2())) {
|
||||
vo.setWpNo(tempWpNo);
|
||||
} else if (tempPlace1Code.equalsIgnoreCase(vo.getPlace1())) {
|
||||
vo.setWpNo(tempWpNo);
|
||||
}
|
||||
}
|
||||
model.addAttribute("wpNoMap", wpNoMap);
|
||||
|
||||
model.addAttribute("placeList", placeList);
|
||||
model.addAttribute("weakPlaceVO", vo);
|
||||
model.addAttribute("loginUserVO", "loginUserVO");
|
||||
model.addAttribute("registerFlag", "create");
|
||||
|
||||
return "/tg/weakPlaceAdd.tiles";
|
||||
}
|
||||
|
||||
/**
|
||||
* 외사취약지 정보를 입력한다.
|
||||
*
|
||||
* @param multiRequest
|
||||
* mutipartform 객체
|
||||
* @param weakPlaceVO
|
||||
* 외사취약지 VO
|
||||
* @param bindingResult
|
||||
* 유효성 검사결과 객체
|
||||
* @param model
|
||||
* 모델 객체
|
||||
* @param status
|
||||
* SessionStatus 객체
|
||||
* @return 외사취약지 조회 화면
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
@RequestMapping(value = "/add.do", method = RequestMethod.POST)
|
||||
public String add(final MultipartHttpServletRequest multiRequest,
|
||||
@Valid @ModelAttribute("weakPlaceVO") final WeakPlaceVO weakPlaceVO,
|
||||
final BindingResult bindingResult, final Model model,
|
||||
final SessionStatus status) throws Exception {
|
||||
// 사용자 인증 검사
|
||||
Boolean isAuthenticated = EgovUserDetailsHelper.isAuthenticated();
|
||||
if (isAuthenticated) {
|
||||
// 유효성 검사
|
||||
beanValidator.validate(weakPlaceVO, bindingResult);
|
||||
if (bindingResult.hasErrors()) {
|
||||
model.addAttribute("weakPlaceVO", weakPlaceVO);
|
||||
model.addAttribute("registerFlag", "create");
|
||||
return "tg/weakPlaceAdd.tiles";
|
||||
}
|
||||
|
||||
// 파일 저장 및 데이터 입력
|
||||
final Map<String, MultipartFile> fileMap = multiRequest.getFileMap();
|
||||
HashMap<String, Object> map = weakPlaceService.insert(weakPlaceVO, fileMap);
|
||||
|
||||
status.setComplete();
|
||||
|
||||
if ((Integer) map.get("result") == 1) {
|
||||
return String.format("redirect:/target/weakplace/view.do?place1=%s&wpNo=%s", map.get("place1"), map.get("wpNo"));
|
||||
}
|
||||
}
|
||||
|
||||
return "error/bizError";
|
||||
}
|
||||
|
||||
/**
|
||||
* 외사취약지 수정화면을 반환한다.
|
||||
*
|
||||
* @param model
|
||||
* Model 객체
|
||||
* @param weakPlaceVO
|
||||
* 외사취약지 VO
|
||||
* @return 외사취약지 수정화면
|
||||
* @throws Exception
|
||||
* 기본예외처리
|
||||
*/
|
||||
@RequestMapping(value = "/update.do", method = RequestMethod.GET)
|
||||
public String update(final Model model, final WeakPlaceVO weakPlaceVO) throws Exception {
|
||||
LoginUserVO loginUserVO = UserUtil.getMemberInfo();
|
||||
|
||||
// 관리자만 수정 가능
|
||||
if (loginUserVO.getAuthAdmin() == 1) {
|
||||
WeakPlaceVO vo = weakPlaceService.select(weakPlaceVO);
|
||||
model.addAttribute("weakPlaceVO", vo);
|
||||
model.addAttribute("loginUserVO", loginUserVO);
|
||||
model.addAttribute("registerFlag", "modify");
|
||||
|
||||
return "/tg/weakPlaceAdd.tiles";
|
||||
}
|
||||
|
||||
return "redirect:/target/weakplace/view.do?place1="
|
||||
+ weakPlaceVO.getPlace1() + "&wpNo=" + weakPlaceVO.getWpNo();
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* 외사취약지 정보를 수정한다.
|
||||
*
|
||||
* @param multiRequest
|
||||
* mutipartform 객체
|
||||
* @param weakPlaceVO
|
||||
* 외사취약지 VO
|
||||
* @param bindingResult
|
||||
* 유효성 검사결과 객체
|
||||
* @param model
|
||||
* 모델 객체
|
||||
* @param status
|
||||
* SessionStatus 객체
|
||||
* @return 외사취약지 조회 화면
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
@RequestMapping(value = "/update.do", method = RequestMethod.POST)
|
||||
public String update(final MultipartHttpServletRequest multiRequest,
|
||||
@Valid @ModelAttribute("weakPlaceVO") final WeakPlaceVO weakPlaceVO,
|
||||
final BindingResult bindingResult, final Model model,
|
||||
final SessionStatus status) throws Exception {
|
||||
LoginUserVO loginUserVO = UserUtil.getMemberInfo();
|
||||
|
||||
// 관리자만 수정 가능
|
||||
if (loginUserVO.getAuthAdmin() == 1) {
|
||||
// 유효성 검사
|
||||
beanValidator.validate(weakPlaceVO, bindingResult);
|
||||
if (bindingResult.hasErrors()) {
|
||||
model.addAttribute("weakPlaceVO", weakPlaceVO);
|
||||
model.addAttribute("registerFlag", "modify");
|
||||
return "tg/weakPlaceAdd.tiles";
|
||||
}
|
||||
|
||||
String[] deleteFiles = multiRequest.getParameterValues("deleteFile");
|
||||
final Map<String, MultipartFile> fileMap = multiRequest.getFileMap();
|
||||
HashMap<String, Object> map = weakPlaceService.update(weakPlaceVO, fileMap, deleteFiles);
|
||||
|
||||
status.setComplete();
|
||||
|
||||
if ((Integer) map.get("result") > 0) {
|
||||
return "redirect:/target/weakplace/view.do?place1="
|
||||
+ weakPlaceVO.getPlace1() + "&wpNo="
|
||||
+ weakPlaceVO.getWpNo();
|
||||
}
|
||||
}
|
||||
|
||||
return "redirect:/target/weakplace/view.do?place1="
|
||||
+ weakPlaceVO.getPlace1() + "&wpNo=" + weakPlaceVO.getWpNo();
|
||||
}
|
||||
|
||||
/**
|
||||
* 외사취약지 정보를 삭제한다.
|
||||
*
|
||||
* @param weakPlaceVO
|
||||
* 외사취약지 VO
|
||||
* @param model
|
||||
* Model 객체
|
||||
* @param status
|
||||
* SessionStatus 객체
|
||||
* @return 외사취약지 목록 화면
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
@RequestMapping(value = "/delete.do", method = RequestMethod.POST)
|
||||
public String delete(final WeakPlaceVO weakPlaceVO, final Model model,
|
||||
final SessionStatus status) throws Exception {
|
||||
LoginUserVO loginUserVO = UserUtil.getMemberInfo();
|
||||
|
||||
// 관리자만 삭제 가능
|
||||
if (loginUserVO.getAuthAdmin() == 1) {
|
||||
WeakPlaceVO vo = weakPlaceService.select(weakPlaceVO);
|
||||
if (vo != null) {
|
||||
HashMap<String, Object> map = weakPlaceService.delete(weakPlaceVO);
|
||||
if ((Integer) map.get("result") > 0) {
|
||||
return "redirect:/target/weakplace/list.do";
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return "redirect:/susa/incident/view.do?place1="
|
||||
+ weakPlaceVO.getPlace1() + "&wpNo=" + weakPlaceVO.getWpNo();
|
||||
}
|
||||
|
||||
/**
|
||||
* 파일을 반환한다.
|
||||
*
|
||||
* @param weakPlaceVO
|
||||
* 외사취약지 VO
|
||||
* @param seq
|
||||
* 파일 인덱스
|
||||
* @param request
|
||||
* HttpServletRequest 객체
|
||||
* @param response
|
||||
* HttpServletResponse 객체
|
||||
* @throws Exception
|
||||
* 기본 예외 처리
|
||||
*/
|
||||
@RequestMapping(value = "/download.do")
|
||||
public void fileResponse(final WeakPlaceVO weakPlaceVO, final int seq,
|
||||
final HttpServletRequest request, final HttpServletResponse response) throws Exception {
|
||||
WeakPlaceVO vo = weakPlaceService.select(weakPlaceVO);
|
||||
String filename = "";
|
||||
if (seq == 1) {
|
||||
filename = vo.getFilename1();
|
||||
} else if (seq == 2) {
|
||||
filename = vo.getFilename2();
|
||||
}
|
||||
|
||||
if (StringUtils.isNotBlank(filename)) {
|
||||
String fileFullPath = propertiesService.getString("Target.wp.fileStorePath") + filename;
|
||||
File file = new File(fileFullPath);
|
||||
if (file.exists()) {
|
||||
FileResponser.setResponse(file, filename, request, response);
|
||||
BufferedInputStream in = null;
|
||||
try {
|
||||
in = new BufferedInputStream(new FileInputStream(file));
|
||||
FileCopyUtils.copy(in, response.getOutputStream());
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
} finally {
|
||||
if (in != null) {
|
||||
try {
|
||||
in.close();
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
}
|
||||
} else {
|
||||
response.setStatus(HttpStatus.NOT_FOUND.value());
|
||||
throw new Exception();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,8 @@
|
|||
/**
|
||||
* 외사대상목표 컨트롤러 패키지.
|
||||
*/
|
||||
/**
|
||||
* @author kimnomin
|
||||
*
|
||||
*/
|
||||
package kcg.faics.tg.web;
|
||||
File diff suppressed because it is too large
Load Diff
|
|
@ -1,17 +1,17 @@
|
|||
|
||||
#-----------------------------------------------------------------------
|
||||
#
|
||||
# globals.properties : \uc2dc\uc2a4\ud15c
|
||||
# globals.properties : \uC2DC\uC2A4\uD15C
|
||||
#
|
||||
#-----------------------------------------------------------------------
|
||||
# 1. key = value \uad6c\uc870\uc785\ub2c8\ub2e4.
|
||||
# 2. key\uac12\uc740 \uacf5\ubc31\ubb38\uc790\ub97c \ud3ec\ud568\ubd88\uac00, value\uac12\uc740 \uacf5\ubc31\ubb38\uc790\ub97c \uac00\ub2a5
|
||||
# 3. key\uac12\uc73c\ub85c \ud55c\uae00\uc744 \uc0ac\uc6a9\ubd88\uac00, value\uac12\uc740 \ud55c\uae00\uc0ac\uc6a9\uc774 \uac00\ub2a5
|
||||
# 4. \uc904\uc744 \ubc14\uafc0 \ud544\uc694\uac00 \uc788\uc73c\uba74 '\'\ub97c \ub77c\uc778\uc758 \ub05d\uc5d0 \ucd94\uac00(\ub9cc\uc57d '\'\ubb38\uc790\ub97c \uc0ac\uc6a9\ud574\uc57c \ud558\ub294 \uacbd\uc6b0\ub294 '\\'\ub97c \uc0ac\uc6a9)
|
||||
# 5. Windows\uc5d0\uc11c\uc758 \ub514\ub809\ud1a0\ub9ac \ud45c\uc2dc : '\\' or '/' ('\' \uc0ac\uc6a9\ud558\uba74 \uc548\ub428)
|
||||
# 6. Unix\uc5d0\uc11c\uc758 \ub514\ub809\ud1a0\ub9ac \ud45c\uc2dc : '/'
|
||||
# 7. \uc8fc\uc11d\ubb38 \ucc98\ub9ac\ub294 #\uc0ac\uc6a9
|
||||
# 8. value\uac12 \ub4a4\uc5d0 \uc2a4\ud398\uc774\uc2a4\uac00 \uc874\uc7ac\ud558\ub294 \uacbd\uc6b0 \uc11c\ube14\ub9bf\uc5d0\uc11c \ucc38\uc870\ud560\ub54c\ub294 \uc5d0\ub7ec\ubc1c\uc0dd\ud560 \uc218 \uc788\uc73c\ubbc0\ub85c trim()\ud558\uac70\ub098 \ub9c8\uc9c0\ub9c9 \uacf5\ubc31\uc5c6\uc774 properties \uac12\uc744 \uc124\uc815\ud560\uac83
|
||||
# 1. key = value \uAD6C\uC870\uC785\uB2C8\uB2E4.
|
||||
# 2. key\uAC12\uC740 \uACF5\uBC31\uBB38\uC790\uB97C \uD3EC\uD568\uBD88\uAC00, value\uAC12\uC740 \uACF5\uBC31\uBB38\uC790\uB97C \uAC00\uB2A5
|
||||
# 3. key\uAC12\uC73C\uB85C \uD55C\uAE00\uC744 \uC0AC\uC6A9\uBD88\uAC00, value\uAC12\uC740 \uD55C\uAE00\uC0AC\uC6A9\uC774 \uAC00\uB2A5
|
||||
# 4. \uC904\uC744 \uBC14\uAFC0 \uD544\uC694\uAC00 \uC788\uC73C\uBA74 '\'\uB97C \uB77C\uC778\uC758 \uB05D\uC5D0 \uCD94\uAC00(\uB9CC\uC57D '\'\uBB38\uC790\uB97C \uC0AC\uC6A9\uD574\uC57C \uD558\uB294 \uACBD\uC6B0\uB294 '\\'\uB97C \uC0AC\uC6A9)
|
||||
# 5. Windows\uC5D0\uC11C\uC758 \uB514\uB809\uD1A0\uB9AC \uD45C\uC2DC : '\\' or '/' ('\' \uC0AC\uC6A9\uD558\uBA74 \uC548\uB428)
|
||||
# 6. Unix\uC5D0\uC11C\uC758 \uB514\uB809\uD1A0\uB9AC \uD45C\uC2DC : '/'
|
||||
# 7. \uC8FC\uC11D\uBB38 \uCC98\uB9AC\uB294 #\uC0AC\uC6A9
|
||||
# 8. value\uAC12 \uB4A4\uC5D0 \uC2A4\uD398\uC774\uC2A4\uAC00 \uC874\uC7AC\uD558\uB294 \uACBD\uC6B0 \uC11C\uBE14\uB9BF\uC5D0\uC11C \uCC38\uC870\uD560\uB54C\uB294 \uC5D0\uB7EC\uBC1C\uC0DD\uD560 \uC218 \uC788\uC73C\uBBC0\uB85C trim()\uD558\uAC70\uB098 \uB9C8\uC9C0\uB9C9 \uACF5\uBC31\uC5C6\uC774 properties \uAC12\uC744 \uC124\uC815\uD560\uAC83
|
||||
#-----------------------------------------------------------------------
|
||||
|
||||
#DBServiceServer
|
||||
|
|
@ -22,12 +22,15 @@
|
|||
|
||||
|
||||
#TEST DB Server
|
||||
Global.datasource.driverClassName=oracle.jdbc.driver.OracleDriver
|
||||
Global.datasource.url=jdbc:oracle:thin:@106.247.244.146:51521:faics
|
||||
Global.datasource.username=new_faics
|
||||
Global.datasource.password=tkdlqjdhltk12#$
|
||||
|
||||
#Global.datasource.driverClassName=oracle.jdbc.driver.OracleDriver
|
||||
#Global.datasource.url=jdbc:oracle:thin:@106.247.244.146:51521:faics
|
||||
#Global.datasource.username=new_faics
|
||||
#Global.datasource.password=tkdlqjdhltk12#$
|
||||
|
||||
Global.datasource.driverClassName=net.sf.log4jdbc.sql.jdbcapi.DriverSpy
|
||||
Global.datasource.url=jdbc:log4jdbc:postgresql://192.168.0.157:5432/faics
|
||||
Global.datasource.username=dbnt0031
|
||||
Global.datasource.password=dbnt0928!
|
||||
|
||||
|
||||
#File path
|
||||
|
|
@ -59,18 +62,18 @@ Global.crypto.hased.password = U7Epd/1HVt76n5o0NAXS9f1ArmdigKFEJYgRfWeBjIA=
|
|||
Global.crypto.password.algorithm = SHA-256
|
||||
|
||||
#System URL
|
||||
#\uc0ac\uc774\ubc84\uc678\uc0ac\uc815\ubcf4\uc2dc\uc2a4\ud15c(\uad6c)
|
||||
#\uC0AC\uC774\uBC84\uC678\uC0AC\uC815\uBCF4\uC2DC\uC2A4\uD15C(\uAD6C)
|
||||
Url.FAICS.preSystem = http://10.29.9.40:8500/login.aspx
|
||||
|
||||
#\uad6d\uc81c\ud574\uc591\uc815\ubcf4\uc2dc\uc2a4\ud15c(\uc2e4\uc11c\ubc84)
|
||||
#\uAD6D\uC81C\uD574\uC591\uC815\uBCF4\uC2DC\uC2A4\uD15C(\uC2E4\uC11C\uBC84)
|
||||
Url.IMIS.loginProc = http://10.29.16.122
|
||||
|
||||
#\uad6d\uc81c\ud574\uc591\uc815\ubcf4\uc2dc\uc2a4\ud15c(\ud14c\uc2a4\ud2b8)
|
||||
#\uAD6D\uC81C\uD574\uC591\uC815\uBCF4\uC2DC\uC2A4\uD15C(\uD14C\uC2A4\uD2B8)
|
||||
#Url.IMIS.loginProc = http://192.168.10.115:8888/logic_login.php
|
||||
|
||||
#\uad6d\ubbfc\uc548\uc804\ucc98
|
||||
#\uAD6D\uBBFC\uC548\uC804\uCC98
|
||||
Url.MPSS = http://www.mpss.go.kr/
|
||||
|
||||
|
||||
#\uc815\uc801 \uc18c\uc2a4 \ubc84\uc804
|
||||
StaticFile.version=180102
|
||||
#StaticFile.version=180102
|
||||
|
|
@ -0,0 +1,2 @@
|
|||
log4jdbc.spylogdelegator.name=net.sf.log4jdbc.log.slf4j.Slf4jSpyLogDelegator
|
||||
log4jdbc.dump.sql.maxlinelength=0
|
||||
|
|
@ -270,15 +270,12 @@
|
|||
A.ADDR_DTL ,
|
||||
A.VLTN_TYPE ,
|
||||
B.CODENM || ' (' || A.VLTN_DTL || ')' VLTN_DTL,
|
||||
DECODE(A.IVSN_TYPE, 'YRB2', '1', '') IVSN_TYPE1,
|
||||
DECODE(A.IVSN_TYPE, 'YRD1', '1', '') IVSN_TYPE2,
|
||||
DECODE(A.IVSN_TYPE, 'YRA1', '1', '') IVSN_TYPE3,
|
||||
DECODE(A.IVSN_TYPE, 'YRB1', '1', '') IVSN_TYPE4,
|
||||
|
||||
|
||||
|
||||
DECODE(A.SPEC_BATL_YN, 'Y', '1' , '') SPEC_BATL_YN,
|
||||
DECODE(A.NLL_YN, 'Y', '1' , '') NLL_YN,
|
||||
case A.IVSN_TYPE when 'YRB2' then '1' else '' end IVSN_TYPE1,
|
||||
case A.IVSN_TYPE when 'YRD1' then '1' else '' end IVSN_TYPE2,
|
||||
case A.IVSN_TYPE when 'YRA1' then '1' else '' end IVSN_TYPE3,
|
||||
case A.IVSN_TYPE when 'YRB1' then '1' else '' end IVSN_TYPE4,
|
||||
case A.SPEC_BATL_YN when 'Y' then '1' else '' end SPEC_BATL_YN,
|
||||
case A.NLL_YN when 'Y' then '1' else '' end NLL_YN,
|
||||
A.AGENCY_TYPE ,
|
||||
A.AGENCY_GUARD ,
|
||||
G.CODENM AGENCY_GUARD_STR ,
|
||||
|
|
@ -300,20 +297,21 @@
|
|||
A.VIO_CNT ,
|
||||
A.VIO_PRTD_AMT ,
|
||||
A.PROC_COND ,
|
||||
DECODE(A.PROC_COND, '02', '1', '') PROC_COND_Y,
|
||||
DECODE(A.PROC_COND, '01', '1', '') PROC_COND_N,
|
||||
case A.PROC_COND when '02' then '1' else '' end PROC_COND_Y,
|
||||
case A.PROC_COND when '01' then '1' else '' end PROC_COND_N,
|
||||
A.MRGN_PYMT_YN ,
|
||||
|
||||
DECODE(A.MRGN_PYMT_YN, 'Y', A.MRGN_PYMT_AMT, '' ) MRGN_PYMT_AMT,
|
||||
DECODE(A.MRGN_PYMT_YN, 'N', A.MRGN_PYMT_AMT, '' ) NO_MRGN_PYMT_AMT,
|
||||
case when A.MRGN_PYMT_YN != null then 'Y' end MRGN_PYMT_AMT,
|
||||
case when A.MRGN_PYMT_AMT != null then '' end MRGN_PYMT_AMT,
|
||||
case when A.MRGN_PYMT_YN != null then 'N' end NO_MRGN_PYMT_AMT,
|
||||
case when A.MRGN_PYMT_AMT != null then '' end NO_MRGN_PYMT_AMT,
|
||||
TO_CHAR(MRGN_PYMT_DATE, 'YYYY-MM-DD hh24:mi') MRGN_PYMT_DATE ,
|
||||
DECODE(A.MRGN_PYMT_YN, 'N', '1', '') NOT_PAYMENT,
|
||||
case A.MRGN_PYMT_YN when 'N' then '1' else '' end NOT_PAYMENT,
|
||||
A.SHIP_PROC_TYPE ,
|
||||
DECODE(A.SHIP_PROC_TYPE, '01', '1', '') SHIP_PROC_TYPE_A,
|
||||
DECODE(A.SHIP_PROC_TYPE, '02', '1', '') SHIP_PROC_TYPE_B,
|
||||
DECODE(A.SHIP_PROC_TYPE, '03', '1', '') SHIP_PROC_TYPE_C,
|
||||
DECODE(A.SHIP_PROC_TYPE, '04', '1', '') SHIP_PROC_TYPE_D,
|
||||
DECODE(A.SHIP_PROC_TYPE, '05', '1', '') SHIP_PROC_TYPE_E,
|
||||
case A.SHIP_PROC_TYPE when '01' then '1' else '' end SHIP_PROC_TYPE_A,
|
||||
case A.SHIP_PROC_TYPE when '02' then '1' else '' end SHIP_PROC_TYPE_B,
|
||||
case A.SHIP_PROC_TYPE when '03' then '1' else '' end SHIP_PROC_TYPE_C,
|
||||
case A.SHIP_PROC_TYPE when '04' then '1' else '' end SHIP_PROC_TYPE_D,
|
||||
case A.SHIP_PROC_TYPE when '05' then '1' else '' end SHIP_PROC_TYPE_E,
|
||||
|
||||
A.SHIP_CMSN_COST,
|
||||
A.DTTN_CAP_CNT ,
|
||||
|
|
@ -325,7 +323,7 @@
|
|||
F.CODENM WO_DTTN_STR,
|
||||
TO_CHAR(A.FIELD_ARST_DATE, 'YYYY-MM-DD hh24:mi') FIELD_ARST_DATE,
|
||||
TO_CHAR(A.FIELD_RLS_DATE, 'YYYY-MM-DD hh24:mi') FIELD_RLS_DATE ,
|
||||
DECODE(A.FIELD_ARST_DATE, NULL, '', '1') FIELD_CNT,
|
||||
case A.FIELD_ARST_DATE when NULL then '' else '1' end FIELD_CNT,
|
||||
A.LEAD_DISTANCE ,
|
||||
A.LEAD_HOUR ,
|
||||
A.LEAD_MINUTE ,
|
||||
|
|
@ -337,22 +335,25 @@
|
|||
A.REG_DATE ,
|
||||
A.REG_USER ,
|
||||
A.REG_AGENCY
|
||||
FROM T_CHN_ARREST_INFO A,
|
||||
TCODE B , -- 위반내용
|
||||
(SELECT CODE, UP_CODE, CODE_NM FROM CD_CODE C WHERE GP_CODE = 'A001' ) C, -- 시군구
|
||||
TCODE D , -- 선적
|
||||
TCODE E , -- 선종
|
||||
(SELECT CODE1, CODE2, CODENM FROM TCODE WHERE CODE1 = 'T005' ) F , -- 무혐의불구속
|
||||
(SELECT CODE1, CODE2, CODENM FROM TCODE WHERE CODE1 = 'C001' ) G , --
|
||||
(SELECT CODE1, CODE2, CODENM FROM TCODE WHERE CODE1 = 'T004' ) H , -- 선질
|
||||
(SELECT CODE, UP_CODE, CODE_NM FROM CD_CODE C WHERE GP_CODE = 'A001' AND UP_CODE ='0000' ) I -- 특별광역시도
|
||||
FROM
|
||||
T_CHN_ARREST_INFO A
|
||||
right outer join
|
||||
(SELECT CODE1, CODE2, CODENM
|
||||
FROM TCODE WHERE CODE1 = 'C001') G
|
||||
on g.code2 = a.agency_guard,
|
||||
TCODE B ,
|
||||
(SELECT CODE, UP_CODE, CODE_NM FROM CD_CODE C WHERE GP_CODE = 'A001' ) C,
|
||||
TCODE D ,
|
||||
TCODE E ,
|
||||
(SELECT CODE1, CODE2, CODENM FROM TCODE WHERE CODE1 = 'T005' ) F ,
|
||||
(SELECT CODE1, CODE2, CODENM FROM TCODE WHERE CODE1 = 'T004' ) H ,
|
||||
(SELECT CODE, UP_CODE, CODE_NM FROM CD_CODE C WHERE GP_CODE = 'A001' AND UP_CODE ='0000' ) I
|
||||
WHERE A.DEL_YN = 'N'
|
||||
AND (A.VLTN_TYPE = B.CODE2 AND B.CODE1 = 'T003')
|
||||
AND (A.ADDR_CITY = C.CODE AND A.ADDR_AREA = C.UP_CODE)
|
||||
AND (A.SHIP_MENT = D.CODE2 AND D.CODE1 = 'SSRR')
|
||||
AND (A.SHIP_TYPE = E.CODE2 AND E.CODE1 = 'FA81')
|
||||
AND A.WO_DTTN_TYPE = F.CODE2
|
||||
AND G.CODE2(+) = A.AGENCY_GUARD
|
||||
AND A.SHIP_QLTY = H.CODE2
|
||||
AND A.ADDR_AREA = I.CODE
|
||||
]]>
|
||||
|
|
@ -511,18 +512,30 @@
|
|||
A.ADDR_DTL ,
|
||||
A.VLTN_TYPE ,
|
||||
B.CODENM || ' (' || A.VLTN_DTL || ')' VLTN_DTL,
|
||||
DECODE(A.IVSN_TYPE, 'YRB2', '1', '') IVSN_TYPE1,
|
||||
DECODE(A.IVSN_TYPE, 'YRD1', '1', '') IVSN_TYPE2,
|
||||
DECODE(A.IVSN_TYPE, 'YRA1', '1', '') IVSN_TYPE3,
|
||||
DECODE(A.IVSN_TYPE, 'YRB1', '1', '') IVSN_TYPE4,
|
||||
|
||||
|
||||
|
||||
DECODE(A.SPEC_BATL_YN, 'Y', '1' , '') SPEC_BATL_YN,
|
||||
DECODE(A.NLL_YN, 'Y', '1' , '') NLL_YN,
|
||||
case A.IVSN_TYPE
|
||||
when 'YRB2' then '1'
|
||||
else '' end IVSN_TYPE1,
|
||||
case A.IVSN_TYPE
|
||||
when 'YRD1' then '1'
|
||||
else '' end IVSN_TYPE2,
|
||||
case A.IVSN_TYPE
|
||||
when 'YRA1' then '1'
|
||||
else '' end IVSN_TYPE3,
|
||||
case A.IVSN_TYPE
|
||||
when 'YRB1' then '1'
|
||||
else '' end IVSN_TYPE4,
|
||||
case A.SPEC_BATL_YN
|
||||
when 'Y' then '1'
|
||||
else '' end SPEC_BATL_YN,
|
||||
case A.NLL_YN
|
||||
when 'Y' then '1'
|
||||
else '' end NLL_YN,
|
||||
A.AGENCY_TYPE ,
|
||||
A.AGENCY_GUARD ,
|
||||
DECODE(A.AGENCY_TYPE, '01', '해경', '02', '해수부', '해군') || ' ' || G.CODENM AGENCY_GUARD_STR,
|
||||
case A.AGENCY_TYPE
|
||||
when '01' then '해경'
|
||||
when '02' then '해수부'
|
||||
else '해군' end || ' ' || G.CODENM AGENCY_GUARD_STR,
|
||||
A.AGENCY_VESSEL ,
|
||||
A.SHIP_NAME ,
|
||||
A.SHIP_TONNAGE ,
|
||||
|
|
@ -541,21 +554,48 @@
|
|||
A.VIO_CNT ,
|
||||
A.VIO_PRTD_AMT ,
|
||||
A.PROC_COND ,
|
||||
DECODE(A.PROC_COND, '02', '1', '') PROC_COND_Y,
|
||||
DECODE(A.PROC_COND, '01', '1', '') PROC_COND_N,
|
||||
case A.PROC_COND
|
||||
when '02' then '1'
|
||||
else '' end PROC_COND_Y,
|
||||
case A.PROC_COND
|
||||
when '01' then '1'
|
||||
else '' end PROC_COND_N,
|
||||
A.MRGN_PYMT_YN ,
|
||||
|
||||
DECODE(A.MRGN_PYMT_YN, 'Y', A.MRGN_PYMT_AMT, '' ) MRGN_PYMT_AMT,
|
||||
DECODE(A.MRGN_PYMT_YN, 'N', A.MRGN_PYMT_AMT, '' ) NO_MRGN_PYMT_AMT,
|
||||
case A.MRGN_PYMT_YN
|
||||
when 'Y' then A.MRGN_PYMT_AMT
|
||||
else null
|
||||
end MRGN_PYMT_AMT,
|
||||
case A.MRGN_PYMT_YN
|
||||
when 'N' then A.MRGN_PYMT_AMT
|
||||
else null
|
||||
end NO_MRGN_PYMT_AMT,
|
||||
TO_CHAR(MRGN_PYMT_DATE, 'YYYY-MM-DD hh24:mi') MRGN_PYMT_DATE ,
|
||||
DECODE(A.MRGN_PYMT_YN, 'N', '1', '') NOT_PAYMENT,
|
||||
case A.MRGN_PYMT_YN
|
||||
when 'N'
|
||||
then '1'
|
||||
else '' end NOT_PAYMENT,
|
||||
A.SHIP_PROC_TYPE ,
|
||||
DECODE(A.SHIP_PROC_TYPE, '01', '1', '') SHIP_PROC_TYPE_A,
|
||||
DECODE(A.SHIP_PROC_TYPE, '02', '1', '') SHIP_PROC_TYPE_B,
|
||||
DECODE(A.SHIP_PROC_TYPE, '03', '1', '') SHIP_PROC_TYPE_C,
|
||||
DECODE(A.SHIP_PROC_TYPE, '04', '1', '') SHIP_PROC_TYPE_D,
|
||||
DECODE(A.SHIP_PROC_TYPE, '05', '1', '') SHIP_PROC_TYPE_E,
|
||||
|
||||
case A.SHIP_PROC_TYPE
|
||||
when '01' then '1'
|
||||
else ''
|
||||
end SHIP_PROC_TYPE_A,
|
||||
case A.SHIP_PROC_TYPE
|
||||
when '02' then '1'
|
||||
else ''
|
||||
end SHIP_PROC_TYPE_B,
|
||||
case A.SHIP_PROC_TYPE
|
||||
when '03' then '1'
|
||||
else ''
|
||||
end SHIP_PROC_TYPE_C,
|
||||
case A.SHIP_PROC_TYPE
|
||||
when '04' then '1'
|
||||
else ''
|
||||
end SHIP_PROC_TYPE_D,
|
||||
case A.SHIP_PROC_TYPE
|
||||
when '05' then '1'
|
||||
else ''
|
||||
end SHIP_PROC_TYPE_E,
|
||||
A.SHIP_CMSN_COST,
|
||||
A.DTTN_CAP_CNT ,
|
||||
A.DTTN_MATE_CNT ,
|
||||
|
|
@ -566,7 +606,10 @@
|
|||
F.CODENM WO_DTTN_STR,
|
||||
TO_CHAR(A.FIELD_ARST_DATE, 'YYYY-MM-DD hh24:mi') FIELD_ARST_DATE,
|
||||
TO_CHAR(A.FIELD_RLS_DATE, 'YYYY-MM-DD hh24:mi') FIELD_RLS_DATE ,
|
||||
DECODE(A.FIELD_ARST_DATE, NULL, '', '1') FIELD_CNT,
|
||||
case A.FIELD_ARST_DATE
|
||||
when null then ''
|
||||
else '1'
|
||||
end FIELD_CNT,
|
||||
A.LEAD_DISTANCE ,
|
||||
A.LEAD_HOUR ,
|
||||
A.LEAD_MINUTE ,
|
||||
|
|
@ -578,13 +621,22 @@
|
|||
A.REG_DATE ,
|
||||
A.REG_USER ,
|
||||
A.REG_AGENCY
|
||||
FROM T_CHN_ARREST_INFO A,
|
||||
TCODE B , -- 위반내용
|
||||
FROM T_CHN_ARREST_INFO A
|
||||
right outer join
|
||||
(select
|
||||
CODE1,
|
||||
CODE2,
|
||||
CODENM
|
||||
from
|
||||
TCODE
|
||||
where
|
||||
CODE1 = 'C001' ) G
|
||||
on G.CODE2 = A.AGENCY_GUARD,
|
||||
TCODE B ,
|
||||
(SELECT CODE, UP_CODE, CODE_NM FROM CD_CODE C WHERE GP_CODE = 'A001' ) C, -- 시군구
|
||||
TCODE D , -- 선적
|
||||
TCODE E , -- 선종
|
||||
TCODE D ,
|
||||
TCODE E ,
|
||||
(SELECT CODE1, CODE2, CODENM FROM TCODE WHERE CODE1 = 'T005' ) F , -- 무혐의불구속
|
||||
(SELECT CODE1, CODE2, CODENM FROM TCODE WHERE CODE1 = 'C001' ) G , --
|
||||
(SELECT CODE1, CODE2, CODENM FROM TCODE WHERE CODE1 = 'T004' ) H , -- 선질
|
||||
(SELECT CODE, UP_CODE, CODE_NM FROM CD_CODE C WHERE GP_CODE = 'A001' AND UP_CODE ='0000' ) I -- 특별광역시도
|
||||
WHERE A.DEL_YN = 'N'
|
||||
|
|
@ -593,7 +645,6 @@
|
|||
AND (A.SHIP_MENT = D.CODE2 AND D.CODE1 = 'SSRR')
|
||||
AND (A.SHIP_TYPE = E.CODE2 AND E.CODE1 = 'FA81')
|
||||
AND A.WO_DTTN_TYPE = F.CODE2
|
||||
AND G.CODE2(+) = A.AGENCY_GUARD
|
||||
AND A.SHIP_QLTY = H.CODE2
|
||||
AND A.ADDR_AREA = I.CODE
|
||||
]]>
|
||||
|
|
@ -947,13 +998,12 @@
|
|||
A.VLTN_TYPE ,
|
||||
B.CODENM || ' (' || A.VLTN_DTL || ')' VLTN_DTL,
|
||||
A.IVSN_TYPE ,
|
||||
DECODE(A.IVSN_TYPE, 'YRB2', 1, 0) IVSN_TYPE1,
|
||||
DECODE(A.IVSN_TYPE, 'YRD1', 1, 0) IVSN_TYPE2,
|
||||
DECODE(A.IVSN_TYPE, 'YRA1', 1, 0) IVSN_TYPE3,
|
||||
DECODE(A.IVSN_TYPE, 'YRB1', 1, 0) IVSN_TYPE4,
|
||||
|
||||
DECODE(A.SPEC_BATL_YN , 'Y', 1, 0) SPEC_BATL,
|
||||
DECODE(A.NLL_YN , 'Y', 1, 0) NLL,
|
||||
case A.IVSN_TYPE when 'YRB2' then 1 else 0 end IVSN_TYPE1,
|
||||
case A.IVSN_TYPE when 'YRD1' then 1 else 0 end IVSN_TYPE2,
|
||||
case A.IVSN_TYPE when 'YRA1' then 1 else 0 end IVSN_TYPE3,
|
||||
case A.IVSN_TYPE when 'YRB1' then 1 else 0 end IVSN_TYPE4,
|
||||
case A.SPEC_BATL_YN when 'Y' then 1 else 0 end SPEC_BATL,
|
||||
case A.NLL_YN when 'Y' then 1 else 0 end NLL,
|
||||
A.AGENCY_TYPE ,
|
||||
A.AGENCY_GUARD ,
|
||||
G.CODENM AGENCY_GUARD_STR ,
|
||||
|
|
@ -974,21 +1024,26 @@
|
|||
A.VIO_CNT ,
|
||||
A.VIO_PRTD_AMT ,
|
||||
A.PROC_COND ,
|
||||
DECODE(A.PROC_COND, '01', 1, 0) PROC_COND1,
|
||||
DECODE(A.PROC_COND, '02', 1, 0) PROC_COND2,
|
||||
case A.PROC_COND when '01' then 1 else 0 end PROC_COND1,
|
||||
case A.PROC_COND when '02' then 1 else 0 end PROC_COND2,
|
||||
A.MRGN_PYMT_YN ,
|
||||
DECODE(A.MRGN_PYMT_YN, 'N', 1, 0) PYMT_N_CNT,
|
||||
--A.MRGN_PYMT_AMT ,
|
||||
DECODE(MRGN_PYMT_YN, 'Y', MRGN_PYMT_AMT, 0) MRGN_PYMT_AMT,
|
||||
DECODE(MRGN_PYMT_YN, 'N', MRGN_PYMT_AMT, 0) NO_MRGN_PYMT_AMT,
|
||||
case MRGN_PYMT_YN
|
||||
when 'Y' then MRGN_PYMT_AMT
|
||||
else 0
|
||||
end MRGN_PYMT_AMT,
|
||||
case MRGN_PYMT_YN
|
||||
when 'N' then MRGN_PYMT_AMT
|
||||
else 0
|
||||
end NO_MRGN_PYMT_AMT,
|
||||
case A.MRGN_PYMT_YN when 'N' then 1 else 0 end PYMT_N_CNT,
|
||||
|
||||
TO_CHAR(MRGN_PYMT_DATE, 'YYYY-MM-DD') MRGN_PYMT_DATE ,
|
||||
A.SHIP_PROC_TYPE ,
|
||||
DECODE(A.SHIP_PROC_TYPE, '01', 1, 0) SHIP_PROC_TYPE_A,
|
||||
DECODE(A.SHIP_PROC_TYPE, '02', 1, 0) SHIP_PROC_TYPE_B,
|
||||
DECODE(A.SHIP_PROC_TYPE, '03', 1, 0) SHIP_PROC_TYPE_C,
|
||||
DECODE(A.SHIP_PROC_TYPE, '04', 1, 0) SHIP_PROC_TYPE_D,
|
||||
DECODE(A.SHIP_PROC_TYPE, '05', 1, 0) SHIP_PROC_TYPE_E,
|
||||
case A.SHIP_PROC_TYPE when '01' then 1 else 0 end SHIP_PROC_TYPE_A,
|
||||
case A.SHIP_PROC_TYPE when '02' then 1 else 0 end SHIP_PROC_TYPE_B,
|
||||
case A.SHIP_PROC_TYPE when '03' then 1 else 0 end SHIP_PROC_TYPE_C,
|
||||
case A.SHIP_PROC_TYPE when '04' then 1 else 0 end SHIP_PROC_TYPE_D,
|
||||
case A.SHIP_PROC_TYPE when '05' then 1 else 0 end SHIP_PROC_TYPE_E,
|
||||
|
||||
A.SHIP_CMSN_COST ,
|
||||
A.DTTN_CAP_CNT ,
|
||||
|
|
@ -999,7 +1054,7 @@
|
|||
F.CODENM WO_DTTN_STR,
|
||||
TO_CHAR(A.FIELD_ARST_DATE, 'YYYY-MM-DD hh24:mi') FIELD_ARST_DATE,
|
||||
TO_CHAR(A.FIELD_RLS_DATE, 'YYYY-MM-DD hh24:mi') FIELD_RLS_DATE ,
|
||||
DECODE(A.FIELD_ARST_DATE, NULL, 0, 1) FIELD_CNT,
|
||||
case A.FIELD_ARST_DATE when NULL then 0 else 1 end FIELD_CNT,
|
||||
A.LEAD_DISTANCE ,
|
||||
A.LEAD_HOUR ,
|
||||
A.LEAD_MINUTE ,
|
||||
|
|
@ -1011,20 +1066,21 @@
|
|||
A.REG_DATE ,
|
||||
A.REG_USER ,
|
||||
A.REG_AGENCY
|
||||
FROM T_CHN_ARREST_INFO A,
|
||||
FROM T_CHN_ARREST_INFO A
|
||||
right outer join
|
||||
(SELECT CODE1, CODE2, CODENM FROM TCODE WHERE CODE1 = 'C001' ) G on G.CODE2 = A.AGENCY_GUARD,
|
||||
TCODE B , -- 위반내용
|
||||
(SELECT CODE, UP_CODE, CODE_NM FROM CD_CODE C WHERE GP_CODE = 'A001' ) C, -- 시군구
|
||||
TCODE D , -- 선적
|
||||
TCODE E , -- 선종
|
||||
(SELECT CODE1, CODE2, CODENM FROM TCODE WHERE CODE1 = 'T005' ) F, -- 무혐의 불구속
|
||||
(SELECT CODE1, CODE2, CODENM FROM TCODE WHERE CODE1 = 'C001' ) G
|
||||
(SELECT CODE1, CODE2, CODENM FROM TCODE WHERE CODE1 = 'T005' ) F -- 무혐의 불구속
|
||||
|
||||
WHERE A.DEL_YN = 'N'
|
||||
AND (A.VLTN_TYPE = B.CODE2 AND B.CODE1 = 'T003')
|
||||
AND (A.ADDR_CITY = C.CODE AND A.ADDR_AREA = C.UP_CODE)
|
||||
AND (A.SHIP_MENT = D.CODE2 AND D.CODE1 = 'SSRR')
|
||||
AND (A.SHIP_TYPE = E.CODE2 AND E.CODE1 = 'FA81')
|
||||
AND A.WO_DTTN_TYPE = F.CODE2
|
||||
AND G.CODE2(+) = A.AGENCY_GUARD
|
||||
]]>
|
||||
<if test="startDate != null and startDate != ''"><![CDATA[
|
||||
AND A.ARST_DATE >= TO_DATE( #{startDate} || ' 00:00', 'YYYY-MM-DD hh24:mi')
|
||||
|
|
@ -1176,7 +1232,7 @@
|
|||
AND 1 = 0
|
||||
</if>
|
||||
<![CDATA[
|
||||
)
|
||||
) list
|
||||
]]>
|
||||
</select>
|
||||
|
||||
|
|
@ -1520,7 +1576,7 @@
|
|||
REG_AGENCY
|
||||
|
||||
) VALUES (
|
||||
T_CHN_ARREST_INFO_ID_SEQ.NEXTVAL,
|
||||
nextval('chn_arrest_bd_seq'),
|
||||
TO_DATE(#{arrestDate}, 'YYYY-MM-DD hh24:mi'),
|
||||
#{agencyType},
|
||||
#{agencyGuard},
|
||||
|
|
@ -1529,18 +1585,18 @@
|
|||
#{violateType},
|
||||
#{violateDetail},
|
||||
#{invasionType},
|
||||
NVL(#{specBatlYn}, 'N'),
|
||||
NVL(#{nllYn}, 'N'),
|
||||
COALESCE(#{specBatlYn}, 'N'),
|
||||
COALESCE(#{nllYn}, 'N'),
|
||||
#{woDetentionType},
|
||||
TO_DATE(#{fieldArrestDate}, 'YYYY-MM-DD hh24:mi'),
|
||||
TO_DATE(#{fieldReleaseDate}, 'YYYY-MM-DD hh24:mi'),
|
||||
NVL(#{leadDistance}, 0),
|
||||
NVL(#{leadHour}, 0),
|
||||
NVL(#{leadMinute}, 0),
|
||||
NVL(#{captainCount}, 0),
|
||||
NVL(#{mateCount}, 0),
|
||||
NVL(#{engineerCount}, 0),
|
||||
NVL(#{crewCount}, 0),
|
||||
COALESCE(#{leadDistance}, 0),
|
||||
COALESCE(#{leadHour}, '0'),
|
||||
COALESCE(#{leadMinute}, '0'),
|
||||
COALESCE(#{captainCount}, 0),
|
||||
COALESCE(#{mateCount}, 0),
|
||||
COALESCE(#{engineerCount}, 0),
|
||||
COALESCE(#{crewCount}, 0),
|
||||
#{shipProcType},
|
||||
#{commissionCost},
|
||||
#{gearCast},
|
||||
|
|
@ -1573,7 +1629,7 @@
|
|||
TO_DATE(#{marginPaymentDate}, 'YYYY-MM-DD hh24:mi'),
|
||||
#{status},
|
||||
#{delYn},
|
||||
SYSDATE,
|
||||
NOW(),
|
||||
#{regUser},
|
||||
#{regAgency}
|
||||
|
||||
|
|
@ -1666,8 +1722,8 @@
|
|||
VLTN_TYPE=#{violateType},
|
||||
VLTN_DTL=#{violateDetail},
|
||||
IVSN_TYPE=#{invasionType},
|
||||
SPEC_BATL_YN=NVL(#{specBatlYn}, 'N'),
|
||||
NLL_YN=NVL(#{nllYn}, 'N'),
|
||||
SPEC_BATL_YN=COALESCE(#{specBatlYn}, 'N'),
|
||||
NLL_YN=COALESCE(#{nllYn}, 'N'),
|
||||
AGENCY_TYPE=#{agencyType},
|
||||
AGENCY_GUARD=#{agencyGuard},
|
||||
AGENCY_VESSEL=#{agencyVessel},
|
||||
|
|
|
|||
|
|
@ -3,34 +3,38 @@
|
|||
<mapper namespace="Board">
|
||||
|
||||
<select id="Board.selectBoardList" parameterType="boardSearchVO" resultType="boardVO">
|
||||
<![CDATA[
|
||||
SELECT
|
||||
BD_SEQ AS SEQ, BD_MB_ID AS USERID, BD_GROUP_SEQ AS GROUPSEQ,
|
||||
BD_CATEGORY AS CATEGORY, BD_NAME AS USERNAME, BD_CONTENT AS CONTENT,
|
||||
BD_SUBJECT AS SUBJECT, BD_PARENT_SEQ AS PARENTSEQ, BD_PREV_SEQ AS PREVSEQ,
|
||||
BD_NEXT_SEQ AS NEXTSEQ, BD_STEP AS STEP, BD_DEPTH AS DEPTH,
|
||||
BD_REGDATE AS REGDATE, BD_HIT AS HIT, BD_RECOMMEND AS RECOMMEND,
|
||||
BD_IP AS IP, BD_NOTICE AS NOTICE, BD_HTML AS HTML,
|
||||
BD_NUM1 AS NUM1, BD_NUM2 AS NUM2, BD_DATA1 AS DATA1, BD_DATA2 AS DATA2,
|
||||
select BD_SEQ AS SEQ,
|
||||
BD_MB_ID AS USERID,
|
||||
BD_GROUP_SEQ AS GROUPSEQ,
|
||||
BD_CATEGORY AS CATEGORY,
|
||||
BD_NAME AS USERNAME,
|
||||
BD_CONTENT AS CONTENT,
|
||||
BD_SUBJECT AS SUBJECT,
|
||||
BD_PARENT_SEQ AS PARENTSEQ,
|
||||
BD_PREV_SEQ AS PREVSEQ,
|
||||
BD_NEXT_SEQ AS NEXTSEQ,
|
||||
BD_STEP AS STEP,
|
||||
BD_DEPTH AS DEPTH,
|
||||
BD_REGDATE AS REGDATE,
|
||||
BD_HIT AS HIT,
|
||||
BD_RECOMMEND AS RECOMMEND,
|
||||
BD_IP AS IP,
|
||||
BD_NOTICE AS NOTICE,
|
||||
BD_HTML AS HTML,
|
||||
BD_NUM1 AS NUM1,
|
||||
BD_NUM2 AS NUM2,
|
||||
BD_DATA1 AS DATA1,
|
||||
BD_DATA2 AS DATA2,
|
||||
FILECNT
|
||||
FROM (
|
||||
SELECT
|
||||
ROWNUM RNUM, ALL_LIST.*, (SELECT #{id} FROM DUAL) ID,
|
||||
(SELECT COUNT(*) FROM H3_BD_${id}_FILE WHERE BF_BD_SEQ = ALL_LIST.BD_SEQ) AS FILECNT
|
||||
FROM (
|
||||
SELECT
|
||||
*
|
||||
FROM H3_BD_${id}_LIST BBS
|
||||
WHERE 1 = 1
|
||||
]]>
|
||||
<choose>
|
||||
<when test='category == " " and id == "stat_bbs"'>
|
||||
</when>
|
||||
<otherwise>
|
||||
from H3_BD_${id}_LIST list
|
||||
left outer join (select BF_BD_SEQ, count(*) as filecnt
|
||||
from H3_BD_notice_FILE
|
||||
group by BF_BD_SEQ) file
|
||||
on list.bd_seq = file.bf_bd_seq
|
||||
<where>
|
||||
<if test='category != null and category != ""'>
|
||||
AND BD_CATEGORY = #{category}
|
||||
</otherwise>
|
||||
</choose>
|
||||
|
||||
</if>
|
||||
<if test="searchKeyword != null and searchKeyword != ''">
|
||||
<choose>
|
||||
<when test="searchCondition == 0">
|
||||
|
|
@ -44,43 +48,27 @@
|
|||
</when>
|
||||
</choose>
|
||||
</if>
|
||||
<![CDATA[ ORDER BY
|
||||
BBS.BD_NOTICE DESC,
|
||||
BBS.BD_GROUP_SEQ DESC,
|
||||
BBS.BD_STEP ASC
|
||||
|
||||
) ALL_LIST
|
||||
)
|
||||
WHERE
|
||||
RNUM > #{firstIndex} AND
|
||||
RNUM <= #{firstIndex} + #{recordCountPerPage}
|
||||
]]>
|
||||
</where>
|
||||
ORDER BY BD_NOTICE DESC, BD_GROUP_SEQ DESC, BD_STEP asc
|
||||
limit #{recordCountPerPage} offset #{firstIndex}
|
||||
</select>
|
||||
|
||||
<select id="Board.selectBoardTotalCnt" parameterType="boardSearchVO" resultType="int">
|
||||
<![CDATA[
|
||||
SELECT
|
||||
COUNT(*)
|
||||
FROM
|
||||
H3_BD_${id}_LIST
|
||||
]]>
|
||||
</select>
|
||||
|
||||
<select id="Board.selectBoardListTotCnt" parameterType="boardSearchVO" resultType="int">
|
||||
<![CDATA[
|
||||
SELECT
|
||||
COUNT(*)
|
||||
FROM
|
||||
H3_BD_${id}_LIST
|
||||
WHERE 1=1
|
||||
]]>
|
||||
<choose>
|
||||
<when test='category == " " and id == "stat_bbs"'>
|
||||
</when>
|
||||
<otherwise>
|
||||
<where>
|
||||
<if test='category != null and category != ""'>
|
||||
AND BD_CATEGORY = #{category}
|
||||
</otherwise>
|
||||
</choose>
|
||||
</if>
|
||||
<if test="searchKeyword != null and searchKeyword != ''">
|
||||
<choose>
|
||||
<when test="searchCondition == 0">
|
||||
|
|
@ -94,10 +82,10 @@
|
|||
</when>
|
||||
</choose>
|
||||
</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<select id="Board.selectBoard" parameterType="boardVO" resultType="boardVO">
|
||||
<![CDATA[
|
||||
SELECT
|
||||
BBS.BD_SEQ AS SEQ, BBS.BD_MB_ID AS USERID, BBS.BD_GROUP_SEQ AS GROUPSEQ,
|
||||
BBS.BD_CATEGORY AS CATEGORY, BBS.BD_NAME AS USERNAME, BBS.BD_CONTENT AS CONTENT,
|
||||
|
|
@ -111,116 +99,112 @@
|
|||
H3_BD_${id}_LIST BBS
|
||||
WHERE
|
||||
BBS.BD_SEQ = #{seq}
|
||||
]]>
|
||||
</select>
|
||||
|
||||
<insert id="Board.insertBoard" parameterType="boardVO">
|
||||
INSERT INTO
|
||||
H3_BD_${id}_LIST (
|
||||
BD_MB_ID, BD_CATEGORY, BD_NAME, BD_GROUP_SEQ,
|
||||
BD_CONTENT, BD_SUBJECT, BD_PARENT_SEQ, BD_PREV_SEQ, BD_NEXT_SEQ, BD_STEP,
|
||||
BD_DEPTH, BD_REGDATE, BD_HIT, BD_RECOMMEND, BD_IP, BD_NOTICE,
|
||||
BD_HTML, BD_NUM1, BD_NUM2, BD_DATA1, BD_DATA2, BD_PLACE1, BD_POSITION
|
||||
BD_MB_ID,
|
||||
BD_CATEGORY,
|
||||
BD_NAME,
|
||||
BD_GROUP_SEQ,
|
||||
BD_CONTENT,
|
||||
BD_SUBJECT,
|
||||
BD_PARENT_SEQ,
|
||||
BD_PREV_SEQ,
|
||||
BD_NEXT_SEQ,
|
||||
BD_STEP,
|
||||
BD_DEPTH,
|
||||
BD_REGDATE,
|
||||
BD_HIT,
|
||||
BD_RECOMMEND,
|
||||
BD_IP,
|
||||
BD_NOTICE,
|
||||
BD_HTML,
|
||||
BD_NUM1,
|
||||
BD_NUM2,
|
||||
BD_DATA1,
|
||||
BD_DATA2,
|
||||
BD_PLACE1,
|
||||
BD_POSITION
|
||||
) VALUES (
|
||||
#{userId}, #{category}, #{userName}, #{groupSeq},
|
||||
#{content}, #{subject}, #{parentSeq}, #{prevSeq}, #{nextSeq}, #{step},
|
||||
#{depth}, SYSDATE, ${hit}, 0, #{ip,jdbcType=VARCHAR}, #{notice},
|
||||
1, 0, 0, #{data1,jdbcType=VARCHAR}, #{data2,jdbcType=VARCHAR}, #{place1,jdbcType=VARCHAR}, #{position,jdbcType=VARCHAR}
|
||||
#{userId},
|
||||
#{category},
|
||||
#{userName},
|
||||
#{groupSeq},
|
||||
#{content},
|
||||
#{subject},
|
||||
#{parentSeq},
|
||||
#{prevSeq},
|
||||
#{nextSeq},
|
||||
#{step},
|
||||
#{depth},
|
||||
NOW(),
|
||||
${hit},
|
||||
0,
|
||||
#{ip,jdbcType=VARCHAR},
|
||||
#{notice},
|
||||
1,
|
||||
0,
|
||||
0,
|
||||
#{data1,jdbcType=VARCHAR},
|
||||
#{data2,jdbcType=VARCHAR},
|
||||
#{place1,jdbcType=VARCHAR},
|
||||
#{position,jdbcType=VARCHAR}
|
||||
)
|
||||
<selectKey resultType="int" keyProperty="seq" order="AFTER">
|
||||
SELECT H3_BD_${id}_LIST_SEQ.CURRVAL FROM DUAL
|
||||
SELECT currval(#{id}||'_bd_seq') as seq
|
||||
</selectKey>
|
||||
<!--
|
||||
BD_SEQ, BD_MB_ID, BD_GROUP_SEQ, BD_CATEGORY, BD_NAME,
|
||||
BD_CONTENT, BD_SUBJECT, BD_PARENT_SEQ, BD_PREV_SEQ, BD_NEXT_SEQ, BD_STEP,
|
||||
BD_DEPTH, BD_REGDATE, BD_HIT, BD_RECOMMEND, BD_IP, BD_NOTICE,
|
||||
BD_HTML, BD_NUM1, BD_NUM2, BD_DATA1, BD_DATA2, BD_PLACE1, BD_POSITION
|
||||
|
||||
|
||||
#{bd_seq}, #{bd_mb_id}, #{bd_group_seq}, #{bd_category}, #{bd_name},
|
||||
#{bd_content}, #{bd_subject}, #{bd_parent_seq}, #{bd_prev_seq}, #{bd_next_seq}, #{bd_step},
|
||||
#{bd_depth}, #{bd_regdate}, #{bd_hit}, #{bd_recommend}, #{bd_ip}, #{bd_notice},
|
||||
#{bd_html}, #{bd_num1}, #{bd_num2}, #{bd_data1}, #{bd_data2}, #{bd_place1}, #{bd_position}
|
||||
-->
|
||||
</insert>
|
||||
|
||||
<update id="Board.updateGrpSeq" parameterType="boardVO">
|
||||
<![CDATA[
|
||||
UPDATE
|
||||
H3_BD_${id}_LIST
|
||||
SET
|
||||
BD_GROUP_SEQ = #{seq}
|
||||
WHERE
|
||||
BD_SEQ = #{seq}
|
||||
]]>
|
||||
</update>
|
||||
|
||||
|
||||
<select id="Board.selectPrevBoard" parameterType="boardVO" resultType="boardVO">
|
||||
<![CDATA[
|
||||
SELECT
|
||||
ALL_LIST.BD_SEQ AS SEQ, ALL_LIST.BD_MB_ID AS USERID, ALL_LIST.BD_GROUP_SEQ AS GROUPSEQ,
|
||||
ALL_LIST.BD_CATEGORY AS CATEGORY, ALL_LIST.BD_NAME AS USERNAME, ALL_LIST.BD_CONTENT AS CONTENT,
|
||||
ALL_LIST.BD_SUBJECT AS SUBJECT, ALL_LIST.BD_PARENT_SEQ AS PARENTSEQ, ALL_LIST.BD_PREV_SEQ AS PREVSEQ,
|
||||
ALL_LIST.BD_NEXT_SEQ AS NEXTSEQ, ALL_LIST.BD_STEP AS STEP, ALL_LIST.BD_DEPTH AS DEPTH,
|
||||
ALL_LIST.BD_REGDATE AS REGDATE, ALL_LIST.BD_HIT AS HIT, ALL_LIST.BD_RECOMMEND AS RECOMMEND,
|
||||
ALL_LIST.BD_IP AS IP, ALL_LIST.BD_NOTICE AS NOTICE, ALL_LIST.BD_HTML AS HTML,
|
||||
ALL_LIST.BD_NUM1 AS NUM1, ALL_LIST.BD_NUM2 AS NUM2, ALL_LIST.BD_DATA1 AS DATA1, ALL_LIST.BD_DATA2 AS DATA2,
|
||||
SELECT BD_SEQ AS SEQ,
|
||||
BD_MB_ID AS USERID,
|
||||
BD_GROUP_SEQ AS GROUPSEQ,
|
||||
BD_CATEGORY AS CATEGORY,
|
||||
BD_NAME AS USERNAME,
|
||||
BD_CONTENT AS CONTENT,
|
||||
BD_SUBJECT AS SUBJECT,
|
||||
BD_PARENT_SEQ AS PARENTSEQ,
|
||||
BD_PREV_SEQ AS PREVSEQ,
|
||||
BD_NEXT_SEQ AS NEXTSEQ,
|
||||
BD_STEP AS STEP,
|
||||
BD_DEPTH AS DEPTH,
|
||||
BD_REGDATE AS REGDATE,
|
||||
BD_HIT AS HIT,
|
||||
BD_RECOMMEND AS RECOMMEND,
|
||||
BD_IP AS IP,
|
||||
BD_NOTICE AS NOTICE,
|
||||
BD_HTML AS HTML,
|
||||
BD_NUM1 AS NUM1,
|
||||
BD_NUM2 AS NUM2,
|
||||
BD_DATA1 AS DATA1,
|
||||
BD_DATA2 AS DATA2,
|
||||
#{id} ID
|
||||
FROM
|
||||
(
|
||||
SELECT ROWNUM RNUM, ALL_LIST.*
|
||||
FROM (
|
||||
SELECT
|
||||
*
|
||||
FROM H3_BD_${id}_LIST
|
||||
WHERE 1 = 1
|
||||
]]>
|
||||
<choose>
|
||||
<when test='category == " " and id == "stat_bbs"'>
|
||||
</when>
|
||||
<otherwise>
|
||||
<where>
|
||||
<if test='seq != null and seq != 0'>
|
||||
AND BD_SEQ = #{seq}
|
||||
</if>
|
||||
<if test='category != " " and id != "stat_bbs"'>
|
||||
AND BD_CATEGORY = #{category}
|
||||
</otherwise>
|
||||
</choose>
|
||||
<![CDATA[
|
||||
ORDER BY
|
||||
BD_GROUP_SEQ DESC,
|
||||
BD_STEP ASC
|
||||
) ALL_LIST
|
||||
) ALL_LIST
|
||||
JOIN
|
||||
(
|
||||
SELECT * FROM
|
||||
(
|
||||
SELECT ROWNUM RNUM, BBS.*
|
||||
FROM (
|
||||
SELECT
|
||||
*
|
||||
FROM H3_BD_${id}_LIST BBS
|
||||
WHERE 1 = 1
|
||||
]]>
|
||||
<choose>
|
||||
<when test='category == " " and id == "stat_bbs"'>
|
||||
</when>
|
||||
<otherwise>
|
||||
AND BD_CATEGORY = #{category}
|
||||
</otherwise>
|
||||
</choose>
|
||||
<![CDATA[
|
||||
ORDER BY
|
||||
BBS.BD_GROUP_SEQ DESC,
|
||||
BBS.BD_STEP ASC
|
||||
) BBS
|
||||
) BBS
|
||||
WHERE BD_SEQ = #{seq}
|
||||
)BBS
|
||||
ON
|
||||
BBS.RNUM + 1 = ALL_LIST.RNUM
|
||||
]]>
|
||||
</if>
|
||||
</where>
|
||||
order by bd_seq desc
|
||||
limit 1 offset 1
|
||||
</select>
|
||||
|
||||
<update id="Board.updateGrpStep" parameterType="boardVO">
|
||||
<![CDATA[
|
||||
UPDATE
|
||||
H3_BD_${id}_LIST
|
||||
SET
|
||||
|
|
@ -228,11 +212,9 @@
|
|||
WHERE
|
||||
BD_GROUP_SEQ = #{seq} AND
|
||||
BD_STEP > #{step}
|
||||
]]>
|
||||
</update>
|
||||
|
||||
<update id="Board.updatePrevNextSeq" parameterType="boardVO">
|
||||
<![CDATA[
|
||||
UPDATE
|
||||
H3_BD_${id}_LIST
|
||||
SET
|
||||
|
|
@ -240,11 +222,9 @@
|
|||
BD_NEXT_SEQ = #{nextSeq}
|
||||
WHERE
|
||||
BD_SEQ = #{seq}
|
||||
]]>
|
||||
</update>
|
||||
|
||||
<update id="Board.updateBoard" parameterType="boardVO">
|
||||
<![CDATA[
|
||||
UPDATE
|
||||
H3_BD_${id}_LIST
|
||||
SET
|
||||
|
|
@ -254,16 +234,13 @@
|
|||
BD_HIT = #{hit}
|
||||
WHERE
|
||||
BD_SEQ = #{seq}
|
||||
]]>
|
||||
</update>
|
||||
|
||||
<delete id="Board.deleteBoard" parameterType="boardVO">
|
||||
<![CDATA[
|
||||
DELETE
|
||||
FROM
|
||||
H3_BD_${id}_LIST
|
||||
WHERE
|
||||
BD_SEQ = #{seq}
|
||||
]]>
|
||||
</delete>
|
||||
</mapper>
|
||||
|
|
|
|||
|
|
@ -46,12 +46,12 @@
|
|||
<insert id="BoardComment.insertBoardComment" parameterType="boardCommentVO">
|
||||
INSERT INTO
|
||||
H3_BD_${id}_COMT (
|
||||
BC_SEQ, BC_NAME, BC_CONTENT, BC_REGDATE, BC_BD_SEQ, BC_IP, BC_MB_ID
|
||||
BC_NAME, BC_CONTENT, BC_REGDATE, BC_BD_SEQ, BC_IP, BC_MB_ID
|
||||
) VALUES (
|
||||
H3_BD_${id}_COMT_SEQ.NEXTVAL, #{userName}, #{content}, SYSDATE, #{parentSeq}, '10.123.141.123', #{userId}
|
||||
#{userName}, #{content}, NOW(), #{parentSeq}, #{ip}, #{userId}
|
||||
)
|
||||
<selectKey resultType="int" keyProperty="seq" order="AFTER">
|
||||
SELECT H3_BD_${id}_COMT_SEQ.CURRVAL FROM DUAL
|
||||
SELECT currval(#{id}||'_bc_seq') as seq
|
||||
</selectKey>
|
||||
</insert>
|
||||
|
||||
|
|
|
|||
|
|
@ -28,7 +28,7 @@
|
|||
]]>
|
||||
</select>
|
||||
|
||||
<insert id="BoardFile.insertBoardFile" parameterType="boardFileVO" useGeneratedKeys="true" keyColumn="BF_SEQ">
|
||||
<insert id="BoardFile.insertBoardFile" parameterType="boardFileVO">
|
||||
<![CDATA[
|
||||
INSERT INTO
|
||||
H3_BD_${id}_FILE (
|
||||
|
|
|
|||
|
|
@ -8,7 +8,7 @@
|
|||
UL_USERID, UL_NAME, UL_LOCATION1, UL_LOCATION2, UL_LOCATION3, UL_REGDATE, UL_USER_IP, UL_PLACE1, UL_POSITION
|
||||
)
|
||||
VALUES (
|
||||
#{userid}, #{name}, #{location1}, #{location2}, #{location3}, SYSDATE, #{userip, jdbcType=VARCHAR}, #{place1}, #{position}
|
||||
#{userid}, #{name}, #{location1}, #{location2}, #{location3}, NOW(), #{userip, jdbcType=VARCHAR}, #{place1}, #{position}
|
||||
)
|
||||
]]>
|
||||
</insert>
|
||||
|
|
@ -19,68 +19,53 @@
|
|||
IO_USERID, IO_TYPE, IO_REGDATE, IO_PLACE1, IO_POSITION, IO_NAME
|
||||
)
|
||||
VALUES (
|
||||
#{user.userid}, #{type}, SYSDATE, #{user.place1}, #{user.position}, #{user.name}
|
||||
#{user.userid}, #{type}, NOW(), #{user.place1}, #{user.position}, #{user.name}
|
||||
)
|
||||
]]>
|
||||
</insert>
|
||||
|
||||
<select id="Log.selectUserLog" parameterType="logSearchVO" resultType="logVO">
|
||||
<![CDATA[
|
||||
SELECT
|
||||
select (ROW_NUMBER() OVER()) AS RNUM,
|
||||
LOG_LIST.*
|
||||
FROM
|
||||
(
|
||||
SELECT
|
||||
ROWNUM RNUM, LOG_LIST.*
|
||||
FROM
|
||||
( SELECT
|
||||
LOG.UL_USERID AS USERID, LOG.UL_NAME AS NAME, LOG.UL_LOCATION1 AS LOCATION1, LOG.UL_LOCATION2 AS LOCATION2, LOG.UL_LOCATION3 AS LOCATION3,
|
||||
TO_CHAR(LOG.UL_REGDATE, 'YYYY-MM-DD HH24:MI:SS') AS REGDATE, LOG.UL_USER_IP AS IP, LOG.UL_POSITION AS POSITION_CODE, CODE.CODENM AS POSITION
|
||||
FROM
|
||||
H3_USER_LOG LOG, TCODE CODE
|
||||
WHERE
|
||||
LOG.UL_POSITION = CODE.CODE2
|
||||
AND CODE.CODE1 = 'C002' ]]>
|
||||
<if test="sdate != null and sdate != '' and edate != null and edate != ''"><![CDATA[
|
||||
AND UL_REGDATE >= #{sdate} || ' 00:00:00'
|
||||
AND UL_REGDATE <= #{edate} || ' 23:59:59' ]]>
|
||||
FROM (SELECT LOG.UL_USERID AS USERID,
|
||||
LOG.UL_NAME AS NAME,
|
||||
LOG.UL_LOCATION1 AS LOCATION1,
|
||||
LOG.UL_LOCATION2 AS LOCATION2,
|
||||
LOG.UL_LOCATION3 AS LOCATION3,
|
||||
TO_CHAR(LOG.UL_REGDATE, 'YYYY-MM-DD HH24:MI:SS') AS REGDATE,
|
||||
LOG.UL_USER_IP AS IP,
|
||||
LOG.UL_POSITION AS POSITION_CODE,
|
||||
CODE.CODENM AS POSITION
|
||||
FROM H3_USER_LOG LOG
|
||||
inner join TCODE CODE on LOG.UL_POSITION = CODE.CODE2 and CODE.CODE1 = 'C002'
|
||||
<where>
|
||||
<if test="sdate != null and sdate != '' and edate != null and edate != ''">
|
||||
AND UL_REGDATE >= (#{sdate} || ' 00:00:00')::date
|
||||
AND UL_REGDATE <= (#{edate} || ' 23:59:59')::date
|
||||
</if>
|
||||
<if test="place1 != null and place1 != ''">
|
||||
AND UL_PLACE1 = #{place1}
|
||||
</if>
|
||||
<if test="name != null and name != ''">
|
||||
AND UL_NAME LIKE '%' || #{name} || '%'
|
||||
</if>
|
||||
<![CDATA[ ORDER BY
|
||||
UL_REGDATE ]]> <if test="order != 0">DESC</if> <![CDATA[
|
||||
</where>
|
||||
ORDER BY UL_REGDATE <if test="order != 0">DESC</if>
|
||||
limit #{recordCountPerPage} offset #{firstIndex}
|
||||
) LOG_LIST
|
||||
WHERE ROWNUM <= #{firstIndex} + #{recordCountPerPage}
|
||||
) LOG_LIST
|
||||
WHERE
|
||||
RNUM > #{firstIndex}
|
||||
]]>
|
||||
</select>
|
||||
|
||||
<select id="Log.selectLoginoutLog" parameterType="logSearchVO" resultType="logVO">
|
||||
<![CDATA[
|
||||
SELECT
|
||||
LOG_LIST.*, CODE.CODENM AS POSITION
|
||||
FROM
|
||||
(
|
||||
SELECT
|
||||
ROWNUM RNUM, LOG_LIST.*
|
||||
FROM
|
||||
( SELECT
|
||||
IO_USERID AS USERID, IO_NAME AS NAME, TO_CHAR(IO_REGDATE, 'YYYY-MM-DD HH24:MI:SS') AS REGDATE, IO_POSITION AS POSITION_CODE, IO_TYPE AS TYPE
|
||||
FROM
|
||||
H3_LOGINOUT_LOG
|
||||
WHERE
|
||||
1 = 1
|
||||
]]>
|
||||
<if test="sdate != null and sdate != '' and edate != null and edate != ''"><![CDATA[
|
||||
AND
|
||||
TO_CHAR(IO_REGDATE, 'yyyy-mm-dd') >= #{sdate} AND
|
||||
TO_CHAR(IO_REGDATE, 'yyyy-mm-dd') <= #{edate} ]]>
|
||||
SELECT (ROW_NUMBER() OVER()) AS RNUM,
|
||||
IO_USERID AS USERID,
|
||||
IO_NAME AS NAME,
|
||||
TO_CHAR(IO_REGDATE, 'YYYY-MM-DD HH24:MI:SS') AS REGDATE,
|
||||
IO_POSITION AS POSITION_CODE,
|
||||
IO_TYPE AS TYPE,
|
||||
CODE.CODENM AS POSITION
|
||||
FROM H3_LOGINOUT_LOG log
|
||||
inner join TCODE CODE on log.IO_POSITION = CODE.CODE2 AND CODE.CODE1 = 'C002'
|
||||
<where>
|
||||
<if test="sdate != null and sdate != '' and edate != null and edate != ''">
|
||||
AND TO_CHAR(log.IO_REGDATE, 'yyyy-mm-dd') >= #{sdate}
|
||||
AND TO_CHAR(log.IO_REGDATE, 'yyyy-mm-dd') <= #{edate}
|
||||
</if>
|
||||
<if test="place1 != null and place1 != ''">
|
||||
AND IO_PLACE1 = #{place1}
|
||||
|
|
@ -88,20 +73,9 @@
|
|||
<if test="name != null and name != ''">
|
||||
AND IO_NAME LIKE '%' || #{name} || '%'
|
||||
</if>
|
||||
<![CDATA[ ORDER BY
|
||||
IO_REGDATE ]]> <if test="order != 0">DESC</if> <![CDATA[
|
||||
) LOG_LIST
|
||||
) LOG_LIST,
|
||||
TCODE CODE
|
||||
|
||||
WHERE
|
||||
RNUM > #{firstIndex} AND
|
||||
RNUM <= #{firstIndex} + #{recordCountPerPage} AND
|
||||
LOG_LIST.POSITION_CODE = CODE.CODE2 AND
|
||||
CODE.CODE1 = 'C002'
|
||||
|
||||
|
||||
]]>
|
||||
</where>
|
||||
ORDER BY IO_REGDATE <if test="order != 0">DESC</if>
|
||||
limit #{recordCountPerPage} offset #{firstIndex}
|
||||
</select>
|
||||
|
||||
<select id="Log.selectLogListTotCnt" parameterType="logSearchVO" resultType="int">
|
||||
|
|
@ -150,18 +124,36 @@
|
|||
</select>
|
||||
|
||||
<select id="Log.selectUrlInfo" parameterType="logVO" resultType="hashmap">
|
||||
<![CDATA[
|
||||
SELECT
|
||||
LEVEL AS LV, MENU.*
|
||||
FROM
|
||||
T_MENU MENU
|
||||
START WITH
|
||||
MENU.URL = #{location2}
|
||||
CONNECT BY PRIOR
|
||||
MENU.PARENT = MENU.ID
|
||||
ORDER BY
|
||||
LV DESC
|
||||
]]>
|
||||
with recursive menu_hierarchy (
|
||||
level,
|
||||
id,
|
||||
name,
|
||||
eng_name,
|
||||
parent,
|
||||
depth,
|
||||
url,
|
||||
menu_position,
|
||||
visible,
|
||||
url_group,
|
||||
sub_visibel,
|
||||
role_level,
|
||||
url_query,
|
||||
board_id,
|
||||
window_target
|
||||
) as (
|
||||
select 1, a.*
|
||||
from t_menu a
|
||||
where url = #{location2}
|
||||
|
||||
union all
|
||||
|
||||
select b.level +1, a.*
|
||||
from t_menu a
|
||||
inner join menu_hierarchy b
|
||||
on a.id = b.parent
|
||||
)
|
||||
select * from menu_hierarchy
|
||||
order by level desc
|
||||
</select>
|
||||
|
||||
<select id="Log.selectLogTotalCnt" parameterType="logSearchVO" resultType="int">
|
||||
|
|
|
|||
|
|
@ -19,85 +19,149 @@
|
|||
</resultMap>
|
||||
|
||||
<select id="selectListWithHigher" parameterType="menuVO" resultMap="menuResult">
|
||||
<![CDATA[
|
||||
SELECT
|
||||
*
|
||||
FROM
|
||||
T_MENU
|
||||
START WITH
|
||||
ID = #{id}
|
||||
CONNECT BY PRIOR
|
||||
PARENT = ID
|
||||
ORDER BY DEPTH, ID
|
||||
]]>
|
||||
with recursive subject (
|
||||
id,
|
||||
name,
|
||||
eng_name,
|
||||
parent,
|
||||
depth,
|
||||
url,
|
||||
menu_position,
|
||||
visible,
|
||||
url_group,
|
||||
sub_visible,
|
||||
role_level,
|
||||
url_query,
|
||||
board_id,
|
||||
window_target
|
||||
) as(
|
||||
select
|
||||
id,
|
||||
name,
|
||||
eng_name,
|
||||
parent,
|
||||
depth,
|
||||
url,
|
||||
menu_position,
|
||||
visible,
|
||||
url_group,
|
||||
sub_visible,
|
||||
role_level,
|
||||
url_query,
|
||||
board_id,
|
||||
window_target
|
||||
from t_menu
|
||||
where id = #{id}
|
||||
union all
|
||||
select
|
||||
m.id,
|
||||
m.name,
|
||||
m.eng_name,
|
||||
m.parent,
|
||||
m.depth,
|
||||
m.url,
|
||||
m.menu_position,
|
||||
m.visible,
|
||||
m.url_group,
|
||||
m.sub_visible,
|
||||
m.role_level,
|
||||
m.url_query,
|
||||
m.board_id,
|
||||
m.window_target
|
||||
from t_menu m inner join subject s on m.id = s.parent
|
||||
)
|
||||
select * from subject
|
||||
ORDER BY depth, ID;
|
||||
</select>
|
||||
|
||||
<select id="selectListWithConnectBy" parameterType="menuVO" resultMap="menuResult">
|
||||
<![CDATA[
|
||||
SELECT
|
||||
LEVEL,
|
||||
with recursive menu(
|
||||
level,
|
||||
ID,
|
||||
NAME,
|
||||
ENG_NAME,
|
||||
PARENT,
|
||||
DEPTH,
|
||||
MENU_POSITION,
|
||||
VISIBLE,
|
||||
SUB_VISIBLE,
|
||||
ROLE_LEVEL,
|
||||
URL_GROUP,
|
||||
URL,
|
||||
URL_QUERY,
|
||||
BOARD_ID,
|
||||
WINDOW_TARGET
|
||||
) as (
|
||||
select
|
||||
1,
|
||||
M.ID, M.NAME, M.ENG_NAME, M.PARENT, M.DEPTH,
|
||||
M.MENU_POSITION, M.VISIBLE, M.SUB_VISIBLE, M.ROLE_LEVEL,
|
||||
NVL(M.URL_GROUP, (SELECT URL_GROUP FROM T_MENU WHERE ID = (SELECT MIN(ID) FROM T_MENU WHERE PARENT = M.ID))) AS URL_GROUP,
|
||||
NVL(M.URL, (SELECT URL FROM T_MENU WHERE ID = (SELECT MIN(ID) FROM T_MENU WHERE PARENT = M.ID))) AS URL,
|
||||
NVL(M.URL_QUERY, (SELECT URL_QUERY FROM T_MENU WHERE ID = (SELECT MIN(ID) FROM T_MENU WHERE PARENT = M.ID))) AS URL_QUERY,
|
||||
NVL(M.BOARD_ID, (SELECT BOARD_ID FROM T_MENU WHERE ID = (SELECT MIN(ID) FROM T_MENU WHERE PARENT = M.ID))) AS BOARD_ID,
|
||||
NVL(M.WINDOW_TARGET, (SELECT WINDOW_TARGET FROM T_MENU WHERE ID = (SELECT MIN(ID) FROM T_MENU WHERE PARENT = M.ID))) AS WINDOW_TARGET
|
||||
FROM
|
||||
T_MENU M
|
||||
WHERE
|
||||
M.VISIBLE = 'Y'
|
||||
AND M.ROLE_LEVEL >= NVL((SELECT ROLE_LEVEL FROM T_SSO_AUTH_CODE AC, TAGENT A WHERE AC.CODE_ID = A.USEGRADE AND A.USERID = #{userId}), 17)
|
||||
]]>
|
||||
<if test="menuPosition != null and menuPosition != ''"><![CDATA[
|
||||
COALESCE(M.URL_GROUP, c.URL_GROUP) AS URL_GROUP,
|
||||
COALESCE(M.URL, c.URL) AS URL,
|
||||
COALESCE(M.URL_QUERY, c.URL_QUERY) AS URL_QUERY,
|
||||
COALESCE(M.BOARD_ID, c.BOARD_ID) AS BOARD_ID,
|
||||
COALESCE(M.WINDOW_TARGET, c.WINDOW_TARGET) AS WINDOW_TARGET
|
||||
FROM T_MENU M left outer join (select id, parent, url_group, url, url_query, board_id, window_target
|
||||
from t_menu a
|
||||
where a.id in (select min(id) id
|
||||
from t_menu
|
||||
group by parent )) c
|
||||
on m.id = c.parent
|
||||
WHERE M.VISIBLE = 'Y'
|
||||
AND M.ROLE_LEVEL >= COALESCE((SELECT ROLE_LEVEL FROM T_SSO_AUTH_CODE AC, TAGENT A WHERE AC.CODE_ID = A.USEGRADE AND A.USERID = #{userId}), 17)
|
||||
AND M.MENU_POSITION = #{menuPosition}
|
||||
]]></if>
|
||||
<if test="depth != null"><![CDATA[
|
||||
AND M.DEPTH <= #{depth}
|
||||
]]></if>
|
||||
<![CDATA[
|
||||
START WITH
|
||||
M.DEPTH = 0
|
||||
CONNECT BY PRIOR
|
||||
M.ID = M.PARENT
|
||||
]]>
|
||||
AND M.DEPTH = 0
|
||||
union all
|
||||
select
|
||||
b.level+1,
|
||||
M.ID, M.NAME, M.ENG_NAME, M.PARENT, M.DEPTH,
|
||||
M.MENU_POSITION, M.VISIBLE, M.SUB_VISIBLE, M.ROLE_LEVEL,
|
||||
COALESCE(M.URL_GROUP, c.URL_GROUP) AS URL_GROUP,
|
||||
COALESCE(M.URL, c.URL) AS URL,
|
||||
COALESCE(M.URL_QUERY, c.URL_QUERY) AS URL_QUERY,
|
||||
COALESCE(M.BOARD_ID, c.BOARD_ID) AS BOARD_ID,
|
||||
COALESCE(M.WINDOW_TARGET, c.WINDOW_TARGET) AS WINDOW_TARGET
|
||||
FROM T_MENU M inner join menu b on M.parent = b.id
|
||||
left outer join (select id, parent, url_group, url, url_query, board_id, window_target
|
||||
from t_menu a
|
||||
where a.id in (select min(id) id
|
||||
from t_menu
|
||||
group by parent )) c
|
||||
on m.id = c.parent
|
||||
where M.VISIBLE = 'Y'
|
||||
AND M.ROLE_LEVEL >= COALESCE((SELECT ROLE_LEVEL FROM T_SSO_AUTH_CODE AC, TAGENT A WHERE AC.CODE_ID = A.USEGRADE AND A.USERID = #{userId}), 17)
|
||||
AND M.MENU_POSITION = #{menuPosition}
|
||||
)
|
||||
select *
|
||||
from menu
|
||||
where level <= ${maxLevel}
|
||||
order by level, id
|
||||
</select>
|
||||
|
||||
<!---->
|
||||
<select id="Menu.getMenuInfo" parameterType="map" resultType="map">
|
||||
<![CDATA[
|
||||
SELECT * FROM (
|
||||
SELECT
|
||||
*
|
||||
FROM
|
||||
T_MENU
|
||||
WHERE
|
||||
URL_GROUP = #{group} AND
|
||||
URL = #{url}
|
||||
]]>
|
||||
<if test="boardId != null and boardId != ''"><![CDATA[
|
||||
SELECT *
|
||||
FROM T_MENU
|
||||
WHERE URL_GROUP = #{group}
|
||||
AND URL = #{url}
|
||||
<if test="boardId != null and boardId != ''">
|
||||
AND BOARD_ID = #{boardId}
|
||||
]]></if>
|
||||
<if test="query != null and query != ''"><![CDATA[
|
||||
</if>
|
||||
<if test="query != null and query != ''">
|
||||
AND URL_QUERY = #{query}
|
||||
]]></if>
|
||||
<![CDATA[
|
||||
) WHERE ROWNUM = 1
|
||||
]]>
|
||||
</if>
|
||||
limit 1
|
||||
</select>
|
||||
|
||||
<select id="Menu.getMenuInfoById" parameterType="map" resultType="map">
|
||||
<![CDATA[
|
||||
SELECT
|
||||
*
|
||||
FROM
|
||||
T_MENU
|
||||
WHERE
|
||||
ID = #{id}
|
||||
]]>
|
||||
</select>
|
||||
|
||||
<select id="Menu.getSubmenu" parameterType="hashmap" resultType="hashmap">
|
||||
<![CDATA[
|
||||
SELECT
|
||||
A.*
|
||||
FROM
|
||||
|
|
@ -108,13 +172,11 @@
|
|||
FROM
|
||||
T_MENU
|
||||
WHERE
|
||||
URL_GROUP = #{URL_GROUP} AND
|
||||
URL = #{URL}
|
||||
]]>
|
||||
<if test="BOARD_ID != null and BOARD_ID != ''"><![CDATA[
|
||||
AND BOARD_ID = #{BOARD_ID}
|
||||
]]></if>
|
||||
<![CDATA[
|
||||
URL_GROUP = #{url_group} AND
|
||||
URL = #{url}
|
||||
<if test="BOARD_ID != null and BOARD_ID != ''">
|
||||
AND BOARD_ID = #{board_id}
|
||||
</if>
|
||||
) B
|
||||
ON
|
||||
B.MENU_POSITION = A.MENU_POSITION AND
|
||||
|
|
@ -122,9 +184,8 @@
|
|||
WHERE
|
||||
A.VISIBLE = 'Y'
|
||||
AND A.SUB_VISIBLE = 'Y'
|
||||
AND A.ROLE_LEVEL >= NVL((SELECT ROLE_LEVEL FROM T_SSO_AUTH_CODE AC, TAGENT A WHERE AC.CODE_ID = A.USEGRADE AND A.USERID = #{userId}), 17)
|
||||
AND A.ROLE_LEVEL >= COALESCE((SELECT ROLE_LEVEL FROM T_SSO_AUTH_CODE AC, TAGENT A WHERE AC.CODE_ID = A.USEGRADE AND A.USERID = #{userId}), 17)
|
||||
ORDER BY
|
||||
A.ID
|
||||
]]>
|
||||
</select>
|
||||
</mapper>
|
||||
|
|
|
|||
|
|
@ -39,10 +39,10 @@
|
|||
)
|
||||
VALUES
|
||||
(
|
||||
(SELECT NVL(MAX(ES_IDX), 0) + 1 FROM H3_EDU_STAT), #{name}, #{stdate}, #{eddate}, #{eduCourse},
|
||||
(SELECT COALESCE(MAX(ES_IDX), 0) + 1 FROM H3_EDU_STAT), #{name}, #{stdate}, #{eddate}, #{eduCourse},
|
||||
#{eduPlace}, #{userId}, #{place1}, #{place2}, #{scholarship},
|
||||
#{position}, #{jobtype}, #{sdate}, #{pdate}, #{adate},
|
||||
#{comment}, SYSDATE, SYSDATE, #{writer}, #{birth}
|
||||
#{comment}, NOW(), NOW(), #{writer}, #{birth}
|
||||
)
|
||||
]]>
|
||||
</insert>
|
||||
|
|
@ -104,7 +104,7 @@
|
|||
ES_PDATE = #{pdate},
|
||||
ES_ADATE = #{adate},
|
||||
ES_COMMENT = #{comment},
|
||||
ES_LOGDATE = SYSDATE,
|
||||
ES_LOGDATE = NOW(),
|
||||
ES_WRITER = #{writer},
|
||||
ES_BIRTH = #{birth}
|
||||
WHERE ES_IDX = #{idx}
|
||||
|
|
|
|||
|
|
@ -2,10 +2,6 @@
|
|||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="Equip">
|
||||
|
||||
<resultMap id="resultMap" type="hashmap">
|
||||
<result property="EU_DETAIL" column="EU_DETAIL" jdbcType="CLOB" javaType="java.lang.String" />
|
||||
</resultMap>
|
||||
|
||||
<resultMap id="useStateResult" type="useStateVO">
|
||||
<result property="police" column="EU_POLICE" />
|
||||
<result property="policeStr" column="EU_POLICE_NM" />
|
||||
|
|
@ -53,16 +49,13 @@
|
|||
</resultMap>
|
||||
|
||||
<select id="Equip.getEquipmentList" parameterType="hashmap" resultType="hashmap">
|
||||
<![CDATA[
|
||||
SELECT
|
||||
'계' AS EQUIP_NM, COUNT(EQ.POLICE) AS TOTAL, CAST('00' AS INT) AS ORDER_VALUE, '00' AS EQUIP,
|
||||
]]>
|
||||
<foreach collection="place1" item="item" separator=",">
|
||||
SUM(CASE POLICE WHEN #{item.code2} THEN 1 ELSE 0 END) AS ${item.code2},
|
||||
SUM(CASE POLICE WHEN 'ps18' THEN 1 ELSE 0 END) AS ps18,
|
||||
SUM(CASE POLICE WHEN 'ps90' THEN 1 ELSE 0 END) AS ps90
|
||||
</foreach>
|
||||
<![CDATA[
|
||||
FROM
|
||||
TEQUIPMENT EQ
|
||||
RIGHT JOIN
|
||||
|
|
@ -81,13 +74,11 @@
|
|||
UNION
|
||||
SELECT
|
||||
TD.CODENM AS EQUIP_NM, COUNT(EQ.POLICE) AS TOTAL, CAST(TD.CODE2 AS INT) AS ORDER_VALUE, TD.CODE2 AS EQUIP,
|
||||
]]>
|
||||
<foreach collection="place1" item="item" separator=",">
|
||||
SUM(CASE POLICE WHEN #{item.code2} THEN 1 ELSE 0 END) AS ${item.code2},
|
||||
SUM(CASE POLICE WHEN 'ps18' THEN 1 ELSE 0 END) AS ps18,
|
||||
SUM(CASE POLICE WHEN 'ps90' THEN 1 ELSE 0 END) AS ps90
|
||||
</foreach>
|
||||
<![CDATA[
|
||||
FROM
|
||||
TEQUIPMENT EQ
|
||||
RIGHT JOIN
|
||||
|
|
@ -107,7 +98,6 @@
|
|||
EQ.EQUIPGUBUN, TD.CODENM, TD.CODE2
|
||||
ORDER BY
|
||||
ORDER_VALUE
|
||||
]]>
|
||||
</select>
|
||||
|
||||
|
||||
|
|
@ -115,47 +105,38 @@
|
|||
<![CDATA[
|
||||
SELECT
|
||||
1 AS CNT, '계' AS GUBUN, '' AS CODE,
|
||||
NVL(SUM(${type}), 0) AS TOTAL,
|
||||
COALESCE(SUM(${type}), 0) AS TOTAL,
|
||||
]]>
|
||||
<foreach collection="place1" item="item" separator=",">
|
||||
NVL(SUM(CASE EU_POLICE WHEN #{item.code2} THEN ${type} ELSE 0 END), 0) AS ${item.code2}
|
||||
COALESCE(SUM(CASE EU_POLICE WHEN #{item.code2} THEN ${type} ELSE 0 END), 0) AS ${item.code2}
|
||||
</foreach>
|
||||
<![CDATA[
|
||||
FROM
|
||||
H3_EQUIP_USE_STATE
|
||||
WHERE
|
||||
EU_YEAR = #{criteria.year} AND
|
||||
EU_QUATER = #{criteria.quater}
|
||||
FROM H3_EQUIP_USE_STATE
|
||||
WHERE EU_YEAR = (#{criteria.year}||'')
|
||||
AND EU_QUATER = (#{criteria.quater}||'')
|
||||
UNION
|
||||
SELECT
|
||||
2 AS CNT, B.CODENM AS GUBUN, B.CODE2 AS CODE,
|
||||
NVL(SUM(${type}), 0) AS TOTAL,
|
||||
COALESCE(SUM(${type}), 0) AS TOTAL,
|
||||
]]>
|
||||
<foreach collection="place1" item="item" separator=",">
|
||||
NVL(SUM(CASE EU_POLICE WHEN #{item.code2} THEN ${type} ELSE 0 END), 0) AS ${item.code2}
|
||||
COALESCE(SUM(CASE EU_POLICE WHEN #{item.code2} THEN ${type} ELSE 0 END), 0) AS ${item.code2}
|
||||
</foreach>
|
||||
<![CDATA[
|
||||
FROM
|
||||
(
|
||||
SELECT
|
||||
*
|
||||
FROM
|
||||
H3_EQUIP_USE_STATE
|
||||
WHERE
|
||||
EU_YEAR = #{criteria.year} AND
|
||||
EU_QUATER = #{criteria.quater}
|
||||
SELECT *
|
||||
FROM H3_EQUIP_USE_STATE
|
||||
WHERE EU_YEAR = (#{criteria.year}||'')
|
||||
AND EU_QUATER = (#{criteria.quater}||'')
|
||||
) A
|
||||
RIGHT JOIN
|
||||
(
|
||||
SELECT
|
||||
CODE2, CODENM
|
||||
FROM
|
||||
TCODE
|
||||
WHERE
|
||||
CODE1 = 'EQUI' AND
|
||||
CODE_USE_YN = 'Y'
|
||||
ORDER BY
|
||||
CODE2
|
||||
SELECT CODE2, CODENM
|
||||
FROM TCODE
|
||||
WHERE CODE1 = 'EQUI'
|
||||
AND CODE_USE_YN = 'Y'
|
||||
ORDER BY CODE2
|
||||
) B
|
||||
ON A.EU_CODE = B.CODE2
|
||||
GROUP BY CODE2, CODENM
|
||||
|
|
@ -190,49 +171,34 @@
|
|||
]]>
|
||||
</select>
|
||||
|
||||
<select id="Equip.getEquipUseStateInfo" parameterType="equipSearchVO" resultMap="resultMap">
|
||||
<select id="Equip.getEquipUseStateInfo" parameterType="equipSearchVO" resultType="hashmap">
|
||||
<![CDATA[
|
||||
SELECT
|
||||
B.CODENM, B.CODE2, A.*
|
||||
FROM
|
||||
(
|
||||
SELECT
|
||||
*
|
||||
FROM
|
||||
H3_EQUIP_USE_STATE
|
||||
WHERE
|
||||
EU_YEAR = #{year} AND
|
||||
EU_QUATER = #{quater} AND
|
||||
EU_POLICE = #{police}
|
||||
) A
|
||||
SELECT B.CODENM,
|
||||
B.CODE2,
|
||||
A.*
|
||||
FROM (SELECT *
|
||||
FROM H3_EQUIP_USE_STATE
|
||||
WHERE EU_YEAR = (#{year}||'')
|
||||
AND EU_QUATER = (#{quater}||'')
|
||||
AND EU_POLICE = #{police}) A
|
||||
RIGHT JOIN
|
||||
(
|
||||
SELECT
|
||||
CODE2, CODENM
|
||||
FROM
|
||||
TCODE
|
||||
WHERE
|
||||
CODE1 = 'EQUI' AND
|
||||
CODE_USE_YN = 'Y'
|
||||
ORDER BY
|
||||
CODE2
|
||||
) B
|
||||
(SELECT CODE2, CODENM
|
||||
FROM TCODE
|
||||
WHERE CODE1 = 'EQUI'
|
||||
AND CODE_USE_YN = 'Y'
|
||||
ORDER BY CODE2 ) B
|
||||
ON A.EU_CODE = B.CODE2
|
||||
ORDER BY
|
||||
B.CODE2
|
||||
ORDER BY B.CODE2
|
||||
]]>
|
||||
</select>
|
||||
|
||||
<select id="Equip.getEquipUseStateInfoByCode" parameterType="hashmap" resultType="hashmap">
|
||||
SELECT
|
||||
*
|
||||
FROM
|
||||
H3_EQUIP_USE_STATE
|
||||
WHERE
|
||||
EU_YEAR = #{year} AND
|
||||
EU_QUATER = #{quater} AND
|
||||
EU_POLICE = #{police} AND
|
||||
EU_CODE = #{code}
|
||||
SELECT *
|
||||
FROM H3_EQUIP_USE_STATE
|
||||
WHERE EU_YEAR = (#{year}||'')
|
||||
AND EU_QUATER = (#{quater}||'')
|
||||
AND EU_POLICE = #{police}
|
||||
AND EU_CODE = #{code}
|
||||
</select>
|
||||
|
||||
<insert id="Equip.insertEquipUseState" parameterType="hashmap">
|
||||
|
|
@ -244,26 +210,27 @@
|
|||
) VALUES (
|
||||
#{police}, #{year}, #{quater},
|
||||
#{code}, #{cnt}, #{detail},
|
||||
#{state}, #{check}, SYSDATE, #{writer}
|
||||
#{state}, #{check}, NOW(), #{writer}
|
||||
)
|
||||
</insert>
|
||||
|
||||
<update id="Equip.updateEquipUseState" parameterType="hashmap">
|
||||
UPDATE
|
||||
H3_EQUIP_USE_STATE
|
||||
SET
|
||||
EU_CNT = #{cnt}, EU_DETAIL = #{detail},
|
||||
EU_STATE = #{state}, EU_CHECK = #{check}
|
||||
WHERE
|
||||
EU_POLICE = #{police} AND EU_YEAR = #{year} AND
|
||||
EU_QUATER = #{quater} AND EU_CODE = #{code}
|
||||
UPDATE H3_EQUIP_USE_STATE
|
||||
SET EU_CNT = #{cnt},
|
||||
EU_DETAIL = #{detail},
|
||||
EU_STATE = #{state},
|
||||
EU_CHECK = #{check}
|
||||
WHERE EU_POLICE = #{police}
|
||||
AND EU_YEAR = (#{year}||'')
|
||||
AND EU_QUATER = (#{quater}||'')
|
||||
AND EU_CODE = #{code}
|
||||
</update>
|
||||
|
||||
<!-- 사용실적 결재 -->
|
||||
<select id="selectStateWaitingList" parameterType="stateWaitingSearchVO" resultMap="useStateResult">
|
||||
<![CDATA[
|
||||
SELECT
|
||||
A.*, NVL(ESJ_SEQ, 0) AS ESJ_SEQ, ESJ_CHECKDATE,
|
||||
A.*, COALESCE(ESJ_SEQ, 0) AS ESJ_SEQ, ESJ_CHECKDATE,
|
||||
(SELECT CODENM FROM TCODE WHERE CODE1 = 'C001' AND CODE2 = A.EU_POLICE) AS POLICE_NAME
|
||||
FROM
|
||||
(SELECT EU_POLICE, EU_YEAR, EU_QUATER FROM H3_EQUIP_USE_STATE GROUP BY EU_POLICE, EU_YEAR, EU_QUATER) A
|
||||
|
|
@ -360,9 +327,7 @@
|
|||
</select>
|
||||
|
||||
<insert id="Equip.insertEquipment" parameterType="equipVO">
|
||||
<![CDATA[
|
||||
INSERT INTO TEQUIPMENT
|
||||
( SERNO,
|
||||
INSERT INTO TEQUIPMENT(
|
||||
NUM,
|
||||
POLICE,
|
||||
EQUIPGUBUN,
|
||||
|
|
@ -385,9 +350,10 @@ INSERT INTO TEQUIPMENT
|
|||
WRITER,
|
||||
LOGDATE)
|
||||
values (
|
||||
TEQUIPMENT_SERNO_SEQ.NEXTVAL,
|
||||
(CASE WHEN (SELECT MAX(NUM) FROM TEQUIPMENT WHERE POLICE = #{police}) IS NULL THEN 1
|
||||
ELSE (SELECT MAX(NUM) + 1 FROM TEQUIPMENT WHERE POLICE = #{police}) END),
|
||||
(CASE
|
||||
WHEN (SELECT MAX(NUM) FROM TEQUIPMENT WHERE POLICE = #{police}) IS NULL THEN 1
|
||||
ELSE (SELECT MAX(NUM)::int + 1 FROM TEQUIPMENT WHERE POLICE = #{police})
|
||||
END),
|
||||
#{police},
|
||||
#{equipType},
|
||||
#{equipName},
|
||||
|
|
@ -407,22 +373,18 @@ INSERT INTO TEQUIPMENT
|
|||
#{fileName1},
|
||||
#{fileName2},
|
||||
#{fileName3},
|
||||
TO_CHAR(SYSDATE, 'YYYYMMDDHH24MISS'),
|
||||
TO_CHAR(NOW(), 'YYYYMMDDHH24MISS'),
|
||||
#{writer},
|
||||
NULL
|
||||
)
|
||||
]]>
|
||||
<selectKey resultType="String" keyProperty="serNo" order="AFTER">
|
||||
SELECT TEQUIPMENT_SERNO_SEQ.CURRVAL FROM DUAL
|
||||
<selectKey resultType="int" keyProperty="serNo" order="AFTER">
|
||||
SELECT currval('tequip_seq') as seq
|
||||
</selectKey>
|
||||
</insert>
|
||||
|
||||
<update id="updateEquipment" parameterType="arrestVO">
|
||||
<![CDATA[
|
||||
UPDATE
|
||||
TEQUIPMENT
|
||||
SET
|
||||
NUM = #{num},
|
||||
<update id="updateEquipment" parameterType="equipVO">
|
||||
UPDATE TEQUIPMENT
|
||||
SET NUM = #{num},
|
||||
EQUIPGUBUN = #{equipType},
|
||||
EQUIPNAME = #{equipName},
|
||||
POLICE = #{police},
|
||||
|
|
@ -442,21 +404,12 @@ INSERT INTO TEQUIPMENT
|
|||
FILENAME1 = #{fileName1},
|
||||
FILENAME2 = #{fileName2},
|
||||
FILENAME3 = #{fileName3},
|
||||
LOGDATE = TO_CHAR(SYSDATE, 'YYYYMMDDHH24MISS')
|
||||
WHERE
|
||||
SERNO = #{serNo}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
]]>
|
||||
LOGDATE = TO_CHAR(NOW(), 'YYYYMMDDHH24MISS')
|
||||
WHERE SERNO = #{serNo}
|
||||
</update>
|
||||
|
||||
<delete id="deleteEquipment" parameterType="equipVO">
|
||||
<![CDATA[
|
||||
DELETE FROM TEQUIPMENT
|
||||
WHERE SERNO = #{serNo}
|
||||
]]>
|
||||
</delete>
|
||||
</mapper>
|
||||
|
|
|
|||
|
|
@ -35,7 +35,7 @@
|
|||
( ESJ_POLICE, ESJ_YEAR, ESJ_QUATER, ESJ_CHECKDATE, ESJ_PLACE1,
|
||||
ESJ_POSITION, ESJ_NAME, ESJ_USERID, ESJ_PROXY_ID, ESJ_MESSAGE )
|
||||
VALUES
|
||||
( #{police}, #{year}, #{quater}, SYSDATE, #{place1Str},
|
||||
( #{police}, #{year}, #{quater}, NOW(), #{place1Str},
|
||||
#{positionStr}, #{name}, #{userId}, #{proxyId}, #{message} )
|
||||
]]>
|
||||
</insert>
|
||||
|
|
|
|||
File diff suppressed because it is too large
Load Diff
|
|
@ -66,66 +66,36 @@
|
|||
</select>
|
||||
|
||||
<select id="getFaListAll" parameterType="memberSearchVO" resultType="memberVO">
|
||||
<![CDATA[
|
||||
SELECT
|
||||
*
|
||||
FROM (
|
||||
SELECT
|
||||
ROWNUM RNUM, MEMBER_LIST.*
|
||||
FROM (
|
||||
SELECT
|
||||
MEMBER_LIST.PLACE1STR || ' ' || MEMBER_LIST.PLACE2STR AS PLACE3STR, MEMBER_LIST.*, TOTALEXCAREER_Y || '년 ' || TOTALEXCAREER_M || '개월' TOTALCAREER
|
||||
FROM
|
||||
(
|
||||
SELECT
|
||||
B.CODENM AS PLACE2STR, A.*
|
||||
FROM
|
||||
(SELECT
|
||||
B.CODENM AS POSITIONSTR, A.*
|
||||
FROM
|
||||
(SELECT
|
||||
B.CODENM AS PLACE1STR, A.*
|
||||
FROM
|
||||
(SELECT
|
||||
B.CODENM AS JOBTYPESTR, A.*
|
||||
FROM
|
||||
(
|
||||
SELECT
|
||||
TAGENT.*,
|
||||
select (ROW_NUMBER() OVER()) AS RNUM,
|
||||
(aa.PLACE1STR || ' ' || aa.PLACE2STR) PLACE3STR,
|
||||
TOTALEXCAREER_Y || '년 ' || TOTALEXCAREER_M || '개월' TOTALCAREER,
|
||||
aa.*
|
||||
from (select pl1.codenm place1str,
|
||||
pl2.codenm PLACE2STR,
|
||||
pst.codenm POSITIONSTR,
|
||||
jt.codenm JOBTYPESTR,
|
||||
MOD((EXCAREER_M + EXCAREER1_M + EXCAREER2_M + EXCAREER3_M), 12) TOTALEXCAREER_M,
|
||||
(EXCAREER_Y + EXCAREER1_Y + EXCAREER2_Y + EXCAREER3_Y) + FLOOR(MOD((EXCAREER_M + EXCAREER1_M + EXCAREER2_M + EXCAREER3_M), 12) / 12) TOTALEXCAREER_Y
|
||||
FROM (
|
||||
SELECT
|
||||
TAGENT.*,
|
||||
SUBSTR(EXCAREER, 1, INSTR(EXCAREER, '-', 1) - 1) EXCAREER_Y,
|
||||
SUBSTR(EXCAREER, INSTR(EXCAREER, '-', 1) + 1, 3) EXCAREER_M,
|
||||
SUBSTR(EXCAREER1, 1, INSTR(EXCAREER1, '-', 1) - 1) EXCAREER1_Y,
|
||||
SUBSTR(EXCAREER1, INSTR(EXCAREER1, '-', 1) + 1, 3) EXCAREER1_M,
|
||||
SUBSTR(EXCAREER2, 1, INSTR(EXCAREER2, '-', 1) - 1) EXCAREER2_Y,
|
||||
SUBSTR(EXCAREER2, INSTR(EXCAREER2, '-', 1) + 1, 3) EXCAREER2_M,
|
||||
SUBSTR(EXCAREER3, 1, INSTR(EXCAREER3, '-', 1) - 1) EXCAREER3_Y,
|
||||
SUBSTR(EXCAREER3, INSTR(EXCAREER3, '-', 1) + 1, 3) EXCAREER3_M
|
||||
FROM
|
||||
TAGENT
|
||||
) TAGENT
|
||||
) A,
|
||||
TCODE B
|
||||
WHERE
|
||||
B.CODE1(+) = 'C003' AND
|
||||
A.JOBTYPE = B.CODE2(+)) A,
|
||||
TCODE B
|
||||
WHERE
|
||||
A.PLACE1 = B.CODE2(+) AND
|
||||
B.CODE1(+) = 'C001' ) A,
|
||||
TCODE B
|
||||
WHERE
|
||||
A.POSITION = B.CODE2(+) AND
|
||||
B.CODE1(+) = 'C002') A,
|
||||
TCODE B
|
||||
WHERE
|
||||
A.PLACE1 = B.CODE1(+) AND
|
||||
A.PLACE2 = B.CODE2(+)
|
||||
ORDER BY ]]>
|
||||
(EXCAREER_Y + EXCAREER1_Y + EXCAREER2_Y + EXCAREER3_Y) + FLOOR(MOD((EXCAREER_M + EXCAREER1_M + EXCAREER2_M + EXCAREER3_M), 12) / 12) TOTALEXCAREER_Y,
|
||||
a.*
|
||||
from (select *,
|
||||
split_part(EXCAREER, '-', 1)::int EXCAREER_Y,
|
||||
split_part(EXCAREER, '-', 2)::int EXCAREER_M,
|
||||
split_part(EXCAREER1, '-', 1)::int EXCAREER1_Y,
|
||||
split_part(EXCAREER1, '-', 2)::int EXCAREER1_M,
|
||||
split_part(EXCAREER2, '-', 1)::int EXCAREER2_Y,
|
||||
split_part(EXCAREER2, '-', 2)::int EXCAREER2_M,
|
||||
split_part(EXCAREER3, '-', 1)::int EXCAREER3_Y,
|
||||
split_part(EXCAREER3, '-', 2)::int EXCAREER3_M
|
||||
from tagent
|
||||
<where>
|
||||
<if test="name != null and name != ''">
|
||||
AND NAME LIKE '%' || #{name} || '%'
|
||||
</if>
|
||||
<if test="place1 != null and place1 != ''">
|
||||
AND PLACE1 = #{place1}
|
||||
</if>
|
||||
</where>
|
||||
ORDER BY
|
||||
<if test="orderkey != null and orderkey != ''">
|
||||
<choose>
|
||||
<when test="ordercode == 7">
|
||||
|
|
@ -137,65 +107,13 @@
|
|||
</otherwise>
|
||||
</choose>
|
||||
</if>
|
||||
PLACE1,
|
||||
PLACE2,
|
||||
PLACE3,
|
||||
POSITION DESC,
|
||||
DUTIES,
|
||||
NAME
|
||||
<![CDATA[
|
||||
) MEMBER_LIST
|
||||
WHERE
|
||||
1 = 1
|
||||
]]>
|
||||
<if test="place1 != null and place1 != ''">
|
||||
AND PLACE1 = #{place1}
|
||||
</if>
|
||||
<if test="name != null and name != ''">
|
||||
AND NAME LIKE '%' || #{name} || '%'
|
||||
</if>
|
||||
<![CDATA[
|
||||
) MEMBER_LIST
|
||||
) A
|
||||
LEFT JOIN
|
||||
(
|
||||
SELECT
|
||||
IO_USERID, TO_CHAR(MAX(IO_REGDATE), 'YYYY-MM-DD HH24:MI:SS') AS RECENTDATE
|
||||
FROM
|
||||
H3_LOGINOUT_LOG
|
||||
GROUP BY
|
||||
IO_USERID
|
||||
) B
|
||||
ON
|
||||
A.USERID = B.IO_USERID
|
||||
]]>
|
||||
<!--
|
||||
SELECT
|
||||
P1.CODENM AS PLACE1STR, P2.CODENM AS PLACE2STR,
|
||||
J.CODENM AS JOBTYPESTR, POS.CODENM AS POSITIONSTR, P1.CODENM || ' ' || P2.CODENM,
|
||||
(경력계산)
|
||||
A.*
|
||||
FROM TAGENT A
|
||||
LEFT JOIN TCODE J ON J.CODE1 = 'C003' AND A.JOBTYPE = J.CODE2
|
||||
LEFT JOIN TCODE P1 ON P1.CODE1 = 'C001' AND A.PLACE1 = P1.CODE2
|
||||
LEFT JOIN TCODE POS ON POS.CODE1 = 'C002' AND A.POSITION = POS.CODE2
|
||||
LEFT JOIN TCODE P2 ON A.PLACE1 = P2.CODE1 AND A.PLACE2 = P2.CODE2
|
||||
LEFT JOIN
|
||||
(
|
||||
SELECT
|
||||
IO_USERID, TO_CHAR(MAX(IO_REGDATE), 'YYYY-MM-DD HH24:MI:SS') AS RECENTDATE
|
||||
FROM
|
||||
H3_LOGINOUT_LOG
|
||||
GROUP BY
|
||||
IO_USERID
|
||||
) B
|
||||
ON
|
||||
A.USERID = B.IO_USERID
|
||||
WHERE
|
||||
A.PLACE1 = 'PS92'
|
||||
ORDER BY
|
||||
PLACE1, PLACE2, PLACE3, POSITION DESC, DUTIES, NAME
|
||||
-->
|
||||
) a
|
||||
inner join tcode pl1 on pl1.code1 = 'C001' and a.place1 = pl1.code2
|
||||
inner join tcode pl2 on a.place1 = pl2.code1 and a.place2 = pl2.code2
|
||||
inner join tcode pst on pst.code1 = 'C002' and a.position = pst.code2
|
||||
inner join tcode jt on jt.code1 = 'C003' and a.jobtype = jt.code2
|
||||
) aa
|
||||
</select>
|
||||
|
||||
<select id="Member.getMemberSearchResult" parameterType="memberSearchVO" resultType="memberVO">
|
||||
|
|
@ -233,66 +151,36 @@
|
|||
</select>
|
||||
|
||||
<select id="Member.getFaMemberList" parameterType="memberSearchVO" resultType="memberVO">
|
||||
<![CDATA[
|
||||
SELECT
|
||||
*
|
||||
FROM (
|
||||
SELECT
|
||||
ROWNUM RNUM, MEMBER_LIST.*
|
||||
FROM (
|
||||
SELECT
|
||||
MEMBER_LIST.PLACE1STR || ' ' || MEMBER_LIST.PLACE2STR AS PLACE3STR, MEMBER_LIST.*, TOTALEXCAREER_Y || '년 ' || TOTALEXCAREER_M || '개월' TOTALCAREER
|
||||
FROM
|
||||
(
|
||||
SELECT
|
||||
B.CODENM AS PLACE2STR, A.*
|
||||
FROM
|
||||
(SELECT
|
||||
B.CODENM AS POSITIONSTR, A.*
|
||||
FROM
|
||||
(SELECT
|
||||
B.CODENM AS PLACE1STR, A.*
|
||||
FROM
|
||||
(SELECT
|
||||
B.CODENM AS JOBTYPESTR, A.*
|
||||
FROM
|
||||
(
|
||||
SELECT
|
||||
TAGENT.*,
|
||||
select (ROW_NUMBER() OVER()) AS RNUM,
|
||||
(aa.PLACE1STR || ' ' || aa.PLACE2STR) PLACE3STR,
|
||||
TOTALEXCAREER_Y || '년 ' || TOTALEXCAREER_M || '개월' TOTALCAREER,
|
||||
aa.*
|
||||
from (select pl1.codenm place1str,
|
||||
pl2.codenm PLACE2STR,
|
||||
pst.codenm POSITIONSTR,
|
||||
jt.codenm JOBTYPESTR,
|
||||
MOD((EXCAREER_M + EXCAREER1_M + EXCAREER2_M + EXCAREER3_M), 12) TOTALEXCAREER_M,
|
||||
(EXCAREER_Y + EXCAREER1_Y + EXCAREER2_Y + EXCAREER3_Y) + FLOOR(MOD((EXCAREER_M + EXCAREER1_M + EXCAREER2_M + EXCAREER3_M), 12) / 12) TOTALEXCAREER_Y
|
||||
FROM (
|
||||
SELECT
|
||||
TAGENT.*,
|
||||
SUBSTR(EXCAREER, 1, INSTR(EXCAREER, '-', 1) - 1) EXCAREER_Y,
|
||||
SUBSTR(EXCAREER, INSTR(EXCAREER, '-', 1) + 1, 3) EXCAREER_M,
|
||||
SUBSTR(EXCAREER1, 1, INSTR(EXCAREER1, '-', 1) - 1) EXCAREER1_Y,
|
||||
SUBSTR(EXCAREER1, INSTR(EXCAREER1, '-', 1) + 1, 3) EXCAREER1_M,
|
||||
SUBSTR(EXCAREER2, 1, INSTR(EXCAREER2, '-', 1) - 1) EXCAREER2_Y,
|
||||
SUBSTR(EXCAREER2, INSTR(EXCAREER2, '-', 1) + 1, 3) EXCAREER2_M,
|
||||
SUBSTR(EXCAREER3, 1, INSTR(EXCAREER3, '-', 1) - 1) EXCAREER3_Y,
|
||||
SUBSTR(EXCAREER3, INSTR(EXCAREER3, '-', 1) + 1, 3) EXCAREER3_M
|
||||
FROM
|
||||
TAGENT
|
||||
) TAGENT
|
||||
) A,
|
||||
TCODE B
|
||||
WHERE
|
||||
B.CODE1(+) = 'C003' AND
|
||||
A.JOBTYPE = B.CODE2(+)) A,
|
||||
TCODE B
|
||||
WHERE
|
||||
A.PLACE1 = B.CODE2(+) AND
|
||||
B.CODE1(+) = 'C001' ) A,
|
||||
TCODE B
|
||||
WHERE
|
||||
A.POSITION = B.CODE2(+) AND
|
||||
B.CODE1(+) = 'C002') A,
|
||||
TCODE B
|
||||
WHERE
|
||||
A.PLACE1 = B.CODE1(+) AND
|
||||
A.PLACE2 = B.CODE2(+)
|
||||
ORDER BY ]]>
|
||||
(EXCAREER_Y + EXCAREER1_Y + EXCAREER2_Y + EXCAREER3_Y) + FLOOR(MOD((EXCAREER_M + EXCAREER1_M + EXCAREER2_M + EXCAREER3_M), 12) / 12) TOTALEXCAREER_Y,
|
||||
a.*
|
||||
from (select *,
|
||||
split_part(EXCAREER, '-', 1)::int EXCAREER_Y,
|
||||
split_part(EXCAREER, '-', 2)::int EXCAREER_M,
|
||||
split_part(EXCAREER1, '-', 1)::int EXCAREER1_Y,
|
||||
split_part(EXCAREER1, '-', 2)::int EXCAREER1_M,
|
||||
split_part(EXCAREER2, '-', 1)::int EXCAREER2_Y,
|
||||
split_part(EXCAREER2, '-', 2)::int EXCAREER2_M,
|
||||
split_part(EXCAREER3, '-', 1)::int EXCAREER3_Y,
|
||||
split_part(EXCAREER3, '-', 2)::int EXCAREER3_M
|
||||
from tagent
|
||||
<where>
|
||||
<if test="name != null and name != ''">
|
||||
AND NAME LIKE '%' || #{name} || '%'
|
||||
</if>
|
||||
<if test="place1 != null and place1 != ''">
|
||||
AND PLACE1 = #{place1}
|
||||
</if>
|
||||
</where>
|
||||
ORDER BY
|
||||
<if test="orderkey != null and orderkey != ''">
|
||||
<choose>
|
||||
<when test="ordercode == 7">
|
||||
|
|
@ -304,189 +192,98 @@
|
|||
</otherwise>
|
||||
</choose>
|
||||
</if>
|
||||
PLACE1,
|
||||
PLACE2,
|
||||
PLACE3,
|
||||
POSITION DESC,
|
||||
DUTIES,
|
||||
NAME
|
||||
<![CDATA[) MEMBER_LIST
|
||||
WHERE
|
||||
1 = 1
|
||||
]]>
|
||||
<if test="place1 != null and place1 != ''">
|
||||
AND PLACE1 = #{place1}
|
||||
</if>
|
||||
<if test="name != null and name != ''">
|
||||
AND NAME LIKE '%' || #{name} || '%'
|
||||
</if>
|
||||
<![CDATA[
|
||||
) MEMBER_LIST
|
||||
) A
|
||||
LEFT JOIN
|
||||
(
|
||||
SELECT
|
||||
IO_USERID, TO_CHAR(MAX(IO_REGDATE), 'YYYY-MM-DD HH24:MI:SS') AS RECENTDATE
|
||||
FROM
|
||||
H3_LOGINOUT_LOG
|
||||
GROUP BY
|
||||
IO_USERID
|
||||
) B
|
||||
ON
|
||||
A.USERID = B.IO_USERID
|
||||
WHERE
|
||||
A.RNUM > #{firstIndex} AND
|
||||
A.RNUM <= #{firstIndex} + #{recordCountPerPage}
|
||||
ORDER BY
|
||||
A.RNUM
|
||||
]]>
|
||||
|
||||
PLACE1, PLACE2, PLACE3, POSITION DESC, DUTIES, NAME
|
||||
limit #{recordCountPerPage} offset #{firstIndex}) a
|
||||
inner join tcode pl1 on pl1.code1 = 'C001' and a.place1 = pl1.code2
|
||||
inner join tcode pl2 on a.place1 = pl2.code1 and a.place2 = pl2.code2
|
||||
inner join tcode pst on pst.code1 = 'C002' and a.position = pst.code2
|
||||
inner join tcode jt on jt.code1 = 'C003' and a.jobtype = jt.code2
|
||||
) aa
|
||||
</select>
|
||||
|
||||
<select id="Member.getCmmnListAll" parameterType="memberSearchVO" resultType="memberVO">
|
||||
<![CDATA[
|
||||
SELECT
|
||||
*
|
||||
FROM (
|
||||
SELECT
|
||||
ROWNUM RNUM, MEMBER_LIST.*
|
||||
FROM (
|
||||
SELECT
|
||||
MEMBER_LIST.PLACE1STR || ' ' || MEMBER_LIST.PLACE2STR AS PLACE3STR, MEMBER_LIST.NAME, MEMBER_LIST.POSITIONSTR,
|
||||
MEMBER_LIST.USERID, MEMBER_LIST.LOGINCHK, MEMBER_LIST.CHKCNT, MEMBER_LIST.IDNO
|
||||
FROM
|
||||
(
|
||||
SELECT
|
||||
B.CODENM AS PLACE2STR, A.*
|
||||
FROM
|
||||
(SELECT
|
||||
B.CODENM AS POSITIONSTR, A.*
|
||||
FROM
|
||||
(SELECT
|
||||
B.CODENM AS PLACE1STR, A.*
|
||||
FROM
|
||||
TUSER A,
|
||||
TCODE B
|
||||
WHERE
|
||||
A.PLACE1 = B.CODE2(+) AND
|
||||
B.CODE1(+) = 'C001' ) A,
|
||||
TCODE B
|
||||
WHERE
|
||||
A.POSITION = B.CODE2(+) AND
|
||||
B.CODE1(+) = 'C002') A,
|
||||
TCODE B
|
||||
WHERE
|
||||
A.PLACE1 = B.CODE1(+) AND
|
||||
B.CODE2(+) = A.PLACE2
|
||||
ORDER BY]]>
|
||||
<if test="orderkey != null and orderkey != ''">
|
||||
${orderkey} <choose><when test="ordertype == 1">DESC</when><otherwise>ASC</otherwise></choose>,
|
||||
select (ROW_NUMBER() OVER()) AS RNUM, aa.*
|
||||
from (select pl1.codenm || ' ' ||pl2.codenm place3str,
|
||||
a.name,
|
||||
pst.codenm POSITIONSTR,
|
||||
a.userid,
|
||||
a.loginchk,
|
||||
a.chkcnt,
|
||||
a.idno,
|
||||
a.place1,
|
||||
b.io_userid,
|
||||
b.recentdate
|
||||
from tuser a
|
||||
inner join tcode pl1 on pl1.code1 = 'C001' and a.place1 = pl1.code2
|
||||
inner join tcode pl2 on a.place1 = pl2.code1 and a.place2 = pl2.code2
|
||||
inner join tcode pst on pst.code1 = 'C002' and a.position = pst.code2
|
||||
left outer join (SELECT IO_USERID, TO_CHAR(MAX(IO_REGDATE), 'YYYY-MM-DD HH24:MI:SS') AS RECENTDATE
|
||||
FROM H3_LOGINOUT_LOG
|
||||
<where>
|
||||
<if test="place1 != null and place1 != ''">
|
||||
AND IO_PLACE1 = #{place1}
|
||||
</if>
|
||||
PLACE1,
|
||||
PLACE2,
|
||||
POSITION DESC,
|
||||
NAME
|
||||
<![CDATA[) MEMBER_LIST
|
||||
WHERE
|
||||
1 = 1
|
||||
]]>
|
||||
<if test="name != null and name != ''">
|
||||
AND IO_NAME LIKE '%' || #{name} || '%'
|
||||
</if>
|
||||
</where>
|
||||
GROUP BY IO_USERID ) B ON A.USERID = B.IO_USERID
|
||||
<where>
|
||||
<if test="place1 != null and place1 != ''">
|
||||
AND PLACE1 = #{place1}
|
||||
</if>
|
||||
<if test="name != null and name != ''">
|
||||
AND NAME LIKE '%' || #{name} || '%'
|
||||
</if>
|
||||
<![CDATA[
|
||||
) MEMBER_LIST
|
||||
) A
|
||||
LEFT JOIN
|
||||
(
|
||||
SELECT
|
||||
IO_USERID, TO_CHAR(MAX(IO_REGDATE), 'YYYY-MM-DD HH24:MI:SS') AS RECENTDATE
|
||||
FROM
|
||||
H3_LOGINOUT_LOG
|
||||
GROUP BY
|
||||
IO_USERID
|
||||
) B
|
||||
ON
|
||||
A.USERID = B.IO_USERID
|
||||
]]>
|
||||
</where>
|
||||
ORDER BY
|
||||
<if test="orderkey != null and orderkey != ''">
|
||||
${orderkey} <choose><when test="ordertype == 1">DESC</when></choose>,
|
||||
</if>
|
||||
PLACE1, PLACE2, POSITION DESC, NAME ) aa
|
||||
</select>
|
||||
|
||||
<select id="Member.getCmmnMemberList" parameterType="memberSearchVO" resultType="memberVO">
|
||||
<![CDATA[
|
||||
SELECT
|
||||
*
|
||||
FROM (
|
||||
SELECT
|
||||
ROWNUM RNUM, MEMBER_LIST.*
|
||||
FROM (
|
||||
SELECT
|
||||
MEMBER_LIST.PLACE1STR || ' ' || MEMBER_LIST.PLACE2STR AS PLACE3STR, MEMBER_LIST.NAME, MEMBER_LIST.POSITIONSTR,
|
||||
MEMBER_LIST.USERID, MEMBER_LIST.LOGINCHK, MEMBER_LIST.CHKCNT, MEMBER_LIST.IDNO, MEMBER_LIST.PLACE1
|
||||
FROM
|
||||
(
|
||||
SELECT
|
||||
B.CODENM AS PLACE2STR, A.*
|
||||
FROM
|
||||
(SELECT
|
||||
B.CODENM AS POSITIONSTR, A.*
|
||||
FROM
|
||||
(SELECT
|
||||
B.CODENM AS PLACE1STR, A.*
|
||||
FROM
|
||||
TUSER A,
|
||||
TCODE B
|
||||
WHERE
|
||||
A.PLACE1 = B.CODE2(+) AND
|
||||
B.CODE1(+) = 'C001' ) A,
|
||||
TCODE B
|
||||
WHERE
|
||||
A.POSITION = B.CODE2(+) AND
|
||||
B.CODE1(+) = 'C002') A,
|
||||
TCODE B
|
||||
WHERE
|
||||
A.PLACE1 = B.CODE1(+) AND
|
||||
B.CODE2(+) = A.PLACE2
|
||||
ORDER BY]]>
|
||||
<if test="orderkey != null and orderkey != ''">
|
||||
${orderkey} <choose><when test="ordertype == 1">DESC</when><otherwise>ASC</otherwise></choose>,
|
||||
select (ROW_NUMBER() OVER()) AS RNUM, aa.*
|
||||
from (select pl1.codenm || ' ' ||pl2.codenm place3str,
|
||||
a.name,
|
||||
pst.codenm POSITIONSTR,
|
||||
a.userid,
|
||||
a.loginchk,
|
||||
a.chkcnt,
|
||||
a.idno,
|
||||
a.place1,
|
||||
b.io_userid,
|
||||
b.recentdate
|
||||
from tuser a
|
||||
inner join tcode pl1 on pl1.code1 = 'C001' and a.place1 = pl1.code2
|
||||
inner join tcode pl2 on a.place1 = pl2.code1 and a.place2 = pl2.code2
|
||||
inner join tcode pst on pst.code1 = 'C002' and a.position = pst.code2
|
||||
left outer join (SELECT IO_USERID, TO_CHAR(MAX(IO_REGDATE), 'YYYY-MM-DD HH24:MI:SS') AS RECENTDATE
|
||||
FROM H3_LOGINOUT_LOG
|
||||
<where>
|
||||
<if test="place1 != null and place1 != ''">
|
||||
AND IO_PLACE1 = #{place1}
|
||||
</if>
|
||||
PLACE1,
|
||||
PLACE2,
|
||||
POSITION DESC,
|
||||
NAME
|
||||
<![CDATA[) MEMBER_LIST
|
||||
WHERE
|
||||
1 = 1
|
||||
]]>
|
||||
<if test="name != null and name != ''">
|
||||
AND IO_NAME LIKE '%' || #{name} || '%'
|
||||
</if>
|
||||
</where>
|
||||
GROUP BY IO_USERID ) B ON A.USERID = B.IO_USERID
|
||||
<where>
|
||||
<if test="place1 != null and place1 != ''">
|
||||
AND PLACE1 = #{place1}
|
||||
</if>
|
||||
<if test="name != null and name != ''">
|
||||
AND NAME LIKE '%' || #{name} || '%'
|
||||
</if>
|
||||
<![CDATA[
|
||||
) MEMBER_LIST
|
||||
) A
|
||||
LEFT JOIN
|
||||
(
|
||||
SELECT
|
||||
IO_USERID, TO_CHAR(MAX(IO_REGDATE), 'YYYY-MM-DD HH24:MI:SS') AS RECENTDATE
|
||||
FROM
|
||||
H3_LOGINOUT_LOG
|
||||
GROUP BY
|
||||
IO_USERID
|
||||
) B
|
||||
ON
|
||||
A.USERID = B.IO_USERID
|
||||
WHERE
|
||||
RNUM > #{firstIndex} AND
|
||||
RNUM <= #{firstIndex} + #{recordCountPerPage}
|
||||
</where>
|
||||
ORDER BY
|
||||
RNUM
|
||||
]]>
|
||||
|
||||
<if test="orderkey != null and orderkey != ''">
|
||||
${orderkey} <choose><when test="ordertype == 1">DESC</when><otherwise>ASC</otherwise></choose>,
|
||||
</if>
|
||||
PLACE1, PLACE2, POSITION DESC, NAME
|
||||
limit #{recordCountPerPage} offset #{firstIndex} ) aa
|
||||
</select>
|
||||
|
||||
|
||||
|
|
@ -588,9 +385,9 @@
|
|||
PLACE1 = #{place1}, PLACE2 = #{place2}, PLACE3 = #{place3},
|
||||
POSITION = #{position}, DUTIES = #{duties}, JOBTYPE = #{jobtype}, INOUT = #{inout}, SCHOLARSHIP = #{scholarship},
|
||||
EXCAREER = #{excareer}, EXCAREER1 = #{excareer1}, EXCAREER2 = #{excareer2}, EXCAREER3 = #{excareer3},
|
||||
COMMENT_ = #{comment_}, LOGINDATE = TO_CHAR(SYSDATE, 'YYYY-MM-DD'),
|
||||
COMMENT_ = #{comment_}, LOGINDATE = TO_CHAR(NOW(), 'YYYY-MM-DD'),
|
||||
CHARGE = #{charge}, EXPLACE = #{explace}, USEGRADE = #{usegrade}, USERIMG = #{userimg,jdbcType=VARCHAR}, USERSIGN = #{usersign,jdbcType=VARCHAR},
|
||||
CHKCNT = NVL(#{chkcnt}, 0)
|
||||
CHKCNT = COALESCE(#{chkcnt}, 0)
|
||||
WHERE
|
||||
USERID = #{userid}
|
||||
]]>
|
||||
|
|
@ -616,7 +413,7 @@
|
|||
</otherwise>
|
||||
</choose>
|
||||
<![CDATA[
|
||||
#{place1}, #{place2}, #{position}, TO_CHAR(SYSDATE, 'YYYYMMDD'), TO_CHAR(SYSDATE, 'YYYYMMDD'), #{writer} )
|
||||
#{place1}, #{place2}, #{position}, TO_CHAR(NOW(), 'YYYYMMDD'), TO_CHAR(NOW(), 'YYYYMMDD'), #{writer} )
|
||||
]]>
|
||||
</insert>
|
||||
|
||||
|
|
@ -634,7 +431,7 @@
|
|||
PLACE1 = #{place1},
|
||||
PLACE2 = #{place2},
|
||||
POSITION = #{position},
|
||||
CHKCNT = NVL(#{chkcnt}, 0)
|
||||
CHKCNT = COALESCE(#{chkcnt}, 0)
|
||||
WHERE
|
||||
USERID = #{userid}
|
||||
]]>
|
||||
|
|
@ -675,43 +472,46 @@
|
|||
</choose>
|
||||
<![CDATA[
|
||||
SET
|
||||
LOGINDATE = TO_CHAR(SYSDATE, 'YYYY-MM-DD'),
|
||||
LOGINDATE = TO_CHAR(NOW(), 'YYYY-MM-DD'),
|
||||
PASSWD = XX1.ENC_VARCHAR2_INS(#{passwd}, 10, 'SHA256')
|
||||
WHERE
|
||||
USERID = #{userid}
|
||||
]]>
|
||||
|
||||
</update>
|
||||
|
||||
|
||||
<select id="Member.getCapacityManagement" resultType="hashmap">
|
||||
<![CDATA[
|
||||
SELECT
|
||||
CASE RESULT_LIST.PLACE WHEN 'PS0' THEN '계' WHEN 'PS001' THEN '소계' ELSE CODE.CODENM END AS CODENM,
|
||||
RESULT_LIST.*, CURRENT_CNT - TOT_CNT AS EXCESS
|
||||
SELECT CASE RESULT_LIST.PLACE
|
||||
WHEN 'PS0' THEN '계'
|
||||
WHEN 'PS001' THEN '소계'
|
||||
ELSE CODE.CODENM
|
||||
END AS CODENM,
|
||||
RESULT_LIST.*,
|
||||
CURRENT_CNT - TOT_CNT AS EXCESS
|
||||
FROM (
|
||||
SELECT
|
||||
A.PLACE1 AS PLACE,
|
||||
NVL(A.TOT_CNT, 0) AS TOT_CNT,
|
||||
NVL(B.CURRENT_CNT,0) AS CURRENT_CNT,
|
||||
NVL(A.POSITION204,0) AS POSITION204, NVL(B.CNT_204,0) AS CNT_204,
|
||||
NVL(A.POSITION203,0) AS POSITION203, NVL(B.CNT_203,0) AS CNT_203,
|
||||
NVL(A.POSITION202,0) AS POSITION202, NVL(B.CNT_202,0) AS CNT_202,
|
||||
NVL(A.POSITION201,0) AS POSITION201, NVL(B.CNT_201,0) AS CNT_201,
|
||||
NVL(A.POSITION104,0) AS POSITION104, NVL(B.CNT_104,0) AS CNT_104,
|
||||
NVL(A.POSITION103,0) AS POSITION103, NVL(B.CNT_103,0) AS CNT_103,
|
||||
NVL(A.POSITION102,0) AS POSITION102, NVL(B.CNT_102,0) AS CNT_102
|
||||
COALESCE(A.TOT_CNT, 0) AS TOT_CNT,
|
||||
COALESCE(B.CURRENT_CNT,0) AS CURRENT_CNT,
|
||||
COALESCE(A.POSITION204,0) AS POSITION204, COALESCE(B.CNT_204,0) AS CNT_204,
|
||||
COALESCE(A.POSITION203,0) AS POSITION203, COALESCE(B.CNT_203,0) AS CNT_203,
|
||||
COALESCE(A.POSITION202,0) AS POSITION202, COALESCE(B.CNT_202,0) AS CNT_202,
|
||||
COALESCE(A.POSITION201,0) AS POSITION201, COALESCE(B.CNT_201,0) AS CNT_201,
|
||||
COALESCE(A.POSITION104,0) AS POSITION104, COALESCE(B.CNT_104,0) AS CNT_104,
|
||||
COALESCE(A.POSITION103,0) AS POSITION103, COALESCE(B.CNT_103,0) AS CNT_103,
|
||||
COALESCE(A.POSITION102,0) AS POSITION102, COALESCE(B.CNT_102,0) AS CNT_102
|
||||
FROM (
|
||||
SELECT
|
||||
'PS0' AS PLACE1,
|
||||
SUM(NVL((POSITION204 + POSITION203 + POSITION202 + POSITION201 + POSITION104 + POSITION103 + POSITION102),0)) AS TOT_CNT,
|
||||
SUM(NVL(POSITION204,0)) AS POSITION204,
|
||||
SUM(NVL(POSITION203,0)) AS POSITION203,
|
||||
SUM(NVL(POSITION202,0)) AS POSITION202,
|
||||
SUM(NVL(POSITION201,0)) AS POSITION201,
|
||||
SUM(NVL(POSITION104,0)) AS POSITION104,
|
||||
SUM(NVL(POSITION103,0)) AS POSITION103,
|
||||
SUM(NVL(POSITION102,0)) AS POSITION102
|
||||
SUM(COALESCE((POSITION204 + POSITION203 + POSITION202 + POSITION201 + POSITION104 + POSITION103 + POSITION102),0)) AS TOT_CNT,
|
||||
SUM(COALESCE(POSITION204,0)) AS POSITION204,
|
||||
SUM(COALESCE(POSITION203,0)) AS POSITION203,
|
||||
SUM(COALESCE(POSITION202,0)) AS POSITION202,
|
||||
SUM(COALESCE(POSITION201,0)) AS POSITION201,
|
||||
SUM(COALESCE(POSITION104,0)) AS POSITION104,
|
||||
SUM(COALESCE(POSITION103,0)) AS POSITION103,
|
||||
SUM(COALESCE(POSITION102,0)) AS POSITION102
|
||||
FROM TAGENTNUM
|
||||
WHERE PLACE1 <> 'PS95'
|
||||
) A INNER JOIN (
|
||||
|
|
@ -740,15 +540,15 @@
|
|||
|
||||
SELECT
|
||||
A.PLACE1 AS PLACE,
|
||||
NVL((A.POSITION204 + A.POSITION203 + A.POSITION202 + A.POSITION201 + A.POSITION104 + A.POSITION103 + A.POSITION102), 0) AS TOT_CNT,
|
||||
NVL(B.CURRENT_CNT,0) AS CURRENT_CNT,
|
||||
NVL(A.POSITION204,0) AS POSITION204, NVL(B.CNT_204,0) AS CNT_204,
|
||||
NVL(A.POSITION203,0) AS POSITION203, NVL(B.CNT_203,0) AS CNT_203,
|
||||
NVL(A.POSITION202,0) AS POSITION202, NVL(B.CNT_202,0) AS CNT_202,
|
||||
NVL(A.POSITION201,0) AS POSITION201, NVL(B.CNT_201,0) AS CNT_201,
|
||||
NVL(A.POSITION104,0) AS POSITION104, NVL(B.CNT_104,0) AS CNT_104,
|
||||
NVL(A.POSITION103,0) AS POSITION103, NVL(B.CNT_103,0) AS CNT_103,
|
||||
NVL(A.POSITION102,0) AS POSITION102, NVL(B.CNT_102,0) AS CNT_102
|
||||
COALESCE((A.POSITION204 + A.POSITION203 + A.POSITION202 + A.POSITION201 + A.POSITION104 + A.POSITION103 + A.POSITION102), 0) AS TOT_CNT,
|
||||
COALESCE(B.CURRENT_CNT,0) AS CURRENT_CNT,
|
||||
COALESCE(A.POSITION204,0) AS POSITION204, COALESCE(B.CNT_204,0) AS CNT_204,
|
||||
COALESCE(A.POSITION203,0) AS POSITION203, COALESCE(B.CNT_203,0) AS CNT_203,
|
||||
COALESCE(A.POSITION202,0) AS POSITION202, COALESCE(B.CNT_202,0) AS CNT_202,
|
||||
COALESCE(A.POSITION201,0) AS POSITION201, COALESCE(B.CNT_201,0) AS CNT_201,
|
||||
COALESCE(A.POSITION104,0) AS POSITION104, COALESCE(B.CNT_104,0) AS CNT_104,
|
||||
COALESCE(A.POSITION103,0) AS POSITION103, COALESCE(B.CNT_103,0) AS CNT_103,
|
||||
COALESCE(A.POSITION102,0) AS POSITION102, COALESCE(B.CNT_102,0) AS CNT_102
|
||||
FROM TAGENTNUM A
|
||||
INNER JOIN (
|
||||
SELECT
|
||||
|
|
@ -779,26 +579,26 @@
|
|||
|
||||
SELECT
|
||||
A.PLACE1 AS PLACE,
|
||||
NVL(A.TOT_CNT, 0) AS TOT_CNT,
|
||||
NVL(B.CURRENT_CNT,0) AS CURRENT_CNT,
|
||||
NVL(A.POSITION204,0) AS POSITION204, NVL(B.CNT_204,0) AS CNT_204,
|
||||
NVL(A.POSITION203,0) AS POSITION203, NVL(B.CNT_203,0) AS CNT_203,
|
||||
NVL(A.POSITION202,0) AS POSITION202, NVL(B.CNT_202,0) AS CNT_202,
|
||||
NVL(A.POSITION201,0) AS POSITION201, NVL(B.CNT_201,0) AS CNT_201,
|
||||
NVL(A.POSITION104,0) AS POSITION104, NVL(B.CNT_104,0) AS CNT_104,
|
||||
NVL(A.POSITION103,0) AS POSITION103, NVL(B.CNT_103,0) AS CNT_103,
|
||||
NVL(A.POSITION102,0) AS POSITION102, NVL(B.CNT_102,0) AS CNT_102
|
||||
COALESCE(A.TOT_CNT, 0) AS TOT_CNT,
|
||||
COALESCE(B.CURRENT_CNT,0) AS CURRENT_CNT,
|
||||
COALESCE(A.POSITION204,0) AS POSITION204, COALESCE(B.CNT_204,0) AS CNT_204,
|
||||
COALESCE(A.POSITION203,0) AS POSITION203, COALESCE(B.CNT_203,0) AS CNT_203,
|
||||
COALESCE(A.POSITION202,0) AS POSITION202, COALESCE(B.CNT_202,0) AS CNT_202,
|
||||
COALESCE(A.POSITION201,0) AS POSITION201, COALESCE(B.CNT_201,0) AS CNT_201,
|
||||
COALESCE(A.POSITION104,0) AS POSITION104, COALESCE(B.CNT_104,0) AS CNT_104,
|
||||
COALESCE(A.POSITION103,0) AS POSITION103, COALESCE(B.CNT_103,0) AS CNT_103,
|
||||
COALESCE(A.POSITION102,0) AS POSITION102, COALESCE(B.CNT_102,0) AS CNT_102
|
||||
FROM (
|
||||
SELECT
|
||||
'PS001' AS PLACE1,
|
||||
SUM(NVL((POSITION204 + POSITION203 + POSITION202 + POSITION201 + POSITION104 + POSITION103 + POSITION102),0)) AS TOT_CNT,
|
||||
SUM(NVL(POSITION204,0)) AS POSITION204,
|
||||
SUM(NVL(POSITION203,0)) AS POSITION203,
|
||||
SUM(NVL(POSITION202,0)) AS POSITION202,
|
||||
SUM(NVL(POSITION201,0)) AS POSITION201,
|
||||
SUM(NVL(POSITION104,0)) AS POSITION104,
|
||||
SUM(NVL(POSITION103,0)) AS POSITION103,
|
||||
SUM(NVL(POSITION102,0)) AS POSITION102
|
||||
SUM(COALESCE((POSITION204 + POSITION203 + POSITION202 + POSITION201 + POSITION104 + POSITION103 + POSITION102),0)) AS TOT_CNT,
|
||||
SUM(COALESCE(POSITION204,0)) AS POSITION204,
|
||||
SUM(COALESCE(POSITION203,0)) AS POSITION203,
|
||||
SUM(COALESCE(POSITION202,0)) AS POSITION202,
|
||||
SUM(COALESCE(POSITION201,0)) AS POSITION201,
|
||||
SUM(COALESCE(POSITION104,0)) AS POSITION104,
|
||||
SUM(COALESCE(POSITION103,0)) AS POSITION103,
|
||||
SUM(COALESCE(POSITION102,0)) AS POSITION102
|
||||
FROM
|
||||
TAGENTNUM
|
||||
WHERE
|
||||
|
|
@ -832,15 +632,15 @@
|
|||
|
||||
SELECT
|
||||
A.PLACE1 AS PLACE,
|
||||
NVL((A.POSITION204 + A.POSITION203 + A.POSITION202 + A.POSITION201 + A.POSITION104 + A.POSITION103 + A.POSITION102), 0) AS TOT_CNT,
|
||||
NVL(B.CURRENT_CNT,0) AS CURRENT_CNT,
|
||||
NVL(A.POSITION204,0) AS POSITION204, NVL(B.CNT_204,0) AS CNT_204,
|
||||
NVL(A.POSITION203,0) AS POSITION203, NVL(B.CNT_203,0) AS CNT_203,
|
||||
NVL(A.POSITION202,0) AS POSITION202, NVL(B.CNT_202,0) AS CNT_202,
|
||||
NVL(A.POSITION201,0) AS POSITION201, NVL(B.CNT_201,0) AS CNT_201,
|
||||
NVL(A.POSITION104,0) AS POSITION104, NVL(B.CNT_104,0) AS CNT_104,
|
||||
NVL(A.POSITION103,0) AS POSITION103, NVL(B.CNT_103,0) AS CNT_103,
|
||||
NVL(A.POSITION102,0) AS POSITION102, NVL(B.CNT_102,0) AS CNT_102
|
||||
COALESCE((A.POSITION204 + A.POSITION203 + A.POSITION202 + A.POSITION201 + A.POSITION104 + A.POSITION103 + A.POSITION102), 0) AS TOT_CNT,
|
||||
COALESCE(B.CURRENT_CNT,0) AS CURRENT_CNT,
|
||||
COALESCE(A.POSITION204,0) AS POSITION204, COALESCE(B.CNT_204,0) AS CNT_204,
|
||||
COALESCE(A.POSITION203,0) AS POSITION203, COALESCE(B.CNT_203,0) AS CNT_203,
|
||||
COALESCE(A.POSITION202,0) AS POSITION202, COALESCE(B.CNT_202,0) AS CNT_202,
|
||||
COALESCE(A.POSITION201,0) AS POSITION201, COALESCE(B.CNT_201,0) AS CNT_201,
|
||||
COALESCE(A.POSITION104,0) AS POSITION104, COALESCE(B.CNT_104,0) AS CNT_104,
|
||||
COALESCE(A.POSITION103,0) AS POSITION103, COALESCE(B.CNT_103,0) AS CNT_103,
|
||||
COALESCE(A.POSITION102,0) AS POSITION102, COALESCE(B.CNT_102,0) AS CNT_102
|
||||
FROM
|
||||
TAGENTNUM A LEFT OUTER JOIN (
|
||||
SELECT
|
||||
|
|
@ -889,15 +689,15 @@
|
|||
SELECT 'PS' AS PLACE1
|
||||
,SUM(CAREER_Y+CAREER1_Y+CAREER2_Y+CAREER3_Y) AS TOT_CNT_Y
|
||||
,SUM(CAREER_M+CAREER1_M+CAREER2_M+CAREER3_M) AS TOT_CNT_M
|
||||
,SUM(NVL(CAREER_Y, 0)) AS CAREER_Y
|
||||
,SUM(NVL(CAREER_M, 0)) AS CAREER_M
|
||||
,SUM(NVL(CAREER1_Y, 0)) AS CAREER1_Y
|
||||
,SUM(NVL(CAREER1_M, 0)) AS CAREER1_M
|
||||
,SUM(NVL(CAREER2_Y, 0)) AS CAREER2_Y
|
||||
,SUM(NVL(CAREER2_M, 0)) AS CAREER2_M
|
||||
,SUM(NVL(CAREER3_Y, 0)) AS CAREER3_Y
|
||||
,SUM(NVL(CAREER3_M, 0)) AS CAREER3_M
|
||||
,SUM((TO_NUMBER(TO_CHAR(SYSDATE, 'MM'), '99') + (TO_NUMBER(TO_CHAR(SYSDATE, 'YYYY'), '9999')
|
||||
,SUM(COALESCE(CAREER_Y, 0)) AS CAREER_Y
|
||||
,SUM(COALESCE(CAREER_M, 0)) AS CAREER_M
|
||||
,SUM(COALESCE(CAREER1_Y, 0)) AS CAREER1_Y
|
||||
,SUM(COALESCE(CAREER1_M, 0)) AS CAREER1_M
|
||||
,SUM(COALESCE(CAREER2_Y, 0)) AS CAREER2_Y
|
||||
,SUM(COALESCE(CAREER2_M, 0)) AS CAREER2_M
|
||||
,SUM(COALESCE(CAREER3_Y, 0)) AS CAREER3_Y
|
||||
,SUM(COALESCE(CAREER3_M, 0)) AS CAREER3_M
|
||||
,SUM((TO_NUMBER(TO_CHAR(NOW(), 'MM'), '99') + (TO_NUMBER(TO_CHAR(NOW(), 'YYYY'), '9999')
|
||||
- TO_NUMBER(TO_CHAR(TO_DATE(ADATE, 'YYYY-MM-DD'), 'YYYY'), '9999'))*12)
|
||||
- TO_NUMBER(TO_CHAR(TO_DATE(ADATE, 'YYYY-MM-DD'), 'MM'), '99')) AS ADD_CAREER
|
||||
FROM H3_CAREER_STAT
|
||||
|
|
@ -905,15 +705,15 @@
|
|||
SELECT 'PS00' AS PLACE1
|
||||
,SUM(CAREER_Y+CAREER1_Y+CAREER2_Y+CAREER3_Y) AS TOT_CNT_Y
|
||||
,SUM(CAREER_M+CAREER1_M+CAREER2_M+CAREER3_M) AS TOT_CNT_M
|
||||
,SUM(NVL(CAREER_Y, 0)) AS CAREER_Y
|
||||
,SUM(NVL(CAREER_M, 0)) AS CAREER_M
|
||||
,SUM(NVL(CAREER1_Y, 0)) AS CAREER1_Y
|
||||
,SUM(NVL(CAREER1_M, 0)) AS CAREER1_M
|
||||
,SUM(NVL(CAREER2_Y, 0)) AS CAREER2_Y
|
||||
,SUM(NVL(CAREER2_M, 0)) AS CAREER2_M
|
||||
,SUM(NVL(CAREER3_Y, 0)) AS CAREER3_Y
|
||||
,SUM(NVL(CAREER3_M, 0)) AS CAREER3_M
|
||||
,SUM((TO_NUMBER(TO_CHAR(SYSDATE, 'MM'), '99') + (TO_NUMBER(TO_CHAR(SYSDATE, 'YYYY'), '9999')
|
||||
,SUM(COALESCE(CAREER_Y, 0)) AS CAREER_Y
|
||||
,SUM(COALESCE(CAREER_M, 0)) AS CAREER_M
|
||||
,SUM(COALESCE(CAREER1_Y, 0)) AS CAREER1_Y
|
||||
,SUM(COALESCE(CAREER1_M, 0)) AS CAREER1_M
|
||||
,SUM(COALESCE(CAREER2_Y, 0)) AS CAREER2_Y
|
||||
,SUM(COALESCE(CAREER2_M, 0)) AS CAREER2_M
|
||||
,SUM(COALESCE(CAREER3_Y, 0)) AS CAREER3_Y
|
||||
,SUM(COALESCE(CAREER3_M, 0)) AS CAREER3_M
|
||||
,SUM((TO_NUMBER(TO_CHAR(NOW(), 'MM'), '99') + (TO_NUMBER(TO_CHAR(NOW(), 'YYYY'), '9999')
|
||||
- TO_NUMBER(TO_CHAR(TO_DATE(ADATE, 'YYYY-MM-DD'), 'YYYY'), '9999'))*12)
|
||||
- TO_NUMBER(TO_CHAR(TO_DATE(ADATE, 'YYYY-MM-DD'), 'MM'), '99')) AS ADD_CAREER
|
||||
FROM
|
||||
|
|
@ -927,15 +727,15 @@
|
|||
'PS001' AS PLACE1
|
||||
,SUM(CAREER_Y+CAREER1_Y+CAREER2_Y+CAREER3_Y) AS TOT_CNT_Y
|
||||
,SUM(CAREER_M+CAREER1_M+CAREER2_M+CAREER3_M) AS TOT_CNT_M
|
||||
,SUM(NVL(CAREER_Y, 0)) AS CAREER_Y
|
||||
,SUM(NVL(CAREER_M, 0)) AS CAREER_M
|
||||
,SUM(NVL(CAREER1_Y, 0)) AS CAREER1_Y
|
||||
,SUM(NVL(CAREER1_M, 0)) AS CAREER1_M
|
||||
,SUM(NVL(CAREER2_Y, 0)) AS CAREER2_Y
|
||||
,SUM(NVL(CAREER2_M, 0)) AS CAREER2_M
|
||||
,SUM(NVL(CAREER3_Y, 0)) AS CAREER3_Y
|
||||
,SUM(NVL(CAREER3_M, 0)) AS CAREER3_M
|
||||
,SUM((TO_NUMBER(TO_CHAR(SYSDATE, 'MM'), '99') + (TO_NUMBER(TO_CHAR(SYSDATE, 'YYYY'), '9999')
|
||||
,SUM(COALESCE(CAREER_Y, 0)) AS CAREER_Y
|
||||
,SUM(COALESCE(CAREER_M, 0)) AS CAREER_M
|
||||
,SUM(COALESCE(CAREER1_Y, 0)) AS CAREER1_Y
|
||||
,SUM(COALESCE(CAREER1_M, 0)) AS CAREER1_M
|
||||
,SUM(COALESCE(CAREER2_Y, 0)) AS CAREER2_Y
|
||||
,SUM(COALESCE(CAREER2_M, 0)) AS CAREER2_M
|
||||
,SUM(COALESCE(CAREER3_Y, 0)) AS CAREER3_Y
|
||||
,SUM(COALESCE(CAREER3_M, 0)) AS CAREER3_M
|
||||
,SUM((TO_NUMBER(TO_CHAR(NOW(), 'MM'), '99') + (TO_NUMBER(TO_CHAR(NOW(), 'YYYY'), '9999')
|
||||
- TO_NUMBER(TO_CHAR(TO_DATE(ADATE, 'YYYY-MM-DD'), 'YYYY'), '9999'))*12)
|
||||
- TO_NUMBER(TO_CHAR(TO_DATE(ADATE, 'YYYY-MM-DD'), 'MM'), '99')) AS ADD_CAREER
|
||||
FROM
|
||||
|
|
@ -948,15 +748,15 @@
|
|||
PLACE1
|
||||
,SUM(CAREER_Y+CAREER1_Y+CAREER2_Y+CAREER3_Y) AS TOT_CNT_Y
|
||||
,SUM(CAREER_M+CAREER1_M+CAREER2_M+CAREER3_M) AS TOT_CNT_M
|
||||
,SUM(NVL(CAREER_Y, 0)) AS CAREER_Y
|
||||
,SUM(NVL(CAREER_M, 0)) AS CAREER_M
|
||||
,SUM(NVL(CAREER1_Y, 0)) AS CAREER1_Y
|
||||
,SUM(NVL(CAREER1_M, 0)) AS CAREER1_M
|
||||
,SUM(NVL(CAREER2_Y, 0)) AS CAREER2_Y
|
||||
,SUM(NVL(CAREER2_M, 0)) AS CAREER2_M
|
||||
,SUM(NVL(CAREER3_Y, 0)) AS CAREER3_Y
|
||||
,SUM(NVL(CAREER3_M, 0)) AS CAREER3_M
|
||||
,SUM((TO_NUMBER(TO_CHAR(SYSDATE, 'MM'), '99') + (TO_NUMBER(TO_CHAR(SYSDATE, 'YYYY'), '9999')
|
||||
,SUM(COALESCE(CAREER_Y, 0)) AS CAREER_Y
|
||||
,SUM(COALESCE(CAREER_M, 0)) AS CAREER_M
|
||||
,SUM(COALESCE(CAREER1_Y, 0)) AS CAREER1_Y
|
||||
,SUM(COALESCE(CAREER1_M, 0)) AS CAREER1_M
|
||||
,SUM(COALESCE(CAREER2_Y, 0)) AS CAREER2_Y
|
||||
,SUM(COALESCE(CAREER2_M, 0)) AS CAREER2_M
|
||||
,SUM(COALESCE(CAREER3_Y, 0)) AS CAREER3_Y
|
||||
,SUM(COALESCE(CAREER3_M, 0)) AS CAREER3_M
|
||||
,SUM((TO_NUMBER(TO_CHAR(NOW(), 'MM'), '99') + (TO_NUMBER(TO_CHAR(NOW(), 'YYYY'), '9999')
|
||||
- TO_NUMBER(TO_CHAR(TO_DATE(ADATE, 'YYYY-MM-DD'), 'YYYY'), '9999'))*12)
|
||||
- TO_NUMBER(TO_CHAR(TO_DATE(ADATE, 'YYYY-MM-DD'), 'MM'), '99')) AS ADD_CAREER
|
||||
FROM
|
||||
|
|
@ -975,61 +775,45 @@
|
|||
</select>
|
||||
|
||||
<select id="selectExmemeber" parameterType="exmemberVO" resultMap="exmemberResult">
|
||||
<![CDATA[
|
||||
SELECT
|
||||
*
|
||||
FROM (
|
||||
SELECT
|
||||
(SELECT CODENM FROM TCODE WHERE CODE1 = 'C001' AND CODE2 = EXA.PLACE1) AS PLACE1STR,
|
||||
(SELECT CODENM FROM TCODE WHERE CODE1 = EXA.PLACE1 AND CODE2 = EXA.PLACE2) AS PLACE2STR,
|
||||
(SELECT CODENM FROM TCODE WHERE CODE1 = 'C009' AND CODE2 = EXA.PLACE3) AS PLACE3STR,
|
||||
(SELECT CODENM FROM TCODE WHERE CODE1 = 'C002' AND CODE2 = EXA.POSITION) AS POSITIONSTR,
|
||||
(SELECT CODENM FROM TCODE WHERE CODE1 = 'C003' AND CODE2 = EXA.JOBTYPE) AS JOBTYPESTR,
|
||||
(SELECT CODENM FROM TCODE WHERE CODE1 = 'C004' AND CODE2 = EXA.DUTIES) AS DUTIESSTR,
|
||||
(SELECT CODENM FROM TCODE WHERE CODE1 = 'C005' AND CODE2 = EXA.SCHOLARSHIP) AS SCHOLARSHIPSTR,
|
||||
(SELECT CODENM FROM TCODE WHERE CODE1 = 'C001' AND CODE2 = EXA.NOWPLACE) AS NOWPLACESTR,
|
||||
(SELECT CODENM FROM TCODE WHERE CODE1 = 'C002' AND CODE2 = EXA.NOWPOSITION) AS NOWPOSITIONSTR,
|
||||
p1.codenm AS PLACE1STR,
|
||||
p2.codenm AS NOWPLACESTR,
|
||||
np.codenm AS PLACE2STR,
|
||||
po.codenm AS POSITIONSTR,
|
||||
npo.codenm AS NOWPOSITIONSTR,
|
||||
jt.codenm AS JOBTYPESTR,
|
||||
dt.codenm AS DUTIESSTR,
|
||||
ss.codenm AS SCHOLARSHIPSTR,
|
||||
p3.codenm AS PLACE3STR,
|
||||
EXA.*
|
||||
FROM
|
||||
TEXAGENT EXA
|
||||
WHERE
|
||||
EXA.USERID = #{userid}
|
||||
ORDER BY CDATE DESC
|
||||
) WHERE ROWNUM = 1
|
||||
]]>
|
||||
FROM texagent exa
|
||||
left outer join tcode p1 on p1.code1 = 'C001' and p1.code2 = exa.place1
|
||||
left outer join tcode p2 on p2.code1 = 'C001'and p2.code2 = exa.nowplace
|
||||
left outer join tcode np on np.code1 = exa .place1 and np.code2 = exa.place2
|
||||
left outer join tcode po on po.code1 = 'C002' and po.code2 = exa.position
|
||||
left outer join tcode npo on npo.code1 = 'C002' and npo.code2 = exa.nowposition
|
||||
left outer join tcode jt on jt.code1 = 'C003' and jt.code2 = exa.jobtype
|
||||
left outer join tcode dt on dt.code1 = 'C004' and dt.code2 = exa.duties
|
||||
left outer join tcode ss on ss.code1 = 'C005' and ss.code2 = exa.scholarship
|
||||
left outer join tcode p3 on p3.code1 = 'C009' and p3.code2 = exa.place3
|
||||
WHERE exa.userid = #{userid}
|
||||
limit 1
|
||||
</select>
|
||||
|
||||
<select id="Member.exmemberList" parameterType="memberSearchVO" resultType="memberVO">
|
||||
<![CDATA[
|
||||
SELECT
|
||||
*
|
||||
FROM (
|
||||
SELECT
|
||||
ROWNUM RNUM, MEMBER_LIST.*
|
||||
FROM (
|
||||
SELECT
|
||||
(ROW_NUMBER() OVER()) RNUM,
|
||||
MEMBER_LIST.*
|
||||
FROM
|
||||
(SELECT
|
||||
FROM (SELECT MEMBER_LIST.*
|
||||
FROM (SELECT
|
||||
(SELECT CODENM FROM TCODE WHERE CODE1 = 'C001' AND CODE2 = EA.PLACE1) AS PLACE1STR,
|
||||
(SELECT CODENM FROM TCODE WHERE CODE1 = 'C002' AND CODE2 = EA.POSITION) AS POSITIONSTR,
|
||||
(SELECT CODENM FROM TCODE WHERE CODE1 = EA.PLACE1 AND CODE2 = EA.PLACE2) AS PLACE2STR,
|
||||
(SELECT CODENM FROM TCODE WHERE CODE1 = 'C001' AND CODE2 = EA.NOWPLACE) AS NOWPLACESTR,
|
||||
(SELECT CODENM FROM TCODE WHERE CODE1 = 'C002' AND CODE2 = EA.NOWPOSITION) AS NOWPOSITIONSTR,
|
||||
EA.*
|
||||
FROM
|
||||
TEXAGENT EA
|
||||
ORDER BY ]]>
|
||||
<if test="orderkey != null and orderkey != ''">
|
||||
${orderkey} <choose><when test="ordertype == 1">DESC</when><otherwise>ASC</otherwise></choose>,
|
||||
</if>
|
||||
PLACE1,
|
||||
POSITION,
|
||||
USERID
|
||||
<![CDATA[) MEMBER_LIST
|
||||
WHERE
|
||||
1 = 1
|
||||
]]>
|
||||
FROM TEXAGENT EA
|
||||
<where>
|
||||
<if test="place1 != null and place1 != ''">
|
||||
AND PLACE1 = #{place1}
|
||||
</if>
|
||||
|
|
@ -1039,14 +823,15 @@
|
|||
<if test="name != null and name != ''">
|
||||
AND NAME LIKE '%' || #{name} || '%'
|
||||
</if>
|
||||
<![CDATA[
|
||||
</where>
|
||||
ORDER by
|
||||
<if test="orderkey != null and orderkey != ''">
|
||||
${orderkey} <choose><when test="ordertype == 1">DESC</when><otherwise>ASC</otherwise></choose>,
|
||||
</if>
|
||||
PLACE1, POSITION, USERID
|
||||
limit #{recordCountPerPage} offset #{firstIndex}
|
||||
) MEMBER_LIST
|
||||
) MEMBER_LIST
|
||||
) WHERE
|
||||
RNUM > #{firstIndex} AND
|
||||
RNUM <= #{firstIndex} + #{recordCountPerPage}
|
||||
ORDER BY
|
||||
RNUM
|
||||
]]>
|
||||
</select>
|
||||
|
||||
<select id="Member.selectExmemberTotalCnt" parameterType="memberSearchVO" resultType="int">
|
||||
|
|
@ -1088,7 +873,7 @@
|
|||
VALUES (
|
||||
#{userid}, #{place1}, #{excareer_y}, #{excareer_m},
|
||||
#{excareer1_y}, #{excareer1_m}, #{excareer2_y}, #{excareer2_m}, #{excareer3_y}, #{excareer3_m},
|
||||
SYSDATE, SYSDATE
|
||||
NOW(), to_char(now(), 'YY/MM/DD')
|
||||
)
|
||||
]]>
|
||||
</insert>
|
||||
|
|
@ -1106,7 +891,7 @@
|
|||
CAREER2_M = #{excareer2_m},
|
||||
CAREER3_Y = #{excareer3_y},
|
||||
CAREER3_M = #{excareer3_m},
|
||||
ADATE = SYSDATE
|
||||
ADATE = NOW()
|
||||
WHERE
|
||||
USERID = #{userid}
|
||||
]]>
|
||||
|
|
@ -1163,7 +948,7 @@
|
|||
<![CDATA[
|
||||
#{name}, #{chnname}, #{family}, #{address}, #{email}, #{hphone}, #{ophone}, #{cphone},
|
||||
#{sdate}, #{pdate}, #{adate}, #{place1}, #{place2}, #{place3}, #{position}, #{duties}, #{jobtype}, 'g',
|
||||
#{scholarship}, #{excareer}, #{excareer1}, #{excareer2}, #{excareer3}, #{inout}, #{comment_}, #{userimg,jdbcType=VARCHAR}, SYSDATE
|
||||
#{scholarship}, #{excareer}, #{excareer1}, #{excareer2}, #{excareer3}, #{inout}, #{comment_}, #{userimg,jdbcType=VARCHAR}, NOW()
|
||||
)
|
||||
]]>
|
||||
</insert>
|
||||
|
|
@ -1195,8 +980,25 @@
|
|||
<![CDATA[
|
||||
#{name}, #{chnname}, #{family}, #{address}, #{email}, #{hphone}, #{ophone}, #{cphone},
|
||||
#{sdate}, #{pdate}, #{adate}, #{place1}, #{place2}, #{place3}, #{position}, #{duties}, #{jobtype}, 'g',
|
||||
#{scholarship}, #{excareer}, #{excareer1}, #{excareer2}, #{excareer3}, #{usegrade}, #{inout}, #{comment_}, #{userimg,jdbcType=VARCHAR}, SYSDATE
|
||||
#{scholarship}, #{excareer}, #{excareer1}, #{excareer2}, #{excareer3}, #{usegrade}, #{inout}, #{comment_}, #{userimg,jdbcType=VARCHAR}, NOW()
|
||||
)
|
||||
]]>
|
||||
</insert>
|
||||
|
||||
|
||||
<delete id="Member.deleteFaMemberList" parameterType="hashmap">
|
||||
delete from TAGENT
|
||||
where userid in
|
||||
<foreach collection="deleteUserList" item="item" index="index" separator="," open="(" close=")">
|
||||
#{item.userid}
|
||||
</foreach>
|
||||
</delete>
|
||||
|
||||
<delete id="Member.deleteCmmnMemberList" parameterType="hashmap">
|
||||
delete from TUSER
|
||||
where userid in
|
||||
<foreach collection="deleteUserList" item="item" index="index" separator="," open="(" close=")">
|
||||
#{item.userid}
|
||||
</foreach>
|
||||
</delete>
|
||||
</mapper>
|
||||
|
|
|
|||
|
|
@ -588,9 +588,9 @@
|
|||
PLACE1 = #{place1}, PLACE2 = #{place2}, PLACE3 = #{place3},
|
||||
POSITION = #{position}, DUTIES = #{duties}, JOBTYPE = #{jobtype}, INOUT = #{inout}, SCHOLARSHIP = #{scholarship},
|
||||
EXCAREER = #{excareer}, EXCAREER1 = #{excareer1}, EXCAREER2 = #{excareer2}, EXCAREER3 = #{excareer3},
|
||||
COMMENT_ = #{comment_}, LOGINDATE = TO_CHAR(SYSDATE, 'YYYY-MM-DD'),
|
||||
COMMENT_ = #{comment_}, LOGINDATE = TO_CHAR(NOW(), 'YYYY-MM-DD'),
|
||||
CHARGE = #{charge}, EXPLACE = #{explace}, USEGRADE = #{usegrade}, USERIMG = #{userimg,jdbcType=VARCHAR}, USERSIGN = #{usersign,jdbcType=VARCHAR},
|
||||
CHKCNT = NVL(#{chkcnt}, 0)
|
||||
CHKCNT = COALESCE(#{chkcnt}, 0)
|
||||
WHERE
|
||||
USERID = #{userid}
|
||||
]]>
|
||||
|
|
@ -616,7 +616,7 @@
|
|||
</otherwise>
|
||||
</choose>
|
||||
<![CDATA[
|
||||
#{place1}, #{place2}, #{position}, TO_CHAR(SYSDATE, 'YYYYMMDD'), TO_CHAR(SYSDATE, 'YYYYMMDD'), #{writer} )
|
||||
#{place1}, #{place2}, #{position}, TO_CHAR(NOW(), 'YYYYMMDD'), TO_CHAR(NOW(), 'YYYYMMDD'), #{writer} )
|
||||
]]>
|
||||
</insert>
|
||||
|
||||
|
|
@ -634,7 +634,7 @@
|
|||
PLACE1 = #{place1},
|
||||
PLACE2 = #{place2},
|
||||
POSITION = #{position},
|
||||
CHKCNT = NVL(#{chkcnt}, 0)
|
||||
CHKCNT = COALESCE(#{chkcnt}, 0)
|
||||
WHERE
|
||||
USERID = #{userid}
|
||||
]]>
|
||||
|
|
@ -674,7 +674,7 @@
|
|||
</otherwise>
|
||||
</choose> <![CDATA[
|
||||
SET
|
||||
LOGINDATE = TO_CHAR(SYSDATE, 'YYYY-MM-DD'),
|
||||
LOGINDATE = TO_CHAR(NOW(), 'YYYY-MM-DD'),
|
||||
PASSWD = XX1.ENC_VARCHAR2_INS(#{passwd}, 10, 'SHA256')
|
||||
WHERE
|
||||
USERID = #{userid}]]>
|
||||
|
|
@ -690,26 +690,26 @@
|
|||
FROM (
|
||||
SELECT
|
||||
A.PLACE1 AS PLACE,
|
||||
NVL(A.TOT_CNT, 0) AS TOT_CNT,
|
||||
NVL(B.CURRENT_CNT,0) AS CURRENT_CNT,
|
||||
NVL(A.POSITION204,0) AS POSITION204, NVL(B.CNT_204,0) AS CNT_204,
|
||||
NVL(A.POSITION203,0) AS POSITION203, NVL(B.CNT_203,0) AS CNT_203,
|
||||
NVL(A.POSITION202,0) AS POSITION202, NVL(B.CNT_202,0) AS CNT_202,
|
||||
NVL(A.POSITION201,0) AS POSITION201, NVL(B.CNT_201,0) AS CNT_201,
|
||||
NVL(A.POSITION104,0) AS POSITION104, NVL(B.CNT_104,0) AS CNT_104,
|
||||
NVL(A.POSITION103,0) AS POSITION103, NVL(B.CNT_103,0) AS CNT_103,
|
||||
NVL(A.POSITION102,0) AS POSITION102, NVL(B.CNT_102,0) AS CNT_102
|
||||
COALESCE(A.TOT_CNT, 0) AS TOT_CNT,
|
||||
COALESCE(B.CURRENT_CNT,0) AS CURRENT_CNT,
|
||||
COALESCE(A.POSITION204,0) AS POSITION204, COALESCE(B.CNT_204,0) AS CNT_204,
|
||||
COALESCE(A.POSITION203,0) AS POSITION203, COALESCE(B.CNT_203,0) AS CNT_203,
|
||||
COALESCE(A.POSITION202,0) AS POSITION202, COALESCE(B.CNT_202,0) AS CNT_202,
|
||||
COALESCE(A.POSITION201,0) AS POSITION201, COALESCE(B.CNT_201,0) AS CNT_201,
|
||||
COALESCE(A.POSITION104,0) AS POSITION104, COALESCE(B.CNT_104,0) AS CNT_104,
|
||||
COALESCE(A.POSITION103,0) AS POSITION103, COALESCE(B.CNT_103,0) AS CNT_103,
|
||||
COALESCE(A.POSITION102,0) AS POSITION102, COALESCE(B.CNT_102,0) AS CNT_102
|
||||
FROM (
|
||||
SELECT
|
||||
'PS0' AS PLACE1,
|
||||
SUM(NVL((POSITION204 + POSITION203 + POSITION202 + POSITION201 + POSITION104 + POSITION103 + POSITION102),0)) AS TOT_CNT,
|
||||
SUM(NVL(POSITION204,0)) AS POSITION204,
|
||||
SUM(NVL(POSITION203,0)) AS POSITION203,
|
||||
SUM(NVL(POSITION202,0)) AS POSITION202,
|
||||
SUM(NVL(POSITION201,0)) AS POSITION201,
|
||||
SUM(NVL(POSITION104,0)) AS POSITION104,
|
||||
SUM(NVL(POSITION103,0)) AS POSITION103,
|
||||
SUM(NVL(POSITION102,0)) AS POSITION102
|
||||
SUM(COALESCE((POSITION204 + POSITION203 + POSITION202 + POSITION201 + POSITION104 + POSITION103 + POSITION102),0)) AS TOT_CNT,
|
||||
SUM(COALESCE(POSITION204,0)) AS POSITION204,
|
||||
SUM(COALESCE(POSITION203,0)) AS POSITION203,
|
||||
SUM(COALESCE(POSITION202,0)) AS POSITION202,
|
||||
SUM(COALESCE(POSITION201,0)) AS POSITION201,
|
||||
SUM(COALESCE(POSITION104,0)) AS POSITION104,
|
||||
SUM(COALESCE(POSITION103,0)) AS POSITION103,
|
||||
SUM(COALESCE(POSITION102,0)) AS POSITION102
|
||||
FROM TAGENTNUM
|
||||
WHERE PLACE1 <> 'PS95'
|
||||
) A INNER JOIN (
|
||||
|
|
@ -738,15 +738,15 @@
|
|||
|
||||
SELECT
|
||||
A.PLACE1 AS PLACE,
|
||||
NVL((A.POSITION204 + A.POSITION203 + A.POSITION202 + A.POSITION201 + A.POSITION104 + A.POSITION103 + A.POSITION102), 0) AS TOT_CNT,
|
||||
NVL(B.CURRENT_CNT,0) AS CURRENT_CNT,
|
||||
NVL(A.POSITION204,0) AS POSITION204, NVL(B.CNT_204,0) AS CNT_204,
|
||||
NVL(A.POSITION203,0) AS POSITION203, NVL(B.CNT_203,0) AS CNT_203,
|
||||
NVL(A.POSITION202,0) AS POSITION202, NVL(B.CNT_202,0) AS CNT_202,
|
||||
NVL(A.POSITION201,0) AS POSITION201, NVL(B.CNT_201,0) AS CNT_201,
|
||||
NVL(A.POSITION104,0) AS POSITION104, NVL(B.CNT_104,0) AS CNT_104,
|
||||
NVL(A.POSITION103,0) AS POSITION103, NVL(B.CNT_103,0) AS CNT_103,
|
||||
NVL(A.POSITION102,0) AS POSITION102, NVL(B.CNT_102,0) AS CNT_102
|
||||
COALESCE((A.POSITION204 + A.POSITION203 + A.POSITION202 + A.POSITION201 + A.POSITION104 + A.POSITION103 + A.POSITION102), 0) AS TOT_CNT,
|
||||
COALESCE(B.CURRENT_CNT,0) AS CURRENT_CNT,
|
||||
COALESCE(A.POSITION204,0) AS POSITION204, COALESCE(B.CNT_204,0) AS CNT_204,
|
||||
COALESCE(A.POSITION203,0) AS POSITION203, COALESCE(B.CNT_203,0) AS CNT_203,
|
||||
COALESCE(A.POSITION202,0) AS POSITION202, COALESCE(B.CNT_202,0) AS CNT_202,
|
||||
COALESCE(A.POSITION201,0) AS POSITION201, COALESCE(B.CNT_201,0) AS CNT_201,
|
||||
COALESCE(A.POSITION104,0) AS POSITION104, COALESCE(B.CNT_104,0) AS CNT_104,
|
||||
COALESCE(A.POSITION103,0) AS POSITION103, COALESCE(B.CNT_103,0) AS CNT_103,
|
||||
COALESCE(A.POSITION102,0) AS POSITION102, COALESCE(B.CNT_102,0) AS CNT_102
|
||||
FROM TAGENTNUM A
|
||||
INNER JOIN (
|
||||
SELECT
|
||||
|
|
@ -777,26 +777,26 @@
|
|||
|
||||
SELECT
|
||||
A.PLACE1 AS PLACE,
|
||||
NVL(A.TOT_CNT, 0) AS TOT_CNT,
|
||||
NVL(B.CURRENT_CNT,0) AS CURRENT_CNT,
|
||||
NVL(A.POSITION204,0) AS POSITION204, NVL(B.CNT_204,0) AS CNT_204,
|
||||
NVL(A.POSITION203,0) AS POSITION203, NVL(B.CNT_203,0) AS CNT_203,
|
||||
NVL(A.POSITION202,0) AS POSITION202, NVL(B.CNT_202,0) AS CNT_202,
|
||||
NVL(A.POSITION201,0) AS POSITION201, NVL(B.CNT_201,0) AS CNT_201,
|
||||
NVL(A.POSITION104,0) AS POSITION104, NVL(B.CNT_104,0) AS CNT_104,
|
||||
NVL(A.POSITION103,0) AS POSITION103, NVL(B.CNT_103,0) AS CNT_103,
|
||||
NVL(A.POSITION102,0) AS POSITION102, NVL(B.CNT_102,0) AS CNT_102
|
||||
COALESCE(A.TOT_CNT, 0) AS TOT_CNT,
|
||||
COALESCE(B.CURRENT_CNT,0) AS CURRENT_CNT,
|
||||
COALESCE(A.POSITION204,0) AS POSITION204, COALESCE(B.CNT_204,0) AS CNT_204,
|
||||
COALESCE(A.POSITION203,0) AS POSITION203, COALESCE(B.CNT_203,0) AS CNT_203,
|
||||
COALESCE(A.POSITION202,0) AS POSITION202, COALESCE(B.CNT_202,0) AS CNT_202,
|
||||
COALESCE(A.POSITION201,0) AS POSITION201, COALESCE(B.CNT_201,0) AS CNT_201,
|
||||
COALESCE(A.POSITION104,0) AS POSITION104, COALESCE(B.CNT_104,0) AS CNT_104,
|
||||
COALESCE(A.POSITION103,0) AS POSITION103, COALESCE(B.CNT_103,0) AS CNT_103,
|
||||
COALESCE(A.POSITION102,0) AS POSITION102, COALESCE(B.CNT_102,0) AS CNT_102
|
||||
FROM (
|
||||
SELECT
|
||||
'PS001' AS PLACE1,
|
||||
SUM(NVL((POSITION204 + POSITION203 + POSITION202 + POSITION201 + POSITION104 + POSITION103 + POSITION102),0)) AS TOT_CNT,
|
||||
SUM(NVL(POSITION204,0)) AS POSITION204,
|
||||
SUM(NVL(POSITION203,0)) AS POSITION203,
|
||||
SUM(NVL(POSITION202,0)) AS POSITION202,
|
||||
SUM(NVL(POSITION201,0)) AS POSITION201,
|
||||
SUM(NVL(POSITION104,0)) AS POSITION104,
|
||||
SUM(NVL(POSITION103,0)) AS POSITION103,
|
||||
SUM(NVL(POSITION102,0)) AS POSITION102
|
||||
SUM(COALESCE((POSITION204 + POSITION203 + POSITION202 + POSITION201 + POSITION104 + POSITION103 + POSITION102),0)) AS TOT_CNT,
|
||||
SUM(COALESCE(POSITION204,0)) AS POSITION204,
|
||||
SUM(COALESCE(POSITION203,0)) AS POSITION203,
|
||||
SUM(COALESCE(POSITION202,0)) AS POSITION202,
|
||||
SUM(COALESCE(POSITION201,0)) AS POSITION201,
|
||||
SUM(COALESCE(POSITION104,0)) AS POSITION104,
|
||||
SUM(COALESCE(POSITION103,0)) AS POSITION103,
|
||||
SUM(COALESCE(POSITION102,0)) AS POSITION102
|
||||
FROM
|
||||
TAGENTNUM
|
||||
WHERE
|
||||
|
|
@ -830,15 +830,15 @@
|
|||
|
||||
SELECT
|
||||
A.PLACE1 AS PLACE,
|
||||
NVL((A.POSITION204 + A.POSITION203 + A.POSITION202 + A.POSITION201 + A.POSITION104 + A.POSITION103 + A.POSITION102), 0) AS TOT_CNT,
|
||||
NVL(B.CURRENT_CNT,0) AS CURRENT_CNT,
|
||||
NVL(A.POSITION204,0) AS POSITION204, NVL(B.CNT_204,0) AS CNT_204,
|
||||
NVL(A.POSITION203,0) AS POSITION203, NVL(B.CNT_203,0) AS CNT_203,
|
||||
NVL(A.POSITION202,0) AS POSITION202, NVL(B.CNT_202,0) AS CNT_202,
|
||||
NVL(A.POSITION201,0) AS POSITION201, NVL(B.CNT_201,0) AS CNT_201,
|
||||
NVL(A.POSITION104,0) AS POSITION104, NVL(B.CNT_104,0) AS CNT_104,
|
||||
NVL(A.POSITION103,0) AS POSITION103, NVL(B.CNT_103,0) AS CNT_103,
|
||||
NVL(A.POSITION102,0) AS POSITION102, NVL(B.CNT_102,0) AS CNT_102
|
||||
COALESCE((A.POSITION204 + A.POSITION203 + A.POSITION202 + A.POSITION201 + A.POSITION104 + A.POSITION103 + A.POSITION102), 0) AS TOT_CNT,
|
||||
COALESCE(B.CURRENT_CNT,0) AS CURRENT_CNT,
|
||||
COALESCE(A.POSITION204,0) AS POSITION204, COALESCE(B.CNT_204,0) AS CNT_204,
|
||||
COALESCE(A.POSITION203,0) AS POSITION203, COALESCE(B.CNT_203,0) AS CNT_203,
|
||||
COALESCE(A.POSITION202,0) AS POSITION202, COALESCE(B.CNT_202,0) AS CNT_202,
|
||||
COALESCE(A.POSITION201,0) AS POSITION201, COALESCE(B.CNT_201,0) AS CNT_201,
|
||||
COALESCE(A.POSITION104,0) AS POSITION104, COALESCE(B.CNT_104,0) AS CNT_104,
|
||||
COALESCE(A.POSITION103,0) AS POSITION103, COALESCE(B.CNT_103,0) AS CNT_103,
|
||||
COALESCE(A.POSITION102,0) AS POSITION102, COALESCE(B.CNT_102,0) AS CNT_102
|
||||
FROM
|
||||
TAGENTNUM A LEFT OUTER JOIN (
|
||||
SELECT
|
||||
|
|
@ -887,15 +887,15 @@
|
|||
SELECT 'PS' AS PLACE1
|
||||
,SUM(CAREER_Y+CAREER1_Y+CAREER2_Y+CAREER3_Y) AS TOT_CNT_Y
|
||||
,SUM(CAREER_M+CAREER1_M+CAREER2_M+CAREER3_M) AS TOT_CNT_M
|
||||
,SUM(NVL(CAREER_Y, 0)) AS CAREER_Y
|
||||
,SUM(NVL(CAREER_M, 0)) AS CAREER_M
|
||||
,SUM(NVL(CAREER1_Y, 0)) AS CAREER1_Y
|
||||
,SUM(NVL(CAREER1_M, 0)) AS CAREER1_M
|
||||
,SUM(NVL(CAREER2_Y, 0)) AS CAREER2_Y
|
||||
,SUM(NVL(CAREER2_M, 0)) AS CAREER2_M
|
||||
,SUM(NVL(CAREER3_Y, 0)) AS CAREER3_Y
|
||||
,SUM(NVL(CAREER3_M, 0)) AS CAREER3_M
|
||||
,SUM((TO_NUMBER(TO_CHAR(SYSDATE, 'MM'), '99') + (TO_NUMBER(TO_CHAR(SYSDATE, 'YYYY'), '9999')
|
||||
,SUM(COALESCE(CAREER_Y, 0)) AS CAREER_Y
|
||||
,SUM(COALESCE(CAREER_M, 0)) AS CAREER_M
|
||||
,SUM(COALESCE(CAREER1_Y, 0)) AS CAREER1_Y
|
||||
,SUM(COALESCE(CAREER1_M, 0)) AS CAREER1_M
|
||||
,SUM(COALESCE(CAREER2_Y, 0)) AS CAREER2_Y
|
||||
,SUM(COALESCE(CAREER2_M, 0)) AS CAREER2_M
|
||||
,SUM(COALESCE(CAREER3_Y, 0)) AS CAREER3_Y
|
||||
,SUM(COALESCE(CAREER3_M, 0)) AS CAREER3_M
|
||||
,SUM((TO_NUMBER(TO_CHAR(NOW(), 'MM'), '99') + (TO_NUMBER(TO_CHAR(NOW(), 'YYYY'), '9999')
|
||||
- TO_NUMBER(TO_CHAR(TO_DATE(ADATE, 'YYYY-MM-DD'), 'YYYY'), '9999'))*12)
|
||||
- TO_NUMBER(TO_CHAR(TO_DATE(ADATE, 'YYYY-MM-DD'), 'MM'), '99')) AS ADD_CAREER
|
||||
FROM H3_CAREER_STAT
|
||||
|
|
@ -903,15 +903,15 @@
|
|||
SELECT 'PS00' AS PLACE1
|
||||
,SUM(CAREER_Y+CAREER1_Y+CAREER2_Y+CAREER3_Y) AS TOT_CNT_Y
|
||||
,SUM(CAREER_M+CAREER1_M+CAREER2_M+CAREER3_M) AS TOT_CNT_M
|
||||
,SUM(NVL(CAREER_Y, 0)) AS CAREER_Y
|
||||
,SUM(NVL(CAREER_M, 0)) AS CAREER_M
|
||||
,SUM(NVL(CAREER1_Y, 0)) AS CAREER1_Y
|
||||
,SUM(NVL(CAREER1_M, 0)) AS CAREER1_M
|
||||
,SUM(NVL(CAREER2_Y, 0)) AS CAREER2_Y
|
||||
,SUM(NVL(CAREER2_M, 0)) AS CAREER2_M
|
||||
,SUM(NVL(CAREER3_Y, 0)) AS CAREER3_Y
|
||||
,SUM(NVL(CAREER3_M, 0)) AS CAREER3_M
|
||||
,SUM((TO_NUMBER(TO_CHAR(SYSDATE, 'MM'), '99') + (TO_NUMBER(TO_CHAR(SYSDATE, 'YYYY'), '9999')
|
||||
,SUM(COALESCE(CAREER_Y, 0)) AS CAREER_Y
|
||||
,SUM(COALESCE(CAREER_M, 0)) AS CAREER_M
|
||||
,SUM(COALESCE(CAREER1_Y, 0)) AS CAREER1_Y
|
||||
,SUM(COALESCE(CAREER1_M, 0)) AS CAREER1_M
|
||||
,SUM(COALESCE(CAREER2_Y, 0)) AS CAREER2_Y
|
||||
,SUM(COALESCE(CAREER2_M, 0)) AS CAREER2_M
|
||||
,SUM(COALESCE(CAREER3_Y, 0)) AS CAREER3_Y
|
||||
,SUM(COALESCE(CAREER3_M, 0)) AS CAREER3_M
|
||||
,SUM((TO_NUMBER(TO_CHAR(NOW(), 'MM'), '99') + (TO_NUMBER(TO_CHAR(NOW(), 'YYYY'), '9999')
|
||||
- TO_NUMBER(TO_CHAR(TO_DATE(ADATE, 'YYYY-MM-DD'), 'YYYY'), '9999'))*12)
|
||||
- TO_NUMBER(TO_CHAR(TO_DATE(ADATE, 'YYYY-MM-DD'), 'MM'), '99')) AS ADD_CAREER
|
||||
FROM
|
||||
|
|
@ -925,15 +925,15 @@
|
|||
'PS001' AS PLACE1
|
||||
,SUM(CAREER_Y+CAREER1_Y+CAREER2_Y+CAREER3_Y) AS TOT_CNT_Y
|
||||
,SUM(CAREER_M+CAREER1_M+CAREER2_M+CAREER3_M) AS TOT_CNT_M
|
||||
,SUM(NVL(CAREER_Y, 0)) AS CAREER_Y
|
||||
,SUM(NVL(CAREER_M, 0)) AS CAREER_M
|
||||
,SUM(NVL(CAREER1_Y, 0)) AS CAREER1_Y
|
||||
,SUM(NVL(CAREER1_M, 0)) AS CAREER1_M
|
||||
,SUM(NVL(CAREER2_Y, 0)) AS CAREER2_Y
|
||||
,SUM(NVL(CAREER2_M, 0)) AS CAREER2_M
|
||||
,SUM(NVL(CAREER3_Y, 0)) AS CAREER3_Y
|
||||
,SUM(NVL(CAREER3_M, 0)) AS CAREER3_M
|
||||
,SUM((TO_NUMBER(TO_CHAR(SYSDATE, 'MM'), '99') + (TO_NUMBER(TO_CHAR(SYSDATE, 'YYYY'), '9999')
|
||||
,SUM(COALESCE(CAREER_Y, 0)) AS CAREER_Y
|
||||
,SUM(COALESCE(CAREER_M, 0)) AS CAREER_M
|
||||
,SUM(COALESCE(CAREER1_Y, 0)) AS CAREER1_Y
|
||||
,SUM(COALESCE(CAREER1_M, 0)) AS CAREER1_M
|
||||
,SUM(COALESCE(CAREER2_Y, 0)) AS CAREER2_Y
|
||||
,SUM(COALESCE(CAREER2_M, 0)) AS CAREER2_M
|
||||
,SUM(COALESCE(CAREER3_Y, 0)) AS CAREER3_Y
|
||||
,SUM(COALESCE(CAREER3_M, 0)) AS CAREER3_M
|
||||
,SUM((TO_NUMBER(TO_CHAR(NOW(), 'MM'), '99') + (TO_NUMBER(TO_CHAR(NOW(), 'YYYY'), '9999')
|
||||
- TO_NUMBER(TO_CHAR(TO_DATE(ADATE, 'YYYY-MM-DD'), 'YYYY'), '9999'))*12)
|
||||
- TO_NUMBER(TO_CHAR(TO_DATE(ADATE, 'YYYY-MM-DD'), 'MM'), '99')) AS ADD_CAREER
|
||||
FROM
|
||||
|
|
@ -946,15 +946,15 @@
|
|||
PLACE1
|
||||
,SUM(CAREER_Y+CAREER1_Y+CAREER2_Y+CAREER3_Y) AS TOT_CNT_Y
|
||||
,SUM(CAREER_M+CAREER1_M+CAREER2_M+CAREER3_M) AS TOT_CNT_M
|
||||
,SUM(NVL(CAREER_Y, 0)) AS CAREER_Y
|
||||
,SUM(NVL(CAREER_M, 0)) AS CAREER_M
|
||||
,SUM(NVL(CAREER1_Y, 0)) AS CAREER1_Y
|
||||
,SUM(NVL(CAREER1_M, 0)) AS CAREER1_M
|
||||
,SUM(NVL(CAREER2_Y, 0)) AS CAREER2_Y
|
||||
,SUM(NVL(CAREER2_M, 0)) AS CAREER2_M
|
||||
,SUM(NVL(CAREER3_Y, 0)) AS CAREER3_Y
|
||||
,SUM(NVL(CAREER3_M, 0)) AS CAREER3_M
|
||||
,SUM((TO_NUMBER(TO_CHAR(SYSDATE, 'MM'), '99') + (TO_NUMBER(TO_CHAR(SYSDATE, 'YYYY'), '9999')
|
||||
,SUM(COALESCE(CAREER_Y, 0)) AS CAREER_Y
|
||||
,SUM(COALESCE(CAREER_M, 0)) AS CAREER_M
|
||||
,SUM(COALESCE(CAREER1_Y, 0)) AS CAREER1_Y
|
||||
,SUM(COALESCE(CAREER1_M, 0)) AS CAREER1_M
|
||||
,SUM(COALESCE(CAREER2_Y, 0)) AS CAREER2_Y
|
||||
,SUM(COALESCE(CAREER2_M, 0)) AS CAREER2_M
|
||||
,SUM(COALESCE(CAREER3_Y, 0)) AS CAREER3_Y
|
||||
,SUM(COALESCE(CAREER3_M, 0)) AS CAREER3_M
|
||||
,SUM((TO_NUMBER(TO_CHAR(NOW(), 'MM'), '99') + (TO_NUMBER(TO_CHAR(NOW(), 'YYYY'), '9999')
|
||||
- TO_NUMBER(TO_CHAR(TO_DATE(ADATE, 'YYYY-MM-DD'), 'YYYY'), '9999'))*12)
|
||||
- TO_NUMBER(TO_CHAR(TO_DATE(ADATE, 'YYYY-MM-DD'), 'MM'), '99')) AS ADD_CAREER
|
||||
FROM
|
||||
|
|
@ -1086,7 +1086,7 @@
|
|||
VALUES (
|
||||
#{userid}, #{place1}, #{excareer_y}, #{excareer_m},
|
||||
#{excareer1_y}, #{excareer1_m}, #{excareer2_y}, #{excareer2_m}, #{excareer3_y}, #{excareer3_m},
|
||||
SYSDATE, SYSDATE
|
||||
NOW(), NOW()
|
||||
)
|
||||
]]>
|
||||
</insert>
|
||||
|
|
@ -1104,7 +1104,7 @@
|
|||
CAREER2_M = #{excareer2_m},
|
||||
CAREER3_Y = #{excareer3_y},
|
||||
CAREER3_M = #{excareer3_m},
|
||||
ADATE = SYSDATE
|
||||
ADATE = NOW()
|
||||
WHERE
|
||||
USERID = #{userid}
|
||||
]]>
|
||||
|
|
@ -1161,7 +1161,7 @@
|
|||
<![CDATA[
|
||||
#{name}, #{chnname}, #{family}, #{address}, #{email}, #{hphone}, #{ophone}, #{cphone},
|
||||
#{sdate}, #{pdate}, #{adate}, #{place1}, #{place2}, #{place3}, #{position}, #{duties}, #{jobtype}, 'g',
|
||||
#{scholarship}, #{excareer}, #{excareer1}, #{excareer2}, #{excareer3}, #{inout}, #{comment_}, #{userimg,jdbcType=VARCHAR}, SYSDATE
|
||||
#{scholarship}, #{excareer}, #{excareer1}, #{excareer2}, #{excareer3}, #{inout}, #{comment_}, #{userimg,jdbcType=VARCHAR}, NOW()
|
||||
)
|
||||
]]>
|
||||
</insert>
|
||||
|
|
@ -1193,7 +1193,7 @@
|
|||
<![CDATA[
|
||||
#{name}, #{chnname}, #{family}, #{address}, #{email}, #{hphone}, #{ophone}, #{cphone},
|
||||
#{sdate}, #{pdate}, #{adate}, #{place1}, #{place2}, #{place3}, #{position}, #{duties}, #{jobtype}, 'g',
|
||||
#{scholarship}, #{excareer}, #{excareer1}, #{excareer2}, #{excareer3}, #{usegrade}, #{inout}, #{comment_}, #{userimg,jdbcType=VARCHAR}, SYSDATE
|
||||
#{scholarship}, #{excareer}, #{excareer1}, #{excareer2}, #{excareer3}, #{usegrade}, #{inout}, #{comment_}, #{userimg,jdbcType=VARCHAR}, NOW()
|
||||
)
|
||||
]]>
|
||||
</insert>
|
||||
|
|
|
|||
|
|
@ -37,82 +37,27 @@
|
|||
</select>
|
||||
|
||||
<select id="MemberAuth.getMemberListByPlace1" parameterType="memberSearchVO" resultType="loginUserVO">
|
||||
<![CDATA[
|
||||
SELECT
|
||||
*
|
||||
FROM (
|
||||
SELECT
|
||||
ROWNUM RNUM, MEMBER_LIST.*
|
||||
FROM (
|
||||
SELECT
|
||||
B.CODENM AS PLACE3STR, A.*
|
||||
FROM
|
||||
(
|
||||
SELECT
|
||||
B.CODENM AS PLACE2STR, A.*
|
||||
FROM
|
||||
(SELECT
|
||||
B.CODENM AS POSITIONSTR, A.*
|
||||
FROM
|
||||
(SELECT
|
||||
B.CODENM AS PLACE1STR, A.*
|
||||
FROM
|
||||
(SELECT
|
||||
B.CODENM AS DUTIESSTR, A.*
|
||||
FROM
|
||||
(SELECT
|
||||
AGENT.USERID, AGENT.NAME, AGENT.PLACE1, AGENT.PLACE2, AGENT.PLACE3, AGENT.DUTIES, AGENT.POSITION, AGENT.USEGRADE,
|
||||
PT_AUTH.AU_CODE AS AUTHCODE
|
||||
FROM
|
||||
( TAGENT AGENT
|
||||
LEFT JOIN
|
||||
RPT_AGENT_AUTH PT_AUTH
|
||||
ON AGENT.USERID = PT_AUTH.AU_ID)
|
||||
LEFT JOIN
|
||||
H3_AGENT_AUTH ST_AUTH
|
||||
ON
|
||||
AGENT.USERID = ST_AUTH.AU_USERID
|
||||
WHERE
|
||||
PLACE1 = #{place1}
|
||||
) A,
|
||||
TCODE B
|
||||
WHERE
|
||||
B.CODE1 = 'C004' AND
|
||||
A.DUTIES = B.CODE2) A,
|
||||
TCODE B
|
||||
WHERE
|
||||
A.PLACE1 = B.CODE2 AND
|
||||
B.CODE1 = 'C001' ) A,
|
||||
TCODE B
|
||||
WHERE
|
||||
A.POSITION = B.CODE2 AND
|
||||
B.CODE1 = 'C002') A,
|
||||
TCODE B
|
||||
WHERE
|
||||
A.PLACE1 = B.CODE1(+) AND
|
||||
B.CODE2(+) = A.PLACE2
|
||||
select (ROW_NUMBER() OVER()) AS RNUM,
|
||||
aa.*
|
||||
from (select pl1.codenm place1str,
|
||||
pl2.codenm PLACE2STR,
|
||||
pl3.codenm PLACE3STR,
|
||||
pst.codenm POSITIONSTR,
|
||||
jt.codenm JOBTYPESTR,
|
||||
a.*
|
||||
from tagent a
|
||||
inner join tcode pl1 on pl1.code1 = 'C001' and a.place1 = pl1.code2
|
||||
inner join tcode pl2 on a.place1 = pl2.code1 and a.place2 = pl2.code2
|
||||
inner join tcode pl3 on pl3.code1 = 'C009' and a.place3 = pl3.code2
|
||||
inner join tcode pst on pst.code1 = 'C002' and a.position = pst.code2
|
||||
inner join tcode jt on jt.code1 = 'C003' and a.jobtype = jt.code2
|
||||
where PLACE1 =#{place1}
|
||||
ORDER BY
|
||||
PLACE1,
|
||||
PLACE2, PLACE3, POSITION DESC, DUTIES, NAME
|
||||
) A,
|
||||
TCODE B
|
||||
WHERE
|
||||
A.PLACE3 = B.CODE2(+) AND
|
||||
CODE1(+) = 'C009'
|
||||
ORDER BY]]>
|
||||
<if test="orderkey != null and orderkey != ''">
|
||||
${orderkey} <choose><when test="ordertype == 1">DESC</when><otherwise>ASC</otherwise></choose>,
|
||||
</if>
|
||||
POSITION DESC,
|
||||
PLACE2, PLACE3, DUTIES, NAME
|
||||
<![CDATA[) MEMBER_LIST
|
||||
)
|
||||
WHERE
|
||||
RNUM > #{firstIndex} AND
|
||||
RNUM <= #{firstIndex} + #{recordCountPerAuthPage}
|
||||
ORDER BY
|
||||
RNUM
|
||||
]]>
|
||||
POSITION DESC, PLACE2, PLACE3, DUTIES, NAME
|
||||
limit #{recordCountPerAuthPage} offset #{firstIndex} ) aa
|
||||
</select>
|
||||
<select id="MemberAuth.getMemberListByPlace1Cnt" parameterType="String" resultType="int">
|
||||
<![CDATA[
|
||||
|
|
|
|||
File diff suppressed because it is too large
Load Diff
|
|
@ -19,11 +19,9 @@
|
|||
</select>
|
||||
|
||||
<insert id="ReportFile.insertFileSeq">
|
||||
<![CDATA[
|
||||
INSERT INTO RPT_FILE_STORAGE (FS_FILE_COUNT) VALUES (1)
|
||||
]]>
|
||||
<selectKey resultType="int" keyProperty="fsSeq" order="AFTER">
|
||||
SELECT RPT_FILE_STORAGE_FS_SEQ_SEQ.CURRVAL FROM DUAL
|
||||
SELECT currval('rpt_file_seq') as fsSeq
|
||||
</selectKey>
|
||||
</insert>
|
||||
|
||||
|
|
@ -32,9 +30,9 @@
|
|||
UPDATE
|
||||
RPT_FILE_STORAGE
|
||||
SET
|
||||
FS_FILE_COUNT = FS_FILE_COUNT + #{cnt}
|
||||
FS_FILE_COUNT = FS_FILE_COUNT + #{cnt}::int
|
||||
WHERE
|
||||
FS_SEQ = #{fsseq}
|
||||
FS_SEQ = #{fsseq}::int
|
||||
]]>
|
||||
</update>
|
||||
|
||||
|
|
|
|||
|
|
@ -19,26 +19,24 @@
|
|||
</resultMap>
|
||||
|
||||
<select id="ReportGoal.selectList" parameterType="reportSearchVO" resultMap="ReportGoalMap">
|
||||
SELECT
|
||||
T.*, ROWNUM AS RN
|
||||
FROM
|
||||
(
|
||||
SELECT
|
||||
A.NAME,
|
||||
A.USERID AS go_id,
|
||||
NVL(G.GO_GOAL1, 0) AS goGoal1,
|
||||
NVL(G.GO_GOAL2, 0) AS goGoal2,
|
||||
NVL(G.GO_GOAL3, 0) AS goGoal3,
|
||||
NVL(G.GO_GOAL4, 0) AS goGoal4,
|
||||
NVL(G.GO_TOTAL, 0) AS goTotal
|
||||
FROM
|
||||
(SELECT * FROM TAGENT WHERE PLACE1 = #{placeGroup}) A
|
||||
LEFT OUTER JOIN
|
||||
(SELECT DISTINCT * FROM RPT_AGENT_GOAL WHERE GO_MONTH = #{month} AND GO_YEAR = #{year}) G
|
||||
ON G.GO_ID = A.USERID
|
||||
ORDER BY
|
||||
POSITION DESC, PLACE2, PLACE3, DUTIES, NAME
|
||||
) T
|
||||
select (row_number () over()) AS rn,
|
||||
t.*
|
||||
from (
|
||||
select
|
||||
a.name,
|
||||
a.userid as go_id,
|
||||
coalesce(b.go_goal1, 0) AS goGoal1,
|
||||
coalesce(b.go_goal2, 0) AS goGoal2,
|
||||
coalesce(b.go_goal3, 0) AS goGoal3,
|
||||
coalesce(b.go_goal4, 0) AS goGoal4,
|
||||
coalesce(b.go_total, 0) AS goTotal
|
||||
from tagent a
|
||||
left outer join rpt_agent_goal b on a.userid = b.go_id
|
||||
and a.place1 = #{placeGroup}
|
||||
and b.go_month = ${month}
|
||||
and b.go_year = ${year}
|
||||
order by position desc, place2, place3, duties, name
|
||||
) t
|
||||
</select>
|
||||
|
||||
<select id="ReportGoal.select" parameterType="reportGoalVO" resultMap="ReportGoalMap">
|
||||
|
|
@ -73,52 +71,86 @@
|
|||
</update>
|
||||
|
||||
<select id="ReportGoal.getStats" parameterType="reportSearchVO" resultType="hashMap">
|
||||
SELECT
|
||||
ROWNUM AS RN, T.*
|
||||
FROM
|
||||
(
|
||||
SELECT
|
||||
NAME,
|
||||
NVL(GO_GOAL1, 0) AS GOAL1, NVL(GO_GOAL2, 0) AS GOAL2, NVL(GO_GOAL3, 0) AS GOAL3, NVL(GO_GOAL4, 0) AS GOAL4,
|
||||
NVL(GO_GOAL1, 0) + NVL(GO_GOAL2, 0) + NVL(GO_GOAL3, 0) + NVL(GO_GOAL4, 0) AS GOAL_TOTAL,
|
||||
(SELECT COUNT(*) FROM RPT_INFO WHERE IN_COMPLETE = 1 AND IN_USERID = A.USERID AND IN_INFO_YEAR = G.GO_YEAR AND IN_INFO_MONTH = G.GO_MONTH AND IN_CATEGORY4 = '01') AS RESULT1,
|
||||
(SELECT COUNT(*) FROM RPT_INFO WHERE IN_COMPLETE = 1 AND IN_USERID = A.USERID AND IN_INFO_YEAR = G.GO_YEAR AND IN_INFO_MONTH = G.GO_MONTH AND IN_CATEGORY4 = '02') AS RESULT2,
|
||||
(SELECT COUNT(*) FROM RPT_INFO WHERE IN_COMPLETE = 1 AND IN_USERID = A.USERID AND IN_INFO_YEAR = G.GO_YEAR AND IN_INFO_MONTH = G.GO_MONTH AND IN_CATEGORY4 IN ('03', '04', '05')) AS RESULT3,
|
||||
(SELECT COUNT(*) FROM RPT_INFO WHERE IN_COMPLETE = 1 AND IN_USERID = A.USERID AND IN_INFO_YEAR = G.GO_YEAR AND IN_INFO_MONTH = G.GO_MONTH AND IN_CATEGORY4 = '06') AS RESULT4,
|
||||
(SELECT COUNT(*) FROM RPT_INFO WHERE IN_COMPLETE = 1 AND IN_USERID = A.USERID AND IN_INFO_YEAR = G.GO_YEAR AND IN_INFO_MONTH = G.GO_MONTH) AS RESULT_TOTAL
|
||||
FROM
|
||||
(SELECT * FROM TAGENT WHERE PLACE1 = #{placeGroup}) A
|
||||
LEFT OUTER JOIN
|
||||
(SELECT DISTINCT * FROM RPT_AGENT_GOAL WHERE GO_YEAR = #{year} AND GO_MONTH = #{month}) G
|
||||
ON G.GO_ID = A.USERID
|
||||
ORDER BY
|
||||
POSITION DESC, PLACE2, PLACE3, DUTIES, NAME
|
||||
) T
|
||||
select (row_number () over()) AS rn,
|
||||
t.*
|
||||
from (
|
||||
select a.name,
|
||||
a.userid as go_id,
|
||||
coalesce(b.go_goal1, 0) AS goal1,
|
||||
coalesce(b.go_goal2, 0) AS goal2,
|
||||
coalesce(b.go_goal3, 0) AS goal3,
|
||||
coalesce(b.go_goal4, 0) AS goal4,
|
||||
coalesce(b.go_total, 0) AS goal_total,
|
||||
coalesce(c.result1, 0) as result1,
|
||||
coalesce(c.result2, 0) as result2,
|
||||
coalesce(c.result3, 0) as result3,
|
||||
coalesce(c.result4, 0) as result4,
|
||||
coalesce(c.result_total, 0) as result_total
|
||||
from tagent a
|
||||
left outer join rpt_agent_goal b
|
||||
on a.place1 = #{placeGroup} and b.go_year = ${year} and b.go_month = ${month} and a.userid = b.go_id
|
||||
left outer join (
|
||||
select in_userid,
|
||||
count(1) filter (where in_category4 = '01') as result1,
|
||||
count(1) filter (where in_category4 = '02') as result2,
|
||||
count(1) filter (where in_category4 in ('03', '04', '05')) as result3,
|
||||
count(1) filter (where in_category4 = '06') as result4,
|
||||
count(1) as result_total
|
||||
from rpt_info
|
||||
where in_complete = '1'
|
||||
and in_place_code = #{placeGroup}
|
||||
and in_info_year = ${year}
|
||||
and in_info_month = ${month}
|
||||
group by in_userid
|
||||
) c on c.in_userid = a.userid
|
||||
order by position desc, place2, place3, duties, name
|
||||
) t
|
||||
</select>
|
||||
|
||||
<select id="ReportGoal.getStatsPlace" parameterType="reportSearchVO" resultType="hashMap">
|
||||
SELECT
|
||||
ROWNUM AS RN, T.*
|
||||
FROM
|
||||
(
|
||||
SELECT
|
||||
CODE2 AS CODE, CODENM AS NAME,
|
||||
SUM(NVL(GO_GOAL1, 0)) AS GOAL1, SUM(NVL(GO_GOAL2, 0)) AS GOAL2, SUM(NVL(GO_GOAL3, 0)) AS GOAL3, SUM(NVL(GO_GOAL4, 0)) AS GOAL4,
|
||||
SUM(NVL(GO_GOAL1, 0)) + SUM(NVL(GO_GOAL2, 0)) + SUM(NVL(GO_GOAL3, 0)) + SUM(NVL(GO_GOAL4, 0)) AS GOAL_TOTAL,
|
||||
(SELECT COUNT(*) FROM RPT_INFO WHERE IN_COMPLETE = 1 AND IN_INFO_YEAR = G.GO_YEAR AND IN_INFO_MONTH = G.GO_MONTH AND IN_CATEGORY4 = '01') AS RESULT1,
|
||||
(SELECT COUNT(*) FROM RPT_INFO WHERE IN_COMPLETE = 1 AND IN_INFO_YEAR = G.GO_YEAR AND IN_INFO_MONTH = G.GO_MONTH AND IN_CATEGORY4 = '02') AS RESULT2,
|
||||
(SELECT COUNT(*) FROM RPT_INFO WHERE IN_COMPLETE = 1 AND IN_INFO_YEAR = G.GO_YEAR AND IN_INFO_MONTH = G.GO_MONTH AND IN_CATEGORY4 IN ('03', '04', '05')) AS RESULT3,
|
||||
(SELECT COUNT(*) FROM RPT_INFO WHERE IN_COMPLETE = 1 AND IN_INFO_YEAR = G.GO_YEAR AND IN_INFO_MONTH = G.GO_MONTH AND IN_CATEGORY4 = '06') AS RESULT4,
|
||||
(SELECT COUNT(*) FROM RPT_INFO WHERE IN_COMPLETE = 1 AND IN_INFO_YEAR = G.GO_YEAR AND IN_INFO_MONTH = G.GO_MONTH) AS RESULT_TOTAL
|
||||
FROM
|
||||
(SELECT * FROM TCODE WHERE CODE1 = 'C001') P
|
||||
LEFT OUTER JOIN
|
||||
(SELECT DISTINCT * FROM RPT_AGENT_GOAL WHERE GO_YEAR = #{year} AND GO_MONTH = #{month}) G
|
||||
ON G.GO_PLACE1 = P.CODE2
|
||||
GROUP BY
|
||||
CODE2, CODENM, GO_YEAR, GO_MONTH
|
||||
ORDER BY
|
||||
CODE2
|
||||
) T
|
||||
select (row_number() over()) AS rn,
|
||||
t.*
|
||||
from (
|
||||
SELECT p.code2 AS CODE,
|
||||
p.codenm AS NAME,
|
||||
coalesce(go_goal1, 0) AS GOAL1,
|
||||
coalesce(go_goal2, 0) AS GOAL2,
|
||||
coalesce(go_goal3, 0) AS GOAL3,
|
||||
coalesce(go_goal4, 0) AS GOAL4,
|
||||
coalesce(go_total, 0) AS GOAL_TOTAL,
|
||||
coalesce(ri.result1, 0) AS RESULT1,
|
||||
coalesce(ri.result2, 0) AS RESULT2,
|
||||
coalesce(ri.result3, 0) AS RESULT3,
|
||||
coalesce(ri.result4, 0) AS RESULT4,
|
||||
coalesce(ri.result_total, 0) AS RESULT_TOTAL
|
||||
from tcode p
|
||||
left outer join (
|
||||
select go_place1,
|
||||
sum(go_goal1) as go_goal1,
|
||||
sum(go_goal2) as go_goal2,
|
||||
sum(go_goal3) as go_goal3,
|
||||
sum(go_goal4) as go_goal4,
|
||||
sum(go_total) as go_total
|
||||
from RPT_AGENT_GOAL
|
||||
where go_year = ${year}
|
||||
and go_month = ${month}
|
||||
group by go_place1
|
||||
) G ON G.GO_PLACE1 = P.CODE2
|
||||
left outer join (
|
||||
select in_place_code,
|
||||
count(1) filter (where in_category4 = '01') as result1,
|
||||
count(1) filter (where in_category4 = '02') as result2,
|
||||
count(1) filter (where in_category4 in ('03', '04', '05')) as result3,
|
||||
count(1) filter (where in_category4 = '06') as result4,
|
||||
count(1) as result_total
|
||||
from rpt_info
|
||||
where in_complete = '1'
|
||||
and in_info_year = ${year}
|
||||
and in_info_month = ${month}
|
||||
group by in_place_code
|
||||
) ri on p.code2 = ri.in_place_code
|
||||
WHERE p.code1 = 'C001'
|
||||
order by p.code2
|
||||
) t
|
||||
</select>
|
||||
</mapper>
|
||||
|
|
@ -90,11 +90,11 @@
|
|||
(JU_INSEQ, JU_GROUP_CODE, JU_CHKDATE, JU_JUDGE, JU_REPORT, JU_PLACE1, JU_PLACE2,
|
||||
JU_POSITION, JU_NAME, JU_USERID, JU_PROXY_ID, JU_DUTIES_CODE, JU_MESSAGE)
|
||||
VALUES
|
||||
(#{juInseq}, #{juGroupCode}, sysdate, #{juJudge}, #{juReport}, #{juPlace1}, #{juPlace2},
|
||||
(#{juInseq}, #{juGroupCode}, NOW(), #{juJudge}, #{juReport}, #{juPlace1}, #{juPlace2},
|
||||
#{juPosition}, #{juName}, #{juUserid}, #{juProxyId}, #{juDutiesCode}, #{juMessage})
|
||||
]]>
|
||||
<selectKey resultType="int" keyProperty="juInseq" order="AFTER">
|
||||
SELECT RPT_JUDGE_HISTORY_JU_SEQ_SEQ.CURRVAL FROM DUAL
|
||||
SELECT currval('rpt_ju_seq') as juInseq
|
||||
</selectKey>
|
||||
</insert>
|
||||
|
||||
|
|
@ -119,28 +119,28 @@
|
|||
SELECT
|
||||
]]>
|
||||
<if test="categoryType.equals(1)">
|
||||
<foreach collection="category1" item="cate" separator=""><![CDATA[
|
||||
TO_CHAR(MAX(DECODE(CATEGORYCODE, #{cate}, TOTAL))) AS "${cate}",
|
||||
]]></foreach>
|
||||
<foreach collection="category1" item="cate" separator="">
|
||||
MAX(CASE CATEGORYCODE WHEN #{cate} THEN TOTAL::int end) AS "${cate}",
|
||||
</foreach>
|
||||
</if>
|
||||
<if test="categoryType.equals(2)">
|
||||
<foreach collection="category2" item="cate" ><![CDATA[
|
||||
TO_CHAR(MAX(DECODE(CATEGORYCODE, #{cate}, TOTAL))) AS "${cate}",
|
||||
]]></foreach>
|
||||
<foreach collection="category2" item="cate" >
|
||||
MAX(CASE CATEGORYCODE WHEN #{cate} THEN TOTAL::int end) AS "${cate}",
|
||||
</foreach>
|
||||
</if>
|
||||
<if test="categoryType.equals(3)">
|
||||
<foreach collection="category3" item="cate" ><![CDATA[
|
||||
TO_CHAR(MAX(DECODE(CATEGORYCODE, #{cate}, TOTAL))) AS "${cate}",
|
||||
]]></foreach>
|
||||
<foreach collection="category3" item="cate" >
|
||||
MAX(CASE CATEGORYCODE WHEN #{cate} THEN TOTAL::int end) AS "${cate}",
|
||||
</foreach>
|
||||
</if>
|
||||
<if test="categoryType.equals(4)">
|
||||
<foreach collection="category4" item="cate" ><![CDATA[
|
||||
TO_CHAR(MAX(DECODE(CATEGORYCODE, #{cate}, TOTAL))) AS "${cate}",
|
||||
]]></foreach>
|
||||
<foreach collection="category4" item="cate" >
|
||||
MAX(CASE CATEGORYCODE WHEN #{cate} THEN TOTAL::int end) AS "${cate}",
|
||||
</foreach>
|
||||
</if>
|
||||
<![CDATA[
|
||||
PLACENAME, PLACECODE,
|
||||
TO_CHAR(SUM(TOTAL)) AS TOTAL
|
||||
SUM(TOTAL) AS TOTAL
|
||||
FROM
|
||||
(
|
||||
SELECT
|
||||
|
|
@ -164,10 +164,10 @@
|
|||
</choose>
|
||||
|
||||
<if test="dateStart != null and dateStart != ''"><![CDATA[
|
||||
AND IN_INFODATE >= #{dateStart}
|
||||
AND IN_INFODATE >= #{dateStart}::date
|
||||
]]></if>
|
||||
<if test="dateEnd != null and dateEnd != ''"><![CDATA[
|
||||
AND IN_INFODATE <= #{dateEnd}
|
||||
AND IN_INFODATE <= #{dateEnd}::date
|
||||
]]></if>
|
||||
<if test="subject != null and subject != ''"><![CDATA[
|
||||
AND IN_SUBJECT LIKE '%'||#{subject}||'%'
|
||||
|
|
@ -271,14 +271,63 @@
|
|||
<![CDATA[
|
||||
/*ReportJudge.statsJudge*/
|
||||
WITH RPT AS (
|
||||
SELECT *
|
||||
SELECT
|
||||
A.IN_PLACE_CODE ,
|
||||
sum(REPORT1) REPORT1,
|
||||
sum(REPORT2) REPORT2,
|
||||
SUM(JU1) JU1,
|
||||
SUM(JU2) JU2,
|
||||
SUM(JU3) JU3,
|
||||
SUM(JU4) JU4,
|
||||
SUM(JU5) JU5,
|
||||
SUM(JU6) JU6,
|
||||
SUM(JU7) JU7,
|
||||
sum(JU1 + JU2) as AG,
|
||||
sum(JU3 + JU4) as BG,
|
||||
sum(JU5 + JU6) as CG,
|
||||
sum(JU7) as DG
|
||||
from (select
|
||||
IN_PLACE_CODE,
|
||||
SUM(case when IN_REPORT1 = 1 then 1 else 0 end) as REPORT1,
|
||||
SUM(case when IN_REPORT2 = 1 then 1 else 0 end) as REPORT2,
|
||||
case IN_JUDGE
|
||||
when 1 then COUNT(in_seq)
|
||||
else 0
|
||||
end JU1,
|
||||
case IN_JUDGE
|
||||
when 2 then COUNT(in_seq)
|
||||
else 0
|
||||
end JU2,
|
||||
case IN_JUDGE
|
||||
when 3 then COUNT(in_seq)
|
||||
else 0
|
||||
end JU3,
|
||||
case IN_JUDGE
|
||||
when 4 then COUNT(in_seq)
|
||||
else 0
|
||||
end JU4,
|
||||
case IN_JUDGE
|
||||
when 5 then COUNT(in_seq)
|
||||
else 0
|
||||
end JU5,
|
||||
case IN_JUDGE
|
||||
when 6 then COUNT(in_seq)
|
||||
else 0
|
||||
end JU6,
|
||||
case IN_JUDGE
|
||||
when 7 then COUNT(in_seq)
|
||||
else 0
|
||||
end JU7
|
||||
FROM
|
||||
RPT_INFO
|
||||
WHERE
|
||||
IN_COMPLETE = '1'
|
||||
AND IN_STATE_CODE <> '99'
|
||||
AND IN_INFODATE >= #{dateStart}
|
||||
AND IN_INFODATE <= #{dateEnd}
|
||||
AND IN_INFODATE >= #{dateStart}::date
|
||||
AND IN_INFODATE <= #{dateEnd}::date
|
||||
group by IN_PLACE_CODE, IN_JUDGE) A
|
||||
where in_place_code <>''
|
||||
group by IN_PLACE_CODE
|
||||
]]>
|
||||
<if test="policeType != null and policeType.length > 0">
|
||||
AND IN_TYPE IN
|
||||
|
|
@ -316,61 +365,119 @@
|
|||
#{category}
|
||||
</foreach>
|
||||
</if>
|
||||
<![CDATA[
|
||||
)
|
||||
SELECT
|
||||
A.PLACENAME,
|
||||
TO_CHAR(REPORT1) REPORT1, TO_CHAR(REPORT2) REPORT2,
|
||||
TO_CHAR(JU1) JU1, TO_CHAR(JU2) JU2, TO_CHAR(JU3) JU3, TO_CHAR(JU4) JU4, TO_CHAR(JU5) JU5, TO_CHAR(JU6) JU6, TO_CHAR(JU7) JU7,
|
||||
TO_CHAR((JU1 + JU2)) AS AG, TO_CHAR((JU3 + JU4)) AS BG, TO_CHAR((JU5 + JU6)) AS CG, TO_CHAR(JU7) AS DG
|
||||
FROM
|
||||
((
|
||||
SELECT
|
||||
PLACENAME, PLACECODE, IN_JUDGE, IN_SEQ
|
||||
FROM
|
||||
RPT R
|
||||
RIGHT OUTER JOIN
|
||||
(
|
||||
SELECT CODE2 AS PLACECODE, CODENM AS PLACENAME
|
||||
FROM TCODE
|
||||
WHERE CODE1 = 'C001'
|
||||
]]>
|
||||
select C.CODENM PLACENAME,
|
||||
R.REPORT1, R.report2, r.ju1, r.ju2, r.ju3, r.ju4, r.ju5, r.ju6, r.ju7, r.ag, r.bg, r.cg, r.dg
|
||||
from RPT R
|
||||
inner join TCODE C
|
||||
ON C.CODE1 = 'C001' AND C.CODE2 = R.IN_PLACE_CODE
|
||||
<if test="places != null and places.length > 0">
|
||||
AND CODE2 IN
|
||||
<foreach collection="places" item="place" open="(" close=")" separator=",">
|
||||
#{place}
|
||||
</foreach>
|
||||
</if>
|
||||
<![CDATA[
|
||||
) C
|
||||
ON C.PLACECODE = R.IN_PLACE_CODE
|
||||
) PIVOT (COUNT(IN_SEQ) FOR IN_JUDGE IN (1 JU1, 2 JU2, 3 JU3, 4 JU4, 5 JU5, 6 JU6, 7 JU7))) A,
|
||||
(
|
||||
SELECT
|
||||
PLACENAME,
|
||||
SUM(CASE WHEN IN_REPORT1 = 1 THEN 1 ELSE 0 END) AS REPORT1,
|
||||
SUM(CASE WHEN IN_REPORT2 = 1 THEN 1 ELSE 0 END) AS REPORT2
|
||||
FROM
|
||||
RPT R
|
||||
RIGHT OUTER JOIN
|
||||
(
|
||||
SELECT CODE2 AS PLACECODE, CODENM AS PLACENAME
|
||||
FROM TCODE
|
||||
WHERE CODE1 = 'C001'
|
||||
]]>
|
||||
<if test="places != null and places.length > 0">
|
||||
AND CODE2 IN
|
||||
<foreach collection="places" item="place" open="(" close=")" separator=",">
|
||||
#{place}
|
||||
</foreach>
|
||||
</if>
|
||||
<![CDATA[
|
||||
) C
|
||||
ON C.PLACECODE = R.IN_PLACE_CODE
|
||||
GROUP BY
|
||||
PLACENAME, PLACECODE ) B
|
||||
WHERE A.PLACENAME = B.PLACENAME
|
||||
ORDER BY PLACECODE
|
||||
]]>
|
||||
|
||||
<!-- WITH RPT AS (-->
|
||||
<!-- SELECT *-->
|
||||
<!-- FROM-->
|
||||
<!-- RPT_INFO-->
|
||||
<!-- WHERE-->
|
||||
<!-- IN_COMPLETE = '1'-->
|
||||
<!-- AND IN_STATE_CODE <> '99'-->
|
||||
<!-- AND IN_INFODATE >= #{dateStart}-->
|
||||
<!-- AND IN_INFODATE <= #{dateEnd}-->
|
||||
<!-- ]]>-->
|
||||
<!-- <if test="policeType != null and policeType.length > 0">-->
|
||||
<!-- AND IN_TYPE IN-->
|
||||
<!-- <foreach collection="policeType" item="type" open="(" close=")" separator=",">-->
|
||||
<!-- #{type}-->
|
||||
<!-- </foreach>-->
|
||||
<!-- </if>-->
|
||||
<!-- <if test="judges != null and judges.length > 0">-->
|
||||
<!-- AND IN_JUDGE IN-->
|
||||
<!-- <foreach collection="judges" item="judge" open="(" close=")" separator=",">-->
|
||||
<!-- #{judge}-->
|
||||
<!-- </foreach>-->
|
||||
<!-- </if>-->
|
||||
<!-- <if test="category1 != null and category1.length > 0">-->
|
||||
<!-- AND IN_CATEGORY1 IN-->
|
||||
<!-- <foreach collection="category1" item="category" open="(" close=")" separator=",">-->
|
||||
<!-- #{category}-->
|
||||
<!-- </foreach>-->
|
||||
<!-- </if>-->
|
||||
<!-- <if test="category2 != null and category2.length > 0">-->
|
||||
<!-- AND IN_CATEGORY2 IN-->
|
||||
<!-- <foreach collection="category2" item="category" open="(" close=")" separator=",">-->
|
||||
<!-- #{category}-->
|
||||
<!-- </foreach>-->
|
||||
<!-- </if>-->
|
||||
<!-- <if test="category3 != null and category3.length > 0">-->
|
||||
<!-- AND IN_CATEGORY3 IN-->
|
||||
<!-- <foreach collection="category3" item="category" open="(" close=")" separator=",">-->
|
||||
<!-- #{category}-->
|
||||
<!-- </foreach>-->
|
||||
<!-- </if>-->
|
||||
<!-- <if test="category4 != null and category4.length > 0">-->
|
||||
<!-- AND IN_CATEGORY4 IN-->
|
||||
<!-- <foreach collection="category4" item="category" open="(" close=")" separator=",">-->
|
||||
<!-- #{category}-->
|
||||
<!-- </foreach>-->
|
||||
<!-- </if>-->
|
||||
<!-- <![CDATA[-->
|
||||
<!-- )-->
|
||||
<!-- SELECT-->
|
||||
<!-- A.PLACENAME,-->
|
||||
<!-- TO_CHAR(REPORT1) REPORT1, TO_CHAR(REPORT2) REPORT2,-->
|
||||
<!-- TO_CHAR(JU1) JU1, TO_CHAR(JU2) JU2, TO_CHAR(JU3) JU3, TO_CHAR(JU4) JU4, TO_CHAR(JU5) JU5, TO_CHAR(JU6) JU6, TO_CHAR(JU7) JU7,-->
|
||||
<!-- TO_CHAR((JU1 + JU2)) AS AG, TO_CHAR((JU3 + JU4)) AS BG, TO_CHAR((JU5 + JU6)) AS CG, TO_CHAR(JU7) AS DG-->
|
||||
<!-- FROM-->
|
||||
<!-- ((-->
|
||||
<!-- SELECT-->
|
||||
<!-- PLACENAME, PLACECODE, IN_JUDGE, IN_SEQ-->
|
||||
<!-- FROM-->
|
||||
<!-- RPT R-->
|
||||
<!-- RIGHT OUTER JOIN-->
|
||||
<!-- (-->
|
||||
<!-- SELECT CODE2 AS PLACECODE, CODENM AS PLACENAME-->
|
||||
<!-- FROM TCODE-->
|
||||
<!-- WHERE CODE1 = 'C001'-->
|
||||
<!-- ]]>-->
|
||||
<!-- <if test="places != null and places.length > 0">-->
|
||||
<!-- AND CODE2 IN-->
|
||||
<!-- <foreach collection="places" item="place" open="(" close=")" separator=",">-->
|
||||
<!-- #{place}-->
|
||||
<!-- </foreach>-->
|
||||
<!-- </if>-->
|
||||
<!-- <![CDATA[-->
|
||||
<!-- ) C-->
|
||||
<!-- ON C.PLACECODE = R.IN_PLACE_CODE-->
|
||||
<!-- ) PIVOT (COUNT(IN_SEQ) FOR IN_JUDGE IN (1 JU1, 2 JU2, 3 JU3, 4 JU4, 5 JU5, 6 JU6, 7 JU7))) A,-->
|
||||
<!-- (-->
|
||||
<!-- SELECT-->
|
||||
<!-- PLACENAME,-->
|
||||
<!-- SUM(CASE WHEN IN_REPORT1 = 1 THEN 1 ELSE 0 END) AS REPORT1,-->
|
||||
<!-- SUM(CASE WHEN IN_REPORT2 = 1 THEN 1 ELSE 0 END) AS REPORT2-->
|
||||
<!-- FROM-->
|
||||
<!-- RPT R-->
|
||||
<!-- RIGHT OUTER JOIN-->
|
||||
<!-- (-->
|
||||
<!-- SELECT CODE2 AS PLACECODE, CODENM AS PLACENAME-->
|
||||
<!-- FROM TCODE-->
|
||||
<!-- WHERE CODE1 = 'C001'-->
|
||||
<!-- ]]>-->
|
||||
<!-- <if test="places != null and places.length > 0">-->
|
||||
<!-- AND CODE2 IN-->
|
||||
<!-- <foreach collection="places" item="place" open="(" close=")" separator=",">-->
|
||||
<!-- #{place}-->
|
||||
<!-- </foreach>-->
|
||||
<!-- </if>-->
|
||||
<!-- <![CDATA[-->
|
||||
<!-- ) C-->
|
||||
<!-- ON C.PLACECODE = R.IN_PLACE_CODE-->
|
||||
<!-- GROUP BY-->
|
||||
<!-- PLACENAME, PLACECODE ) B-->
|
||||
<!-- WHERE A.PLACENAME = B.PLACENAME-->
|
||||
<!-- ORDER BY PLACECODE-->
|
||||
</select>
|
||||
</mapper>
|
||||
|
|
@ -74,20 +74,12 @@
|
|||
<select id="Security.getHierarchyRoles" resultType="map">
|
||||
<![CDATA[
|
||||
SELECT
|
||||
*
|
||||
FROM (
|
||||
SELECT ROWNUM RNUM, ROLES_LIST.*
|
||||
FROM (
|
||||
SELECT
|
||||
A.CHILDREN_ROLE CHILD, A.PARENTS_ROLE PARENT
|
||||
(ROW_NUMBER() OVER()) AS RNUM, A.CHILDREN_ROLE CHILD, A.PARENTS_ROLE PARENT
|
||||
FROM
|
||||
T_SSO_HIERARCHY_ROLES A
|
||||
LEFT JOIN T_SSO_HIERARCHY_ROLES B
|
||||
ON (A.CHILDREN_ROLE = B.PARENTS_ROLE)
|
||||
) ROLES_LIST
|
||||
)
|
||||
ORDER BY
|
||||
RNUM DESC
|
||||
order by RNUM desc
|
||||
]]>
|
||||
</select>
|
||||
|
||||
|
|
|
|||
|
|
@ -62,7 +62,8 @@
|
|||
<![CDATA[
|
||||
SELECT *
|
||||
FROM (
|
||||
SELECT ROWNUM RNUM, ALL_LIST.*,
|
||||
SELECT
|
||||
(row_number() over()) as RNUM, ALL_LIST.*,
|
||||
(SELECT COUNT(*) FROM H3_SUSA_FILE WHERE SF_SS_SEQ = ALL_LIST.SS_IDX) AS FILE_CNT,
|
||||
(SELECT CODENM FROM TCODE WHERE CODE1 = 'C001' AND CODE2 = ALL_LIST.SS_PLACE1) AS PLACE1_STR
|
||||
FROM (
|
||||
|
|
@ -85,7 +86,7 @@
|
|||
<![CDATA[
|
||||
ORDER BY SS_IDX DESC
|
||||
) ALL_LIST
|
||||
)
|
||||
) AS list
|
||||
WHERE
|
||||
RNUM > #{firstIndex} AND
|
||||
RNUM <= #{firstIndex} + #{recordCountPerPage}
|
||||
|
|
@ -128,20 +129,33 @@
|
|||
</select>
|
||||
|
||||
<insert id="Susa.insert" parameterType="susaVO">
|
||||
INSERT INTO H3_SUSA_LIST
|
||||
(
|
||||
SS_TYPE, SS_AGENCY, SS_CHARGE_NM, SS_SDATE, SS_REGDATE,
|
||||
SS_CONTENTS, SS_PLACE1, SS_EDATE, SS_TITLE, SS_RESULT,
|
||||
insert into H3_SUSA_LIST (
|
||||
SS_TYPE,
|
||||
SS_AGENCY,
|
||||
SS_CHARGE_NM,
|
||||
SS_SDATE,
|
||||
SS_REGDATE,
|
||||
SS_CONTENTS,
|
||||
SS_PLACE1,
|
||||
SS_EDATE,
|
||||
SS_TITLE,
|
||||
SS_RESULT,
|
||||
SS_WRITER
|
||||
)
|
||||
VALUES
|
||||
(
|
||||
#{type}, #{agency}, #{chargeNm}, #{sdate}, SYSDATE,
|
||||
#{contents}, #{place1}, #{edate}, #{title}, #{result},
|
||||
) values (
|
||||
#{type},
|
||||
#{agency},
|
||||
#{chargeNm},
|
||||
#{sdate},
|
||||
NOW(),
|
||||
#{contents},
|
||||
#{place1},
|
||||
#{edate},
|
||||
#{title},
|
||||
#{result},
|
||||
#{writer}
|
||||
)
|
||||
<selectKey resultType="int" keyProperty="idx" order="AFTER">
|
||||
SELECT H3_SUSA_LIST_SS_IDX_SEQ.CURRVAL FROM DUAL
|
||||
SELECT currval('susa_list_seq') as idx
|
||||
</selectKey>
|
||||
</insert>
|
||||
|
||||
|
|
|
|||
|
|
@ -38,10 +38,8 @@
|
|||
]]>
|
||||
</select>
|
||||
|
||||
<insert id="SusaFile.insert" parameterType="susaVO" useGeneratedKeys="true" keyColumn="SF_SEQ">
|
||||
<![CDATA[
|
||||
INSERT INTO
|
||||
H3_SUSA_FILE (
|
||||
<insert id="SusaFile.insert" parameterType="susaVO">
|
||||
INSERT INTO H3_SUSA_FILE (
|
||||
SF_ORDER,
|
||||
SF_ORG_NAME,
|
||||
SF_SAVE_NAME,
|
||||
|
|
@ -52,7 +50,6 @@
|
|||
#{saveName},
|
||||
#{parentSeq}
|
||||
)
|
||||
]]>
|
||||
</insert>
|
||||
|
||||
<delete id="SusaFile.delete" parameterType="susaVO">
|
||||
|
|
|
|||
|
|
@ -0,0 +1,171 @@
|
|||
<?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="Corp">
|
||||
|
||||
<resultMap id="corpResult" type="corpVO">
|
||||
<result property="place1" column="PLACE1" />
|
||||
<result property="place1str" column="CODENM" />
|
||||
<result property="orgId" column="ORG_ID" />
|
||||
<result property="orgNo" column="ORG_NO" />
|
||||
<result property="grpNo" column="GRP_NO" />
|
||||
<result property="name" column="NAME" />
|
||||
<result property="location" column="LOCATION" />
|
||||
<result property="ceo" column="CEO" />
|
||||
<result property="jobType" column="JOBTYPE" />
|
||||
<result property="tel" column="TEL" />
|
||||
<result property="fax" column="FAX" />
|
||||
<result property="comments" column="COMMENTS" />
|
||||
<result property="partner" column="PARTNER" />
|
||||
<result property="shipCnt" column="SHIPCNT" />
|
||||
<result property="memberCnt" column="MEMBERCNT" />
|
||||
<result property="basicYear" column="BASICYEAR" />
|
||||
<result property="fund" column="FUND" />
|
||||
<result property="writerPlace1" column="WRITER_PLACE1" />
|
||||
<result property="writer" column="WRITER" />
|
||||
<result property="credate" column="CREDATE" />
|
||||
<result property="logdate" column="LOGDATE" />
|
||||
</resultMap>
|
||||
|
||||
<select id="select" parameterType="corpVO" resultMap="corpResult">
|
||||
<![CDATA[
|
||||
SELECT
|
||||
CP.*, C.CODENM
|
||||
FROM
|
||||
TCORP CP, TCODE C
|
||||
WHERE
|
||||
C.CODE1 = 'C001'
|
||||
AND CP.PLACE1 = C.CODE2
|
||||
AND CP.PLACE1 = #{place1}
|
||||
AND CP.ORG_ID = #{orgId}
|
||||
AND CP.ORG_NO = #{orgNo}
|
||||
]]>
|
||||
</select>
|
||||
|
||||
<select id="selectList" parameterType="corpSearchVO" resultMap="corpResult">
|
||||
<![CDATA[
|
||||
SELECT
|
||||
CP.*, C.CODENM
|
||||
FROM
|
||||
TCORP CP, TCODE C
|
||||
WHERE
|
||||
C.CODE1 = 'C001'
|
||||
AND CP.PLACE1 = C.CODE2
|
||||
AND CP.ORG_ID = #{orgId}
|
||||
AND CP.GRP_NO = #{grpNo}
|
||||
]]>
|
||||
<if test="place1 != null and place1 != ''">
|
||||
AND CP.PLACE1 = #{place1}
|
||||
</if>
|
||||
<if test="name != null and name != ''">
|
||||
AND CP.NAME LIKE '%' || #{name} || '%'
|
||||
</if>
|
||||
<if test="jobType != null and jobType != ''">
|
||||
AND CP.JOBTYPE = #{jobType}
|
||||
</if>
|
||||
<![CDATA[
|
||||
ORDER BY
|
||||
CP.PLACE1 ASC
|
||||
]]>
|
||||
</select>
|
||||
|
||||
<select id="selectStats" parameterType="hashmap" resultType="hashmap" >
|
||||
<![CDATA[
|
||||
SELECT
|
||||
COUNT(ORG_ID) AS TOT_CNT,
|
||||
'00' AS ORG_ID,
|
||||
'계' AS ORG_NM,
|
||||
'00' AS GRP_NO,
|
||||
]]>
|
||||
<foreach collection="placeList" item="item" index="index" separator="," open="" close="">
|
||||
SUM(CASE PLACE1 WHEN #{item} THEN 1 ELSE 0 END) AS ${item}_CNT
|
||||
</foreach>
|
||||
<![CDATA[
|
||||
FROM TCORP
|
||||
UNION
|
||||
SELECT
|
||||
COUNT(TP.ORG_ID) AS TOT_CNT,
|
||||
SUBSTR(TD.CODE2,1,2) AS ORG_ID,
|
||||
TD.CODENM AS ORG_NM,
|
||||
SUBSTR(TD.CODE2,3,2) AS GRP_NO,
|
||||
]]>
|
||||
<foreach collection="placeList" item="item" index="index" separator="," open="" close="">
|
||||
SUM(CASE PLACE1 WHEN #{item} THEN 1 ELSE 0 END) AS ${item}_CNT
|
||||
</foreach>
|
||||
<![CDATA[
|
||||
FROM TCORP TP LEFT JOIN TCODE TD ON TP.ORG_ID = SUBSTR(TD.CODE2,1,2)
|
||||
WHERE TD.CODE1 = 'CORP'
|
||||
GROUP BY TP.ORG_ID, TD.CODENM, GRP_NO, TD.CODE2
|
||||
ORDER BY ORG_ID ASC
|
||||
]]>
|
||||
</select>
|
||||
|
||||
<insert id="insert" parameterType="corpVO">
|
||||
<![CDATA[
|
||||
INSERT INTO TCORP
|
||||
(
|
||||
PLACE1, ORG_ID, ORG_NO, GRP_NO, NAME,
|
||||
LOCATION, CEO, JOBTYPE, TEL, FAX,
|
||||
COMMENTS, PARTNER, SHIPCNT, MEMBERCNT, BASICYEAR,
|
||||
FUND, WRITER_PLACE1, WRITER, CREDATE, LOGDATE
|
||||
)
|
||||
VALUES
|
||||
(
|
||||
#{place1}, #{orgId}, #{orgNo}, #{grpNo}, #{name},
|
||||
#{location}, #{ceo}, #{jobType}, #{tel}, #{fax},
|
||||
#{comments}, #{partner}, #{shipCnt}, #{memberCnt}, #{basicYear},
|
||||
#{fund}, #{writerPlace1}, #{writer}, TO_CHAR(NOW(), 'YYYYMMDDHH24MISS'), TO_CHAR(NOW(), 'YYYYMMDDHH24MISS')
|
||||
)
|
||||
]]>
|
||||
</insert>
|
||||
|
||||
<update id="update" parameterType="corpVO">
|
||||
<![CDATA[
|
||||
UPDATE
|
||||
TCORP
|
||||
SET
|
||||
GRP_NO = #{grpNo},
|
||||
NAME = #{name},
|
||||
LOCATION = #{location},
|
||||
CEO = #{ceo},
|
||||
JOBTYPE = #{jobType},
|
||||
TEL = #{tel},
|
||||
FAX = #{fax},
|
||||
COMMENTS = #{comments},
|
||||
PARTNER = #{partner},
|
||||
BASICYEAR = #{basicYear},
|
||||
SHIPCNT = #{shipCnt},
|
||||
MEMBERCNT = #{memberCnt},
|
||||
FUND = #{fund},
|
||||
WRITER = #{writer},
|
||||
WRITER_PLACE1 = #{writerPlace1},
|
||||
LOGDATE = TO_CHAR(NOW(), 'YYYYMMDDHH24MISS')
|
||||
WHERE
|
||||
PLACE1 = #{place1}
|
||||
AND ORG_ID = #{orgId}
|
||||
AND ORG_NO = #{orgNo}
|
||||
]]>
|
||||
</update>
|
||||
|
||||
<delete id="delete" parameterType="corpVO">
|
||||
<![CDATA[
|
||||
DELETE
|
||||
FROM
|
||||
TCORP
|
||||
WHERE
|
||||
PLACE1 = #{place1}
|
||||
AND ORG_ID = #{orgId}
|
||||
AND ORG_NO = #{orgNo}
|
||||
]]>
|
||||
</delete>
|
||||
|
||||
<select id="selectMaxOrgNo" parameterType="corpVO" resultType="int">
|
||||
<![CDATA[
|
||||
SELECT
|
||||
MAX(ORG_NO)
|
||||
FROM
|
||||
TCORP
|
||||
WHERE
|
||||
ORG_ID = #{orgId}
|
||||
]]>
|
||||
</select>
|
||||
</mapper>
|
||||
|
|
@ -0,0 +1,119 @@
|
|||
<?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="DivMng">
|
||||
|
||||
<resultMap id="divMngResult" type="divMngVO">
|
||||
<result property="place" column="DS_PLACE" />
|
||||
<result property="placeStr" column="CODENM" />
|
||||
<result property="no" column="DS_NO" />
|
||||
<result property="local" column="DS_LOCAL" />
|
||||
<result property="gubun" column="DS_GUBUN" />
|
||||
<result property="staffNum" column="DS_STAFF_NUM" />
|
||||
<result property="tel" column="DS_TEL" />
|
||||
<result property="condition" column="DS_CONDITION" />
|
||||
<result property="equipStat" column="DS_EQUIP_STAT" />
|
||||
<result property="fileImg" column="DS_FILEIMG" />
|
||||
<result property="file1" column="DS_FILE1" />
|
||||
<result property="file2" column="DS_FILE2" />
|
||||
<result property="file3" column="DS_FILE3" />
|
||||
<result property="creDate" column="DS_CREDATE" />
|
||||
<result property="logDate" column="DS_LOGDATE" />
|
||||
<result property="writer" column="DS_WRITER" />
|
||||
</resultMap>
|
||||
|
||||
<select id="select" parameterType="divMngVO" resultMap="divMngResult">
|
||||
<![CDATA[
|
||||
SELECT
|
||||
DS.*, C.CODENM
|
||||
FROM
|
||||
H3_DIVISION_MANAGE_STAT DS, TCODE C
|
||||
WHERE
|
||||
C.CODE1 = 'C001'
|
||||
AND DS.DS_PLACE = C.CODE2
|
||||
AND DS.DS_PLACE = #{place}
|
||||
AND DS.DS_NO = #{no}
|
||||
]]>
|
||||
</select>
|
||||
|
||||
<select id="selectList" parameterType="divMngSearchVO" resultMap="divMngResult">
|
||||
<![CDATA[
|
||||
SELECT
|
||||
DS.*, C.CODENM
|
||||
FROM
|
||||
H3_DIVISION_MANAGE_STAT DS, TCODE C
|
||||
WHERE
|
||||
C.CODE1 = 'C001'
|
||||
AND DS.DS_PLACE = C.CODE2
|
||||
|
||||
]]>
|
||||
<if test="place != null and place != ''">
|
||||
AND DS.DS_PLACE = #{place}
|
||||
</if>
|
||||
<![CDATA[
|
||||
ORDER BY
|
||||
DS.DS_PLACE ASC,
|
||||
DS.DS_NO ASC
|
||||
]]>
|
||||
</select>
|
||||
|
||||
<insert id="insert" parameterType="divMngVO">
|
||||
<![CDATA[
|
||||
INSERT INTO H3_DIVISION_MANAGE_STAT
|
||||
(
|
||||
DS_PLACE, DS_NO, DS_LOCAL, DS_GUBUN, DS_STAFF_NUM,
|
||||
DS_TEL, DS_CONDITION, DS_EQUIP_STAT, DS_FILEIMG, DS_FILE1,
|
||||
DS_FILE2, DS_FILE3, DS_CREDATE, DS_WRITER
|
||||
)
|
||||
VALUES
|
||||
(
|
||||
#{place}, #{no}, #{local}, #{gubun}, #{staffNum},
|
||||
#{tel}, #{condition}, #{equipStat}, #{fileImg}, #{file1},
|
||||
#{file2}, #{file3}, NOW(), #{writer}
|
||||
)
|
||||
]]>
|
||||
</insert>
|
||||
|
||||
<update id="update" parameterType="divMngVO">
|
||||
<![CDATA[
|
||||
UPDATE
|
||||
H3_DIVISION_MANAGE_STAT
|
||||
SET
|
||||
DS_LOCAL = #{local},
|
||||
DS_GUBUN = #{gubun},
|
||||
DS_STAFF_NUM = #{staffNum},
|
||||
DS_TEL = #{tel},
|
||||
DS_CONDITION = #{condition},
|
||||
DS_EQUIP_STAT = #{equipStat},
|
||||
DS_FILEIMG = #{fileImg},
|
||||
DS_FILE1 = #{file1},
|
||||
DS_FILE2 = #{file2},
|
||||
DS_FILE3 = #{file3},
|
||||
DS_LOGDATE = NOW()
|
||||
WHERE
|
||||
DS_PLACE = #{place}
|
||||
AND DS_NO = #{no}
|
||||
]]>
|
||||
</update>
|
||||
|
||||
<delete id="delete" parameterType="divMngVO">
|
||||
<![CDATA[
|
||||
DELETE
|
||||
FROM
|
||||
H3_DIVISION_MANAGE_STAT
|
||||
WHERE
|
||||
DS_PLACE = #{place}
|
||||
AND DS_NO = #{no}
|
||||
]]>
|
||||
</delete>
|
||||
|
||||
<select id="selectMaxNo" parameterType="divMngVO" resultType="int">
|
||||
<![CDATA[
|
||||
SELECT
|
||||
MAX(DS_NO)
|
||||
FROM
|
||||
H3_DIVISION_MANAGE_STAT
|
||||
WHERE
|
||||
DS_PLACE = #{place}
|
||||
]]>
|
||||
</select>
|
||||
</mapper>
|
||||
|
|
@ -0,0 +1,124 @@
|
|||
<?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="Ferry">
|
||||
|
||||
<resultMap id="ferryResult" type="ferryVO">
|
||||
<result property="serNo" column="SER_NO" />
|
||||
<result property="ferryOffice" column="FERRYOFFICE" />
|
||||
<result property="ferryName" column="FERRYNAME" />
|
||||
<result property="ferryTon" column="FERRYTON" />
|
||||
<result property="ferryRoute" column="FERRYROUTE" />
|
||||
<result property="ferryTime" column="FERRYTIME" />
|
||||
<result property="ferrySpeedMax" column="FERRYSPEEDMAX" />
|
||||
<result property="ferrySpeedNor" column="FERRYSPEEDNOR" />
|
||||
<result property="ferryGuestCnt" column="FERRYGUESTCNT" />
|
||||
<result property="ferryClueCnt" column="FERRYCLUECNT" />
|
||||
<result property="runTerm" column="RUNTERM" />
|
||||
<result property="runCnt" column="RUNCNT" />
|
||||
<result property="repreName" column="REPRENAME" />
|
||||
<result property="tel" column="TEL" />
|
||||
<result property="ferrySosok" column="FERRYSOSOK" />
|
||||
<result property="sailingDistance" column="SAILINGDISTANCE" />
|
||||
<result property="sailingDate" column="SAILINGDATE" />
|
||||
<result property="cooperateNation" column="COOPERATENATION" />
|
||||
<result property="writer" column="WRITER" />
|
||||
<result property="creDate" column="CREDATE" />
|
||||
<result property="logDate" column="LOGDATE" />
|
||||
<result property="imgFile" column="IMGFILE" />
|
||||
<result property="comments" column="COMMENTS" />
|
||||
</resultMap>
|
||||
|
||||
<select id="select" parameterType="ferryVO" resultMap="ferryResult">
|
||||
<![CDATA[
|
||||
SELECT
|
||||
*
|
||||
FROM
|
||||
TFERRY
|
||||
WHERE
|
||||
SER_NO = #{serNo}
|
||||
]]>
|
||||
</select>
|
||||
|
||||
<select id="selectList" parameterType="divMngSearchVO" resultMap="ferryResult">
|
||||
<![CDATA[
|
||||
SELECT
|
||||
*
|
||||
FROM
|
||||
TFERRY
|
||||
WHERE
|
||||
FERRYROUTE = #{ferryRoute}
|
||||
ORDER BY
|
||||
SER_NO ASC
|
||||
]]>
|
||||
</select>
|
||||
|
||||
<insert id="insert" parameterType="ferryVO">
|
||||
<![CDATA[
|
||||
INSERT INTO TFERRY
|
||||
(
|
||||
SER_NO, FERRYOFFICE, FERRYNAME, FERRYTON, FERRYROUTE,
|
||||
FERRYTIME, FERRYSPEEDMAX, FERRYSPEEDNOR, FERRYGUESTCNT, FERRYCLUECNT,
|
||||
RUNTERM, RUNCNT, REPRENAME, TEL, FERRYSOSOK,
|
||||
SAILINGDISTANCE, SAILINGDATE, COOPERATENATION, WRITER, CREDATE,
|
||||
LOGDATE, IMGFILE, COMMENTS
|
||||
)
|
||||
VALUES
|
||||
(
|
||||
#{serNo}, #{ferryOffice}, #{ferryName}, #{ferryTon}, #{ferryRoute},
|
||||
#{ferryTime}, #{ferrySpeedMax}, #{ferrySpeedNor}, #{ferryGuestCnt}, #{ferryClueCnt},
|
||||
#{runTerm}, #{runCnt}, #{repreName}, #{tel}, #{ferrySosok},
|
||||
#{sailingDistance}, #{sailingDate}, #{cooperateNation}, #{writer}, TO_CHAR(NOW(), 'YYYYMMDDHH24MISS'),
|
||||
TO_CHAR(NOW(), 'YYYYMMDDHH24MISS'), #{imgFile}, #{comments}
|
||||
)
|
||||
]]>
|
||||
</insert>
|
||||
|
||||
<update id="update" parameterType="ferryVO">
|
||||
<![CDATA[
|
||||
UPDATE
|
||||
TFERRY
|
||||
SET
|
||||
FERRYOFFICE = #{ferryOffice},
|
||||
FERRYNAME = #{ferryName},
|
||||
FERRYTON = #{ferryTon},
|
||||
FERRYROUTE = #{ferryRoute},
|
||||
FERRYTIME = #{ferryTime},
|
||||
FERRYSPEEDMAX = #{ferrySpeedMax},
|
||||
FERRYSPEEDNOR = #{ferrySpeedNor},
|
||||
FERRYGUESTCNT = #{ferryGuestCnt},
|
||||
FERRYCLUECNT = #{ferryClueCnt},
|
||||
RUNTERM = #{runTerm},
|
||||
RUNCNT = #{runCnt},
|
||||
REPRENAME = #{repreName},
|
||||
TEL = #{tel},
|
||||
FERRYSOSOK = #{ferrySosok},
|
||||
SAILINGDISTANCE = #{sailingDistance},
|
||||
SAILINGDATE = #{sailingDate},
|
||||
COOPERATENATION = #{cooperateNation},
|
||||
LOGDATE = TO_CHAR(NOW(), 'YYYYMMDDHH24MISS'),
|
||||
IMGFILE = #{imgFile},
|
||||
COMMENTS = #{comments}
|
||||
WHERE
|
||||
SER_NO = #{serNo}
|
||||
]]>
|
||||
</update>
|
||||
|
||||
<delete id="delete" parameterType="ferryVO">
|
||||
<![CDATA[
|
||||
DELETE
|
||||
FROM
|
||||
TFERRY
|
||||
WHERE
|
||||
SER_NO = #{serNo}
|
||||
]]>
|
||||
</delete>
|
||||
|
||||
<select id="selectMaxSerNo" parameterType="ferryVO" resultType="int">
|
||||
<![CDATA[
|
||||
SELECT
|
||||
MAX(SER_NO)
|
||||
FROM
|
||||
TFERRY
|
||||
]]>
|
||||
</select>
|
||||
</mapper>
|
||||
|
|
@ -0,0 +1,145 @@
|
|||
<?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="WeakPlace">
|
||||
|
||||
<resultMap id="weakplaceResult" type="weakPlaceVO">
|
||||
<result property="place1" column="PLACE1" />
|
||||
<result property="place1str" column="CODENM" />
|
||||
<result property="wpNo" column="WP_NO" />
|
||||
<result property="name" column="NAME" />
|
||||
<result property="location" column="LOCATION" />
|
||||
<result property="comments" column="COMMENTS" />
|
||||
<result property="filename1" column="FILENAME1" />
|
||||
<result property="filename2" column="FILENAME2" />
|
||||
<result property="writer" column="WRITER" />
|
||||
<result property="credate" column="CREDATE" />
|
||||
<result property="logdate" column="LOGDATE" />
|
||||
</resultMap>
|
||||
|
||||
<select id="WeakPlace.select" parameterType="weakPlaceVO" resultMap="weakplaceResult">
|
||||
<![CDATA[
|
||||
SELECT
|
||||
WP.*, C.CODENM
|
||||
FROM
|
||||
TWEAKPLACE WP, TCODE C
|
||||
WHERE
|
||||
UPPER(WP.PLACE1) = UPPER(C.CODE2)
|
||||
AND C.CODE1 = 'C001'
|
||||
AND WP.PLACE1 = #{place1}
|
||||
AND WP.WP_NO = #{wpNo}
|
||||
]]>
|
||||
</select>
|
||||
|
||||
<select id="WeakPlace.selectList" parameterType="weakPlaceSearchVO" resultMap="weakplaceResult">
|
||||
<![CDATA[
|
||||
SELECT
|
||||
WP.*, C.CODENM
|
||||
FROM
|
||||
TWEAKPLACE WP, TCODE C
|
||||
WHERE
|
||||
UPPER(WP.PLACE1) = UPPER(C.CODE2)
|
||||
AND C.CODE1 = 'C001'
|
||||
]]>
|
||||
<if test="place1 != null and place1 != '' and place1 != 'PS00'">
|
||||
AND WP.PLACE1 = #{place1}
|
||||
</if>
|
||||
<![CDATA[
|
||||
ORDER BY
|
||||
WP.PLACE1 ASC, WP.WP_NO ASC
|
||||
]]>
|
||||
</select>
|
||||
|
||||
<select id="WeakPlace.selectStatsPerPlace" parameterType="hashmap" resultType="hashmap" >
|
||||
<![CDATA[
|
||||
SELECT
|
||||
*
|
||||
FROM
|
||||
(
|
||||
SELECT
|
||||
'0' AS PLACE1, '전체' AS CODENM_YAK, COUNT(*) AS CNT
|
||||
FROM
|
||||
TWEAKPLACE
|
||||
UNION
|
||||
SELECT
|
||||
C.CODE2, C.CODENM_YAK, COUNT(WP.WP_NO) AS CNT
|
||||
FROM
|
||||
TCODE C LEFT JOIN TWEAKPLACE WP ON UPPER(C.CODE2) = UPPER(WP.PLACE1)
|
||||
WHERE
|
||||
C.CODE1 = 'C001'
|
||||
AND UPPER(C.CODE2) IN
|
||||
]]>
|
||||
<foreach collection="placeList" item="item" index="index" separator="," open="(" close=")">
|
||||
UPPER(#{item})
|
||||
</foreach>
|
||||
<![CDATA[
|
||||
GROUP BY
|
||||
C.CODE2, C.CODENM_YAK
|
||||
) AS list
|
||||
ORDER BY
|
||||
UPPER(PLACE1) ASC
|
||||
]]>
|
||||
</select>
|
||||
|
||||
<select id="selectMaxWpNo" parameterType="String" resultType="int">
|
||||
<![CDATA[
|
||||
SELECT
|
||||
COALESCE(WP_NO, 0)
|
||||
FROM
|
||||
(
|
||||
SELECT
|
||||
WP_NO
|
||||
FROM
|
||||
TWEAKPLACE
|
||||
WHERE
|
||||
PLACE1 = #{_parameter}
|
||||
ORDER BY WP_NO DESC
|
||||
) add
|
||||
limit 1
|
||||
]]>
|
||||
</select>
|
||||
|
||||
<insert id="insert" parameterType="weakPlaceVO">
|
||||
<![CDATA[
|
||||
INSERT
|
||||
INTO TWEAKPLACE
|
||||
(
|
||||
PLACE1, WP_NO, NAME, LOCATION, COMMENTS,
|
||||
FILENAME1, FILENAME2, WRITER, CREDATE, LOGDATE
|
||||
)
|
||||
VALUES
|
||||
(
|
||||
#{place1}, #{wpNo}, #{name}, #{location}, #{comments},
|
||||
#{filename1}, #{filename2}, #{writer}, TO_CHAR(NOW(), 'YYYYMMDDHH24MISS'), NULL
|
||||
)
|
||||
]]>
|
||||
</insert>
|
||||
|
||||
<update id="update" parameterType="weakPlaceVO">
|
||||
<![CDATA[
|
||||
UPDATE
|
||||
TWEAKPLACE
|
||||
SET
|
||||
NAME = #{name},
|
||||
LOCATION = #{location},
|
||||
COMMENTS = #{comments},
|
||||
FILENAME1 = #{filename1},
|
||||
FILENAME2 = #{filename2},
|
||||
LOGDATE = TO_CHAR(NOW(), 'YYYYMMDDHH24MISS')
|
||||
WHERE
|
||||
PLACE1 = #{place1}
|
||||
AND WP_NO = #{wpNo}
|
||||
]]>
|
||||
</update>
|
||||
|
||||
<delete id="delete" parameterType="weakPlaceVO">
|
||||
<![CDATA[
|
||||
DELETE
|
||||
FROM
|
||||
TWEAKPLACE
|
||||
WHERE
|
||||
PLACE1 = #{place1}
|
||||
AND WP_NO = #{wpNo}
|
||||
]]>
|
||||
</delete>
|
||||
|
||||
</mapper>
|
||||
|
|
@ -54,15 +54,15 @@
|
|||
<typeAlias alias="eduVO" type="kcg.faics.fa.vo.EduVO"/>
|
||||
<typeAlias alias="eduSearchVO" type="kcg.faics.fa.vo.EduSearchVO"/>
|
||||
|
||||
<!-- kcg.faics.target -->
|
||||
<typeAlias alias="weakPlaceVO" type="kcg.faics.target.vo.WeakPlaceVO"/>
|
||||
<typeAlias alias="weakPlaceSearchVO" type="kcg.faics.target.vo.WeakPlaceSearchVO" />
|
||||
<typeAlias alias="corpVO" type="kcg.faics.target.vo.CorpVO"/>
|
||||
<typeAlias alias="corpSearchVO" type="kcg.faics.target.vo.CorpSearchVO" />
|
||||
<typeAlias alias="divMngVO" type="kcg.faics.target.vo.DivMngVO"/>
|
||||
<typeAlias alias="divMngSearchVO" type="kcg.faics.target.vo.DivMngSearchVO" />
|
||||
<typeAlias alias="ferryVO" type="kcg.faics.target.vo.FerryVO"/>
|
||||
<typeAlias alias="ferrySearchVO" type="kcg.faics.target.vo.FerrySearchVO" />
|
||||
<!-- kcg.faics.tg -->
|
||||
<typeAlias alias="weakPlaceVO" type="kcg.faics.tg.vo.WeakPlaceVO"/>
|
||||
<typeAlias alias="weakPlaceSearchVO" type="kcg.faics.tg.vo.WeakPlaceSearchVO" />
|
||||
<typeAlias alias="corpVO" type="kcg.faics.tg.vo.CorpVO"/>
|
||||
<typeAlias alias="corpSearchVO" type="kcg.faics.tg.vo.CorpSearchVO" />
|
||||
<typeAlias alias="divMngVO" type="kcg.faics.tg.vo.DivMngVO"/>
|
||||
<typeAlias alias="divMngSearchVO" type="kcg.faics.tg.vo.DivMngSearchVO" />
|
||||
<typeAlias alias="ferryVO" type="kcg.faics.tg.vo.FerryVO"/>
|
||||
<typeAlias alias="ferrySearchVO" type="kcg.faics.tg.vo.FerrySearchVO" />
|
||||
|
||||
<!-- kcg.faics.admin -->
|
||||
<typeAlias alias="logSearchVO" type="kcg.faics.admin.vo.LogSearchVO" />
|
||||
|
|
|
|||
|
|
@ -45,18 +45,10 @@
|
|||
<ul class="right btn-style">
|
||||
<li><a class="btn_excel" href="javascript:fn_goExcel();"></a></li>
|
||||
<li><a href="#" class="btn_reset" onclick="location.reload();"></a></li>
|
||||
<li><a class="btn_delete" href="javascript:fn_goDelete();"></a></li>
|
||||
</ul>
|
||||
</div>
|
||||
<table class="tbl_list" width="100%" border="0" cellpadding="0" cellspacing="0">
|
||||
<colgroup>
|
||||
<col width="80"/>
|
||||
<col width="200">
|
||||
<col width="100"/>
|
||||
<col width="100">
|
||||
<col width="100"/>
|
||||
<col width="60"/>
|
||||
<col width="60"/>
|
||||
</colgroup>
|
||||
<thead>
|
||||
<tr>
|
||||
<th align="center"><spring:message code="member.view.seq" /></th>
|
||||
|
|
@ -84,8 +76,11 @@
|
|||
<img src="/images/cmmn/blank_1x1.png" />
|
||||
</span>
|
||||
</th>
|
||||
<c:if test="${userVO.isSysAdmin == true or (userVO.isAdmin == true and result.place1 eq userVO.place1)}">
|
||||
<th><spring:message code="button.modify"/></th>
|
||||
<th><spring:message code="button.delete"/></th>
|
||||
<th><input type="checkbox" id="allChk"></th>
|
||||
</c:if>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
|
|
@ -98,18 +93,11 @@
|
|||
<td align="center" class="listtd"><c:out value="${result.positionStr}" /></td>
|
||||
<td align="center" class="listtd"><c:out value="${result.useridStr}"/></td>
|
||||
<td align="center" class="listtd"><c:out value="${result.name}" /></td>
|
||||
|
||||
<td align="center" class="listtd">
|
||||
<c:if test="${userVO.isSysAdmin == true or (userVO.isAdmin == true and result.place1 eq userVO.place1)}">
|
||||
<a href="#" onclick="modifyUser('<c:out value="${result.userid}"/>', '<c:out value="${result.name}"/>', '<c:out value="${result.place3Str}"/>');"><spring:message code="button.modify" /></a>
|
||||
<td align="center" class="listtd"><a href="#" onclick="modifyUser('<c:out value="${result.userid}"/>', '<c:out value="${result.name}"/>', '<c:out value="${result.place3Str}"/>');"><spring:message code="button.modify" /></a></td>
|
||||
<td align="center" class="listtd"><a href="#" onclick="deleteUser('<c:out value="${result.userid}"/>', '<c:out value="${result.name}"/>');"><spring:message code="button.delete" /></a></td>
|
||||
<td align="center"><input type="checkbox" name="userId" class="deleteUser" value="${result.userid}"></td>
|
||||
</c:if>
|
||||
</td>
|
||||
<td align="center" class="listtd">
|
||||
<c:if test="${userVO.isSysAdmin == true or (userVO.isAdmin == true and result.place1 eq userVO.place1)}">
|
||||
<a href="#" onclick="deleteUser('<c:out value="${result.userid}"/>', '<c:out value="${result.name}"/>');"><spring:message code="button.delete" /></a>
|
||||
</c:if>
|
||||
</td>
|
||||
|
||||
</tr>
|
||||
</c:forEach>
|
||||
</c:when>
|
||||
|
|
@ -199,6 +187,42 @@
|
|||
});
|
||||
});
|
||||
|
||||
$(document).on("change", "#allChk", function (){
|
||||
$(".deleteUser").prop("checked", this.checked)
|
||||
})
|
||||
|
||||
/* 사용자 삭제 */
|
||||
function fn_goDelete() {
|
||||
var checkBox = $(".deleteUser:checked")
|
||||
if(checkBox.length>0){
|
||||
if(confirm("사용자 정보 "+checkBox.length+"건 을 삭제하시겠습니까?")){
|
||||
var userIdStr = "";
|
||||
for(var i=0; i<checkBox.length; i++){
|
||||
var user = checkBox[i];
|
||||
userIdStr+=(user.value+"|");
|
||||
}
|
||||
/* ie에서 for of 반복문에서 에러 발생.
|
||||
for(const user of checkBox){
|
||||
userIdStr+=(user.value+"|");
|
||||
}*/
|
||||
$.ajax({
|
||||
url: '<c:out value="/admin/cmmnMemberDelete.do"/>',
|
||||
type: 'post',
|
||||
dataType: 'json',
|
||||
data : {userIdStr: userIdStr.slice(0, -1)},
|
||||
success: function (data) {
|
||||
if(data.result>0){
|
||||
alert("삭제되었습니다.")
|
||||
location.reload();
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
}else{
|
||||
alert("삭제 대상을 선택해주세요.")
|
||||
}
|
||||
}
|
||||
|
||||
/* 글 목록 화면 function */
|
||||
function fn_searchList() {
|
||||
document.searchForm.action = "<c:url value='/admin/cmmnMemberList.do'/>";
|
||||
|
|
|
|||
|
|
@ -8,7 +8,7 @@
|
|||
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt"%>
|
||||
<%@ taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions"%>
|
||||
<script type="text/javaScript" defer="defer">
|
||||
<!--
|
||||
//<!--
|
||||
|
||||
$(document).ready(function(){
|
||||
|
||||
|
|
@ -39,6 +39,10 @@
|
|||
});
|
||||
});
|
||||
|
||||
$(document).on('change', '#allChk', function (){
|
||||
$(".deleteUser").prop('checked', this.checked);
|
||||
})
|
||||
|
||||
/* 글 상세 화면 function */
|
||||
function fn_select(id) {
|
||||
document.listForm.userid.value = id;
|
||||
|
|
@ -64,6 +68,37 @@
|
|||
document.searchForm.submit();
|
||||
}
|
||||
|
||||
/* 사용자 삭제 */
|
||||
function fn_goDelete() {
|
||||
var checkBox = $(".deleteUser:checked");
|
||||
if(checkBox.length>0){
|
||||
if(confirm("사용자 정보 "+checkBox.length+"건 을 삭제하시겠습니까?")){
|
||||
var userIdStr = "";
|
||||
for(var i=0; i<checkBox.length; i++){
|
||||
var user = checkBox[i];
|
||||
userIdStr+=(user.value+"|");
|
||||
}
|
||||
/* ie에서 for of 반복문이 동작하지 않음.
|
||||
for(var user of checkBox){
|
||||
userIdStr+=(user.value+"|");
|
||||
}*/
|
||||
$.ajax({
|
||||
url: '<c:out value="/admin/faMemberDelete.do"/>',
|
||||
type: 'post',
|
||||
dataType: 'json',
|
||||
data : {userIdStr: userIdStr.slice(0, -1)},
|
||||
success: function (data) {
|
||||
if(data.result>0){
|
||||
alert("삭제되었습니다.")
|
||||
location.reload();
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
}else{
|
||||
alert("삭제 대상을 선택해주세요.")
|
||||
}
|
||||
}
|
||||
/* pagination 페이지 링크 function */
|
||||
function fn_link_page(pageNo) {
|
||||
document.searchForm.pageIndex.value = pageNo;
|
||||
|
|
@ -122,19 +157,21 @@
|
|||
<ul class="right btn-style">
|
||||
<li><a class="btn_excel" href="javascript:fn_goExcel();"></a></li>
|
||||
<li><a href="#" class="btn_reset" onclick="location.reload();"></a></li>
|
||||
<li><a class="btn_delete" href="javascript:fn_goDelete();"></a></li>
|
||||
</ul>
|
||||
</div>
|
||||
<table class="tbl_list" width="100%" border="0" cellpadding="0" cellspacing="0">
|
||||
<colgroup>
|
||||
<col width="70" >
|
||||
<col width="200" >
|
||||
<col width="110" >
|
||||
<col width="100" >
|
||||
<col width="80" >
|
||||
<col width="100" >
|
||||
<col width="100" >
|
||||
<col width="100" >
|
||||
<col width="80" >
|
||||
<col width="80" >
|
||||
<col width="70" >
|
||||
<col width="70" >
|
||||
</colgroup>
|
||||
<thead>
|
||||
<tr>
|
||||
|
|
@ -189,6 +226,7 @@
|
|||
</th>
|
||||
<c:if test="${userVO.isSysAdmin == true}">
|
||||
<th align="center">수정</th>
|
||||
<th><input type="checkbox" id="allChk"></th>
|
||||
</c:if>
|
||||
</tr>
|
||||
</thead>
|
||||
|
|
@ -219,6 +257,7 @@
|
|||
<td align="center"><c:out value="${result.usegrade}" /></td>
|
||||
<c:if test="${userVO.isSysAdmin == true}">
|
||||
<td align="center"><a href="javascript:fn_modify('${result.userid}');">수정</a></td>
|
||||
<td align="center"><input type="checkbox" name="userId" class="deleteUser" value="${result.userid}"></td>
|
||||
</c:if>
|
||||
</tr>
|
||||
</c:forEach>
|
||||
|
|
|
|||
|
|
@ -6,8 +6,10 @@
|
|||
<%@ taglib prefix="ct" tagdir="/WEB-INF/tags"%>
|
||||
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt"%>
|
||||
<%@ taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions"%>
|
||||
<% request.setCharacterEncoding("UTF-8"); %>
|
||||
|
||||
<script type="text/javaScript" language="javascript" defer="defer">
|
||||
<!--
|
||||
|
||||
|
||||
/* 글 상세 화면 function */
|
||||
function fn_select(id) {
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@
|
|||
<%@taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt"%>
|
||||
<%@ taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions" %>
|
||||
<script type="text/javaScript" type="text/javascript" defer="defer">
|
||||
<!--
|
||||
|
||||
/* 글 목록 화면 function */
|
||||
function fn_selectList() {
|
||||
document.menuForm.action = "<c:url value='/bbs/list.do'/>";
|
||||
|
|
@ -69,7 +69,6 @@
|
|||
}
|
||||
});
|
||||
});
|
||||
-->
|
||||
</script>
|
||||
<div id="table">
|
||||
<table class="tbl_view">
|
||||
|
|
|
|||
|
|
@ -6,7 +6,8 @@
|
|||
<div id="title" class="title-area">
|
||||
<ul class="page-title">
|
||||
<li>
|
||||
<c:out value="${menu.NAME}" /> <span><c:out value="${menu.ENG_NAME}" /></span>
|
||||
<c:out value="${menu.name}" /> <span><c:out value="${menu.eng_name}" /></span>
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
|
@ -19,13 +20,13 @@
|
|||
<c:forEach var="sub" items="${subMenu}" varStatus="status">
|
||||
<li>
|
||||
<c:choose>
|
||||
<c:when test="${sub.URL_GROUP == 'bbs'}">
|
||||
<c:set var="id" value="${fn:split(sub.URL, '/')[0]}"/>
|
||||
<c:set var="category" value="${fn:split(sub.URL, '/')[1]}"/>
|
||||
<a <c:if test="${sub.ID == menu.ID}">${current}</c:if> href="/<c:out value="${sub.URL_GROUP}"/>/list.do?id=${id}">${sub.NAME}</a>
|
||||
<c:when test="${sub.url_group == 'bbs'}">
|
||||
<c:set var="id" value="${fn:split(sub.url, '/')[0]}"/>
|
||||
<c:set var="category" value="${fn:split(sub.url, '/')[1]}"/>
|
||||
<a <c:if test="${sub.id == menu.id}">${current}</c:if> href="/<c:out value="${sub.url_group}"/>/list.do?id=${id}">${sub.name}</a>
|
||||
</c:when>
|
||||
<c:otherwise>
|
||||
<a <c:if test="${sub.ID == menu.ID}">${current}</c:if> href="/<c:out value="${sub.URL_GROUP}"/><c:out value="${sub.URL}"/>">${sub.NAME}</a>
|
||||
<a <c:if test="${sub.id == menu.id}">${current}</c:if> href="/<c:out value="${sub.url_group}"/><c:out value="${sub.url}"/>">${sub.name}</a>
|
||||
</c:otherwise>
|
||||
</c:choose>
|
||||
<c:if test="${!status.last}">${isEnd}</c:if>
|
||||
|
|
|
|||
|
|
@ -3,7 +3,7 @@
|
|||
<%@ taglib prefix="form" uri="http://www.springframework.org/tags/form"%>
|
||||
<%@ taglib prefix="spring" uri="http://www.springframework.org/tags"%>
|
||||
<script type="text/javaScript" language="javascript" defer="defer">
|
||||
<!--
|
||||
<!-- -->
|
||||
/* 화면 출력 function */
|
||||
function fn_goPrint() {
|
||||
var printThis = document.getElementById("table").innerHTML;
|
||||
|
|
@ -36,64 +36,64 @@
|
|||
<tr>
|
||||
<th align="center"><spring:message code="equip.name" /></th>
|
||||
<th align="center"><spring:message code="equip.total" /></th>
|
||||
<th align="center"><spring:message code="equip.PS00" /></th>
|
||||
<th align="center"><spring:message code="equip.PS01" /></th>
|
||||
<th align="center"><spring:message code="equip.PS02" /></th>
|
||||
<th align="center"><spring:message code="equip.PS03" /></th>
|
||||
<th align="center"><spring:message code="equip.PS04" /></th>
|
||||
<th align="center"><spring:message code="equip.PS05" /></th>
|
||||
<th align="center"><spring:message code="equip.PS06" /></th>
|
||||
<th align="center"><spring:message code="equip.PS07" /></th>
|
||||
<th align="center"><spring:message code="equip.PS08" /></th>
|
||||
<th align="center"><spring:message code="equip.PS09" /></th>
|
||||
<th align="center"><spring:message code="equip.PS10" /></th>
|
||||
<th align="center"><spring:message code="equip.PS11" /></th>
|
||||
<th align="center"><spring:message code="equip.PS12" /></th>
|
||||
<th align="center"><spring:message code="equip.PS13" /></th>
|
||||
<th align="center"><spring:message code="equip.PS14" /></th>
|
||||
<th align="center"><spring:message code="equip.PS15" /></th>
|
||||
<th align="center"><spring:message code="equip.PS16" /></th>
|
||||
<th align="center"><spring:message code="equip.PS17" /></th>
|
||||
<th align="center"><spring:message code="equip.PS18" /></th>
|
||||
<th align="center"><spring:message code="equip.PS19" /></th>
|
||||
<th align="center"><spring:message code="equip.PS50" /></th>
|
||||
<th align="center"><spring:message code="equip.PS90" /></th>
|
||||
<th align="center"><spring:message code="equip.PS91" /></th>
|
||||
<th align="center"><spring:message code="equip.PS92" /></th>
|
||||
<th align="center"><spring:message code="equip.PS93" /></th>
|
||||
<th align="center"><spring:message code="equip.PS94" /></th>
|
||||
<th align="center"><spring:message code="equip.ps00" /></th>
|
||||
<th align="center"><spring:message code="equip.ps01" /></th>
|
||||
<th align="center"><spring:message code="equip.ps02" /></th>
|
||||
<th align="center"><spring:message code="equip.ps03" /></th>
|
||||
<th align="center"><spring:message code="equip.ps04" /></th>
|
||||
<th align="center"><spring:message code="equip.ps05" /></th>
|
||||
<th align="center"><spring:message code="equip.ps06" /></th>
|
||||
<th align="center"><spring:message code="equip.ps07" /></th>
|
||||
<th align="center"><spring:message code="equip.ps08" /></th>
|
||||
<th align="center"><spring:message code="equip.ps09" /></th>
|
||||
<th align="center"><spring:message code="equip.ps10" /></th>
|
||||
<th align="center"><spring:message code="equip.ps11" /></th>
|
||||
<th align="center"><spring:message code="equip.ps12" /></th>
|
||||
<th align="center"><spring:message code="equip.ps13" /></th>
|
||||
<th align="center"><spring:message code="equip.ps14" /></th>
|
||||
<th align="center"><spring:message code="equip.ps15" /></th>
|
||||
<th align="center"><spring:message code="equip.ps16" /></th>
|
||||
<th align="center"><spring:message code="equip.ps17" /></th>
|
||||
<th align="center"><spring:message code="equip.ps18" /></th>
|
||||
<th align="center"><spring:message code="equip.ps19" /></th>
|
||||
<th align="center"><spring:message code="equip.ps50" /></th>
|
||||
<th align="center"><spring:message code="equip.ps90" /></th>
|
||||
<th align="center"><spring:message code="equip.ps91" /></th>
|
||||
<th align="center"><spring:message code="equip.ps92" /></th>
|
||||
<th align="center"><spring:message code="equip.ps93" /></th>
|
||||
<th align="center"><spring:message code="equip.ps94" /></th>
|
||||
</tr>
|
||||
</thead>
|
||||
<c:forEach var="equipStatus" items="${equipStatusList}" varStatus="status">
|
||||
<c:forEach var="equipstatus" items="${equipStatusList}" varStatus="status">
|
||||
<tr>
|
||||
<td align="center"><a href="javascript:fnEquipList('<c:out value="${equipStatus.EQUIP }"/>')" style="color:#0000ff;"><c:out value="${equipStatus.EQUIP_NM}" /></a></td>
|
||||
<td align="center"><c:out value="${equipStatus.TOTAL}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.PS00}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.PS01}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.PS02}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.PS03}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.PS04}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.PS05}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.PS06}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.PS07}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.PS08}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.PS09}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.PS10}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.PS11}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.PS12}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.PS13}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.PS14}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.PS15}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.PS16}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.PS17}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.PS18}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.PS19}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.PS50}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.PS90}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.PS91}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.PS92}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.PS93}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.PS94}" /></td>
|
||||
<td align="center"><a href="javascript:fnEquipList('<c:out value="${equipstatus.equip }"/>')" style="color:#0000ff;"><c:out value="${equipstatus.equip_nm}" /></a></td>
|
||||
<td align="center"><c:out value="${equipstatus.total}" /></td>
|
||||
<td align="center"><c:out value="${equipstatus.ps00}" /></td>
|
||||
<td align="center"><c:out value="${equipstatus.ps01}" /></td>
|
||||
<td align="center"><c:out value="${equipstatus.ps02}" /></td>
|
||||
<td align="center"><c:out value="${equipstatus.ps03}" /></td>
|
||||
<td align="center"><c:out value="${equipstatus.ps04}" /></td>
|
||||
<td align="center"><c:out value="${equipstatus.ps05}" /></td>
|
||||
<td align="center"><c:out value="${equipstatus.ps06}" /></td>
|
||||
<td align="center"><c:out value="${equipstatus.ps07}" /></td>
|
||||
<td align="center"><c:out value="${equipstatus.ps08}" /></td>
|
||||
<td align="center"><c:out value="${equipstatus.ps09}" /></td>
|
||||
<td align="center"><c:out value="${equipstatus.ps10}" /></td>
|
||||
<td align="center"><c:out value="${equipstatus.ps11}" /></td>
|
||||
<td align="center"><c:out value="${equipstatus.ps12}" /></td>
|
||||
<td align="center"><c:out value="${equipstatus.ps13}" /></td>
|
||||
<td align="center"><c:out value="${equipstatus.ps14}" /></td>
|
||||
<td align="center"><c:out value="${equipstatus.ps15}" /></td>
|
||||
<td align="center"><c:out value="${equipstatus.ps16}" /></td>
|
||||
<td align="center"><c:out value="${equipstatus.ps17}" /></td>
|
||||
<td align="center"><c:out value="${equipstatus.ps18}" /></td>
|
||||
<td align="center"><c:out value="${equipstatus.ps19}" /></td>
|
||||
<td align="center"><c:out value="${equipstatus.ps50}" /></td>
|
||||
<td align="center"><c:out value="${equipstatus.ps90}" /></td>
|
||||
<td align="center"><c:out value="${equipstatus.ps91}" /></td>
|
||||
<td align="center"><c:out value="${equipstatus.ps92}" /></td>
|
||||
<td align="center"><c:out value="${equipstatus.ps93}" /></td>
|
||||
<td align="center"><c:out value="${equipstatus.ps94}" /></td>
|
||||
</tr>
|
||||
</c:forEach>
|
||||
</table>
|
||||
|
|
|
|||
|
|
@ -62,11 +62,11 @@
|
|||
<tbody>
|
||||
<c:forEach var="equip" items="${equipList}" varStatus="status">
|
||||
<tr>
|
||||
<td class="title text" ><c:out value="${equip.CODENM}" /></td>
|
||||
<td class="number"><input type="text" name="<c:out value="${equip.CODE2}" />_cnt" value="<c:out value="${equip.EU_CNT}" />"></td>
|
||||
<td class="text"><textarea rows="" cols="" name="<c:out value="${equip.CODE2}" />_detail"><c:out value="${equip.EU_DETAIL}" /></textarea></td>
|
||||
<td class="number"><input type="text" name="<c:out value="${equip.CODE2}" />_check" value="<c:out value="${equip.EU_CHECK}" />"></td>
|
||||
<td class="data"><input type="text" name="<c:out value="${equip.CODE2}" />_state" value="<c:out value="${equip.EU_STATE}" />"></td>
|
||||
<td class="title text" ><c:out value="${equip.codenm}" /></td>
|
||||
<td class="number"><input type="text" name="<c:out value="${equip.code2}" />_cnt" value="<c:out value="${equip.eu_cnt}" />"></td>
|
||||
<td class="text"><textarea rows="" cols="" name="<c:out value="${equip.code2}" />_detail"><c:out value="${equip.eu_detail}" /></textarea></td>
|
||||
<td class="number"><input type="text" name="<c:out value="${equip.code2}" />_check" value="<c:out value="${equip.eu_check}" />"></td>
|
||||
<td class="data"><input type="text" name="<c:out value="${equip.code2}" />_state" value="<c:out value="${equip.eu_state}" />"></td>
|
||||
</tr>
|
||||
</c:forEach>
|
||||
</tbody>
|
||||
|
|
|
|||
|
|
@ -43,11 +43,11 @@
|
|||
<c:when test="${fn:length(useStateList) > 0}">
|
||||
<c:forEach var="result" items="${useStateList}" varStatus="status">
|
||||
<tr>
|
||||
<td align="center"><c:out value="${result.CODENM}" /></td>
|
||||
<td align="center"><c:out value="${result.EU_CNT}" /></td>
|
||||
<td align="center"><c:out value="${empty fn:trim(result.EU_DETAIL) ? '해당사항 없음.' : result.EU_DETAIL}" /></td>
|
||||
<td align="center"><c:out value="${result.EU_CHECK}" /></td>
|
||||
<td align="center"><c:out value="${empty fn:trim(result.EU_STATE) ? '-' : result.EU_STATE}" /></td>
|
||||
<td align="center"><c:out value="${result.codenm}" /></td>
|
||||
<td align="center"><c:out value="${result.eu_cnt}" /></td>
|
||||
<td align="center"><c:out value="${empty fn:trim(result.eu_detail) ? '해당사항 없음.' : result.eu_detail}" /></td>
|
||||
<td align="center"><c:out value="${result.eu_check}" /></td>
|
||||
<td align="center"><c:out value="${empty fn:trim(result.eu_state) ? '-' : result.eu_state}" /></td>
|
||||
</tr>
|
||||
</c:forEach>
|
||||
</c:when>
|
||||
|
|
|
|||
|
|
@ -41,7 +41,7 @@
|
|||
<li class="form_search margin-left">
|
||||
<form:select path="year" cssClass="use">
|
||||
<c:forEach var="item" items="${equipStatusYearList}" varStatus="status">
|
||||
<form:option value="${item.UYEAR}" label="${item.UYEAR}년"/>
|
||||
<form:option value="${item.uyear}" label="${item.uyear}년"/>
|
||||
</c:forEach>
|
||||
</form:select>
|
||||
</li>
|
||||
|
|
@ -85,60 +85,60 @@
|
|||
<tr>
|
||||
<th align="center"><spring:message code="equip.name" /></th>
|
||||
<th align="center"><spring:message code="equip.total" /></th>
|
||||
<th align="center"><spring:message code="equip.PS00" /></th>
|
||||
<th align="center"><spring:message code="equip.PS01" /></th>
|
||||
<th align="center"><spring:message code="equip.PS02" /></th>
|
||||
<th align="center"><spring:message code="equip.PS03" /></th>
|
||||
<th align="center"><spring:message code="equip.PS04" /></th>
|
||||
<th align="center"><spring:message code="equip.PS05" /></th>
|
||||
<th align="center"><spring:message code="equip.PS06" /></th>
|
||||
<th align="center"><spring:message code="equip.PS07" /></th>
|
||||
<th align="center"><spring:message code="equip.PS08" /></th>
|
||||
<th align="center"><spring:message code="equip.PS09" /></th>
|
||||
<th align="center"><spring:message code="equip.PS10" /></th>
|
||||
<th align="center"><spring:message code="equip.PS11" /></th>
|
||||
<th align="center"><spring:message code="equip.PS12" /></th>
|
||||
<th align="center"><spring:message code="equip.PS13" /></th>
|
||||
<th align="center"><spring:message code="equip.PS14" /></th>
|
||||
<th align="center"><spring:message code="equip.PS15" /></th>
|
||||
<th align="center"><spring:message code="equip.PS16" /></th>
|
||||
<th align="center"><spring:message code="equip.PS17" /></th>
|
||||
<th align="center"><spring:message code="equip.PS18" /></th>
|
||||
<th align="center"><spring:message code="equip.PS90" /></th>
|
||||
<th align="center"><spring:message code="equip.PS91" /></th>
|
||||
<th align="center"><spring:message code="equip.PS92" /></th>
|
||||
<th align="center"><spring:message code="equip.PS93" /></th>
|
||||
<th align="center"><spring:message code="equip.PS94" /></th>
|
||||
<th align="center"><spring:message code="equip.ps00" /></th>
|
||||
<th align="center"><spring:message code="equip.ps01" /></th>
|
||||
<th align="center"><spring:message code="equip.ps02" /></th>
|
||||
<th align="center"><spring:message code="equip.ps03" /></th>
|
||||
<th align="center"><spring:message code="equip.ps04" /></th>
|
||||
<th align="center"><spring:message code="equip.ps05" /></th>
|
||||
<th align="center"><spring:message code="equip.ps06" /></th>
|
||||
<th align="center"><spring:message code="equip.ps07" /></th>
|
||||
<th align="center"><spring:message code="equip.ps08" /></th>
|
||||
<th align="center"><spring:message code="equip.ps09" /></th>
|
||||
<th align="center"><spring:message code="equip.ps10" /></th>
|
||||
<th align="center"><spring:message code="equip.ps11" /></th>
|
||||
<th align="center"><spring:message code="equip.ps12" /></th>
|
||||
<th align="center"><spring:message code="equip.ps13" /></th>
|
||||
<th align="center"><spring:message code="equip.ps14" /></th>
|
||||
<th align="center"><spring:message code="equip.ps15" /></th>
|
||||
<th align="center"><spring:message code="equip.ps16" /></th>
|
||||
<th align="center"><spring:message code="equip.ps17" /></th>
|
||||
<th align="center"><spring:message code="equip.ps18" /></th>
|
||||
<th align="center"><spring:message code="equip.ps90" /></th>
|
||||
<th align="center"><spring:message code="equip.ps91" /></th>
|
||||
<th align="center"><spring:message code="equip.ps92" /></th>
|
||||
<th align="center"><spring:message code="equip.ps93" /></th>
|
||||
<th align="center"><spring:message code="equip.ps94" /></th>
|
||||
</tr>
|
||||
</thead>
|
||||
<c:forEach var="equipStatus" items="${equipStatusList}" varStatus="status">
|
||||
<tr>
|
||||
<td align="center"><c:out value="${equipStatus.GUBUN}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.TOTAL}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.PS00}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.PS01}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.PS02}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.PS03}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.PS04}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.PS05}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.PS06}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.PS07}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.PS08}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.PS09}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.PS10}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.PS11}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.PS12}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.PS13}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.PS14}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.PS15}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.PS16}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.PS17}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.PS18}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.PS90}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.PS91}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.PS92}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.PS93}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.PS94}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.gubun}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.total}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.ps00}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.ps01}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.ps02}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.ps03}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.ps04}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.ps05}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.ps06}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.ps07}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.ps08}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.ps09}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.ps10}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.ps11}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.ps12}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.ps13}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.ps14}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.ps15}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.ps16}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.ps17}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.ps18}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.ps90}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.ps91}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.ps92}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.ps93}" /></td>
|
||||
<td align="center"><c:out value="${equipStatus.ps94}" /></td>
|
||||
</tr>
|
||||
</c:forEach>
|
||||
</table>
|
||||
|
|
|
|||
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue