Skip to content

Commit 02b1f7a

Browse files
Copilotjbtronics
andauthored
Improve documentation clarity and fix outdated information (#1129)
* Initial plan * Improve documentation clarity, fix typos, and update outdated information Co-authored-by: jbtronics <[email protected]> * Replace LCSC with Mouser in cloud providers list per d-buchmann's review Co-authored-by: jbtronics <[email protected]> * Remove outdated Mouser API issue notice Removed outdated information about the Mouser API's current issues with datasheets and part specifications. --------- Co-authored-by: copilot-swe-agent[bot] <[email protected]> Co-authored-by: jbtronics <[email protected]> Co-authored-by: Jan Böhmer <[email protected]>
1 parent d244400 commit 02b1f7a

18 files changed

+95
-97
lines changed

CONTRIBUTING.md

Lines changed: 22 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# How to contribute
22

3-
Thank you for consider to contribute to Part-DB!
4-
Please read the text below, so your contributed content can be contributed easily to Part-DB.
3+
Thank you for considering contributing to Part-DB!
4+
Please read the text below, so your contributed content can be incorporated into Part-DB easily.
55

66
You can contribute to Part-DB in various ways:
77
* Report bugs and request new features via [issues](https://github.com/Part-DB/Part-DB-server/issues)
@@ -18,38 +18,38 @@ Part-DB uses translation keys (e.g. part.info.title) that are sorted by their us
1818
was translated in other languages (this is possible via the "Other languages" dropdown in the translation editor).
1919

2020
## Project structure
21-
Part-DB uses symfony's recommended [project structure](https://symfony.com/doc/current/best_practices.html).
21+
Part-DB uses Symfony's recommended [project structure](https://symfony.com/doc/current/best_practices.html).
2222
Interesting folders are:
2323
* `public`: Everything in this directory will be publicly accessible via web. Use this folder to serve static images.
24-
* `assets`: The frontend assets are saved here. You can find the javascript and CSS code here.
25-
* `src`: Part-DB's PHP code is saved here. Note that the sub directories are structured by the classes purposes (so use `Controller` Controllers, `Entities` for Database models, etc.)
26-
* `translations`: The translations used in Part-DB are saved here
24+
* `assets`: The frontend assets are saved here. You can find the JavaScript and CSS code here.
25+
* `src`: Part-DB's PHP code is saved here. Note that the subdirectories are structured by the classes' purposes (so use `Controller` for Controllers, `Entity` for Database models, etc.)
26+
* `translations`: The translations used in Part-DB are saved here.
2727
* `templates`: The templates (HTML) that are used by Twig to render the different pages. Email templates are also saved here.
28-
* `tests/`: Tests that can be run by PHPunit.
28+
* `tests/`: Tests that can be run by PHPUnit.
2929

3030
## Development environment
31-
For setting up an development you will need to install PHP, composer, a database server (MySQL or MariaDB) and yarn (which needs an nodejs environment).
32-
* Copy `.env` to `.env.local` and change `APP_ENV` to `APP_ENV=dev`. That way you will get development tools (symfony profiler) and other features that
31+
For setting up a development environment, you will need to install PHP, Composer, a database server (MySQL or MariaDB) and yarn (which needs a Node.js environment).
32+
* Copy `.env` to `.env.local` and change `APP_ENV` to `APP_ENV=dev`. That way you will get development tools (Symfony profiler) and other features that
3333
will simplify development.
34-
* Run `composer install` (without -o) to install PHP dependencies and `yarn install` to install frontend dependencies
35-
* Run `yarn watch`. The program will run in the background and compile the frontend files whenever you change something in the CSS or TypeScript files
36-
* For running Part-DB it is recommended to use [Symfony CLI](https://symfony.com/download).
37-
That way you can run a correct configured webserver with `symfony serve`
34+
* Run `composer install` (without -o) to install PHP dependencies and `yarn install` to install frontend dependencies.
35+
* Run `yarn watch`. The program will run in the background and compile the frontend files whenever you change something in the CSS or TypeScript files.
36+
* For running Part-DB, it is recommended to use [Symfony CLI](https://symfony.com/download).
37+
That way you can run a correctly configured webserver with `symfony serve`.
3838

3939
## Coding style
40-
Code should follow the [PSR12-Standard](https://www.php-fig.org/psr/psr-12/) and symfony's [coding standards](https://symfony.com/doc/current/contributing/code/standards.html).
40+
Code should follow the [PSR-12 Standard](https://www.php-fig.org/psr/psr-12/) and Symfony's [coding standards](https://symfony.com/doc/current/contributing/code/standards.html).
4141

4242
Part-DB uses [Easy Coding Standard](https://github.com/symplify/easy-coding-standard) to check and fix coding style violations:
43-
* To check your code for valid code style run `vendor/bin/ecs check src/`
44-
* To fix violations run `vendor/bin/ecs check src/` (please checks afterwards if the code is valid afterwards)
43+
* To check your code for valid code style, run `vendor/bin/ecs check src/`
44+
* To fix violations, run `vendor/bin/ecs check src/ --fix` (please check afterwards if the code is still valid)
4545

4646
## GitHub actions
47-
Part-DB uses GitHub actions to run various tests and checks on the code:
47+
Part-DB uses GitHub Actions to run various tests and checks on the code:
4848
* Yarn dependencies can compile
49-
* PHPunit tests run successful
50-
* Config files, translations and templates has valid syntax
51-
* Doctrine schema valid
49+
* PHPUnit tests run successfully
50+
* Config files, translations, and templates have valid syntax
51+
* Doctrine schema is valid
5252
* No known vulnerable dependencies are used
53-
* Static analysis successful (phpstan with `--level=2`)
53+
* Static analysis is successful (phpstan with `--level=2`)
5454

55-
Further the code coverage of the PHPunit tests is determined and uploaded to [CodeCov](https://codecov.io/gh/Part-DB/Part-DB-server).
55+
Further, the code coverage of the PHPUnit tests is determined and uploaded to [CodeCov](https://codecov.io/gh/Part-DB/Part-DB-server).

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -142,7 +142,7 @@ There you will find various methods to support development on a monthly or a one
142142

143143
## Built with
144144

145-
* [Symfony 5](https://symfony.com/): The main framework used for the serverside PHP
145+
* [Symfony 6](https://symfony.com/): The main framework used for the serverside PHP
146146
* [Bootstrap 5](https://getbootstrap.com/) and [Bootswatch](https://bootswatch.com/): Used as website theme
147147
* [Fontawesome](https://fontawesome.com/): Used as icon set
148148
* [Hotwire Stimulus](https://stimulus.hotwired.dev/) and [Hotwire Turbo](https://turbo.hotwired.dev/): Frontend

docs/api/intro.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ See [Authentication chapter]({% link api/authentication.md %}) for more details.
4646

4747
The API is split into different endpoints, which are reachable under the `/api/` path of your Part-DB instance (
4848
e.g. `https://your-part-db.local/api/`).
49-
There are various endpoints for each entity type (like `part`, `manufacturer`, etc.), which allow you to read and write data, and some special endpoints like `search` or `statistics`.
49+
There are various endpoints for each entity type (like `parts`, `manufacturers`, etc.), which allow you to read and write data, and some special endpoints like `search` or `statistics`.
5050

5151
For example, all API endpoints for managing categories are available under `/api/categories/`. Depending on the exact
5252
path and the HTTP method used, you can read, create, update or delete categories.
@@ -56,7 +56,7 @@ For most entities, there are endpoints like this:
5656
* **POST**: `/api/categories/` - Create a new category
5757
* **GET**: `/api/categories/{id}` - Get a specific category by its ID
5858
* **DELETE**: `/api/categories/{id}` - Delete a specific category by its ID
59-
* **UPDATE**: `/api/categories/{id}` - Update a specific category by its ID. Only the fields which are sent in the
59+
* **PATCH**: `/api/categories/{id}` - Update a specific category by its ID. Only the fields which are sent in the
6060
request are updated, all other fields are left unchanged.
6161
Be aware that you have to set the [JSON Merge Patch](https://datatracker.ietf.org/doc/html/rfc7386) content type
6262
header (`Content-Type: application/merge-patch+json`) for this to work.

docs/concepts.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -23,14 +23,14 @@ each other so that it does not matter which one of your 1000 things of Part you
2323
A part entity has many fields, which can be used to describe it better. Most of the fields are optional:
2424

2525
* **Name** (Required): The name of the part or how you want to call it. This could be a manufacturer-provided name, or a
26-
name you thought of yourself. Each name needs to be unique and must exist in a single category.
26+
name you thought of yourself. Each name needs to be unique and must exist in a single category only.
2727
* **Description**: A short (single-line) description of what this part is/does. For longer information, you should use
2828
the comment field or the specifications
2929
* **Category** (Required): The category (see there) to which this part belongs to.
3030
* **Tags**: The list of tags this part belongs to. Tags can be used to group parts logically (similar to the category),
3131
but tags are much less strict and formal (they don't have to be defined beforehand) and you can assign multiple tags to
3232
a part. When clicking on a tag, a list with all parts which have the same tag, is shown.
33-
* **Min Instock**: *Not really implemented yet*. Parts where the total instock is below this value, will show up for
33+
* **Min Instock**: *Not fully implemented yet*. Parts where the total instock is below this value will show up for
3434
ordering.
3535
* **Footprint**: See there. Useful especially for electronic parts, which have one of the common electronic footprints (
3636
like DIP8, SMD0805 or similar). If a part has no explicitly defined preview picture, the preview picture of its
@@ -48,9 +48,9 @@ A part entity has many fields, which can be used to describe it better. Most of
4848
completely trustworthy.
4949
* **Favorite**: Parts with this flag are highlighted in parts lists
5050
* **Mass**: The mass of a single piece of this part (so of a single transistor). Given in grams.
51-
* **Internal Part number** (IPN): Each part is automatically assigned a numerical ID that identifies a part in the
52-
database. This ID depends on when a part was created and can not be changed. If you want to assign your own unique
53-
identifiers, or sync parts identifiers with the identifiers of another database you can use this field.
51+
* **Internal Part Number** (IPN): Each part is automatically assigned a numerical ID that identifies a part in the
52+
database. This ID depends on when a part was created and cannot be changed. If you want to assign your own unique
53+
identifiers, or sync parts identifiers with the identifiers of another database, you can use this field.
5454

5555
### Stock / Part lot
5656

@@ -99,12 +99,12 @@ possible category tree could look like this:
9999

100100
### Supplier
101101

102-
A Supplier is a vendor/distributor where you can buy/order parts. Price information of parts is associated with a
102+
A supplier is a vendor/distributor where you can buy/order parts. Price information of parts is associated with a
103103
supplier.
104104

105105
### Manufacturer
106106

107-
A manufacturer represents the company that manufacturers/builds various parts (not necessarily sell them). If the
107+
A manufacturer represents the company that manufactures/builds various parts (not necessarily sells them). If the
108108
manufacturer also sells the parts, you have to create a supplier for that.
109109

110110
### Storage location

docs/configuration.md

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ nav_order: 5
66

77
# Configuration
88

9-
Part-DBs behavior can be configured to your needs. There are different kinds of configuration options: Options, which are
9+
Part-DB's behavior can be configured to your needs. There are different kinds of configuration options: Options that are
1010
user-changeable (changeable dynamically via frontend), options that can be configured by environment variables, and
1111
options that are only configurable via Symfony config files.
1212

@@ -40,8 +40,8 @@ The following configuration options can only be changed by the server administra
4040
variables, changing the `.env.local` file or setting env for your docker container. Here are just the most important
4141
options listed, see `.env` file for the full list of possible env variables.
4242

43-
Environment variables allow to overwrite settings in the web interface. This is useful, if you want to enforce certain
44-
settings to be unchangable by users, or if you want to configure settings in a central place in a deployed environment.
43+
Environment variables allow you to overwrite settings in the web interface. This is useful if you want to enforce certain
44+
settings to be unchangeable by users, or if you want to configure settings in a central place in a deployed environment.
4545
On the settings page, you can hover over a setting to see, which environment variable can be used to overwrite it, it
4646
is shown as tooltip. API keys or similar sensitive data which is overwritten by env variables, are redacted on the web
4747
interface, so that even administrators cannot see them (only the last 2 characters and the length).
@@ -105,11 +105,11 @@ bundled with Part-DB. Set `DATABASE_MYSQL_SSL_VERIFY_CERT` if you want to accept
105105
* `part_delete`: Delete operation of an existing part
106106
* `part_create`: Creation of a new part
107107
* `part_stock_operation`: Stock operation on a part (therefore withdraw, add or move stock)
108-
* `datastructure_edit`: Edit operation of an existing datastructure (e.g. category, manufacturer, ...)
109-
* `datastructure_delete`: Delete operation of a existing datastructure (e.g. category, manufacturer, ...)
110-
* `datastructure_create`: Creation of a new datastructure (e.g. category, manufacturer, ...)
111-
* `CHECK_FOR_UPDATES` (default `1`): Set this to 0, if you do not want Part-DB to connect to GitHub to check for new
112-
versions, or if your server can not connect to the internet.
108+
* `datastructure_edit`: Edit operation of an existing data structure (e.g. category, manufacturer, ...)
109+
* `datastructure_delete`: Delete operation of an existing data structure (e.g. category, manufacturer, ...)
110+
* `datastructure_create`: Creation of a new data structure (e.g. category, manufacturer, ...)
111+
* `CHECK_FOR_UPDATES` (default `1`): Set this to 0 if you do not want Part-DB to connect to GitHub to check for new
112+
versions, or if your server cannot connect to the internet.
113113
* `APP_SECRET` (env only): This variable is a configuration parameter used for various security-related purposes,
114114
particularly for securing and protecting various aspects of your application. It's a secret key that is used for
115115
cryptographic operations and security measures (session management, CSRF protection, etc..). Therefore this
@@ -262,10 +262,10 @@ markdown (and even some subset of HTML) syntax to format the text.
262262

263263
## parameters.yaml
264264

265-
You can also configure some options via the `config/parameters.yaml` file. This should normally not need,
266-
and you should know what you are doing, when you change something here. You should expect, that you will have to do some
267-
manual merge, when you have changed something here and update to a newer version of Part-DB. It is possible that
268-
configuration options here will change or be completely removed in future versions of Part-DB.
265+
You can also configure some options via the `config/parameters.yaml` file. This should normally not be needed,
266+
and you should know what you are doing when you change something here. You should expect that you will have to do some
267+
manual merges when you have changed something here and update to a newer version of Part-DB. It is possible that
268+
configuration options here will change or be completely removed in future versions of Part-DB.
269269

270270
If you change something here, you have to clear the cache, before the changes will take effect with the
271271
command `bin/console cache:clear`.

docs/index.md

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -27,31 +27,31 @@ It is installed on a web server and so can be accessed with any browser without
2727
* Inventory management of your electronic parts. Each part can be assigned to a category, footprint, manufacturer,
2828
and multiple store locations and price information. Parts can be grouped using tags. You can associate various files
2929
like datasheets or pictures with the parts.
30-
* Multi-language support (currently German, English, Russian, Japanese and French (experimental))
31-
* Barcodes/Labels generator for parts and storage locations, scan barcodes via webcam using the builtin barcode scanner
32-
* User system with groups and detailed (fine granular) permissions.
30+
* Multi-language support (currently German, English, Russian, Japanese, French, Czech, Danish, and Chinese)
31+
* Barcodes/Labels generator for parts and storage locations, scan barcodes via webcam using the built-in barcode scanner
32+
* User system with groups and detailed (fine-grained) permissions.
3333
Two-factor authentication is supported (Google Authenticator and Webauthn/U2F keys) and can be enforced for groups.
34-
Password reset via email can be setup.
34+
Password reset via email can be set up.
3535
* Optional support for single sign-on (SSO) via SAML (using an intermediate service
3636
like [Keycloak](https://www.keycloak.org/) you can connect Part-DB to an existing LDAP or Active Directory server)
3737
* Import/Export system
3838
* Project management: Create projects and assign parts to the bill of material (BOM), to show how often you could build
3939
this project and directly withdraw all components needed from DB
40-
* Event log: Track what changes happens to your inventory, track which user does what. Revert your parts to older
40+
* Event log: Track what changes happen to your inventory, track which user does what. Revert your parts to older
4141
versions.
42-
* Responsive design: You can use Part-DB on your PC, your tablet and your smartphone using the same interface.
42+
* Responsive design: You can use Part-DB on your PC, your tablet, and your smartphone using the same interface.
4343
* MySQL, SQLite and PostgreSQL are supported as database backends
4444
* Support for rich text descriptions and comments in parts
4545
* Support for multiple currencies and automatic update of exchange rates supported
4646
* Powerful search and filter function, including parametric search (search for parts according to some specifications)
4747
* Easy migration from an existing PartKeepr instance (see [here]({%link partkeepr_migration.md %}))
48-
* Use cloud providers (like Octopart, Digikey, Farnell or TME) to automatically get part information, datasheets and
48+
* Use cloud providers (like Octopart, Digikey, Farnell, Mouser, or TME) to automatically get part information, datasheets, and
4949
prices for parts (see [here]({% link usage/information_provider_system.md %}))
5050
* API to access Part-DB from other applications/scripts
51-
* [Integration with KiCad]({%link usage/eda_integration.md %}): Use Part-DB as central datasource for your
52-
KiCad and see available parts from Part-DB directly inside KiCad.
51+
* [Integration with KiCad]({%link usage/eda_integration.md %}): Use Part-DB as the central datasource for your
52+
KiCad and see available parts from Part-DB directly inside KiCad.
5353

54-
With these features Part-DB is useful to hobbyists, who want to keep track of their private electronic parts inventory,
54+
With these features, Part-DB is useful to hobbyists, who want to keep track of their private electronic parts inventory,
5555
or makerspaces, where many users should have (controlled) access to the shared inventory.
5656

5757
Part-DB is also used by small companies and universities for managing their inventory.
@@ -67,11 +67,11 @@ See [LICENSE](https://github.com/Part-DB/Part-DB-symfony/blob/master/LICENSE) fo
6767
## Donate for development
6868

6969
If you want to donate to the Part-DB developer, see the sponsor button in the top bar (next to the repo name).
70-
There you will find various methods to support development on a monthly or a one time base.
70+
There you will find various methods to support development on a monthly or a one-time basis.
7171

7272
## Built with
7373

74-
* [Symfony 5](https://symfony.com/): The main framework used for the serverside PHP
74+
* [Symfony 6](https://symfony.com/): The main framework used for the serverside PHP
7575
* [Bootstrap 5](https://getbootstrap.com/) and [Bootswatch](https://bootswatch.com/): Used as website theme
7676
* [Fontawesome](https://fontawesome.com/): Used as icon set
7777
* [Hotwire Stimulus](https://stimulus.hotwired.dev/) and [Hotwire Turbo](https://turbo.hotwired.dev/): Frontend

docs/installation/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,4 +8,4 @@ has_children: true
88
# Installation
99
Below you can find some guides to install Part-DB.
1010

11-
For the hobbyists without much experience, we recommend the docker installation or direct installation on debian.
11+
For hobbyists without much experience, we recommend the Docker installation or direct installation on Debian.

0 commit comments

Comments
 (0)