Page Menu
Home
GnuPG
Search
Configure Global Search
Log In
Files
F32567750
AphrontAbstractAttachedFileView.php
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Size
1016 B
Subscribers
None
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"
}
}
File Metadata
Details
Attached
Mime Type
text/x-php
Expires
Fri, Nov 14, 8:16 PM (20 h, 36 m)
Storage Engine
local-disk
Storage Format
Raw Data
Storage Handle
f1/97/eae82656e1b2ccf52869880520b9
Attached To
rPHAB Phabricator
Event Timeline
Log In to Comment