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.
272 lines
10 KiB
272 lines
10 KiB
<#include "../../_include/_t.ftl"/>
|
|
<!DOCTYPE html>
|
|
<html>
|
|
<head>
|
|
<title></title>
|
|
<#include "../../_include/_h.ftl"/>
|
|
<#include "../../_include/_l.ftl"/>
|
|
<#include "../../_include/_j.ftl"/>
|
|
<#include "../../_include/_z.ftl"/>
|
|
<#include "../../_include/admin/_c.ftl"/>
|
|
</head>
|
|
<body>
|
|
<div class="page_div">
|
|
<blockquote class="layui-elem-quote">${title}</blockquote>
|
|
<div class="layui-bg-gray page_tools">
|
|
<div class="layui-inline layui-form" style="width:350px;" id="xmp_appId_tips">
|
|
<select id="xmp_appId" lay-filter="xmp_appId_filter">
|
|
<option value="">全部第三方单位</option>
|
|
<#list xmpApp as app>
|
|
<option value="${app.id}">${(app.appName)!'没有维护名称'}</option>
|
|
</#list>
|
|
</select>
|
|
</div>
|
|
<div class="layui-inline" style="width:200px;">
|
|
<input class="layui-input" id="soc0_socName" placeholder="企业单位名称(支持模糊)" autocomplete="off"/>
|
|
</div>
|
|
<button id="soc0_queryBtn" class="layui-btn layui-btn-normal"><i class="layui-icon"></i>查询</button>
|
|
<button id="soc0_resetBtn" class="layui-btn layui-btn-normal"><i class="layui-icon"></i>重置</button>
|
|
</div>
|
|
<table id="xmp_dataTable" lay-filter="xmp_dataTable_filter" lay-size="sm"></table>
|
|
</div>
|
|
<!--添加页面-->
|
|
<div id="xmp_addWin" class="page_win page_win_hide">
|
|
<form id="xmp_addForm" lay-filter="xmp_addForm_filter" class="layui-form">
|
|
<input type="hidden" id="xmp_addForm_appId" name="appId" value=""/>
|
|
<div class="layui-form-item">
|
|
<label class="layui-form-label">所属应用:</label>
|
|
<div class="layui-form-mid"><span id="xmp_addForm_app"></span></div>
|
|
</div>
|
|
<div class="layui-form-item">
|
|
<label class="layui-form-label">规则名称:</label>
|
|
<div class="layui-input-inline" style="width:600px;">
|
|
<input type="text" name="xmpName" class="layui-input" placeholder="请输入规则名称" lay-verify="required" lay-verType="tips" autocomplete="off"/>
|
|
</div>
|
|
</div>
|
|
<div class="layui-form-item">
|
|
<label class="layui-form-label">描述:</label>
|
|
<div class="layui-input-inline" style="width:600px;">
|
|
<input type="text" name="xmpDes" class="layui-input" placeholder="请输入描述" autocomplete="off"/>
|
|
</div>
|
|
</div>
|
|
<div class="layui-form-item">
|
|
<label class="layui-form-label">详情:</label>
|
|
<div class="layui-input-inline">
|
|
<ul id="xmp_addTree" class="ztree"></ul>
|
|
</div>
|
|
</div>
|
|
<div class="layui-form-item">
|
|
<div class="layui-input-block page_btn">
|
|
<button lay-submit class="layui-btn layui-btn-normal" lay-filter="xmp_addForm_filter"><i class="icon_submit"></i>提交数据</button>
|
|
<button id="xmp_addForm_closeBtn" class="layui-btn layui-btn-danger"><i class="icon_cancel"></i>关闭</button>
|
|
</div>
|
|
</div>
|
|
</form>
|
|
</div>
|
|
<!--修改页面-->
|
|
<div id="xmp_updateWin" class="page_win page_win_hide">
|
|
<form id="xmp_updateForm" lay-filter="xmp_updateForm_filter" class="layui-form">
|
|
<input type="hidden" name="id" value=""/>
|
|
<input type="hidden" name="appId" value=""/>
|
|
<div class="layui-form-item">
|
|
<label class="layui-form-label">所属应用:</label>
|
|
<div class="layui-form-mid"><span id="xmp_updateForm_app"></span></div>
|
|
</div>
|
|
<div class="layui-form-item">
|
|
<label class="layui-form-label">规则名称:</label>
|
|
<div class="layui-input-inline" style="width:600px;">
|
|
<input type="text" name="xmpName" class="layui-input" placeholder="请输入规则名称" lay-verify="required" lay-verType="tips" autocomplete="off"/>
|
|
</div>
|
|
</div>
|
|
<div class="layui-form-item">
|
|
<label class="layui-form-label">描述:</label>
|
|
<div class="layui-input-inline" style="width:600px;">
|
|
<input type="text" name="xmpDes" class="layui-input" placeholder="请输入描述" autocomplete="off"/>
|
|
</div>
|
|
</div>
|
|
<div class="layui-form-item">
|
|
<label class="layui-form-label">详情:</label>
|
|
<div class="layui-input-inline">
|
|
<ul id="xmp_updateTree" class="ztree"></ul>
|
|
</div>
|
|
</div>
|
|
<div class="layui-form-item">
|
|
<div class="layui-input-block page_btn">
|
|
<button lay-submit class="layui-btn layui-btn-normal" lay-filter="xmp_updateForm_filter"><i class="icon_submit"></i>保存数据</button>
|
|
<button id="xmp_updateForm_closeBtn" class="layui-btn layui-btn-danger"><i class="icon_cancel"></i>关闭</button>
|
|
</div>
|
|
</div>
|
|
</form>
|
|
</div>
|
|
<script type="text/javascript">
|
|
layuiplus.on(function(){
|
|
layuiplus.init(0);
|
|
//定义窗口变量============
|
|
var xmp_addWin = null;
|
|
var xmp_updateWin = null;
|
|
var soc0_detailWin = null;
|
|
//数据表格=================================================================================
|
|
var xmp_dataTable = table.render({
|
|
elem:"#xmp_dataTable",
|
|
url:"${ctx}/admin/data/xmp/list",
|
|
method:"get",
|
|
cols:[[
|
|
{field:"socName",title:"企业单位名称",unresize:true,width:260,templet:"<div><span title=\"{{d.socName}}\">{{d.socName}}</span></div>"},
|
|
{field:"regionVals",title:"所属行政区划",unresize:true,width:300,templet:"<div><span title=\"{{d.regionVals}}\">{{d.regionVals}}</span></div>"},
|
|
{field:"appName",title:"第三方平台名称",unresize:true,width:350},
|
|
{field:"state",title:"审核状态",unresize:true,width:150},
|
|
{field:"state",title:"审核时间",unresize:true,width:150},
|
|
{title:"操作 ",unresize:true,align:"left",templet:function(d){
|
|
var opt = "<a class=\"layui-btn layui-btn-normal layui-btn-xs\" lay-event=\"opt_detail\">企业单位详情</a> ";
|
|
opt += "<a class=\"layui-btn layui-btn-xs\" lay-event=\"opt_yes\">通过</a> ";
|
|
opt += "<a class=\"layui-btn layui-btn-xs\" lay-event=\"opt_no\">不通过</a> ";
|
|
return opt;
|
|
}}
|
|
]],
|
|
page:{
|
|
layout:["prev","page","next","skip","count","limit"],
|
|
limits:[10,20,30]
|
|
//curr:1,//设定初始页
|
|
//groups:5,//连续页码
|
|
//first:"首页",//不设置为1
|
|
//last:"尾页"//不设置为总页数
|
|
}
|
|
});
|
|
//数据表格每行数据操作监听=================================================================
|
|
table.on("tool(xmp_dataTable_filter)",function(row){//row.data row.event
|
|
if(row.event == "opt_yes"){
|
|
layer.confirm("该第三方添加的单位将在一企一档展示。<br/>如果继续请点击“确定”,否则点击“取消”<br/>是否继续?",{title:"提示",icon:3},function(index){
|
|
$.ajax({
|
|
type:"get",
|
|
url:"${ctx}/admin/data/xmp/is",
|
|
data:{id:row.data.id, xrId:row.data.xrId, is:"1"},
|
|
dataType:"json",
|
|
success:function(data){
|
|
if(data.status == true){
|
|
xmp_dataTable.reload({
|
|
where:{
|
|
xmpApp:$("#xmp_appId").val()
|
|
}
|
|
});
|
|
layer.close(index);
|
|
layer.msg("操作成功",{time:2000});
|
|
}
|
|
}
|
|
});
|
|
});
|
|
}
|
|
if(row.event == "opt_no"){
|
|
layer.confirm("该第三方添加的单位将无法在一企一档展示。<br/>如果继续请点击“确定”,否则点击“取消”<br/>是否继续?",{title:"提示",icon:3},function(index){
|
|
$.ajax({
|
|
type:"get",
|
|
url:"${ctx}/admin/data/xmp/is",
|
|
data:{id:row.data.id, xrId:row.data.xrId, is:"2"},
|
|
dataType:"json",
|
|
success:function(data){
|
|
if(data.status == true){
|
|
xmp_dataTable.reload({
|
|
where:{
|
|
xmpApp:$("#xmp_appId").val()
|
|
}
|
|
});
|
|
layer.close(index);
|
|
layer.msg("操作成功",{time:2000});
|
|
}
|
|
}
|
|
});
|
|
});
|
|
}
|
|
if(row.event == "opt_detail"){
|
|
soc0_detailWin = layer.open({
|
|
type: 2,
|
|
title: "<i class=\"icon_detail\"></i>企业单位详情["+row.data.socName+"]",
|
|
shade:0.3,
|
|
area: ["1400px", "780px"],
|
|
btn: ['通过', '不通过', '取消'],
|
|
yes: function(index, layero){
|
|
layer.confirm("该第三方添加的单位将在一企一档展示。<br/>如果继续请点击“确定”,否则点击“取消”<br/>是否继续?",{title:"提示",icon:3},function(index){
|
|
$.ajax({
|
|
type:"get",
|
|
url:"${ctx}/admin/data/xmp/is",
|
|
data:{id:row.data.id, xrId:row.data.xrId, is:"1"},
|
|
dataType:"json",
|
|
success:function(data){
|
|
if(data.status == true){
|
|
xmp_dataTable.reload({
|
|
where:{
|
|
xmpApp:$("#xmp_appId").val()
|
|
}
|
|
});
|
|
layer.close(index);
|
|
layer.close(soc0_detailWin);
|
|
layer.msg("操作成功",{time:2000});
|
|
}
|
|
}
|
|
});
|
|
});
|
|
},
|
|
btn2: function(index, layero){
|
|
layer.confirm("该第三方添加的单位将无法在一企一档展示。<br/>如果继续请点击“确定”,否则点击“取消”<br/>是否继续?",{title:"提示",icon:3},function(index){
|
|
$.ajax({
|
|
type:"get",
|
|
url:"${ctx}/admin/data/xmp/is",
|
|
data:{id:row.data.id, xrId:row.data.xrId, is:"2"},
|
|
dataType:"json",
|
|
success:function(data){
|
|
if(data.status == true){
|
|
xmp_dataTable.reload({
|
|
where:{
|
|
xmpApp:$("#xmp_appId").val()
|
|
}
|
|
});
|
|
layer.close(index);
|
|
layer.close(soc0_detailWin);
|
|
layer.msg("操作成功",{time:2000});
|
|
}
|
|
}
|
|
});
|
|
});
|
|
},
|
|
btn3: function(index, layero){
|
|
layer.close(index);
|
|
},
|
|
content: "${ctx}/work/social/soc0/window?baseId="+row.data.id+"&groupId="+row.data.relId+"&groupName="+row.data.socName
|
|
});
|
|
}
|
|
});
|
|
//数据表格上面工具栏================================================================================
|
|
form.on("select(xmp_appId_filter)",function(data){
|
|
//console.log(data.value);//得到被选中的值
|
|
xmp_dataTable.reload({
|
|
where:{
|
|
xmpApp:data.value
|
|
}
|
|
});
|
|
});
|
|
|
|
//查询
|
|
$("#soc0_queryBtn").click(function(){
|
|
xmp_dataTable.reload({
|
|
where:{
|
|
socName:$("#soc0_socName").val(),
|
|
xmpApp:$("#xmp_appId").val()
|
|
}
|
|
});
|
|
});
|
|
//重置
|
|
$("#soc0_resetBtn").click(function(){
|
|
$("#soc0_socName").val("");
|
|
$("#xmp_appId").val("");
|
|
xmp_dataTable.reload({
|
|
where:{
|
|
socName:"",
|
|
xmpApp:""
|
|
}
|
|
});
|
|
});
|
|
|
|
});
|
|
|
|
</script>
|
|
</body>
|
|
</html>
|