#
luxiaotao1123
2021-01-26 58758fe8a1a59f0af9e04c8a5f1cf1a7139deb0d
src/main/webapp/views/tag/tag.html
@@ -190,7 +190,7 @@
                    return;
                }
                var ids = checkRows.map(function (d) {
                    return d.authorityId;
                    return d.id;
                });
                doDel({ids: ids});
            }
@@ -274,15 +274,30 @@
            }, function (i) {
                layer.close(i);
                var loadIndex = layer.load(2);
                $.get('../../json/ok.json', {id: obj.data ? obj.data.authorityId : obj.ids}, function (res) {
                    layer.close(loadIndex);
                    if (res.code === 200) {
                        layer.msg(res.msg, {icon: 1});
                        insTb.refresh();
                    } else {
                        layer.msg(res.msg, {icon: 2});
                var ids;
                if (obj.data) {
                    ids = [];
                    ids[0] = obj.data.id;
                } else {
                    ids = obj.ids;
                }
                $.ajax({
                    url: baseUrl+"/tag/delete/auth",
                    headers: {'token': localStorage.getItem('token')},
                    data: {ids: ids},
                    method: 'POST',
                    success: function (res) {
                        layer.close(loadIndex);
                        if (res.code === 200){
                            layer.msg(res.msg, {icon: 1});
                            insTb.refresh();
                        } else if (res.code === 403){
                            top.location.href = baseUrl+"/";
                        } else {
                            layer.msg(res.msg, {icon: 2});
                        }
                    }
                }, 'json');
                })
            });
        }