修改单位管理
This commit is contained in:
1 parent
bf6c516bb6
commit
38873a5206
18 files changed
+748
-601
No files matched your search
@@ -24,8 +24,48 @@
|
||||
{block name="form"}{/block}
|
||||
</div>
|
||||
{block name="myjs"}{/block}
|
||||
<script type="text/javascript">
|
||||
|
||||
</script>
|
||||
<script>
|
||||
layui.use(['form'], function(){
|
||||
var form = layui.form;
|
||||
|
||||
//监听提交
|
||||
form.on('submit(mysubmit)', function(data){
|
||||
$.ajax({
|
||||
url:"{$list.set.url}",
|
||||
type:"{$list.set.formpost}",
|
||||
data:data.field,
|
||||
dataType:'json',
|
||||
success:function(result){
|
||||
|
||||
if(result.val === 1)
|
||||
{
|
||||
//先得到当前iframe层的索引
|
||||
var index = parent.layer.getFrameIndex(window.name);
|
||||
//再执行关闭
|
||||
parent.layer.close(index);
|
||||
|
||||
parent.layui.table.reload('mytable');
|
||||
}
|
||||
// 弹出提示
|
||||
parent.layer.msg(result.msg,
|
||||
{
|
||||
icon:1,
|
||||
time:2000
|
||||
});
|
||||
},
|
||||
error:function(xhr,status,error) {
|
||||
layer.msg('数据处理错误',{
|
||||
icon: 1,
|
||||
time: 2000 //2秒关闭(如果不配置,默认是3秒)
|
||||
});
|
||||
}
|
||||
});
|
||||
return false;
|
||||
});
|
||||
|
||||
});
|
||||
|
||||
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
@@ -29,7 +29,7 @@
|
||||
<div class="x-body">
|
||||
<div class="layui-collapse">
|
||||
<div class="layui-colla-item">
|
||||
<h2 class="layui-colla-title">查询条件</h2>
|
||||
<h2 class="layui-colla-title">筛选</h2>
|
||||
<div class="layui-colla-content layui-hidden">
|
||||
<div class="layui-row">
|
||||
{block name="search"}{/block}
|
||||
@@ -37,7 +37,6 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{block name="table"}{/block}
|
||||
</div>
|
||||
<script type="text/html" id="status">
|
||||
@@ -97,18 +96,18 @@
|
||||
}
|
||||
|
||||
/*删除*/
|
||||
function del(obj,id,url){
|
||||
function del(obj,url){
|
||||
layer.confirm('确认要删除吗?',function(index){
|
||||
$.ajax({
|
||||
url:url+'/m',
|
||||
type:'DELETE',
|
||||
data:{
|
||||
ids:id
|
||||
ids:obj.data.id
|
||||
},
|
||||
success:function(result){
|
||||
if(result.val == 1)
|
||||
{
|
||||
$(obj).del();
|
||||
obj.del();
|
||||
layer.msg('已删除!');
|
||||
}else{
|
||||
layer.msg('数据处理错误!',function(){});
|
||||
@@ -173,6 +172,12 @@
|
||||
x_admin_show(title,url,width,height,max);
|
||||
}
|
||||
|
||||
// 提交表单
|
||||
function submitform(formname)
|
||||
{
|
||||
$('#'+formname).submit();
|
||||
// layer.msg('aa');
|
||||
}
|
||||
</script>
|
||||
{block name="myjs"}{/block}
|
||||
</body>
|
||||
|
||||
@@ -25,7 +25,7 @@ class YanZheng extends Controller
|
||||
if( strlen($username)<1 )
|
||||
{
|
||||
// $this->redirect('/login',302);
|
||||
echo "<script>top.location.href='login';</script>";
|
||||
echo "<script>top.location.href='/login';</script>";
|
||||
}
|
||||
|
||||
// 检验用户名或密码是否正确
|
||||
|
||||
Loaded 3 of 18 files, more files were not shown because too many files have changed in this diff.
Show more
Reference in new issue
Block a user