/** * Render the file upload form in its initial state. * @param $args array * @param $request Request * @return string a serialized JSON object */ function displayFileUploadForm($args, &$request) { // Instantiate, configure and initialize the form. import('controllers.wizard.fileUpload.form.SubmissionFilesUploadForm'); $monograph =& $this->getMonograph(); $fileForm = new SubmissionFilesUploadForm($request, $monograph->getId(), $this->getStageId(), $this->getUploaderRoles(), $this->getFileStage(), $this->getRevisionOnly(), $this->getReviewType(), $this->getRound(), $this->getRevisedFileId()); $fileForm->initData($args, $request); // Render the form. $json = new JSON(true, $fileForm->fetch($request)); return $json->getString(); }
/** * Render the file upload form in its initial state. * @param $args array * @param $request Request * @return JSONMessage JSON object */ function displayFileUploadForm($args, $request) { // Instantiate, configure and initialize the form. import('lib.pkp.controllers.wizard.fileUpload.form.SubmissionFilesUploadForm'); $submission = $this->getSubmission(); $fileForm = new SubmissionFilesUploadForm($request, $submission->getId(), $this->getStageId(), $this->getUploaderRoles(), $this->getUploaderGroupIds(), $this->getFileStage(), $this->getRevisionOnly(), $this->getReviewRound(), $this->getRevisedFileId(), $this->getAssocType(), $this->getAssocId()); $fileForm->initData($args, $request); // Render the form. return new JSONMessage(true, $fileForm->fetch($request)); }
/** * Render the file upload form in its initial state. * @param $args array * @param $request Request * @return string a serialized JSON object */ function displayFileUploadForm($args, &$request) { // Instantiate, configure and initialize the form. import('controllers.grid.files.submissionFiles.form.SubmissionFilesUploadForm'); $monograph =& $this->getMonograph(); $revisedFileId = $this->_getRevisedFileIdFromRequest($request); $fileForm = new SubmissionFilesUploadForm($request, $monograph->getId(), $this->getFileStage(), $this->revisionOnly(), $revisedFileId); $fileForm->initData($args, $request); // Render the form. $json = new JSON('true', $fileForm->fetch($request)); return $json->getString(); }