相关列表仅工作一半 [英] Related List only half-working

查看:84
本文介绍了相关列表仅工作一半的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我对相关列表有疑问.开箱即用,我只能让它工作一半(IMHO).

I have a question about related lists. Out-of-the-box I can only get it half working (IMHO).

首先,我正在使用SharePoint 2016.我知道这是一个SP 2013论坛,但没有看到SP 2016论坛.这是我的观察.我创建了两个自定义列表,它们将成为父列表和子列表.我在每个字段中创建了一个公共字段并进行了配置 子列表中的列,作为对父列表中相应列的查找字段.

First, I'm using SharePoint 2016.  I know this is a SP 2013 forum but I didn't see a SP 2016 forum.  Here's my observation.  I created two custom lists that would be the parent and child list.  I created a common field in each and configured the column in the child list as a lookup field against the corresponding column in the parent. 

接下来,我在父显示表单中插入了 相关列表 Web部件.在网络部分 连接 -> 获取过滤器值 下拉菜单指向正确的父列表,并且每个列表中的正确字段都相互关联.

Next I inserted a Related List web part in the parent display form.  In the  the web part, the Connections--> Get Filter Values From drop-down points to the proper parent list and the correct fields in each are associated with each other.

现在,当我在父列表中显示记录时,我可以正确看到所有关联的子记录.我可以从列表中打开它们,甚至可以对其进行编辑.但是,当我从父记录的DispForm添加新的子记录时,子NewForm却没有 拥有父母的钥匙"预先输入.我必须从列表中选择父记录.

Now when I display a record in the parent list I correctly see all the associated child records.  I can open any them from the list and even edit them.  But when I add a new child record from the parent record's DispForm, the child NewForm doesn't have the parent's "key" pre-entered in.  I have to pick the parent record from a list.

是否有任何方法可以自动获取包含在子记录NewForm中的父记录中的common字段?

Is there any way to get the value of the common field in the parent record automatically included in the child record NewForm? 

我已经看到了很多有关使用Java脚本和JQuery来获取传递给子NewForm的父值的讨论.如果必须包含脚本,可以.但是要确保没有现成的解决方案.太接近了 完成,我希望我错过了一些东西.

I've seen a lot of discussion on using java script and JQuery to get the parent value passed to the child NewForm.  If I have to include a script, fine.  But wanted to make sure there was no out-of-the-box solution.  It's so close to being complete I was hoping I missed something.

如果我必须编写脚本,可以有人指出我与SP 2016兼容的版本.

If I have to write a script can someone point me to a SP 2016 compatible version.

谢谢

账单

推荐答案

没有现成的解决方案可以自动在NewForm中填充父项数据

作为一种解决方法,我们可以使用InfoPath自定义新项目表单,以自动填充项目数据. 从父级列表中检索数据,然后为字段添加默认值.

1.在InfoPath中打开表单.

2.点击数据"标签>下的数据连接".添加>接收数据> SharePoint库或列表>输入您的SharePoint网站的路径>选择列表.

3.选择要在表单中自动填充的字段.

4.输入数据连接的名称,然后单击完成.

5.右键单击文本框>文本框属性>默认值>插入字段或组>显示高级视图>选择您刚刚在步骤4创建的数据连接.

6.选择您要自动填充数据的字段.过滤数据>根据查找归档数据过滤数据.

此处是有关逐步在InfoPath中自动填充文本框的演示,以供您参考.它仍然具有有关SharePoint 2016的良好信息.

http://www.jeanpaulva.com/index.php/2013/12/31/auto-fill-textbox-in-infopath/

最好的问候,

Linda(张)


这篇关于相关列表仅工作一半的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