refactor: 공통 사용 메소드 refactoring

- 폐기관리 상세 정보 목록 조회 AddsNimsService로 이종
dev
Jonguk. Lim 4 months ago
parent e3aa2f93dc
commit 8f620d6660

@ -0,0 +1,10 @@
package cokr.xit.adds.nims.service;
import java.util.List;
import cokr.xit.adds.nims.DsuseMgtDetailQuery;
import cokr.xit.foundation.data.DataObject;
public interface AddsNimsService {
List<DataObject> getDsuseMgtDetailList(DsuseMgtDetailQuery query);
}

@ -1,20 +0,0 @@
package cokr.xit.adds.nims.service;
import java.util.List;
import java.util.Map;
import cokr.xit.adds.nims.DsuseMgtDetailQuery;
import cokr.xit.foundation.data.DataObject;
public interface DsuseMgtDetailService {
/** .
* @param query
* <ul><li>pageNum: </li>
* <li>fetchSize: </li>
* </ul>
* @return
*/
List<DataObject> getDsuseMgtDetailList(DsuseMgtDetailQuery query);
}

@ -0,0 +1,25 @@
package cokr.xit.adds.nims.service.bean;
import java.util.List;
import javax.annotation.Resource;
import org.springframework.stereotype.Service;
import cokr.xit.adds.nims.DsuseMgtDetailQuery;
import cokr.xit.adds.nims.dao.DsuseMgtDetailMapper;
import cokr.xit.adds.nims.service.AddsNimsService;
import cokr.xit.foundation.component.AbstractServiceBean;
import cokr.xit.foundation.data.DataObject;
@Service("addsNimsService")
public class AddsNimsServiceBean extends AbstractServiceBean implements AddsNimsService {
/** 폐기관리상세 정보 DAO */
@Resource(name = "dsuseMgtDetailMapper")
private DsuseMgtDetailMapper dsuseMgtDetailMapper;
@Override
public List<DataObject> getDsuseMgtDetailList(DsuseMgtDetailQuery query){
return dsuseMgtDetailMapper.selectDsuseMgtDetailList(query);
}
}

@ -1,30 +0,0 @@
package cokr.xit.adds.nims.service.bean;
import java.util.ArrayList;
import java.util.Iterator;
import java.util.List;
import java.util.Map;
import javax.annotation.Resource;
import org.springframework.stereotype.Service;
import cokr.xit.adds.nims.DsuseMgtDetailQuery;
import cokr.xit.adds.nims.dao.DsuseMgtDetailMapper;
import cokr.xit.adds.nims.service.DsuseMgtDetailService;
import cokr.xit.foundation.component.AbstractServiceBean;
import cokr.xit.foundation.data.DataObject;
@Service("dsuseMgtDetailService")
public class DsuseMgtDetailServiceBean extends AbstractServiceBean implements DsuseMgtDetailService {
/** 폐기관리상세 정보 DAO */
@Resource(name = "dsuseMgtDetailMapper")
private DsuseMgtDetailMapper dsuseMgtDetailMapper;
@Override
public List<DataObject> getDsuseMgtDetailList(DsuseMgtDetailQuery query){
return dsuseMgtDetailMapper.selectDsuseMgtDetailList(query);
}
}

