cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - You can change your system assigned username to something more personal in your community settings. X

How do I add an action only for a document subtype?

VladiSlav
17-Peridot

How do I add an action only for a document subtype?

Hello everyone, please tell me how to add an action to the "Actions" button for only one subtype of the document WTDocument?

ACCEPTED SOLUTION

Accepted Solutions
hlafkir
14-Alexandrite
(To:VladiSlav)

Hi

You may check for the property menufor described here :

Defining New Action Model

focus on the "menufor" keyword this point.

 

Just be aware of the article : CS312920 if this not work, a pre-validation is required.

 

Sample Code
The following is sample code for an action model that configures a subtype:
<!-- Copied from ChangeManagement-actionModels.xml -->
<!-- Originally copied from menu for wt.change2.WTChangeRequest2 -->
<model name="sample change request actions" menufor="WCTYPE|
wt.change2.WTChangeRequest2|org.default.www.SampleChangeRequest">
<action name="view" type="object"/>
<action name="SETLIFECYCLESTATE" type="pdmObject"/>
<action name="createSubscription" type="subscription"/>
<action name="separator" type="separator"/>
<action name="reviseChangeItems" type="change"/>
<action name="editCapabilityPackage" type="capabilityPackage"/>
<action name="create" type="approach" />
<action name="create" type="capabilityImplementationProject" />
<action name="separator" type="separator"/>
<action name="sandboxAddToProject" type="object"/>
<action name="SBAddToPrj" type="sandbox"/>
<action name="removeShare" type="object"/>
<action name="separator" type="separator"/>
<action name="ManageSecurity" type="accessPermission"/>
<action name="renameObjectWizard" type="object"/>
<action name="delete" type="object"/>
<action name="separator" type="separator"/>
<action name="separator" type="separator"/>
<action name="discuss" type="forum"/>
<action name="copy" type="object"/>
</model>
 
good luck !

View solution in original post

4 REPLIES 4
Florent
15-Moonstone
(To:VladiSlav)

You need to implement your own custom validator or filter.

 

Florent ROUSSEL
www.4cad.ca
hlafkir
14-Alexandrite
(To:VladiSlav)

Hi

You may check for the property menufor described here :

Defining New Action Model

focus on the "menufor" keyword this point.

 

Just be aware of the article : CS312920 if this not work, a pre-validation is required.

 

Sample Code
The following is sample code for an action model that configures a subtype:
<!-- Copied from ChangeManagement-actionModels.xml -->
<!-- Originally copied from menu for wt.change2.WTChangeRequest2 -->
<model name="sample change request actions" menufor="WCTYPE|
wt.change2.WTChangeRequest2|org.default.www.SampleChangeRequest">
<action name="view" type="object"/>
<action name="SETLIFECYCLESTATE" type="pdmObject"/>
<action name="createSubscription" type="subscription"/>
<action name="separator" type="separator"/>
<action name="reviseChangeItems" type="change"/>
<action name="editCapabilityPackage" type="capabilityPackage"/>
<action name="create" type="approach" />
<action name="create" type="capabilityImplementationProject" />
<action name="separator" type="separator"/>
<action name="sandboxAddToProject" type="object"/>
<action name="SBAddToPrj" type="sandbox"/>
<action name="removeShare" type="object"/>
<action name="separator" type="separator"/>
<action name="ManageSecurity" type="accessPermission"/>
<action name="renameObjectWizard" type="object"/>
<action name="delete" type="object"/>
<action name="separator" type="separator"/>
<action name="separator" type="separator"/>
<action name="discuss" type="forum"/>
<action name="copy" type="object"/>
</model>
 
good luck !
VladiSlav
17-Peridot
(To:hlafkir)

 

hlafkir ,Thank you very much, this is what you need

Hi VladiSlav, did this work for you?? i tried the same for one of the document subtype dint work, so need your suggestion

Announcements

Top Tags