[Bug 7379] New: some database fields are displayed 'as is' when they are linked to autorised values
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=7379 Bug #: 7379 Summary: some database fields are displayed 'as is' when they are linked to autorised values Classification: Unclassified Change sponsored?: --- Product: Koha Version: rel_3_6 Platform: All OS/Version: All Status: NEW Severity: normal Priority: P5 - low Component: Architecture, internals, and plumbing AssignedTo: gmcharlt@gmail.com ReportedBy: gaetan.boisson@biblibre.com QAContact: ian.walls@bywatersolutions.com When items.copynumber is linked to an autorized value, the value displayed both on OPAC and on the staff interface is the one found in the database and not the description linked to the value. This should be fixed in order for this field to function like the other ones, where the authorized value's description is displayed when the field is linked to an authorized value. -- Configure bugmail: http://bugs.koha-community.org/bugzilla3/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=7379 Adrien SAURAT <adrien.saurat@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |ASSIGNED CC| |adrien.saurat@biblibre.com AssignedTo|gmcharlt@gmail.com |adrien.saurat@biblibre.com -- Configure bugmail: http://bugs.koha-community.org/bugzilla3/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=7379 --- Comment #1 from Adrien SAURAT <adrien.saurat@biblibre.com> 2012-01-03 10:31:09 UTC --- Created attachment 7025 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=7025 proposed patch Displays description for copynumber (staff and OPAC) + corrects a small bug which was generating error messages in logs + corrects indentations -- Configure bugmail: http://bugs.koha-community.org/bugzilla3/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=7379 Adrien SAURAT <adrien.saurat@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Priority|P5 - low |PATCH-Sent Patch Status|--- |Needs Signoff -- Configure bugmail: http://bugs.koha-community.org/bugzilla3/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=7379 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |katrin.fischer@bsz-bw.de --- Comment #2 from Katrin Fischer <katrin.fischer@bsz-bw.de> 2012-01-03 10:36:42 UTC --- I am not sure about the indentation changes - it makes it hard to read your patch and spot the real changes. I think in the past it was said to do things like this in a separate patch (http://wiki.koha-community.org/wiki/Coding_Guidelines#Refactoring_Code) Not sure how we want to handle this now - perhaps a question for the QA team? -- Configure bugmail: http://bugs.koha-community.org/bugzilla3/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=7379 --- Comment #3 from Adrien SAURAT <adrien.saurat@biblibre.com> 2012-01-03 10:51:25 UTC --- Well, refactoring could take some time and is not necessarily useful. Indenting is quick to do and makes the file more readable (but the patch far less readable indeed). I'll follow any line, but it needs to be clear, Chris told me a few weeks ago that it was good to enhance the code whenever possible without creating new bugs for this. ====================================== I'll help you read this patch. I used the same code already used for "ccode", adding this in opac-detail.pl : my $copynumbers = GetKohaAuthorisedValues('items.copynumber',$dat->{'frameworkcode'}, 'opac'); ... if ( my $copynumber = $itm->{'copynumber'} ) { $itm->{'copynumber'} = $copynumbers->{$copynumber} if ( defined($copynumbers) && exists( $copynumbers->{$copynumber} ) ); } and this in detail.pl : my $copynumbers = GetKohaAuthorisedValues('items.copynumber', $fw); ... my $copynumber = $item->{'copynumber'}; $item->{'copynumber'} = $copynumbers->{$copynumber} if ( defined( $copynumber ) && defined($copynumber) && exists( $copynumbers->{$copynumber} ) ); ========================== Next time I'll try to modify only the code surrounding the bug fix. -- Configure bugmail: http://bugs.koha-community.org/bugzilla3/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=7379 Magnus Enger <magnus@enger.priv.no> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |magnus@enger.priv.no --- Comment #4 from Magnus Enger <magnus@enger.priv.no> 2012-01-03 10:53:56 UTC --- I think there is some relevant advice here: http://wiki.koha-community.org/wiki/Perltidy We just need to figure out what a "code block" is... ;-) -- Configure bugmail: http://bugs.koha-community.org/bugzilla3/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=7379 --- Comment #5 from Katrin Fischer <katrin.fischer@bsz-bw.de> 2012-01-03 11:00:35 UTC --- Magnus: agreed :) For the record, meeting minutes and decided style: http://librarypolice.com/koha-meetings/2011/koha.2011-10-05-10.00.html AGREED: perl-style (Brooke, 12:37:05) I also discovered the bugzilla 'Diff' view is quite helpful to spot the real changes. -- Configure bugmail: http://bugs.koha-community.org/bugzilla3/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=7379 --- Comment #6 from Gaetan Boisson <gaetan.boisson@biblibre.com> 2012-01-03 11:25:01 UTC --- This works fine on the admin side. On the OPAC side however, it doesn't work when the authorized value is 0. -- Configure bugmail: http://bugs.koha-community.org/bugzilla3/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=7379 Adrien SAURAT <adrien.saurat@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #7025|0 |1 is obsolete| | --- Comment #7 from Adrien SAURAT <adrien.saurat@biblibre.com> 2012-01-03 13:07:38 UTC --- Created attachment 7026 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=7026 proposed patch #2 Corrected. Works on Staff/OPAC even if value is 0. -- Configure bugmail: http://bugs.koha-community.org/bugzilla3/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=7379 --- Comment #8 from Gaetan Boisson <gaetan.boisson@biblibre.com> 2012-01-03 13:15:21 UTC --- The 0 problem is solved! I discovered a new one though : on the items tab on the admin interface the informations are displayed in a different layout, this still displays the authorised value and not it's description. -- Configure bugmail: http://bugs.koha-community.org/bugzilla3/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=7379 Adrien SAURAT <adrien.saurat@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #7026|0 |1 is obsolete| | --- Comment #9 from Adrien SAURAT <adrien.saurat@biblibre.com> 2012-01-03 15:41:26 UTC --- Created attachment 7029 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=7029 proposed patch #3 Handles now the page "moredetail" (items). -- Configure bugmail: http://bugs.koha-community.org/bugzilla3/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=7379 --- Comment #10 from Gaetan Boisson <gaetan.boisson@biblibre.com> 2012-01-03 16:07:46 UTC --- Created attachment 7030 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=7030 [SIGNED-OFF] Works on the OPAC and in the admin, both in normal and item view. Bug 7379: display of copynumber description The biblio/items detail pages display the copynumber description if an authorized value is configured accordingly. Signed-off-by: Gaetan Boisson <gaetan.boisson@biblibre.com> -- Configure bugmail: http://bugs.koha-community.org/bugzilla3/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=7379 Gaetan Boisson <gaetan.boisson@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Patch Status|Needs Signoff |Signed Off -- Configure bugmail: http://bugs.koha-community.org/bugzilla3/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=7379 --- Comment #11 from Ian Walls <ian.walls@bywatersolutions.com> 2012-01-11 02:39:29 UTC --- Perhaps I'm missing something, but it does seem to me that copynumber is a field that makes sense to link to an authorised values field. Unlike location and ccode, which are a discrete set of values, copynumbers are sequential, with a potentially infinite number of values. Preconfiguring a set of values seems like a very uncommon practice. If we're going to add support for copynumber authorised values, I think we should add support for ANY item field being linked to authorised values (since that can be changed by any library in the Frameworks) This is where I'd change the status to "In Discussion"... -- Configure bugmail: http://bugs.koha-community.org/bugzilla3/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=7379 --- Comment #12 from Adrien SAURAT <adrien.saurat@biblibre.com> 2012-01-11 08:42:49 UTC --- Gaetan would know better about the functionnal part. I only know that at least one of our libraries uses copynumber with a set of values. For information (I guess it was understood this way but prefer to be sure), if there are no authorised values associated to the copynumber, the copynumber is simply displayed. This patch wouldn't force any library to add a new authorised values. And doing this for copynumber maybe (Gaetan?) makes sense because not so many fields are displayed on the detail page. Which other field would need to get such a link possibility? -- Configure bugmail: http://bugs.koha-community.org/bugzilla3/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=7379 --- Comment #13 from Gaetan Boisson <gaetan.boisson@biblibre.com> 2012-01-11 10:09:55 UTC --- Ian is right that it is uncommon practice to use an authorised value for copynumber. The problem has it roots in the fact that we don't have something like 'extended item attributes' like we have for patrons, so we find ourselves doing with the available fields to take care of all the small idiosyncrasies of our libraries. For now my opinion is that whenever a field is linked to an authorised value, then the label for the value should be displayed and not the value itself. -- Configure bugmail: http://bugs.koha-community.org/bugzilla3/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=7379 --- Comment #14 from Katrin Fischer <katrin.fischer@bsz-bw.de> 2012-01-11 10:21:57 UTC --- I think a lot of people reuse fields and reusing copynumber should be relatively safe. As we have the option to link an authorised value category to each field in configuration, it should work for all of them or only offer the option for those where it works. A general solution would be nice - but not sure how hard it is. -- Configure bugmail: http://bugs.koha-community.org/bugzilla3/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=7379 --- Comment #15 from Adrien SAURAT <adrien.saurat@biblibre.com> 2012-01-11 14:46:29 UTC --- There is no way to dynamically implement a general solution which would display labels wherever we expect them. I had to specifically add this for copynumber in the detail pages. Doing this for every field in every potential page would require a exhaustive listing of all cases. Which fields would need this? ("all of them" seems not so sure to me, see "Last seen" and "Barcode") -- Configure bugmail: http://bugs.koha-community.org/bugzilla3/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=7379 M. de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #7029|0 |1 is obsolete| | -- Configure bugmail: http://bugs.koha-community.org/bugzilla3/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=7379 M. de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |In Discussion CC| |m.de.rooy@rijksmuseum.nl --- Comment #16 from M. de Rooy <m.de.rooy@rijksmuseum.nl> 2012-01-18 13:07:28 UTC --- It seems to me (from the above comments) that this report is a typical candidate for being parked at In Discussion for this time. Perhaps the author could mail the list and ask for more input? -- Configure bugmail: http://bugs.koha-community.org/bugzilla3/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=7379 Gaetan Boisson <gaetan.boisson@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|In Discussion |Signed Off Summary|some database fields are |copynumber is displayed 'as |displayed 'as is' when they |is' when linked to |are linked to autorised |autorised values |values | --- Comment #17 from Gaetan Boisson <gaetan.boisson@biblibre.com> 2012-02-10 15:12:23 UTC --- In order to make the discussion move forward, i am renaming this bug to something more specific (the submitted patch has already been tested and signed off), and creating another bug ticket where we should see whether we want to generalize this behaviour to other fields and how. See : http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=7525 -- Configure bugmail: http://bugs.koha-community.org/bugzilla3/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=7379 Gaetan Boisson <gaetan.boisson@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- See Also| |http://bugs.koha-community. | |org/bugzilla3/show_bug.cgi? | |id=7525 -- Configure bugmail: http://bugs.koha-community.org/bugzilla3/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=7379 Paul Poulain <paul.poulain@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Priority|PATCH-Sent (DO NOT USE) |P3 CC| |paul.poulain@biblibre.com --- Comment #18 from Paul Poulain <paul.poulain@biblibre.com> 2012-02-20 21:32:35 UTC --- I tend to agree with Gaetan's opinion : let's push this patch, and discuss a generic option. Won't force the decision though. Marcel, what's your ? -- Configure bugmail: http://bugs.koha-community.org/bugzilla3/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=7379 M. de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Failed QA --- Comment #19 from M. de Rooy <m.de.rooy@rijksmuseum.nl> 2012-03-01 11:25:50 UTC --- Adrien: Patch has merge conflicts now in opac-detail and detail.pl The conflict in opac-detail is the most interesting, mainly because of this (new) call: my ($reserve_status) = C4::Reserves::CheckReserves($itm->{itemnumber}); I started resolving, but I think it is better to leave that up to you in this case. When you have tested it again, I can continue QA "unbiased".. -- Configure bugmail: http://bugs.koha-community.org/bugzilla3/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=7379 Adrien SAURAT <adrien.saurat@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #7030|0 |1 is obsolete| | --- Comment #20 from Adrien SAURAT <adrien.saurat@biblibre.com> --- Created attachment 7977 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=7977&action=edit proposed patch #2 It should apply again. This time the patch is easier to read (no indentation change). -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=7379 Adrien SAURAT <adrien.saurat@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Failed QA |Needs Signoff -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=7379 M. de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Signed Off QA Contact|koha.sekjal@gmail.com |m.de.rooy@rijksmuseum.nl --- Comment #21 from M. de Rooy <m.de.rooy@rijksmuseum.nl> --- I am setting this status back to Signed off (which it was before starting QA). Will pick this up soon if no other QA team member beats me to it. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=7379 M. de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Failed QA --- Comment #22 from M. de Rooy <m.de.rooy@rijksmuseum.nl> --- QA Comment: A general discussion about this kind of change can be held elsewhere indeed. I do not know if many will put auth values on copynumber, but I do not object to this specific change. catalogue/detail and opac-detail look good. moredetail: there is no check here like in detail; if the value has no entry in the auth value hash, you display nothing while detail and opac-detail show the original value. Please add the check there too for getting this patch in the next stage. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=7379 Paul Poulain <paul.poulain@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Failed QA |In Discussion -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=7379 Paul Poulain <paul.poulain@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Blocks| |7515 -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=7379 Adrien SAURAT <adrien.saurat@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #7977|0 |1 is obsolete| | --- Comment #23 from Adrien SAURAT <adrien.saurat@biblibre.com> --- Created attachment 10036 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=10036&action=edit proposed patch #3 New patch, with default value appearing in "moredetail" even if the AV does not exist. (to test this specific behaviour : select a value then delete the AV associated to it) -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=7379 Adrien SAURAT <adrien.saurat@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|In Discussion |Signed Off -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=7379 M. de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Passed QA Version|rel_3_6 |master --- Comment #24 from M. de Rooy <m.de.rooy@rijksmuseum.nl> --- The adjusted patch lost the signoff in the commit message, but did not really change. A previous QA comment has been applied. Looks good to me. Passed QA -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=7379 Paul Poulain <paul.poulain@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Passed QA |Pushed to Master Version|master |rel_3_8 --- Comment #25 from Paul Poulain <paul.poulain@biblibre.com> --- Patch pushed, signoff from Gaetan reintroduced -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=7379 --- Comment #26 from Rolando Isidoro <rolando.isidoro@gmail.com> --- Created attachment 12954 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=12954&action=edit Bug 7379- Allow for new type of LDAP authentication This patch aims to solve the LDAP bind authentication method. Here are some considerations: - This is a standalone patch, so all the previous submitted ones are rendered obsolete; - LDAP bind authentication is now done in 3 steps: 1 - LDAP anonymous bind; 2 - LDAP search entry for the given username; 3 - LDAP bind with the DN of the found entry + the given password. - The process fails if none or more than 1 entries are found for the given username; - The <principal_name> setting in koha-conf.xml isn't used anymore; - The patch is backwards compatible, so users already using the previously implemented LDAP bind authentication should be able to use it the same. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=7379 --- Comment #27 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- Hi Rolando, thank you for your patch, but I think you might have had a typo in your bug number - could you check? -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=7379 Rolando Isidoro <rolando.isidoro@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #12954|0 |1 is obsolete| | --- Comment #28 from Rolando Isidoro <rolando.isidoro@gmail.com> --- Comment on attachment 12954 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=12954 Bug 7379- Allow for new type of LDAP authentication Wrong bug number, sorry for the mix up. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=7379 Chris Cormack <chris@bigballofwax.co.nz> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Pushed to Master |Pushed to Stable CC| |chris@bigballofwax.co.nz --- Comment #29 from Chris Cormack <chris@bigballofwax.co.nz> --- Pushed to 3.8.x will be in 3.8.12 -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org