起步软件技术论坛
搜索
 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 5042|回复: 5

[结贴] 集成的例子 DEMO_HTML错误

[复制链接]

74

主题

197

帖子

403

积分

中级会员

Rank: 3Rank: 3

积分
403
QQ
发表于 2020-2-21 17:18:59 | 显示全部楼层 |阅读模式
版本: 小版本号:
数据库: 服务器操作系统: 应用服务器:
客户端操作系统: 浏览器:
看了关于和第三方 集成 sso的帖子,从 demo中拷贝出 DEMO_HTML测试,但出现错误,html页面的错误如下: 我跟踪了/UI2/demo/actions/process/integration/doLogin.j“” 里的代码:运行到下面这行就错了,检查是否原有sessionid过期,这个请求中的sessionid参数是空的。
ActionResult checkResult = ActionEngine.checkSession(bsessionid, ActionUtils.JSON_CONTENT_TYPE);  

无标题.png


我看了下 服务端的 tomcat控制台,没出现异常信息,但却有很多条select语句,如下:

2020-02-21 17:13:59 Not registed session:BCE2829D4B22018E88E773D661CB91B7, jsessionid:JSESSIONID=, action: check_session
2020-02-21 17:13:59 [SQL Time]sql 执行时间:2ms, exec KSQL: select case when UPPER(p.sLoginName)=:name then 1 when UPPER(p.sCode)=:name then 2 else 3 end as odr , mo, mo.sFID, mo.sFName, mo.sFCode, p.* from SA_OPPerson p join SA_OPOrg mo ON p.sMainOrgID = mo where (UPPER(p.sLoginName)=:name or UPPER(p.sCode)=:name) and p.sValidState=1 order by odr
  --> sql:SELECT  CASE WHEN UPPER(p.SLOGINNAME) =  ?  THEN ? WHEN UPPER(p.SCODE) =  ?  THEN ? ELSE ? END  AS odr, mo.sID, mo.sFID AS sFID, mo.sFName AS sFName, mo.SFCODE AS sFCode, p.sID AS p, p.SNAME AS sName, p.SCODE AS sCode, p.SIDCARD AS sIDCard, p.SNUMB AS sNumb, p.SLOGINNAME AS sLoginName, p.SPASSWORD AS sPassword, p.SPASSWORDTIMELIMIT AS sPasswordTimeLimit, p.SPASSWORDMODIFYTIME AS sPasswordModifyTime, p.SMAINORGID AS sMainOrgID, p.SSAFELEVELID AS sSafeLevelID, p.SSEQUENCE AS sSequence, p.SVALIDSTATE AS sValidState, p.SDESCRIPTION AS sDescription, p.SPHOTO AS sPhoto, p.SPHOTOLASTMODIFIED AS sPhotoLastModified, p.SSEX AS sSex, p.SBIRTHDAY AS sBirthday, p.SJOINDATE AS sJoinDate, p.SHOMEPLACE AS sHomePlace, p.SCOUNTRY AS sCountry, p.SPROVINCE AS sProvince, p.SCITY AS sCity, p.SDEGREE AS sDegree, p.SGRADUATESCHOOL AS sGraduateSchool, p.SSPECIALITY AS sSpeciality, p.SSCHOOLLENGTH AS sSchoolLength, p.STITLE AS sTitle, p.SMARRIAGE AS sMarriage, p.SCARDNO AS sCardNO, p.SCARDKIND AS sCardKind, p.SFAMILYADDRESS AS sFamilyAddress, p.SZIP AS sZip, p.SMSN AS sMsn, p.SQQ AS sQQ, p.SMAIL AS sMail, p.SMOBILEPHONE AS sMobilePhone, p.SFAMILYPHONE AS sFamilyPhone, p.SOFFICEPHONE AS sOfficePhone, p.SENGLISHNAME AS sEnglishName, p.VERSION AS version FROM SA_OPPerson p JOIN SA_OPOrg mo ON p.SMAINORGID = mo.sID  WHERE  ( (UPPER(p.SLOGINNAME) =  ? ) OR (UPPER(p.SCODE) =  ? ) ) AND (p.SVALIDSTATE = ?)   ORDER BY odr ASC
--> binds:[SYSTEM, 1, SYSTEM, 2, 3, SYSTEM, SYSTEM, 1]
2020-02-21 17:13:59 [KSQL Time]sql 执行时间:9ms, ksql:select case when UPPER(p.sLoginName)=:name then 1 when UPPER(p.sCode)=:name then 2 else 3 end as odr , mo, mo.sFID, mo.sFName, mo.sFCode, p.* from SA_OPPerson p join SA_OPOrg mo ON p.sMainOrgID = mo where (UPPER(p.sLoginName)=:name or UPPER(p.sCode)=:name) and p.sValidState=1 order by odr
2020-02-21 17:13:59 [SQL Time]sql 执行时间:1ms, exec KSQL: SELECT p, p.sName AS pname, p.sCode AS pcode, mo, mo.sFID as m_sfid, mo.sFName as m_sfname, mo.sFCode as m_sfcode , a.sOrgFName as agt_fname, a.sOrgFID as agt_fid, a.sProcess as agt_process  FROM SA_OPPerson p JOIN SA_OPOrg mo ON p.sMainOrgID = mo JOIN SA_OPOrg pm ON pm.sValidState = 1 AND pm.sPersonID = p AND pm.sOrgKindID = 'psm' JOIN SA_OPAgent a ON a.sOrgFID = pm.sFID AND a.sAgentID = 'PSN01' AND a.sValidState = 1 AND (:now >= a.sStartTime OR a.sStartTime IS NULL) AND (a.sFinishTime IS NULL OR a.sFinishTime >= :now)
  --> sql:SELECT  p.sID, p.SNAME AS pname, p.SCODE AS pcode, mo.sID, mo.sFID AS m_sfid, mo.sFName AS m_sfname, mo.SFCODE AS m_sfcode, a.SORGFNAME AS agt_fname, a.SORGFID AS agt_fid, a.SPROCESS AS agt_process FROM SA_OPPerson p JOIN SA_OPOrg mo ON p.SMAINORGID = mo.sID JOIN SA_OPOrg pm ON  (pm.SVALIDSTATE = ?) AND (pm.SPERSONID = p.sID) AND (pm.SORGKINDID = ?)  JOIN SA_OPAgent a ON  (a.SORGFID = pm.sFID) AND (a.SAGENTID = ?) AND (a.SVALIDSTATE = ?) AND ( ( ?  >= a.SSTARTTIME) OR (a.SSTARTTIME IS NULL) ) AND ( (a.SFINISHTIME IS NULL) OR (a.SFINISHTIME >=  ? ) )
--> binds:[1, psm, PSN01, 1, 2020-02-21 17:13:59.438, 2020-02-21 17:13:59.438]
2020-02-21 17:13:59 [KSQL Time]sql 执行时间:8ms, ksql:SELECT p, p.sName AS pname, p.sCode AS pcode, mo, mo.sFID as m_sfid, mo.sFName as m_sfname, mo.sFCode as m_sfcode , a.sOrgFName as agt_fname, a.sOrgFID as agt_fid, a.sProcess as agt_process  FROM SA_OPPerson p JOIN SA_OPOrg mo ON p.sMainOrgID = mo JOIN SA_OPOrg pm ON pm.sValidState = 1 AND pm.sPersonID = p AND pm.sOrgKindID = 'psm' JOIN SA_OPAgent a ON a.sOrgFID = pm.sFID AND a.sAgentID = 'PSN01' AND a.sValidState = 1 AND (:now >= a.sStartTime OR a.sStartTime IS NULL) AND (a.sFinishTime IS NULL OR a.sFinishTime >= :now)
2020-02-21 17:13:59 [SQL Time]sql 执行时间:4ms, exec KSQL: select pm.sFID AS pm_fid,pm.sFName AS pm_fname,pm.sFCode AS pm_fcode, r, r.sCode as r_sCode, r.sName as r_sName, perm1.*  from SA_OPOrg pm  OPTIONAL JOIN SA_OPAuthorize au ON pm.sFID like concat(au.sOrgFID, '%')  JOIN SA_OPRole r ON (au.sAuthorizeRoleID=r AND r.sValidState = 1)  OPTIONAL JOIN SA_OPPermission perm1 ON (perm1.sPermissionRoleID=r  and perm1.sValidState=1)  WHERE pm.sValidState=1 and pm.sPersonID=:personId and pm.sOrgKindID=:kind
  --> sql:SELECT  pm.sFID AS pm_fid, pm.sFName AS pm_fname, pm.SFCODE AS pm_fcode, r.sID, r.SCODE AS r_sCode, r.SNAME AS r_sName, perm1.sID AS perm1, perm1.sPermissionRoleID AS sPermissionRoleID, perm1.SPROCESS AS sProcess, perm1.SACTIVITYFNAME AS sActivityFName, perm1.SACTIVITY AS sActivity, perm1.SACTIONSNAMES AS sActionsNames, perm1.SACTIONS AS sActions, perm1.SSEMANTICDP AS sSemanticDP, perm1.SPERMISSIONKIND AS sPermissionKind, perm1.SDESCRIPTION AS sDescription, perm1.SSEQUENCE AS sSequence, perm1.SVALIDSTATE AS sValidState, perm1.VERSION AS version FROM SA_OPOrg pm LEFT JOIN SA_OPAuthorize au ON pm.sFID LIKE concat_ws('',au.SORGFID, ?) JOIN SA_OPRole r ON  (au.sAuthorizeRoleID = r.sID) AND (r.SVALIDSTATE = ?)  LEFT JOIN SA_OPPermission perm1 ON  (perm1.sPermissionRoleID = r.sID) AND (perm1.SVALIDSTATE = ?)   WHERE  (pm.SVALIDSTATE = ?) AND (pm.SPERSONID =  ? ) AND (pm.SORGKINDID =  ? )
