Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F93619475
AphrontAbstractAttachedFileView.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
Sat, Nov 30, 05:12
Size
1016 B
Mime Type
text/x-php
Expires
Mon, Dec 2, 05:12 (2 d)
Engine
blob
Format
Raw Data
Handle
22677499
Attached To
rPH Phabricator
AphrontAbstractAttachedFileView.php
View Options
<?php
abstract
class
AphrontAbstractAttachedFileView
extends
AphrontView
{
private
$file
;
final
public
function
setFile
(
PhabricatorFile
$file
)
{
$this
->
file
=
$file
;
return
$this
;
}
final
protected
function
getFile
()
{
return
$this
->
file
;
}
final
protected
function
getName
()
{
$file
=
$this
->
getFile
();
return
phutil_tag
(
'a'
,
array
(
'href'
=>
$file
->
getViewURI
(),
'target'
=>
'_blank'
,
),
$file
->
getName
());
}
final
protected
function
getRemoveElement
()
{
$file
=
$this
->
getFile
();
return
javelin_tag
(
'a'
,
array
(
'class'
=>
'button grey'
,
'sigil'
=>
'aphront-attached-file-view-remove'
,
// NOTE: Using 'ref' here instead of 'meta' because the file upload
// endpoint doesn't receive request metadata and thus can't generate
// a valid response with node metadata.
'ref'
=>
$file
->
getPHID
(),
),
"
\x
E2
\x
9C
\x
96"
);
// "Heavy Multiplication X"
}
}
Event Timeline
Log In to Comment