I working on angular 7 app i need to write condition on data content to display text field as link
on this line content of data display
"let repdata of ReportData"> -
"let rep of contentBody"> "let r1 of rep">"" nbtooltipplacement="right" - class="ng-star-inserted">{{r1}}
on these line header display meaning columns namets for content body and headercol data source- "width: max-content">
"" style="width: max-content;" *ngFor="let coln of headerCols"> "coln != 'totalCount'" >- {{coln}}
data displayes is- this._displayreport.GetReportDetailsPaging(this.searchData).subscribe((data: any[]) => {
- this.reportdetailslist = data;
- this.headerCols = Object.keys(data[0]);
- data.forEach((item) =>{
- let values = Object.keys(item).map((key)=> item[key]).filter(item =>item != data[0].totalCount)
- this.contentBody.push(values);
- });
- });
- reportid url
- 1222 display as icon
- 1333 as it returned
- 1555 as it returned
I need to know how to write condition if reportid=1222then display column as icon can click on itondata above i have two column must be existreportid urlI need to write if reportid =2020 then convert text url to iconso how to do that please ?
Replies
Know the answer? Post it — somebody with the same question will find it here.