--> binds:[%, 1, 1, 1, PSN01, psm]
2020-02-21 17:13:59 [KSQL Time]sql 执行时间:18ms, ksql:select pm.sFID AS pm_fid,pm.sFName AS pm_fname,pm.sFCode AS pm_fcode, r, r.sCode as r_sCode, r.sName as r_sName, perm1.*  from SA_OPOrg pm  OPTIONAL JOIN SA_OPAuthorize au ON pm.sFID like concat(au.sOrgFID, '%')  JOIN SA_OPRole r ON (au.sAuthorizeRoleID=r AND r.sValidState = 1)  OPTIONAL JOIN SA_OPPermission perm1 ON (perm1.sPermissionRoleID=r  and perm1.sValidState=1)  WHERE pm.sValidState=1 and pm.sPersonID=:personId and pm.sOrgKindID=:kind
2020-02-21 17:13:59 [SQL Time]sql 执行时间:1ms, exec KSQL: select o.sFID, o.sFName, o.sFCode from SA_OPOrg o where o.sValidState=1 and o.sPersonID=:personId
  --> sql:SELECT  o.sFID AS sFID, o.sFName AS sFName, o.SFCODE AS sFCode FROM SA_OPOrg o  WHERE  (o.SVALIDSTATE = ?) AND (o.SPERSONID =  ? )
--> binds:[1, PSN01]
2020-02-21 17:13:59 [KSQL Time]sql 执行时间:4ms, ksql:select o.sFID, o.sFName, o.sFCode from SA_OPOrg o where o.sValidState=1 and o.sPersonID=:personId
2020-02-21 17:13:59 [SQL Time]sql 执行时间:2ms, exec KSQL: select r, par, par.sCode as p_sCode, par.sName as p_sName, p.* from SA_OPRole par optional join SA_OPPermission p on p.sPermissionRoleID=par and par.sValidState = 1 and p.sValidState=1 join SA_OPRole r on par=r.sParentRole AND r IN ('0953A29D83D84E5F8F6E133E6D16421C', 'RL03-demo', 'RL-SYSTEM', 'RL-USER')
  --> sql:SELECT  r.sID, par.sID, par.SCODE AS p_sCode, par.SNAME AS p_sName, p.sID AS p, p.sPermissionRoleID AS sPermissionRoleID, p.SPROCESS AS sProcess, p.SACTIVITYFNAME AS sActivityFName, p.SACTIVITY AS sActivity, p.SACTIONSNAMES AS sActionsNames, p.SACTIONS AS sActions, p.SSEMANTICDP AS sSemanticDP, p.SPERMISSIONKIND AS sPermissionKind, p.SDESCRIPTION AS sDescription, p.SSEQUENCE AS sSequence, p.SVALIDSTATE AS sValidState, p.VERSION AS version FROM SA_OPRole par LEFT JOIN SA_OPPermission p ON  (p.sPermissionRoleID = par.sID) AND (par.SVALIDSTATE = ?) AND (p.SVALIDSTATE = ?)  JOIN (SA_OPRole r LEFT JOIN SA_OPParentRole SA_OPParentRole__1 ON r.sID = SA_OPParentRole__1.sRoleID  ) ON  (par.sID = SA_OPParentRole__1.sParentRoleID) AND ( r.sID IN (?, ?, ?, ?) )
