| | |
| | | data: parent.powerTreeData, |
| | | isJump: true |
| | | }); |
| | | |
| | | console.log(parent.powerTreeData) |
| | | loadPower(); |
| | | function loadPower(){ |
| | | $.ajax({ |
| | |
| | | form.on('submit(save)', function () { |
| | | var param = []; |
| | | var checkData = tree.getChecked('powerTree'); |
| | | console.log(checkData) |
| | | checkData.map(function (obj) { |
| | | obj.children.map(function (resource) { |
| | | |
| | | //console.log(resource) |
| | | var childrens = []; |
| | | resource.children.map(function (resource) { |
| | | childrens.push(resource.id); |
| | | }); |
| | | if (resource.children) { |
| | | resource.children.map(function (resource) { |
| | | childrens.push(resource.id); |
| | | }); |
| | | } |
| | | var one = { |
| | | 'two': resource.id, |
| | | 'three': childrens |
| | |
| | | success: function (res) { |
| | | if (res.code === 200){ |
| | | parent.layer.closeAll(); |
| | | parent.layer.msg(res.msg); |
| | | } else if (res.code === 403){ |
| | | top.location.href = baseUrl+"/"; |
| | | } else { |