KamranAftab - Monday, December 16, 2013 9:01 AM:
Hi All,
I have created a custom change type (ETAR). I want it to behave like the ECR in that when I press the right mouse button on a part, it gives me an option to "Add Item(s) to Change" option. When I pick this option, a dialog comes up with "Change Type: " drop down. The drop down has values for the OOTB types listed. How do I add my custom change type to this drop down? Additionally, I would also like the changes shown in the Part grid "changes" list.
Thanks in advance.
Kamran
KamranAftab - Monday, December 16, 2013 2:10 PM:
I was able to figure this out by carrying out the following steps:
1. Modify method "PE_ChooseCMItem_API
- Add "ETAR" to "this.ChangeItemList"
ChooseCMItemDialog = function (itemTypeName)
{
document.isEditMode = true;
this.ItemTypeName = itemTypeName;
this.ChangeItemList = ["PR", "ECN", "ECR", "Simple ECO", "Simple MCO", "Express ECO", "Express DCO", "ETAR"];
2. Modify PE_AddChangeItem
- Add "case "ETAR": "
switch (typeName)
{
case "PR":
changeItem = new PRChangeItem(item);
break;
case "ECR":
case "ETAR":
case "ECN":
case "Express ECO":
case "Express DCO":
case "Simple ECO":
changeItem = new GenericChangeItem(item);
break;
case "Simple MCO":
changeItem = new MCOChangeItem(item);
break;
}