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

QQ登录

只需一步,快速开始

查看: 4252|回复: 14

[结贴] setfilter无法过滤指定部门(selectorgpc组件)

[复制链接]

41

主题

303

帖子

877

积分

高级会员

Rank: 4

积分
877
QQ
发表于 2016-12-14 08:15:32 | 显示全部楼层 |阅读模式
版本: BeX5V3.3 小版本号:
数据库: MySQL 服务器操作系统: Windows 应用服务器: Tomcat
客户端操作系统: Windows 其它 浏览器: IE9
本帖最后由 lwcompany 于 2016-12-14 08:50 编辑

Model.prototype.orgSelectPC1ShowOption = function(event){
           debugger;
              var SA_OPOrg=this.comp("bizData1");
               var like="LIKE '%/集团/总经理室/零售部%'";
                    SA_OPOrg.setFilter("sFName","SA_OPOrg.sFName='"+like+"'");
           debugger;

又试了
var SA_OPOrg=this.comp("bizData1");
               var like="集团/总经理室/零售部";
                   SA_OPOrg.filters.setFilter("sFName","SA_OPOrg.sFName LIKE '%"+like+"%'");
                    SA_OPOrg.refreshData();
还是不好用
无法过滤出指定部门,事件触发后只能显示顶层菜单


setfilter无法过滤指定部门20161214081158.png

91

主题

13万

帖子

3万

积分

管理员

Rank: 9Rank: 9Rank: 9

积分
36064
发表于 2016-12-14 10:35:17 | 显示全部楼层
如果是根目录的过滤参考
http://docs.wex5.com/bex5-ui-question-list-10084/
远程的联系方法QQ1392416607,添加好友时,需在备注里注明其论坛名字及ID,公司等信息
发远程时同时也发一下帖子地址,方便了解要解决的问题  WeX5教程  WeX5下载



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

使用道具 举报

41

主题

303

帖子

877

积分

高级会员

Rank: 4

积分
877
QQ
 楼主| 发表于 2016-12-14 11:26:15 | 显示全部楼层
本帖最后由 lwcompany 于 2016-12-14 11:30 编辑

我的组件是orgselectpc,没有这个属性呀,我想过滤中间结点
回复 支持 反对

使用道具 举报

91

主题

13万

帖子

3万

积分

管理员

Rank: 9Rank: 9Rank: 9

积分
36064
发表于 2016-12-14 13:46:47 | 显示全部楼层
只要是data设置的树形的都可以设置设置

orgSelectPC里面默认封装了树形的data
远程的联系方法QQ1392416607,添加好友时,需在备注里注明其论坛名字及ID,公司等信息
发远程时同时也发一下帖子地址,方便了解要解决的问题  WeX5教程  WeX5下载



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

使用道具 举报

41

主题

303

帖子

877

积分

高级会员

Rank: 4

积分
877
QQ
 楼主| 发表于 2016-12-14 22:22:41 | 显示全部楼层
   SA_OPOrg.getTreeOption().rootfilter="SA_OPOrg.sFName LIKE '%"+like+"%'";还是过滤不出来
回复 支持 反对

使用道具 举报

91

主题

13万

帖子

3万

积分

管理员

Rank: 9Rank: 9Rank: 9

积分
36064
发表于 2016-12-15 09:48:39 | 显示全部楼层
http://bbs.wex5.com/forum.php?mo ... 4&pid=165004035
把具体的sql打出来看看执行的sql是什么
远程的联系方法QQ1392416607,添加好友时,需在备注里注明其论坛名字及ID,公司等信息
发远程时同时也发一下帖子地址,方便了解要解决的问题  WeX5教程  WeX5下载



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

使用道具 举报

41

主题

303

帖子

877

积分

高级会员

Rank: 4

积分
877
QQ
 楼主| 发表于 2016-12-15 12:36:53 | 显示全部楼层
2016-12-15 12:37:57 加载模块:/SA/doc/logic ...
2016-12-15 12:37:57 加载模块:/SA/doc/logic/code ...
2016-12-15 12:37:57 [SQL Time]sql 执行时间:0ms, exec KSQL: select SA_DocLinkDefine,SA_DocLinkDefine.sDefineItems,SA_DocLinkDefine.sActivity,SA_DocLinkDefine.sPersonFID from SA_DocLinkDefine SA_DocLinkDefine where (SA_DocLinkDefine.sProcess='/guojinerp/tczjrbb/process/zjrbb/inputzjrbb/inputzjrbbProcess' and (SA_DocLinkDefine.sActivity='' or SA_DocLinkDefine.sActivity IS NULL)) or (SA_DocLinkDefine.sProcess='/guojinerp/tczjrbb/process/zjrbb/inputzjrbb/inputzjrbbProcess' and SA_DocLinkDefine.sActivity='mainActivity')  order by SA_DocLinkDefine.sActivity desc
  --> sql:SELECT  SA_DocLinkDefine.sID, SA_DocLinkDefine.SDEFINEITEMS AS sDefineItems, SA_DocLinkDefine.SACTIVITY AS sActivity, SA_DocLinkDefine.SPERSONFID AS sPersonFID FROM SA_DocLinkDefine SA_DocLinkDefine  WHERE  ( (SA_DocLinkDefine.SPROCESS = ?) AND ( (SA_DocLinkDefine.SACTIVITY = ?) OR (SA_DocLinkDefine.SACTIVITY IS NULL) ) ) OR ( (SA_DocLinkDefine.SPROCESS = ?) AND (SA_DocLinkDefine.SACTIVITY = ?) )   ORDER BY SA_DocLinkDefine.SACTIVITY DESC
--> binds:[/guojinerp/tczjrbb/process/zjrbb/inputzjrbb/inputzjrbbProcess, , /guojinerp/tczjrbb/process/zjrbb/inputzjrbb/inputzjrbbProcess, mainActivity]
2016-12-15 12:37:57 [SQL Time]sql 执行时间:0ms, exec KSQL: SELECT SA_OPOrg.*  FROM SA_OPOrg SA_OPOrg WHERE (SA_OPOrg.sValidState >= 0) AND ((SA_OPOrg.sValidState = 1) AND (SA_OPOrg.sParent IS NULL)) ORDER BY SA_OPOrg.sSequence asc LIMIT 0, 20
  --> sql:SELECT  SA_OPOrg.sID AS SA_OPOrg, SA_OPOrg.SADDRESS AS sAddress, SA_OPOrg.SCODE AS sCode, SA_OPOrg.SDESCRIPTION AS sDescription, SA_OPOrg.SFCODE AS sFCode, SA_OPOrg.sFID AS sFID, SA_OPOrg.sFName AS sFName, SA_OPOrg.SFAX AS sFax, SA_OPOrg.SLEVEL AS sLevel, SA_OPOrg.SLONGNAME AS sLongName, SA_OPOrg.SNAME AS sName, SA_OPOrg.SNODEKIND AS sNodeKind, SA_OPOrg.SORGKINDID AS sOrgKindID, SA_OPOrg.sParent AS sParent, SA_OPOrg.SPERSONID AS sPersonID, SA_OPOrg.SPHONE AS sPhone, SA_OPOrg.SSEQUENCE AS sSequence, SA_OPOrg.SVALIDSTATE AS sValidState, SA_OPOrg.SWXDEPTID AS sWxDeptID, SA_OPOrg.SZIP AS sZip, SA_OPOrg.VERSION AS version FROM SA_OPOrg SA_OPOrg  WHERE  (SA_OPOrg.SVALIDSTATE >= ?) AND ( (SA_OPOrg.SVALIDSTATE = ?) AND (SA_OPOrg.sParent IS NULL) )   ORDER BY SA_OPOrg.SSEQUENCE ASC
--> binds:[0, 1]
2016-12-15 12:37:57 [SQL Time]sql 执行时间:0ms, exec KSQL:
  --> sql:SELECT count(*) FROM SA_OPOrg SA_OPOrg  WHERE  (SA_OPOrg.SVALIDSTATE >= ?) AND ( (SA_OPOrg.SVALIDSTATE = ?) AND (SA_OPOrg.sParent IS NULL) )
--> binds:[0, 1]
2016-12-15 12:37:58 [SQL Time]sql 执行时间:0ms, exec KSQL: SELECT SA_OPOrg.*  FROM SA_OPOrg SA_OPOrg WHERE (SA_OPOrg.sValidState >= 0) AND ((SA_OPOrg.sValidState = 1) AND (SA_OPOrg.sParent IS NULL)) ORDER BY SA_OPOrg.sSequence asc LIMIT 0, 20
  --> sql:SELECT  SA_OPOrg.sID AS SA_OPOrg, SA_OPOrg.SADDRESS AS sAddress, SA_OPOrg.SCODE AS sCode, SA_OPOrg.SDESCRIPTION AS sDescription, SA_OPOrg.SFCODE AS sFCode, SA_OPOrg.sFID AS sFID, SA_OPOrg.sFName AS sFName, SA_OPOrg.SFAX AS sFax, SA_OPOrg.SLEVEL AS sLevel, SA_OPOrg.SLONGNAME AS sLongName, SA_OPOrg.SNAME AS sName, SA_OPOrg.SNODEKIND AS sNodeKind, SA_OPOrg.SORGKINDID AS sOrgKindID, SA_OPOrg.sParent AS sParent, SA_OPOrg.SPERSONID AS sPersonID, SA_OPOrg.SPHONE AS sPhone, SA_OPOrg.SSEQUENCE AS sSequence, SA_OPOrg.SVALIDSTATE AS sValidState, SA_OPOrg.SWXDEPTID AS sWxDeptID, SA_OPOrg.SZIP AS sZip, SA_OPOrg.VERSION AS version FROM SA_OPOrg SA_OPOrg  WHERE  (SA_OPOrg.SVALIDSTATE >= ?) AND ( (SA_OPOrg.SVALIDSTATE = ?) AND (SA_OPOrg.sParent IS NULL) )   ORDER BY SA_OPOrg.SSEQUENCE ASC
--> binds:[0, 1]
2016-12-15 12:37:58 [SQL Time]sql 执行时间:15ms, exec KSQL:
  --> sql:SELECT count(*) FROM SA_OPOrg SA_OPOrg  WHERE  (SA_OPOrg.SVALIDSTATE >= ?) AND ( (SA_OPOrg.SVALIDSTATE = ?) AND (SA_OPOrg.sParent IS NULL) )
--> binds:[0, 1]
2016-12-15 12:38:01 [SQL Time]sql 执行时间:0ms, exec KSQL: SELECT SA_OPOrg.*  FROM SA_OPOrg SA_OPOrg WHERE (SA_OPOrg.sValidState >= 0) AND ((SA_OPOrg.sValidState = 1) AND (SA_OPOrg.sParent='ORG01')) ORDER BY SA_OPOrg.sSequence asc LIMIT 0, 20
  --> sql:SELECT  SA_OPOrg.sID AS SA_OPOrg, SA_OPOrg.SADDRESS AS sAddress, SA_OPOrg.SCODE AS sCode, SA_OPOrg.SDESCRIPTION AS sDescription, SA_OPOrg.SFCODE AS sFCode, SA_OPOrg.sFID AS sFID, SA_OPOrg.sFName AS sFName, SA_OPOrg.SFAX AS sFax, SA_OPOrg.SLEVEL AS sLevel, SA_OPOrg.SLONGNAME AS sLongName, SA_OPOrg.SNAME AS sName, SA_OPOrg.SNODEKIND AS sNodeKind, SA_OPOrg.SORGKINDID AS sOrgKindID, SA_OPOrg.sParent AS sParent, SA_OPOrg.SPERSONID AS sPersonID, SA_OPOrg.SPHONE AS sPhone, SA_OPOrg.SSEQUENCE AS sSequence, SA_OPOrg.SVALIDSTATE AS sValidState, SA_OPOrg.SWXDEPTID AS sWxDeptID, SA_OPOrg.SZIP AS sZip, SA_OPOrg.VERSION AS version FROM SA_OPOrg SA_OPOrg  WHERE  (SA_OPOrg.SVALIDSTATE >= ?) AND ( (SA_OPOrg.SVALIDSTATE = ?) AND (SA_OPOrg.sParent = ?) )   ORDER BY SA_OPOrg.SSEQUENCE ASC
--> binds:[0, 1, ORG01]
2016-12-15 12:38:01 [SQL Time]sql 执行时间:0ms, exec KSQL:
  --> sql:SELECT count(*) FROM SA_OPOrg SA_OPOrg  WHERE  (SA_OPOrg.SVALIDSTATE >= ?) AND ( (SA_OPOrg.SVALIDSTATE = ?) AND (SA_OPOrg.sParent = ?) )
--> binds:[0, 1, ORG01]
2016-12-15 12:38:03 [SQL Time]sql 执行时间:0ms, exec KSQL: SELECT SA_OPOrg.*  FROM SA_OPOrg SA_OPOrg WHERE (SA_OPOrg.sValidState >= 0) AND ((SA_OPOrg.sValidState = 1) AND (SA_OPOrg.sParent='VZ7VScuQds3ihWL12CN')) ORDER BY SA_OPOrg.sSequence asc LIMIT 0, 20
  --> sql:SELECT  SA_OPOrg.sID AS SA_OPOrg, SA_OPOrg.SADDRESS AS sAddress, SA_OPOrg.SCODE AS sCode, SA_OPOrg.SDESCRIPTION AS sDescription, SA_OPOrg.SFCODE AS sFCode, SA_OPOrg.sFID AS sFID, SA_OPOrg.sFName AS sFName, SA_OPOrg.SFAX AS sFax, SA_OPOrg.SLEVEL AS sLevel, SA_OPOrg.SLONGNAME AS sLongName, SA_OPOrg.SNAME AS sName, SA_OPOrg.SNODEKIND AS sNodeKind, SA_OPOrg.SORGKINDID AS sOrgKindID, SA_OPOrg.sParent AS sParent, SA_OPOrg.SPERSONID AS sPersonID, SA_OPOrg.SPHONE AS sPhone, SA_OPOrg.SSEQUENCE AS sSequence, SA_OPOrg.SVALIDSTATE AS sValidState, SA_OPOrg.SWXDEPTID AS sWxDeptID, SA_OPOrg.SZIP AS sZip, SA_OPOrg.VERSION AS version FROM SA_OPOrg SA_OPOrg  WHERE  (SA_OPOrg.SVALIDSTATE >= ?) AND ( (SA_OPOrg.SVALIDSTATE = ?) AND (SA_OPOrg.sParent = ?) )   ORDER BY SA_OPOrg.SSEQUENCE ASC
--> binds:[0, 1, VZ7VScuQds3ihWL12CN]
2016-12-15 12:38:03 [SQL Time]sql 执行时间:0ms, exec KSQL:
  --> sql:SELECT count(*) FROM SA_OPOrg SA_OPOrg  WHERE  (SA_OPOrg.SVALIDSTATE >= ?) AND ( (SA_OPOrg.SVALIDSTATE = ?) AND (SA_OPOrg.sParent = ?) )
--> binds:[0, 1, VZ7VScuQds3ihWL12CN]
回复 支持 反对

使用道具 举报

91

主题

13万

帖子

3万

积分

管理员

Rank: 9Rank: 9Rank: 9

积分
36064
发表于 2016-12-15 14:09:27 | 显示全部楼层
看orgSelectPC在点下拉的时候控制台输出的sql啊
远程的联系方法QQ1392416607,添加好友时,需在备注里注明其论坛名字及ID,公司等信息
发远程时同时也发一下帖子地址,方便了解要解决的问题  WeX5教程  WeX5下载



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

使用道具 举报

41

主题

303

帖子

877

积分

高级会员

Rank: 4

积分
877
QQ
 楼主| 发表于 2016-12-15 16:13:40 | 显示全部楼层
2016-12-15 16:16:14 [SQL Time]sql 执行时间:0ms, exec KSQL: SELECT SA_OPOrg.*  FROM SA_OPOrg SA_OPOrg WHERE (SA_OPOrg.sValidState >= 0) AND ((SA_OPOrg.sValidState = 1) AND (SA_OPOrg.sParent IS NULL)) ORDER BY SA_OPOrg.sSequence asc LIMIT 0, 20
  --> sql:SELECT  SA_OPOrg.sID AS SA_OPOrg, SA_OPOrg.SADDRESS AS sAddress, SA_OPOrg.SCODE AS sCode, SA_OPOrg.SDESCRIPTION AS sDescription, SA_OPOrg.SFCODE AS sFCode, SA_OPOrg.sFID AS sFID, SA_OPOrg.sFName AS sFName, SA_OPOrg.SFAX AS sFax, SA_OPOrg.SLEVEL AS sLevel, SA_OPOrg.SLONGNAME AS sLongName, SA_OPOrg.SNAME AS sName, SA_OPOrg.SNODEKIND AS sNodeKind, SA_OPOrg.SORGKINDID AS sOrgKindID, SA_OPOrg.sParent AS sParent, SA_OPOrg.SPERSONID AS sPersonID, SA_OPOrg.SPHONE AS sPhone, SA_OPOrg.SSEQUENCE AS sSequence, SA_OPOrg.SVALIDSTATE AS sValidState, SA_OPOrg.SWXDEPTID AS sWxDeptID, SA_OPOrg.SZIP AS sZip, SA_OPOrg.VERSION AS version FROM SA_OPOrg SA_OPOrg  WHERE  (SA_OPOrg.SVALIDSTATE >= ?) AND ( (SA_OPOrg.SVALIDSTATE = ?) AND (SA_OPOrg.sParent IS NULL) )   ORDER BY SA_OPOrg.SSEQUENCE ASC
--> binds:[0, 1]
2016-12-15 16:16:14 [SQL Time]sql 执行时间:0ms, exec KSQL:
  --> sql:SELECT count(*) FROM SA_OPOrg SA_OPOrg  WHERE  (SA_OPOrg.SVALIDSTATE >= ?) AND ( (SA_OPOrg.SVALIDSTATE = ?) AND (SA_OPOrg.sParent IS NULL) )
--> binds:[0, 1]
2016-12-15 16:16:15 [SQL Time]sql 执行时间:0ms, exec KSQL: SELECT SA_OPOrg.*  FROM SA_OPOrg SA_OPOrg WHERE (SA_OPOrg.sValidState >= 0) AND ((SA_OPOrg.sValidState = 1) AND (SA_OPOrg.sParent='ORG01')) ORDER BY SA_OPOrg.sSequence asc LIMIT 0, 20
  --> sql:SELECT  SA_OPOrg.sID AS SA_OPOrg, SA_OPOrg.SADDRESS AS sAddress, SA_OPOrg.SCODE AS sCode, SA_OPOrg.SDESCRIPTION AS sDescription, SA_OPOrg.SFCODE AS sFCode, SA_OPOrg.sFID AS sFID, SA_OPOrg.sFName AS sFName, SA_OPOrg.SFAX AS sFax, SA_OPOrg.SLEVEL AS sLevel, SA_OPOrg.SLONGNAME AS sLongName, SA_OPOrg.SNAME AS sName, SA_OPOrg.SNODEKIND AS sNodeKind, SA_OPOrg.SORGKINDID AS sOrgKindID, SA_OPOrg.sParent AS sParent, SA_OPOrg.SPERSONID AS sPersonID, SA_OPOrg.SPHONE AS sPhone, SA_OPOrg.SSEQUENCE AS sSequence, SA_OPOrg.SVALIDSTATE AS sValidState, SA_OPOrg.SWXDEPTID AS sWxDeptID, SA_OPOrg.SZIP AS sZip, SA_OPOrg.VERSION AS version FROM SA_OPOrg SA_OPOrg  WHERE  (SA_OPOrg.SVALIDSTATE >= ?) AND ( (SA_OPOrg.SVALIDSTATE = ?) AND (SA_OPOrg.sParent = ?) )   ORDER BY SA_OPOrg.SSEQUENCE ASC
--> binds:[0, 1, ORG01]
2016-12-15 16:16:15 [SQL Time]sql 执行时间:0ms, exec KSQL:
  --> sql:SELECT count(*) FROM SA_OPOrg SA_OPOrg  WHERE  (SA_OPOrg.SVALIDSTATE >= ?) AND ( (SA_OPOrg.SVALIDSTATE = ?) AND (SA_OPOrg.sParent = ?) )
--> binds:[0, 1, ORG01]
2016-12-15 16:16:17 [SQL Time]sql 执行时间:0ms, exec KSQL: SELECT SA_OPOrg.*  FROM SA_OPOrg SA_OPOrg WHERE (SA_OPOrg.sValidState >= 0) AND ((SA_OPOrg.sValidState = 1) AND (SA_OPOrg.sParent='VZ7VScuQds3ihWL12CN')) ORDER BY SA_OPOrg.sSequence asc LIMIT 0, 20
  --> sql:SELECT  SA_OPOrg.sID AS SA_OPOrg, SA_OPOrg.SADDRESS AS sAddress, SA_OPOrg.SCODE AS sCode, SA_OPOrg.SDESCRIPTION AS sDescription, SA_OPOrg.SFCODE AS sFCode, SA_OPOrg.sFID AS sFID, SA_OPOrg.sFName AS sFName, SA_OPOrg.SFAX AS sFax, SA_OPOrg.SLEVEL AS sLevel, SA_OPOrg.SLONGNAME AS sLongName, SA_OPOrg.SNAME AS sName, SA_OPOrg.SNODEKIND AS sNodeKind, SA_OPOrg.SORGKINDID AS sOrgKindID, SA_OPOrg.sParent AS sParent, SA_OPOrg.SPERSONID AS sPersonID, SA_OPOrg.SPHONE AS sPhone, SA_OPOrg.SSEQUENCE AS sSequence, SA_OPOrg.SVALIDSTATE AS sValidState, SA_OPOrg.SWXDEPTID AS sWxDeptID, SA_OPOrg.SZIP AS sZip, SA_OPOrg.VERSION AS version FROM SA_OPOrg SA_OPOrg  WHERE  (SA_OPOrg.SVALIDSTATE >= ?) AND ( (SA_OPOrg.SVALIDSTATE = ?) AND (SA_OPOrg.sParent = ?) )   ORDER BY SA_OPOrg.SSEQUENCE ASC
--> binds:[0, 1, VZ7VScuQds3ihWL12CN]
2016-12-15 16:16:17 [SQL Time]sql 执行时间:0ms, exec KSQL:
  --> sql:SELECT count(*) FROM SA_OPOrg SA_OPOrg  WHERE  (SA_OPOrg.SVALIDSTATE >= ?) AND ( (SA_OPOrg.SVALIDSTATE = ?) AND (SA_OPOrg.sParent = ?) )
--> binds:[0, 1, VZ7VScuQds3ihWL12CN]
回复 支持 反对

使用道具 举报

91

主题

13万

帖子

3万

积分

管理员

Rank: 9Rank: 9Rank: 9

积分
36064
发表于 2016-12-15 17:06:09 | 显示全部楼层
很明显sql中没有你的条件啊

具体代码发一下看看
远程的联系方法QQ1392416607,添加好友时,需在备注里注明其论坛名字及ID,公司等信息
发远程时同时也发一下帖子地址,方便了解要解决的问题  WeX5教程  WeX5下载



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

使用道具 举报

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

本版积分规则

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

GMT+8, 2024-11-21 21:54 , Processed in 0.062621 second(s), 33 queries .

Powered by Discuz! X3.4

© 2001-2013 Comsenz Inc.

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