We can't import our custom framework as default framework. We try it in KOHA 16.01 and 16.05. We also try to export default framework, edit only one name of field and still it's impossible to import it as default framework. In version 3.20 everything is OK.
Confirmed on master.
Created attachment 60216 [details] [review] Bug 18111: Fix import of default framework Caused by bug 16035. Recreate the issue: Go to Home › Administration › MARC frameworks For the default framework: Actions > import It will not work Test plan: Confirm test plans from bug 16035 and bug 17389 still pass Confirm that the import for the default framework now works
Upping severity.
Comment on attachment 60216 [details] [review] Bug 18111: Fix import of default framework Review of attachment 60216 [details] [review]: ----------------------------------------------------------------- Overall, I like this cleaner code. ::: admin/import_export_framework.pl @@ +53,5 @@ > ## Exporting > if ($action eq 'export' && $input->request_method() eq 'GET') { > my $strXml = ''; > + my $format = $input->param('type_export_' . $framework_name); > + ExportFramework('', \$strXml, $format); Shouldn't this be $frameworkcode? You split the code and name logic, so the code is set properly.
Created attachment 60239 [details] [review] Bug 18111: Fix import of default framework Caused by bug 16035. Recreate the issue: Go to Home › Administration › MARC frameworks For the default framework: Actions > import It will not work Test plan: Confirm test plans from bug 16035 and bug 17389 still pass Confirm that the import for the default framework now works
(In reply to M. Tompsett from comment #4) > > + ExportFramework('', \$strXml, $format); > > Shouldn't this be $frameworkcode? You split the code and name logic, so the > code is set properly. Erk yes of course, I kept the wrong line!
Created attachment 60436 [details] [review] Bug 18111: Swap framework_name and frameworkcode With the frameworkcode changed to an empty string, which really is closer to the physical reality, some javascript somewhere breaks. This means the spinner does not appear when you confirm that you wish to import it. TEST PLAN ---------- 1) apply first patch 2) export default framework, doesn't matter format 3) import default framework using that file. 4) answer yes or whatever it is. -- spinner does not appear. 5) apply this patch 6) import default framework use the same file. 7) answer yes or whatever it is. -- spinner does appear. 8) decide if you wish to find and fix the javascript conditions. if yes -- do so, and then obsolete this once you have. if not -- sign this off after running koha qa test tools
Created attachment 60437 [details] [review] [SIGNED-OFF] Bug 18111: Fix import of default framework Caused by bug 16035. Recreate the issue: Go to Home › Administration › MARC frameworks For the default framework: Actions > import It will not work Test plan: Confirm test plans from bug 16035 and bug 17389 still pass Confirm that the import for the default framework now works Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Created attachment 60438 [details] [review] [SIGNED-OFF] Bug 18111: Swap framework_name and frameworkcode With the frameworkcode changed to an empty string, which really is closer to the physical reality, some javascript somewhere breaks. This means the spinner does not appear when you confirm that you wish to import it. TEST PLAN ---------- 1) apply first patch 2) export default framework, doesn't matter format 3) import default framework using that file. 4) answer yes or whatever it is. -- spinner does not appear. 5) apply this patch 6) import default framework use the same file. 7) answer yes or whatever it is. -- spinner does appear. 8) decide if you wish to find and fix the javascript conditions. if yes -- do so, and then obsolete this once you have. if not -- sign this off after running koha qa test tools Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Created attachment 60522 [details] [review] Bug 18111: Fix import of default framework Caused by bug 16035. Recreate the issue: Go to Home › Administration › MARC frameworks For the default framework: Actions > import It will not work Test plan: Confirm test plans from bug 16035 and bug 17389 still pass Confirm that the import for the default framework now works Signed-off-by: Josef Moravec <josef.moravec@gmail.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Created attachment 60523 [details] [review] Bug 18111: Swap framework_name and frameworkcode With the frameworkcode changed to an empty string, which really is closer to the physical reality, some javascript somewhere breaks. This means the spinner does not appear when you confirm that you wish to import it. TEST PLAN ---------- 1) apply first patch 2) export default framework, doesn't matter format 3) import default framework using that file. 4) answer yes or whatever it is. -- spinner does not appear. 5) apply this patch 6) import default framework use the same file. 7) answer yes or whatever it is. -- spinner does appear. 8) decide if you wish to find and fix the javascript conditions. if yes -- do so, and then obsolete this once you have. if not -- sign this off after running koha qa test tools Signed-off-by: Josef Moravec <josef.moravec@gmail.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
The fix works as expected.
Pushed to master for 17.05, thanks Jonathan, Mark!
These patches have been pushed to 16.11.x and will be in 16.11.04.
import default framework in 16.11.04 is OK, thanks
Pushed to 16.05.x, for 16.05.10 release
Created attachment 61099 [details] [review] Bug 18111: Follow-up for 3.22.x Replace [% frameworkcode %] by 'default' wherever needed
Pushed to 3.22.x, will be in 3.22.18