Hello,
I’m learning to code & would like to have some help to enhance a free plugin I found and that I want to use into MSCRM 2011.
Link to the extension: http://blogs.msdn.com/b/paf/archive/2011/03/25/microsoft-dynamics-crm-2011-hierarchical-treeview-version-0-1.aspx
Solution Features
•Dynamically display associated entities with the current record.
•You can customize the display.
•You can open records from the list
What it looks like:
What I want to do:
display connections only. I could already get what you can see below on the screenshot (on the top, it is the Account name, and under, 2 contacts connected to the Account: Bob & Karsten):
I customizing the xml portion contained into the Web Ressouce by doing this (for the whole web resource code, you can find it on the link I provide before or By clicking here:
<script type="text/javascript"> var slConf = '<?xml version="1.0"?>' + '<hierarchies xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">' + '<hierarchy entity="account" pk="accountid" icon="gps_imgs/ico_account.png" displayField="name" UrlBody="/main.aspx?etc=1" UrlBodyExtra="extraqs=id=" UrlSuffix="pagetype=entityrecord">' + '<relatedEntity name="connection" pluralName="Connections" pk="connectionid" fk="record1id" displayField="name" icon="gps_imgs/ico_subaccount.png" UrlBody="main.aspx?etn=account" UrlBodyExtra="extraqs=id=" UrlSuffix="pagetype=entityrecord" />' + '</hierarchy>' + '</hierarchies>';</script>
Hierarchy :Represents the current entity
entity : schema name of the entity
pk : primary key of the entity
relatedEntity : represents an entity linked to the current record
fk : foreign key (this one, it don't understand it.)
Also, I don't understand this part:
displayField= "name|string,estimatedvalue|Money,estimatedclosedate|System.DateTime,closeprobability|int,ownerid|EntityReference" |
with this explanation 'If there are several attributes, you must use the separator ‘|’ between type and schema name and use a comma to separate different fields'
Personal Comment: why is it written 'Money', or 'int', or 'system.datetime', or 'string', what does it means, those are not fields, and not type of fields? (checked the metadata)
Finaly, what I would like to = also display the connections from Bob & Karsten into the same Tree View that is displayed on the account page, and for that, I don't know how to do, and even if, it is possible. You can expand the Account with a click, then you see the title 'Connections', you can also expand it, and then you see the 2 records connected to the Account. From here, I want also to be able to expand a record to see is connections when it has some by keeping the view like a tree (connections from bob have to be an other 'branch' of the Tree).
Help would be greatly appreciated.
Thank you and have a nice week-end!
Séb