Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F72366556
PhabricatorEdgeEditType.php
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Subscribers
None
File Metadata
Details
File Info
Storage
Attached
Created
Mon, Jul 15, 09:42
Size
1 KB
Mime Type
text/x-php
Expires
Wed, Jul 17, 09:42 (2 d)
Engine
blob
Format
Raw Data
Handle
19047126
Attached To
rPH Phabricator
PhabricatorEdgeEditType.php
View Options
<?php
final
class
PhabricatorEdgeEditType
extends
PhabricatorEditType
{
private
$edgeOperation
;
private
$valueDescription
;
public
function
setEdgeOperation
(
$edge_operation
)
{
$this
->
edgeOperation
=
$edge_operation
;
return
$this
;
}
public
function
getEdgeOperation
()
{
return
$this
->
edgeOperation
;
}
public
function
getValueType
()
{
return
'list<phid>'
;
}
public
function
generateTransaction
(
PhabricatorApplicationTransaction
$template
,
array
$spec
)
{
$value
=
idx
(
$spec
,
'value'
);
$value
=
array_fuse
(
$value
);
$value
=
array
(
$this
->
getEdgeOperation
()
=>
$value
,
);
$template
->
setTransactionType
(
$this
->
getTransactionType
())
->
setNewValue
(
$value
);
foreach
(
$this
->
getMetadata
()
as
$key
=>
$value
)
{
$template
->
setMetadataValue
(
$key
,
$value
);
}
return
$template
;
}
public
function
setValueDescription
(
$value_description
)
{
$this
->
valueDescription
=
$value_description
;
return
$this
;
}
public
function
getValueDescription
()
{
return
$this
->
valueDescription
;
}
}
Event Timeline
Log In to Comment