@@ -33,6 +33,10 @@ |
||
| 33 | 33 | |
| 34 | 34 | protected $definition; |
| 35 | 35 | |
| 36 | + /** |
|
| 37 | + * @param string $name |
|
| 38 | + * @param string $title |
|
| 39 | + */ |
|
| 36 | 40 | public function __construct($name, $title, WorkflowDefinition $definition) |
| 37 | 41 | { |
| 38 | 42 | $this->definition = $definition; |
@@ -5,7 +5,6 @@ |
||
| 5 | 5 | use ReflectionClass; |
| 6 | 6 | use SilverStripe\Control\HTTPResponse; |
| 7 | 7 | use SilverStripe\Core\ClassInfo; |
| 8 | -use SilverStripe\Core\Manifest\ModuleLoader; |
|
| 9 | 8 | use SilverStripe\Forms\FormField; |
| 10 | 9 | use SilverStripe\ORM\ArrayList; |
| 11 | 10 | use SilverStripe\Security\SecurityToken; |
@@ -27,6 +27,10 @@ |
||
| 27 | 27 | protected $parent; |
| 28 | 28 | protected $name; |
| 29 | 29 | |
| 30 | + /** |
|
| 31 | + * @param WorkflowField $parent |
|
| 32 | + * @param string $name |
|
| 33 | + */ |
|
| 30 | 34 | public function __construct($parent, $name) |
| 31 | 35 | { |
| 32 | 36 | $this->parent = $parent; |
@@ -3,7 +3,6 @@ |
||
| 3 | 3 | namespace Symbiote\AdvancedWorkflow\Forms; |
| 4 | 4 | |
| 5 | 5 | use SilverStripe\Forms\Form; |
| 6 | -use FormResponse; |
|
| 7 | 6 | use SilverStripe\Control\Director; |
| 8 | 7 | use SilverStripe\Control\HTTPResponse; |
| 9 | 8 | use SilverStripe\Core\Convert; |
@@ -66,7 +66,7 @@ discard block |
||
| 66 | 66 | * Which columns are handled by this component |
| 67 | 67 | * |
| 68 | 68 | * @param type $gridField |
| 69 | - * @return type |
|
| 69 | + * @return string[] |
|
| 70 | 70 | */ |
| 71 | 71 | public function getColumnsHandled($gridField) |
| 72 | 72 | { |
@@ -77,7 +77,7 @@ discard block |
||
| 77 | 77 | * Which GridField actions are this component handling |
| 78 | 78 | * |
| 79 | 79 | * @param GridField $gridField |
| 80 | - * @return array |
|
| 80 | + * @return string[] |
|
| 81 | 81 | */ |
| 82 | 82 | public function getActions($gridField) |
| 83 | 83 | { |
@@ -73,7 +73,7 @@ discard block |
||
| 73 | 73 | * Which columns are handled by this component |
| 74 | 74 | * |
| 75 | 75 | * @param type $gridField |
| 76 | - * @return type |
|
| 76 | + * @return string[] |
|
| 77 | 77 | */ |
| 78 | 78 | public function getColumnsHandled($gridField) |
| 79 | 79 | { |
@@ -85,7 +85,7 @@ discard block |
||
| 85 | 85 | * @param DataObject $record |
| 86 | 86 | * @param string $columnName |
| 87 | 87 | * |
| 88 | - * @return string - the HTML for the column |
|
| 88 | + * @return \SilverStripe\ORM\FieldType\DBHTMLText - the HTML for the column |
|
| 89 | 89 | */ |
| 90 | 90 | public function getColumnContent($gridField, $record, $columnName) |
| 91 | 91 | { |
@@ -82,6 +82,7 @@ discard block |
||
| 82 | 82 | * Will recursively query parent elements until it finds one, if available |
| 83 | 83 | * |
| 84 | 84 | * @param DataObject $dataObject |
| 85 | + * @return null|DataObject |
|
| 85 | 86 | */ |
| 86 | 87 | public function getDefinitionFor(DataObject $dataObject) |
| 87 | 88 | { |
@@ -133,6 +134,7 @@ discard block |
||
| 133 | 134 | * Retrieves and collates the workflow definitions for a data object, where the first element will be the main workflow definition. |
| 134 | 135 | * |
| 135 | 136 | * @param DataObject object |
| 137 | + * @param DataObject $object |
|
| 136 | 138 | * @return array |
| 137 | 139 | */ |
| 138 | 140 | |
@@ -163,7 +165,7 @@ discard block |
||
| 163 | 165 | * |
| 164 | 166 | * @param mixed $item |
| 165 | 167 | * @param bool $includeComplete |
| 166 | - * @return WorkflowInstance|null |
|
| 168 | + * @return DataObject|null |
|
| 167 | 169 | */ |
| 168 | 170 | public function getWorkflowFor($item, $includeComplete = false) |
| 169 | 171 | { |
@@ -182,6 +184,7 @@ discard block |
||
| 182 | 184 | /** |
| 183 | 185 | * Get all the workflow action instances for an item |
| 184 | 186 | * |
| 187 | + * @param DataObject $item |
|
| 185 | 188 | * @return DataList|null |
| 186 | 189 | */ |
| 187 | 190 | public function getWorkflowHistoryFor($item, $limit = null) |
@@ -312,7 +315,6 @@ discard block |
||
| 312 | 315 | /** |
| 313 | 316 | * Get items that the passed-in user has awaiting for them to action |
| 314 | 317 | * |
| 315 | - * @param Member $member |
|
| 316 | 318 | * @return DataList |
| 317 | 319 | */ |
| 318 | 320 | public function userPendingItems(Member $user) |
@@ -340,7 +342,6 @@ discard block |
||
| 340 | 342 | /** |
| 341 | 343 | * Get items that the passed-in user has submitted for workflow review |
| 342 | 344 | * |
| 343 | - * @param Member $member |
|
| 344 | 345 | * @return DataList |
| 345 | 346 | */ |
| 346 | 347 | public function userSubmittedItems(Member $user) |
@@ -83,6 +83,9 @@ discard block |
||
| 83 | 83 | */ |
| 84 | 84 | protected $structure; |
| 85 | 85 | |
| 86 | + /** |
|
| 87 | + * @param string $name |
|
| 88 | + */ |
|
| 86 | 89 | public function __construct($name, $description = '', $version = '0.0', $remindDays = 0, $sort = 0) |
| 87 | 90 | { |
| 88 | 91 | $this->name = $name; |
@@ -131,7 +134,7 @@ discard block |
||
| 131 | 134 | * Creates the relevant data objects for this structure, returning an array |
| 132 | 135 | * of actions in the order they've been created |
| 133 | 136 | * |
| 134 | - * @param WorkflowDefinition $definitino |
|
| 137 | + * @param WorkflowDefinition $definition |
|
| 135 | 138 | * An optional workflow definition to bind the actions into |
| 136 | 139 | * @return array |
| 137 | 140 | */ |
@@ -183,7 +186,7 @@ discard block |
||
| 183 | 186 | * Create a workflow action based on a template |
| 184 | 187 | * |
| 185 | 188 | * @param string $name |
| 186 | - * @param array $template |
|
| 189 | + * @param array $actionTemplate |
|
| 187 | 190 | * @param WorkflowDefinition $definition |
| 188 | 191 | * @return WorkflowAction |
| 189 | 192 | * @throws Exception |
@@ -8,7 +8,6 @@ |
||
| 8 | 8 | use SilverStripe\ORM\DataObject; |
| 9 | 9 | use SilverStripe\ORM\FieldType\DBDatetime; |
| 10 | 10 | use SilverStripe\Translatable\Model\Translatable; |
| 11 | -use SilverStripe\Security\Member; |
|
| 12 | 11 | use SilverStripe\Subsites\Extensions\SiteTreeSubsites; |
| 13 | 12 | use SilverStripe\Versioned\Versioned; |
| 14 | 13 | use Symbiote\AdvancedWorkflow\DataObjects\WorkflowAction; |
@@ -27,6 +27,10 @@ |
||
| 27 | 27 | protected $parent; |
| 28 | 28 | protected $name; |
| 29 | 29 | |
| 30 | + /** |
|
| 31 | + * @param WorkflowField $parent |
|
| 32 | + * @param string $name |
|
| 33 | + */ |
|
| 30 | 34 | public function __construct($parent, $name) |
| 31 | 35 | { |
| 32 | 36 | $this->parent = $parent; |