You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
135 lines
4.2 KiB
135 lines
4.2 KiB
<!DOCTYPE html>
|
|
<html>
|
|
|
|
<head>
|
|
<meta charset="utf-8">
|
|
<title></title>
|
|
<link rel="stylesheet" href="../../../component/pear/css/pear.css" />
|
|
<style>
|
|
.woo-tool-text-delimiter {
|
|
width: 1px;
|
|
height: 12px;
|
|
background: #EEEEEE;
|
|
display: inline-block;
|
|
margin: 0 6px 0 4px;
|
|
}
|
|
|
|
.woo-theme-color {
|
|
color: #2d8cf0 !important;
|
|
}
|
|
|
|
.woo-tool-span {
|
|
margin: 0 3px;
|
|
position: relative;
|
|
top: -1px;
|
|
cursor: pointer;
|
|
}
|
|
</style>
|
|
</head>
|
|
|
|
<body class="pear-container layui-form">
|
|
|
|
|
|
|
|
<div class="layui-card">
|
|
|
|
<div class="layui-card-body">
|
|
<input type="radio" name="type_id" value="0" title="全部">
|
|
<input type="radio" name="type_id" value="1" title="本市">
|
|
<input type="radio" name="type_id" value="2" title="本区(县)">
|
|
<input type="radio" name="type_id" value="3" title="本单位(校)">
|
|
</div>
|
|
<div class="layui-card-body">
|
|
权限:
|
|
<input type="checkbox" name="" title="查询" lay-skin="primary" checked disabled>
|
|
<input type="checkbox" name="" title="增加" lay-skin="primary">
|
|
<input type="checkbox" name="" title="修改" lay-skin="primary" >
|
|
</div>
|
|
|
|
</div>
|
|
</div>
|
|
|
|
<div class="bottom">
|
|
<div class="button-container">
|
|
<button type="submit" class="pear-btn pear-btn-primary pear-btn-sm" lay-submit="" lay-filter="save">
|
|
<i class="layui-icon layui-icon-ok"></i>
|
|
提交
|
|
</button>
|
|
</div>
|
|
</div>
|
|
|
|
|
|
|
|
<script src="../../../component/layui/layui.js"></script>
|
|
<script src="../../../component/pear/pear.js"></script>
|
|
|
|
<script>
|
|
layui.use(['table', 'form', 'jquery', 'common', 'laytpl'], function () {
|
|
var table = layui.table;
|
|
var form = layui.form;
|
|
var $ = layui.jquery;
|
|
var common = layui.common;
|
|
var laytpl = layui.laytpl;
|
|
|
|
var systemId = GetQueryString("system_id");
|
|
var tablesName = GetQueryString("tables_name");
|
|
|
|
|
|
|
|
form.on('submit(save)', function (data) {
|
|
var value = $('input[name="type_id"]:checked').val();
|
|
//判断是否选中了范围单选框
|
|
if (value == undefined) {
|
|
layer.msg("请选择范围", {
|
|
icon: 2,
|
|
time: 2000
|
|
});
|
|
return false;
|
|
}
|
|
|
|
data.field["system_id"] = systemId;
|
|
data.field["table_names"] = tablesName;
|
|
|
|
$.ajax({
|
|
url: '/dsBase/dataShare/saveSubscribTable',
|
|
data: data.field,
|
|
type: 'post',
|
|
success: function (result) {
|
|
if (result.success) {
|
|
layer.msg("设置成功!", {
|
|
icon: 1,
|
|
time: 1300
|
|
}, function () {
|
|
parent.layer.close(parent.layer.getFrameIndex(window.name));
|
|
parent.layui.table.reload("data-table");
|
|
});
|
|
} else {
|
|
layer.msg(result.message, {
|
|
icon: 2,
|
|
time: 2000
|
|
});
|
|
}
|
|
}
|
|
});
|
|
return false;
|
|
});
|
|
|
|
|
|
|
|
|
|
|
|
|
|
function GetQueryString(name, istop) {
|
|
var reg = new RegExp("(^|&)" + name + "=([^&]*)(&|$)", "i");
|
|
var r = window.location.search.substr(1).match(reg);
|
|
if (typeof (istop) != "undefined") r = top.location.search.substr(1).match(reg);
|
|
|
|
if (r != null) return unescape(r[2]);
|
|
return null;
|
|
}
|
|
|
|
});
|
|
</script>
|
|
</body>
|
|
|
|
</html> |