--> binds:[1, 1, 0953A29D83D84E5F8F6E133E6D16421C, RL03-demo, RL-SYSTEM, RL-USER]
2020-02-21 17:13:59 [KSQL Time]sql 执行时间:7ms, ksql:select r, par, par.sCode as p_sCode, par.sName as p_sName, p.* from SA_OPRole par optional join SA_OPPermission p on p.sPermissionRoleID=par and par.sValidState = 1 and p.sValidState=1 join SA_OPRole r on par=r.sParentRole AND r IN ('0953A29D83D84E5F8F6E133E6D16421C', 'RL03-demo', 'RL-SYSTEM', 'RL-USER')
2020-02-21 17:13:59 [SQL Time]sql 执行时间:1ms, exec KSQL: select m.*,mt.sCode from SA_OPManagement m optional join SA_OPManageType mt on m.sManageTypeID=mt where '/ORG01.ogn/PSN01@ORG01.psm' like concat(m.sOrgFID, '%')
  --> sql:SELECT  m.sID AS m, m.SORGID AS sOrgID, m.SORGFID AS sOrgFID, m.SORGNAME AS sOrgName, m.SORGFNAME AS sOrgFName, m.SMANAGEORGID AS sManageOrgID, m.SMANAGEORGNAME AS sManageOrgName, m.SMANAGEORGFID AS sManageOrgFID, m.SMANAGEORGFNAME AS sManageOrgFName, m.SMANAGETYPEID AS sManageTypeID, m.SCREATORFID AS sCreatorFID, m.SCREATORFNAME AS sCreatorFName, m.SCREATETIME AS sCreateTime, m.VERSION AS version, mt.SCODE AS sCode FROM SA_OPManagement m LEFT JOIN SA_OPManageType mt ON m.SMANAGETYPEID = mt.sID  WHERE ? LIKE concat_ws('',m.SORGFID, ?)
--> binds:[/ORG01.ogn/PSN01@ORG01.psm, %]
2020-02-21 17:13:59 [KSQL Time]sql 执行时间:6ms, ksql:select m.*,mt.sCode from SA_OPManagement m optional join SA_OPManageType mt on m.sManageTypeID=mt where '/ORG01.ogn/PSN01@ORG01.psm' like concat(m.sOrgFID, '%')





91

主题

13万

帖子

3万

积分

管理员

Rank: 9Rank: 9Rank: 9

积分
36069
发表于 2020-2-21 17:44:41 | 显示全部楼层
点登录报错了吗?
远程的联系方法QQ1392416607,添加好友时,需在备注里注明其论坛名字及ID,公司等信息
发远程时同时也发一下帖子地址,方便了解要解决的问题  WeX5教程  WeX5下载



如按照该方法解决,请及时跟帖,便于版主结贴
回复 支持 反对

使用道具 举报

74

主题

197

帖子

403

积分

中级会员

Rank: 3Rank: 3

积分
403
QQ
 楼主| 发表于 2020-2-21 17:47:32 | 显示全部楼层
jishuang 发表于 2020-2-21 17:44
点登录报错了吗?

是的,点的html上的登录按钮,报的上面的错误,直接从x5自己的登录页是可以的
回复 支持 反对

使用道具 举报

74

主题

197

帖子

403

积分

中级会员

Rank: 3Rank: 3

积分
403
QQ
 楼主| 发表于 2020-2-21 17:50:12 | 显示全部楼层
jishuang 发表于 2020-2-21 17:44
点登录报错了吗?

html页上的注销也是错误:服务端 tomcat控制台倒是输出了一行错误信息:
2020-02-21 17:49:10 Not registed session:9F33DFDCCF6BE15DC23676462F47B893, jsessionid:JSESSIONID=, action: logout
回复 支持 反对

使用道具 举报

91

主题

13万

帖子

3万

积分

管理员

Rank: 9Rank: 9Rank: 9

积分
36069
发表于 2020-2-21 18:09:35 | 显示全部楼层
127.0.0.1改为localhost
远程的联系方法QQ1392416607,添加好友时,需在备注里注明其论坛名字及ID,公司等信息
发远程时同时也发一下帖子地址,方便了解要解决的问题  WeX5教程  WeX5下载



如按照该方法解决,请及时跟帖,便于版主结贴
回复 支持 反对

使用道具 举报

74

主题

197

帖子

403

积分

中级会员

Rank: 3Rank: 3

积分
403
QQ
 楼主| 发表于 2020-2-21 18:57:18 | 显示全部楼层
jishuang 发表于 2020-2-21 18:09
127.0.0.1改为localhost

解决了,可能是版本问题吧, demo_html中 要求的返回格式和 系统那个 doLogin.j不一致,后来我自己又写了个.j。输出信息,发现已经正确执行了。把前后端的格式设成一样的,就可以了
回复 支持 反对

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

小黑屋|手机版|X3技术论坛|Justep Inc.    

GMT+8, 2024-11-27 14:37 , Processed in 0.108906 second(s), 28 queries .

Powered by Discuz! X3.4

© 2001-2013 Comsenz Inc.

快速回复 返回顶部 返回列表