Page 1 of 1

Ceate Work-Item(s) from Wiki-Form

Posted: Wed Mar 10, 2010 7:55 am
by thk007
Hi,

is it possible to create a Wiki-Form for creation of connected Work-Items? E.g. I want to create a changerequest-WI and (depending on some checkboxes) one to n task-WIs below the changerequest WI.

Thanks,
Thomas

Re: Ceate Work-Item(s) from Wiki-Form

Posted: Thu Mar 11, 2010 10:53 am
by NickEntin
Hi Thomas,

I'm not sure I understood you well:
- do you want on creation of linked WI open a Wiki page to define additional parameters?
- or you want to create WI from a wiki page so-to-say individually.

Second is possible via Velocity programming against Polarion API.
For the first I hardly imagine how this could work, so my initial answer is no.

Please note that creation of 1-to-n subitems automatically (depending e.g. on checkboxes of the custom fields of your CR is possible without involving of any Wiki).
As an entry point you may check http://extensions.polarion.com/polarion/extensions/extension.jsp?extension=PE-22.
Of course you may provide additional checks of custom fields (checkboxes) set in the Change Request and vary creation of subitems consequentially.

Best regards,
Nick

Re: Ceate Work-Item(s) from Wiki-Form

Posted: Fri Oct 29, 2010 10:39 am
by thk007
Hi,

thank you. The second one is what I want to do.

In the meantime I managed to read an existing workitem and I managed to create and save a new workitem thru a Wikipage.
But: I was not able to set my own description (plain text) for this new workitem.
Whatever I do: the resulting wi does not contain my description!

Can anybody give me an example where and how to add the description?

This is what already works:

Code: Select all

  $transactionService.beginTx()
  #set($newWorkItem = $trackerService.createWorkItem($project))
  $newWorkItem.setTitle("My Titel")
  $newWorkItem.setTimePoint($myTimepoint)
  $newWorkItem.setType($project.getWorkItemTypeEnum().wrapOption("changerequest"))
  $newWorkItem.addAssignee($myAssignee))
  $newWorkItem.setSeverity($project.getSeverityEnum().wrapOption("normal"))
  $newWorkItem.setPriority($project.getPriorityEnum().wrapOption("25.0"))
  $newWorkItem.save()
  $transactionService.endTx(false)


Thank you!

Thomas