Showing
1 changed file
with
0 additions
and
5 deletions
| @@ -28,15 +28,11 @@ | @@ -28,15 +28,11 @@ | ||
| 28 | {include file="common/foot"/} | 28 | {include file="common/foot"/} |
| 29 | <script src="/static/common/js/angular.min.js"></script> | 29 | <script src="/static/common/js/angular.min.js"></script> |
| 30 | <script> | 30 | <script> |
| 31 | - var m = angular.module('hd',[]); | ||
| 32 | - m.controller('ctrl',['$scope',function($scope) { | ||
| 33 | - $scope.field = '{$info|raw}'!='null'?{$info|raw}:{title:''}; | ||
| 34 | layui.use(['form', 'layer'], function () { | 31 | layui.use(['form', 'layer'], function () { |
| 35 | var form = layui.form, layer = layui.layer,$= layui.jquery; | 32 | var form = layui.form, layer = layui.layer,$= layui.jquery; |
| 36 | form.on('submit(submit)', function (data) { | 33 | form.on('submit(submit)', function (data) { |
| 37 | loading = layer.load(1,{shade:[0.1,'#fff']}); | 34 | loading = layer.load(1,{shade:[0.1,'#fff']}); |
| 38 | // 提交到方法 默认为本身 | 35 | // 提交到方法 默认为本身 |
| 39 | - data.field.group_id = $scope.field.group_id; | ||
| 40 | $.post("{:url('addagent')}", data.field, function (res) { | 36 | $.post("{:url('addagent')}", data.field, function (res) { |
| 41 | layer.close(loading); | 37 | layer.close(loading); |
| 42 | if (res.code > 0) { | 38 | if (res.code > 0) { |
| @@ -49,5 +45,4 @@ | @@ -49,5 +45,4 @@ | ||
| 49 | }); | 45 | }); |
| 50 | }) | 46 | }) |
| 51 | }); | 47 | }); |
| 52 | - }]); | ||
| 53 | </script> | 48 | </script> |
-
Please register or login to post a comment