From a2275d2796331ff824f0f3ce05b9c2f92ad728c8 Mon Sep 17 00:00:00 2001 From: Danijel Anđelković Date: Tue, 12 Apr 2022 21:12:10 +0200 Subject: Ispravio datatable komponentu koja se nije ucitavala za postojeci dataset. Dodao broj redova u klasu dataset posto vise nije isti kao broj elemenata podataka koje prikazujemo. --- backend/api/api/Controllers/FileController.cs | 4 ++-- backend/api/api/Models/Dataset.cs | 1 + 2 files changed, 3 insertions(+), 2 deletions(-) (limited to 'backend/api') diff --git a/backend/api/api/Controllers/FileController.cs b/backend/api/api/Controllers/FileController.cs index 0be480f2..a5d0ae7e 100644 --- a/backend/api/api/Controllers/FileController.cs +++ b/backend/api/api/Controllers/FileController.cs @@ -121,9 +121,9 @@ namespace api.Controllers if (hasHeader) - return String.Join("", System.IO.File.ReadLines(filePath).Take(11)); + return String.Join("\n", System.IO.File.ReadLines(filePath).Take(11)); else - return String.Join("", System.IO.File.ReadLines(filePath).Take(10)); + return String.Join("\n", System.IO.File.ReadLines(filePath).Take(10)); } diff --git a/backend/api/api/Models/Dataset.cs b/backend/api/api/Models/Dataset.cs index 12dcfa08..47814449 100644 --- a/backend/api/api/Models/Dataset.cs +++ b/backend/api/api/Models/Dataset.cs @@ -25,6 +25,7 @@ namespace api.Models public bool hasHeader { get; set; } public ColumnInfo[] columnInfo { get; set; } + public int rowCount { get; set; } public int nullCols { get; set; } public int nullRows { get; set; } public bool isPreProcess { get; set; } -- cgit v1.2.3