Summary: | Import default framework is broken | ||
---|---|---|---|
Product: | Koha | Reporter: | Viliam <viliam.polonec> |
Component: | System Administration | Assignee: | Jonathan Druart <jonathan.druart> |
Status: | CLOSED FIXED | QA Contact: | Testopia <testopia> |
Severity: | major | ||
Priority: | P5 - low | CC: | gmcharlt, jonathan.druart, julian.maurice, katrin.fischer, kyle, mtj, tomascohen |
Version: | master | ||
Hardware: | All | ||
OS: | Linux | ||
Change sponsored?: | --- | Patch complexity: | --- |
Documentation contact: | Documentation submission: | ||
Text to go in the release notes: | Version(s) released in: | ||
Bug Depends on: | 16035 | ||
Bug Blocks: | |||
Attachments: |
Bug 18111: Fix import of default framework
Bug 18111: Fix import of default framework Bug 18111: Swap framework_name and frameworkcode [SIGNED-OFF] Bug 18111: Fix import of default framework [SIGNED-OFF] Bug 18111: Swap framework_name and frameworkcode Bug 18111: Fix import of default framework Bug 18111: Swap framework_name and frameworkcode Bug 18111: Follow-up for 3.22.x |
Description
Viliam
2017-02-14 11:22:33 UTC
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 |