1. jQuery 下拉菜单
$.ajax({
url:basePath + "/resources/js/jquery.cxselect/cityData.min.json",
success:function(data){
$('#element_id').cxSelect({
url : data,
selects : [ 'province', 'city' ],
nodata : 'none'
});
placeSign();
}
});
2. 销假流程的ajax
$.ajax({
type: "POST",
url: basePath + "workflow/oa/leaveBack/startLeaveBack.htmls",
data: {
"serialNumber": serialNumber,
"leaveBackStartDate": startDate,
"leaveBackEndDate": endDate,
"leaveDay": leaveDays,
"leaveTime": leaveHours
},
dataType: "json",
success: function(result) {
if("loginAgain" == result.msg) {
setTimeout(function(){
window.location=basePath+"admin/employee/login.htmls";
},100);
} else {
setTimeout(function(){
window.location=basePath+"workflow/process/start.htmls";
},100);
}
if("reApply" == result.msg) {
alert("请勿重复提交表单");
}
}
})
后台处理代码
@RequestMapping(value = "/startLeaveBack", method = RequestMethod.POST)
@ResponseBody
public Message startLeaveBack(HttpSession session, CancelLeaveVO cancelLeaveVO) {
Message msg = new M