๐Ÿ“– User Guide
โฌ‡ Download PDF
  1. Features Overview
  2. How To โ€” Step-by-Step Workflows
  3. Admin Only
  4. CAD Integration

1. Features Overview

๐Ÿข Multi-tenant workspaces

PartsHub is multi-tenant โ€” one deployment can serve several independent companies (tenants), each with its own isolated database.


๐ŸŒ Multi-language

The UI runs in three languages: English, ็น้ซ”ไธญๆ–‡ (Traditional), and ็ฎ€ไฝ“ไธญๆ–‡ (Simplified). Change it from the user menu โ†’ ๐ŸŒ Language. The choice persists per browser (localStorage). The user guide is also served in the matching language when opened via the โ“ Help menu.


๐ŸŽ“ Interactive tours

Under โ“ Help โ–พ you'll find guided tours that highlight buttons and walk through common flows:

Each step points at the real UI element and can auto-navigate to the right tab. Great for onboarding new users.


๐Ÿงฉ Component Catalogue

The central record for every electronic part. Each component holds:

Components are linked to BOMs, vendor quotes, stock moves, and PO lines. Archiving a component hides it from active lists but preserves all history.


๐Ÿšš Stock Management

All quantity changes are recorded as moves, not direct edits:

Operation Effect When to use
IN Increases stock Receiving parts from a supplier or PO
OUT Decreases stock Consuming parts for a project or production
Transfer Moves between bins / ownerships Rearranging physical storage or reassigning ownership
Adjust Applies a signed delta (+ or โˆ’) to current stock Correcting stock after a physical count
Free Sample Increases stock Receiving a free sample โ€” no PO required

Each move stores: component, quantity, bin, ownership, date, user, and optional notes.

Date & time: every stock form has a Date and Time field so moves can be backdated. If left blank the current timestamp is used. All users (not just admins) may set this.

Destination (Stock OUT only): an optional field to record where the parts are physically going (e.g. "Company B"). Appears in the history table and export.

Ownership: each move is tagged to an ownership (e.g. "Company A", "Company B"). This controls which owner's inventory changes when the move is recorded.

Sample moves: both free and paid samples use the sample movement type and appear with a teal pill in stock-move history. Sample unit costs are excluded from the Moving Average Cost calculation so they do not distort regular production pricing.

All moves appear in Stock-move history and can be undone via โ†ถ Undo. Undoing a stock move deletes the original move record and reverses inventory โ€” no compensating row is left behind. Note: Free Sample moves cannot be undone โ€” use a Stock OUT to correct a mistake.


๐Ÿท๏ธ Lot Tracking (Date Code / Vendor Lot / Expiry)

Every Stock IN creates a lot โ€” a distinct batch identified by:

How lots are consumed: - Stock OUT and Production consumption deduct FIFO by expiry date (oldest first, NULLs last). "Legacy" lots (created during migration with no batch info) are drawn last so real-batch stock is used first. - Transfer and Reassign ownership preserve each lot's date code + expiry as it moves. - Adjustment with a positive delta creates a new lot; a negative delta consumes FIFO from existing lots.

Where to see lots: - Browse โ†’ Inventory โ€” click the ๐Ÿท๏ธ button on any row to see every active lot for that bin (date code, vendor lot, expiry countdown; expired = red, expiring < 30 days = amber). - Tools โ†’ ๐Ÿ•ฐ๏ธ Lot expiry โ€” a filterable report of every lot ranked by days-to-expiry; export to xlsx.


๐Ÿ“ฆ Products and BOMs

A product is an assembly (PCB, module, finished good). Its Bill of Materials lists every component needed and the quantity per unit.


๐Ÿ—๏ธ Build Feasibility

Tools โ†’ Build feasibility answers: "How many units can I build right now?"

Given a product and a target quantity, the tool checks every BOM line against current stock and classifies each part: - โœ… Sufficient stock - โš ๏ธ Partial stock (this part limits the buildable quantity) - โŒ Zero stock (hard blocker)

The result shows the maximum buildable quantity and a per-line stock breakdown.


โš ๏ธ Build Shortfalls

Tools โ†’ Build shortfalls shows a consolidated shortage list across all products โ€” useful for raising a purchase order to cover multiple builds at once.


๐Ÿงฎ BOM Cost Roll-up

Tools โ†’ BOM cost roll-up calculates the total material cost for a product.


๐Ÿท๏ธ Vendor Quotes

Vendor quotes record supplier pricing for components. Features: - Multiple vendors per component - Tiered pricing (MOQ breaks): e.g. 1โ€“99 pcs @ $0.50, 100+ @ $0.30 - Currency per quote (converted via FX rates) - Effective date range support


๐Ÿ›’ Purchase Orders

POs track orders placed with suppliers.

