Share this post on:

ActionView(fullName, required = true) : View?

Returns an action view by its full name.

ActionView Parameters

fullName : String
View full name in the form ‘SolutionName.ItemTypeName.ViewName’.

required : Boolean = true
False to return null if view was not found.

ActionView Examples

var view = ActionView('TargetSolution.TargetType.TargetActionView', false);

View(fullName, forState?, isAction = false, required = true) : View?

Returns a view by its full name or ID.

View Parameters

fullName : String
View full name in the form ‘Solution.ItemType.View’, or integer view ID.

forState? : String?
State name to search a view for.
There should be permission to the view in the specified state for the current user.
If null, there should be stateless permission for the current user.
Can be ‘*’ to ignore permissions.

isAction : Boolean? = false
False to exclude action views from search.
True to search only action views.
Null to search both action and non-action views.

required : Boolean = true
False to return null if view was not found.

View Examples

var view = View(1001);
var view = View('Solution.ItemType.View', null, null, false);

Views(viewType?, viewFormat?, fullName?, internal?) : View[]

Returns all views matching specified criteria.

Views Parameters

viewType? : String?
Can be ‘Items’, ‘New’, ‘Update’, ‘Read’, ‘Print’, ‘Report’, ‘Import’, ‘Template’, ‘Layout’, ‘EventHandler’, ‘Task’, ‘Generator’, ‘Custom’, ‘Override’.
Can be null to include all types.

viewFormat? : String?
Can be null to include all formats, or can be any supported format (e.g. ‘js’, ‘css’, ‘auto’).
Can start with ‘!’ to exclude format.

fullName? : String?
If not empty, then search by full name.

internal? : Boolean?
True to return internal views only.
False to return non-internal views only.
Null to return both internal and non-internal views.

Views Examples

var handlers = Views('EventHandler');
Share this post on:

Leave a Comment

Your email address will not be published. Required fields are marked *