<%@ page import="weaver.integration.entrance.bean.OutterLoginBean" %>
<%@ page import="weaver.integration.entrance.service.EntranceService" %>
<%@ page import="weaver.integration.entrance.service.IEntranceService" %>
<%@ page import="weaver.integration.entrance.service.IOutterSysServer" %>
<%@ page import="weaver.integration.entrance.service.impl.NcServer" %>
<%@ page import="weaver.integration.entrance.service.permission.IPermissionService" %>
<%@ page import="weaver.integration.entrance.service.permission.PermissionService" %>
<%@ page contentType="text/html;charset=UTF-8" language="java"%>
<%--<%@ include file="/systeminfo/init_wev8.jsp" %>--%>
<%@ page import="weaver.integration.logging.LoggerFactory" %>
<%@ page import="weaver.integration.logging.Logger" %>
<%@ page import="weaver.general.Util" %>
<%@ page import="java.util.Map" %>
<%@ page import="java.util.Objects" %>
<%@ page import="weaver.general.BaseBean" %>
<%@ page import="weaver.hrm.User" %>
<%@ page import="weaver.hrm.HrmUserVarify" %>
<%@ page import="weaver.interfaces.encode.AES_IV" %>
<%@ page import="com.engine.common.util.ParamUtil" %>
<%@ page import="com.icbc.api.internal.apache.http.impl.cookie.S" %>
<jsp:useBean id="rs" class="weaver.conn.RecordSet" scope="page" />
<jsp:useBean id="RecordSet" class="weaver.conn.RecordSet" scope="page" />
<jsp:useBean id="RecordSet1" class="weaver.conn.RecordSet" scope="page" />

<%
    Logger integration_logger = LoggerFactory.getLogger();
    BaseBean bb = new BaseBean();
    String mhurl = "";
    String encodeResultStr = "";
    try {
        User user = HrmUserVarify.getUser(request,response);
        String loginid = user.getLoginid();
        Map<String, Object> paramMap = ParamUtil.request2Map(request);
        mhurl = (String) paramMap.get("mhurl");

        AES_IV aesIV = new AES_IV();
        // AES的密钥长度最好是16位(不是必须)
        String password = "ecology_nsh_2021";
        // AES的向量长度必须为16位
        String iv = "weaver_nsyh_2021";
        aesIV.setPwd(password);
        aesIV.setIv(iv);
        // 加密
        encodeResultStr = aesIV.encode(loginid);
        // out.println(mhurl);
        response.sendRedirect(mhurl+"?loginid="+encodeResultStr);

    }catch (Exception E){
        bb.writeLog("mhxxerror====>"+E.getMessage());
        response.sendRedirect(mhurl);
    }
    %>