Files
SIPAIIS_WMS_JSSW/WebRoot/jsp/report/rptInfoSetAddSimple.jsp
2026-01-16 14:13:44 +08:00

171 lines
6.3 KiB
Plaintext
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<%@ page language="java" pageEncoding="UTF-8" %>
<%@ taglib uri="http://java.sun.com/jstl/core_rt" prefix="c" %>
<%@page import="com.sipai.entity.report.RptInfoSet" %>
<% request.setAttribute("RptType_Day", RptInfoSet.RptType_Day); %>
<% request.setAttribute("RptType_Week", RptInfoSet.RptType_Week); %>
<% request.setAttribute("RptType_Tenday", RptInfoSet.RptType_Tenday); %>
<% request.setAttribute("RptType_Month", RptInfoSet.RptType_Month); %>
<% request.setAttribute("RptType_Quarterly", RptInfoSet.RptType_Quarterly); %>
<% request.setAttribute("RptType_Year", RptInfoSet.RptType_Year); %>
<%request.setAttribute("TYPE_CATALOGUE", RptInfoSet.TYPE_CATALOGUE);%>
<%request.setAttribute("TYPE_SETTING", RptInfoSet.TYPE_SETTING);%>
<style type="text/css">
.select2-container .select2-selection--single {
height: 34px;
line-height: 34px;
}
.select2-selection__arrow {
margin-top: 3px;
}
</style>
<script type="text/javascript">
var masterId_process = '${id}';//业务Id
var tbName_process = 'TB_Report_RptInfoSetFile'; //数据表
var nameSpace_process = 'Report';//保存文件夹
var status = 'delete';//有删除权限
var showUser4SelectsFun1 = function () {
var userIds = $("#checkuser").val();
$.post(ext.contextPath + '/user/userForSelect.do', {
formId: "subForm",
hiddenId: "checkuser",
textId: "auditMan1",
userIds: userIds
}, function (data) {
$("#user4SelectDiv").html(data);
openModal("user4SelectModal");
});
};
var showUser4SelectsFun2 = function () {
var userIds = $("#createusers").val();
$.post(ext.contextPath + '/user/userForSelect.do', {
formId: "subForm",
hiddenId: "createusers",
textId: "auditMan2",
userIds: userIds
}, function (data) {
$("#user4SelectDiv").html(data);
openModal("user4SelectModal");
});
};
var showUser4SelectsFun3 = function () {
var userIds = $("#browseusers").val();
$.post(ext.contextPath + '/user/userForSelect.do', {
formId: "subForm",
hiddenId: "browseusers",
textId: "auditMan3",
userIds: userIds
}, function (data) {
$("#user4SelectDiv").html(data);
openModal("user4SelectModal");
});
};
function dosave() {
$("#subForm").bootstrapValidator('validate');//提交验证
if ($("#subForm").data('bootstrapValidator').isValid()) {//获取验证结果,如果成功,执行下面代码
$.post(ext.contextPath + "/report/rptInfoSet/dosave.do", $("#subForm").serialize(), function (result) {
if (result.code == 1) {
initTreeView();
//showAlert('s','保存成功');
} else {
showAlert('d', '保存失败');
}
}, 'json');
}
}
$("#subForm").bootstrapValidator({
live: 'disabled',//验证时机enabled是内容有变化就验证默认disabled和submitted是提交再验证
fields: {
name: {
validators: {
notEmpty: {
message: '名称不能为空'
}
}
},
morder: {
validators: {
notEmpty: {
message: '顺序不能为空'
},
regexp: {
regexp: /^[0-9]*$/,
message: '顺序必须为数字'
}
}
}
}
});
$(function () {
//初始化文件显示
getFileList_process();
//默认不审核
$('#checkDivId').hide();
});
//是否审核 不审核则不显示 “可审核报表用户” 框
$('#checkst').on('change', function () {
var val = $(this).val();
if (val == '是') {
$('#checkDivId').show();
}
if (val == '否') {
$('#checkDivId').hide();
}
});
</script>
<div class="box box-primary">
<div class="box-header with-border">
<h3 class="box-title">新增</h3>
<div class="box-tools pull-right">
<a onclick="dosave()" class="btn btn-box-tool" data-toggle="tooltip" title="保存"><i
class="glyphicon glyphicon-floppy-disk"></i></a>
</div>
</div>
<!-- /.box-header -->
<div class="box-body ">
<form class="form-horizontal " id="subForm">
<input id="id" name="id" type="hidden" value="${id}"/>
<input id="unitId" name="unitId" type="hidden" value="${param.unitId}"/>
<input type="hidden" id="type" name="type" value="${TYPE_CATALOGUE}">
<!-- 界面提醒div强制id为alertDiv -->
<div id="alertDiv"></div>
<div id="menu4SelectDiv"></div>
<div class="form-group">
<label class="col-sm-2 control-label">报表类型</label>
<div class="col-sm-4">
<input type="text" class="form-control" id="name" name="name" placeholder="报表名称"
value="${rptInfoSet.name }" autocomplete="off">
</div>
<label class="col-sm-2 control-label">上级菜单</label>
<div class="col-sm-4">
<input type="text" class="form-control" id="pname" name="pname" placeholder="上级菜单"
onclick="showMenu4SelectFun()" value="${pname}">
<input id="pid" name="pid" type="hidden" value="${pid}"/>
</div>
</div>
<div class="form-group">
<label class="col-sm-2 control-label">顺序</label>
<div class="col-sm-4">
<input type="number" class="form-control" id="morder" name="morder" placeholder="顺序"
value="${rptInfoSet.morder }" autocomplete="off">
</div>
</div>
<input id="checkuser" name="checkuser" type="hidden"/>
<input id="createusers" name="createusers" type="hidden"/>
<input id="browseusers" name="browseusers" type="hidden"/>
</form>
</div>
</div>