๐Ÿ›’ Create POs from BOM (product detail): a shortcut that groups a product's BOM lines by preferred vendor and lets you create one draft PO per vendor in a single click. Features: - Build volume input (default = product's target quantity) - "Consider stock" toggle โ†’ order only the shortfall - ๐Ÿ’ฐ Cheaper-elsewhere hint when another vendor's price is lower than the preferred vendor's - โš ๏ธ MOQ warnings per line - Tick individual vendor groups to include; unassigned components (no preferred vendor) get their own card that you resolve manually


๐ŸŽฏ End Customers

Manage โ†’ Manage lists โ†’ End customers โ€” a lookup of companies you deliver products to. Each row holds: - Name (required) - Website / note (optional) - Profit % โ€” a target margin used to compute quotation prices for that customer

The profit percentage feeds the Quotations module (below).


๐Ÿงพ Customer Quotations

Manage โ†’ ๐Ÿงพ Quotation โ€” issue a quote to an end customer. A single quote can mix any number of component lines and product lines.

Where to see quotes: Browse โ†’ ๐Ÿงพ Customer quotations โ€” filterable list with per-row actions: - Click a row to reopen and edit - ๐Ÿ–จ๏ธ Print (opens the printable HTML page) - xlsx export - Delete (soft-delete, recoverable by an admin)


๐Ÿ“‰ Reorder Suggestions

Tools โ†’ Reorder suggestions lists every component whose stock is at or below its reorder point. The table includes the lowest vendor quote so you can immediately assess cost before raising a PO.


๐Ÿญ Production Consumption

Tools โ†’ Production consumption deducts stock for a completed build run. Quantities come from the product's BOM ร— build volume โ€” no manual consumption file required.

Field Required Notes
Product โœ… Selects the BOM to use
Build volume โœ… Number of units built; all BOM quantities are multiplied by this
Producer (vendor) โ€” Contract manufacturer who performed the build
Production date โ€” Actual date of production (can be backdated)
Scrap file โ€” Excel/CSV with columns ID, Scrap, Location for components that had waste. Components not listed default to scrap = 0.

Workflow: 1. Fill in the fields above and click Preview 2. The preview table loads all BOM lines with deduction quantities and auto-selects the highest-stock bin per component 3. Review for any shortages (shown in red) 4. Click Apply (deduct stock) โ€” one Stock OUT move is created per BOM line

The operation is logged in the Activity log and can be undone via โ†ถ Undo.

Submitting scrap after the run: if the scrap data arrives after the production run has already been applied, go to Browse โ†’ Production log โ†’ Runs, find the run row, and click + Scrap. Upload the scrap file in the same format โ€” the system creates additional Stock OUT moves and links them back to the original run.

Scrap file format (optional): upload an Excel or CSV file with three columns:

Column Description
ID Component SN (e.g. R00032)
Scrap Number of scrapped units for this component
Location Storage bin the scrap came from

Components in the BOM but not listed in the scrap file default to scrap = 0. Scrap quantities are deducted separately from the main build deduction and appear in the Scrap report (Tools โ†’ Scrap report).


๐Ÿ”ง Adjustment Report

Tools โ†’ Adjustment report summarises all stock adjustments by component over a chosen date range. Use it to identify parts that are frequently or significantly corrected โ€” a pattern that may indicate handling losses, a bad reorder point, or an unreliable count process.

Column Description
# Events How many separate adjustment entries exist for this component in the range
Total adjusted Net delta across all events โ€” positive means net addition, negative means net removal
Last adjusted Date of the most recent adjustment
By Users who made adjustments for this component

The table is sorted by largest absolute total adjusted (biggest discrepancies first). Export to Excel via the โฌ‡ Export xlsx button.


๐Ÿ’ฑ FX Rates

Tools โ†’ FX rates stores exchange rates relative to the base currency (TWD by default). Rates are used by the cost roll-up and quote displays. Update rates manually as needed.


Universal search answers the question "find me anything related to X" โ€” it searches across all data types at once with a single keyword.

Mental model: it is a keyword lookup, not a full browse.

Universal Search Browse screens
Use when You don't know which tab holds what you need You know what you're looking at and want to filter/sort/export
Input Free-text keyword Structured filters (category, date range, typeโ€ฆ)
Output Top 50 matches per data type All matching rows, paginated
Scope Components, Products, BOMs, POs, Quotes, Files, Stock moves, Change log One data type per screen

What it searches in each bucket:

Bucket Fields searched
Components SN, MPN, description, manufacturer, value
Products Product code, name
BOM lines MPN, product code
Purchase orders PO number, vendor name, notes
Vendor quotes MPN, vendor name
Files Filename, notes
Stock moves SN, MPN, notes, created by, category code/name
Change log Summary, operation type, created by

50-result cap: each bucket shows at most 50 matches. If a bucket shows "top 50 matches", there are more rows โ€” use the dedicated Browse screen to see all of them. The Stock movements bucket links directly to Browse โ†’ Stock-move history when capped.

Tip: use a specific keyword (e.g. "MESH", "RC0402", "PO 150123") rather than a broad one โ€” the more specific, the more useful the results.


Other Search Tools

