detailjsp

来源:互联网 发布:淘宝肥王书店 编辑:程序博客网 时间:2024/06/05 09:38

 

<%@ page language="java" contentType="text/html; charset=utf-8" pageEncoding="utf-8"%>

<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>

<%@ taglib prefix="form" uri="http://www.springframework.org/tags/form" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">

<html>

<head>

<meta http-equiv="Content-Type" content="text/html; charset=utf-8">

<jsp:include page="../script.jsp"></jsp:include>

<style type="text/css">

</style>

<script type="text/javascript">

$(function(){

$(".text").addClass("ui-widget-content ui-corner-all");

$(".helper").addClass("ui-icon ui-icon-search").button();

$("#startdate").datepicker();

$("#enddate").datepicker();

$("#OutSourcingdetailForm").submit(function(){

$("input.text").trim();

});

$("#btnSave").button();

$("#btnBack").button().click(function(){

window.location.href= "${pageContext.request.contextPath}/employee/${employeeid}/OutSourcing.html";

});

$("#outsourcinghelper").click(function(){

$('#dialog-inputhelper').load('${pageContext.request.contextPath}/common/InputHelper.html',

{

moduleid:"OutSourcing",

titem: ["groupname", "deptno"],

tval: [$('#groupname').val(), $('#deptno').val()],

bitem: ["groupname", "deptno"],

bdisplayid: ["groupname", "deptno"]

}

);

});

});

 

</script>

</head>

<body>

 

<jsp:include page="../header.jsp"></jsp:include>

<h2><c:if test="${isNew}">添加外派信息</c:if><c:if test="${!isNew}">编辑外派信息</c:if></h2>

<form:form id="outSourcingdetailForm" commandName="outSourcingdetailForm" method="POST">

 

外派类型:&nbsp;&nbsp;<form:radiobutton path="outtype" value="外派"/><label>外派</label>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<form:radiobutton path="outtype" value="支援"/><label>支援</label><br>

开始时间:<form:input type="text" id="startdate" path="startdate" class="text" cssErrorClass="text ui-state-error"/><form:errors path="startdate" cssClass="error"/><br>

结束时间:<form:input type="text" id="enddate" path="enddate" class="text" cssErrorClass="text ui-state-error"/><form:errors path="enddate" cssClass="error"/><br>

目的地:&nbsp;&nbsp;&nbsp;<form:input type="text" id="destination" path="destination" class="text" cssErrorClass="text ui-state-error"/><br>

支援部门:<form:input path="groupname"style="width:60px" class="text"/><span id="outsourcinghelper"  class="helper"></span><form:input type="text" id="deptno"path="deptno" style="width:65px" class="text" cssErrorClass="text ui-state-error"/><form:errors path="deptno" cssClass="error"/><br>

<jsp:include page="../messager.jsp"></jsp:include>

<input type="submit" id="btnSave" value="保存"/>

<c:if test="${!isNew}">

<input type="button" id="btnDelete" value="删除"/>

<div id="comfineDialog" title="确认">确定要删除吗?</div>

<script type="text/javascript">

$(function(){

$("#btnDelete").button().click(function(){

$( "#comfineDialog" ).dialog("open");

return false;

});

$("#comfineDialog").dialog({

autoOpen: false,

resizable: false,

height:140,

modal: true,

buttons: {

"删除": function() {

$("input.text").trim();

$("#outSourcingdetailForm")[0].action="${pageContext.request.contextPath}/employee/${outSourcingdetailForm.employeeid}/OutSourcingdetail/${outSourcingdetailForm.outsourcingid}/delete.html";

$("#outSourcingdetailForm").submit();

},

Cancel: function() {

$( this ).dialog( "close" );

}

}

});

});

</script>

</c:if>

<input type="button" id="btnBack" value="返回"/>

<form:hidden path="updatedate"/>

</form:form>

<script type="text/javascript">

</script>

<jsp:include page="../footer.jsp"></jsp:include>

<div id="dialog-inputhelper"></div>

</body>

</html>