Merge branch 'devs/bap-monitoring' into 'jenkins_with_weblogic'
작업대기 일괄 삭제 로직 추가 See merge request eapim/eapim-admin!14
This commit is contained in:
@@ -144,7 +144,7 @@ $(document).ready(function() {
|
|||||||
autowidth: true,
|
autowidth: true,
|
||||||
viewrecords: true,
|
viewrecords: true,
|
||||||
gridview: true,
|
gridview: true,
|
||||||
/* multiselect: true, */
|
multiselect: true,
|
||||||
rowList: eval('[${rmsDefaultRowList}]'),
|
rowList: eval('[${rmsDefaultRowList}]'),
|
||||||
gridComplete: function (d) {
|
gridComplete: function (d) {
|
||||||
var colModel = $(this).getGridParam("colModel");
|
var colModel = $(this).getGridParam("colModel");
|
||||||
@@ -196,7 +196,7 @@ $(document).ready(function() {
|
|||||||
return false;
|
return false;
|
||||||
});
|
});
|
||||||
|
|
||||||
$("#btn_delete").click(function() {
|
/* $("#btn_delete").click(function() {
|
||||||
var selRowCnt = $("#grid").jqGrid("getGridParam", "selarrrow").length;
|
var selRowCnt = $("#grid").jqGrid("getGridParam", "selarrrow").length;
|
||||||
if ( selRowCnt == 0 ) {
|
if ( selRowCnt == 0 ) {
|
||||||
alert("선택된 작업대기 항목이 없습니다.");
|
alert("선택된 작업대기 항목이 없습니다.");
|
||||||
@@ -233,8 +233,47 @@ $(document).ready(function() {
|
|||||||
list();
|
list();
|
||||||
alert("삭제 되었습니다.");
|
alert("삭제 되었습니다.");
|
||||||
}
|
}
|
||||||
|
}); */
|
||||||
|
|
||||||
|
$("#btn_delete").click(function(){
|
||||||
|
var returnUrl = getReturnUrlForReturn();
|
||||||
|
var arrGridData = new Array();
|
||||||
|
var selRowIds = $("#grid").jqGrid("getGridParam", "selarrrow");
|
||||||
|
|
||||||
|
if(selRowIds.length == 0)
|
||||||
|
{
|
||||||
|
alert("삭제할 작업대기항목을 선택하여 주십시요.");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
console.log("selRowIds : "+selRowIds);
|
||||||
|
if ( confirm( "삭제하시겠습니까?" ) != true ) return;
|
||||||
|
|
||||||
|
for(var i=0;i<selRowIds.length;i++){
|
||||||
|
$("#grid").jqGrid("setCell", selRowIds[i], "CHK", "true");
|
||||||
|
arrGridData.push($("#grid").getRowData(selRowIds[i]));
|
||||||
|
}
|
||||||
|
|
||||||
|
var postData = new Array();
|
||||||
|
postData.push({ name: "cmd" , value:"DELETE_BS03"});
|
||||||
|
postData.push({ name: "gridData" , value:JSON.stringify(arrGridData)});
|
||||||
|
|
||||||
|
$.ajax({
|
||||||
|
type : "POST",
|
||||||
|
url:url,
|
||||||
|
data:postData,
|
||||||
|
success:function(args){
|
||||||
|
alert("삭제되었습니다.");
|
||||||
|
|
||||||
|
goNav(returnUrl);//LIST로 이동
|
||||||
|
},
|
||||||
|
error:function(e){
|
||||||
|
alert("실패 : "+e.responseText);
|
||||||
|
}
|
||||||
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
buttonControl();
|
buttonControl();
|
||||||
init(list);
|
init(list);
|
||||||
});
|
});
|
||||||
@@ -250,8 +289,8 @@ $(document).ready(function() {
|
|||||||
</div><!-- end content_top -->
|
</div><!-- end content_top -->
|
||||||
<div class="content_middle" id="content_middle">
|
<div class="content_middle" id="content_middle">
|
||||||
<div class="search_wrap">
|
<div class="search_wrap">
|
||||||
<%-- <img src="<c:url value="/img/btn_excel.png"/>" id="btn_excel" level="R"/>
|
<%-- <img src="<c:url value="/img/btn_excel.png"/>" id="btn_excel" level="R"/> --%>
|
||||||
<img src="<c:url value="/img/btn_delete.png"/>" alt="" id="btn_delete" level="W" status="DETAIL"/> --%>
|
<img src="<c:url value="/img/btn_delete.png"/>" alt="" id="btn_delete" level="W" status="DETAIL"/>
|
||||||
<img src="<c:url value="/img/btn_search.png"/>" alt="" id="btn_search" level="R" />
|
<img src="<c:url value="/img/btn_search.png"/>" alt="" id="btn_search" level="R" />
|
||||||
</div>
|
</div>
|
||||||
<div class="title">작업대기 관리</div>
|
<div class="title">작업대기 관리</div>
|
||||||
|
|||||||
+51
-31
@@ -7,6 +7,13 @@ import java.util.Map;
|
|||||||
import javax.servlet.http.HttpServletRequest;
|
import javax.servlet.http.HttpServletRequest;
|
||||||
import javax.servlet.http.HttpServletResponse;
|
import javax.servlet.http.HttpServletResponse;
|
||||||
|
|
||||||
|
import com.eactive.eai.rms.bap.tansaction.transactionStatus.BapTransactionStatusService;
|
||||||
|
import com.eactive.eai.rms.common.base.BapBaseAnnotationController;
|
||||||
|
import com.eactive.eai.rms.common.combo.IbatisComboService;
|
||||||
|
import com.eactive.eai.rms.common.util.CamelCaseUtil;
|
||||||
|
import com.eactive.eai.rms.common.vo.JsonPageVo;
|
||||||
|
import com.google.gson.Gson;
|
||||||
|
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.beans.factory.annotation.Qualifier;
|
import org.springframework.beans.factory.annotation.Qualifier;
|
||||||
import org.springframework.stereotype.Controller;
|
import org.springframework.stereotype.Controller;
|
||||||
@@ -14,15 +21,8 @@ import org.springframework.web.bind.annotation.RequestMapping;
|
|||||||
import org.springframework.web.bind.annotation.RequestParam;
|
import org.springframework.web.bind.annotation.RequestParam;
|
||||||
import org.springframework.web.servlet.ModelAndView;
|
import org.springframework.web.servlet.ModelAndView;
|
||||||
|
|
||||||
import com.eactive.eai.rms.bap.tansaction.transactionStatus.BapTransactionStatusService;
|
|
||||||
import com.eactive.eai.rms.common.base.BapBaseAnnotationController;
|
|
||||||
import com.eactive.eai.rms.common.combo.ComboService;
|
|
||||||
import com.eactive.eai.rms.common.combo.IbatisComboService;
|
|
||||||
import com.eactive.eai.rms.common.util.CamelCaseUtil;
|
|
||||||
import com.eactive.eai.rms.common.vo.JsonPageVo;
|
|
||||||
|
|
||||||
@Controller
|
@Controller
|
||||||
public class BapTransactionWaitController extends BapBaseAnnotationController {
|
public class BapTransactionWaitController extends BapBaseAnnotationController {
|
||||||
|
|
||||||
@Autowired
|
@Autowired
|
||||||
@Qualifier("bapTransactionStatusService")
|
@Qualifier("bapTransactionStatusService")
|
||||||
@@ -36,14 +36,15 @@ public class BapTransactionWaitController extends BapBaseAnnotationController {
|
|||||||
private IbatisComboService comboService;
|
private IbatisComboService comboService;
|
||||||
|
|
||||||
@RequestMapping(value = "/bap/transaction/transactionWaitMan.view")
|
@RequestMapping(value = "/bap/transaction/transactionWaitMan.view")
|
||||||
public String viewList(HttpServletRequest request, @RequestParam(value = "cmd", required = false ) String cmd ) throws Exception {
|
public String viewList(HttpServletRequest request, @RequestParam(value = "cmd", required = false) String cmd)
|
||||||
if (cmd == null || "LIST".equals(cmd.toUpperCase())){
|
throws Exception {
|
||||||
|
if (cmd == null || "LIST".equals(cmd.toUpperCase())) {
|
||||||
cmd = "";
|
cmd = "";
|
||||||
} else {
|
} else {
|
||||||
cmd = CamelCaseUtil.converCamelCase(cmd);
|
cmd = CamelCaseUtil.converCamelCase(cmd);
|
||||||
}
|
}
|
||||||
String path = request.getServletPath();
|
String path = request.getServletPath();
|
||||||
return path.split("[.]")[0]+cmd;
|
return path.split("[.]")[0] + cmd;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -56,7 +57,7 @@ public class BapTransactionWaitController extends BapBaseAnnotationController {
|
|||||||
@RequestParam HashMap<String, Object> paramMap) throws Exception {
|
@RequestParam HashMap<String, Object> paramMap) throws Exception {
|
||||||
|
|
||||||
Map<String, Object> map = service.selectList(pageVo.getStartNum(), pageVo.getEndNum(), paramMap);
|
Map<String, Object> map = service.selectList(pageVo.getStartNum(), pageVo.getEndNum(), paramMap);
|
||||||
|
|
||||||
pageVo.setTotalCount((Integer) map.get("totalCount"));
|
pageVo.setTotalCount((Integer) map.get("totalCount"));
|
||||||
|
|
||||||
Map<String, Object> resultMap = new HashMap<String, Object>();
|
Map<String, Object> resultMap = new HashMap<String, Object>();
|
||||||
@@ -65,13 +66,13 @@ public class BapTransactionWaitController extends BapBaseAnnotationController {
|
|||||||
resultMap.put("records", pageVo.getTotalCount());// 전체 레코드건수
|
resultMap.put("records", pageVo.getTotalCount());// 전체 레코드건수
|
||||||
resultMap.put("rows", map.get("list"));
|
resultMap.put("rows", map.get("list"));
|
||||||
|
|
||||||
ModelAndView modelAndView = new ModelAndView("jsonView",resultMap);
|
ModelAndView modelAndView = new ModelAndView("jsonView", resultMap);
|
||||||
return modelAndView;
|
return modelAndView;
|
||||||
}
|
}
|
||||||
|
|
||||||
@RequestMapping(value = "/bap/transaction/transactionWaitMan.json",params = "cmd=DETAIL")
|
@RequestMapping(value = "/bap/transaction/transactionWaitMan.json", params = "cmd=DETAIL")
|
||||||
public ModelAndView selectDetail(HttpServletRequest request,
|
public ModelAndView selectDetail(HttpServletRequest request,
|
||||||
HttpServletResponse response, @RequestParam HashMap<String,Object> param) throws Exception {
|
HttpServletResponse response, @RequestParam HashMap<String, Object> param) throws Exception {
|
||||||
|
|
||||||
HashMap<String, Object> map = service.selectDetail(param);
|
HashMap<String, Object> map = service.selectDetail(param);
|
||||||
|
|
||||||
@@ -80,39 +81,58 @@ public class BapTransactionWaitController extends BapBaseAnnotationController {
|
|||||||
return modelAndView;
|
return modelAndView;
|
||||||
}
|
}
|
||||||
|
|
||||||
@RequestMapping(value = "/bap/transaction/transactionWaitMan.json",params = "cmd=LIST_INIT_COMBO")
|
@RequestMapping(value = "/bap/transaction/transactionWaitMan.json", params = "cmd=LIST_INIT_COMBO")
|
||||||
public ModelAndView initCombo( HttpServletRequest request,
|
public ModelAndView initCombo(HttpServletRequest request,
|
||||||
HttpServletResponse response) throws Exception {
|
HttpServletResponse response) throws Exception {
|
||||||
|
|
||||||
List<Map<String, Object>> bjobBzwkDstcd = comboService.selectListComboForTableWithCode("TSEAIBJ02", "BJOBBZWKDSTCD", "BJOBBZWKNAME");
|
List<Map<String, Object>> bjobBzwkDstcd = comboService.selectListComboForTableWithCode("TSEAIBJ02",
|
||||||
List<Map<String, Object>> osidInstiDstcd = statusService.selectOsidInstiDstcd("");
|
"BJOBBZWKDSTCD", "BJOBBZWKNAME");
|
||||||
// List<Map<String, Object>> svcPrcssNo = comboService.selectListComboForTable("TSEAICM20", "code", "codename","codegroup = 'SVC_PRCSS_NO' ");
|
List<Map<String, Object>> osidInstiDstcd = statusService.selectOsidInstiDstcd("");
|
||||||
//comboService.selectListCombo("SVC_PRCSS_NO");
|
// List<Map<String, Object>> svcPrcssNo =
|
||||||
|
// comboService.selectListComboForTable("TSEAICM20", "code",
|
||||||
|
// "codename","codegroup = 'SVC_PRCSS_NO' ");
|
||||||
|
// comboService.selectListCombo("SVC_PRCSS_NO");
|
||||||
|
|
||||||
Map<String, Object> resultMap = new HashMap<String, Object>();
|
Map<String, Object> resultMap = new HashMap<String, Object>();
|
||||||
|
|
||||||
resultMap.put("bjobBzwkDstcd" , bjobBzwkDstcd);
|
resultMap.put("bjobBzwkDstcd", bjobBzwkDstcd);
|
||||||
resultMap.put("osidInstiDstcd" , osidInstiDstcd);
|
resultMap.put("osidInstiDstcd", osidInstiDstcd);
|
||||||
// resultMap.put("svcPrcssNo" , svcPrcssNo);
|
// resultMap.put("svcPrcssNo" , svcPrcssNo);
|
||||||
|
|
||||||
ModelAndView modelAndView = new ModelAndView("jsonView",resultMap);
|
ModelAndView modelAndView = new ModelAndView("jsonView", resultMap);
|
||||||
return modelAndView;
|
return modelAndView;
|
||||||
}
|
}
|
||||||
|
|
||||||
@RequestMapping(value = "/bap/transaction/transactionWaitMan.json",params = "cmd=UPDATE")
|
@RequestMapping(value = "/bap/transaction/transactionWaitMan.json", params = "cmd=UPDATE")
|
||||||
private String update(HttpServletRequest request,
|
private String update(HttpServletRequest request,
|
||||||
HttpServletResponse response, @RequestParam HashMap<String,Object> map ) throws Exception {
|
HttpServletResponse response, @RequestParam HashMap<String, Object> map) throws Exception {
|
||||||
|
|
||||||
service.update(map);
|
service.update(map);
|
||||||
|
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
@RequestMapping(value = "/bap/transaction/transactionWaitMan.json",params = "cmd=DELETE")
|
|
||||||
|
@RequestMapping(value = "/bap/transaction/transactionWaitMan.json", params = "cmd=DELETE")
|
||||||
private String delete(HttpServletRequest request,
|
private String delete(HttpServletRequest request,
|
||||||
HttpServletResponse response, @RequestParam HashMap<String,Object> map ) throws Exception {
|
HttpServletResponse response, @RequestParam HashMap<String, Object> map) throws Exception {
|
||||||
|
|
||||||
service.delete(map);
|
service.delete(map);
|
||||||
|
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@RequestMapping(value = "/bap/transaction/transactionWaitMan.json", params = "cmd=DELETE_BS03")
|
||||||
|
public ModelAndView deleteBs03(HttpServletRequest request,
|
||||||
|
HttpServletResponse response, String gridData)
|
||||||
|
throws Exception {
|
||||||
|
|
||||||
|
Gson gson = new Gson();
|
||||||
|
@SuppressWarnings("unchecked")
|
||||||
|
HashMap<String, Object>[] list = gson.fromJson(gridData,
|
||||||
|
HashMap[].class);
|
||||||
|
|
||||||
|
service.deleteBs03(list);
|
||||||
|
|
||||||
|
return null;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
+11
@@ -63,4 +63,15 @@ public class BapTransactionWaitService extends BapBaseService {
|
|||||||
//dao.updateBJ08(paramMap);
|
//dao.updateBJ08(paramMap);
|
||||||
dao.delete(paramMap);
|
dao.delete(paramMap);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public void deleteBs03(HashMap<String, Object>[] paramList) throws Exception {
|
||||||
|
|
||||||
|
HashMap<String, Object> map = new HashMap<String, Object>();
|
||||||
|
for (HashMap<String, Object> paramMap : paramList) {
|
||||||
|
map.put("bjobDmndMsgID", paramMap.get("BJOBDMNDMSGID"));
|
||||||
|
map.put("bjobDmndSubMsgID", paramMap.get("BJOBDMNDSUBMSGID"));
|
||||||
|
dao.delete(map);
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
}
|
}
|
||||||
Reference in New Issue
Block a user