Feature Location Description
Component browse Browse โ†’ Components Full-text + column filters across the catalogue
BOM line browse Browse โ†’ BOM lines Search all BOM lines across all products
Stock-move history Browse โ†’ Stock-move history Full filterable/exportable move history
Unused components Search โ†’ Unused components Parts in catalogue not referenced by any active BOM
Most-used components Search โ†’ Most-used components Parts ranked by number of BOMs referencing them
Archived components Search โ†’ Archived components Soft-deleted components

Column filters (โ–พ button in any column header) work like Excel โ€” filter by exact value, range, or pattern. Active filters are highlighted in blue.


๐Ÿ“œ Activity Log and Undo

Browse โ†’ Activity log records every write operation: who did what and when.

The โ†ถ Undo button (top nav, Ctrl+Z) reverses the most recent reversible action. For stock moves, undo deletes the original record and corrects inventory โ€” no compensating row is created. Hover over the button to preview what will be undone. Not all operations are undoable โ€” the preview will indicate if an action cannot be reversed.


๐Ÿงฒ CAD Integration โ€” Cadence OrCAD Capture CIS

Cadence Capture engineers place parts directly from the PartsHub catalogue. Each schematic instance is stamped with the authoritative PartsHub SN, MPN, footprint, and lifecycle, and Capture's BOM export comes out with the correct internal Part Numbers. Snapshots (.mdb + .olb symbol libraries) are published per release via Tools โ†’ ๐Ÿ“ฅ Cadence CIS Downloads and downloaded by engineer PCs. Full setup and refresh workflows are in section 3 below.


2. How To โ€” Step-by-Step Workflows


Add a new component

  1. Go to Manage โ†’ Add component
  2. Fill in: MPN, category, manufacturer (required)
  3. Optionally add: value, spec, description, reorder point, initial bin
  4. Click Save
  5. The component gets an auto-assigned SN and appears in the catalogue immediately

Bulk-import components (admin)

Use this for seeding a fresh workspace or loading a supplier's parts list in one shot.

  1. Manage โ†’ ๐Ÿ“ฅ Components import (admin)
  2. Click โฌ‡ Download template (direct URL: /api/import/components/template.xlsx) โ€” an .xlsx pre-filled with the required columns and a Category dropdown listing every existing category code
  3. Fill one row per component in the template; leave optional columns blank
  4. Drag the file back onto the upload area (or click) โ†’ Preview โ€” the panel shows every row with a status: NEW, UPDATE (matched by SN or MPN), or SKIP (validation error)
  5. Fix any row flagged red, re-preview, then click Apply โ€” components are created/updated in a single transaction

