Open Monograph Press  1.1
 All Classes Namespaces Functions Variables Groups Pages
MySubmissionsListGridHandler.inc.php
1 <?php
2 
16 // Import grid base classes.
17 import('lib.pkp.controllers.grid.submissions.SubmissionsListGridHandler');
18 import('lib.pkp.controllers.grid.submissions.SubmissionsListGridRow');
19 
20 // Import 'my submissions' list specific grid classes.
21 import('lib.pkp.controllers.grid.submissions.mySubmissions.MySubmissionsListGridCellProvider');
22 
28  parent::SubmissionsListGridHandler();
29  $this->addRoleAssignment(
30  array(ROLE_ID_MANAGER, ROLE_ID_SUB_EDITOR, ROLE_ID_ASSISTANT, ROLE_ID_AUTHOR),
31  array('fetchGrid', 'fetchRow', 'deleteSubmission')
32  );
33  }
34 
35  //
36  // Implement template methods from PKPHandler
37  //
41  function initialize($request) {
42  parent::initialize($request);
43 
44  $titleColumn = $this->getColumn('title');
45  $titleColumn->setCellProvider(new MySubmissionsListGridCellProvider());
46  }
47 
48 
49  //
50  // Implement template methods from SubmissionListGridHandler
51  //
55  function getSubmissions($request, $userId) {
56  $this->setTitle('submission.mySubmissions');
57 
58  $submissionDao = Application::getSubmissionDAO();
59  $rangeInfo = $this->getGridRangeInfo($request, $this->getId());
60  $data = $submissionDao->getUnpublishedByUserId($userId, null, $rangeInfo);
61  return $data;
62  }
63 }
64 
65 ?>
Handle submission list grid requests.
addRoleAssignment($roleIds, $operations)
Handle author&#39;s submissions list grid requests (submissions the user has made).
static getSubmissionDAO()
getColumn($columnId)
getGridRangeInfo($request, $rangeName, $contextData=null)