public static string SendMsgToJMJ(string SendMsg, out string RecMsg)
        {
            string            sendData   = "";
            PlatFormInterface pfi        = PlatFormInterface.getInstance();
            string            statusCode = "";
            string            message    = "";

            RecMsg = "";
            string recode = "";

            if (GlobalClass.oldMethodFlag)
            {
                //recode = YN_TCPinterface.TCPinterface.AccessJMJ(GlobalClass.name, GlobalClass.idcardType, GlobalClass.idcard, GlobalClass.receipt, SendMsg, out message);
                if (recode.Equals("0000"))
                {
                    return(message);
                }
            }
            else
            {
                string jmjbm = pfi.getEncryptor(GlobalClass.idcard, GlobalClass.name, GlobalClass.distCode /*pfi.adCode*/, SendMsg, GlobalClass.userId /*pfi.operatorNo*/, GlobalClass.jylsh, GlobalClass.receipt, GlobalClass.strCertificateType, GlobalClass.oldyhkh, GlobalClass.ssbm, out statusCode, out message, out sendData);

                if (statusCode == "200")
                {
                    return(jmjbm);
                }
            }

            return("");
        }
Beispiel #2
0
        private void btnLogin_Click(object sender, EventArgs e)
        {
            if (tbPws.Text.Equals("") || tbUser.Text.Equals(""))
            {
                labelInfo.Text = "输入不能为空!";
                return;
            }
            string            username   = tbUser.Text;
            string            password   = tbPws.Text;
            string            statusCode = "";
            string            message    = "";
            PlatFormInterface pfi        = PlatFormInterface.getInstance();

            loginInfo = pfi.checkLogin(username, password, out statusCode, out message);
            if (statusCode == "200" && message == "登录成功")
            {
                GlobalClass.userId    = loginInfo[0];
                GlobalClass.orgId     = loginInfo[5];
                GlobalClass.loginName = loginInfo[1];//username;
                GlobalClass.distCode  = loginInfo[16];
                GlobalClass.yhbm      = loginInfo[17];
                this.DialogResult     = DialogResult.OK;
                Close();
            }
            else
            {
                labelInfo.Text = message;
            }
        }