* create new blank report * * @param $name * @param int $type * @param int $parent * @param $pages * @return int * @throws Exception */
(int $type, int $parent)
| 161 | * @throws Exception |
| 162 | */ |
| 163 | public function create(int $type, int $parent): int { |
| 164 | if (!$this->isValidParent($parent)) { |
| 165 | return 0; |
| 166 | } |
| 167 | $reportId = $this->PanoramaMapper->create($this->l10n->t('New'), $type, $parent, '[]'); |
| 168 | $this->ActivityManager->triggerEvent($reportId, ActivityManager::OBJECT_PANORAMA, ActivityManager::SUBJECT_PANORAMA_ADD); |
| 169 | return $reportId; |
| 170 | } |
| 171 | |
| 172 | /** |
| 173 | * update report details |
no test coverage detected