[Koha-devel] Vue improvements/refactorings

Jonathan Druart jonathan.druart at bugs.koha-community.org
Thu Feb 16 08:41:07 CET 2023


Bug 32806 modifies the directory structure and how Vue files are organised.
Bug 32939 is centralising the way we request the Koha REST API by having a
single place where the fetch is made.
I want people to be aware of these changes, and see them agree (or disagree
and provide follow-ups) quickly. There are many changes to build on top of
that, and we don't want to provide them before getting the suggestion
approved.

Le mer. 15 févr. 2023 à 23:18, David Cook <dcook at prosentient.com.au> a
écrit :

> I’ve started playing more with Vue for some other projects, so I wouldn’t
> mind taking a look.
>
>
>
> Is there anything particular you want us to look at with these patches?
>
>
>
> David Cook
>
> Senior Software Engineer
>
> Prosentient Systems
>
> Suite 7.03
>
> 6a Glen St
>
> Milsons Point NSW 2061
>
> Australia
>
>
>
> Office: 02 9212 0899
>
> Online: 02 8005 0595
>
>
>
> *From:* Koha-devel <koha-devel-bounces at lists.koha-community.org> *On
> Behalf Of *Jonathan Druart
> *Sent:* Thursday, 16 February 2023 12:10 AM
> *To:* koha-devel <koha-devel at lists.koha-community.org>
> *Subject:* [Koha-devel] Vue improvements/refactorings
>
>
>
> Hi,
>
>
>
> Pedro and I have been working on improving the way we request the Koha
> REST API from Vue components.
>
> We ended up with the implementation that is available on the following
> remote branch:
>
> https://gitlab.com/joubu/Koha/-/commits/bug_32925
>
>
>
> It contains the patches from the following bug reports:
>
> *Bug 32898*
> <https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=32898> -
> Cypress tests are failing
>
> *Bug 32923*
> <https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=32923> -
> x-koha-embed must a header of collectionFormat csv
>
> *Bug 32806*
> <https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=32806> - Some
> Vue files need to be moved for better reusability
>
> *Bug 32939*
> <https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=32939> - Have
> generic fetch functions in vue modules
>
> *Bug 32925*
> <https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=32925> -
> Display loading info when a form is submitted
>
>
>
> First, make the tests pass (32898)! We forgot to include the cypress test
> in the jenkins pipeline and we missed regressions! There have been
> regressions on the REST API specs, that are fixed on 32923.
>
> We noticed that the code we provided for the ERM module was not flexible
> enough and too ERM oriented. Some directories have been moved and code
> split a bit to make it more reusable for other modules (32806).
>
> Finally there are 32939 that introduce generic fetch functions, to have
> all the error handling (catch exceptions and display the error on the UI)
> in a single place. On top of that we added a "loading" message when a form
> (POST/PUT/DELETE) is submitted and, thanks to the previous moves, it's only
> a couple of lines of code!
>
>
>
> All this must be considered a base for future Vue enhancements, and I
> would like people interested in the Vue work to have a look at it.
>
>
>
> Cheers,
>
> Jonathan
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.koha-community.org/pipermail/koha-devel/attachments/20230216/00294e0d/attachment.htm>


More information about the Koha-devel mailing list