PHP 클래스 SubmissionDAO, pkp-lib

상속: extends DAO
파일 보기 프로젝트 열기: pkp/pkp-lib 1 사용 예제들

공개 프로퍼티들

프로퍼티 타입 설명
$authorDao
$cache

공개 메소드들

메소드 설명
__construct ( ) Constructor.
_cacheMiss ( $cache, $id ) : Monograph Callback for a cache miss.
_fromRow ( $row ) : Submission Internal function to return a Submission object from a row.
_getCache ( ) : Cache Get the submission cache.
changePubId ( $submissionId, $pubIdType, $pubId )
deleteAllPubIds ( $contextId, $pubIdType )
deleteByContextId ( $contextId ) Delete all submissions by context ID.
deleteById ( $submissionId ) Delete a submission by ID.
deleteObject ( $submission ) Delete a submission.
deletePermissions ( $contextId ) Delete the attached licenses of all submissions in a context.
deletePubId ( $submissionId, $pubIdType )
flushCache ( ) Flush the submission cache.
getActiveSubmissions ( $contextId = null, $title = null, $author = null, $editor = null, $stageId = null, $rangeInfo = null, $orphaned = false ) : DAOResultFactory Get all active submissions for a context.
getAdditionalFieldNames ( ) : array Get a list of additional fields that do not have dedicated accessors.
getAssignedById ( integer $submissionId, integer $userId, integer $contextId = null, boolean $useCache = false ) : Submission Retrieve a submission by ID only if the submission is not published, has been submitted, and does not belong to the user in question and is not STATUS_DECLINED.
getAssignedToOthers ( $userId, $contextId = null, $title = null, $author = null, $editor = null, $stageId = null, $rangeInfo = null ) : DAOResultFactory Get all submissions that are assigned to users other than the passed one.
getAssignedToUser ( $userId, $contextId = null, $title = null, $author = null, $stageId = null, $rangeInfo = null ) : DAOResultFactory Get all submissions that are considered assigned to the passed user, excluding author participation.
getByContextId ( $contextId ) : DAOResultFactory Get all submissions for a context.
getById ( $submissionId, $contextId = null, $useCache = false ) : Submission Retrieve a submission by ID.
getByStatus ( $status, $userId = null, $contextId = null, $title = null, $author = null, $stageId = null, $rangeInfo = null ) : DAOResultFactory Get all submissions for a status.
getBySubEditorId ( $contextId, $subEditorId = null, $includeDeclined = true, $includePublished = true, $title = null, $author = null, $stageId = null, $rangeInfo = null ) : DAOResultFactory Get all unassigned submissions for a context or all contexts
getByUserId ( $userId, $contextId = null ) : array Get all submissions for a user.
getInsertId ( ) : integer Get the ID of the last inserted submission.
getLocaleFieldNames ( ) : array Get a list of fields for which localized data is supported
getReviewerArchived ( $reviewerId, $contextId = null, $title = null, $author = null, $stageId = null, $rangeInfo = null ) : DAOResultFactory Get all submissions that a reviewer denied a review request.
getUnpublishedByUserId ( $userId, $contextId = null, $title = null, $stageId = null, $rangeInfo = null ) : array Get all unpublished submissions for a user.
newDataObject ( ) : Submission Instantiate a new data object.
pubIdExists ( $pubIdType, $pubId, $submissionId, $contextId )
updateLocaleFields ( $submission ) Update the settings for this object

보호된 메소드들

메소드 설명
_arrayWalkIntCast ( string $value ) : integer Sanity test to cast values to int for database queries.
getCompletionConditions ( $completed ) : string Get conditions required to establish whether the submission is "completed".
getCompletionJoins ( ) : string Get additional joins required to establish whether the submission is "completed".
getFetchColumns ( ) : string Return a SQL snippet of extra columns to fetch during submission fetch queries.
getFetchJoins ( ) : string Return a SQL snippet of extra joins to include during fetch queries.
getFetchParameters ( ) : array Return a list of extra parameters to bind to the submission fetch queries.
getGroupByColumns ( ) : string Return a SQL snippet of columns to group by the submission fetch queries.
getSubEditorJoin ( ) : string Return a SQL snippet of extra sub editor related join to include during fetch queries.

비공개 메소드들

