skip to Main Content

Javascript – how take father from button click

I need to get father after a click: i have this code html: <button mat-icon-button (click)="download($event)"> the code html generate is this: <button _ngcontent-wsc-c153="" mat-icon-button="" class="" aria-label=""> <mat-icon _ngcontent-wsc-c153="" role="img" alt="download" class="" aria-hidden="true" data-mat-icon-type="font" aria-describedby="cdk-describedby-message-2" cdk-describedby-host="0">download_for_offline</mat-icon><!----> </button> in my ts…

VIEW QUESTION

Javascript – Angular directive this and closure issue

I have such directive: @Directive({ selector: '[imgTest]', }) export class ImgTest implements AfterViewInit, OnDestroy { private originalImage: HTMLImageElement; private secondImage: HTMLDivElement; constructor(private elementRef: ElementRef, public sanitizer: DomSanitizer) {} @HostListener('load') public onLoad(): void { this.process(); } public ngAfterViewInit(): void { this.originalImage…

VIEW QUESTION

Javascript – I need to Arrange my Json data to iteratable one

[{"TenantId":96,"BatchNo":"B-638248651272667323PI345-1","Rate":10.00,"Qty":1.00,"Discount":0.00,"Gross":10.00,"Net":10.00,"TransactionType":1,"CombinationId":null,"PurchaseInvoiceDetailsId":11394,"PurchaseInvoiceDetails":null,"SalesInvoiceDetailId":null,"SalesInvoiceDetail":null,"SalesReturnDetailsId":null,"SalesReturnDetails":null,"PurchaseReturnDetailsId":null,"PurchaseReturnDetails":null,"ProductProfileId":6490,"ProductProfile":null,"ProductVarientLinksId":null,"ProductVarientLinks":null,"ProductionOrderDetailId":null,"ProductionOrderDetail":null,"QuickSaleInvoiceDetailId":null,"QuickSaleInvoiceDetail":null,"DirectSaleDetailId":null,"DirectSaleDetail":null,"QuickPreparedItemId":null,"QuickPreparedItem":null,"QuickSaleFoodWastgeId":null,"QuickSaleFoodWastge":null,"TransferDetailId":null,"TransferDetail":null,"StoreId":245,"Store":null,"BranchId":233,"Branch":null,"UnitId":238,"Unit":null,"BaseUnitId":239,"BaseUnit":null,"BaseQty":1000.00,"DamageStockDetailsId":null,"DamageStockDetails":null,"StockUpdateDetailId":null,"StockUpdateDetail":null,"QuickSaleOrderDetailId":null,"QuickRaweMaterialsUsedId":null,"QuickRaweMaterialsUsed":null,"Date":"2023-07-13T00:00:00","BarcodeNumber":null,"CompanyId":66,"Company":null,"RawmaterialsReturnId":null,"RawmaterialsReturn":null,"FinishedGoodDetailId":null,"FinishedGoodDetail":null,"DeliveryDetailsId":null,"DeliveryDetails":null,"GrnDetailsId":null,"GrnDetails":null,"QRCodeDetailsId":null,"QRCodeDetails":null,"UPICode":null,"MaxRate":0.00,"SalesRate":0.00,"ExpiryDate":null,"SerialNumber1":null,"SerialNumber2":null,"ChasisNo":null,"MotorNo":null,"RepackingId":null,"Repacking":null,"RepackingDetailsId":null,"RepackingDetails":null,"StockCorrectionDetailsId":null,"StockCorrectionDetails":null,"PurchaseRate":0.00,"FinancialYearMastersId":312,"FinancialYearMasters":null,"Reference":null,"IsDeleted":false,"DeleterUserId":null,"DeletionTime":null,"LastModificationTime":null,"LastModifierUserId":null,"CreationTime":"2023-07-13T17:27:14.3584215","CreatorUserId":253,"Id":47819}] This is my Json data and this varying the key values so i need to loop with the below format eg: [ {"TenantId":96},{"BatchNo":"B-638248651272667323PI345-1"} ]

VIEW QUESTION
Back To Top
Search