Giter VIP home page Giter VIP logo

Comments (2)

andrew-yangy avatar andrew-yangy commented on May 28, 2024

Hi JianHe007,
I'm glad my work helps you! Here are the answers to your questions:

  1. Unfortunately the current branch does not support column sorting, it might be added soon.
  2. You can set selection properties in your template like this:
     <ay-treeTable [value]="nodes.data" [globalFilter]="gb"
                  selectionMode="single" [(selection)]="selectedRows"
                  (onNodeSelect)="nodeSelect($event)">
      <ay-column field="name" header="Name">
        <ng-template let-col let-node="rowData" pTemplate="body">
          <span>{{node.data[col.field]}}</span>
        </ng-template>
      </ay-column>
      <ay-column field="size" header="Size"></ay-column>
      <ay-column field="type" header="Type"></ay-column>
    </ay-treeTable>
  1. You can use whatever event you want in the tag.
<ay-column field="name" header="Name">
        <ng-template let-col let-node="rowData" pTemplate="body">
          <span (mouseUp)="fn($event)">{{node.data[col.field]}}</span>
        </ng-template>
      </ay-column>

from ng-treetable.

JianHe007 avatar JianHe007 commented on May 28, 2024

Hi ddvkid,
thanks for your kindness. It does work in No.2.
In No.3, I tried the "span (mouseUp)" ,it was not work. the "span (mouseover)" is OK.
Thank you again!

from ng-treetable.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.