简体   繁体   中英

Kendo-grid with clickable link

I am very new to angular etc. This is probably super easy for some but I am having trouble.

I have a kendo-grid with a few columns and would like to have one column which will have a clickable link (ex. users) that will route the user to a new page which will take them to the (user section).

My question is what steps do I take for 1. Create clickable link 2. Route the user to a new page and the specific section on that page that deals with (ex. users)

Which kendo are you using?

For Kendo Angular use kendo-grid-column

<kendo-grid [data]="gridData">
        <kendo-grid-column title="Name" width="40">
          <ng-template kendoGridCellTemplate let-dataItem>
            <a class="text-primary" [routerLink]="...">{{dataItem.name}}</a>
          </ng-template>
        </kendo-grid-column>
</kendo-grid>

For Kendo UI use grid options columns template

    columns: [
       {
            field: "name",
            title: "Name",
            template: "<a href href='...'>#:name#</a>",
            width: "250px"
        } as kendo.ui.GridColumn
    ],

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM