init
Showing
1 changed file
with
25 additions
and
1 deletions
| ... | @@ -122,7 +122,31 @@ | ... | @@ -122,7 +122,31 @@ |
| 122 | btn: ['确认','取消'], | 122 | btn: ['确认','取消'], |
| 123 | title: '删除网查' | 123 | title: '删除网查' |
| 124 | }, function(){ | 124 | }, function(){ |
| 125 | layer_load('应用工具', '<?=site_url("tool/web")?>'); | 125 | $.ajax({ |
| 126 | type:'delete', | ||
| 127 | url:apiBaseUrl + id, | ||
| 128 | cache: false, | ||
| 129 | data:JSON.stringify(data), | ||
| 130 | dataType:'json', | ||
| 131 | contentType: "application/json; charset=UTF-8", | ||
| 132 | success:function(data){ | ||
| 133 | if(data.msg){ | ||
| 134 | layer.alert(data.msg); | ||
| 135 | } else if(data.code != 0){ | ||
| 136 | layer.alert('请求失败'); | ||
| 137 | } else { | ||
| 138 | layer.msg('删除成功'); | ||
| 139 | setTimeout(function () { | ||
| 140 | layer_load('应用工具', '<?=site_url("tool/web")?>'); | ||
| 141 | },500); | ||
| 142 | } | ||
| 143 | |||
| 144 | }, | ||
| 145 | error:function(){ | ||
| 146 | layer.alert("请求失败") | ||
| 147 | } | ||
| 148 | }) | ||
| 149 | |||
| 126 | }); | 150 | }); |
| 127 | } | 151 | } |
| 128 | </script> | 152 | </script> | ... | ... |
-
Please register or sign in to post a comment