Notes: - SN is auto-generated for NEW rows (respects the tenant's SN prefix) - Row-by-row errors don't block the successful rows; the summary reports what was imported and what was skipped - Everything is logged as components.import and undoable in the Activity log


Bulk-import a BOM

  1. Open the product โ†’ BOM lines panel โ†’ Import BOM
  2. Click โฌ‡ Download template on the upload dialog โ€” pre-set headers so auto-detect maps every column
  3. Fill one line per component (SN or MPN + Reference designators + Quantity), plus optional DNP / Value / Footprint / Notes
  4. Upload โ†’ Preview โ€” the importer resolves every row against the component catalogue (fuzzy match on MPN, exact on SN)
  5. Pick a replace mode โ€” merge (default; upsert only the file's rows), sections (wipe categories present in the file, then insert), or all (wipe every existing line before insert)
  6. Click Apply

Edit an existing component

  1. Go to Browse โ†’ Components
  2. Search or scroll to find the component
  3. Click any row to open the edit drawer
  4. Modify any field and click Save changes
  5. Use โ†ถ Undo to reverse if needed

Record stock IN (receiving parts)

  1. Go to Manage โ†’ Stock IN / OUT / Transfer
  2. Select the component (type MPN or description to search)
  3. Choose operation: IN
  4. Enter quantity and destination bin
  5. Set Type:
  6. receipt โ€” standard purchase (default)
  7. sample (cost not averaged) โ€” paid sample; enter unit cost for payment reference, but the price will not be included in the Moving Average Cost
  8. initial_count โ€” first-time stock entry
  9. transfer_in โ€” receiving a transfer from another bin
  10. Optionally enter unit cost, currency, link to a PO, and add a note
  11. Click Record

Receive a free sample (no PO)

Use this when a vendor sends parts at no charge โ€” no purchase order is involved.

  1. Go to Manage โ†’ Free Sample
  2. Select the component and bin
  3. Enter quantity
  4. Optionally fill in vendor name, sample reference, ownership, and notes
  5. Click Record Sample

The move is recorded as sample type with a teal pill in stock-move history. Free Sample moves cannot be undone โ€” record a Stock OUT to reverse if needed.


Record stock OUT (consuming parts)

  1. Manage โ†’ Stock IN / OUT / Transfer
  2. Choose OUT
  3. Select component, quantity, and source bin
  4. Optionally set Destination (where the parts are going, e.g. "Company B")
  5. Optionally set ownership and date/time
  6. Click Record

Transfer between bins

  1. Manage โ†’ Stock IN / OUT / Transfer
  2. Choose Transfer
  3. Select component, quantity, source bin โ†’ destination bin
  4. Click Record

Correct stock with an adjustment

Use Adjust when a physical count reveals the system quantity does not match reality and you cannot trace the exact cause (unknown scrap, damage, miscounting in a previous receipt, etc.).

Important: Adjust takes a delta โ€” the difference, not the target total. If the system shows 500 and the physical count is 480, enter โˆ’20. If the system shows 300 and the physical count is 310, enter +10.

Do not use Adjust for scrap โ€” use the Submit Scrap workflow instead (Browse โ†’ Production log โ†’ find the run โ†’ + Scrap). Using both for the same event causes double-deduction.

  1. Manage โ†’ Stock IN / OUT / Transfer
  2. Choose Adjust
  3. Select component, location, and ownership
  4. Enter the delta โ€” positive to add, negative to remove (e.g. โˆ’20)
  5. Add a note describing why the discrepancy exists (or "physical count" if unknown)
  6. Click Adjust

To review all past adjustments across components, use Tools โ†’ Adjustment report. Filter by date range and category to identify parts with frequent or large discrepancies.


Create a new product and BOM

  1. Manage โ†’ New product โ€” enter name, revision, status
  2. Open the product (Browse โ†’ Products โ†’ click row)
  3. In the BOM tab, click Import BOM to upload a CSV, or Add line to enter manually
  4. CSV format: MPN, Quantity, Reference (one line per component)
  5. Unmatched MPNs will prompt you to create new components on the fly

Check if you can build a product

  1. Tools โ†’ Build feasibility
  2. Select a product
  3. Enter target quantity
  4. Review the โœ… / โš ๏ธ / โŒ status per component
  5. The header shows the maximum buildable quantity

Calculate BOM cost

  1. Tools โ†’ BOM cost roll-up
  2. Select a product and quantity
  3. The table shows unit cost and extended cost per line
  4. Click Export to Excel to download

Create a Purchase Order

  1. Manage โ†’ Purchase Order
  2. Fill in: vendor, currency, expected delivery date, and optionally Owner (who paid for / owns this stock)
  3. Click Add line for each component โ€” enter MPN, qty, unit price
  4. Click Save PO
  5. When parts arrive: Browse โ†’ Purchase orders โ†’ click the PO โ†’ Receive
  6. All received stock is automatically assigned to the PO's owner

Receive a PO (partial or full)

  1. Browse โ†’ Purchase orders โ†’ click a PO row
  2. For each line that has arrived, check the box and confirm quantity
  3. Click Receive selected โ€” stock IN moves are created automatically
  4. Unreceived lines remain open on the PO

Create POs from a product's BOM

  1. Open the product (Browse โ†’ Products โ†’ click row)
  2. In the BOM lines panel, click ๐Ÿ›’ Create POs from BOM
  3. Enter the build volume
  4. Optionally tick "Order only shortfall" to subtract current stock
  5. Review the per-vendor cards โ€” each shows the lines, qty, unit price, per-currency totals
  6. Watch for hints:
  7. ๐Ÿ’ฐ = cheaper elsewhere (another vendor has a lower price at this qty)
  8. โš ๏ธ = below MOQ or no preferred vendor
  9. Untick any vendor group you don't want to create right now
  10. Click Create selected POs โ€” one draft PO per vendor group

Issue a customer quotation

  1. Make sure the customer exists: Manage โ†’ Manage lists โ†’ End customers. Set the Profit %.
  2. Manage โ†’ ๐Ÿงพ Quotation opens the New quotation form
  3. Pick the end customer (their profit auto-fills)
  4. Choose quote date, valid-until date, currency, notes
  5. Add lines:
  6. + Component โ€” enter SN or MPN, cost auto-loads from components.unit_cost
  7. + Product โ€” enter product code, cost auto-sums from the BOM
  8. Edit quantity, unit cost, or profit % per line โ€” unit price and line total recompute live
  9. Click Save โ€” quote gets an auto number Q-YYYYMMDD-NNN
  10. Find it in Browse โ†’ ๐Ÿงพ Customer quotations
  11. From the list: ๐Ÿ–จ๏ธ Print, xlsx Export, or delete

Record a lot / batch on receipt

When receiving parts that carry a manufacturer's date code or a distributor lot number:

  1. Manage โ†’ Stock IN
  2. Fill in the standard fields (component, location, qty, ownership)
  3. Fill in the optional lot fields:
  4. Date code โ€” e.g. 2352
  5. Lot number โ€” from the distributor's label (e.g. 904042AJ2)
  6. Expiry date โ€” for age-sensitive parts
  7. Submit โ€” this creates a distinct lot. Every future Stock OUT or Production run consumes FIFO by expiry.

To view all lots for a bin: Browse โ†’ Inventory โ†’ click the ๐Ÿท๏ธ button on the row. To find expiring parts: Tools โ†’ ๐Ÿ•ฐ๏ธ Lot expiry.


Switch between tenants

If your account has access to more than one tenant:


Change UI language

  1. Click your name (top-right) to open the user menu
  2. Under ๐ŸŒ Language, pick English / ็น้ซ”ไธญๆ–‡ / ็ฎ€ไฝ“ไธญๆ–‡
  3. The choice persists on this browser. The user guide (โ“ Help โ†’ ๐Ÿ“– User guide) also switches to match.

Add a vendor quote

  1. Open a component (Browse โ†’ Components โ†’ click row)
  2. Go to the Quotes tab in the edit drawer
  3. Click Add quote
  4. Enter: vendor, currency, MOQ, unit price, effective dates
  5. Add additional price tiers for quantity breaks if needed

Record a production run

  1. Tools โ†’ Production consumption
  2. Select the product and enter the build volume (number of units built)
  3. Optionally fill in: producer/vendor, production date, and a scrap file (Excel/CSV with columns ID, Scrap, Location)
  4. Click Preview โ€” the table loads one row per BOM line with auto-selected bins (highest-stock bin per component) and calculates total deduction = BOM qty ร— build volume
  5. Review the preview: rows shown in red indicate a shortage
  6. Click Apply (deduct stock) โ€” one Stock OUT move is created per BOM line
  7. The run is logged in the Activity log; use โ†ถ Undo to reverse if needed

If scrap data arrives later: go to Browse โ†’ Production log โ†’ Runs, click + Scrap on the relevant run, and upload the scrap file. Additional OUT moves are created and linked to the original run automatically.


Find what to reorder

  1. Tools โ†’ Reorder suggestions
  2. Review the list of parts below their reorder point
  3. Click on any row to open the component for more detail
  4. Use the quote information to raise a PO

Export data

What How
Component list Browse โ†’ Components โ†’ Export (Excel)
Stock-move history Browse โ†’ Stock-move history โ†’ Export
BOM cost Tools โ†’ BOM cost roll-up โ†’ Export to Excel
Adjustment report Tools โ†’ Adjustment report โ†’ โฌ‡ Export xlsx
Activity log Browse โ†’ Activity log โ†’ Export

Manage users (admin only)

  1. Manage โ†’ ๐Ÿ‘ฅ Users
  2. Click + Add user to create an account โ€” set username, display name, role, and temporary password
  3. On any row:
  4. Edit โ€” profile fields; Password โ€” reset password
  5. Role โ€” opens a dropdown modal with admin / user / readonly
  6. Enable / Disable โ€” flip is_active (self-disable is blocked)
  7. Make super / Revoke super โ€” visible only to a super-admin; grants the cross-tenant super-admin flag (self-revoke blocked to avoid lockout)
  8. Delete โ€” soft-delete; a Show deleted checkbox surfaces hidden rows with Restore / Delete forever
  9. Delete forever now also removes the corresponding master.users row and its user_tenants mapping if the user has no other memberships โ€” no more ghost entries in the Tenants panel
  10. Roles:
  11. admin โ€” full write access in the tenant
  12. user โ€” normal write access
  13. readonly โ€” view only
  14. super-admin โ€” cross-tenant privilege (Tenants panel, per-tenant DB sizes in Storage usage, can enter any tenant); orthogonal to role
  15. Users can change their own password via the top-right dropdown โ†’ Change password

New signup flow: registered users start as readonly + is_active=0 and can't sign in until an admin flips them active. Approval emails go to every super-admin plus every admin of the target tenant.


Manage tenants (super-admin only)

  1. Manage โ†’ ๐Ÿข Tenants (super-admin)
  2. Existing tenants show slug, name, DB, user count, active toggle, and an optional SN prefix (3 uppercase letters, unique across tenants โ€” prepended to auto-generated component SNs as PFX-R00001)
  3. To create a new tenant: fill in slug (lowercase, URL-safe) + display name, then optionally the First admin section (username / full name / email / temporary password). Click Provision โ€” creates a new empty database with the current schema and category list seeded (locations, ownerships, and other lookup lists start empty). If a first admin is given, they get a welcome email with sign-in details.
  4. Toggle active off to hide a tenant from the login picker without deleting anything
  5. In the User โ†’ Tenant mapping grid, tick which users belong to which tenants
  6. Backups โ€” automatic nightly dump at 03:00 UTC, retained 7 days per tenant. Click Backup now for an on-demand snapshot.

File storage isolation: uploaded files (product files, datasheets, PO attachments, component design files, company logos, manufacturer/vendor logos) live under webui/uploads/<tenant-slug>/โ€ฆ โ€” each tenant's files are on a separate subtree and can only be reached through its own DB.


Update FX rates

  1. Tools โ†’ FX rates
  2. Enter the rate for each currency relative to the base currency (TWD)
  3. Click Save โ€” cost roll-ups immediately use the new rates

Check storage usage

  1. Manage โ†’ ๐Ÿ’พ Storage usage (admin only)
  2. Directories โ€” per-kind file counts and disk usage for the current tenant's upload subtree (webui/uploads/<slug>/โ€ฆ)
  3. Database โ€” per-table row counts and sizes for the current tenant's DB
  4. Disk โ€” free space on the VM
  5. Super-admins additionally see a ๐Ÿข Per-tenant database size table listing every tenant's DB size and table count so they can spot which workspace is growing fastest

View stock-move history

  1. Browse โ†’ Stock-move history
  2. Set one or more filters: component ID/MPN, category, location, type, product, date range
  3. Click Search
  4. Results show IN / OUT quantities, destination, and who recorded the move
  5. Click Export โ†“ to download the filtered result as Excel

The Product filter is especially useful: selecting a product shows all moves for every component in its BOM, including components from sub-assemblies.


3. Admin Only

Features gated to admin role (or higher). Regular users won't see the menu entries.

Quick index โ€” where each admin feature lives

Task Where Notes
Bulk-import components Manage โ†’ ๐Ÿ“ฅ Components import .xlsx template with category dropdown; preview then apply
Manage users (create, role, enable, password reset, delete) Manage โ†’ ๐Ÿ‘ฅ Users See "Manage users"
Manage tenants (create workspaces, first admin, backups) Manage โ†’ ๐Ÿข Tenants (super-admin) Super-admin only
Grant / revoke Super-admin Users tab โ†’ Make super / Revoke super Super-admin only; can't revoke self
Storage usage Manage โ†’ ๐Ÿ’พ Storage usage Tenant-scoped for admins; per-tenant DB breakdown for super-admins
Edit legacy lot expiry Tools โ†’ ๐Ÿ•ฐ๏ธ Lot expiry โ†’ Edit per row Fix expiry/date-code/vendor-lot on pre-PartsHub stock
Backdate stock moves Any Stock IN/OUT/Transfer/Adjust form โ†’ Date field Non-admins can only backdate ~5 min in the past
Export "Update source file" Browse โ†’ Components โ†’ Update source file Overwrites component_coding.xlsx on the VM (backup taken first)
Delete permanently (Delete forever) Users tab โ†’ Show deleted โ†’ Delete forever Purges master.users + user_tenants; irreversible

Admin sanity checklist

Do these once when spinning up a new tenant:

  1. Provision the tenant with a First admin so someone can approve future signups
  2. In Manage โ†’ Manage lists, seed the initial Locations (physical bins) and Ownerships
  3. Optionally set an SN prefix in Tenants so component SNs read PFX-R00001
  4. Configure SMTP on the VM (webui/.env) so approval / welcome emails actually send

Role reference

Role Read Write Manage users Cross-tenant
readonly โœ… โŒ โŒ โŒ
user โœ… โœ… Own profile only โŒ
admin โœ… โœ… Full within tenant โŒ
super-admin (flag) โœ… โœ… Full + Tenants panel โœ…

super-admin is orthogonal to role โ€” you can be user + super, or admin + super. Grant/revoke via Users โ†’ Make super / Revoke super.


โ˜๏ธ Automatic off-site backup

Goal: every night, a .zip of your tenant's DB + uploads lands in your own OneDrive / Google Drive / Dropbox โ€” without giving PartsHub any cloud credentials.

How it works

  1. PartsHub gives you an API key + a ready-made script.
  2. You save the script on your PC and schedule it (Task Scheduler on Windows / cron on macOS / Linux).
  3. The script downloads a fresh .zip every night into a folder you choose.
  4. Your OneDrive / Google Drive / Dropbox client is already syncing that folder โ†’ the backup lands in your cloud automatically.

One-time setup (~3 minutes)

  1. Open Manage โ†’ ๐Ÿ’พ Storage usage โ†’ โ˜๏ธ Automatic off-site backup.
  2. Click + Generate API key, give it a label like "OneDrive โ€“ my PC". Copy the key โ€” it's shown only once.
  3. Click โฌ‡ Windows script (.ps1) or โฌ‡ macOS / Linux script (.sh) โ€” the file downloads.
  4. Open the script in a text editor and:
  5. Paste the key into the $BackupKey = '...' line.
  6. Set $DestDir to a folder your cloud client already syncs (e.g. C:\Users\me\OneDrive\PartsHub-Backups\adaptox).
  7. Register the script with Task Scheduler (Windows) or crontab -e (Mac / Linux) โ€” daily at your preferred time.

Turning it off / rotating keys

What's inside the zip

Security notes


4. CAD Integration

๐Ÿงฒ Cadence OrCAD Capture CIS

Capture engineers can place parts directly from PartsHub. The schematic instance is stamped with the authoritative PartsHub SN, MPN, footprint, and lifecycle, and the BOM export from Capture already carries the correct internal Part Numbers.

How it works (snapshot mode)

The catalog refreshes once per release โ€” no live DB connection required from engineer PCs, and no MySQL port exposed on the VM firewall.

Admin card: Tools โ†’ ๐Ÿ“ฅ Cadence CIS Downloads

How to โ€” publish a new CIS download

  1. Double-click scripts\refresh_cis.bat. It reads scripts\refresh_cis.env (create once from scripts\refresh_cis.env.example with your MYSQL_PASSWORD + PARTSHUB_SESSION cookie), pulls the latest cloud DB into local (scripts\pull_cloud_to_local.ps1), rebuilds the .mdb from that, uploads to PartsHub, and prints the download URL.
  2. Confirm in Tools โ†’ ๐Ÿ“ฅ Cadence CIS Downloads that today's .mdb is at the top with a fresh timestamp.
  3. Notify engineers so they re-download. The Latest download URL copy-button on the card is the stable URL you can hand out โ€” it always resolves to the newest .mdb.

How to โ€” build an offline handover bundle

.\scripts\pack_cis_zip.ps1 builds exports\cis\partshub-cis-YYYY-MM-DD.zip containing the latest .mdb, every .olb from PartsHub, and a README with the setup steps. Email or USB-transfer the zip to any engineer PC โ€” no PartsHub login needed on that side. Same-day rebuild: run refresh_cis.bat first so the bundle picks up today's snapshot.

How to โ€” upload a new symbol library (.olb)

.olb files are one-time uploads; they're only replaced when the symbol itself changes.

How to โ€” assign a Capture symbol to a part

Capture's Schematic Part is a bare symbol name (e.g. R, INDUCTOR, MAX__MAX1719_0) โ€” not LIBRARY:PART syntax. On placement, Capture searches every registered .olb for a part with that exact internal name and uses the first match.

Three levers, in order of preference:

Category Default
R R
C C
L INDUCTOR
D DIODE
SW SW PUSHBUTTON-SPST
CON CONNECTOR
Q, IC, LED, F, Y, T none โ€” must set per part

Change with SQL on the tenant DB: sql UPDATE component_categories SET cis_default_symbol='DIODE' WHERE code='D'; - Bulk / scripted โ€” scripts\set_cis_symbol.ps1 -Sn <SN> -Symbol <name> updates both local and cloud in one shot. Useful for scripted seeds (see scripts\setup_ic_olbs.sql for the initial seeding mapping).

After any change, run scripts\refresh_cis.bat and engineers re-download the .mdb. refresh_cis.bat auto-pulls cloud โ†’ local before building, so cloud is always the source of truth.

Gotchas

How to โ€” set up a new engineer PC

Prereqs (once per PC):

  1. Install the standalone Microsoft Access Database Engine 2016 Redistributable (64-bit) โ€” download AccessDatabaseEngine_X64.exe (79.5 MB) from Microsoft's page. Install it from an elevated PowerShell with the SkipQuickReg=1 flag โ€” this makes it work even when the PC already has Microsoft 365 / Office (which ships its own ACE driver that CIS is not compatible with):

powershell Start-Process -FilePath "C:\path\to\AccessDatabaseEngine_X64.exe" ` -ArgumentList "/quiet","/norestart","SkipQuickReg=1" -Verb RunAs -Wait

Verify the standalone version is registered (not the Office version):

powershell Get-ItemProperty 'HKLM:\SOFTWARE\ODBC\ODBCINST.INI\Microsoft Access Driver (*.mdb, *.accdb)' | Select-Object Driver

Expected: C:\PROGRA~1\COMMON~1\MICROS~1\OFFICE16\ACEODBC.DLL (version 16.0.4999.1000). If it says \Microsoft Office\root\vfs\ instead, the Office ACE driver won and CIS will drop the connection every 1โ€“5 minutes. Re-run the install, then reboot.

  1. Create the folder %USERPROFILE%\PartsHub\.
  2. In Access: File โ†’ Options โ†’ Trust Center โ†’ Trust Center Settings โ†’ Trusted Locations โ†’ Add new location, path %USERPROFILE%\PartsHub\, tick Subfolders trusted. This prevents Mark-of-the-Web from blocking each freshly-downloaded .mdb.

Get the files:

Configure Capture (once):

  1. Launch OrCAD Capture CIS (not plain Capture โ€” File โ†’ Change Product if needed).
  2. Open or create a project.
  3. Options โ†’ CIS Configuration โ†’ Setup โ†’ Newโ€ฆ
  4. Name: PartsHub
  5. Data source: Microsoft Access Database
  6. Database file: %USERPROFILE%\PartsHub\partshub_cis.mdb
  7. Tick cis_components โ†’ Next
  8. Wizard steps: Part_Number โ†’ Part Number, Value โ†’ Value, Part_Type โ†’ Category Code, Schematic_Part โ†’ Schematic Part, Browsable โ†’ tick Datasheet, Visibility โ†’ keep Part Number
    • Value, Keyed โ†’ tick both. Finish.
  9. In Project Manager โ†’ Library folder โ†’ right-click โ†’ Add Fileโ€ฆ โ†’ select every .olb in %USERPROFILE%\PartsHub\.

Test:

  1. Place โ†’ Database Partโ€ฆ (Z) โ†’ pick a resistor (R00001) โ†’ Place.
  2. Confirm the placed symbol carries the PartsHub SN as its Part Number property.

If Capture pops "Package X not found in configured libraries list", click Configure Library on the dialog and add the missing .olb from %USERPROFILE%\PartsHub\.

How to โ€” refresh after the database changes

Engineer side, per release:

  1. Close Capture before updating โ€” replacing the file while Capture has it open causes a connection drop and triggers the Select Database popup.
  2. Tools โ†’ ๐Ÿ“ฅ Cadence CIS Downloads โ†’ Download the top row.
  3. Save as %USERPROFILE%\PartsHub\partshub_cis.mdb, overwrite the previous file.
  4. Unblock: right-click partshub_cis.mdb โ†’ Properties โ†’ tick ่งฃ้™คๅฐ้Ž– / Unblock โ†’ OK. (Every download resets the MotW flag.)
  5. Reopen Capture โ€” the new rows appear in the CIS browser.

If a symbol library changed, also re-download the new .olb.

How to โ€” handle Windows / Office updates that break CIS

Symptom: after a Windows Update, Office 365 update, or Access reinstall, Capture's CIS starts popping the Select Database dialog every 1โ€“5 minutes. This means an OS update has re-registered the Office Click-to-Run ACE driver on top of the standalone one that CIS needs.

Recovery โ€” 30 seconds, no install needed. Two ways:

Easy way โ€” double-click scripts\repair_ace_odbc.cmd from the repo (or the copy someone dropped on your Desktop). It reads the current ODBC registration, decides whether a fix is needed, prompts for UAC only if it has to change anything, and reports the outcome. Idempotent โ€” safe to run whenever CIS acts up.

Manual way โ€” do it inline if you don't have the script handy:

  1. Verify the ODBC driver has flipped back to the wrong DLL: powershell Get-ItemProperty 'HKLM:\SOFTWARE\ODBC\ODBCINST.INI\Microsoft Access Driver (*.mdb, *.accdb)' | Select-Object Driver Bad: a path containing \Microsoft Office\root\vfs\. Good: C:\Program Files\Common Files\Microsoft Shared\OFFICE16\ACEODBC.DLL.

  2. If bad, flip the ODBC registration back to the standalone DLL directly โ€” run these four commands in an elevated PowerShell (right-click โ†’ Run as administrator), no re-install needed: powershell $dll = 'C:\Program Files\Common Files\Microsoft Shared\OFFICE16\ACEODBC.DLL' # 64-bit ODBC (checked by 64-bit tools and some apps) reg.exe add "HKLM\SOFTWARE\ODBC\ODBCINST.INI\Microsoft Access Driver (*.mdb, *.accdb)" /v Driver /t REG_SZ /d $dll /f reg.exe add "HKLM\SOFTWARE\ODBC\ODBCINST.INI\Microsoft Access Driver (*.mdb, *.accdb)" /v Setup /t REG_SZ /d $dll /f # 32-bit ODBC (checked by Capture, which is a 32-bit process) reg.exe add "HKLM\SOFTWARE\WOW6432Node\ODBC\ODBCINST.INI\Microsoft Access Driver (*.mdb, *.accdb)" /v Driver /t REG_SZ /d $dll /f reg.exe add "HKLM\SOFTWARE\WOW6432Node\ODBC\ODBCINST.INI\Microsoft Access Driver (*.mdb, *.accdb)" /v Setup /t REG_SZ /d $dll /f Both the 64-bit (SOFTWARE\ODBC\โ€ฆ) and 32-bit (SOFTWARE\WOW6432Node\ODBC\โ€ฆ) keys must point at the standalone DLL โ€” Capture is a 32-bit process and reads the WOW6432Node hive. Fixing only the 64-bit key leaves the popup recurring.

Verify both afterwards: powershell Get-ItemProperty 'HKLM:\SOFTWARE\ODBC\ODBCINST.INI\Microsoft Access Driver (*.mdb, *.accdb)' | Select-Object Driver Get-ItemProperty 'HKLM:\SOFTWARE\WOW6432Node\ODBC\ODBCINST.INI\Microsoft Access Driver (*.mdb, *.accdb)' | Select-Object Driver Both should show C:\Program Files\Common Files\Microsoft Shared\OFFICE16\ACEODBC.DLL.

  1. Reboot Windows (belt-and-braces โ€” some cached ACE DLLs stay loaded in Capture until process/OS restart).

  2. Reopen Capture. Pop-ups should stop.

Why the installer isn't enough: re-running AccessDatabaseEngine_X64.exe sees the same version already installed and does a no-op โ€” the ODBC registration Office overwrote never gets restored. The reg.exe fix above is what actually takes.

When to use the installer: only if the standalone DLL itself is missing (e.g. fresh PC that never had this fix, or someone uninstalled the redistributable).

Preventive habits:

Setup files and DBC template

The DBC template and full engineer walkthrough live in docs/cis/.


Document last updated: 2026-09-15