Commit graph

106 commits

Author SHA1 Message Date
Jan Böhmer
594a5779dc Specify that we mean a column in drop statement. This is more correct
Some checks are pending
Build assets artifact / Build assets artifact (push) Waiting to run
Docker Image Build / docker (push) Waiting to run
Docker Image Build (FrankenPHP) / docker (push) Waiting to run
Static analysis / Static analysis (push) Waiting to run
PHPUnit Tests / PHPUnit and coverage Test (PHP 8.1, mysql) (push) Waiting to run
PHPUnit Tests / PHPUnit and coverage Test (PHP 8.2, mysql) (push) Waiting to run
PHPUnit Tests / PHPUnit and coverage Test (PHP 8.3, mysql) (push) Waiting to run
PHPUnit Tests / PHPUnit and coverage Test (PHP 8.4, mysql) (push) Waiting to run
PHPUnit Tests / PHPUnit and coverage Test (PHP 8.1, postgres) (push) Waiting to run
PHPUnit Tests / PHPUnit and coverage Test (PHP 8.2, postgres) (push) Waiting to run
PHPUnit Tests / PHPUnit and coverage Test (PHP 8.3, postgres) (push) Waiting to run
PHPUnit Tests / PHPUnit and coverage Test (PHP 8.4, postgres) (push) Waiting to run
PHPUnit Tests / PHPUnit and coverage Test (PHP 8.1, sqlite) (push) Waiting to run
PHPUnit Tests / PHPUnit and coverage Test (PHP 8.2, sqlite) (push) Waiting to run
PHPUnit Tests / PHPUnit and coverage Test (PHP 8.3, sqlite) (push) Waiting to run
PHPUnit Tests / PHPUnit and coverage Test (PHP 8.4, sqlite) (push) Waiting to run
This should help with more strict sql servers like in issue #900
2025-03-29 20:57:58 +01:00
Jan Böhmer
467d50bd31 Use slightly different migration method for attachment system migration
This maybe help with issue #871
2025-02-25 00:32:04 +01:00
Jan Böhmer
6fd05e1456 Fixed migration 2025-02-22 19:23:28 +01:00
Jan Böhmer
bec45d60e5 Fixed migration for postgresql 2025-02-22 18:03:03 +01:00
Jan Böhmer
019e67a676 Migrate legacy attachment discriminator class values to modern format, so that we can make the discriminator map unique and fix a deprecation with doctrine 2025-02-22 17:58:20 +01:00
Jan Böhmer
48be9a8098 Made attachment datatable sortable by internal filename and external url 2025-02-22 17:41:41 +01:00
Treeed
29f92d9bd3
Split attachment paths (#848)
* fixed attachment statistics for sqlite

* Split attachment path into internal and external path, so the external source URL can be retained after a file is downloaded

* Make internal and external path for attachments nullable, to make clear that they have no internal or external path

* Added migrations for nullable columns for postgres and mysql

* Added migration for nullable internal and external pathes for sqlite

* Added translations

* Fixed upload error

* Restrict length of filename badge in attachment edit view

* Improved margins with badges in attachment edit

* Added a link to view external version from attachment edit

* Let media_url  stay in API attachments responses for backward compatibility

---------

Co-authored-by: jona <a@b.c>
Co-authored-by: Jan Böhmer <mail@jan-boehmer.de>
2025-02-22 17:29:14 +01:00
Jan Böhmer
27a28d4adc Fixed the NatSortKey function where regex characters were improperly escaped in the old migration
This caused a "range out of order in character class" error and propably affected the functionality of the sort function
2024-07-28 17:08:55 +02:00
Jan Böhmer
4946a9ab0d Fixed SQL declaration of NatSortKey function
We do not need the delimiter declarations
2024-06-18 22:32:07 +02:00
Jan Böhmer
123372d93f Allow to emulate natural sort on mysql platforms 2024-06-18 21:42:00 +02:00
Jan Böhmer
0a482da93e Use postgres native array_position function instead of our FIELD function and pass it as array literal instead of variadic function
Otherwise we will run into errors, that we can not give more than 100 arguments to a function
2024-06-17 23:13:04 +02:00
Jan Böhmer
8bb8118d9f Use natural sorting for trees and others repository functions 2024-06-17 22:33:40 +02:00
Jan Böhmer
9db822eabd Use natural sorting for string datatables columns when using postgres
The natural sorting solution is quite portable, so this should be possible for other database types too later
2024-06-17 21:38:16 +02:00
Jan Böhmer
4f75e2641b Define a custom FIELD function to sort tables by list of ids without the emulation via string operations 2024-06-16 23:46:40 +02:00
Jan Böhmer
eab1c7096c Use the postgres migration code generated by the new doctrine orm versions
This now uses IDENTITY columns for ID columns, which makes their behavior more similar to the behavior of MySQL and SQLite
2024-06-10 22:38:46 +02:00
Jan Böhmer
8ee3aaf4f4 Added Sqlite migrations required by new doctrine/orm version and fixed migration duplication for sqlite 2024-06-10 21:54:15 +02:00
Jan Böhmer
427b8659c9 Added MySQL migrations required by the doctrine upgrades
The new ORM versions, do not have anymore column comments, so these got removed
2024-06-10 21:43:25 +02:00
Jan Böhmer
a88a2e04cf Added the required initial users and groups for the database migration 2024-06-09 00:11:58 +02:00
Jan Böhmer
02acafc348 Added postgres to the AbstractMultiPlatformMigration class 2024-06-06 23:11:11 +02:00
Jan Böhmer
91b7f2752f Added the database fields required by the new webauthn bundle versions 2024-04-28 00:31:38 +02:00
Jan Böhmer
0445b87567 Added EDA column migration for SQLite 2023-12-03 00:00:46 +01:00
Jan Böhmer
bf5ed030fe Use the EDAInfo data to send info to KiCAD 2023-11-30 19:34:50 +01:00
Jan Böhmer
b76b2740a7 Use Embeddables for EDACategoryInfo instead of a json column 2023-11-30 19:13:32 +01:00
Jan Böhmer
d5f002ac20 Added basic ability to store EDA Data in a Part
But that might change, as it is currently not ideal
2023-11-30 12:54:30 +01:00
Jan Böhmer
6cff19358a Dont show the permission reset warning during database migration anymore
This only affects database which were older than the new permission system  and hopefully everybody should have updated by now. The message could irritate new users, so it was removed
2023-11-25 13:21:39 +01:00
Jan Böhmer
0ab604d468 Added migrations for sqlite 2023-11-17 23:26:45 +01:00
Jan Böhmer
c7892cb9e2 Added a seperate field for specifying the other relation 2023-11-14 23:35:18 +01:00
Jan Böhmer
8ab9cf1417 Added very basic possibility to add an association 2023-11-13 00:11:58 +01:00
Jan Böhmer
eabd03dc53 Fixed variable access curly brackets deprecations in migrations 2023-11-03 23:04:55 +01:00
Jan Böhmer
43c15de55c Added SQLite migrations for API tokens 2023-09-18 16:36:08 +02:00
Jan Böhmer
deec059a38 Merge branch 'master' into api 2023-09-17 10:32:25 +02:00
Jan Böhmer
4bed50d894 Allow database migration from legacy versions even if the perms_label column is missing in the groups table
This fixes issue #366 and #67
2023-09-09 23:04:50 +02:00
Jan Böhmer
8dad143f8d Added own APIToken authenticator, so we can wrap the used API token inside the symfony security token 2023-08-17 00:17:02 +02:00
Jan Böhmer
3bc6e61869 Added very basic system to add API tokens to an user 2023-08-15 23:36:56 +02:00
Jan Böhmer
c737348cea Dont skip the Sqlite migration. Do nothing instead
Before this migration was never finished and always re executed on subsequent migration attempts.
2023-07-31 22:30:02 +02:00
Jan Böhmer
e8e2258357 Added migration for SQLite 2023-07-31 22:28:19 +02:00
Jan Böhmer
0f336b6f89 Allow for longer manufacturer and supplier URLs 2023-07-31 00:00:57 +02:00
Jan Böhmer
6a00b8e168 Added possibility to manage client_credentials OAuth tokens 2023-07-30 15:24:46 +02:00
Jan Böhmer
5c17aee1e4 Properly escape group table name
Otherwise MySQL 8 will not be able to use this schema
2023-07-17 00:49:25 +02:00
Jan Böhmer
f423fdf7f8 Fixed bug in DB schema, which prevented the creation of parts without info provider reference 2023-07-16 23:48:55 +02:00
Jan Böhmer
edc54aaf91 Added migrations for sqlite and new additional_names field 2023-07-16 20:47:25 +02:00
Jan Böhmer
a95ba1acc4 Add a reference to the used info provider to a part 2023-07-16 01:24:49 +02:00
Jan Böhmer
7c03630e24 Added DB migration to fix compatibility with latest webauthn bundle 2023-05-28 02:06:48 +02:00
Jan Böhmer
557347d42d Fixed legacy database migration for newer MySQL version 2023-05-07 21:43:01 +02:00
Jan Böhmer
19ae9e7456 Fixed issue preventing migration from legacy Part-DB version
This bug was introduced during the fix for issue #260 (commit 2717d7d). With this commit issue #287 should be fixed
2023-05-07 02:29:32 +02:00
Jan Böhmer
303a3690e8 Normalize class_names for attachments migrated from legacy Part-DB database
This fixes issue #272
2023-04-17 23:52:08 +02:00
Jan Böhmer
c317bc020a Theme config migration should now work properly when migrating from legacy DB 2023-04-15 00:51:32 +02:00
Jan Böhmer
4065fb77da Properly escape group table name in legacy DB migration for compatibility with MySQL 8
Fixes issue #271
2023-04-15 00:49:02 +02:00
Jan Böhmer
fc1d2269d0 Fixed error with default values on older MySQL version
We have removed the default values for the columns completly, as it were only needed on SQLite when adding the column to existing row.
As this was done in an earlier migration, we can now safely remove it.

The MySQL now correctly detects no more changes. SQLite however still generates some wrong migration changes.
2023-04-09 01:17:48 +02:00
Jan Böhmer
cc033d5be7 Properly escape users and groups table name for newer MySQL version 2023-04-09 00:08:08 +02:00