Page Menu
Home
Phorge
Search
Configure Global Search
Log In
Files
F958019
PhrequentPushConduitAPIMethod.php
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Flag For Later
Award Token
Size
1 KB
Referenced Files
None
Subscribers
None
PhrequentPushConduitAPIMethod.php
View Options
<?php
final
class
PhrequentPushConduitAPIMethod
extends
PhrequentConduitAPIMethod
{
public
function
getAPIMethodName
()
{
return
'phrequent.push'
;
}
public
function
getMethodDescription
()
{
return
pht
(
'Start tracking time on an object by '
.
'pushing it on the tracking stack.'
);
}
public
function
getMethodStatus
()
{
return
self
::
METHOD_STATUS_UNSTABLE
;
}
public
function
defineParamTypes
()
{
return
array
(
'objectPHID'
=>
'required phid'
,
'startTime'
=>
'int'
,
);
}
public
function
defineReturnType
()
{
return
'phid'
;
}
public
function
defineErrorTypes
()
{
return
array
(
);
}
protected
function
execute
(
ConduitAPIRequest
$request
)
{
$user
=
$request
->
getUser
();
$object_phid
=
$request
->
getValue
(
'objectPHID'
);
$timestamp
=
$request
->
getValue
(
'startTime'
);
if
(
$timestamp
===
null
)
{
$timestamp
=
time
();
}
$editor
=
new
PhrequentTrackingEditor
();
return
$editor
->
startTracking
(
$user
,
$object_phid
,
$timestamp
);
}
}
File Metadata
Details
Attached
Mime Type
text/x-php
Expires
Tue, Jun 17, 8:06 PM (2 d)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
227489
Default Alt Text
PhrequentPushConduitAPIMethod.php (1 KB)
Attached To
Mode
rP Phorge
Attached
Detach File
Event Timeline
Log In to Comment