Koha/installer
Katrin Fischer c904db832e Bug 22024: Correct new installations with missing data
For a new installation the data in the class_* will be
missing as class_sources.sql couldn't be executed. It will
fail with:

DBD::mysql::st execute failed: Cannot add or update a child row:
a foreign key constraint fails (`koha_kohadev`.`class_sources`,
CONSTRAINT `class_source_ibfk_2` FOREIGN KEY (`class_split_rule`)
REFERENCES `class_split_rules` (`class_split_rule`)) at /usr/share/perl5/DBIx/RunSQL.pm line 273.

As this might have been missed and the web installer can still
be completed, this patch checks for the tables being empty and
adds the default data if they are.

To test:
- Without the patch
- Run the de-DE or another translated installer
- Verify the error is shown
- Complete the installer
- Verify class_sources table is empty
- Apply patches
- Run the database update
- Verify data classification sources, filing rules, and
  slitting rules are now complete

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
2018-12-19 16:32:03 +00:00
..
data/mysql Bug 22024: Correct new installations with missing data 2018-12-19 16:32:03 +00:00
externalmodules.pl
html-template-to-template-toolkit.pl Bug 21719: Fix typos 2018-11-08 02:18:46 +00:00
install.pl Bug 21719: Fix typos 2018-11-08 02:18:46 +00:00
onboarding.pl Bug 21149: Fix superlibrarian creation in onboarding 2018-08-08 12:49:22 +00:00