Skip to content

Simplify Part / SupplierPart relationship #680

Closed

Description

@SchrodingersGat

Currently, a "Part" must be linked to a "SupplierPart" to be purchaseable, or be linked to data such as "manufacturer" / "supplier" etc.

This creates some unnecessary duplication for any Part where there is only one concrete SupplierPart reference. In such as case, the relationship:

Part <- SupplierPart is moot, it could simple be Part - *if the Part object could link to a Supplier, MPN, etc.

Proposal

  1. Remove the "SupplierPart" model entirely
  2. The "Part" model gets the following additional fields:
  • Supplier (Company)
  • SKU
  • MPN
  • price
  1. The "Part" model becomes a tree-style model, with "child" parts that are more "refined" versions of the part above them.

For example, a part could be "10K_0805" (not "fully defined") but it has two child parts which point to concrete 10K_0805 resistors from various manufacturers.

Or, a Part could be a fully-defined resistor with complete link to MPN / SKU / etc

One advantage of such an approach is that a BOM could specify the top-level part (e.g. "10K_0805") to mean "It does not particularly matter which 10K 0805 resistor is used here, as long as it is found underneath this generic part".

Alternatively, a BOM can specify a "concrete" (fully defined) part.

Activity

  1. maholli commented on Apr 4, 2020

    @maholli

    I think this is the proper way to handle this. Passives are a great example of not caring about the endless SKU adaptations, but merely that it's a "10K_0805."

    Should be a straightforward change to the current db, right? Just take existing SupplierPart entries and change them to the proposed "child" format, then add them as children to the appropriate Part entries.

  2. a7hybnj2 commented on Apr 13, 2020

    @a7hybnj2

    I am very interested in this feature. I switched 1206 blue leds recently. In all my builds I had to update to be the new part#. Would be amazing if you could link criteria like 1206, BLUE, 10˚, 20mA. and have it point to all matching parts.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions