CodeBeamOrg / CodeBeam.MudBlazor.Extensions

Useful third party extension components for MudBlazor, from the contributors.
https://mudextensions.codebeam.org/
MIT License
441 stars 69 forks source link

New Feature: CSV File Header Matcher / CSV Mapping in Blazor #69

Closed enkodellc closed 1 year ago

enkodellc commented 2 years ago

Here is a example of the component.
https://try.mudblazor.com/snippet/QYGcvPGRKNnbVkiE

Similar to this: https://codesandbox.io/s/github/beamworks/react-csv-importer/tree/master/demo-sandbox

Idea: Select a CSV file, matches expected table headers to the CSV headers so you can import the csv file to your table.

I have it working in my app. I use FuzzyMatch to do a fuzzy match automatically but could be replaced with someone's own SearchFunc like MudBlazor does on MudAutocomplete. If you like the idea I will submit a PR.

mckaragoz commented 2 years ago

If i understand true, you have a CSV-List<> transformer right? So we are not limited to use it on MudTable?

enkodellc commented 2 years ago

Right now I use it to Import data into existing database tables. It could be used to populate MudTable as well. The main theme is that users often do not name their csv file headers to match watch is already defined by a table. So this helps them select the csv file and matches the fields. It is quite often used for CRM's / uploading to databases.