chore: limit submitting rows based on liscence
Build / Build-and-ng-test (pull_request) Failing after 17s

This commit is contained in:
Sabir Hassan
2024-01-24 14:28:56 +05:00
parent 233eca39ef
commit 8afee29e02
+4 -1
View File
@@ -324,7 +324,10 @@ export class XLMapComponent implements AfterContentInit, AfterViewInit, OnInit {
const csvContent =
Object.keys(this.xlData[0]).join(',') +
'\n' +
this.xlData.map((row: any) => Object.values(row).join(',')).join('\n')
this.xlData
.slice(0, this.licenceState.value.submit_rows_limit)
.map((row: any) => Object.values(row).join(','))
.join('\n')
const blob = new Blob([csvContent], { type: 'application/csv' })
const file: File = this.blobToFile(blob, this.filename + '.csv')