表单Python插件,根据一字段过滤另一个辅助资料列表原创
38人赞赏了该文章
205次浏览
编辑于2024年03月18日 11:29:19
import clr clr.AddReference('mscorlib') clr.AddReference('Kingdee.BOS.Core') from System import * from Kingdee.BOS.Core.DynamicForm.PlugIn import * from Kingdee.BOS.Core.DynamicForm.PlugIn.Args import * from Kingdee.BOS.Util import * def BeforeF7Select(e): if (e.FieldKey.Equals("F_XVKJ_LCB", StringComparison.OrdinalIgnoreCase)): if this.Model.GetValue("F_XVKJ_ddlb") is None: return #取得界面上字段的值,添加到列表过滤 glz=str(this.Model.GetValue("F_XVKJ_ddlb")[1]) # 增加辅助资料列表快捷过滤 kjgl=" FNumber like '" + glz +"%'" #this.View.ShowMessage(kjgl) e.ListFilterParameter.Filter = StringUtils.JoinFilterString(e.ListFilterParameter.Filter, kjgl);
推荐阅读