@@ -115,17 +115,26 @@ |
||
115 | 115 | return $randomString; |
116 | 116 | } |
117 | 117 | |
118 | + /** |
|
119 | + * @param string $model |
|
120 | + */ |
|
118 | 121 | private function getWorkflow($model){ |
119 | 122 | $data = WorkflowModel::where('content_type', 'like', '%' . $model . '%')->get(); |
120 | 123 | return $data; |
121 | 124 | } |
122 | 125 | |
126 | + /** |
|
127 | + * @param string $state |
|
128 | + */ |
|
123 | 129 | private function getState($state){ |
124 | 130 | $name = \Transliteration::clean_filename(strtolower($state)); |
125 | 131 | $data = WorkflowState::where('status', 1)->where('name', 'like', '%' . $name . '%')->get(); |
126 | 132 | return $data; |
127 | 133 | } |
128 | 134 | |
135 | + /** |
|
136 | + * @param ApiKeys $api |
|
137 | + */ |
|
129 | 138 | private function saveHistory($api, $workflow, $statesFrom, $statesTo){ |
130 | 139 | $history = New History; |
131 | 140 | $history->content_id = $api->id; |