简体   繁体   English

Dynamics CRM 根据父表单/实体在新表单/实体中填充关系数据

[英]Dynamics CRM fill relationship data in new form/entity according to parent form/entity

When I open some company in CRM, I have ability to add new contact from that particular company.当我在 CRM 中开设一些公司时,我可以添加来自该特定公司的新联系人。 When new contact form is open it is already filled with mapping values from that company (company name, telephone, address...).当新的联系表单打开时,它已经填充了来自该公司的映射值(公司名称、电话、地址...)。

That is a great feature.这是一个很棒的功能。 I want to implement that by myself with web resource in JavaScript.我想用 JavaScript 中的网络资源自己实现。 Web resource only contains buttons to the new entity. Web 资源仅包含指向新实体的按钮。 I want to open new entity (in my case to open new contact from particular company) and that new entity should have already filled input according to some custom relationship mapping which I made.我想打开新实体(在我的情况下是打开来自特定公司的新联系人),并且该新实体应该已经根据我制作的一些自定义关系映射填写了输入。

How I did that:我是如何做到的:

1) Am looking for custom relationship name (it is in configuration). 1)正在寻找自定义关系名称(在配置中)。

2) After that I am looking for mapping fields between two entities according to relationship. 2)之后,我根据关系寻找两个实体之间的映射字段。

3) Finally according to page "Set field values using parameters passed to a form" ( https://msdn.microsoft.com/en-us/library/gg334375.aspx ) I am passing mapping fields value from company to contact form. 3)最后根据页面“使用传递给表单的参数设置字段值”( https://msdn.microsoft.com/en-us/library/gg334375.aspx )我将映射字段值从公司传递到联系表单。

Is there any easier way to do that, just to pass name of relationship and particular company and that my new contact form be automatically filed with values from company according to relationship ?有没有更简单的方法来做到这一点,只是传递关系和特定公司的名称,并且我的新联系表格会根据关系自动提交公司的值?

You can issue an InitializeFromRequest to the server.您可以向服务器发出InitializeFromRequest The server returns an InitializeFromResponse holding an Entity property in which you will find the prefilled attributes.服务器返回一个InitializeFromResponse ,其中包含一个Entity属性,您将在其中找到预填充的属性。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 Dynamics crm 365 快速创建表单获取父实体数据 - Dynamics crm 365 quick create form get parent entity data Dynamics CRM 2013:从实体设置表单中的默认值 - Dynamics CRM 2013: Setting default values in a form from an entity 在crm JS中使用params打开新的实体表单 - open new entity form with params in crm JS CRM Dynamics,如何使用一种形式传递值,并使用Xrm.Utility.openEntityForm()在新的Entity(form)中设置值; - CRM Dynamics , How to pass values from one form and set the values in a new Entity(form) using Xrm.Utility.openEntityForm(); 从弹出式CRM Dynamics 2015中的父表单获取数据 - Get data from parent form in a popup CRM Dynamics 2015 如何使用 JavaScript 在 Dynamics 365 CRM 内部部署的表单上填写父查询? - How to use JavaScript to fill parent lookup on form in Dynamics 365 CRM on-premise? 如何确定Dynamics CRM 2013中是否以实体形式满足所有业务规则? - How can I determine if all business rules are met in an entity form in Dynamics CRM 2013? CRM 2011如何使用Java来使用子/相关实体表单中的值更新父实体字段 - CRM 2011 how to update a Parent entity field with values from a child/related entity form using Javascript 使用 JavaScript 的 Microsoft Dynamics 实体表单验证 - Microsoft Dynamics Entity Form Validation Using JavaScript Dynamics 365 将实体类型传递给表单 - Dynamics 365 Passing Regarding Entity Type to a Form
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM