简体   繁体   English

Dynamics CRM插件父上下文

[英]Dynamics CRM plugin parent context

I have a requirement to prevent the closing of an appointment from the Contact form (in the list of activities). 我有一个要求防止从“联系表”(活动列表中)中关闭约会。 How can I detect that the appointment was closed from the Contact form? 如何从“联系人”表单中检测到约会已关闭? I tried with context.ParentContext.PrimaryEntityName , but it is "appointment" even in this case! 我尝试使用context.ParentContext.PrimaryEntityName ,但是即使在这种情况下,它也是“约会”! The plugin is postoperation synchronous. 该插件是后操作同步的。

Plugin does not know from where action is initiated. 插件不知道从何处启动操作。 In your case, you want to identify if the Close appointment action is taken by User - navigate from Contact form. 对于您的情况,您想确定“关闭约会”操作是否由用户执行-从“联系人”表单中导航。

Better to remove the navigation - Activities from Contact or filter out the Appointments in Contacts - Activities Associated view. 最好从“联系人”中删除导航-“活动”,或过滤掉“联系人-活动关联”视图中的约会。 If needed, may be a new view can be created & set it as default. 如果需要,可以创建一个新视图并将其设置为默认视图。

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

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM