| | |
| | | layer.load(2); |
| | | admin.req('api-uaa/clients/' + obj.data.id, {}, function (data) { |
| | | layer.closeAll('loading'); |
| | | layer.msg('成功', {icon: 1, time: 500}); |
| | | layer.msg('成功', {icon: 1, time: 2000}); |
| | | obj.del(); |
| | | }, 'DELETE'); |
| | | }); |
| | |
| | | layer.load(2); |
| | | admin.req('api-uaa/clients/saveOrUpdate', JSON.stringify(data.field), function (data) { |
| | | layer.closeAll('loading'); |
| | | console.log(data); |
| | | if (data.code == 0) { |
| | | layer.msg(data.msg, {icon: 1, time: 500}); |
| | | layer.msg(data.msg, {icon: 1, time: 2000}); |
| | | table.reload('app-table'); |
| | | layer.closeAll('page'); |
| | | } else { |
| | | layer.msg(data.msg, {icon: 2, time: 500}); |
| | | layer.msg(data.msg, {icon: 2, time: 2000}); |
| | | } |
| | | }, $('#app-form').attr('method')); |
| | | return false; |