메소드 설명
_getEditorSearchQuery ( ) : string Get the editor search query for submissions.

메소드 상세

__construct() 공개 메소드

Constructor.
public __construct ( )

_arrayWalkIntCast() 보호된 메소드

Sanity test to cast values to int for database queries.
protected _arrayWalkIntCast ( string $value ) : integer
$value string
리턴 integer

_cacheMiss() 공개 메소드

Callback for a cache miss.
public _cacheMiss ( $cache, $id ) : Monograph
$cache Cache
$id string
리턴 Monograph

_fromRow() 공개 메소드

Internal function to return a Submission object from a row.
public _fromRow ( $row ) : Submission
$row array
리턴 Submission

_getCache() 공개 메소드

Get the submission cache.
public _getCache ( ) : Cache
리턴 Cache

changePubId() 공개 메소드

public changePubId ( $submissionId, $pubIdType, $pubId )

deleteAllPubIds() 공개 메소드

public deleteAllPubIds ( $contextId, $pubIdType )

deleteByContextId() 공개 메소드

Delete all submissions by context ID.
public deleteByContextId ( $contextId )
$contextId int

deleteById() 공개 메소드

Delete a submission by ID.
public deleteById ( $submissionId )
$submissionId int

deleteObject() 공개 메소드

Delete a submission.
public deleteObject ( $submission )
$submission Submission

deletePermissions() 공개 메소드

Delete the attached licenses of all submissions in a context.
public deletePermissions ( $contextId )

deletePubId() 공개 메소드

public deletePubId ( $submissionId, $pubIdType )

flushCache() 공개 메소드

Flush the submission cache.
public flushCache ( )

getActiveSubmissions() 공개 메소드

Get all active submissions for a context.
public getActiveSubmissions ( $contextId = null, $title = null, $author = null, $editor = null, $stageId = null, $rangeInfo = null, $orphaned = false ) : DAOResultFactory
$contextId int optional
$title string|null optional Filter by title.
$author string|null optional Filter by author.
$editor int|null optional Filter by editor name.
$stageId int|null optional Filter by stage id.
$rangeInfo DBResultRange optional
$orphaned boolean Whether the incomplete submissions that have no author assigned should be considered too
리턴 DAOResultFactory

getAdditionalFieldNames() 공개 메소드

Get a list of additional fields that do not have dedicated accessors.
public getAdditionalFieldNames ( ) : array
리턴 array

getAssignedById() 공개 메소드

Retrieve a submission by ID only if the submission is not published, has been submitted, and does not belong to the user in question and is not STATUS_DECLINED.
public getAssignedById ( integer $submissionId, integer $userId, integer $contextId = null, boolean $useCache = false ) : Submission
$submissionId integer
$userId integer
$contextId integer
$useCache boolean
리턴 Submission

getAssignedToOthers() 공개 메소드

Get all submissions that are assigned to users other than the passed one.
public getAssignedToOthers ( $userId, $contextId = null, $title = null, $author = null, $editor = null, $stageId = null, $rangeInfo = null ) : DAOResultFactory
$userId int
$contextId int optional
$title string|null optional Filter by title.
$author string|null optional Filter by author.
$editor int|null optional Filter by editor name.
$stageId int|null optional Filter by stage id.
$rangeInfo DBResultRange optional
리턴 DAOResultFactory

getAssignedToUser() 공개 메소드

Get all submissions that are considered assigned to the passed user, excluding author participation.
public getAssignedToUser ( $userId, $contextId = null, $title = null, $author = null, $stageId = null, $rangeInfo = null ) : DAOResultFactory
$userId int
$contextId int optional
$title string|null optional Filter by title.
$author string|null optional Filter by author.
$stageId int|null optional Filter by stage id.
$rangeInfo DBResultRange optional
리턴 DAOResultFactory

getByContextId() 공개 메소드

Get all submissions for a context.
public getByContextId ( $contextId ) : DAOResultFactory
$contextId int
리턴 DAOResultFactory containing matching Submissions

getById() 공개 메소드

Retrieve a submission by ID.
public getById ( $submissionId, $contextId = null, $useCache = false ) : Submission
$submissionId int
$contextId int optional
$useCache boolean optional
리턴 Submission

getByStatus() 공개 메소드

