|
|
@@ -1,630 +0,0 @@
|
|
|
-<%@ page import="ss.WebC" %>
|
|
|
-<%@ page import="ss.serv.ServC" %>
|
|
|
-<%@ page language="java" pageEncoding="UTF-8" isELIgnored="false" %>
|
|
|
-<%@ taglib uri="/ssTag" prefix="ss"%>
|
|
|
-<!DOCTYPE html>
|
|
|
-<html lang="en">
|
|
|
- <head>
|
|
|
- <meta charset="UTF-8" />
|
|
|
- <meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
|
- <script>window.loginStatus="${empty sessionScope['ssUser']?'0':'1'}"</script>
|
|
|
- <ss:skin file='main.css'/>
|
|
|
- <script type="text/javascript" src="/ss/jquery/jquery.js"></script>
|
|
|
- <script type="text/javascript" src="/ss/artdialog/artDialogUtil.js"></script>
|
|
|
- <script type="text/javascript" src="/ss/js/base.js"></script>
|
|
|
- <script> if(!window.wd) var wd={}; if(!wd.display) wd.display={}; wd.display.wdDialogId="1"; if(!wd.app) wd.app={}; wd.app.name='pms';</script>
|
|
|
- <script type="text/javascript" src="/ss/js/masklayer.js"></script>
|
|
|
- <script type="text/javascript" src="/ss/js/wdDialogInit.js"></script>
|
|
|
- <script type="text/javascript" src="/ss/js/common.js"></script>
|
|
|
- <script type="text/javascript" src="/ss/js/display.js"></script>
|
|
|
- <script type="text/javascript" src="/ss/js/edit.js"></script>
|
|
|
- <script type="text/javascript" src="/ss/nicescroll/jquery.nicescroll.js"></script>
|
|
|
- <script type="text/javascript" src="/ss/nicescroll/jquery.nicescroll.iframehelper.min.js"></script>
|
|
|
- <link rel="stylesheet" type="text/css" href="/ss/window/theme/dhtmlxwindows.css">
|
|
|
- <link rel="stylesheet" type="text/css" href="/ss/window/theme/dhx_blue/dhtmlxwindows_dhx_blue.css">
|
|
|
- <script type="text/javascript" src="/ss/window/dhtmlxcommon.js"></script>
|
|
|
- <script type="text/javascript" src="/ss/window/dhtmlxwindows.js"></script>
|
|
|
- <script type="text/javascript" src="/ss/window/dhtmlxcontainer.js"></script>
|
|
|
-
|
|
|
- <%
|
|
|
- if(pageContext.getSession().getAttribute("ssUser")==null){
|
|
|
- /* 再改,去掉 loginExp.ss.jsp(写死错误信息),改用 relogin.ss.jsp。Lin
|
|
|
- request.getRequestDispatcher(WebC.PPATH_loginExp).forward(request,response);
|
|
|
- */
|
|
|
- request.setAttribute(ServC.REQ_msg, WebC.LOGIN_expMsg);
|
|
|
- request.getRequestDispatcher(WebC.PPATH_relogin).forward(request,response);
|
|
|
-
|
|
|
- return;
|
|
|
- }
|
|
|
- %>
|
|
|
-
|
|
|
- <title>${sessionScope.projectUrlDesc}</title>
|
|
|
-
|
|
|
- <link rel="stylesheet" type="text/css" href="/ss/window/theme/dhtmlxwindows.css">
|
|
|
- <script type="text/javascript" src="/ss/window/dhtmlxcommon.js"></script>
|
|
|
-<%-- 去掉,上面已经有了。Lin(新UI)
|
|
|
- <script type="text/javascript" src="/ss/window/dhtmlxwindows.js"></script>
|
|
|
---%>
|
|
|
- <script type="text/javascript" src="/ss/window/dhtmlxcontainer.js"></script>
|
|
|
- <script type="text/javascript" src="/ss/js/wdDialogInit.js"></script>
|
|
|
- <ss:skin file='dlg.css'/>
|
|
|
- <script type="text/javascript" src="/js/load.js"></script> <%-- ="/newUI/ss/js/base.js"。Lin(新UI) --%>
|
|
|
-
|
|
|
- </head>
|
|
|
-
|
|
|
- <body>
|
|
|
-
|
|
|
- <!-- menu标签输出start -->
|
|
|
-<%-- <ss:menu/>--%>
|
|
|
- <!-- menu标签输出end -->
|
|
|
-
|
|
|
- <div id="app" >
|
|
|
- <div class="self-block layout-container" :sys-mode="sysMode" v-show="isLockScreen==false">
|
|
|
- <div class="header">
|
|
|
- <global-header :menu-data="menuData[8]" :icon-items="iconItems"></global-header>
|
|
|
- </div>
|
|
|
- <div class="content-area">
|
|
|
- <global-menu :menu-items="menuData[1]"></global-menu>
|
|
|
-
|
|
|
- <div class="main-content">
|
|
|
- <iframe
|
|
|
- :src="currentPage"
|
|
|
- frameborder="0"
|
|
|
-
|
|
|
- ifrType="appWin"
|
|
|
- name="win2"
|
|
|
- class="appIframe"
|
|
|
- oriSrc="/initDesktop?"
|
|
|
- ></iframe>
|
|
|
- </div>
|
|
|
- </div>
|
|
|
- </div>
|
|
|
- <div class="login-container lockscreen-container" style="background-image: url(/skin/easy/images/login-bg.png)" <%-- (/newUI/skin/easy/images/login-bg.png)。Lin(新UI) --%>
|
|
|
- v-show="isLockScreen == true" @click.self="toggleRight">
|
|
|
- <div class="left" @click.self="toggleRight"></div>
|
|
|
- <div class="right" :class="{ 'right--visible': isRightVisible }"
|
|
|
- @click="resetTimer"
|
|
|
- @mousemove="resetTimer">
|
|
|
- <div class="content-area">
|
|
|
- <div class="login-box">
|
|
|
- <ss-login-icon class="login-icon-change-user" onclick="wd.display.exit({homepage:1})"></ss-login-icon>
|
|
|
- <div class="box-header">
|
|
|
- <img :src="defaultPersonalPhoto" style="margin-bottom: 15px;" />
|
|
|
- <p>您好,${sessionScope['ssUser'].xm} 欢迎回来</p>
|
|
|
- </div>
|
|
|
- <div>
|
|
|
-
|
|
|
- </div>
|
|
|
- <div class="box-container">
|
|
|
- <form class="box-form">
|
|
|
-
|
|
|
- <div class="form-item">
|
|
|
- <div class="icon">
|
|
|
- <ss-login-icon class="login-icon-password" />
|
|
|
- </div>
|
|
|
- <ss-login-input type="password" v-model="formData.password"
|
|
|
- placeholder="请输入您的密码" />
|
|
|
- </div>
|
|
|
-
|
|
|
-
|
|
|
- <div class="form-bar">
|
|
|
- <span><ss-login-button class="login-icon-yaoyiyao" text="摇一摇登录" type="button"
|
|
|
- @click="handleClick" /></span>
|
|
|
- <span><ss-login-button class="login-icon-loginin" text="登录" type="button"
|
|
|
- @click="unlockSessionByPassword" /></span>
|
|
|
- </div>
|
|
|
- </form>
|
|
|
- <!-- 错误提示 -->
|
|
|
- <div v-if="errInfo.status" class="err-tip">
|
|
|
- <div class="time">
|
|
|
- <div v-for="i in errInfo.allTime" :key="i"
|
|
|
- :class="{ fill: errInfo.allTime - i < errInfo.time }"></div>
|
|
|
- </div>
|
|
|
- <div class="tip">{{ errInfo.tip }}</div>
|
|
|
- </div>
|
|
|
- </div>
|
|
|
- <div class="box-footer">
|
|
|
- <div class="left"></div>
|
|
|
-
|
|
|
- </div>
|
|
|
- </div>
|
|
|
- </div>
|
|
|
- <div class="footer">
|
|
|
- <div>服务单位:广州非繁科技有限公司</div>
|
|
|
- </div>
|
|
|
-
|
|
|
- </div>
|
|
|
- </div>
|
|
|
-
|
|
|
- </div>
|
|
|
- <script type="text/javascript" src="/js/lockScreen.js"></script> <%-- ="/newUI/ss/js/lockScreen.js"。Lin(新UI) --%>
|
|
|
-<%-- 去掉。Lin(新UI)
|
|
|
- 用新UI的 lockScreen.js(注意大小写)
|
|
|
- 先不去掉
|
|
|
---%>
|
|
|
- <script type="text/javascript" src="/ss/js/lockscreen.js"></script>
|
|
|
-
|
|
|
- <ss:skin file='lock.css'/>
|
|
|
- <script>
|
|
|
- var body = $(window.top.document.body);
|
|
|
- // $(top.document.head).append('');
|
|
|
- var funcStr = " if($('#mm').attr('type') == 'password') {$('#mm').attr('type','text')} else {$('#mm').attr('type','password')}";
|
|
|
- var defaultPersonalPhoto=wd.common.loadSkinFile('image/default-personalPhoto.png');
|
|
|
-
|
|
|
- <ss:equal val='${empty sessionScope["ssUser"]["yszwj"]}' val2='false'>
|
|
|
-<%-- 改。Lin
|
|
|
- defaultPersonalPhoto="/service?wdService=getData&path=${sessionScope['env.ry']['yszwj']}"; --%>
|
|
|
- <%--defaultPersonalPhoto="/service?wdService=dlByHttp&path=${sessionScope['wd.yyh']['yszwj']}";--%>
|
|
|
- defaultPersonalPhoto="/service?ssServ=dlByHttp&type=img&path=${sessionScope['ssOrigUser']['yszwj']}";
|
|
|
- </ss:equal>
|
|
|
-
|
|
|
- body.append('<div class="lock-controll-screen" style="display:none;">'+
|
|
|
- '<div id="lock-screen" class="lock-screen login-js-lock-screen" style="background-color: rgb(0, 0, 0);">'+
|
|
|
- '<div class="lock-controll-panel login-translucentDiv" style="position:relative;">'+
|
|
|
- '<div class="login-sca" ></div>'+
|
|
|
- '<div class="login-black icon-replace" title="切换登录" style="width: 22px;height: 22px;margin-right: 5px;margin-top: 5px;cursor:pointer;position:absolute;top:0;right:0;" onclick="wd.display.exit({homepage:1})"></div>'+
|
|
|
- '<div class="welcomeWords" style="padding: 4px 24px;border-radius: 20px;text-align: center;"><div class="personalPhoto" style="margin-left: 98px;margin-bottom: 15px;"><img src="'+defaultPersonalPhoto+'" /></div><p class="login-unlockHello">您好, <input id="zh" name="zh" type="hidden" value="${sessionScope['ssUser'].xm}"></input>${sessionScope['ssUser'].xm} 欢迎回来</p><p> </p></div>'+
|
|
|
- '<p class="lock-controll-input clearfix" ><input id="mm" name="mm" style="background:none !important;" class="login-header_password_sp login-input login-unlockInput" type="password" /><span class="ksmm icon-eye" onclick="'+funcStr+'"></span><button style="background-size:unset;" id="unlockByPassword" class="lock-controll-button icon-enter content-invertButton"></button><button id="unlockByApp" class="lock-controll-button content-invertButton invertIcon-mobile"></button><span class="icon-countdownButton" style="position: absolute;top: 0px;width: 45px;border-radius: 3px;right: -94px;line-height: 30px;text-align: center;"></span></p>'+
|
|
|
- '<p class="lock-controll-hint"><span style="text-align: center;display: block;font-size: 14px;margin-top: 10px;color: #f00;" id="lock-msg"></span></p>'+
|
|
|
- '<p class="lock-controll-button-container" style="display: flex;align-items: center;justify-content: space-between;"><button id="unlockByVoice" style="display:none" class="lock-controll-button login-jslock-button login-unlockByVoice">按住说话</button></p>'+
|
|
|
- '</div>'+
|
|
|
- '</div>'+
|
|
|
- '<div class="home-clock desktop-time">12:12</div>'+
|
|
|
- '</div>');
|
|
|
-
|
|
|
- body.append('<div id="background-desktop" class="background-desktop" style="display:none;"></div>');
|
|
|
- body.append('<ul class="home-tool desktop-time clearfix" style="display:none">' +
|
|
|
- '<li id="pl-list"><div class="pl-list-container"><div class="pl-list"></div><div id="pl-page" class="pl-page"></div></div><a href="#" class="icon-forum listIcon"></a></li>' +
|
|
|
- '<li id="dz-count"><div class="dz-count" id="dz-count"><div id="dz-count-text" class="login-dz-count-text"></div></div><a href="#" class="icon-like listIcon"></a></li>' +
|
|
|
- '<li id="pic-info"><div class="pic-info login-pic-info"><table><tr><th>作者</th><td id="pic-zz-text"></td></tr><tr><th>发布时间</th><td id="pic-fbsj-text"></td></tr><tr><th>名称</th><td id="pic-mc-text"></td></tr></table></div><a href="#" class="icon-info listIcon"></a></li>' +
|
|
|
- '</ul>');
|
|
|
-
|
|
|
- /** 锁屏监听处理开始 **/
|
|
|
- var lockScreenData = {
|
|
|
- url1: '<ss:serv name='wd.lockSession' parm='{"wdConfirmationCaptchaService":"0"}'/>',
|
|
|
- url2: '<ss:serv name='wd.checkIsUnlockedByApp' parm='{"wdConfirmationCaptchaService":"0"}'/>',
|
|
|
- url3: '<ss:serv name='unlockByPwd' parm='{"wdConfirmationCaptchaService":"0"}'/>',
|
|
|
- url4: '<ss:serv name='loadDeskImg' parm='{"wdConfirmationCaptchaService":"0"}'/>',
|
|
|
- url5: '<ss:serv name='pl_cxajax' parm='{"wdConfirmationCaptchaService":"0"}'/>',
|
|
|
- url6: 'wd.display.showComponent({show:["wdDialog"],url:"<ss:serv name='pl_cx' parm='{"wdConfirmationCaptchaService":"0"}' dest='pl_cx'/>",title:"pl_cx",width:650,height:555});',
|
|
|
- url7: '<ss:serv name='nr_dz' parm='{"wdConfirmationCaptchaService":"0"}'/>',
|
|
|
- url8: '<ss:serv name='wrLockStat' parm='{"wdConfirmationCaptchaService":"0"}'/>'
|
|
|
- };
|
|
|
- // 将锁屏需要的东西放进sessionStorage里
|
|
|
- sessionStorage.setItem("lockScreenData",JSON.stringify(lockScreenData));
|
|
|
- // 获取sessionStorage里用户设置的锁屏时间
|
|
|
- var time = sessionStorage.getItem("lockTime");
|
|
|
- //var time = 2;
|
|
|
- console.log("用户设置的锁屏时间",time)
|
|
|
- if(!time){
|
|
|
- time = 15;
|
|
|
- }
|
|
|
- // 实例化锁屏方法,time分钟后锁屏
|
|
|
- // var lock = new LockScreen($(top.document).find('.lock-controll-screen'),$(top.document).find('#home-background'),$(top.document).find('.home-tool'),time,lockScreenData);
|
|
|
-
|
|
|
- // 键盘按下重新设置锁屏
|
|
|
- // $(document).keydown(function(event){
|
|
|
- // // time分钟后重新锁屏
|
|
|
- // lock.setupAutoLock(time);
|
|
|
- // });
|
|
|
- // 鼠标移动重新设置锁屏
|
|
|
- // document.onmousemove = function() {
|
|
|
- // // time分钟后重新锁屏
|
|
|
- // lock.setupAutoLock(time);
|
|
|
- // }
|
|
|
- /** 锁屏监听处理结束 **/
|
|
|
-
|
|
|
- function lockScreenFun(){
|
|
|
- console.log("锁屏点击了2");
|
|
|
- wd.display.beaconLogin("loginOut");
|
|
|
- $(top.document).find('#background-desktop').css('display','block');
|
|
|
- $.ajax({
|
|
|
- type: 'POST',
|
|
|
- url: '<ss:serv name='wrLockStat' parm='{"wdConfirmationCaptchaService":"0"}'/>',
|
|
|
- data: {},
|
|
|
- async: false,
|
|
|
- success: function (data) {
|
|
|
- console.log("成功锁屏");
|
|
|
- lock.lockSession(time);
|
|
|
- },
|
|
|
- });
|
|
|
- }
|
|
|
- wd.topWindow.lockScreen=function(){
|
|
|
- $('#lock').trigger("click");
|
|
|
- }
|
|
|
-
|
|
|
- var passwordeye = $('.login-eyeIcon');
|
|
|
- var showPwd = $(".login-unlockInput");
|
|
|
- passwordeye.on('click', function() {
|
|
|
- console.log(1111111111111);
|
|
|
- if(showPwd.prop('type') == 'text') {
|
|
|
- showPwd.prop('type', 'password');
|
|
|
- } else {
|
|
|
- showPwd.prop('type', 'text');
|
|
|
- };
|
|
|
- });
|
|
|
-
|
|
|
- var kscs =parseInt('<%=base.SsC.LOGIN_maxNum %>');
|
|
|
- var cwcs = 0;
|
|
|
- var cs="";
|
|
|
- for(let i = 1;i<=kscs;i++){
|
|
|
- if(i>cwcs){
|
|
|
- cs += '<span class="login-sc login-used login-unused" style="display:none;width: 8px;height: 8px;border-radius: 50%;float: left;margin-right: 5px;" time="'+i+'"></span>';
|
|
|
- }else{
|
|
|
- cs += '<span class="login-sc login-used login-used" style="display:none;width: 8px;height: 8px;border-radius: 50%;float: left;margin-right: 5px;" time="'+i+'"></span>';
|
|
|
- }
|
|
|
- }
|
|
|
-
|
|
|
- $(".login-sca").append(cs);
|
|
|
-
|
|
|
- console.log("出去了");
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
- function goToIndex() {
|
|
|
- delCookie("userId");
|
|
|
- var sbbs = $("input[name='sbbs']").val();
|
|
|
- var ysbbs = $("input[name='ysbbs']").val();
|
|
|
- window.location.href = "/index?homepage=1&sbbs=" + sbbs+"&ysbbs=" + ysbbs;
|
|
|
- }
|
|
|
- function getCookie(name){
|
|
|
- var arr,reg=new RegExp("(^| )"+name+"=([^;]*)(;|$)");
|
|
|
- if(arr=document.cookie.match(reg))
|
|
|
- return unescape(arr[2]);
|
|
|
- else
|
|
|
- return null;
|
|
|
- }
|
|
|
- function delCookie(name){
|
|
|
- var exp = new Date();
|
|
|
- exp.setTime(exp.getTime() - 1);
|
|
|
- var cval=getCookie(name);
|
|
|
- if(cval!=null)
|
|
|
- document.cookie= name + "="+cval+";expires="+exp.toGMTString();
|
|
|
- }
|
|
|
- </script>
|
|
|
-
|
|
|
- <script type="module">
|
|
|
-
|
|
|
- import { eventBus, EVEN_VAR } from "/js/vue/EventBus.js"; <%-- "/newUI/ss/js/EventBus.js"。Lin(新UI) --%>
|
|
|
- SS.ready(function() {
|
|
|
- if (!window.sharedEventBus) {
|
|
|
- window.sharedEventBus = eventBus;
|
|
|
- }
|
|
|
-
|
|
|
- const sysMode = {
|
|
|
- read: {
|
|
|
- key: "read",
|
|
|
- icon: "setting",
|
|
|
- },
|
|
|
- edit: {
|
|
|
- key: "edit",
|
|
|
- icon: "check",
|
|
|
- },
|
|
|
- };
|
|
|
- const currentMode = Vue.ref(sysMode.read.key);
|
|
|
- const toggoleSysMode = function (key) {
|
|
|
- let newKey = sysMode.edit.key;
|
|
|
- if (currentMode.value === sysMode.edit.key) {
|
|
|
- newKey = sysMode.read.key;
|
|
|
- // SYBJCTRL.saveedit(SESSION_STATE); //保存编辑模式
|
|
|
- }else{
|
|
|
- wd.topWindow.gxhymWindow.userEdit('gr');
|
|
|
- // wd.topWindow.gxhymWindow.userEdit("gf"); //打开编辑模式
|
|
|
- }
|
|
|
- // 设置系统模式
|
|
|
- currentMode.value = newKey;
|
|
|
- eventBus.publish(EVEN_VAR.systemEditModelChange, newKey);
|
|
|
- }
|
|
|
- // 调用组件中的初始化方法
|
|
|
- window.SS.dom.initializeFormApp({
|
|
|
- el: "#app",
|
|
|
- data() {
|
|
|
- return {
|
|
|
- lockTime: sessionStorage.getItem("lockTime") || 15,
|
|
|
- isLockScreen: ${!empty sessionScope.isLockScreen},
|
|
|
- isRightVisible: false,
|
|
|
- hideTimer: null,
|
|
|
- defaultPersonalPhoto: "",
|
|
|
- errInfo: {
|
|
|
- status: false,
|
|
|
- time: 5,
|
|
|
- allTime: 5,
|
|
|
- tip: "",
|
|
|
- },
|
|
|
- formData: {
|
|
|
- password: "",
|
|
|
-
|
|
|
- },
|
|
|
- sysMode: sysMode.read.key,
|
|
|
- currentPage: "/initDesktop?",
|
|
|
- menuData: {
|
|
|
- "8": //系统菜单(左上角LOGO下拉出来的菜单)
|
|
|
- [],
|
|
|
- "1"://侧方菜单(主菜单)
|
|
|
- [{
|
|
|
- desc: "首页",
|
|
|
- icon: "nav-icon-home",
|
|
|
- pid:"00001",
|
|
|
- type:"2",
|
|
|
- url:'/initDesktop?'
|
|
|
- }]
|
|
|
- },
|
|
|
- iconItems: [
|
|
|
- { name: 'question', size: '22px', class: 'header-help', action: () => wd.display.showComponent({show:["wdDialog"],url:"<ss:serv name='querySYSHelp' parm='{"wdConfirmationCaptchaService":"0","ishelp":"true","dialogid":"1"}' dest='cmsPlay'/>",title:"使用指南",width:900,height:800,minHeight:1,maxHeight:800}) },
|
|
|
- { name: 'check', size: '22px',class: 'header-save', condition: () => currentMode.value === sysMode.edit.key, action: () => toggoleSysMode()},
|
|
|
- { name: 'setting-fill', size: '22px', class: 'header-setting',condition: () => currentMode.value !== sysMode.edit.key, action: () => toggoleSysMode() },
|
|
|
- { name: 'list-fill', size: '22px', class: 'header-menu', action: () => console.log('list-fill clicked') },
|
|
|
- { name: 'topic-fill', size: '22px', class: 'header-skin', action: () => wd.display.showComponent({show:["wdDialog"],url:"<ss:serv name='gxhpf_cx' parm='{"wdConfirmationCaptchaService":"0"}' dest='ty_hf'/>",title:"换肤",width:799,height:757}) },
|
|
|
- { name: 'lock-fill', size: '22px', class: 'header-lock', action: () => this.lockScreenFun() },
|
|
|
- { name: 'quit', class: 'big', size: '36px', class: 'header-logout', action: () => wd.display.exit() },
|
|
|
- ],
|
|
|
- };
|
|
|
- },
|
|
|
- methods: {
|
|
|
- setupAutoLock() {
|
|
|
- if(this.autoLockTimer) {
|
|
|
- clearTimeout(this.autoLockTimer);
|
|
|
- }
|
|
|
- this.autoLockTimer = setTimeout(() => {
|
|
|
- console.log('自动锁屏');
|
|
|
- this.lockScreenFun();
|
|
|
- }, this.lockTime * 60 * 1000);
|
|
|
- },
|
|
|
- // 编辑模式变化
|
|
|
- sysEditModelChange(mode) {
|
|
|
- this.sysMode = mode;
|
|
|
- },
|
|
|
- currentPageChange(page) {
|
|
|
- this.currentPage = "./" + page;
|
|
|
- },
|
|
|
- showErrorMsg(msg,sydlcs,zcs){
|
|
|
- console.log(msg,sydlcs,zcs);
|
|
|
- var kscs = zcs;
|
|
|
- var cs = '';
|
|
|
- // for (let i = 1; i <= kscs; i++) {
|
|
|
- // if (i <= (zcs - sydlcs)) {
|
|
|
- // cs = '<span class="login-sc login-used login-used" style="width: 8px;height: 8px;display:block;border-radius: 50%;float: left;margin-right: 5px;" time="' + i + '"></span>';
|
|
|
- // } else {
|
|
|
- // cs = '<span class="login-sc login-used login-unused" style="width: 8px;height: 8px;display: block;border-radius: 50%;float: left;margin-right: 5px;" time="' + i + '"></span>';
|
|
|
- // }
|
|
|
- // console.log(cs);
|
|
|
-
|
|
|
- // }
|
|
|
- this.errInfo.time = sydlcs;
|
|
|
- this.errInfo.allTime = zcs;
|
|
|
- this.errInfo.tip = msg;
|
|
|
- this.errInfo.status = true;
|
|
|
-
|
|
|
- if (sydlcs == zcs) {
|
|
|
- this.errInfo.status = false;
|
|
|
- }
|
|
|
-
|
|
|
- if (0 >= sydlcs) {
|
|
|
- this.errInfo.status = true;
|
|
|
- this.errInfo.time = 0;
|
|
|
- this.errInfo.allTime = 5;
|
|
|
- this.errInfo.tip = msg;
|
|
|
- return false;
|
|
|
- } else {
|
|
|
- this.errInfo.status = true;
|
|
|
- this.errInfo.tip = msg;
|
|
|
- }
|
|
|
- },
|
|
|
- lockScreenFun(){
|
|
|
- console.log("锁屏点击了1");
|
|
|
- this.isLockScreen = true;
|
|
|
- $("#app").css("position", "relative");
|
|
|
- wd.display.beaconLogin("loginOut");
|
|
|
- $.ajax({
|
|
|
- type: 'POST',
|
|
|
- url: '<ss:serv name='wrLockStat' parm='{"wdConfirmationCaptchaService":"0"}'/>',
|
|
|
- data: {},
|
|
|
- async: false,
|
|
|
- success: function (data) {
|
|
|
- console.log("成功锁屏");
|
|
|
- // lock.lockSession(time);
|
|
|
- },
|
|
|
- });
|
|
|
- },
|
|
|
- unlockSessionByPassword(){
|
|
|
- console.log("解锁");
|
|
|
- $("#app").css("position", "");
|
|
|
- var mm=this.formData.password;
|
|
|
- if(!mm){
|
|
|
- this.errInfo.status = true;
|
|
|
- this.errInfo.tip = "请输入密码";
|
|
|
- this.errInfo.time = 5;
|
|
|
- return;
|
|
|
- }
|
|
|
- var that = this;
|
|
|
- $.ajax({
|
|
|
- url: '<ss:serv name='unlockByPwd' parm='{"wdConfirmationCaptchaService":"0"}'/>',
|
|
|
- dataType: 'json',
|
|
|
- type: 'POST',
|
|
|
- data: {
|
|
|
- mm: mm,
|
|
|
- },
|
|
|
- success: function(data) {
|
|
|
- // context.target.find('#lock-msg').html(data.msg);
|
|
|
- if (data.code == -1) {
|
|
|
- that.showErrorMsg(data.msg, data.sydlcs, data.zcs);
|
|
|
- }
|
|
|
- if (data.code == 0) {
|
|
|
- that.isLockScreen = false;
|
|
|
- that.formData.password = "";
|
|
|
- that.errInfo.status = false;
|
|
|
- that.errInfo.time = 5;
|
|
|
- that.errInfo.allTime = 5;
|
|
|
- }
|
|
|
- },
|
|
|
- });
|
|
|
- },
|
|
|
- changeUser(){
|
|
|
- console.log('Button clicked!', event);
|
|
|
- },
|
|
|
- toggleRight() {
|
|
|
- this.isRightVisible = !this.isRightVisible;
|
|
|
-
|
|
|
- // 清除之前的定时器
|
|
|
- if (this.hideTimer) {
|
|
|
- clearTimeout(this.hideTimer);
|
|
|
- }
|
|
|
-
|
|
|
- // 设置新的定时器
|
|
|
- if (this.isRightVisible) {
|
|
|
- this.hideTimer = setTimeout(() => {
|
|
|
- this.isRightVisible = false;
|
|
|
- }, 10000);
|
|
|
- }
|
|
|
- },
|
|
|
- // 当用户在右侧区域操作时,重置定时器
|
|
|
- resetTimer() {
|
|
|
- if (this.hideTimer) {
|
|
|
- clearTimeout(this.hideTimer);
|
|
|
- }
|
|
|
- this.hideTimer = setTimeout(() => {
|
|
|
- this.isRightVisible = false;
|
|
|
- }, 10000);
|
|
|
- }
|
|
|
- },
|
|
|
- mounted() {
|
|
|
- // console.log(window.SS)
|
|
|
- console.log(window.top.SS)
|
|
|
-
|
|
|
- window.top.SS.lockScreenService.init(this);
|
|
|
- eventBus.subscribe(EVEN_VAR.systemEditModelChange,this.sysEditModelChange);
|
|
|
- eventBus.subscribe(EVEN_VAR.currentPage, this.currentPageChange);
|
|
|
- // 监听锁屏
|
|
|
- // 设置键盘和鼠标事件监听
|
|
|
- document.addEventListener('keydown', () => {
|
|
|
- this.setupAutoLock();
|
|
|
- });
|
|
|
-
|
|
|
- document.addEventListener('mousemove', () => {
|
|
|
- this.setupAutoLock();
|
|
|
- });
|
|
|
- this.setupAutoLock();
|
|
|
-
|
|
|
- <ss:equal val='${empty sessionScope.isLockScreen}' val2='false'>
|
|
|
- this.lockScreenFun();
|
|
|
- </ss:equal>
|
|
|
- this.defaultPersonalPhoto = wd.common.loadSkinFile('image/default-personalPhoto.png');
|
|
|
- // 如果用户有自定义头像,则使用自定义头像
|
|
|
- <ss:equal val='${empty sessionScope["ssUser"]["yszwj"]}' val2='false'>
|
|
|
- <%-- 改。Lin
|
|
|
- defaultPersonalPhoto="/service?wdService=getData&path=${sessionScope['env.ry']['yszwj']}"; --%>
|
|
|
- <%--this.defaultPersonalPhoto="/service?wdService=dlByHttp&path=${sessionScope['wd.yyh']['yszwj']}";--%>
|
|
|
- this.defaultPersonalPhoto="/service?ssServ=dlByHttp&type=img&path=${sessionScope['ssOrigUser']['yszwj']}";
|
|
|
- </ss:equal>
|
|
|
-
|
|
|
- const that = this;
|
|
|
-
|
|
|
- $.ajax({
|
|
|
- type: 'POST',
|
|
|
-
|
|
|
- url: '<ss:serv name='wrMenuList'/>',
|
|
|
- async: false,
|
|
|
- dataType: 'json',
|
|
|
- success: function (data) {
|
|
|
- // alert('菜单数据:'+JSON.stringify(data));
|
|
|
- that.menuData = data;
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
- <%-- 测试新UI临时写死 start --%>
|
|
|
-
|
|
|
- // that.menuData["1"].unshift({
|
|
|
- // desc: "单位",
|
|
|
- // icon: "nav-icon-home",
|
|
|
- // pid:"00001",
|
|
|
- // type:"2",
|
|
|
- // url:'<ss:serv name='dw_cx' dest='objList_bk' parm='{}'/>'
|
|
|
- // });
|
|
|
-
|
|
|
- // that.menuData["1"].unshift({
|
|
|
- // desc: "在用单位-部门",
|
|
|
- // icon: "nav-icon-home",
|
|
|
- // pid:"00001",
|
|
|
- // type:"2",
|
|
|
- // url:'<ss:serv name='bm_cx' dest='1objList' parm='{dwid:"101122",ssObjId:"101122",ssObjName:"dw",dataType:"change",ParentViewObject:"dw"}'/>'
|
|
|
- // });
|
|
|
-
|
|
|
- // that.menuData["1"].unshift({
|
|
|
- // desc: "人员",
|
|
|
- // icon: "nav-icon-person",
|
|
|
- // pid:"00001",
|
|
|
- // type:"2",
|
|
|
- // url:'<ss:serv name='ry_cx' dest='1ryList' parm='{}'/>'
|
|
|
- // });
|
|
|
- <%-- 测试新UI临时写死 end --%>
|
|
|
-
|
|
|
- that.menuData["1"].unshift({
|
|
|
- desc: "首页",
|
|
|
- icon: "icon-shouye", // v3.0 改为使用新图标库 by xu 20251215
|
|
|
- pid:"00001",
|
|
|
- type:"2",
|
|
|
- url:'/initDesktop?'
|
|
|
- });
|
|
|
-
|
|
|
- // v3.0 设置菜单图标 - 使用业务图标库 by xu 20251215
|
|
|
- that.menuData["1"].forEach(item => {
|
|
|
- // 一级菜单(文件夹类型)- 有同名二级菜单的用同样图标
|
|
|
- if(item.id === "1021775") item.icon = "icon-obj-ry"; // 人员
|
|
|
- if(item.id === "1021812") item.icon = "icon-obj-xy"; // 学员
|
|
|
- if(item.id === "1021809") item.icon = "icon-biz-grxf"; // 个人消费
|
|
|
- if(item.id === "1021783") item.icon = "icon-biz-men"; // 门
|
|
|
- if(item.id === "1021806") item.icon = "icon-caipin"; // 菜品
|
|
|
- if(item.id === "1021786") item.icon = "icon-biz-rc"; // 日程
|
|
|
- if(item.id === "1021789") item.icon = "icon-biz-xc"; // 巡查
|
|
|
- if(item.id === "1021793") item.icon = "icon-biz-kq"; // 考勤
|
|
|
- if(item.id === "1021795") item.icon = "icon-biz-wp"; // 物品
|
|
|
- if(item.id === "1021804") item.icon = "icon-biz-cl"; // 车辆
|
|
|
- // 评价(1021780)、场地(1021800) 暂无图标,使用默认文件夹图标
|
|
|
-
|
|
|
- // 二级菜单使用对象图标
|
|
|
- if(item.id === "ry_search") item.icon = "icon-obj-ry"; // 人员
|
|
|
- if(item.id === "gw_search") item.icon = "icon-obj-gw"; // 岗位
|
|
|
- if(item.id === "qz_search") item.icon = "icon-obj-qz"; // 群组
|
|
|
- if(item.id === "dw_search") item.icon = "icon-obj-dw"; // 单位
|
|
|
- if(item.id === "xy_search") item.icon = "icon-obj-xy"; // 学员
|
|
|
- if(item.id === "grcz_search") item.icon = "icon-obj-grcz"; // 个人充值
|
|
|
- if(item.id === "xfj_search") item.icon = "icon-obj-xfj"; // 消费机
|
|
|
- if(item.id === "jcjl_search") item.icon = "icon-obj-jcjl"; // 进出记录
|
|
|
- if(item.id === "mjd_search") item.icon = "icon-obj-mjd"; // 门禁点
|
|
|
- if(item.id === "mtcp_search") item.icon = "icon-mingricaipin"; // 明天菜品
|
|
|
- if(item.id === "cp_search") item.icon = "icon-caipin"; // 菜品
|
|
|
- if(item.id === "rc_search") item.icon = "icon-biz-rc"; // 日程
|
|
|
- if(item.id === "rcjh_search") item.icon = "icon-obj-rcjh"; // 日程计划
|
|
|
- if(item.id === "xcdjl_search") item.icon = "icon-obj-xcjl"; // 巡查记录
|
|
|
- if(item.id === "xcd_search") item.icon = "icon-obj-xcd"; // 巡查点
|
|
|
- if(item.id === "kqjl_search") item.icon = "icon-obj-kqjl"; // 考勤记录
|
|
|
- if(item.id === "wp_search") item.icon = "icon-biz-wp"; // 物品
|
|
|
- if(item.id === "cl_search") item.icon = "icon-biz-cl"; // 车辆
|
|
|
- if(item.id === "cd_search") item.icon = "icon-biz-cd"; // 场地
|
|
|
- });
|
|
|
- },
|
|
|
- });
|
|
|
-
|
|
|
- // 初始化菜单模式为收起(设置CSS变量)
|
|
|
- const layoutContainer = document.querySelector('.layout-container');
|
|
|
- if (layoutContainer) {
|
|
|
- layoutContainer.style.setProperty('--left-side-width', '60px');
|
|
|
- }
|
|
|
- },
|
|
|
- unmounted() {
|
|
|
- // 清理定时器和事件监听
|
|
|
- if(this.autoLockTimer) {
|
|
|
- clearTimeout(this.autoLockTimer);
|
|
|
- }
|
|
|
- document.removeEventListener('keydown', this.setupAutoLock);
|
|
|
- document.removeEventListener('mousemove', this.setupAutoLock);
|
|
|
- eventBus.clear(
|
|
|
- EVEN_VAR.systemEditModelChange,
|
|
|
- this.sysEditModelChange
|
|
|
- );
|
|
|
- },
|
|
|
- });
|
|
|
- });
|
|
|
- </script>
|
|
|
- </body>
|
|
|
-</html>
|