-
-
Notifications
You must be signed in to change notification settings - Fork 42
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
BOM import #273
base: master
Are you sure you want to change the base?
BOM import #273
Conversation
Merge from Binner master
Hi Sean - absolutely interested in this. It's been on my todo list for a while :) I'll review the code and see if we can get to an approval by Monday. Cheers! |
Excellent! Let me know any changes you'd like. |
Hello Jean, |
Ah yes that would help. I'm using the new BOM support in KiCAD 8 and then I added MPN for the manufacturer part number. I want to make it more robust to support other styles but this was a 1st pass. |
Hi Shaun, Thank you for your quick reply. I successfully imported your BOM. I had an idea for supporting multiple BOM formats: When you upload your BOM, it would display the contents of each column. Above each column, there could be a button to select the type of information it contains. If there are columns with data that aren't useful for the Binner, you could simply select "skip," and the program would ignore that column. This approach would allow for the upload of various types of BOMs. I got the idea from DigiKey, where you can upload BOMs into your basket and specify the type of information for each column. Best regards, |
Yeah that's my eventual goal but it's beyond my javascript hacking skills
atm. :D Plus I'm trying not to do too much yak shaving so I started with
this as this is all I need for the moment. lol.
Shaun
…On Fri, Aug 2, 2024 at 1:52 AM RoyalGamerTV ***@***.***> wrote:
Hi Shaun,
Thank you for your quick reply. I successfully imported your BOM. I had an
idea for supporting multiple BOM formats: When you upload your BOM, it
would display the contents of each column. Above each column, there could
be a button to select the type of information it contains. If there are
columns with data that aren't useful for the Binner, you could simply
select "skip," and the program would ignore that column. This approach
would allow for the upload of various types of BOMs. I got the idea from
DigiKey, where you can upload BOMs into your basket and specify the type of
information for each column.
Best regards,
max
—
Reply to this email directly, view it on GitHub
<#273 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/ABLXJ22QFUN5TLQWGMQCWKTZPNCFXAVCNFSM6AAAAABKDSXWP2VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDENRUHA4TGMZYHE>
.
You are receiving this because you authored the thread.Message ID:
***@***.***>
|
@@ -62,7 +50,7 @@ public async Task<ImportResult> ImportAsync(Project project, Stream stream, IUse | |||
// read csv header | |||
Header? header = null; | |||
var headerRow = rows.First(); | |||
if (headerRow.StartsWith("#")) | |||
if (headerRow.StartsWith("\"#\"")) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should likely be if (headerRow.StartsWith("#") || headerRow.StartsWith("\"#\""))
as many CSV formats don't require quoted headers
@shaun-leach once the conflicts are resolved I can merge this if all of your changes are complete |
Add support for importing BOMs via CSV and excel.
Curious if this is something you're interested in and if so, would love your input on this as I'm a hacker at times when it comes to stuff like this. ;) Also I want to clean up the import code to reduce the amount of duplicated code between the CSV and excel importers.