@ -33,8 +33,10 @@ import cokr.xit.adds.cmm.model.DsuseRsltInfo;
import cokr.xit.adds.cmm.model.NimsApiRequest;
import cokr.xit.adds.cmmn.hwp.format.DisposeProcessDetails;
import cokr.xit.adds.cmmn.hwp.format.DisposeResultReport;
import cokr.xit.adds.nims.DsuseMgtDetailQuery;
import cokr.xit.adds.nims.DsuseMgtDocQuery;
import cokr.xit.adds.nims.DsuseMgtReceiptQuery;
import cokr.xit.adds.nims.service.AddsNimsService;
import cokr.xit.adds.nims.service.DsuseMgtDocService;
import cokr.xit.adds.nims.service.DsuseMgtReceiptService;
import cokr.xit.applib.Print;
@ -81,6 +83,9 @@ public class AddsNimsController extends ApplicationController {
@Resource(name="sigunguDepartmentService")
private SigunguDepartmentService sggDeptService;
@Resource(name="addsNimsService")
private AddsNimsService addsNimsService;
@Resource(name="dsuseMgtReceiptService")
private DsuseMgtReceiptService dsuseMgtReceiptService;
@ -91,6 +96,21 @@ public class AddsNimsController extends ApplicationController {
private FileService fileService;
private JSON json = new JSON();
//-------------------------------------------------------------------------------------------------
// 공통 - 폐기관리 상세 목록
//-------------------------------------------------------------------------------------------------
@RequestMapping(name="폐기관리 상세 목록 조회", value= "/dsuseMgtDetail-list.do")
public ModelAndView getDsuseMgtList(DsuseMgtDetailQuery query) {
return setCollectionInfo(new ModelAndView("jsonView"), addsNimsService.getDsuseMgtDetailList(query),"","dsuseMgtDetail");
}
//-------------------------------------------------------------------------------------------------
// 공통 - 폐기관리 상세 목록
//-------------------------------------------------------------------------------------------------
//-------------------------------------------------------------------------------------------------
// 신청서 접수
//-------------------------------------------------------------------------------------------------

@ -1,61 +0,0 @@
package cokr.xit.adds.nims.web;
import javax.annotation.Resource;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.servlet.ModelAndView;
import com.fasterxml.jackson.core.JsonProcessingException;
import cokr.xit.adds.nims.DsuseMgtDetailQuery;
import cokr.xit.adds.nims.service.DsuseMgtDetailService;
import cokr.xit.base.web.ApplicationController;
import net.minidev.json.parser.ParseException;
@Controller
@RequestMapping(
name = "마약류폐기 신청 상세",
value = {"/adds/nims"}
)
public class DsuseMgtDetailController extends ApplicationController {
public static final String CLASS_URL = "/adds/nims";
public class METHOD_URL {
public static final String
dsuseMgtDetailMain = "/dsuseMgt-info.do" // 부과 제외 관리 메인 화면
, getDsuseMgtDetailList = "/dsuseMgtDetail-list.do" // 부과 제외 대장 목록 조회
// , getLevyExclusionInfo = "/020/info.do" // 부과 제외 대장 조회
// , createLevyExclusion = "/020/create.do" // 부과 제외 대장 등록
;
}
@Resource(name="dsuseMgtDetailService")
private DsuseMgtDetailService dsuseMgtDetailService;
@RequestMapping(name="마약류폐기 신청서 접수 메인", value=METHOD_URL.dsuseMgtDetailMain)
public ModelAndView dsuseMgtMain(String usrRptIdNo) {
ModelAndView mav = new ModelAndView("adds/nims/dsuseMgt-info");
// 사용자 정보
//ManagedUser managedUser = (ManagedUser)currentUser().getUser();
return mav
.addObject("pageName", "dsuseMgtInfo") // View(jsp)에서 사용할 id 뒤에 붙일 suffix
.addObject("infoPrefix", "dsuseMgt") // prefix
.addObject("infoPrefixUrl", "/adds/nims") // prefixUrl
.addObject("usrRptIdNo", usrRptIdNo)
;
}
@RequestMapping(name="마약류폐기 신청서 접수 조회", value=METHOD_URL.getDsuseMgtDetailList)
public ModelAndView getDsuseMgtList(DsuseMgtDetailQuery query) throws JsonProcessingException, ParseException {
return setCollectionInfo(new ModelAndView("jsonView"), dsuseMgtDetailService.getDsuseMgtDetailList(query),"","dsuseMgtDetail");
}
}
Loading…
Cancel
Save