[Bps-public-commit] rt-extension-assets branch, 1.1/csv, updated. 1.0rc2-5-ga08f89c

Alex Vandiver alexmv at bestpractical.com
Wed Apr 2 16:20:35 EDT 2014


The branch, 1.1/csv has been updated
       via  a08f89cba9582ee6e671c6f94f6d899c173cb3d3 (commit)
       via  9732223ad00563daa8176d569f7d2011d3b4a345 (commit)
       via  17194c6ec3eb77fef845874838c52c3097bfcfbf (commit)
      from  02e9cfaa6dea73a48326f556d6a10294475b5bf8 (commit)

Summary of changes:
 html/Asset/Elements/TSVExport | 1 +
 html/Asset/Search/Results.tsv | 4 +++-
 2 files changed, 4 insertions(+), 1 deletion(-)

- Log -----------------------------------------------------------------
commit 17194c6ec3eb77fef845874838c52c3097bfcfbf
Author: Alex Vandiver <alexmv at bestpractical.com>
Date:   Wed Apr 2 16:19:18 2014 -0400

    Pass the correct class to ColumnMap
    
    As Assets are mostly made of CFs, this _mostly_ worked, but failed to
    pick up the right properties for roles.

diff --git a/html/Asset/Elements/TSVExport b/html/Asset/Elements/TSVExport
index eff696f..0d34357 100644
--- a/html/Asset/Elements/TSVExport
+++ b/html/Asset/Elements/TSVExport
@@ -75,6 +75,7 @@ my $col_entry = sub {
         header => Encode::encode_utf8(loc($col->{title} || $col->{attribute})),
         map    => $m->comp(
             "/Elements/ColumnMap",
+            Class => "RT__Asset",
             Name  => $col->{attribute},
             Attr  => 'value'
         ),

commit 9732223ad00563daa8176d569f7d2011d3b4a345
Author: Alex Vandiver <alexmv at bestpractical.com>
Date:   Wed Apr 2 16:19:40 2014 -0400

    Include the id in the format

diff --git a/html/Asset/Search/Results.tsv b/html/Asset/Search/Results.tsv
index 7f54607..08afa05 100644
--- a/html/Asset/Search/Results.tsv
+++ b/html/Asset/Search/Results.tsv
@@ -54,7 +54,7 @@ ProcessAssetsSearchArguments(
     Assets => $assets, Catalog => $catalog_obj, ARGSRef => \%ARGS,
 );
 
-my $Format = q|Name, Description, Status, Catalog, |;
+my $Format = q|id, Name, Description, Status, Catalog, |;
 
 $Format .= "$_, " for RT::Asset->Roles;
 

commit a08f89cba9582ee6e671c6f94f6d899c173cb3d3
Author: Alex Vandiver <alexmv at bestpractical.com>
Date:   Wed Apr 2 16:20:27 2014 -0400

    Add a format to modify TSV downloads

diff --git a/html/Asset/Search/Results.tsv b/html/Asset/Search/Results.tsv
index 08afa05..4451f69 100644
--- a/html/Asset/Search/Results.tsv
+++ b/html/Asset/Search/Results.tsv
@@ -62,6 +62,8 @@ my $CFs = RT::CustomFields->new( $session{CurrentUser} );
 $CFs->LimitToCatalog( $catalog_obj->Id );
 $Format .= "'__CF.{$_}__/TITLE:$_', " for map {$_ = $_->Name; s/['\\]/\\$1/g; $_} @{$CFs->ItemsArrayRef};
 
+$m->callback(CallbackName => "ModifyFormat", Format => \$Format );
+
 my $comp = "/Asset/Elements/TSVExport";
 $comp = "/Elements/TSVExport" if $m->comp_exists("/Elements/TSVExport");
 

-----------------------------------------------------------------------



More information about the Bps-public-commit mailing list