Merge branch 'jsp'
This commit is contained in:
commit
db1e29ddb9
@ -11,6 +11,7 @@ import org.springframework.stereotype.Controller;
|
|||||||
import org.springframework.ui.ModelMap;
|
import org.springframework.ui.ModelMap;
|
||||||
import org.springframework.web.bind.annotation.ModelAttribute;
|
import org.springframework.web.bind.annotation.ModelAttribute;
|
||||||
import org.springframework.web.bind.annotation.RequestMapping;
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
|
import org.springframework.web.servlet.ModelAndView;
|
||||||
|
|
||||||
import egovframework.rte.ptl.mvc.tags.ui.pagination.PaginationInfo;
|
import egovframework.rte.ptl.mvc.tags.ui.pagination.PaginationInfo;
|
||||||
import itn.let.kakao.admin.kakaoAt.service.MjonKakaoAtStatVO;
|
import itn.let.kakao.admin.kakaoAt.service.MjonKakaoAtStatVO;
|
||||||
@ -61,4 +62,31 @@ public class KakaoStatisticsController {
|
|||||||
return "/uss/ion/kakaoat/KakaoAtSendStatistics";
|
return "/uss/ion/kakaoat/KakaoAtSendStatistics";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// 알림톡 발송 통계
|
||||||
|
@RequestMapping(value = "/uss/ion/kakao/insertKakaoAtCountStatApiAjax.do")
|
||||||
|
public ModelAndView insertKakaoAtCountStatApiAjax(
|
||||||
|
@ModelAttribute("kakaoAtStatVO") MjonKakaoAtStatVO kakaoAtStatVO) throws Exception {
|
||||||
|
|
||||||
|
ModelAndView modelAndView = new ModelAndView();
|
||||||
|
modelAndView.setViewName("jsonView");
|
||||||
|
|
||||||
|
boolean isSuccess = true;
|
||||||
|
String msg = "";
|
||||||
|
|
||||||
|
try {
|
||||||
|
|
||||||
|
kakaoStatisticsService.insertKakaoAtCountStat(kakaoAtStatVO);
|
||||||
|
|
||||||
|
}
|
||||||
|
catch(Exception e) {
|
||||||
|
isSuccess = false;
|
||||||
|
msg = e.getMessage();
|
||||||
|
}
|
||||||
|
|
||||||
|
modelAndView.addObject("isSuccess", isSuccess);
|
||||||
|
modelAndView.addObject("msg", msg);
|
||||||
|
|
||||||
|
return modelAndView;
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@ -96,6 +96,43 @@
|
|||||||
form.submit();
|
form.submit();
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// 오늘날짜
|
||||||
|
function getTodayDate() {
|
||||||
|
var today = new Date();
|
||||||
|
|
||||||
|
var year = today.getFullYear();
|
||||||
|
var month = ('0' + (today.getMonth() + 1)).slice(-2);
|
||||||
|
var day = ('0' + today.getDate()).slice(-2);
|
||||||
|
|
||||||
|
var dateString = year + month + day;
|
||||||
|
|
||||||
|
return dateString;
|
||||||
|
}
|
||||||
|
|
||||||
|
// 당일 데이터 업데이트
|
||||||
|
function setTodayUpdate() {
|
||||||
|
var url = "/uss/ion/kakao/insertKakaoAtCountStatApiAjax.do?statStartDate=" + getTodayDate() + "&statEndDate=" + getTodayDate();
|
||||||
|
|
||||||
|
$.ajax({
|
||||||
|
type: "POST",
|
||||||
|
url: url,
|
||||||
|
data: {},
|
||||||
|
dataType:'json',
|
||||||
|
async: true,
|
||||||
|
success: function (data) {
|
||||||
|
if (data.isSuccess) {
|
||||||
|
location.reload();
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
alert("Msg : " + data.msg);
|
||||||
|
}
|
||||||
|
},
|
||||||
|
error: function (e) {
|
||||||
|
alert("ERROR : " + JSON.stringify(e));
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
</script>
|
</script>
|
||||||
<style type="text/css">
|
<style type="text/css">
|
||||||
.pageCont .listTop {padding:0 0 10px;font-weight:700;text-align:right;}
|
.pageCont .listTop {padding:0 0 10px;font-weight:700;text-align:right;}
|
||||||
@ -166,6 +203,8 @@
|
|||||||
<input type="button" class="btnType1" onclick="fn_list_search(); return false;" value="검색">
|
<input type="button" class="btnType1" onclick="fn_list_search(); return false;" value="검색">
|
||||||
</div>
|
</div>
|
||||||
<div class="listTop">
|
<div class="listTop">
|
||||||
|
<input type="button" style="cursor: pointer;" onclick="setTodayUpdate();" value="Today Update">
|
||||||
|
|
||||||
(부가세 별도)
|
(부가세 별도)
|
||||||
</div>
|
</div>
|
||||||
<div class="tableWrap">
|
<div class="tableWrap">
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user