Get all submissions for a status.
public getByStatus ( $status, $userId = null, $contextId = null, $title = null, $author = null, $stageId = null, $rangeInfo = null ) : DAOResultFactory
$status int Status to get submissions for
$userId int optional User to require an assignment for
$contextId mixed optional Context(s) to fetch submissions for
$title string optional
$author string optional
$stageId int optional
$rangeInfo DBResultRange optional
리턴 DAOResultFactory

getBySubEditorId() 공개 메소드

Get all unassigned submissions for a context or all contexts
public getBySubEditorId ( $contextId, $subEditorId = null, $includeDeclined = true, $includePublished = true, $title = null, $author = null, $stageId = null, $rangeInfo = null ) : DAOResultFactory
$contextId int optional the ID of the context to query.
$subEditorId int optional the ID of the sub editor whose section will be included in the results (excluding others).
$includeDeclined boolean optional include submissions which have STATUS_DECLINED
$includePublished boolean optional include submissions which are published
$title string|null optional Filter by title.
$author string|null optional Filter by author.
$stageId int|null optional Filter by stage id.
$rangeInfo DBRangeInfo
리턴 DAOResultFactory containing matching Submissions

getByUserId() 공개 메소드

Get all submissions for a user.
public getByUserId ( $userId, $contextId = null ) : array
$userId int
$contextId int optional
리턴 array Submissions

getCompletionConditions() 추상적인 보호된 메소드

Get conditions required to establish whether the submission is "completed".
abstract protected getCompletionConditions ( $completed ) : string
$completed boolean True for completed submissions; false for incomplete
리턴 string

getCompletionJoins() 보호된 메소드

Get additional joins required to establish whether the submission is "completed".
protected getCompletionJoins ( ) : string
리턴 string

getFetchColumns() 추상적인 보호된 메소드

Return a SQL snippet of extra columns to fetch during submission fetch queries.
abstract protected getFetchColumns ( ) : string
리턴 string

getFetchJoins() 추상적인 보호된 메소드

Return a SQL snippet of extra joins to include during fetch queries.
abstract protected getFetchJoins ( ) : string
리턴 string

getFetchParameters() 추상적인 보호된 메소드

Return a list of extra parameters to bind to the submission fetch queries.
abstract protected getFetchParameters ( ) : array
리턴 array

getGroupByColumns() 추상적인 보호된 메소드

See bug #8557, all tables that have columns selected must have one column listed here to keep PostgreSQL happy.
abstract protected getGroupByColumns ( ) : string
리턴 string

getInsertId() 공개 메소드

Get the ID of the last inserted submission.
public getInsertId ( ) : integer
리턴 integer

getLocaleFieldNames() 공개 메소드

Get a list of fields for which localized data is supported
public getLocaleFieldNames ( ) : array
리턴 array

getReviewerArchived() 공개 메소드

It will list only the submissions that a review has denied ALL review assignments.
public getReviewerArchived ( $reviewerId, $contextId = null, $title = null, $author = null, $stageId = null, $rangeInfo = null ) : DAOResultFactory
$reviewerId int
$contextId int optional
$title string optional
$author string optional
$stageId int optional
$rangeInfo DBResultRange optional
리턴 DAOResultFactory

getSubEditorJoin() 추상적인 보호된 메소드

Return a SQL snippet of extra sub editor related join to include during fetch queries.
abstract protected getSubEditorJoin ( ) : string
리턴 string

getUnpublishedByUserId() 공개 메소드

Get all unpublished submissions for a user.
public getUnpublishedByUserId ( $userId, $contextId = null, $title = null, $stageId = null, $rangeInfo = null ) : array
$userId int
$contextId int optional
$rangeInfo DBResultRange optional
리턴 array Submissions

newDataObject() 공개 메소드

Instantiate a new data object.
public newDataObject ( ) : Submission
리턴 Submission

pubIdExists() 공개 메소드

public pubIdExists ( $pubIdType, $pubId, $submissionId, $contextId )

updateLocaleFields() 공개 메소드

Update the settings for this object
public updateLocaleFields ( $submission )
$submission object

프로퍼티 상세

$authorDao 공개적으로 프로퍼티

public $authorDao

$cache 공개적으로 프로퍼티

public $cache