Skip to content
Permalink
Fetching contributors…
Cannot retrieve contributors at this time
33 lines (31 sloc) 1.15 KB
id: ListingPageFullPath
name: ListingPageFullPath
version: 1.0
list_properties:
page:
fullpath:
label: 'フルパス'
html: >
sub {
my $prop = shift;
my ( $obj, $app, $opts ) = @_;
my $folder = $obj->folder;
if ($folder) {
my @folders = ();
while (1) {
if ($folder->parent == 0) {
push (@folders, $folder);
last;
}
push (@folders, $folder);
$folder = MT::Folder->load($folder->parent);
}
@folders = reverse @folders;
my @folder_labels = ();
for my $folder (@folders) {
push (@folder_labels, $folder->label);
}
return MT::Util::encode_html(join('/', @folder_labels));
}
return '(root)';
}
You can’t perform that action at this time.