123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778 |
- <%@ page contentType="text/html;charset=UTF-8" %>
- <%@ include file="/WEB-INF/views/include/taglib.jsp"%>
- <html>
- <head>
- <title>广告位管理管理</title>
- <meta name="decorator" content="default"/>
- <script type="text/javascript">
- $(document).ready(function() {
- //$("#name").focus();
- $("#inputForm").validate({
- submitHandler: function(form){
- loading('正在提交,请稍等...');
- form.submit();
- },
- errorContainer: "#messageBox",
- errorPlacement: function(error, element) {
- $("#messageBox").text("输入有误,请先更正。");
- if (element.is(":checkbox")||element.is(":radio")||element.parent().is(".input-append")){
- error.appendTo(element.parent().parent());
- } else {
- error.insertAfter(element);
- }
- }
- });
- });
- /**
- * @param obj
- * jquery控制input只能输入数字
- */
- function onlynum(obj) {
- obj.value = obj.value.replace(/[^\d]/g, ""); //清除"数字"以外的字符
- }
- </script>
- </head>
- <body>
- <ul class="nav nav-tabs">
- <li><a href="${ctx}/newhome/newPageAdvertising/">广告位管理列表</a></li>
- <li class="active"><a href="${ctx}/newhome/newPageAdvertising/form?id=${newPageAdvertising.id}">广告位管理<shiro:hasPermission name="newhome:newPageAdvertising:edit">${not empty newPageAdvertising.id?'编辑':'添加'}</shiro:hasPermission><shiro:lacksPermission name="newhome:newPageAdvertising:edit">查看</shiro:lacksPermission></a></li>
- </ul><br/>
- <form:form id="inputForm" modelAttribute="newPageAdvertising" action="${ctx}/newhome/newPageAdvertising/save" method="post" class="form-horizontal">
- <form:hidden path="id"/>
- <sys:message content="${message}"/>
- <div class="control-group">
- <label class="control-label"><font color="red">*</font>广告标题:</label>
- <div class="controls">
- <form:input path="adTitle" htmlEscape="false" maxlength="40" class="input-xlarge required"/>
- </div>
- </div>
- <div class="control-group">
- <label class="control-label"><font color="red">*</font>上传图片:</label>
- <div class="controls">
- <form:hidden id="adImage" path="adImage" htmlEscape="false" maxlength="255" class="input-xlarge required"/>
- <sys:ckfinder input="adImage" type="images" uploadPath="/photo" selectMultiple="false" maxWidth="100" maxHeight="100"/>
- </div>
- <div class="controls" style="padding-top: 20px;">
- <label style="color:#D0D0D0 ;"></span>广告图大小:180 * 100 / PX</label>
- </div>
- </div>
- <div class="control-group">
- <label class="control-label"><font color="red">*</font>链接:</label>
- <div class="controls">
- <form:input path="link" htmlEscape="false" maxlength="255" class="input-xlarge required"/>
- </div>
- </div>
- <div class="control-group">
- <label class="control-label"><font color="red">*</font>排序:</label>
- <div class="controls">
- <form:input path="sort" htmlEscape="false" maxlength="11" onkeyup="onlynum(this)" class="input-xlarge required"/>
- </div>
- </div>
- <div class="form-actions">
- <shiro:hasPermission name="newhome:newPageAdvertising:edit"><input id="btnSubmit" class="btn btn-primary" type="submit" value="保 存"/> </shiro:hasPermission>
- <input id="btnCancel" class="btn" type="button" value="返 回" onclick="history.go(-1)"/>
- </div>
- </form:form>
- </body>
- </html>
|