* create new blank report * * @param $name * @param int $type * @param int $parent * @param $pages * @return int * @throws Exception */
(int $type, int $parent)
| 134 | * @throws Exception |
| 135 | */ |
| 136 | public function create(int $type, int $parent): int { |
| 137 | if (!$this->isValidParent($parent)) { |
| 138 | return 0; |
| 139 | } |
| 140 | $reportId = $this->PanoramaMapper->create($this->l10n->t('New'), $type, $parent, '[]'); |
| 141 | $this->ActivityManager->triggerEvent($reportId, ActivityManager::OBJECT_PANORAMA, ActivityManager::SUBJECT_PANORAMA_ADD); |
| 142 | return $reportId; |
| 143 | } |
| 144 | |
| 145 | /** |
| 146 | * update report details |
no test coverage detected