<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Customize nuxeo-assets-search-result.html in Nuxeo Forum</title>
    <link>https://connect.hyland.com/t5/nuxeo-forum/customize-nuxeo-assets-search-result-html/m-p/319665#M6666</link>
    <description>&lt;P&gt;I want to display an other metadata not the parentRef&lt;/P&gt;</description>
    <pubDate>Thu, 11 Jun 2020 16:33:32 GMT</pubDate>
    <dc:creator>Mariem_Ben_Maal</dc:creator>
    <dc:date>2020-06-11T16:33:32Z</dc:date>
    <item>
      <title>Customize nuxeo-assets-search-result.html</title>
      <link>https://connect.hyland.com/t5/nuxeo-forum/customize-nuxeo-assets-search-result-html/m-p/319660#M6661</link>
      <description>&lt;P&gt;I want to customize the nuxeo-data-table that shows nuxeo-results in nuxeo-assets-search-results.html by adding a new column which displays a property of a parent document.
I'm asking a solution  to access to a parent document data in such widget.
I' ve tried to get the parent data using a function that call the operation "Document.getParent" and return the property I need.
In fact, I've added a new column that calls this function :&lt;/P&gt;
  &lt;NUXEO-DATA-TABLE-COLUMN&gt;
             &lt;TEMPLATE&gt;
            [[_getProperty(item)]]
            &lt;/TEMPLATE&gt;
      &lt;/NUXEO-DATA-TABLE-COLUMN&gt;
function I used : 
&lt;P&gt;_getProperty: function(item) {
this.currentItemId = item.uid;
if (this.currentItemId != null &amp;amp;&amp;amp; this.currentItemId != undefined) {
this.$.fetchDocumentOperation
.execute()
.then(function(response) {
this.input = response;
if (this.input != null &amp;amp;&amp;amp; this.input != undefined) {
this.$.getParentOperation.execute().then(function(response2) {
console.log(response2.properties["xpath"]);
return response2.properties["xpath"];
}.bind(this))
.catch(function(error) {
console.log("error:" + error);
}.bind(this));
}
}.bind(this))
.catch(function(error) {
console.log("error:" + error);
}.bind(this));&lt;/P&gt;
&lt;P&gt;By this solution I was able to display the property I need in console but it's not displayed in interface.&lt;/P&gt;</description>
      <pubDate>Fri, 05 Jun 2020 08:52:54 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/nuxeo-forum/customize-nuxeo-assets-search-result-html/m-p/319660#M6661</guid>
      <dc:creator>Mariem_Ben_Maal</dc:creator>
      <dc:date>2020-06-05T08:52:54Z</dc:date>
    </item>
    <item>
      <title>Re: Customize nuxeo-assets-search-result.html</title>
      <link>https://connect.hyland.com/t5/nuxeo-forum/customize-nuxeo-assets-search-result-html/m-p/319661#M6662</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;
&lt;P&gt;The simplest way to edit the default dam search is to import the Studio External Template called "Default Nuxeo DAM Configuration" in your project and edit the configuration (see screenshot)&lt;/P&gt;
&lt;P&gt;Regards&lt;/P&gt;</description>
      <pubDate>Mon, 08 Jun 2020 13:01:47 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/nuxeo-forum/customize-nuxeo-assets-search-result-html/m-p/319661#M6662</guid>
      <dc:creator>Gregory_Carlin</dc:creator>
      <dc:date>2020-06-08T13:01:47Z</dc:date>
    </item>
    <item>
      <title>Re: Customize nuxeo-assets-search-result.html</title>
      <link>https://connect.hyland.com/t5/nuxeo-forum/customize-nuxeo-assets-search-result-html/m-p/319662#M6663</link>
      <description>&lt;P&gt;Thanks for your reply, But I need to know how can I get access to a parent document data in such widget&lt;/P&gt;</description>
      <pubDate>Tue, 09 Jun 2020 10:07:48 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/nuxeo-forum/customize-nuxeo-assets-search-result-html/m-p/319662#M6663</guid>
      <dc:creator>Mariem_Ben_Maal</dc:creator>
      <dc:date>2020-06-09T10:07:48Z</dc:date>
    </item>
    <item>
      <title>Re: Customize nuxeo-assets-search-result.html</title>
      <link>https://connect.hyland.com/t5/nuxeo-forum/customize-nuxeo-assets-search-result-html/m-p/319663#M6664</link>
      <description>&lt;P&gt;I'm not sure that's the proper approach, I'd take a different one. If you need to use the parent object's metadata, you should also have it on your child objects. That metadata would be defined in a schema, which can be easily copied with an automation chain (Document.CopySchema). By doing so you will also be able to search for your documents using parent's metadata. That's covered in a University video, I believe it was "Content modeling options".&lt;/P&gt;</description>
      <pubDate>Tue, 09 Jun 2020 11:09:25 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/nuxeo-forum/customize-nuxeo-assets-search-result-html/m-p/319663#M6664</guid>
      <dc:creator>michal_m</dc:creator>
      <dc:date>2020-06-09T11:09:25Z</dc:date>
    </item>
    <item>
      <title>Re: Customize nuxeo-assets-search-result.html</title>
      <link>https://connect.hyland.com/t5/nuxeo-forum/customize-nuxeo-assets-search-result-html/m-p/319664#M6665</link>
      <description>&lt;P&gt;You should use something like&lt;/P&gt;
&lt;PRE&gt;&lt;CODE&gt;&amp;lt;nuxeo-data-table-column name="Parent" field="item.parentRef"&amp;gt;
&amp;lt;template&amp;gt;
&amp;lt;nuxeo-document-suggestion value="[[item.parentRef]]" readonly="true"&amp;gt;&amp;lt;/nuxeo-document-suggestion&amp;gt;
&amp;lt;/template&amp;gt;
&amp;lt;/nuxeo-data-table-column&amp;gt;
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Tue, 09 Jun 2020 12:04:43 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/nuxeo-forum/customize-nuxeo-assets-search-result-html/m-p/319664#M6665</guid>
      <dc:creator>Gregory_Carlin</dc:creator>
      <dc:date>2020-06-09T12:04:43Z</dc:date>
    </item>
    <item>
      <title>Re: Customize nuxeo-assets-search-result.html</title>
      <link>https://connect.hyland.com/t5/nuxeo-forum/customize-nuxeo-assets-search-result-html/m-p/319665#M6666</link>
      <description>&lt;P&gt;I want to display an other metadata not the parentRef&lt;/P&gt;</description>
      <pubDate>Thu, 11 Jun 2020 16:33:32 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/nuxeo-forum/customize-nuxeo-assets-search-result-html/m-p/319665#M6666</guid>
      <dc:creator>Mariem_Ben_Maal</dc:creator>
      <dc:date>2020-06-11T16:33:32Z</dc:date>
    </item>
  </channel>
</rss>

