Skip to end of banner
Go to start of banner

admCreateProject

Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 5 Next »

Availability

This routine is available starting with katl-commons 2.5.8.

Syntax

admCreateProject(pkey, pname, description, lead, url, categoryName, defaultIsUnassigned, avatarId)

Starting with version 3.1.0

admCreateProject(pkey, pname, description, lead, url, categoryName, defaultIsUnassigned, avatarId, projectTypeKey)

Description

Creates a new project, optionally offering support for category of the project

Creates the project and configures it with the default security level, default workflow scheme, etc.

Parameters

Parameter name

Type

Required

Description

 pkeystringyesProject key
pnamestringyesProject name.
descriptionstringyesProject description.
leadstringyesRepresents a valid user that should be assignable on the project.
urlstringyesURL of the project. Leave blank if no URL is available.
categoryNamestringyesName of the category.
defaultIsUnassignedbooleanyesSet it to 'true' if you don't want to assign issues to the project lead above.
avatarIdnumericyesSet it to a negative number or zero for the default avatar id. Otherwise, you need to choose a valid avatar id.
projectTypeKeystringnoSet the project type key. If it is not set, the default value is "business".

Return type

boolean

Returns 'true' if the project was created and 'false' if not.

Example

Example 1

admCreateProject("T3", "Thunderbolt3", "Three thunderbolts in a single hole", "zeus", "http://thunderbolts.olimpus.gr", "PUBLIC", false, 0);

 

Example 2

admCreateProject("T3", "Thunderbolt3", "Three thunderbolts in a single hole", "zeus", "http://thunderbolts.olimpus.gr", "PUBLIC", false, 0, "business");

Duplicates projects

It doesn't check if a project with the same key or name already exists. So far, Jira controller code allows the project version creation action.

You will need permissions to create a project.

See also

  • No labels