Browse Source

前端修改

huangzhiyong 8 years ago
parent
commit
a5be9f975f

+ 35 - 35
src/main/webapp/WEB-INF/ehr/jsp/common/indexJs.jsp

@ -408,41 +408,41 @@
    $(function () {
        if (window.history && window.history.pushState) {
            $(window).on('popstate', function () {
                var hashLocation = location.hash;
                var hashSplit = hashLocation.split("#!/");
                var hashName = hashSplit[1];
                if (hashName !== '') {
                    var hash = window.location.hash;
                    if (hash === '') {
                        $.ligerDialog.confirm('是否确认后退登出系统!', function (yes) {
                            if (yes) {
                                $.ajax({ //获取表的字段列表
                                    type: "POST",
                                    url: "${contextRoot}/system/logoutAction",
                                    dataType: "json",
                                    cache: false,
                                    success: function (data) {
                                        if (data.successFlg) {
                                            localStorage.removeItem("userRole");
                                            location.href = "${contextRoot}/"+data.data+"/loginPage";
                                        }
                                        else {
                                            $.ligerDialog.error(data.message);
                                        }
                                    },
                                    error: function (data) {
                                        $.ligerDialog.error("Status:" + data.status + "(" + data.statusText + ")");
                                    }
                                });
                            }
                        });
                    }
                }
            });
            window.history.pushState('forward', null, './indexPage');
        }
        <%--if (window.history && window.history.pushState) {--%>
            <%--$(window).on('popstate', function () {--%>
                <%--var hashLocation = location.hash;--%>
                <%--var hashSplit = hashLocation.split("#!/");--%>
                <%--var hashName = hashSplit[1];--%>
                <%--if (hashName !== '') {--%>
                    <%--var hash = window.location.hash;--%>
                    <%--if (hash === '') {--%>
                        <%--$.ligerDialog.confirm('是否确认后退登出系统!', function (yes) {--%>
                            <%--if (yes) {--%>
                                <%--$.ajax({ //获取表的字段列表--%>
                                    <%--type: "POST",--%>
                                    <%--url: "${contextRoot}/system/logoutAction",--%>
                                    <%--dataType: "json",--%>
                                    <%--cache: false,--%>
                                    <%--success: function (data) {--%>
                                        <%--if (data.successFlg) {--%>
                                            <%--localStorage.removeItem("userRole");--%>
                                            <%--location.href = "${contextRoot}/"+data.data+"/loginPage";--%>
                                        <%--}--%>
                                        <%--else {--%>
                                            <%--$.ligerDialog.error(data.message);--%>
                                        <%--}--%>
                                    <%--},--%>
                                    <%--error: function (data) {--%>
                                        <%--$.ligerDialog.error("Status:" + data.status + "(" + data.statusText + ")");--%>
                                    <%--}--%>
                                <%--});--%>
                            <%--}--%>
                        <%--});--%>
                    <%--}--%>
                <%--}--%>
            <%--});--%>
            <%--window.history.pushState('forward', null, './indexPage');--%>
        <%--}--%>
        isLogin();
        indexPage.init();

+ 2 - 2
src/main/webapp/WEB-INF/ehr/jsp/system/app/appJs.jsp

@ -30,11 +30,11 @@
                    status:appStatus
                },
                columns: [
                    {display: '应用名称', id: 'id', name: 'name', width: '15%'},
                    {display: '英文名', name: 'code', width: '10%'},
                    {display: '图标', name: 'icon', width: '10%',height:'50',align: 'center', render: function (rowdata, rowindex, value) {
                        return ' <div style="vertical-align:middle;"><img  style="width: 50px; height: 50px;"  src="${contextRoot}/app/read/'+ rowdata.icon+'" /></div>';
                    }},
                    {display: '应用名称', id: 'id', name: 'name', width: '15%'},
                    {display: '英文名', name: 'code', width: '10%'},
                    {display: '开发者', name: 'developer', width: '10%'},
                    {display: '状态', name: 'status', width: '10%',align: 'center', render: function (rowdata, rowindex, value) {
                        if(rowdata.status==1 ){